From ebcfa9b040eccba4d0c32a9c65866544edfef4e7 Mon Sep 17 00:00:00 2001 From: songshankun <songshankun@foxmail.com> Date: 星期一, 23 十月 2023 16:27:18 +0800 Subject: [PATCH] feat: 通道没有任务时不展示工序状态 --- src/components/TaskControlModal.vue | 21 ++++++++++++--------- 1 files changed, 12 insertions(+), 9 deletions(-) diff --git a/src/components/TaskControlModal.vue b/src/components/TaskControlModal.vue index 2134a65..537dcee 100644 --- a/src/components/TaskControlModal.vue +++ b/src/components/TaskControlModal.vue @@ -136,8 +136,12 @@ </div> </template> <div class="gif-right"> - ----- 鍓╀綑鏃堕棿 ----- - <span>00:00:{{ 30 - Number(num) < 10 ? 0 : '' }}{{ 30 - Number(num) }}</span> + <div> + ----- 鍓╀綑鏃堕棿 ----- + </div> + <div> + <span>00:00:{{ 30 - Number(num) < 10 ? 0 : '' }}{{ 30 - Number(num) }}</span> + </div> </div> </div> {{ message }} @@ -212,6 +216,7 @@ <script> import {getTaskInfo, sendProcessParams, startTask,} from "@/api/home"; // 浜х嚎 +import {channelNameConfig} from "@/common/constants"; export default { name: 'TaskControlModal', components: {}, @@ -243,11 +248,7 @@ isLoading: false, second: 0, secondTimer: null, - // 閫氶亾鍚嶇О閰嶇疆 Channel 0 瀵瑰簲灞曠ず 0, Channel 1 瀵瑰簲灞曠ず A,鏆傛椂蹇界暐鍏朵綑鎯呭喌 - channelNameConfig: { - 0: '0', - 1: 'A' - } + channelNameConfig: channelNameConfig }; }, mounted() { @@ -366,6 +367,8 @@ getCurrentTaskProduceParams(id) { // const id = this.currentTaskData?.Procedure?.ID if (id) { + this.currentProcessParams = [] + this.getProcessParamsErrMsg = "" startTask({id}).then((res) => { if (res.code === 200) { this.currentProcessParams = res.data.Params ?? [] @@ -424,9 +427,9 @@ if (this.currentTaskData?.Procedure?.ID && this.currentTaskData?.Procedure?.Status === 1) { this.num = 0; this.showBtn = 1; - this.show = true; + // this.show = true; } else { - this.show = false; + // this.show = false; } }, getDateObj(date, fmt) { -- Gitblit v1.8.0