|
|
@@ -1397,7 +1397,16 @@
|
|
|
},
|
|
|
|
|
|
productionSchedulingSuccess(data) {
|
|
|
- // data.productionPlanIds = this.selection.map((i) => i.id);
|
|
|
+ const missingBom = this.selection.filter((item) => !item.bomCategoryId);
|
|
|
+ if (this.selection.length > 0 && missingBom.length > 0) {
|
|
|
+ const codes = missingBom
|
|
|
+ .map((item) => item.code)
|
|
|
+ .filter((c) => c != null && c !== '')
|
|
|
+ .join('、');
|
|
|
+ return this.$message.warning(
|
|
|
+ `计划编码【${codes || '未知'}】没有定义BOM,请先添加BOM!`
|
|
|
+ );
|
|
|
+ }
|
|
|
this.$refs.newFactoryProductionSchedulingRef.open({
|
|
|
selectedPlans: this.selection,
|
|
|
allPlans: this.allPlanTableData
|