|
@@ -1866,7 +1866,7 @@
|
|
|
let userdeviceId = mqttInfo.connectInfo.clientID;
|
|
|
let ClassrommNum = localStorage.getItem('classNum')
|
|
|
//let sendMsg = 'devices/' + userdeviceId + '/messages/events/endpoint=coretopiciot&groupNum=' + ClassrommNum + '&deviceId=' + userdeviceId
|
|
|
- let sendMsg = directMethod + '$iothub/methods/POST/directMethod/' + userdeviceId
|
|
|
+ let sendMsginfo = directMethod + '$iothub/methods/POST/directMethod/' + userdeviceId
|
|
|
const timestamp = Math.floor(Date.now() / 1000)
|
|
|
if (e === 'BackSeatnum') {
|
|
|
var msgconfig = {
|
|
@@ -1884,7 +1884,7 @@
|
|
|
console.log('发送内容:' + payload)
|
|
|
console.log('发送主题:' + pubTopic)
|
|
|
let client = this.client
|
|
|
- client.publish(sendMsg, payload, { qos: 0 }, (error) => {
|
|
|
+ client.publish(sendMsginfo, payload, { qos: 0 }, (error) => {
|
|
|
if (!error) {
|
|
|
console.log('发布成功')
|
|
|
} else {
|