From 4ac3178b0487633de5cde93d74757dbf56ccd32d Mon Sep 17 00:00:00 2001 From: lld <15027638633@163.com> Date: Sun, 8 Mar 2026 21:44:34 +0800 Subject: [PATCH] bug --- pages/home/control/automatic.vue | 3 ++- pages/home/control/index.vue | 15 +++++++-------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/pages/home/control/automatic.vue b/pages/home/control/automatic.vue index 20e3ed7..545f18c 100644 --- a/pages/home/control/automatic.vue +++ b/pages/home/control/automatic.vue @@ -365,7 +365,7 @@ export default { handler(newVal) { // 确保数据有值后执行方法 if (newVal) { - this.rollerParam.ventTotalLen = newVal; + this.rollerParam.autoTotalLen = newVal; } } } @@ -662,6 +662,7 @@ export default { this.message = JSON.stringify({[`${type}1`]: status}) this.$emit(emitFunction, this.message); + this.$set(this.status, type, status); //todo // this.testAuto(type); diff --git a/pages/home/control/index.vue b/pages/home/control/index.vue index b86baf0..05e59ce 100644 --- a/pages/home/control/index.vue +++ b/pages/home/control/index.vue @@ -420,14 +420,13 @@ export default { // 3. 区分“回执”和“其他内容” if (tag==='ack' && msgData.prop && "suc" in msgData) { this.handleCommandAck(msgData); + } else if (tag==='listener' && "msg" in msgData && "clientId" in msgData) { + if (mqttUtil.getMqttState().clientId === msgData.clientId) { + this.$modal.msg( + `${msgData.msg}` + ); + } } - // else if (tag==='ack' && "msg" in msgData && "clientId" in msgData) { - // if (mqttUtil.getMqttState().clientId === msgData.clientId) { - // this.$modal.msg( - // `${msgData.msg}` - // ); - // } - // } else { this.handleOtherContent(msgData,tag) } @@ -471,7 +470,7 @@ export default { var arr = ['jbk', "jbg", "jm1k", "jm1g", "jm2k", "jm2g", "jm3k", "jm3g","jlk","jlg"] const allKeysNumeric = Object.keys(msgData).some(key => arr.includes(key)); if (allKeysNumeric) { - this.status = {...msgData} + // this.status = {...msgData} Object.keys(msgData).forEach(key => { const value = msgData[key]; this.show[key] = value === 0 ? '暂停' : '运行';