feat: rewrite workflows page as dense list
This commit is contained in:
@@ -70,6 +70,10 @@ test("proxies workflow lookup items from the backend workflows list api", async
|
||||
},
|
||||
currentStep: "review",
|
||||
currentStepLabel: "人工审核",
|
||||
failureCount: 0,
|
||||
reviewTaskStatus: "revision_uploaded",
|
||||
revisionCount: 1,
|
||||
pendingManualConfirm: true,
|
||||
updatedAt: "2026-03-27T14:00:03Z",
|
||||
},
|
||||
],
|
||||
|
||||
@@ -16,15 +16,21 @@ const WORKFLOW_ITEMS: WorkflowLookupItemVM[] = [
|
||||
},
|
||||
currentStep: "review",
|
||||
currentStepLabel: "人工审核",
|
||||
failureCount: 2,
|
||||
reviewTaskStatus: "revision_uploaded",
|
||||
revisionCount: 1,
|
||||
pendingManualConfirm: true,
|
||||
updatedAt: "2026-03-27T09:15:00Z",
|
||||
},
|
||||
];
|
||||
|
||||
test("shows the real recent-workflows entry state", () => {
|
||||
test("renders workflows as a high-density table with shared toolbar controls", () => {
|
||||
render(<WorkflowLookup items={WORKFLOW_ITEMS} />);
|
||||
|
||||
expect(screen.getByText("流程追踪首页当前显示真实后端最近流程。")).toBeInTheDocument();
|
||||
expect(screen.getByText("订单 #4201")).toBeInTheDocument();
|
||||
expect(screen.getByRole("columnheader", { name: "流程类型" })).toBeInTheDocument();
|
||||
expect(screen.getByRole("columnheader", { name: "失败次数" })).toBeInTheDocument();
|
||||
expect(screen.getByLabelText("流程状态筛选")).toBeInTheDocument();
|
||||
expect(screen.getByText("#4201")).toBeInTheDocument();
|
||||
});
|
||||
|
||||
test("supports workflow status filtering and pagination actions", () => {
|
||||
|
||||
@@ -79,6 +79,9 @@ test("maps workflow lookup status and current step labels", () => {
|
||||
status: "running",
|
||||
currentStep: "fusion",
|
||||
currentStepLabel: "融合",
|
||||
failureCount: 0,
|
||||
revisionCount: 0,
|
||||
pendingManualConfirm: false,
|
||||
statusMeta: {
|
||||
label: "处理中",
|
||||
tone: "info",
|
||||
|
||||
Reference in New Issue
Block a user