diff --git a/src/views/contract/components/printPaymentForm.vue b/src/views/contract/components/printPaymentForm.vue index 76974b7..f3ed201 100644 --- a/src/views/contract/components/printPaymentForm.vue +++ b/src/views/contract/components/printPaymentForm.vue @@ -799,7 +799,17 @@ export default { console.log('textarea fieldName:' + fieldName + "--- " + input.value) } else { // 对于其他类型的输入,直接设置value - input.setAttribute('value', input.value) + // 如果是资金划拨审批单,为特定字段设置默认值 + if (this.getForms && this.getForms.includes('资金划拨审批单')) { + const amountFields = ['contractAmount', 'auditAmount', 'previousPayment', 'currentPayment', 'currentDuePayment', 'totalPaid', 'totalPlanned'] + if (amountFields.includes(fieldName) && (!input.value || input.value === '')) { + input.setAttribute('value', '0') + } else { + input.setAttribute('value', input.value) + } + } else { + input.setAttribute('value', input.value) + } } } }