浏览代码

feat: 接口调试

zhangjie 11 月之前
父节点
当前提交
e00fe698d4

二进制
src/assets/images/icon-close-act.png


+ 3 - 6
src/components/base/RoomClassSelect.vue

@@ -11,8 +11,8 @@
     <el-option
     <el-option
       v-for="(item, index) in optionList"
       v-for="(item, index) in optionList"
       :key="index"
       :key="index"
-      :value="item.name"
-      :label="item.name"
+      :value="item"
+      :label="item"
     >
     >
     </el-option>
     </el-option>
   </el-select>
   </el-select>
@@ -75,10 +75,7 @@ export default {
     },
     },
     select() {
     select() {
       this.$emit("input", this.selected);
       this.$emit("input", this.selected);
-      this.$emit(
-        "change",
-        this.optionList.find((item) => item.name === this.selected)
-      );
+      this.$emit("change", this.selected);
     },
     },
   },
   },
 };
 };

+ 3 - 1
src/modules/client/components/ManualBindDialog.vue

@@ -276,7 +276,7 @@ export default {
     },
     },
     canSubmit() {
     canSubmit() {
       return (
       return (
-        this.releaseStudent &&
+        !this.releaseStudent ||
         this.releaseStudent.studentCode === this.modalForm.studentCode
         this.releaseStudent.studentCode === this.modalForm.studentCode
       );
       );
     },
     },
@@ -295,6 +295,8 @@ export default {
         this.releaseStudent = null;
         this.releaseStudent = null;
       }
       }
 
 
+      if (!this.modalForm.studentName) this.modalForm.id = null;
+
       this.modalForm.semesterId = this.task.semesterId;
       this.modalForm.semesterId = this.task.semesterId;
       this.modalForm.examId = this.task.examId;
       this.modalForm.examId = this.task.examId;
       this.modalForm.courseCode = this.task.courseCode;
       this.modalForm.courseCode = this.task.courseCode;

+ 1 - 1
src/plugins/imageUpload.js

@@ -35,7 +35,7 @@ export async function toUploadImg(options) {
       });
       });
     }
     }
   } else {
   } else {
-    formData.append("fileType", options.fileTypeId);
+    formData.append("fileTypeId", options.fileTypeId);
     formData.append("classRoomName", options.roomOrClass);
     formData.append("classRoomName", options.roomOrClass);
   }
   }