Skip to content

Commit

Permalink
fix(components): 修复topic 订阅不正常
Browse files Browse the repository at this point in the history
  • Loading branch information
h7ml committed Jun 21, 2022
1 parent 8b11081 commit 93ce252
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/views/DeviceCloud/manage/devicelist.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1083,7 +1083,7 @@
},
async subAllDevice() {
await this.$subscribe('$dg/user/devicestate/#')
this.$dgiotBus.$on('/$dg/user', (Msg) => {
this.$dgiotBus.$on('/$dg/user/devicestate', (Msg) => {
console.log('收到消息', Msg)
const parseString = JSON.parse(Msg.payloadString)
console.log('收到消息', parseString)
Expand Down
2 changes: 1 addition & 1 deletion src/views/DeviceCloud/manage/home_index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -1216,7 +1216,7 @@
},
async subAllDevice() {
await this.$subscribe('$dg/user/devicestate/#')
this.$dgiotBus.$on('/$dg/user', (Msg) => {
this.$dgiotBus.$on('/$dg/user/devicestate', (Msg) => {
console.log('收到消息', Msg)
const parseString = JSON.parse(Msg.payloadString)
console.log('收到消息', parseString)
Expand Down

0 comments on commit 93ce252

Please sign in to comment.