Files
track/frontend
duxingchen 2b5e3ae4c3 feat(frontend): 更新 TS 类型定义与 API 服务层,对接后端重构接口
types/api.ts:
- TaskSummary/TaskResponse 新增 is_rework, reject_reason, received_at, completed_at 字段
- 新增 TASK_STATUS 常量 (PENDING/WIP/COMPLETED/REJECTED/ARCHIVED)
- 新增 TaskTransferResponse, TaskRejectPayload, TaskTransferPayload 类型
- ProductScanResponse 新增 current_location_id, task_tree 字段

types/admin.ts:
- ProductResponse 新增 current_location_id 字段

services/taskApi.ts:
- 新增 getTaskTree(serialNumber) — 产品全景任务树
- 新增 receiveTask(taskId) — 确认接收
- 新增 rejectTask(taskId, reason) — 品质驳回
- 新增 transferTask(taskId, assignees, name, note?) — 完工裂变转交
2026-08-04 17:30:12 +08:00
..
2026-08-04 10:05:59 +08:00
2026-08-04 10:05:59 +08:00
2026-08-04 10:05:59 +08:00
2026-08-04 10:05:59 +08:00

React + TypeScript + Vite

This template provides a minimal setup to get React working in Vite with HMR and some Oxlint rules.

Currently, two official plugins are available:

React Compiler

The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see this documentation.

Expanding the Oxlint configuration

If you are developing a production application, we recommend enabling type-aware lint rules by installing oxlint-tsgolint and editing .oxlintrc.json:

{
  "$schema": "./node_modules/oxlint/configuration_schema.json",
  "plugins": ["react", "typescript", "oxc"],
  "options": {
    "typeAware": true
  },
  "rules": {
    "react/rules-of-hooks": "error",
    "react/only-export-components": ["warn", { "allowConstantExport": true }]
  }
}

See the Oxlint rules documentation for the full list of rules and categories.