|
|
@ -101,7 +101,9 @@ |
|
|
|
onLoad(options) { |
|
|
|
onLoad(options) { |
|
|
|
if (options.item) { |
|
|
|
if (options.item) { |
|
|
|
this.postData = JSON.parse(decodeURI(options.item)) |
|
|
|
this.postData = JSON.parse(decodeURI(options.item)) |
|
|
|
if (!this.postData.sysRoleList) this.postData.sysRoleList = [] |
|
|
|
if (!this.postData.sysRoleList) { |
|
|
|
|
|
|
|
this.$set(this.postData,'sysRoleList',[]) |
|
|
|
|
|
|
|
} |
|
|
|
} else this.isAdd = this.wantUpdate = true |
|
|
|
} else this.isAdd = this.wantUpdate = true |
|
|
|
|
|
|
|
|
|
|
|
uni.$on('yunSiteServiceStation', (item) => { |
|
|
|
uni.$on('yunSiteServiceStation', (item) => { |
|
|
@ -119,6 +121,7 @@ |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
uni.$on('yunSiteAuth', (item) => { |
|
|
|
uni.$on('yunSiteAuth', (item) => { |
|
|
|
|
|
|
|
// console.log('item',item) |
|
|
|
if (!item.isChecked) { |
|
|
|
if (!item.isChecked) { |
|
|
|
let index = this.postData.sysRoleList.findIndex(secItem => secItem.id == item.id) |
|
|
|
let index = this.postData.sysRoleList.findIndex(secItem => secItem.id == item.id) |
|
|
|
if (index !== -1) { |
|
|
|
if (index !== -1) { |
|
|
@ -127,6 +130,7 @@ |
|
|
|
return |
|
|
|
return |
|
|
|
} |
|
|
|
} |
|
|
|
this.postData.sysRoleList.push(item) |
|
|
|
this.postData.sysRoleList.push(item) |
|
|
|
|
|
|
|
console.log('this.postData.sysRoleList',this.postData.sysRoleList) |
|
|
|
}) |
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|