操作员管理与角色管理查看的添加

This commit is contained in:
lai_kd
2019-08-29 19:25:38 +08:00
parent 5b3b66bfb1
commit 95fff0817d
2 changed files with 19 additions and 3 deletions
+10 -2
View File
@@ -5,7 +5,7 @@
<el-input v-model="dataForm.roleName" placeholder="角色名称" clearable></el-input>
</el-form-item>
<el-form-item>
<el-button @click="getDataList()">查询</el-button>
<el-button type="text" size="small" @click="queryHandle(scope.row.id)">查看</el-button>
<el-button v-if="isAuth('sys:role:save')" type="primary" @click="addOrUpdateHandle()">新增</el-button>
<el-button v-if="isAuth('sys:role:delete')" type="danger" @click="deleteHandle()" :disabled="dataListSelections.length <= 0">批量删除</el-button>
</el-form-item>
@@ -56,7 +56,7 @@
width="180"
label="操作">
<template slot-scope="scope">
<el-button v-if="isAuth('sys:role:info')" type="text" size="small" @click="getDataList()">查看</el-button>
<el-button type="text" size="small" @click="queryHandle(scope.row.id)">查看</el-button>
<el-button v-if="isAuth('sys:role:update')" type="text" size="small" @click="addOrUpdateHandle(scope.row.id)">修改</el-button>
<el-button v-if="isAuth('sys:role:delete')" type="text" size="small" @click="deleteHandle(scope.row)">删除</el-button>
<el-button type="text" size="small" @click="queryOperHandle(scope.row.id)">关联</el-button>
@@ -148,6 +148,14 @@
this.$refs.addOrUpdate.init(id)
})
},
//查看
queryHandle(id) {
this.addOrUpdateVisible = true
this.$nextTick(() => {
this.$refs.addOrUpdate.readonly = true
this.$refs.addOrUpdate.init(id)
})
},
// 删除
deleteHandle (row) {
var ids = row ? [row.id] : this.dataListSelections.map(item => {
+9 -1
View File
@@ -88,7 +88,7 @@
width="200"
label="操作">
<template slot-scope="scope">
<el-button v-if="isAuth('sys:user:info')" type="text" size="small" @click="getDataList()">查看</el-button>
<el-button type="text" size="small" @click="queryHandle(scope.row.oper_id)">查看</el-button>
<el-button v-if="isAuth('sys:user:update')" type="text" size="small" @click="addOrUpdateHandle(scope.row.oper_id)">修改</el-button>
<el-button v-if="isAuth('sys:user:update')" type="text" size="small" @click="updatePasswordHandle(scope.row)">改密</el-button>
<el-button v-if="isAuth('sys:user:delete')" type="text" size="small" @click="deleteHandle(scope.row)">删除</el-button>
@@ -185,6 +185,14 @@
this.$refs.addOrUpdate.init(id)
})
},
//查看
queryHandle(id) {
this.addOrUpdateVisible = true
console.log(id + "id");
this.$nextTick(() => {
this.$refs.addOrUpdate.init(id)
})
},
// 更改用户密码
updatePasswordHandle (row) {
// this.addOrUpdateVisible = true