修复财务页面竞态并整理采购与运输展示
This commit is contained in:
@@ -79,6 +79,7 @@ export function feeActions(fee: OverseasFee, can: (permission: string) => boolea
|
||||
const closed = fee.reviewStatus === 'REJECTED' || ['VOIDED', 'SUPERSEDED', 'CANCELLED'].includes(fee.sourceStatus)
|
||||
const canReview = can(feePermissions.review)
|
||||
const visibleActions = fee.allowedActions.filter(action => action in actionLabels && !['APPROVE', 'REJECT', 'CANCEL'].includes(action))
|
||||
.filter(action => !['ADJUST', 'VOID'].includes(action) || ['DRAFT', 'PENDING'].includes(fee.reviewStatus))
|
||||
.filter(action => !closed || ['RETRY_RELEASE', 'RETRY_FUNDING_DELIVERY'].includes(action))
|
||||
.filter(action => can(['VOID'].includes(action) ? feePermissions.review : feePermissions.edit))
|
||||
.map(action => ({ key: action, label: actionLabels[action]!, priority: 20,
|
||||
|
||||
Reference in New Issue
Block a user