版本1.3.4
This commit is contained in:
@@ -84,7 +84,6 @@
|
||||
}
|
||||
},
|
||||
created() {
|
||||
console.log(this.oilList)
|
||||
this.initForm()
|
||||
},
|
||||
watch: {
|
||||
@@ -116,7 +115,7 @@
|
||||
|
||||
},
|
||||
initForm() {
|
||||
if (this.oilList) {
|
||||
if (this.oilList[0]) {
|
||||
this.selected = this.oilList[0]
|
||||
}
|
||||
},
|
||||
@@ -128,21 +127,13 @@
|
||||
gunId: this.gunId + 1,
|
||||
realPay: this.money.realPay
|
||||
}
|
||||
console.log('被选中的', data5)
|
||||
this.$emit('confirmVol', data5)
|
||||
},
|
||||
calcMoney(e) {
|
||||
// var vol;
|
||||
// vol = e.detail.value.replace(/^(\-)*(\d+)\.(\d\d).*$/,'$1$2.$3');
|
||||
// this.vol = vol
|
||||
|
||||
this.price = this.selected.xkPrice ? this.selected.xkPrice : this.selected.lvPrice
|
||||
this.money.total = this.vol * this.selected.standardPrice
|
||||
// this.money.discount = this.money.total - this.vol * (this.selected.standardPrice - this.price)
|
||||
// this.money.realPay = (this.money.total - this.money.discount).toFixed(2)
|
||||
this.money.discount = this.vol * (this.selected.standardPrice - this.price)
|
||||
this.money.realPay = (this.money.total - this.money.discount).toFixed(2)
|
||||
console.log('总金额', '折扣', '实际支付')
|
||||
}
|
||||
},
|
||||
filters: {
|
||||
|
||||
Reference in New Issue
Block a user