应收账单模块,调整枚举代码优化

This commit is contained in:
caojia
2026-09-17 11:00:59 +08:00
parent 5207c00574
commit a17f09683b
26 changed files with 397 additions and 140 deletions
+6 -23
View File
@@ -1,23 +1,6 @@
export const AR_BILL_STATUS = Object.freeze({
DRAFT: 'DRAFT',
CONFIRMED: 'CONFIRMED',
PARTIAL_WRITTEN_OFF: 'PARTIAL_WRITTEN_OFF',
WRITTEN_OFF: 'WRITTEN_OFF',
VOID: 'VOID'
})
export const AR_BILL_STATUS_OPTIONS = Object.freeze([
{ label: '草稿', value: AR_BILL_STATUS.DRAFT },
{ label: '已确认', value: AR_BILL_STATUS.CONFIRMED },
{ label: '部分核销', value: AR_BILL_STATUS.PARTIAL_WRITTEN_OFF },
{ label: '已核销', value: AR_BILL_STATUS.WRITTEN_OFF },
{ label: '已作废', value: AR_BILL_STATUS.VOID }
])
export const AR_BILL_STATUS_TYPES = Object.freeze({
[AR_BILL_STATUS.DRAFT]: 'info',
[AR_BILL_STATUS.CONFIRMED]: 'primary',
[AR_BILL_STATUS.PARTIAL_WRITTEN_OFF]: 'warning',
[AR_BILL_STATUS.WRITTEN_OFF]: 'success',
[AR_BILL_STATUS.VOID]: 'danger'
})
// 保留旧的导入路径,统一从应收枚举文件导出,避免页面各自维护状态编码。
export {
AR_BILL_STATUS,
AR_BILL_STATUS_OPTIONS,
AR_BILL_STATUS_TYPES
} from './enums'