优化
This commit is contained in:
@@ -3,7 +3,7 @@ import type { Amount, ProcurementCreate, ProcurementFee } from './api/procuremen
|
||||
export const procurementStatuses: Record<string, string> = {
|
||||
PENDING_REVIEW: '待审核', RECEIVING: '收货中', WAIT_CUSTOMER_CONFIRM: '待客户确认', CONFIRMED: '已确认',
|
||||
IN_TRANSIT: '运输中', DELIVERING: '派送中', COMPLETED: '签收完成',
|
||||
REJECTED: '已拒绝', CANCELLED: '已取消', EXCEPTION_CLOSED: '异常关闭',
|
||||
REJECTED: '已拒绝', CANCELLED: '已取消',
|
||||
}
|
||||
export const feePurposes: Record<string, string> = {
|
||||
SAMPLE_PAYMENT: '样品货款', INTERNATIONAL_ESTIMATE: '预估国际运费', INTERNATIONAL_FREIGHT: '实际国际运费',
|
||||
@@ -12,7 +12,7 @@ export const feePurposes: Record<string, string> = {
|
||||
export function statusLabel(status: string | null | undefined, direction?: string | null) { return regionText(status ? procurementStatuses[status] || '待核对进度' : '—', direction) }
|
||||
export function statusTone(status: string | null | undefined): 'success' | 'warning' | 'danger' | 'info' | 'primary' {
|
||||
if (status === 'COMPLETED' || status === 'CONFIRMED') return 'success'
|
||||
if (status === 'REJECTED' || status === 'EXCEPTION_CLOSED') return 'danger'
|
||||
if (status === 'REJECTED') return 'danger'
|
||||
if (status === 'CANCELLED') return 'info'
|
||||
if (status === 'IN_TRANSIT' || status === 'DELIVERING') return 'primary'
|
||||
return 'warning'
|
||||
|
||||
Reference in New Issue
Block a user