Your Name 1 year ago
parent
commit
b22c3e0672
3 changed files with 16 additions and 5 deletions
  1. 2 2
      public/index.html
  2. 3 0
      src/api.js
  3. 11 3
      src/views/papers/cutPaper.vue

+ 2 - 2
public/index.html

@@ -8,8 +8,8 @@
     <link rel="icon" href="<%= BASE_URL %>favicon.ico">
     <title>阅卷系统</title>
     <!-- <script src="https://api.map.baidu.com/api?v=1.0&type=webgl&ak=uscumpiG2CkippMbzaC7njksj7OuL7hj"></script> -->
-    <script src="https://printjs-4de6.kxcdn.com/print.min.js"></script>
-    <link rel="stylesheet" href="https://printjs-4de6.kxcdn.com/print.min.css">
+    <!-- <script src="https://printjs-4de6.kxcdn.com/print.min.js"></script>
+    <link rel="stylesheet" href="https://printjs-4de6.kxcdn.com/print.min.css"> -->
   </head>
 
 <body>

+ 3 - 0
src/api.js

@@ -155,6 +155,9 @@ export default {
     delPaperInfo: params => {
         return axios.delete(`${baseURL}/api/admin/papers`, { params: params })
     },
+    updatePaperInfo: params => {
+        return axios.put(`${baseURL}/api/admin/papers/update`, params)
+    },
     // 阅卷任务
     getMarkTaskList: params => {
         return axios.get(`${baseURL}/api/admin/marktask/list`, { params: params })

+ 11 - 3
src/views/papers/cutPaper.vue

@@ -151,7 +151,7 @@
         </el-row>
         <div slot="footer" class="dialog-footer">
             <el-button @click="open = false">取 消</el-button>
-            <el-button type="primary" @click="submitForm">保 存</el-button>
+            <el-button type="primary" @click="updatePaperRecInfo">保 存</el-button>
         </div>
     </el-dialog>
   </section>
@@ -207,7 +207,8 @@
         addQueForm:{},
         stdQueList:[
           // {qno:"",score:1,qtype:"单选",stdAns:""}
-        ]
+        ],
+        stdQnoPoints:[]
       };
     },
     methods: {
@@ -293,6 +294,12 @@
           }
         });
       },
+      updatePaperRecInfo(){
+        let params = {id:1,stdQnoPoints:this.stdQnoPoints}
+        this.$api.updatePaperInfo(params).then(res=>{
+
+        })
+      },
       remoteMethod(query) {
         if (query !== "") {
           // this.loading = true;
@@ -365,7 +372,8 @@
       tryRecPaper(){
         this.ansImgLoading = true;
         this.$api.tryRecPaper({img:this.curAnsImg,optionDir:this.optionDir,queDir:this.queDir}).then(res=>{
-          this.recCurAnsImg = res.data.data;
+          this.recCurAnsImg = res.data.data.recImg;
+          this.stdQnoPoints = res.data.data.ansCnts;
           this.ansImgLoading = false;
         })
       },