feat(M08-B): 增加保洁结算单和超时回收
This commit is contained in:
@@ -78,3 +78,27 @@
|
||||
- 权限:`cleaning.task.read`、`tenant.manage` 或 `PLATFORM_ADMIN`。
|
||||
- 查询:`page`、`pageSize`。
|
||||
- 说明:返回 `COMPLETED` 且 `settled_at IS NULL` 的待结算保洁任务。
|
||||
|
||||
- `POST /admin-api/cleaning/reclaim-timeouts`
|
||||
- 登录:必需。
|
||||
- 权限:`cleaning.task.write`、`tenant.manage` 或 `PLATFORM_ADMIN`。
|
||||
- Body:`olderThanMinutes?: number`,`limit?: number`。
|
||||
- 说明:将超时停留在 `CLAIMED` 或 `STARTED` 的任务回收到 `WAITING`,并清空保洁员领取状态。
|
||||
|
||||
- `GET /admin-api/cleaning/settlements`
|
||||
- 登录:必需。
|
||||
- 权限:`cleaning.task.read`、`tenant.manage` 或 `PLATFORM_ADMIN`。
|
||||
- 查询:`page`、`pageSize`、`status`。
|
||||
- 说明:查询保洁结算单,状态支持 `DRAFT`、`CONFIRMED`、`PAID`、`CANCELLED`。
|
||||
|
||||
- `POST /admin-api/cleaning/settlements`
|
||||
- 登录:必需。
|
||||
- 权限:`cleaning.task.write`、`tenant.manage` 或 `PLATFORM_ADMIN`。
|
||||
- Body:`cleanerUserId: string`,`storeId?: string`,`note?: string`。
|
||||
- 说明:将指定保洁员已完成未结算任务生成 `DRAFT` 结算单,任务同步转为 `SETTLED` 并写入结算明细。
|
||||
|
||||
- `POST /admin-api/cleaning/settlements/:settlementId/confirm`
|
||||
- 登录:必需。
|
||||
- 权限:`cleaning.task.write`、`tenant.manage` 或 `PLATFORM_ADMIN`。
|
||||
- Body:`note?: string`。
|
||||
- 说明:将 `DRAFT` 结算单确认成 `CONFIRMED`,后续真实支付/发放仍待继续。
|
||||
|
||||
Reference in New Issue
Block a user