diff --git a/src/views/projectcenter/TaskAdd.vue b/src/views/projectcenter/TaskAdd.vue
index 63ac1f9b..001d836e 100644
--- a/src/views/projectcenter/TaskAdd.vue
+++ b/src/views/projectcenter/TaskAdd.vue
@@ -442,6 +442,7 @@ function changeStageIndex(index) {
const getTask = async () => {
await api.getDraftTask({projectId: route.query.projectId}).then((res) => {
projectInfo.value = res.data.data
+ console.log("获取任务列表:" + JSON.stringify(projectInfo.value) )
});
};
diff --git a/src/views/projectcenter/temTask.vue b/src/views/projectcenter/temTask.vue
index 4cf30df3..9cfd488f 100644
--- a/src/views/projectcenter/temTask.vue
+++ b/src/views/projectcenter/temTask.vue
@@ -281,7 +281,7 @@
@@ -541,7 +541,16 @@ const cancelModal = ref(false);
const deleteStageModal = ref(false);
const templateLoading = ref(false);
const cancleLoading = ref(false);
-const projectInfo = ref({stageList: [{taskTemplateList: [{}]}], projectTemplateInfo: {}});
+const projectInfo = ref({
+ stageList: [{
+ "id":"0",
+ taskTemplateList: [{
+ }]
+ }],
+ projectTemplateInfo: {
+
+ }
+});
const activeIndex = ref(0);
const moveChapterIndex = ref(0);
const deleteIndex = ref(0);
@@ -576,6 +585,13 @@ function changeStageIndex(index) {
const getTask = async () => {
await api.templateEditDetail(route.query.projectId).then((res) => {
projectInfo.value = res.data.data
+ if(projectInfo.value.stageList.length == 0){
+ projectInfo.value.stageList = [{
+ "id":"0",
+ taskTemplateList: []
+ }]
+ }
+ console.log("获取任务列表信息:" + JSON.stringify(projectInfo.value));
});
};
@@ -721,7 +737,7 @@ const closeDeAll = () => {
const submitStorage = async () => {
templateLoading.value = true
await request(PROJECT_TEMPLATE_DETAIL_MODIFY, projectInfo.value)
- await getTask()
+ // await getTask()
message.success("保存成功");
templateLoading.value = false
};