v5拼单免审核
This commit is contained in:
@@ -1369,26 +1369,21 @@ function canRemindAcceptance(order: WorkOrder) {
|
||||
}
|
||||
|
||||
function canAutoAcceptOrder(order: WorkOrder, workerCanAutoAcceptWithoutEvidence: boolean) {
|
||||
return (
|
||||
workerCanAutoAcceptWithoutEvidence &&
|
||||
!order.myShare &&
|
||||
order.sharing?.enabled !== true &&
|
||||
['in_progress', 'problem'].includes(order.status)
|
||||
)
|
||||
if (!workerCanAutoAcceptWithoutEvidence) return false
|
||||
if (order.myShare) return order.myShare.status === 'joined' && order.status !== 'accepted'
|
||||
return order.sharing?.enabled !== true && ['in_progress', 'problem'].includes(order.status)
|
||||
}
|
||||
|
||||
function canSupplementAcceptedEvidence(order: WorkOrder) {
|
||||
if (order.myShare || order.status !== 'accepted' || order.acceptance?.reviewMode !== 'vip_auto') {
|
||||
return false
|
||||
}
|
||||
const dueAt = Date.parse(String(order.acceptance.evidenceDueAt || ''))
|
||||
const acceptance = getWorkerAcceptance(order)
|
||||
if (order.status !== 'accepted' || acceptance?.reviewMode !== 'vip_auto') return false
|
||||
const dueAt = Date.parse(String(acceptance.evidenceDueAt || ''))
|
||||
return Number.isFinite(dueAt) && dueAt > Date.now()
|
||||
}
|
||||
|
||||
function isVipEvidencePending(order: WorkOrder) {
|
||||
return (
|
||||
order.acceptance?.reviewMode === 'vip_auto' && order.acceptance?.evidenceStatus === 'pending'
|
||||
)
|
||||
const acceptance = getWorkerAcceptance(order)
|
||||
return acceptance?.reviewMode === 'vip_auto' && acceptance?.evidenceStatus === 'pending'
|
||||
}
|
||||
|
||||
/** 是否可编辑验收图片:未提交时可暂存,已提交(待验收)时可补充/修改 */
|
||||
|
||||
Reference in New Issue
Block a user