qq пре 2 година
родитељ
комит
128be3bab6

+ 5 - 5
src/components/assembly/tk_st_qp.vue

@@ -47,7 +47,7 @@
               <span class="gray">/{{ tk_list.length}}</span></span
             >
           </div>
-          <div class="tk_list" :style="{height:navId==1?Common.clientHeight-65+'px':Common.clientHeight-130+'px'}">
+          <div class="tk_list" :style="{height:navId==1?$c.cle-65+'px':$c.cle-130+'px'}">
             <li
               class="tk_item"
               v-for="(item, i) in tk_list"
@@ -97,15 +97,15 @@
             <span>第{{ i + 1 }}题</span>
            <el-progress
                       :percentage="
-                        item.marked_amount == 0 ? 0 : (item.marked_amount / tk_list.length) * 100
+                        item.marked_amount == 0 ? 0 : (item.marked_amount / item.question_amount) * 100
                       "
                       :stroke-width="10"
-                      :color="item.marked_amount == tk_list.length ? '#0A9DFF' : '#FA0A2F'"
+                      :color="item.marked_amount == item.question_amount ? '#0A9DFF' : '#FA0A2F'"
                     ></el-progress>
-                    <span>{{ item.marked_amount }}/{{ tk_list.length }}</span>
+                    <span>{{ item.marked_amount }}/{{item.question_amount }}</span>
           </li>
         </div>
-          <div class="st_tk_num" v-else :style="{height:Common.clientHeight-130+'px'}">
+          <div class="st_tk_num" v-else :style="{height:$c.cle-130+'px'}">
                   <li
                     v-for="(item, i) in tk_num"
                     :key="i + '批阅'"

+ 1 - 1
src/components/customer/err_book.vue

@@ -257,7 +257,7 @@ export default {
   width: 230px;
   padding: 10px 0;
   background-color: #fff;
-  height: 176px;
+  height: 130px;
 }
 .leftMenu i {
   display: inline-block;

+ 1 - 1
src/components/customer/per_err.vue

@@ -334,7 +334,7 @@ export default {
   width: 230px;
   padding: 10px 0;
   background-color: #fff;
-  height: 176px;
+  height: 130px;
 }
 .leftMenu i {
   /* width: 14px;

+ 1 - 1
src/components/customer/student_err.vue

@@ -253,7 +253,7 @@ export default {
   width: 230px;
   padding: 10px 0;
   background-color: #fff;
-  height: 176px;
+  height: 130px;
 }
 .leftMenu i {
   /* width: 14px;

+ 7 - 13
src/components/customer/tk_yp.vue

@@ -158,9 +158,9 @@
                   >
                     <span>第{{ i + 1 }}题</span>
                     <el-progress
-                      :percentage="item.bfb"
+                      :percentage="item.marked_amount == 0 ? 0 : (item.marked_amount / item.question_amount) * 100"
                       :stroke-width="10"
-                      :color="item.marked_amount == tk_list.length ? '#0A9DFF' : '#FA0A2F'"
+                      :color="item.marked_amount == item.question_amount ? '#0A9DFF' : '#FA0A2F'"
                     ></el-progress>
                     <span>{{ item.marked_amount }}/{{ item.question_amount}}</span>
                   </li>
@@ -241,9 +241,9 @@
     <div class="bg_box" v-if="is_answer">
       <div class="answers">
         <span class="el-icon-circle-close" @click="is_answer=false"></span>
-           <img :src="answer.full_img" alt="">
+           <!-- <img :src="answer.full_img" alt=""> -->
             <div> <span>答案:</span> <span class="option">{{answer.answer}}</span></div>
-            <div> <span>解析:</span> <span>{{answer.analysis}}</span></div>
+            <div> <span>解析:</span> <span v-html="answer.analysis"></span></div>
       </div>
     </div>
     <full v-if="full" @sign="sign" @fatherMethod='review_succ' :tk_lists='tk_list' :tk_nums='tk_num' :selectIds='selectId' :num_ids='num_id' :navIds='nav_id' @pnoChange='pnoChange'></full>
@@ -420,14 +420,6 @@ export default {
         var that = this;
        get("/v1/api/tasks/"+ this.id +"/process").then((res) => {
       if (res.errcode == 0) {
-         res.data.forEach((item,i) => {
-           if(item.marked_amount){
-             item.bfb = (item.question_amount/that.tk_list.length).toFixed(2)*100
-            //  console.log(item.bfb)
-           }else{
-             item.bfb =0
-           }
-          });
         that.tk_num = res.data;
         that.lock = true;
       }
@@ -440,7 +432,6 @@ export default {
           return;
       }
       this.lock = false;
-      // console.log(id,score)
      var pattern=/^([1-9]\d*|0)$/;
       if (!score) {
         this.$message.warning("还没打分哦~");
@@ -448,6 +439,9 @@ export default {
       }else if(!pattern.test(this.score)){
          this.$message.warning('分数输入不正确');
         return
+      }else if(Number(this.score) > this.tk_list[this.selectId].score){
+          this.$message.warning('批阅得分大于试题满分,本题满分为:'+this.tk_list[this.selectId].score+'分');
+             return
       }
       this.downLoadImage(id,score);
     },

+ 1 - 1
src/components/customer/topic.vue

@@ -629,7 +629,7 @@ export default {
   width: 230px;
   padding: 10px 0;
   background-color: #fff;
-  /* height: 130px; */
+  height: 130px;
 }
 .leftMenu i {
   /* width: 14px;