|
@@ -266,13 +266,23 @@ export default {
|
|
} else if (_value < this.handleMinNumber) {
|
|
} else if (_value < this.handleMinNumber) {
|
|
this.$util.msg(`该商品最小起订量为${this.handleMinNumber}`, 2000)
|
|
this.$util.msg(`该商品最小起订量为${this.handleMinNumber}`, 2000)
|
|
this.productCount = this.handleMinNumber
|
|
this.productCount = this.handleMinNumber
|
|
- } else if (_value % this.handleMinNumber != 0) {
|
|
|
|
- this.$util.msg('购买量必须为起订量的整数倍', 2000)
|
|
|
|
- this.productCount = this.handleMinNumber
|
|
|
|
- } else if (_value > this.handleStock) {
|
|
|
|
- this.productCount = this.handleStock
|
|
|
|
} else {
|
|
} else {
|
|
- this.productCount = e.detail.value
|
|
|
|
|
|
+ if (this.skuProduct.step == 2) {
|
|
|
|
+ if (_value % this.handleMinNumber != 0) {
|
|
|
|
+ this.$util.msg('购买量必须为起订量的整数倍', 2000)
|
|
|
|
+ this.productCount = this.handleMinNumber
|
|
|
|
+ } else if (_value > this.handleStock) {
|
|
|
|
+ this.productCount = this.handleStock
|
|
|
|
+ } else {
|
|
|
|
+ this.productCount = _value
|
|
|
|
+ }
|
|
|
|
+ }else{
|
|
|
|
+ if (_value > this.handleStock) {
|
|
|
|
+ this.productCount = this.handleStock
|
|
|
|
+ } else {
|
|
|
|
+ this.productCount = _value
|
|
|
|
+ }
|
|
|
|
+ }
|
|
}
|
|
}
|
|
},
|
|
},
|
|
handleBuyConfirm(type) {
|
|
handleBuyConfirm(type) {
|