|
@@ -28,7 +28,7 @@
|
|
|
</div>
|
|
|
<div class="table-operator">
|
|
|
<!-- <a-button v-if="$hasPermissions('B_powerMD_user_add')" type="primary" class="button-error" @click="openModal">新增</a-button> -->
|
|
|
- <a-button type="primary" class="button-error" @click="openModal">新增</a-button>
|
|
|
+ <a-button type="primary" v-if="$hasPermissions('B_power_user_add')" class="button-error" @click="openModal">新增</a-button>
|
|
|
</div>
|
|
|
<s-table
|
|
|
ref="table"
|
|
@@ -44,8 +44,8 @@
|
|
|
<!-- <a-switch v-if="$hasPermissions('B_powerMD_user_enable')" checkedChildren="启用" unCheckedChildren="禁用" v-model="record.loginFlag" @change="changeFlagHandle(text, record)"/>
|
|
|
<span v-else>{{ record.loginFlag==1?'已启用':'已禁用' }}</span> -->
|
|
|
<!-- 超级管理员不可删除不可编辑不可启禁用 -->
|
|
|
- <a-switch v-if="record.superAdmin!=1" checkedChildren="启用" unCheckedChildren="禁用" v-model="record.loginFlag" @change="changeFlagHandle(text, record)"/>
|
|
|
- <span v-if="record.superAdmin==1">{{ record.loginFlag==1?'已启用':'已禁用' }}</span>
|
|
|
+ <a-switch v-if="record.superAdmin!=1 && $hasPermissions('B_power_user_enable')" checkedChildren="启用" unCheckedChildren="禁用" v-model="record.loginFlag" @change="changeFlagHandle(text, record)"/>
|
|
|
+ <span v-else>{{ record.loginFlag==1?'已启用':'已禁用' }}</span>
|
|
|
</span>
|
|
|
<span slot="action" slot-scope="text, record">
|
|
|
<!-- <a-icon
|
|
@@ -70,25 +70,26 @@
|
|
|
<a-icon
|
|
|
type="edit"
|
|
|
title="编辑"
|
|
|
- v-if="record.superAdmin!=1"
|
|
|
+ v-if="record.superAdmin!=1 &&$hasPermissions('B_power_user_edit')"
|
|
|
:style="{fontSize: '20px',color:' #1890FF',padding:' 0 10px'}"
|
|
|
@click="handleEdit(record)"
|
|
|
/>
|
|
|
<a-icon
|
|
|
type="unlock"
|
|
|
title="重置密码"
|
|
|
- v-if="record.loginFlag==1 && record.superAdmin!=1"
|
|
|
+ v-if="record.loginFlag==1 && record.superAdmin!=1 &&$hasPermissions('B_power_user_resetPsd')"
|
|
|
:style="{fontSize: '20px',color:' #ffaa00',padding: '0 10px'}"
|
|
|
@click="resetPassword(record)" />
|
|
|
<a-icon
|
|
|
type="delete"
|
|
|
title="删除"
|
|
|
:style="{fontSize: '20px',color: '#f00',padding: '0 10px'}"
|
|
|
- v-if="record.loginFlag==0 && record.superAdmin!=1"
|
|
|
+ v-if="record.loginFlag==0 && record.superAdmin!=1 &&$hasPermissions('B_power_user_del')"
|
|
|
@click="delect(record)"/>
|
|
|
<a-icon
|
|
|
type="setting"
|
|
|
title="分区设置"
|
|
|
+ v-if="$hasPermissions('B_power_user_set')"
|
|
|
:style="{fontSize: '20px',color:' #00aa00',padding: '0 10px'}"
|
|
|
@click="handleSetting(record)" />
|
|
|
</span>
|