|
|
@@ -819,9 +819,10 @@
|
|
|
} else {
|
|
|
if(this.factoryList.find(item => item.id == this.userInfo.factoryId)?.id) {
|
|
|
this.factoryId = this.userInfo.factoryId;
|
|
|
- if(this.allocateId == 1) {
|
|
|
- this.params.targetFactoriesId = this.factoryId
|
|
|
- }
|
|
|
+ this.params.targetFactoriesId = this.factoryId
|
|
|
+ // if(this.allocateId == 1) {
|
|
|
+ // this.params.targetFactoriesId = this.factoryId
|
|
|
+ // }
|
|
|
this.getTreeData(this.factoryId)
|
|
|
}
|
|
|
}
|
|
|
@@ -988,14 +989,21 @@
|
|
|
this.getTreeData();
|
|
|
},
|
|
|
targetFactoryChange() {
|
|
|
- this.reset();
|
|
|
- this.getTreeData();
|
|
|
+ // this.reset();
|
|
|
+ // this.getTreeData();
|
|
|
},
|
|
|
search() {
|
|
|
return new Promise((resolve, reject) => {
|
|
|
// 重置错误标志
|
|
|
this.searchState.hasError = false;
|
|
|
|
|
|
+ if(!this.params.targetFactoriesId){
|
|
|
+ this.searchState.hasError = true;
|
|
|
+ const errorMsg = '调入工厂不能为空';
|
|
|
+ this.$message.error(errorMsg);
|
|
|
+ return reject(new Error(errorMsg));
|
|
|
+ }
|
|
|
+
|
|
|
if(!this.params.inWarehouseId){
|
|
|
this.searchState.hasError = true;
|
|
|
const errorMsg = '调入仓库不能为空';
|