diff --git a/src/features/user-management/index.tsx b/src/features/user-management/index.tsx deleted file mode 100644 index 56cb577..0000000 --- a/src/features/user-management/index.tsx +++ /dev/null @@ -1,49 +0,0 @@ -"use client" - -import { UserTable } from "./components/user-table" -import { adminConfig } from "./config/admin" -import { teacherConfig } from "./config/teacher" -import { guestConfig } from "./config/guest" -import { problemConfig } from "./config/problem" - -interface UserManagementProps { - userType: "admin" | "teacher" | "guest" | "problem" -} - -export function UserManagement({ userType }: UserManagementProps) { - // 根据用户类型返回对应的配置 - if (userType === "admin") { - return ( - - ) - } - if (userType === "teacher") { - return ( - - ) - } - if (userType === "guest") { - return ( - - ) - } - if (userType === "problem") { - return ( - - ) - } - - return
暂不支持 {userType} 类型
-} \ No newline at end of file diff --git a/src/types/problem.ts b/src/types/problem.ts deleted file mode 100644 index e236c91..0000000 --- a/src/types/problem.ts +++ /dev/null @@ -1,12 +0,0 @@ -export interface Problem { - id: string; - displayId: number; - difficulty: string; - isPublished: boolean; - isTrim: boolean; - timeLimit: number; - memoryLimit: number; - userId?: string | null; - createdAt: string; - updatedAt: string; -} \ No newline at end of file diff --git a/src/types/user.ts b/src/types/user.ts deleted file mode 100644 index 02c3965..0000000 --- a/src/types/user.ts +++ /dev/null @@ -1,19 +0,0 @@ -export interface UserBase { - id: string; - name?: string; - email: string; - password?: string; - role?: string; - createdAt: string; - updatedAt?: string; -} - -export interface Admin extends UserBase { - // 管理员特有字段(如有) -} -export interface Teacher extends UserBase { - // 教师特有字段(如有) -} -export interface Guest extends UserBase { - // 学生特有字段(如有) -} \ No newline at end of file