From 441700673a26144cfcf93b87e0bdcdb06958dabe Mon Sep 17 00:00:00 2001 From: riku <risaku@163.com> Date: 星期一, 25 十一月 2024 16:06:23 +0800 Subject: [PATCH] 1. 修复问题新增对话框中,无法正确上传图片的问题 2. 工地施工阶段可选项更新 --- src/views/fysp/check/ProCheck.vue | 60 +++++++++++++----------------------------------------------- 1 files changed, 13 insertions(+), 47 deletions(-) diff --git a/src/views/fysp/check/ProCheck.vue b/src/views/fysp/check/ProCheck.vue index 9cda78a..411065c 100644 --- a/src/views/fysp/check/ProCheck.vue +++ b/src/views/fysp/check/ProCheck.vue @@ -239,7 +239,7 @@ taskApi.getSubtaskSummary(param).then((res) => { const list = []; res.forEach((s) => { - const t = this.getSubtaskType(s); + const t = ProCheckProxy.getSubtaskType(s); list.push({ status: s.subtask.status, type: t, @@ -254,39 +254,6 @@ this.mainLoading = false; } }); - }, - //鑾峰彇浠诲姟闂鐨勫鏍告儏鍐� - getSubtaskType(s) { - let type = 0; - // 鏃犻棶棰� - if (s.proNum == 0) { - type = 0; - } - // 闂鏈鏍� - else if (s.proCheckedNum == 0) { - type = 1; - } - // 闂閮ㄥ垎瀹℃牳 - else if (s.proCheckedNum < s.proNum) { - type = 2; - } - // 鏈暣鏀� - else if (s.changeNum < s.proNum) { - type = 3; - } - // 鏁存敼鏈鏍� - else if (s.changeCheckedNum == 0) { - type = 4; - } - // 鏁存敼閮ㄥ垎瀹℃牳 - else if (s.changeCheckedNum < s.changeNum) { - type = 5; - } - // 瀹屽叏瀹℃牳 - else { - type = 6; - } - return type; }, //鐐瑰嚮宸︿晶鑿滃崟浠诲姟浜嬩欢 chooseSubtask(s) { @@ -304,12 +271,11 @@ this.mainLoading = false; }); }, - onAddProCanceled() { - }, + onAddProCanceled() {}, // 闂鍗$墖缁勪欢涓诲姩鍙戣捣鍒锋柊鐖剁粍浠舵暟鎹� updateSubtask(refresh = false) { this.curSubtask.data.proCheckedNum++; - this.curSubtask.type = this.getSubtaskType(this.curSubtask.data); + this.curSubtask.type = ProCheckProxy.getSubtaskType(this.curSubtask.data); if (this.proAddOrUpdDialogVisible) { this.proAddOrUpdDialogVisible = false; } @@ -318,8 +284,8 @@ // 鍒锋柊褰撳墠閫変腑瀛愪换鍔� refreshCurrSubtask(refresh) { this.sideLoading = false; - // this.mainLoading = true; setTimeout(() => { + this.mainLoading = true; taskApi .getProBySubtask(this.curSubtask.data.stGuid) .then((res) => { @@ -340,18 +306,18 @@ // this.curSubtask = s; }) .finally(() => { - // this.mainLoading = false; + this.mainLoading = false; }); - }, 150); + }, 500); }, // 闂瀹℃牳瀹屾垚鍚庯紝鏇存柊宸︿晶鍒楄〃瀵瑰簲瀛愪换鍔$姸鎬� - handleProblemCheck(){ - const status = ProCheckProxy.calProStatus(this.curProList) - this.curSubtask.data.proNum = status.proNum - this.curSubtask.data.proCheckedNum = status.proCheckedNum - this.curSubtask.data.changeNum = status.changeNum - this.curSubtask.data.changeCheckedNum = status.changeCheckedNum - this.curSubtask.type = this.getSubtaskType(this.curSubtask.data) + handleProblemCheck() { + const status = ProCheckProxy.calProStatus(this.curProList); + this.curSubtask.data.proNum = status.proNum; + this.curSubtask.data.proCheckedNum = status.proCheckedNum; + this.curSubtask.data.changeNum = status.changeNum; + this.curSubtask.data.changeCheckedNum = status.changeCheckedNum; + this.curSubtask.type = ProCheckProxy.getSubtaskType(this.curSubtask.data); } }, mounted() {} -- Gitblit v1.9.3