diff --git a/src/config/getData2.js b/src/config/getData2.js index c40033f..59e4671 100644 --- a/src/config/getData2.js +++ b/src/config/getData2.js @@ -76,3 +76,26 @@ export const sysRoleQuery = (page, size) => post('api/sysRole/query', { page: page, size: size }) +// 1.2 添加角色 +export const sysRoleAdd = (name, remark) => post('api/sysRole/add', { + name: name, + remark: remark +}) +// 1.3 修改角色 +export const sysRoleEdit = (roleId, name, remark) => post('api/sysRole/edit', { + roleId: roleId, + name: name, + remark: remark +}) +// 1.4 删除角色 +export const sysRoleDelete = (roleId) => post('api/sysRole/delete', { + rolesIds: roleId +}) +// 1.5 保存菜单 +export const sysRoleMenu = (roleId, menus) => post('api/sysRole/menu', { + roleId: roleId, + menus: menus +}) +// 1.6 查询菜单树 +export const menuQuery = (roleId, menus) => post('api/sysRole/menuQuery', { +}) diff --git a/src/main.js b/src/main.js index f0fce1a..5a1ba16 100644 --- a/src/main.js +++ b/src/main.js @@ -9,7 +9,7 @@ import fastClick from 'fastclick' import infiniteScroll from 'vue-infinite-scroll' import VueTouchKeyboard from 'vue-touch-keyboard' import 'vue-touch-keyboard/dist/vue-touch-keyboard.css' -import { DatePicker, Select, Option, Radio, Menu, MenuItem } from 'element-ui' +import { DatePicker, Select, Option, Radio, Menu, MenuItem, Tree } from 'element-ui' import { Pagination } from 'vant' // import '@style/layout.styl' import '@style/common.styl' @@ -26,6 +26,7 @@ Vue.use(Option) Vue.use(Radio) Vue.use(Menu) Vue.use(MenuItem) +Vue.use(Tree) Vue.use(Pagination) Vue.use(infiniteScroll) Vue.use(VueTouchKeyboard) diff --git a/src/pages/modules/systemmanage/role.vue b/src/pages/modules/systemmanage/role.vue index dc1728e..c01c584 100644 --- a/src/pages/modules/systemmanage/role.vue +++ b/src/pages/modules/systemmanage/role.vue @@ -19,13 +19,13 @@
- 超级管理员 - 垃圾分类几点睡浪费就冷冻机房蓝黛科技弗兰克 - 2023-05-05 08:50:08 + {{ e.name }} + {{ e.remark }} + {{ e.createTime }}
- - + +
@@ -34,45 +34,18 @@
角色名称 - +
-
-
-
- -
- - -
- {{e.label}} -
-
-
-
- -
- - -
- {{el.label}} -
-
-
-
- -
- - -
- {{ ele.label }} -
-
-
-
-
-
-
+ +
@@ -80,6 +53,7 @@ ref="child" :title="title" :type="type" + :unclick="unclick" @toSure="toSureDialog" >
@@ -87,7 +61,7 @@
*角色名称
- +
@@ -107,114 +81,27 @@