Compare commits
3 Commits
1.1.0-clou
...
main-cloud
Author | SHA1 | Date |
---|---|---|
|
29ff09d3aa | |
|
e6481aa606 | |
|
7330e38296 |
|
@ -2,4 +2,4 @@ VITE_APP_MODE=production
|
||||||
VITE_BASE_API_URL=http://103.187.147.241:30050/api
|
VITE_BASE_API_URL=http://103.187.147.241:30050/api
|
||||||
VITE_BASE_API_REPORT_URL=http://103.187.147.241:30050/api
|
VITE_BASE_API_REPORT_URL=http://103.187.147.241:30050/api
|
||||||
|
|
||||||
VITE_BASE_API_URL_LOCAL=https://api.sky.eigen.co.id/api
|
VITE_BASE_API_URL_LOCAL=https://api.office.weplayground.id/api
|
|
@ -1,5 +1,5 @@
|
||||||
VITE_APP_MODE=production
|
VITE_APP_MODE=production
|
||||||
VITE_BASE_API_URL=https://api.office.weplayground.id/api
|
VITE_BASE_API_URL=http://103.187.147.241:30050/api
|
||||||
VITE_BASE_API_REPORT_URL=https://api.office.weplayground.id/api
|
VITE_BASE_API_REPORT_URL=http://103.187.147.241:30050/api
|
||||||
|
|
||||||
VITE_BASE_API_URL_LOCAL=https://api.office.weplayground.id/api
|
VITE_BASE_API_URL_LOCAL=http://103.187.147.241:30050/api
|
|
@ -33,6 +33,13 @@ export default function AdminLayout(props: AdminLayoutProps) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function checkAllowAccessSetting() {
|
||||||
|
const username = user?.username;
|
||||||
|
const allowList = ['Endy', 'superadmin'];
|
||||||
|
if (allowList.includes(username)) return true;
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Layout>
|
<Layout>
|
||||||
<Header
|
<Header
|
||||||
|
@ -81,7 +88,15 @@ export default function AdminLayout(props: AdminLayoutProps) {
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
],
|
]
|
||||||
|
.map((item) => {
|
||||||
|
const isAllowSetting = checkAllowAccessSetting();
|
||||||
|
if (!isAllowSetting && (item.key === '1' || item.type === 'divider')) {
|
||||||
|
return undefined;
|
||||||
|
}
|
||||||
|
return item;
|
||||||
|
})
|
||||||
|
.filter(Boolean) as any,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Avatar size={35} style={{ cursor: 'pointer' }}>
|
<Avatar size={35} style={{ cursor: 'pointer' }}>
|
||||||
|
|
Loading…
Reference in New Issue