Quellcode durchsuchen

客观题识别基本完成

Your Name vor 1 Jahr
Ursprung
Commit
839b4a6371
3 geänderte Dateien mit 38 neuen und 35 gelöschten Zeilen
  1. 2 6
      src/constant.js
  2. 9 15
      src/views/papers/cutPaper.vue
  3. 27 14
      src/views/tasks/Index.vue

+ 2 - 6
src/constant.js

@@ -45,11 +45,7 @@ export default{
     ],
     recErrorList:[
         {label:"待上传",value:0},
-        {label:"少识别选项",value:-1},
-        {label:"多识别选项",value:-2},
-        {label:"单选题多涂",value:-3},
-        {label:"考号异常,少识别选项",value:-11},
-        {label:"考号异常,多识别选项",value:-12},
-        {label:"考号异常,单选题多涂",value:-13}
+        {label:"考号异常",value:-1},
+        {label:"客观题异常",value:-2},
     ]
 }

+ 9 - 15
src/views/papers/cutPaper.vue

@@ -108,8 +108,8 @@
     <!-- 客观题设置 -->
     <el-dialog title="客观题设置" :visible.sync="open" width="90%" append-to-body>
       <el-row :gutter="20">
-        <el-col :span="12">
-          <h4>分数设置</h4>
+        <el-col :span="6">
+          <h4>题号设置</h4>
           <!-- <div class="tag-group">
                   <span class="tag-group__title">填涂选项:</span>
                   <el-tag
@@ -123,7 +123,7 @@
                   </el-tag>
                 </div> -->
           <div style="margin-top:10px;" class="setScoreForm">
-            <el-form :inline="true" v-model="addQueForm">
+            <!--<el-form :inline="true" v-model="addQueForm">
               <el-form-item label="题号">
                 <el-input size="mini" v-model="addQueForm.fQno"></el-input>
               </el-form-item>
@@ -139,17 +139,10 @@
                   <el-option label="多选" value="2">多选</el-option>
                 </el-select>
               </el-form-item>
-              <!-- <el-form-item label="标准答案">
-                <el-select size="mini" v-model="addQueForm.stdAns" multiple>
-                  <el-option :label="item.label" :value="item.value" v-for="(item,index) in $const.ansOptionList"
-                    :key="index"></el-option>
-                </el-select>
-              </el-form-item> -->
               <el-form-item>
                 <el-button size="mini" type="primary" @click="addQues">设置</el-button>
               </el-form-item>
-            </el-form>
-
+            </el-form>-->
             <el-table :data="curStdQueList.slice((currentPage-1)*pageSize,currentPage*pageSize)">
               <el-table-column label="序号" prop="qno" width="60px"></el-table-column>
               <el-table-column label="题号" prop="qno">
@@ -157,7 +150,7 @@
                     <el-input size="mini" v-model="scope.row.qno" />
                 </template>
               </el-table-column>
-              <el-table-column label="分数" prop="score"></el-table-column>
+              <!--<el-table-column label="分数" prop="score"></el-table-column>
               <el-table-column label="题型" prop="qtype">
                 <template slot-scope="scope">
                   <span v-if="scope.row.qtype==1">单选</span>
@@ -173,13 +166,14 @@
                   </el-tag>
                 </template>
               </el-table-column>
+              -->
             </el-table>
             <el-pagination background layout="prev, pager, next" :page-sizes="[10,20,30,50]" :page-size="pageSize"
               @current-change="handleCurrentChange" :current-page.sync="currentPage" :total="curStdQueList.length">
             </el-pagination>
           </div>
         </el-col>
-        <el-col :span="12">
+        <el-col :span="18">
           <h4>答题卡预览</h4>
           <!-- <el-image v-else :src="curAnsImg" v-loading="ansImgLoading"></el-image> -->
           <el-row>
@@ -858,7 +852,7 @@
         if (this.stepNum == 2) {
           let params = {
             id: this.$route.query.id,
-            khPoints:this.khPointsCrop,
+            khPoints:this.khPoints,
             khPointsCrop:this.snoImg,
             khType:this.khType,
             khLength:this.khLength,
@@ -867,7 +861,7 @@
           this.$api.updatePaperInfo(params).then(res => {
             let rst = res.data;
             if (!rst.code && rst.data.khPointsCrop && rst.data.khPoints) {
-              let khPointsCrop = JSON.parse(rst.data.khPointsCrop)
+              let khPointsCrop = JSON.parse(rst.data.khPoints)
               let stdKhList = JSON.parse(rst.data.stdKhList);
               let khLength = rst.data.khLength;
               if (khPointsCrop.x < 10 || khPointsCrop.y < 10 || khPointsCrop.w < 50 ||

+ 27 - 14
src/views/tasks/Index.vue

@@ -127,12 +127,12 @@
             <el-form-item label="姓名">
               <el-input size="mini" placeholder="请输入姓名/考号" v-model="queryName" clearable></el-input>
             </el-form-item>
-            <el-form-item label="识别异常">
+            <!--<el-form-item label="识别异常">
               <el-select v-model="queryMarkStatus" size="mini" clearable>
                 <el-option v-for="item in $const.recErrorList" :label="item.label" :value="item.value"></el-option>
 
               </el-select>
-            </el-form-item>
+            </el-form-item>-->
             <el-form-item>
               <el-button type="primary" size="mini" @click=searchMarkData>搜索</el-button>
               <el-button size="mini" @click="reSetMarkData">重置</el-button>
@@ -156,8 +156,10 @@
           <el-row>
             <el-col :span="24">
               <el-tabs v-model="activeName" @tab-click="handleTabClick">
-                <el-tab-pane :label="'正常('+recSucTotal+')'" name="1"></el-tab-pane>
-                <el-tab-pane :label="'异常('+recErrTotal+')'" name="100"></el-tab-pane>
+                <el-tab-pane :label="'正确('+recSucTotal+')'" name="1"></el-tab-pane>
+                <el-tab-pane :label="'考号异常('+recKhErrTotal+')'" name="-1"></el-tab-pane>
+                <el-tab-pane :label="'客观题异常('+recObjErrTotal+')'" name="-2"></el-tab-pane>
+                <el-tab-pane :label="'待上传('+recWaitingErrTotal+')'" name="0"></el-tab-pane>
               </el-tabs>
             </el-col>
           </el-row>
@@ -184,13 +186,15 @@
                 <span style="font-size:12px;">{{scope.row.ctime}}</span>
               </template>
             </el-table-column>
-            <el-table-column align="center" prop="date" label="操作" fixed="right" width="120px">
+            <el-table-column align="center" prop="date" label="操作" fixed="right" width="160px">
               <template slot-scope="scope">
-                <el-button v-if="scope.row.mark_status!=0" @click="showCurRecImg(scope.row)" size="mini" type="text">查看
+                <!--<el-button v-if="scope.row.mark_status!=0" @click="showCurRecImg(scope.row)" size="mini" type="text">查看
                 </el-button>
                 <el-button v-if="scope.row.mark_status!=0" @click="showCurRecKhImg(scope.row)" size="mini" type="text">
-                  考号</el-button>
-                <el-button @click="delStudents(scope.row.student_id,scope.$index)" size="mini" type="text">删除
+                  考号</el-button>-->
+                <el-button @click="delStudents(scope.row.student_id,scope.$index,'delRec')" size="mini" type="text">删除识别结果
+                </el-button>
+                <el-button @click="delStudents(scope.row.student_id,scope.$index,'delStudent')" size="mini" type="text">删除学生
                 </el-button>
               </template>
             </el-table-column>
@@ -294,7 +298,9 @@
         recTotal: 0,
         recParams: {},
         recSucTotal: 0,
-        recErrTotal: 0,
+        recKhErrTotal: 0,
+        recObjErrTotal: 0,
+        recWaitingErrTotal:0,
         queryName: "",
         queryMarkStatus: null,
         selectException: [],
@@ -529,7 +535,9 @@
           })
           this.recTotal = res.data.data.total;
           this.recSucTotal = res.data.data.suc_total;
-          this.recErrTotal = res.data.data.err_total;
+          this.recKhErrTotal = res.data.data.kh_err_total;
+          this.recObjErrTotal = res.data.data.obj_err_cnt;
+          this.recWaitingErrTotal = res.data.data.waiting_cnt;
           this.loading = false;
         })
         window.clearInterval(this.timer);
@@ -548,7 +556,9 @@
             })
             that.recTotal = res.data.data.total;
             that.recSucTotal = res.data.data.suc_total;
-            that.recErrTotal = res.data.data.err_total;
+            that.recKhErrTotal = res.data.data.kh_err_total;
+            that.recObjErrTotal = res.data.data.obj_err_cnt;
+            that.recWaitingErrTotal = res.data.data.waiting_cnt;
           })
         }, 4000)
       },
@@ -596,9 +606,10 @@
           }
         }
       },
-      delStudents(id, index) {
+      delStudents(id, index,action) {
         this.$api.delMarkTaskStudents({
-          id: id
+          id: id,
+          action:action
         }).then(res => {
           this.msgSuccess("删除成功!");
           this.studentsList.splice(index, 1)
@@ -748,7 +759,9 @@
               })
               that.recTotal = res.data.data.total;
               that.recSucTotal = res.data.data.suc_total;
-              that.recErrTotal = res.data.data.err_total;
+              that.recKhErrTotal = res.data.data.kh_err_total;
+              that.recObjErrTotal = res.data.data.obj_err_cnt;
+              that.recWaitingErrTotal = res.data.data.waiting_cnt;
             })
           }, 4000)
         })