提交
This commit is contained in:
1 parent
771f010a39
commit
ee4abd361e
102 files changed
+8021
-4094
No files matched your search
@@ -297,11 +297,10 @@
|
||||
<el-input v-model="formData.insurancePolicyNo" placeholder="请输入保险单号" />
|
||||
</el-form-item>
|
||||
<el-form-item label="保单费用(元)">
|
||||
<el-input-number
|
||||
<AmountInput
|
||||
v-model="formData.insuranceFee"
|
||||
:precision="2"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
placeholder="请输入保单费用"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="保险单生效时间">
|
||||
@@ -415,7 +414,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<span class="upload-hint"
|
||||
>支持图片、视频、PDF、Word、Excel等文件,单文件不超过 20MB</span
|
||||
>支持图片、视频、PDF、Word、Excel等文件</span
|
||||
>
|
||||
</div>
|
||||
</el-form-item>
|
||||
@@ -474,6 +473,7 @@
|
||||
Delete
|
||||
} from '@element-plus/icons-vue'
|
||||
import ProtocolViewDialog from '../protocol/ProtocolViewDialog.vue'
|
||||
import AmountInput from '@/components/common/amount-input/index.vue'
|
||||
import {
|
||||
fetchCollectionProtocolDetail,
|
||||
type CollectionProtocolRow
|
||||
@@ -1062,13 +1062,6 @@
|
||||
const file = uploadFile.raw || uploadFile
|
||||
if (!file) return
|
||||
|
||||
const maxSizeMb = 20
|
||||
if (file.size / 1024 / 1024 > maxSizeMb) {
|
||||
ElMessage.error(`文件大小不能超过 ${maxSizeMb}MB`)
|
||||
attachmentUploadRef.value?.clearFiles()
|
||||
return
|
||||
}
|
||||
|
||||
const tempId = `temp_${Date.now()}_${Math.random().toString(36).slice(2, 8)}`
|
||||
formData.attachments.push({
|
||||
id: tempId,
|
||||
|
||||
@@ -285,16 +285,21 @@
|
||||
import { maskIdCard } from '@/utils/mask-sensitive'
|
||||
import { downloadAttachmentFile } from '@/utils/download-attachment'
|
||||
import {
|
||||
formatPaymentAmount,
|
||||
formatPaymentDueDate,
|
||||
payModeLabel,
|
||||
protocolStatusLabel,
|
||||
protocolStatusTagType,
|
||||
transferTypeLabel
|
||||
} from '@/utils/protocol-payment-labels'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
|
||||
defineOptions({ name: 'CellStoragePaymentConfirm' })
|
||||
|
||||
function formatPaymentAmount(v: unknown): string {
|
||||
if (v == null || v === '') return '-'
|
||||
return '¥' + formatMoneyDisplay(v)
|
||||
}
|
||||
|
||||
function formatLocalDate(d: Date): string {
|
||||
const y = d.getFullYear()
|
||||
const m = String(d.getMonth() + 1).padStart(2, '0')
|
||||
|
||||
@@ -332,13 +332,11 @@
|
||||
>
|
||||
<div class="form-grid-2">
|
||||
<el-form-item label="退费金额(元)" prop="refundAmount" class="form-col-span-2">
|
||||
<el-input-number
|
||||
<AmountInput
|
||||
v-model="refundForm.refundAmount"
|
||||
:min="0.01"
|
||||
:precision="2"
|
||||
:step="100"
|
||||
controls-position="right"
|
||||
style="width: 100%"
|
||||
placeholder="请输入退费金额"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="退费备注" prop="refundRemark" class="form-col-span-2">
|
||||
@@ -447,6 +445,8 @@
|
||||
import { fetchUploadAttachment } from '@/api/business'
|
||||
import { maskIdCard } from '@/utils/mask-sensitive'
|
||||
import { isPaymentDueWithinWarnWindow } from '@/utils/protocol-payment-labels'
|
||||
import AmountInput from '@/components/common/amount-input/index.vue'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
import {
|
||||
protocolStatusLabel,
|
||||
protocolStatusTagType,
|
||||
@@ -544,11 +544,9 @@
|
||||
return isPaymentDueWithinWarnWindow(row.installmentDueDate) ? 'row-due-soon' : ''
|
||||
}
|
||||
|
||||
function formatAmount(v: unknown) {
|
||||
function formatAmount(v: unknown): string {
|
||||
if (v == null || v === '') return '-'
|
||||
const n = Number(v)
|
||||
if (Number.isNaN(n)) return String(v)
|
||||
return '¥' + n.toLocaleString('zh-CN', { minimumFractionDigits: 2, maximumFractionDigits: 2 })
|
||||
return '¥' + formatMoneyDisplay(v)
|
||||
}
|
||||
|
||||
async function loadData() {
|
||||
@@ -668,11 +666,6 @@
|
||||
async function handleRefundAttachmentChange(uploadFile: { raw?: File }) {
|
||||
const file = uploadFile.raw
|
||||
if (!file) return
|
||||
const maxSizeMb = 20
|
||||
if (file.size / 1024 / 1024 > maxSizeMb) {
|
||||
ElMessage.error(`文件大小不能超过 ${maxSizeMb}MB`)
|
||||
return
|
||||
}
|
||||
const tempId = `temp_${Date.now()}`
|
||||
refundForm.attachments.push({
|
||||
id: tempId,
|
||||
|
||||
@@ -188,7 +188,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<span class="upload-hint"
|
||||
>支持图片、视频、PDF、Word、Excel等文件,单文件不超过 20MB</span
|
||||
>支持图片、视频、PDF、Word、Excel等文件</span
|
||||
>
|
||||
</div>
|
||||
</el-form-item>
|
||||
@@ -585,12 +585,10 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="价格(元)">
|
||||
<el-input
|
||||
<AmountInput
|
||||
v-model="row.price"
|
||||
type="number"
|
||||
step="any"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
placeholder="请输入价格"
|
||||
@change="onSamplePriceChange"
|
||||
/>
|
||||
</el-form-item>
|
||||
@@ -844,7 +842,7 @@
|
||||
class="detail-amount"
|
||||
:class="detail.payStatus === 'yjf' ? 'green' : 'amber'"
|
||||
>
|
||||
¥{{ detail.dueAmount }}
|
||||
{{ fmtMoney(detail.dueAmount) }}
|
||||
</span>
|
||||
<span
|
||||
v-if="detail.payStatus"
|
||||
@@ -896,12 +894,10 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="转账金额(元)">
|
||||
<el-input
|
||||
<AmountInput
|
||||
v-model="detail.transferAmount"
|
||||
type="number"
|
||||
step="any"
|
||||
:min="0"
|
||||
style="width: 100%"
|
||||
placeholder="请输入转账金额"
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="转账时间">
|
||||
@@ -1010,7 +1006,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<span class="upload-hint"
|
||||
>支持图片、视频、PDF、Word、Excel等文件,单文件不超过 20MB</span
|
||||
>支持图片、视频、PDF、Word、Excel等文件</span
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
@@ -1215,6 +1211,8 @@
|
||||
import { fetchEthnicList, type EthnicOption } from '@/api/ethnic'
|
||||
import { useUserStore } from '@/store/modules/user'
|
||||
import { syncFqPaymentDetailRowCount } from '@/utils/protocol-payment-installment'
|
||||
import AmountInput from '@/components/common/amount-input/index.vue'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
import {
|
||||
payModeLabel,
|
||||
newbornSexLabel,
|
||||
@@ -1225,6 +1223,12 @@
|
||||
payStatusLabel
|
||||
} from '@/utils/status-tag-registry'
|
||||
|
||||
/** 金额只读展示:千分位 + ¥ 前缀 */
|
||||
function fmtMoney(v: unknown): string {
|
||||
if (v == null || v === '') return '—'
|
||||
return '¥' + formatMoneyDisplay(v)
|
||||
}
|
||||
|
||||
const userStore = useUserStore()
|
||||
|
||||
const customerId = ref<string | null>(null)
|
||||
@@ -2738,13 +2742,6 @@
|
||||
const file = uploadFile.raw || uploadFile
|
||||
if (!file) return
|
||||
|
||||
const maxSizeMb = 20
|
||||
if (file.size / 1024 / 1024 > maxSizeMb) {
|
||||
ElMessage.error(`文件大小不能超过 ${maxSizeMb}MB`)
|
||||
attachmentUploadRef.value?.clearFiles()
|
||||
return
|
||||
}
|
||||
|
||||
const tempId = `temp_${Date.now()}_${Math.random().toString(36).slice(2, 8)}`
|
||||
formData.attachments.push({
|
||||
id: tempId,
|
||||
@@ -2789,11 +2786,6 @@
|
||||
const file = uploadFile.raw || uploadFile
|
||||
if (!file) return
|
||||
|
||||
const maxSizeMb = 20
|
||||
if (file.size / 1024 / 1024 > maxSizeMb) {
|
||||
ElMessage.error(`文件大小不能超过 ${maxSizeMb}MB`)
|
||||
return
|
||||
}
|
||||
|
||||
const detail = formData.paymentDetails[detailIndex]
|
||||
if (!detail) return
|
||||
|
||||
@@ -454,7 +454,7 @@
|
||||
<div class="data-item"
|
||||
><div class="data-label">保单费用(元)</div
|
||||
><div class="data-value">{{
|
||||
formatMoney(fullmoonInsuranceInfo?.insuranceFee)
|
||||
fmtMoney(fullmoonInsuranceInfo?.insuranceFee)
|
||||
}}</div></div
|
||||
>
|
||||
<div class="data-item"
|
||||
@@ -722,13 +722,13 @@
|
||||
<div class="payment-metric"
|
||||
><div class="pm-label">合同金额(元)</div
|
||||
><div class="pm-value pm-value--amount">{{
|
||||
payment?.contractAmount ? `¥${payment.contractAmount}` : '—'
|
||||
fmtMoney(payment?.contractAmount)
|
||||
}}</div></div
|
||||
>
|
||||
<div class="payment-metric"
|
||||
><div class="pm-label">已收金额(元)</div
|
||||
><div class="pm-value pm-value--amount pm-value--received">{{
|
||||
receivedAmount ? `¥${receivedAmount}` : '—'
|
||||
fmtMoney(receivedAmount)
|
||||
}}</div></div
|
||||
>
|
||||
<template v-if="payment?.payMode === 'dj'">
|
||||
@@ -775,7 +775,7 @@
|
||||
class="pdc-header-amount"
|
||||
:class="payDetailColorClass(String(detail.payStatus || ''))"
|
||||
>
|
||||
{{ detail.dueAmount ? `¥${detail.dueAmount}` : '—' }}
|
||||
{{ fmtMoney(detail.dueAmount) }}
|
||||
</span>
|
||||
</div>
|
||||
<el-tag :type="payStatusTagType(String(detail.payStatus || ''))" size="small">
|
||||
@@ -788,7 +788,7 @@
|
||||
<div class="pdc-info-item">
|
||||
<span class="info-label">应缴费金额(元)</span>
|
||||
<span class="info-value">{{
|
||||
detail.dueAmount ? `¥${detail.dueAmount}` : '—'
|
||||
fmtMoney(detail.dueAmount)
|
||||
}}</span>
|
||||
</div>
|
||||
<div class="pdc-info-item">
|
||||
@@ -800,7 +800,7 @@
|
||||
<div class="pdc-info-item">
|
||||
<span class="info-label">转账金额(元)</span>
|
||||
<span class="info-value">{{
|
||||
detail.transferAmount ? `¥${detail.transferAmount}` : '—'
|
||||
fmtMoney(detail.transferAmount)
|
||||
}}</span>
|
||||
</div>
|
||||
<div class="pdc-info-item">
|
||||
@@ -951,7 +951,7 @@
|
||||
<span
|
||||
class="flow-detail-card__value"
|
||||
:class="payDetailColorClass(String(detail.payStatus || ''))"
|
||||
>{{ detail.refundAmount ? `¥${detail.refundAmount}` : '—' }}</span
|
||||
>{{ fmtMoney(detail.refundAmount) }}</span
|
||||
>
|
||||
</div>
|
||||
<div
|
||||
@@ -1172,6 +1172,7 @@
|
||||
fetchUserList
|
||||
} from '@/api/admin'
|
||||
import { downloadAttachmentFile } from '@/utils/download-attachment'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
import {
|
||||
protocolStatusLabel,
|
||||
protocolStatusTagType,
|
||||
@@ -1358,11 +1359,10 @@
|
||||
return val === '1' ? 'success' : 'info'
|
||||
}
|
||||
|
||||
function formatMoney(val: unknown) {
|
||||
if (val === null || val === undefined || val === '') return '—'
|
||||
const n = Number(val)
|
||||
if (Number.isNaN(n)) return String(val)
|
||||
return `¥${n.toLocaleString('zh-CN', { minimumFractionDigits: 2, maximumFractionDigits: 2 })}`
|
||||
/** 金额只读展示:千分位 + ¥ 前缀,null 显示 — */
|
||||
function fmtMoney(v: unknown): string {
|
||||
if (v == null || v === '') return '—'
|
||||
return '¥' + formatMoneyDisplay(v)
|
||||
}
|
||||
|
||||
function storageCertMakeStatusLabel(makeStatus: string) {
|
||||
|
||||
@@ -302,16 +302,21 @@
|
||||
import { maskIdCard } from '@/utils/mask-sensitive'
|
||||
import { downloadAttachmentFile } from '@/utils/download-attachment'
|
||||
import {
|
||||
formatPaymentAmount,
|
||||
formatPaymentDueDate,
|
||||
payModeLabel,
|
||||
protocolStatusLabel,
|
||||
protocolStatusTagType,
|
||||
transferTypeLabel
|
||||
} from '@/utils/protocol-payment-labels'
|
||||
import { formatMoneyDisplay } from '@/utils/money-format'
|
||||
|
||||
defineOptions({ name: 'CellStorageRefundConfirm' })
|
||||
|
||||
function formatPaymentAmount(v: unknown): string {
|
||||
if (v == null || v === '') return '-'
|
||||
return '¥' + formatMoneyDisplay(v)
|
||||
}
|
||||
|
||||
function formatLocalDate(d: Date): string {
|
||||
const y = d.getFullYear()
|
||||
const m = String(d.getMonth() + 1).padStart(2, '0')
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<span class="upload-hint">支持图片、视频、PDF、Word、Excel等文件,单文件不超过 20MB</span>
|
||||
<span class="upload-hint">支持图片、视频、PDF、Word、Excel等文件</span>
|
||||
</div>
|
||||
</el-form-item>
|
||||
<div class="form-grid-2">
|
||||
@@ -504,13 +504,6 @@
|
||||
const file = uploadFile.raw || uploadFile
|
||||
if (!file) return
|
||||
|
||||
const maxSizeMb = 20
|
||||
if (file.size / 1024 / 1024 > maxSizeMb) {
|
||||
ElMessage.error(`文件大小不能超过 ${maxSizeMb}MB`)
|
||||
certAttachmentUploadRef.value?.clearFiles()
|
||||
return
|
||||
}
|
||||
|
||||
const tempId = `temp_${Date.now()}_${Math.random().toString(36).slice(2, 8)}`
|
||||
certAttachments.value.push({
|
||||
id: tempId,
|
||||
|
||||
Reference in new issue
Block a user