|
@@ -2072,8 +2072,8 @@
|
|
|
|
|
|
|
|
async getReduceLossParam() {
|
|
async getReduceLossParam() {
|
|
|
if (this.reduceLossForm.quantity) {
|
|
if (this.reduceLossForm.quantity) {
|
|
|
- if (Number(this.reduceLossData.feedQuantity) == 0) {
|
|
|
|
|
- this.$message.warning('减损数不能为0');
|
|
|
|
|
|
|
+ if (Number(this.reduceLossData.feedQuantity) <= 0) {
|
|
|
|
|
+ this.$message.warning('增加数不能小于0');
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -2081,7 +2081,7 @@
|
|
|
Number(this.reduceLossData.feedQuantity) <
|
|
Number(this.reduceLossData.feedQuantity) <
|
|
|
Number(this.reduceLossForm.quantity)
|
|
Number(this.reduceLossForm.quantity)
|
|
|
) {
|
|
) {
|
|
|
- this.$message.warning('减损数不能大于数量');
|
|
|
|
|
|
|
+ this.$message.warning('增加数不能大于数量');
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -2100,20 +2100,24 @@
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
if (dataList.length != 0) {
|
|
if (dataList.length != 0) {
|
|
|
- this.refreshReduceLossData(dataList);
|
|
|
|
|
|
|
+ this.refreshReduceLossData(dataList,'add');
|
|
|
}
|
|
}
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
this.reduceLossVisible = false;
|
|
this.reduceLossVisible = false;
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- refreshReduceLossData(list) {
|
|
|
|
|
|
|
+ refreshReduceLossData(list,type) {
|
|
|
const number = this.sub(
|
|
const number = this.sub(
|
|
|
Number(this.list[this.reduceLossIndex].feedQuantity),
|
|
Number(this.list[this.reduceLossIndex].feedQuantity),
|
|
|
Number(this.reduceLossForm.quantity)
|
|
Number(this.reduceLossForm.quantity)
|
|
|
);
|
|
);
|
|
|
- this.list[this.reduceLossIndex].extInfo.sourceQuantity = number;
|
|
|
|
|
- this.list[this.reduceLossIndex].feedQuantity = number;
|
|
|
|
|
|
|
+
|
|
|
|
|
+ if(!type) {
|
|
|
|
|
+ this.list[this.reduceLossIndex].extInfo.sourceQuantity = number;
|
|
|
|
|
+ this.list[this.reduceLossIndex].feedQuantity = number;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
this.list[this.reduceLossIndex].extInfo.newWeight =
|
|
this.list[this.reduceLossIndex].extInfo.newWeight =
|
|
|
(Number(this.list[this.reduceLossIndex].extInfo.newWeight) * 100000) /
|
|
(Number(this.list[this.reduceLossIndex].extInfo.newWeight) * 100000) /
|
|
|
100000 -
|
|
100000 -
|