From efefbc15efe54bbd4da12bf8aff49432f5b752b8 Mon Sep 17 00:00:00 2001
From: xiangpei <xiangpei@timesnew.cn>
Date: 星期四, 28 十一月 2024 11:59:13 +0800
Subject: [PATCH] 默认值
---
src/views/exam/paper/edit.vue | 17 ++++++++++++++---
1 files changed, 14 insertions(+), 3 deletions(-)
diff --git a/src/views/exam/paper/edit.vue b/src/views/exam/paper/edit.vue
index 9936316..09df0c0 100644
--- a/src/views/exam/paper/edit.vue
+++ b/src/views/exam/paper/edit.vue
@@ -155,6 +155,7 @@
</el-select> -->
<el-cascader
clearable
+ collapse-tags
v-model="student.deptIds"
:options="depts"
:props="{ emitPath: false, multiple: true, value: 'id', label: 'name', checkStrictly: true }"
@@ -222,6 +223,7 @@
},
subjectIdList: [],
form: {
+ deptId: '',
menuIds: [],
aggregateSource: 100,
id: null,
@@ -232,7 +234,10 @@
limitDateTime: [],
name: '',
suggestTime: null,
- titleItems: [],
+ titleItems: [{
+ name: '',
+ questionItems: []
+ }],
subjectSource: {},
questionTypeVMS: [],
examineeList: [],
@@ -278,12 +283,18 @@
};
},
created() {
+ // departmentApi.getCurrentDeptId().then(res => {
+ // if (res.response && res.response[0]) {
+ // this.form.deptId = res.response[0];
+ // }
+ // });
let id = this.$route.query.id;
let _this = this;
this.initSubject(function () {
_this.subjectFilter = _this.subjects;
});
if (id && parseInt(id) !== 0) {
+ _this.selectAllBoolean = false;
_this.formLoading = true;
examPaperApi.select(id).then(re => {
const { userIds, userNames } = re.response;
@@ -327,20 +338,20 @@
this.getStudent();
},
selectAll () {
- this.selectAllBoolean = false;
let param = { ...this.student };
param.pageSize = 999999;
examPaperApi.selectStudent(param).then(res => {
this.handleSelection(res.response.list);
res.response.list.forEach(item => {
this.$refs.multipleTable.toggleRowSelection(item, true);
+ this.selectAllBoolean = false;
})
this.getStudent();
});
},
unselectAll () {
- this.selectAllBoolean = true;
this.$refs.multipleTable.clearSelection();
+ this.selectAllBoolean = true;
},
getStudent() {
this.student.listLoading = true;
--
Gitblit v1.8.0