| | |
| | | <div class="role_manage"> |
| | | <div> |
| | | <el-row class="title"> |
| | | <el-col :span="12" style="padding-left: 20px;">角色管理</el-col> |
| | | <el-col :span="12" style="padding-left: 20px;text-align: left;">角色管理</el-col> |
| | | <el-col :span="12" style="text-align: right;"> |
| | | <el-button size="medium" type="primary" @click="openAdd" v-if="addPower">新增角色</el-button> |
| | | </el-col> |
| | |
| | | select: [] |
| | | } |
| | | }, |
| | | selectField: {} |
| | | selectField: {}, |
| | | needSort: ['createTime', 'updateTime', 'name'], |
| | | }, |
| | | entityCopy: {}, |
| | | upIndex: 0, |
| | |
| | | this.getPower() |
| | | }, |
| | | methods: { |
| | | refreshTable() { |
| | | this.$refs['ValueTable'].selectList() |
| | | refreshTable(e) { |
| | | this.$refs['ValueTable'].selectList(e) |
| | | }, |
| | | refresh() { |
| | | this.componentData.entity = this.HaveJson(this.entityCopy) |
| | |
| | | upRole(row) { |
| | | this.type = '修改' |
| | | this.addData.roleName = row.name |
| | | this.addData.category = row.category |
| | | this.$set(this.addData, 'category', row.category) |
| | | // this.addData.category = row.category |
| | | this.selectPowerByRoleId(row.id) |
| | | }, |
| | | selectRole(row) { |
| | | this.type = '查看' |
| | | this.addData.roleName = row.name |
| | | this.addData.category = row.category |
| | | this.$set(this.addData, 'category', row.category) |
| | | // this.addData.category = row.category |
| | | this.selectPowerByRoleId(row.id) |
| | | }, |
| | | openAdd() { |
| | |
| | | } |
| | | this.addLoad = false |
| | | this.addDia = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | }).catch(e => { |
| | | this.addLoad = false |
| | | }) |