|
|
@@ -1782,22 +1782,27 @@
|
|
|
// 包装维度最小包装单元改变——>总重量
|
|
|
minPackingQuantityChange(row, value, index) {
|
|
|
console.log(value);
|
|
|
- if (row.measureUnit !== 'KG') {
|
|
|
- if (value.replace(/^(0+)|[^\d]+/g, '') > 999999) {
|
|
|
- this.$set(this.productList[index], 'minPackingQuantity', 999999);
|
|
|
- } else {
|
|
|
- this.$set(
|
|
|
- this.productList[index],
|
|
|
- 'minPackingQuantity',
|
|
|
- value.replace(/^(0+)|[^\d]+/g, '')
|
|
|
- );
|
|
|
- }
|
|
|
- } else {
|
|
|
- if (value < 1) {
|
|
|
- this.$set(this.productList[index], 'minPackingQuantity', 1);
|
|
|
- } else if (value > 999999) {
|
|
|
- this.$set(this.productList[index], 'minPackingQuantity', 999999);
|
|
|
- }
|
|
|
+ // if (row.measureUnit !== 'KG') {
|
|
|
+ // if (value.replace(/^(0+)|[^\d]+/g, '') > 999999) {
|
|
|
+ // this.$set(this.productList[index], 'minPackingQuantity', 999999);
|
|
|
+ // } else {
|
|
|
+ // this.$set(
|
|
|
+ // this.productList[index],
|
|
|
+ // 'minPackingQuantity',
|
|
|
+ // value.replace(/^(0+)|[^\d]+/g, '')
|
|
|
+ // );
|
|
|
+ // }
|
|
|
+ // } else {
|
|
|
+ // if (value < 0) {
|
|
|
+ // this.$set(this.productList[index], 'minPackingQuantity', 1);
|
|
|
+ // } else if (value > 999999) {
|
|
|
+ // this.$set(this.productList[index], 'minPackingQuantity', 999999);
|
|
|
+ // }
|
|
|
+ // }
|
|
|
+ if (value < 0) {
|
|
|
+ this.$set(this.productList[index], 'minPackingQuantity', 1);
|
|
|
+ } else if (value > 999999) {
|
|
|
+ this.$set(this.productList[index], 'minPackingQuantity', 999999);
|
|
|
}
|
|
|
if (row.packingQuantity >= 0 && value >= 0) {
|
|
|
this.packNum(row, row.packingQuantity, index);
|