|
|
@@ -7,7 +7,7 @@
|
|
|
row-key="code"
|
|
|
custom-class="ele-dialog-form"
|
|
|
title="生产前准备"
|
|
|
- @closed="onClose"
|
|
|
+ :before-close="onClose"
|
|
|
append-to-body
|
|
|
:maxable="true"
|
|
|
>
|
|
|
@@ -229,7 +229,10 @@
|
|
|
</ele-modal>
|
|
|
|
|
|
<kitting-complete ref="kittingCompleteRef"></kitting-complete>
|
|
|
- <auxiliary-material ref="auxiliaryMaterialRef"></auxiliary-material>
|
|
|
+ <auxiliary-material
|
|
|
+ ref="auxiliaryMaterialRef"
|
|
|
+ @success="updateStatus"
|
|
|
+ ></auxiliary-material>
|
|
|
</ele-modal>
|
|
|
</template>
|
|
|
|
|
|
@@ -520,14 +523,14 @@
|
|
|
this.visible = true;
|
|
|
this.itemData = item;
|
|
|
this.preReleaseList = [];
|
|
|
- if (item.preRelease.length) {
|
|
|
- this.preReleaseList = item.preRelease;
|
|
|
- } else {
|
|
|
+ // if (item.preRelease.length) {
|
|
|
+ // this.preReleaseList = item.preRelease;
|
|
|
+ // } else {
|
|
|
if (item.id && this.type == 'plan') {
|
|
|
this.completenessCheck(item.id);
|
|
|
} else if (this.type == 'order') {
|
|
|
this.completenessCheck(item.productionPlanId, item.id);
|
|
|
- }
|
|
|
+ // }
|
|
|
}
|
|
|
},
|
|
|
|
|
|
@@ -535,6 +538,7 @@
|
|
|
|
|
|
onClose() {
|
|
|
this.visible = false;
|
|
|
+ this.$emit('update');
|
|
|
},
|
|
|
|
|
|
handleClose() {
|
|
|
@@ -615,7 +619,8 @@
|
|
|
const list = [this.itemData];
|
|
|
this.$refs.kittingCompleteRef.open(list);
|
|
|
} else if (item.preType == '2') {
|
|
|
- this.$refs.auxiliaryMaterialRef.open(this.itemData);
|
|
|
+ const data = this.preReleaseList.find((it) => it.preType == 2);
|
|
|
+ this.$refs.auxiliaryMaterialRef.open(this.itemData, data);
|
|
|
}
|
|
|
},
|
|
|
|
|
|
@@ -711,6 +716,12 @@
|
|
|
});
|
|
|
},
|
|
|
|
|
|
+ updateStatus() {
|
|
|
+ const index = this.preReleaseList.findIndex((it) => it.preType == 2);
|
|
|
+
|
|
|
+ this.$set(this.preReleaseList[index], 'statusStr', '齐套');
|
|
|
+ },
|
|
|
+
|
|
|
async batchConfirm() {
|
|
|
const valid = await this.$refs.form.validate().catch(() => false);
|
|
|
if (!valid) return;
|