Commit 25e44be7 by 前端

bug修复

1 parent 08c91b69
......@@ -241,7 +241,9 @@
"
style="margin-left: 8px"
v-model="itm.repeatFlag"
@change="repeatChange(itm, itm.repeatFlag)"
@change="
repeatChange(index, itm, itm.repeatFlag, index1)
"
>不限制</el-checkbox
>
</el-form-item>
......@@ -732,6 +734,7 @@ export default {
// task -- 具体哪个任务
// taskIndex -- 具体任务索引
this.taskList[dateTaskIndex].missionList.splice(taskIndex, 1)
this.$refs['taskForm'][dateTaskIndex].clearValidate()
},
handleBlur(dateTask) {
if (dateTask.repeatCount) {
......@@ -739,11 +742,17 @@ export default {
}
},
// 重复次数选择框改变
repeatChange(dateTask, type) {
repeatChange(listindex, dateTask, type, taskIndex) {
// dateTask.repeatFlag = !dateTask.repeatFlag
// this.$nextTick(() => {
if (type) {
dateTask.repeatCount = -1
// dateTask.repeatCount = -1
// 去除校验
this.$refs['taskForm'][listindex].fields.map((i) => {
if (i.prop === 'missionList.' + taskIndex + '.repeatCount') {
i.clearValidate()
}
})
} else {
// this.$nextTick(() => {
// dateTask.repeatCount = ''
......@@ -905,6 +914,15 @@ export default {
},
// 提交任务
submitTask() {
// 遍历重复次数
this.taskList.map((item) => {
item.missionList.map((itm) => {
// itm.repeatCount = itm.repeatCount ? itm.repeatCount : -1
if (itm.repeatCount || itm.repeatFlag) {
itm.repeatCount = itm.repeatCount ? itm.repeatCount : -1
}
})
})
try {
this.basicFormValidate()
} catch (err) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!