增加待补图订单筛选

This commit is contained in:
yml2213
2026-08-17 12:43:22 +08:00
parent baf09dc533
commit 1d9e102527
7 changed files with 50 additions and 9 deletions
@@ -696,12 +696,15 @@ export async function listAdminWorkOrders(query: JsonObject = {}) {
const page = normalizePage(query.page)
const pageSize = normalizePageSize(query.pageSize)
const workerId = normalizeOptionalId(query.workerId ?? query.worker_id) || 0
const statuses = normalizeStatuses(query.status)
const vipEvidencePending = normalizeBoolean(query.vipEvidencePending, false)
const { items, total } = await listWorkOrders({
page,
pageSize,
statuses: normalizeStatuses(query.status),
statuses,
keyword: String(query.keyword || '').trim(),
workerSharingId: workerId,
vipEvidencePending,
})
const shares = await listWorkOrderSharesByOrderIds(items.map((item) => Number(item.id)))
const sharesByOrderId = new Map<number, WorkOrderShareRow[]>()
@@ -89,6 +89,7 @@ import {
mapWorkerUser,
normalizeAmountFen,
assertWithdrawChannelAllowedForAmount,
normalizeBoolean,
normalizeFinanceRequestStatus,
normalizeFinanceRequestType,
normalizeInteger,
@@ -1114,12 +1115,14 @@ export async function listWorkerMyOrders(query: JsonObject = {}, session: Worker
await settleOverdueWorkOrders({ workerId: worker.id, limit: 50 })
const page = normalizePage(query.page)
const pageSize = normalizePageSize(query.pageSize)
const vipEvidencePending = normalizeBoolean(query.vipEvidencePending, false)
const { items, total } = await listWorkOrders({
page,
pageSize,
statuses: normalizeStatuses(query.status),
keyword: String(query.keyword || '').trim(),
workerSharingId: worker.id,
vipEvidencePending,
sort: 'worker_claimed_at_desc',
})
const permissions = resolveWorkerPermissions(worker)