公告板
版本库
filestore
活动
搜索
登录
main
/
zy-asrs-master
概况
操作记录
提交次数
目录
文档
派生
对比
blame
|
历史
|
原始文档
Merge remote-tracking branch 'origin/nbncasrs' into nbncasrs
Junjie
2024-05-31
93b17a7e74d8e16ac6fa30e90e9db3960736d57f
[zy-asrs-master.git]
/
zy-asrs-flow
/
src
/
access.ts
1
2
3
4
5
6
7
8
9
/**
* @see https://umijs.org/docs/max/access#access
* */
export default function access(initialState: { currentUser?: API.CurrentUser } | undefined) {
const { currentUser } = initialState ?? {};
return {
canAdmin: currentUser && currentUser.access === 'admin',
};
}