Browse Source

一键修复回调逻辑调整

pull/123/head
liwei 3 years ago
parent
commit
d13e1e0206
1 changed files with 40 additions and 7 deletions
  1. +40
    -7
      src/views/productplan/workbench/schedule.vue

+ 40
- 7
src/views/productplan/workbench/schedule.vue View File

@ -933,17 +933,50 @@
postRepairschedule({
TaskId: this.allData.TaskId
}).then(({
code
code,
data: {
WorklineDict,
UnPlannedTaskArray,
TaskId,
PlannedTaskArray,
LockedTaskArray
}
}) => {
this.fullscreenLoading = false;
if (code === 200) {
this.$message({
showClose: true,
duration: 1000,
message: '一键修复成功',
type: 'success'
this.allData = {
UnPlannedTaskArray,
TaskId,
PlannedTaskArray,
LockedTaskArray,
ManualPlannedTask: {},
Operation: "",
}
this.wiewPlanList([]);
gantt.clearAll();
// gantt.templates.timeline_cell_class
const data = [{
_is_bg: true,
id: 10001,
start_date: `${moment(this.startAndEdnDate[0]).format('YYYY-MM-DD')} 00:00:00`,
end_date: `${moment(this.startAndEdnDate[1]).format('YYYY-MM-DD')} 23:59:59`,
// duration: 1,
text: this.parms['WorkLine-Descr'],
progress: 0,
sortorder: 1,
parent: 0,
open: true,
unavailableRanges: this.disabledDate
}]
gantt.parse({
start_date: `${moment(this.startAndEdnDate[0]).format('YYYY-MM-DD')} 00:00:00`,
end_date: `${moment(this.startAndEdnDate[1]).format('YYYY-MM-DD')} 23:59:59`,
data: data
})
this.search();
data.forEach((item) => {
gantt.getAnothersStore().addItem(item)
})
this.setTaskGantt(WorklineDict);
}
})
},


Loading…
Cancel
Save