Commit 01503792 authored by 我在何方's avatar 我在何方

收款单详情优化2.2

parent c09c8a70
...@@ -838,12 +838,14 @@ export default { ...@@ -838,12 +838,14 @@ export default {
this.addForm.amount = '' this.addForm.amount = ''
this.$modal.msgError(this.$t('输入金额不对')); this.$modal.msgError(this.$t('输入金额不对'));
}else{ }else{
if(this.addForm&&this.addForm.amount&&this.addForm.amount.indexOf('.')>-1){ // console.log(this.addForm.amount)
pointArr = this.addForm.amount.split('.') // this.addForm.amount = this.addForm.amount.toFixed(2)
// if(this.addForm&&this.addForm.amount&&this.addForm.amount.indexOf('.')>-1){
pointArr = this.addForm.amount.toString().split('.')
if(pointArr.length>1&&pointArr[1]){ if(pointArr.length>1&&pointArr[1]){
this.addForm.amount =Math.round(this.addForm.amount*100)/100 this.addForm.amount =Math.round(this.addForm.amount*100)/100
} }
} // }
} }
this.$set(this.addForm, 'writeOffAmount', NP.times(this.addForm.rate || 0, this.addForm.amount || 0)) this.$set(this.addForm, 'writeOffAmount', NP.times(this.addForm.rate || 0, this.addForm.amount || 0))
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment