Browse Source

变更令

ZaiZai 1 năm trước cách đây
mục cha
commit
bee433e351
1 tập tin đã thay đổi với 13 bổ sung1 xóa
  1. 13 1
      src/views/debit-pay/admin/components/middlepay/addModal.vue

+ 13 - 1
src/views/debit-pay/admin/components/middlepay/addModal.vue

@@ -95,7 +95,7 @@
                                 <hc-table-input v-model="row.currentMeterTotal" @blur="currentMeterTotalBlur(row)" />
                             </template>
                             <template #containChangeTotal="{ row }">
-                                <hc-table-input v-model="row.containChangeTotal" />
+                                <hc-table-input v-model="row.containChangeTotal" @blur="containChangeTotalBlur(row)" />
                             </template>
                             <template #currentMeterMoney="{ row }">
                                 <hc-table-input v-model="row.currentMeterMoney" disabled />
@@ -369,6 +369,18 @@ const currentMeterTotalBlur = (row) => {
     })
 }
 
+//计算含变更数量
+const containChangeTotalBlur = (row) => {
+    let val = row.containChangeTotal
+    const isMeter = isNumberReg(val)
+    if (isNullES(val) || !isMeter) {
+        val = 0
+    }
+    nextTick(() => {
+        row.containChangeTotal = val
+    })
+}
+
 //判断是否红色
 const addTableRowStyle = ({ row }) => {
     if (row.allMeterTotal > row.resolveTotal) {