You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
export default (initialState: API.UserInfo) => {
|
|
// 在这里按照初始化数据定义项目中的权限,统一管理
|
|
// 参考文档 https://umijs.org/docs/max/access
|
|
const canSeeAdmin = !!(
|
|
initialState && initialState.name !== 'dontHaveAccess'
|
|
);
|
|
return {
|
|
canSeeAdmin,
|
|
canDelete: true,
|
|
canLogin: true
|
|
};
|
|
};
|