|
|
@@ -995,13 +995,20 @@
|
|
|
this.searchState.hasError = false;
|
|
|
|
|
|
if(!this.params.inWarehouseId){
|
|
|
-
|
|
|
this.searchState.hasError = true;
|
|
|
const errorMsg = '调入仓库不能为空';
|
|
|
this.$message.error(errorMsg);
|
|
|
return reject(new Error(errorMsg));
|
|
|
}
|
|
|
|
|
|
+ // 检查是否存在quantity小于等于0或无效的项
|
|
|
+ if(this.tableData.some((item) => !item.quantity || item.quantity <= 0)) {
|
|
|
+ this.searchState.hasError = true;
|
|
|
+ const errorMsg = '调拨数量不能为0';
|
|
|
+ this.$message.error(errorMsg);
|
|
|
+ return reject(new Error(errorMsg));
|
|
|
+ }
|
|
|
+
|
|
|
if (this.allocateId == 1) {
|
|
|
// 库内调拨
|
|
|
if (this.params.inFreightId && this.params.outFreightId) {
|