- //
- //
-
-
- {userInfo?.nickname + ' ' + t('setting.workspace')}
-
-
- }
- >
-
-
-
-
-
- {/* */}
-
- {t('setting.teamMembers')}
-
-
-
- setSearchUser(e.target.value)}
- />
-
-
-
-
-
-
-
-
-
-
-
- {/* */}
-
- {t('setting.joinedTeams')}
-
- setSearchTerm(e.target.value)}
- placeholder={t('common.search')}
- />
-
-
-
-
-
-
-
- {addingTenantModalVisible && (
-
- )}
-
+
+
+
);
};
diff --git a/web/src/pages/user-setting/setting-team/legacy-page.tsx b/web/src/pages/user-setting/setting-team/legacy-page.tsx
new file mode 100644
index 0000000000..8257f971e0
--- /dev/null
+++ b/web/src/pages/user-setting/setting-team/legacy-page.tsx
@@ -0,0 +1,113 @@
+/*
+ * Copyright 2026 The InfiniFlow Authors. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+import { Button } from '@/components/ui/button';
+import { Card, CardContent, CardHeader, CardTitle } from '@/components/ui/card';
+import { useFetchUserInfo } from '@/hooks/use-user-setting-request';
+import { useTranslation } from 'react-i18next';
+
+import Spotlight from '@/components/spotlight';
+import { SearchInput } from '@/components/ui/input';
+import { UserPlus } from 'lucide-react';
+import { useState } from 'react';
+import { ProfileSettingWrapperCard } from '../components/user-setting-header';
+import AddingUserModal from './add-user-modal';
+import { useAddUser } from './hooks';
+import TenantTable from './tenant-table';
+import UserTable from './user-table';
+
+const UserSettingTeam = () => {
+ const { data: userInfo } = useFetchUserInfo();
+ const { t } = useTranslation();
+ const [searchTerm, setSearchTerm] = useState('');
+ const [searchUser, setSearchUser] = useState('');
+ const {
+ addingTenantModalVisible,
+ hideAddingTenantModal,
+ showAddingTenantModal,
+ handleAddUserOk,
+ } = useAddUser();
+
+ return (
+
+
+ {userInfo?.nickname + ' ' + t('setting.workspace')}
+
+
+ }
+ >
+
+
+
+
+
+ {/* */}
+
+ {t('setting.teamMembers')}
+
+
+
+ setSearchUser(e.target.value)}
+ />
+
+
+
+
+
+
+
+
+
+
+
+ {/* */}
+
+ {t('setting.joinedTeams')}
+
+ setSearchTerm(e.target.value)}
+ placeholder={t('common.search')}
+ />
+
+
+
+
+
+
+
+ {addingTenantModalVisible && (
+
+ )}
+
+ );
+};
+
+export default UserSettingTeam;
diff --git a/web/src/pages/user-setting/setting-team/user-table.tsx b/web/src/pages/user-setting/setting-team/user-table.tsx
index 44d940137e..60a59b0fca 100644
--- a/web/src/pages/user-setting/setting-team/user-table.tsx
+++ b/web/src/pages/user-setting/setting-team/user-table.tsx
@@ -30,7 +30,10 @@ import {
TableHeader,
TableRow,
} from '@/components/ui/table';
-import { useListTenantUser } from '@/hooks/use-user-setting-request';
+import {
+ useFetchTenantInfo,
+ useListTenantUser,
+} from '@/hooks/use-user-setting-request';
import { formatDate } from '@/utils/date';
import { upperFirst } from 'lodash';
import { ArrowDown, ArrowUp, ArrowUpDown, Trash2 } from 'lucide-react';
@@ -49,7 +52,9 @@ const ColorMap: Record
= {
};
const UserTable = ({ searchUser }: { searchUser: string }) => {
- const { data, loading } = useListTenantUser();
+ const { data: tenantInfo } = useFetchTenantInfo();
+ const { data, loading } = useListTenantUser(tenantInfo.tenant_id);
+ // const { handleDeleteTenantUser } = useHandleDeleteUser();
const { deleteTenantUser } = useHandleDeleteUser();
const [sortOrder, setSortOrder] = useState<'asc' | 'desc' | null>(null);
const { t } = useTranslation();
diff --git a/web/src/pages/user-setting/sidebar/hooks.tsx b/web/src/pages/user-setting/sidebar/hooks.tsx
index 68d9372b40..89640590dd 100644
--- a/web/src/pages/user-setting/sidebar/hooks.tsx
+++ b/web/src/pages/user-setting/sidebar/hooks.tsx
@@ -15,13 +15,14 @@
*/
import { useLogout } from '@/hooks/use-login-request';
+import { PrivateRoutes } from '@/ee/private-routes';
import { Routes } from '@/routes';
import { useCallback, useEffect, useState } from 'react';
import { useLocation, useNavigate } from 'react-router';
export const useHandleMenuClick = () => {
const navigate = useNavigate();
- const [active, setActive] = useState();
+ const [active, setActive] = useState();
const { logout } = useLogout();
const location = useLocation();
useEffect(() => {
@@ -32,7 +33,7 @@ export const useHandleMenuClick = () => {
}, [location]);
const handleMenuClick = useCallback(
- (key: Routes) => () => {
+ (key: Routes | PrivateRoutes) => () => {
if (key === Routes.Logout) {
logout();
} else {
diff --git a/web/src/pages/user-setting/sidebar/index.tsx b/web/src/pages/user-setting/sidebar/index.tsx
index b0dd58f521..759badb86e 100644
--- a/web/src/pages/user-setting/sidebar/index.tsx
+++ b/web/src/pages/user-setting/sidebar/index.tsx
@@ -19,6 +19,7 @@ import { RAGFlowAvatar } from '@/components/ragflow-avatar';
import ThemeSwitch from '@/components/theme-switch';
import { Button } from '@/components/ui/button';
import { Domain } from '@/constants/common';
+import { useSettingMenuItems } from '@/ee/pages/user-setting/sidebar/use-setting-menu';
import { useLogout } from '@/hooks/use-login-request';
import {
useFetchSystemVersion,
@@ -90,6 +91,7 @@ export function SideBar() {
}
}, [fetchSystemVersion]);
const { logout } = useLogout();
+ const items = useSettingMenuItems(menuItems(t));
return (