This commit is contained in:
@@ -385,6 +385,23 @@ export default {
|
||||
this.activeItemIndex
|
||||
].requestAmountViz;
|
||||
if (requestQuantity != null && requestQuantity > 0) {
|
||||
let selectedPartWarehouse = this.$refs[
|
||||
`Items[${this.activeWoItemIndex}].parts[${this.activeItemIndex}].partWarehouseId`
|
||||
].getFullSelectionValue();
|
||||
if (
|
||||
selectedPartWarehouse != null &&
|
||||
selectedPartWarehouse.name != null
|
||||
) {
|
||||
selectedPartWarehouse = selectedPartWarehouse.name;
|
||||
}
|
||||
|
||||
let selectedPart = this.$refs[
|
||||
`Items[${this.activeWoItemIndex}].parts[${this.activeItemIndex}].partId`
|
||||
].getFullSelectionValue();
|
||||
if (selectedPart != null && selectedPart.name != null) {
|
||||
selectedPart = selectedPart.name;
|
||||
}
|
||||
|
||||
//change the partquantity
|
||||
this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
@@ -399,15 +416,11 @@ export default {
|
||||
partId: this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
].partId,
|
||||
partViz: this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
].partViz,
|
||||
partViz: selectedPart,
|
||||
partWarehouseId: this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
].partWarehouseId,
|
||||
partWarehouseViz: this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
].partWarehouseViz,
|
||||
partWarehouseViz: selectedPartWarehouse,
|
||||
quantity: requestQuantity,
|
||||
isDirty: true,
|
||||
workOrderItemId: this.value.items[this.activeWoItemIndex].id,
|
||||
@@ -415,7 +428,7 @@ export default {
|
||||
});
|
||||
this.$emit("change");
|
||||
|
||||
//clear the error but leave dirty
|
||||
//clear the error but leave dirty and let user save it
|
||||
this.value.items[this.activeWoItemIndex].parts[
|
||||
this.activeItemIndex
|
||||
].requestAmountViz = null;
|
||||
@@ -423,7 +436,6 @@ export default {
|
||||
this.fieldValueChanged(`Items[${this.activeWoItemIndex}].parts[
|
||||
${this.activeItemIndex}
|
||||
].quantity`);
|
||||
//let user save it
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user