Payment bug fixed

This commit is contained in:
Vion
2022-01-23 21:10:24 +08:00
parent c5e5978615
commit 560d9b5c1c
7 changed files with 33 additions and 11 deletions

View File

@@ -274,6 +274,15 @@ export default {
// });
},
plus(num, index) {
let leftAllotment = this.cartData[index].leftAllotment;
if(this.cartData[index].buyCount >= leftAllotment) {
this.$message({
type: "error",
message: "已达到本品最大购买上限",
});
return;
}
this.cartData[index].buyCount =
parseInt(this.cartData[index].buyCount) + 1;
},