This commit is contained in:
zlwu committed 2026-05-19 23:12:56 +08:00
1 parent 93cd506a90
commit 3b875ec370
93 files changed
+11514 -2304

No files matched your search

@@ -1211,6 +1211,15 @@
import { fetchEthnicList, type EthnicOption } from '@/api/ethnic'
import { useUserStore } from '@/store/modules/user'
import { syncFqPaymentDetailRowCount } from '@/utils/protocol-payment-installment'
import {
payModeLabel,
newbornSexLabel,
deliveryModeLabel,
sampleStatusLabel,
transportTypeLabel,
transferTypeLabel,
payStatusLabel
} from '@/utils/status-tag-registry'
const userStore = useUserStore()
@@ -1332,47 +1341,6 @@
(e: 'saved'): void
}>()
/* ====== 标签映射 ====== */
function protocolStatusLabel(s: string) {
const m: Record<string, string> = {
dsx: '待生效',
sxz: '生效中',
ygq: '已过期',
yzf: '已作废',
zky: '转科研'
}
return m[s] || s || '-'
}
function payModeLabel(s: string) {
if (s === 'dj') return '趸交'
if (s === 'fq') return '分期'
return s || '-'
}
function newbornSexLabel(s: string) {
if (s === '1') return '男'
if (s === '0') return '女'
return s || '-'
}
function deliveryModeLabel(s: string) {
if (s === 'sc') return '顺产'
if (s === 'pgc') return '剖宫产'
return s || '-'
}
function sampleStatusLabel(s: string) {
const m: Record<string, string> = { ycj: '已采集', jcz: '检测中', yrk: '已入库', yzf: '已作废' }
return m[s] || s || '-'
}
function transportTypeLabel(s: string) {
if (s === 'kdys') return '快递运输'
if (s === 'ryxd') return '人员携带'
return s || '-'
}
function siteName(id: string) {
if (!id) return '-'
return siteOptions.value.find((x) => x.id === id)?.siteName || '-'
@@ -1411,11 +1379,6 @@
return `样本 ${index + 1}`
}
function transferTypeLabel(s: string) {
const m: Record<string, string> = { wxzz: '微信', zzbzz: '支付宝', yhkzz: '银行卡', xj: '现金' }
return m[s] || s || '-'
}
function formatPaymentDateYmd(val: string) {
const s = String(val || '').trim()
if (s.length === 8 && /^\d{8}$/.test(s)) {
@@ -1464,17 +1427,6 @@
}
}
function payStatusLabel(s: string) {
const m: Record<string, string> = {
dfj: '待缴费',
jfqrz: '缴费确认中',
yjf: '已缴费',
tfqrz: '退费确认中',
ytf: '已退费'
}
return m[s] || s || '-'
}
/* ====== Tab 常量 ====== */
const formTabs = [
{ key: 'basic', label: '基本信息' },