Explorar o código

合并v0.1.6最新功能/调整角色管理绑定用户接口

code4eat %!s(int64=3) %!d(string=hai) anos
pai
achega
d13dfa27a8
Modificáronse 2 ficheiros con 8 adicións e 5 borrados
  1. 2 2
      config/proxy.ts
  2. 6 3
      src/pages/PlatformMana/roleManage/index.js

+ 2 - 2
config/proxy.ts

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-09-03 14:28:27
- * @LastEditTime: 2022-01-05 15:03:31
+ * @LastEditTime: 2022-01-05 17:06:44
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /MedicalWisdomCheckSys/config/proxy.ts
@@ -20,7 +20,7 @@
 export default { 
   dev: {
     '/api': {
-      target: 'http://118.31.245.65:8083/',
+      target: 'http://112.124.59.133:8083/',
       changeOrigin: true,
       pathRewrite: { '^/api': '' },
     },

+ 6 - 3
src/pages/PlatformMana/roleManage/index.js

@@ -1,7 +1,7 @@
 /*
  * @Author: your name
  * @Date: 2021-07-26 10:13:13
- * @LastEditTime: 2021-10-22 10:39:58
+ * @LastEditTime: 2022-01-05 17:20:33
  * @LastEditors: Please set LastEditors
  * @Description: In User Settings Edit
  * @FilePath: /TracerMethodology_PC/src/pages/UserMana/index.js
@@ -178,7 +178,7 @@ const UserMana = () => {
 
   //获取Drawer用户列表
   const getUsers = async (params = {}, sort, filter) => {
-    const res = await getUserList(params);
+    const res = await getUserList({...params,roleId:currentRow.roleId});
     if(res){
       return {
         data: res.list,
@@ -221,8 +221,10 @@ const UserMana = () => {
    * @param {String} type   user/menu
    */
   const bindInitHandle = async (record,type)=>{
-    const {roleId} = record;
     
+    const {roleId} = record;
+    setCurrentRow(record);
+
     if(type == 'user'){
       const resp = await roleHasBindUsers({roleId});
       if(resp){
@@ -231,6 +233,7 @@ const UserMana = () => {
       }
       setEditRoleBindUsers(true);
     }
+    
     if(type == 'menu'){
       const resp = await roleHasBindMenus({roleId});
       if(resp){