|
@@ -9,12 +9,9 @@
|
|
|
* @typedef {import('@/api/claim/index').ClaimQueryParams} ClaimQueryParams - 理赔查询参数
|
|
|
* @typedef {import('@/api/claim/index').ClaimAuditItem} ClaimAuditItem - 审核记录数据项
|
|
|
* @typedef {import('@/api/claim/index').ClaimAttachmentItem} ClaimAttachmentItem - 附件信息
|
|
|
- * @typedef {import('@/api/claim/index').ApiResponse} ApiResponse - API响应数据
|
|
|
- * @typedef {import('@/api/claim/index').PageResult} PageResult - 分页结果
|
|
|
*/
|
|
|
|
|
|
/**
|
|
|
- * @typedef {import('@/constants/claim').AUDIT_STATUS} AUDIT_STATUS - 审核状态枚举
|
|
|
* @typedef {import('@/constants/claim').CLAIM_SOURCE_TYPE} CLAIM_SOURCE_TYPE - 理赔来源类型枚举
|
|
|
* @typedef {import('@/constants/claim').ATTACHMENT_FILE_TYPE} ATTACHMENT_FILE_TYPE - 附件文件类型枚举
|
|
|
*/
|
|
@@ -33,7 +30,7 @@
|
|
|
* @property {string|null} id - 审核记录ID(编辑时必需)
|
|
|
* @property {number|null} claimId - 理赔ID
|
|
|
* @property {string} claimNo - 理赔编号
|
|
|
- * @property {number|null} auditResult - 审核结果 1-通过 2-拒绝
|
|
|
+ * @property {number|null} auditResult - 审核结果,使用 AUDIT_STATUS.APPROVED / AUDIT_STATUS.REJECTED
|
|
|
* @property {number} auditAmount - 审核金额
|
|
|
* @property {string} reasonDetail - 审核说明
|
|
|
* @property {number|null} auditorId - 审核人ID
|
|
@@ -77,7 +74,8 @@ import {
|
|
|
getClaimSourceTypeLabel,
|
|
|
getClaimSourceTypeType,
|
|
|
isValidAuditStatus,
|
|
|
- isValidClaimSourceType
|
|
|
+ isValidClaimSourceType,
|
|
|
+ AUDIT_STATUS
|
|
|
} from '@/constants/claim'
|
|
|
|
|
|
export default {
|
|
@@ -648,14 +646,13 @@ export default {
|
|
|
|
|
|
/**
|
|
|
* 获取审核结果类型
|
|
|
- * @this {Vue & import('./types').ClaimComponent}
|
|
|
- * @param {number} result - 审核结果 1-通过 2-拒绝
|
|
|
+ * @param {number} result - 审核结果,使用 AUDIT_STATUS
|
|
|
* @returns {string} 结果类型 'success' | 'danger' | 'info'
|
|
|
*/
|
|
|
getAuditResultType(result) {
|
|
|
const typeMap = {
|
|
|
- 1: 'success',
|
|
|
- 2: 'danger'
|
|
|
+ [AUDIT_STATUS.APPROVED]: 'success',
|
|
|
+ [AUDIT_STATUS.REJECTED]: 'danger'
|
|
|
}
|
|
|
return typeMap[result] || 'info'
|
|
|
},
|
|
@@ -695,14 +692,13 @@ export default {
|
|
|
|
|
|
/**
|
|
|
* 获取审核结果文本
|
|
|
- * @this {Vue & import('./types').ClaimComponent}
|
|
|
- * @param {number} result - 审核结果 1-通过 2-拒绝
|
|
|
+ * @param {number} result - 审核结果,使用 AUDIT_STATUS
|
|
|
* @returns {string} 结果文本 '通过' | '拒绝' | '未知'
|
|
|
*/
|
|
|
getAuditResultText(result) {
|
|
|
const textMap = {
|
|
|
- 1: '通过',
|
|
|
- 2: '拒绝'
|
|
|
+ [AUDIT_STATUS.APPROVED]: '通过',
|
|
|
+ [AUDIT_STATUS.REJECTED]: '拒绝'
|
|
|
}
|
|
|
return textMap[result] || '未知'
|
|
|
}
|