管理人员角色相关优化

This commit is contained in:
禺狨 2023-04-04 14:10:58 +08:00
parent ab06c731aa
commit 1a73f08a74
3 changed files with 4 additions and 2 deletions

View File

@ -9,6 +9,7 @@ interface Option {
} }
interface PropInterface { interface PropInterface {
refresh: boolean;
type: string; type: string;
text: string; text: string;
onUpdate: (keys: any, title: any) => void; onUpdate: (keys: any, title: any) => void;
@ -34,7 +35,7 @@ export const TreeAdminroles = (props: PropInterface) => {
setTreeData(new_arr); setTreeData(new_arr);
} }
}); });
}, []); }, [props.refresh]);
const onSelect = (selectedKeys: any, info: any) => { const onSelect = (selectedKeys: any, info: any) => {
let label = "全部" + props.text; let label = "全部" + props.text;
if (info) { if (info) {

View File

@ -185,6 +185,7 @@ const SystemAdministratorPage = () => {
<div className="tree-main-body"> <div className="tree-main-body">
<div className="left-box"> <div className="left-box">
<TreeAdminroles <TreeAdminroles
refresh={refresh}
type="" type=""
text={"管理员"} text={"管理员"}
onUpdate={(keys: any, title: any) => { onUpdate={(keys: any, title: any) => {

View File

@ -152,7 +152,7 @@ export const SystemAdminrolesUpdate: React.FC<PropInterface> = ({
return ( return (
<> <>
<Drawer <Drawer
title="新建角色" title="编辑角色权限"
onClose={onCancel} onClose={onCancel}
maskClosable={false} maskClosable={false}
open={open} open={open}