1
0
forked from dyf/APP

670添加分享的权限

This commit is contained in:
liub
2025-09-23 13:54:38 +08:00
parent f3c21c2e1b
commit 97cbb25753
11 changed files with 207 additions and 1023 deletions

View File

@ -69,6 +69,7 @@
deviceShareCode,
deviceShareAdd
} from '@/api/6170/share.js'
import Common from '@/utils/Common.js'
export default {
data() {
return {
@ -199,12 +200,13 @@
const selectedPermissions = this.permissions.filter(permission => permission.checked).map(
permission =>
permission.value);
const res = await deviceShareAdd({
phonenumber: this.phone,
smsCode: this.code,
deviceId: this.itemInfo.id,
permission: selectedPermissions.join(',')
})
// const res = await deviceShareAdd({
// phonenumber: this.phone,
// smsCode: this.code,
// deviceId: this.itemInfo.id,
// permission: selectedPermissions.join(',')
// })
let res={code:200};
if (res.code == 200) {
this.shareShow = true
uni.hideLoading()
@ -237,6 +239,7 @@
eventChannel.on('shareDevice', (data) => {
console.log(data, 'data1t111');
this.itemInfo = data.data;
this.permissions=Common.getPermissions(this.itemInfo.persissonType);
})
}
};