From 4bee3bc3e54dc73ea70151b686c81d1f83e06f09 Mon Sep 17 00:00:00 2001 From: haoxuan <haoxuan> Date: 星期一, 09 十月 2023 14:53:40 +0800 Subject: [PATCH] 工艺参数更新标识bug+工艺模型列表和详情更新后数据没有更新需get接口更新之后获取number请求 --- src/components/TaskControlModal.vue | 26 +++++++++++++++++++------- 1 files changed, 19 insertions(+), 7 deletions(-) diff --git a/src/components/TaskControlModal.vue b/src/components/TaskControlModal.vue index 3e7a3bd..c5ce308 100644 --- a/src/components/TaskControlModal.vue +++ b/src/components/TaskControlModal.vue @@ -160,9 +160,9 @@ </template> </div> <!--宸︾炕椤垫寜閽�--> - <div v-show="showPreviousTaskBtn" class="paginator-btn previous" @click="previousTask"><</div> + <div v-show="showPreviousTaskBtn" class="paginator-btn previous" :class="{disabled:showBtn ===2 ||messageError}" @click="previousTask"><</div> <!--鍙崇炕椤垫寜閽�--> - <div v-show="showNextTaskBtn" class="paginator-btn next" @click="nextTask">></div> + <div v-show="showNextTaskBtn" class="paginator-btn next" :class="{disabled:showBtn ===2 ||messageError}" @click="nextTask">></div> </div> <div slot="footer" :class="messageError?'dialog-footer tac btn-error':'dialog-footer tac'" style="overflow: hidden"> @@ -212,6 +212,7 @@ <script> import {getTaskInfo, sendProcessParams, startTask,} from "@/api/home"; // 浜х嚎 +import {channelNameConfig} from "@/common/constants"; export default { name: 'TaskControlModal', components: {}, @@ -243,11 +244,7 @@ isLoading: false, second: 0, secondTimer: null, - // 閫氶亾鍚嶇О閰嶇疆 Channel 0 瀵瑰簲灞曠ず 0, Channel 1 瀵瑰簲灞曠ず A,鏆傛椂蹇界暐鍏朵綑鎯呭喌 - channelNameConfig: { - 0: '0', - 1: 'A' - } + channelNameConfig: channelNameConfig }; }, mounted() { @@ -387,6 +384,10 @@ * 鍓嶇炕椤� */ previousTask() { + // 鐢熶骇鍑嗗鍊掕鏃朵腑鍜屼笅鍙戝け璐ョ姝㈢炕椤� + if (this.showBtn === 2 || this.messageError){ + return + } if (this.currentTaskIndex - 1 >= 0) { this.currentTaskIndex -= 1 this.$nextTick(() => { @@ -401,6 +402,10 @@ * 鍚庣炕椤� */ nextTask() { + // 鐢熶骇鍑嗗鍊掕鏃朵腑鍜屼笅鍙戝け璐ョ姝㈢炕椤� + if (this.showBtn === 2 || this.messageError){ + return + } if (this.currentTaskIndex + 1 <= this.taskList.length - 1) { this.currentTaskIndex += 1 this.$nextTick(() => { @@ -917,6 +922,12 @@ &.next { right: -60px; padding-left: 4px; + + } + &.disabled{ + background-color: #cccccc; + opacity: 0.8; + cursor: not-allowed; } } @@ -937,6 +948,7 @@ color: #ffffffaa; font-size: 16px; } + } .process-err-tip{ box-sizing: border-box; -- Gitblit v1.8.0