|
|
@ -59,8 +59,19 @@ |
|
|
|
<view class="ei-author"> |
|
|
|
<view>权限:</view> |
|
|
|
<view> |
|
|
|
<view class="tag-active" v-if="k.extension.permission.menu.length == permissionArr.length">全部权限</view> |
|
|
|
<view v-else v-for="e in k.extension.permission.menu" :key="e">{{permissionObj[e] || ''}}</view> |
|
|
|
<view |
|
|
|
class="tag-active" |
|
|
|
v-if="isAllAuthor({ |
|
|
|
adminLs: k.extension.permission.menu, |
|
|
|
localLs: permissionArr, |
|
|
|
})" |
|
|
|
>全部权限</view> |
|
|
|
<block v-else > |
|
|
|
<block v-for="e in k.extension.permission.menu" :key="e"> |
|
|
|
<view v-if="!!permissionObj[e]">{{permissionObj[e] || ''}}</view> |
|
|
|
</block> |
|
|
|
|
|
|
|
</block> |
|
|
|
</view> |
|
|
|
</view> |
|
|
|
</view> |
|
|
@ -114,11 +125,21 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
onLoad(){ |
|
|
|
|
|
|
|
}, |
|
|
|
onShow(){ |
|
|
|
this.refreshEmployList(); |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
// 是否全部权限 |
|
|
|
isAllAuthor({ |
|
|
|
adminLs = [], |
|
|
|
localLs = [] |
|
|
|
}){ |
|
|
|
if(!localLs || !adminLs || !adminLs.length || !localLs.length)return false; |
|
|
|
let _unAuthorLs = localLs.filter(ele=>!adminLs.includes(+ele.key)) |
|
|
|
return !_unAuthorLs.length |
|
|
|
}, |
|
|
|
// 移除员工 |
|
|
|
employeeDelete: util.debounce(function(){ |
|
|
|
let _employeeList = this.employeeInfo.employee || []; |
|
|
|