|
|
@@ -54,6 +54,7 @@ const NotificationSetting = dynamic(() => import('../../components/Admin/Notific
|
|
|
const SlackIntegration = dynamic(() => import('../../components/Admin/SlackIntegration/SlackIntegration'), { ssr: false });
|
|
|
const LegacySlackIntegration = dynamic(() => import('../../components/Admin/LegacySlackIntegration/LegacySlackIntegration'), { ssr: false });
|
|
|
const UserManagement = dynamic(() => import('../../components/Admin/UserManagement'), { ssr: false });
|
|
|
+const ManageExternalAccount = dynamic(() => import('../../components/Admin/ManageExternalAccount'), { ssr: false });
|
|
|
const UserGroupPage = dynamic(() => import('../../components/Admin/UserGroup/UserGroupPage'), { ssr: false });
|
|
|
const ElasticsearchManagement = dynamic(() => import('../../components/Admin/ElasticsearchManagement/ElasticsearchManagement'), { ssr: false });
|
|
|
// named export
|
|
|
@@ -84,8 +85,17 @@ const AdminMarkdownSettingsPage: NextPage<Props> = (props: Props) => {
|
|
|
|
|
|
const { t } = useTranslation('admin');
|
|
|
const router = useRouter();
|
|
|
- const path = router.query.path || 'home';
|
|
|
- const name = Array.isArray(path) ? path[0] : path;
|
|
|
+ // const path = router.query.path || 'home';
|
|
|
+ const { path } = router.query;
|
|
|
+ console.log({ path });
|
|
|
+
|
|
|
+ let name;
|
|
|
+ if (path != null /* && Array.isArray(path) */) {
|
|
|
+ name = path[1] != null ? path[1] : path[0];
|
|
|
+ }
|
|
|
+ else {
|
|
|
+ name = 'home';
|
|
|
+ }
|
|
|
|
|
|
const adminPagesMap = {
|
|
|
home: {
|
|
|
@@ -116,7 +126,6 @@ const AdminMarkdownSettingsPage: NextPage<Props> = (props: Props) => {
|
|
|
importer: {
|
|
|
title: useCustomTitle(props, t('Import Data')),
|
|
|
component: <DataImportPageContents />,
|
|
|
-
|
|
|
},
|
|
|
export: {
|
|
|
title: useCustomTitle(props, t('Export Archive Data')),
|
|
|
@@ -142,6 +151,10 @@ const AdminMarkdownSettingsPage: NextPage<Props> = (props: Props) => {
|
|
|
title: useCustomTitle(props, t('User_Management')),
|
|
|
component: <UserManagement />,
|
|
|
},
|
|
|
+ 'external-accounts': {
|
|
|
+ title: useCustomTitle(props, t('external_account_management')),
|
|
|
+ component: <ManageExternalAccount />,
|
|
|
+ },
|
|
|
'user-groups': {
|
|
|
title: useCustomTitle(props, t('UserGroup Management')),
|
|
|
component: <UserGroupPage />,
|