WANG 6 lat temu
rodzic
commit
18078d54fd

+ 25 - 3
src/modules/examwork/view/offlineExamOrgSettings.vue

@@ -72,7 +72,7 @@
                 <el-button
                   size="mini"
                   type="info"
-                  @click="editExamOrg(scope.row)"
+                  @click="updateExamOrg(scope.row)"
                 >
                   修改
                 </el-button>
@@ -113,7 +113,20 @@ export default {
       tableData: [],
       currentPage: 1,
       pageSize: 10,
-      total: 0
+      total: 0,
+
+      orgSetting: {
+        examId: null,
+        orgId: null,
+        beginTime: null,
+        endTime: null,
+        properties: {
+          CAN_UPLOAD_ATTACHMENT: "true"
+        }
+      },
+      addOrgSettingDialog: false,
+      updateOrgSettingDialog: false,
+      orgList4InsertOrUpdate: []
     };
   },
   methods: {
@@ -158,7 +171,16 @@ export default {
       this.currentPage = val;
       this.search();
     },
-    editExamOrg() {},
+    updateExamOrg(row) {
+      this.orgSetting.examId = row.examId;
+      this.orgSetting.beginTime = row.beginTime;
+      this.orgList4InsertOrUpdate = [{ id: row.orgId, name: row.orgName }];
+      this.orgSetting.orgId = row.orgId;
+      this.orgSetting.endTime = row.endTime;
+      this.orgSetting.properties.CAN_UPLOAD_ATTACHMENT =
+        row.properties.CAN_UPLOAD_ATTACHMENT;
+      this.updateOrgSettingDialog = true;
+    },
     search() {
       let param = new URLSearchParams(this.formSearch);
       let url =