From ba616e9307681da4781b7610ec3c27721d793379 Mon Sep 17 00:00:00 2001
From: guifei zhu <guifeizhu@guifeideiMac.local>
Date: 星期三, 18 九月 2024 12:13:37 +0800
Subject: [PATCH] 添加mqtt通讯
---
pages/me/control.vue | 102 ++++++++++++++++++++++++++++++++++++++-------------
1 files changed, 76 insertions(+), 26 deletions(-)
diff --git a/pages/me/control.vue b/pages/me/control.vue
index 3e0a559..4abf342 100644
--- a/pages/me/control.vue
+++ b/pages/me/control.vue
@@ -40,11 +40,18 @@
return {
sendMsg: '',
recviceMsg: '',
- baseList: [{
+ baseList: [
+ /* {
+ id: 1010,
+ img: '',
+ title: '缁翠慨妯″紡',
+ name: 'warning'
+ }, */
+ {
id: 1010,
img: '',
- title: '缁翠慨妯″紡',
- name: 'warning'
+ title: '骞茬嚗鍚姩',
+ name: 'play-circle'
},
{
id: 0,
@@ -59,18 +66,12 @@
title: '鍋滄杩愯',
name: 'pause-circle'
},
- {
- id: 1001,
- img: '',
- title: '椋庣鍗�',
- name: 'arrow-up'
- },
- {
- id: 1003,
- img: '',
- title: '婊氱瓛鍗�',
- name: 'arrow-upward'
- },
+ // {
+ // id: 1001,
+ // img: '',
+ // title: '椋庣鍗�',
+ // name: 'arrow-up'
+ // },
{
id: 1005,
img: '',
@@ -78,25 +79,74 @@
name: 'checkmark-circle'
},
{
- id: 1002,
+ id: 1003,
img: '',
- title: '椋庣闄�',
- name: 'arrow-down'
+ title: '婊氱瓛鍗�',
+ name: 'arrow-upward'
+ },
+ {
+ id: 1011,
+ img: '',
+ title: '鍓嶉棬寮�鍏�',
+ name: 'plus-circle'
},
-
+
+ // {
+ // id: 1002,
+ // img: '',
+ // title: '椋庣闄�',
+ // name: 'arrow-down'
+ // },
+ {
+ id: 1006,
+ img: '',
+ title: '婊氱瓛鍙嶈浆',
+ name: 'close-circle'
+ },
+
{
id: 1004,
img: '',
title: '婊氱瓛闄�',
name: 'arrow-downward'
+ },
+ {
+ id: 1012,
+ img: '',
+ title: '鍚庨棬寮�鍏�',
+ name: 'minus-circle'
+ },
+ {
+ id: 1013,
+ img: '',
+ title: '鐑鍚姩',
+ name: 'coupon'
},
-
+
{
- id: 1006,
+ id: 1014,
img: '',
- title: '婊氱瓛鍙嶈浆',
- name: 'close-circle'
- },
+ title: '寮�闂ㄨ瀵�',
+ name: 'eye'
+ },
+ {
+ id: 1015,
+ img: '',
+ title: '鍑烘枡',
+ name: 'shopping-cart'
+ },{
+ id: 1016,
+ img: '',
+ title: '娓呴櫎',
+ name: 'trash'
+ },{
+ id: 1017,
+ img: '',
+ title: '鎵嬪姩/鑷姩',
+ name: 'fingerprint'
+ }
+
+
]
}
},
@@ -147,7 +197,7 @@
parmas.tenantId = 1003
parmas.machineId = 'GM001'
- this.sendMsg = '鍙戦�侊細' + this.formatData() + JSON.stringify(parmas)
+ this.sendMsg = '鍙戦�侊細' + this.formatData() + JSON.stringify(parmas)
this.recviceMsg = ''
console.info(parmas)
this.$api.sendCommand(parmas).then((res) => {
@@ -159,7 +209,7 @@
}
}).finally(() => {
-
+
})
},
formatData() {
--
Gitblit v1.9.3