mirror of
https://gitee.com/beecue/fastbee.git
synced 2025-12-17 16:36:03 +08:00
日志添加租户和用户信息
This commit is contained in:
@@ -38,7 +38,7 @@ export default {
|
||||
methods: {
|
||||
/** 连接Mqtt */
|
||||
connectMqtt(subscribeTopics) {
|
||||
let randomClientId='web-' + Math.random().toString(16).substr(2);
|
||||
let randomClientId = 'web-' + Math.random().toString(16).substr(2);
|
||||
let options = {
|
||||
username: "wumei-smart",
|
||||
password: getToken(),
|
||||
@@ -53,7 +53,7 @@ export default {
|
||||
console.log("mqtt地址:", url);
|
||||
this.client = mqtt.connect(url, options);
|
||||
this.client.on("connect", (e) => {
|
||||
console.log("客户端:"+randomClientId+",成功连接服务器:", e);
|
||||
console.log("客户端:" + randomClientId + ",成功连接服务器:", e);
|
||||
// 订阅主题
|
||||
if (subscribeTopics != '' && subscribeTopics.length > 0) {
|
||||
this.client.subscribe(subscribeTopics, {
|
||||
@@ -89,7 +89,11 @@ export default {
|
||||
if (!err) {
|
||||
console.log('成功发布主题:' + topic)
|
||||
console.log('主题内容:' + message);
|
||||
this.$modal.notifySuccess("[ " + name + " ] 指令发送成功");
|
||||
if (topic.indexOf('offline') > 0) {
|
||||
this.$modal.notify("[ " + name + " ] 影子指令发送成功");
|
||||
} else {
|
||||
this.$modal.notifySuccess("[ " + name + " ] 指令发送成功");
|
||||
}
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
@@ -41,17 +41,17 @@
|
||||
<table>
|
||||
<tr>
|
||||
<td rowspan="3" style="width:60px;font-weight:bold;color:#fff;line-height:28px;background-color:#F56C6C;text-align:center;font-size:18px;">演 示<br />账 号</td>
|
||||
<td style="padding:10px 20px 0 10px;">管理员</td>
|
||||
<td style="padding:10px 15px 0 10px;">受限管理</td>
|
||||
<td style="padding:10px 30px 0 0;">wumei</td>
|
||||
<td style="padding-top:10px;">123456</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding:0 20px 0 10px;">租户账号</td>
|
||||
<td style="padding:0 15px 0 10px;">租户账号</td>
|
||||
<td>wumei-t1</td>
|
||||
<td>123456</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="padding:0 20px 10px 10px;">普通用户</td>
|
||||
<td style="padding:0 15px 10px 10px;">普通用户</td>
|
||||
<td style="padding-bottom:10px;">wumei-u1</td>
|
||||
<td style="padding-bottom:10px;">123456</td>
|
||||
</tr>
|
||||
|
||||
Reference in New Issue
Block a user