|
@@ -27,7 +27,7 @@ export function getAuthority(str?: string): string | string[] {
|
|
|
|
|
|
|
|
export function setAuthority(authority: string | string[]): void {
|
|
export function setAuthority(authority: string | string[]): void {
|
|
|
const proAuthority = typeof authority === 'string' ? [authority] : authority;
|
|
const proAuthority = typeof authority === 'string' ? [authority] : authority;
|
|
|
|
|
+ localStorage.setItem('antd-pro-authority', JSON.stringify(proAuthority));
|
|
|
// auto reload
|
|
// auto reload
|
|
|
reloadAuthorized();
|
|
reloadAuthorized();
|
|
|
- return localStorage.setItem('antd-pro-authority', JSON.stringify(proAuthority));
|
|
|
|
|
}
|
|
}
|