Browse Source

押金小数位数修改

mainqaq 2 years ago
parent
commit
bbeabdf912

+ 2 - 2
src/xt_pages/hospitalStation/components/chargeDialog.vue View File

@@ -303,7 +303,7 @@
303 303
           }
304 304
           // this.form.private_price = parseFloat(this.form.tmp_decimal) + parseFloat(this.form.pay_price)
305 305
 
306
-          this.form.pay_price = (parseFloat(this.form.private_price) * 10000 - parseFloat(this.form.tmp_decimal) * 10000) / 10000
306
+          this.form.pay_price = ((parseFloat(this.form.private_price) * 10000 - parseFloat(this.form.tmp_decimal) * 10000) / 10000).toFixed(2)
307 307
         },
308 308
         changedecimal() {
309 309
           // console.log("this.isshow前",this.isshow)
@@ -325,7 +325,7 @@
325 325
             }
326 326
             // this.form.private_price = parseFloat(this.form.tmp_decimal) + parseFloat(this.form.pay_price)
327 327
             this.tmp_pay = this.form.pay_price
328
-            this.form.pay_price = (parseFloat(this.form.private_price) * 10000 - parseFloat(this.form.tmp_decimal) * 10000) / 10000
328
+            this.form.pay_price = ((parseFloat(this.form.private_price) * 10000 - parseFloat(this.form.tmp_decimal) * 10000) / 10000).toFixed(2)
329 329
           }
330 330
         },
331 331
         //查询用户当前的余额

+ 2 - 2
src/xt_pages/outpatientCharges/components/chargeDialog.vue View File

@@ -220,7 +220,7 @@
220 220
         }
221 221
         // this.form.private_price = parseFloat(this.form.tmp_decimal) + parseFloat(this.form.pay_price)
222 222
 
223
-        this.form.pay_price = (parseFloat(this.form.private_price)*10000 - parseFloat(this.form.tmp_decimal)*10000)/10000
223
+        this.form.pay_price = ((parseFloat(this.form.private_price)*10000 - parseFloat(this.form.tmp_decimal)*10000)/10000).toFixed(2)
224 224
       },
225 225
       changedecimal(){
226 226
         console.log("this.form.dec_way前",this.form.dec_way)
@@ -242,7 +242,7 @@
242 242
           }
243 243
           // this.form.private_price = parseFloat(this.form.tmp_decimal) + parseFloat(this.form.pay_price)
244 244
           this.tmp_pay = this.form.pay_price
245
-          this.form.pay_price = (parseFloat(this.form.private_price)*10000 - parseFloat(this.form.tmp_decimal)*10000)/10000
245
+          this.form.pay_price = ((parseFloat(this.form.private_price)*10000 - parseFloat(this.form.tmp_decimal)*10000)/10000).toFixed(2)
246 246
         }
247 247
       },
248 248
       //查询用户当前的余额