zhangjie 1 年之前
父节点
当前提交
ef76e978f5

+ 2 - 2
src/constants/app.js

@@ -18,8 +18,8 @@ export function getOrgCode() {
   domain = window.localStorage.getItem("domain_in_url");
   if (domain) return domain;
 
-  const hostname = window.location.hostname;
-  domain = hostname.split(".")[0];
+  // const hostname = window.location.hostname;
+  // domain = hostname.split(".")[0];
   return domain;
 }
 

+ 1 - 0
src/modules/login/views/Login.vue

@@ -226,6 +226,7 @@ export default {
       this.$parent.version = data.version || "";
       this.schoolLogo = data.logo;
       this.schoolInfo = data;
+      this.loginModel.schoolCode = data.schoolCode;
       this.$ls.set("schoolInfo", data);
     },
     switchLoginType() {

+ 3 - 3
src/modules/mark/components/ScoreCheckDetail.vue

@@ -419,15 +419,15 @@ export default {
       this.getList();
     },
     // img view
+    async toViewTrack(row) {
+      this.toMarkTrack(row.studentId);
+    },
     toViewSheetPaper(row) {
       this.curImageIndex = 0;
       this.imageList = row.sheetUrls || [];
       this.selectImage(this.curImageIndex);
       this.$refs.SimpleImagePreview.open();
     },
-    async toViewTrack(row) {
-      this.toMarkTrack(row.studentId);
-    },
     selectImage(index) {
       this.curImage = this.imageList[index];
     },

+ 6 - 1
src/modules/mark/components/markDetail/MarkDetailArbitration.vue

@@ -21,6 +21,7 @@
             v-model="filter.type"
             type="MARK_ARBITRATE_STATUS"
             placeholder="状态"
+            :clearable="false"
           >
           </status-select>
         </el-form-item>
@@ -39,7 +40,7 @@
       <div class="part-box-action">
         <el-button
           type="primary"
-          :disabled="!multipleSelection.length"
+          :disabled="batchDoneDisabled"
           @click="toBatchDone(multipleSelection)"
         >
           批量处理
@@ -159,6 +160,10 @@ export default {
     selectGroupNumber() {
       return this.multipleSelection[0]?.groupNumber;
     },
+    batchDoneDisabled() {
+      if (!this.multipleSelection.length) return true;
+      return this.multipleSelection.some((item) => item.status === "MARKED");
+    },
   },
   mounted() {
     this.filter.className = this.$ls.get("preset-className", undefined);

+ 52 - 4
src/modules/mark/components/markDetail/MarkDetailIssue.vue

@@ -27,8 +27,8 @@
         </el-form-item>
         <el-form-item label="状态">
           <el-select v-model="filter.status" placeholder="状态" clearable>
-            <el-option value="BACK" label="已处理"></el-option>
-            <el-option value="WAITING" label="未处理"></el-option>
+            <el-option value="BACK" label="已打回"></el-option>
+            <el-option value="WAITING" label="未打回"></el-option>
           </el-select>
         </el-form-item>
         <el-form-item label="密号">
@@ -49,7 +49,7 @@
           :disabled="!multipleSelection.length"
           @click="toBatchReset"
         >
-          批量处理
+          批量打回
         </el-button>
       </div>
     </div>
@@ -124,7 +124,13 @@
               :disabled="scope.row.status === 'BACK'"
               type="text"
               @click="toSimpleReset(scope.row)"
-              >处理</el-button
+              >打回</el-button
+            >
+            <el-button
+              class="btn-primary"
+              type="text"
+              @click="toViewSheetPaper(scope.row)"
+              >原图</el-button
             >
           </template>
         </el-table-column>
@@ -143,6 +149,14 @@
         </el-pagination>
       </div>
     </div>
+
+    <!-- image-preview -->
+    <simple-image-preview
+      :cur-image="curImage"
+      @on-prev="toPrevImage"
+      @on-next="toNextImage"
+      ref="SimpleImagePreview"
+    ></simple-image-preview>
   </div>
 </template>
 
@@ -152,9 +166,11 @@ import {
   markIssueReset,
   markGroupQuestions,
 } from "../../api";
+import SimpleImagePreview from "@/components/SimpleImagePreview";
 
 export default {
   name: "mark-detail-issue",
+  components: { SimpleImagePreview },
   props: {
     baseInfo: {
       type: Object,
@@ -178,6 +194,10 @@ export default {
       questions: [],
       multipleSelection: [],
       chartData: {},
+      // img view
+      curImage: {},
+      curImageIndex: 0,
+      imageList: [],
     };
   },
   mounted() {
@@ -245,6 +265,34 @@ export default {
       this.$message.success("操作成功!");
       this.getList();
     },
+    // img view
+    toViewSheetPaper(row) {
+      this.curImageIndex = 0;
+      this.imageList = row.sheetUrls || [];
+      this.selectImage(this.curImageIndex);
+      this.$refs.SimpleImagePreview.open();
+    },
+    selectImage(index) {
+      this.curImage = this.imageList[index];
+    },
+    toPrevImage() {
+      if (this.curImageIndex === 0) {
+        this.curImageIndex = this.imageList.length - 1;
+      } else {
+        this.curImageIndex--;
+      }
+
+      this.selectImage(this.curImageIndex);
+    },
+    toNextImage() {
+      if (this.curImageIndex === this.imageList.length - 1) {
+        this.curImageIndex = 0;
+      } else {
+        this.curImageIndex++;
+      }
+
+      this.selectImage(this.curImageIndex);
+    },
   },
 };
 </script>