Update Item.vue

There is an error in calculating maxDiscount. 
maxDiscount = item.price * item.quantity
This commit is contained in:
Dj KHIREDDINE
2021-02-02 19:23:32 +01:00
committed by GitHub
parent 7b95ccb5fc
commit 739efcce79

View File

@ -301,7 +301,7 @@ export default {
set: function (newValue) {
if (parseFloat(newValue) > 0) {
this.item.price = Math.round(newValue * 100)
this.maxDiscount = this.item.price
this.maxDiscount = this.item.price * this.item.quantity
} else {
this.item.price = newValue
}