feat(collect): 补资料改为订单号直连并按状态一次性提交

- 公开补资料页 /supplement/:订单号 直接按平台订单号查询,不再依赖链接记录;旧 token 链接一律 404
- 仅「待完善 + 未指派 + 无拼单份额」可提交,提交后状态变为待分配,重复提交返回 409
- 非可编辑工单只返回商品、工单号、状态与客服提示,不返回已填资料和截图
- 管理端新增「重置补资料」:待分配且未指派、无份额、未发布时一键重置回待完善
- 新增 canResetMaterial 能力与 material_reset 流转事件,工单状态文案统一为「待分配」
This commit is contained in:
2026-11-01 18:12:44 +08:00
parent aed76e047e
commit a2cf48f5fc
24 changed files with 1223 additions and 494 deletions
+5 -4
View File
@@ -381,19 +381,20 @@ export function submitCollectOrder(payload: {
)
}
export function fetchCollectMaterialLink(token: string) {
return apiGet<CollectMaterialLinkInfo>(`/api/v1/collect/link/${encodeURIComponent(token)}`)
export function fetchCollectMaterialLink(code: string) {
return apiGet<CollectMaterialLinkInfo>(`/api/v1/collect/link/${encodeURIComponent(code)}`)
}
export function submitCollectMaterialLink(
token: string,
code: string,
payload: {
workOrderId?: number
fields: Record<string, string>
screenshots?: UploadedFile[]
},
) {
return apiPost<CollectMaterialLinkSubmitResult>(
`/api/v1/collect/link/${encodeURIComponent(token)}/submit`,
`/api/v1/collect/link/${encodeURIComponent(code)}/submit`,
payload,
)
}