diff --git a/docs/user/usage.md b/docs/user/usage.md index 9c4f4fe..632b336 100644 --- a/docs/user/usage.md +++ b/docs/user/usage.md @@ -46,7 +46,7 @@ bun run dev config.yaml - **Admin(管理台)**:全局管理视角,包含总览和项目管理。默认入口,访问 `/` 即可进入。 - **Workbench(工作台)**:项目维度视角,通过 `/workbench/:projectId` 进入指定项目的工作台。URL 可保存为浏览器书签,下次直接进入。仅 active 状态的项目可进入工作台,archived 项目不可访问。 -从项目管理页面的 active 项目行可点击"进入工作台"跳转到对应项目的工作台。 +从项目管理页面的 active 项目行可点击"工作台"跳转到对应项目的工作台。 ## 模型管理 diff --git a/src/web/pages/projects/components/ProjectTable.tsx b/src/web/pages/projects/components/ProjectTable.tsx index fb559d6..60ea429 100644 --- a/src/web/pages/projects/components/ProjectTable.tsx +++ b/src/web/pages/projects/components/ProjectTable.tsx @@ -4,7 +4,7 @@ import { DeleteOutlined, EditOutlined, InboxOutlined, LoginOutlined, RedoOutline import { App as AntApp, Button, Popconfirm, Space, Table, Tag } from "antd"; import { useNavigate } from "react-router"; -import type { Project, ProjectListResponse } from "../../../../shared/api"; +import type { Project, ProjectListResponse, ProjectStatus } from "../../../../shared/api"; interface ProjectTableProps { data: ProjectListResponse | undefined; @@ -16,11 +16,12 @@ interface ProjectTableProps { onRestore: (id: string) => Promise; page: number; pageSize: number; + status: ProjectStatus; } const COLUMNS: ColumnsType = [ - { dataIndex: "name", ellipsis: true, title: "项目名称", width: 160 }, - { dataIndex: "description", ellipsis: true, title: "项目描述" }, + { dataIndex: "name", ellipsis: true, title: "名称", width: 140 }, + { dataIndex: "description", ellipsis: true, title: "描述" }, { align: "center", dataIndex: "status", @@ -31,21 +32,21 @@ const COLUMNS: ColumnsType = [ return 进行中; }, title: "状态", - width: 100, + width: 90, }, { align: "center", dataIndex: "createdAt", render: (_value, record: Project) => formatDatetime(record.createdAt), title: "创建时间", - width: 185, + width: 180, }, { align: "center", dataIndex: "updatedAt", render: (_value, record: Project) => formatDatetime(record.updatedAt), title: "更新时间", - width: 185, + width: 180, }, ]; @@ -59,6 +60,7 @@ export function ProjectTable({ onRestore, page, pageSize, + status, }: ProjectTableProps) { const { message } = AntApp.useApp(); const navigate = useNavigate(); @@ -92,7 +94,6 @@ export function ProjectTable({ const operationColumn: ColumnsType[number] = { dataIndex: "op", - fixed: "right", render: (_value, record: Project) => { if (record.status === "active") { return ( @@ -103,7 +104,7 @@ export function ProjectTable({ size="small" type="link" > - 进入工作台 + 工作台