Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 020e131df0 |
@@ -151,17 +151,19 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
// 外部调用:启动开门流程
|
||||
async open() {
|
||||
async open(userId) {
|
||||
if (this.step) return;
|
||||
|
||||
this.cancelled = false;
|
||||
this.step = 'opening';
|
||||
|
||||
const uid = userId || this.userId;
|
||||
|
||||
try {
|
||||
const res = await post('/device-scan/open', {
|
||||
device_id: this.deviceId,
|
||||
door_index: 0,
|
||||
user_id: this.userId
|
||||
user_id: uid
|
||||
});
|
||||
|
||||
const ret = res.data || {};
|
||||
|
||||
@@ -441,7 +441,7 @@ export default {
|
||||
}
|
||||
|
||||
// 调用组件方法启动开门流程
|
||||
this.$refs.doorPanel.open();
|
||||
this.$refs.doorPanel.open(this.userId);
|
||||
},
|
||||
handleMenuClick(item) {
|
||||
switch (item.action) {
|
||||
|
||||
Reference in New Issue
Block a user