From 1eca2968de55b8a6541dae4d0f8dec21df1e1df1 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Wed, 26 May 2021 21:37:24 +0000 Subject: [PATCH] --- .../work-order-item-part-requests.vue | 100 +++++++++--------- ayanova/src/components/work-order-items.vue | 22 +++- 2 files changed, 67 insertions(+), 55 deletions(-) diff --git a/ayanova/src/components/work-order-item-part-requests.vue b/ayanova/src/components/work-order-item-part-requests.vue index 8819b845..a25bd5ca 100644 --- a/ayanova/src/components/work-order-item-part-requests.vue +++ b/ayanova/src/components/work-order-item-part-requests.vue @@ -5,20 +5,16 @@ - - - $ayiPlus - - {{ $ay.t("New") }} - $ayiTrashAlt @@ -146,39 +142,39 @@ export default { } }, methods: { - warehouseChange(newName) { - this.value.items[this.activeWoItemIndex].partRequests[ - this.activeItemIndex - ].partWarehouseViz = newName; - }, - partChange(newName) { - this.value.items[this.activeWoItemIndex].partRequests[ - this.activeItemIndex - ].partViz = newName; - }, - newItem() { - let newIndex = this.value.items[this.activeWoItemIndex].partRequests - .length; + // warehouseChange(newName) { + // this.value.items[this.activeWoItemIndex].partRequests[ + // this.activeItemIndex + // ].partWarehouseViz = newName; + // }, + // partChange(newName) { + // this.value.items[this.activeWoItemIndex].partRequests[ + // this.activeItemIndex + // ].partViz = newName; + // }, + // newItem() { + // let newIndex = this.value.items[this.activeWoItemIndex].partRequests + // .length; - this.value.items[this.activeWoItemIndex].partRequests.push({ - id: 0, - concurrency: 0, - userId: null, - description: null, - serials: null, - partId: null, - partWarehouseId: null, - quantity: 1, - received: null, - purchaseOrderItemId: null, - isDirty: true, - workOrderItemId: this.value.items[this.activeWoItemIndex].id, - uid: Date.now() //used for error tracking / display - }); - this.$emit("change"); - this.selectedRow = [{ index: newIndex }]; - this.activeItemIndex = newIndex; - }, + // this.value.items[this.activeWoItemIndex].partRequests.push({ + // id: 0, + // concurrency: 0, + // userId: null, + // description: null, + // serials: null, + // partId: null, + // partWarehouseId: null, + // quantity: 1, + // received: null, + // purchaseOrderItemId: null, + // isDirty: true, + // workOrderItemId: this.value.items[this.activeWoItemIndex].id, + // uid: Date.now() //used for error tracking / display + // }); + // this.$emit("change"); + // this.selectedRow = [{ index: newIndex }]; + // this.activeItemIndex = newIndex; + // }, unDeleteItem() { this.value.items[this.activeWoItemIndex].partRequests[ this.activeItemIndex @@ -209,15 +205,15 @@ export default { form() { return window.$gz.form; }, - fieldValueChanged(ref) { - if (!this.formState.loading && !this.formState.readonly) { - //flag this record dirty so it gets picked up by save - this.value.items[this.activeWoItemIndex].partRequests[ - this.activeItemIndex - ].isDirty = true; - window.$gz.form.fieldValueChanged(this.pvm, ref); - } - }, + // fieldValueChanged(ref) { + // if (!this.formState.loading && !this.formState.readonly) { + // //flag this record dirty so it gets picked up by save + // this.value.items[this.activeWoItemIndex].partRequests[ + // this.activeItemIndex + // ].isDirty = true; + // window.$gz.form.fieldValueChanged(this.pvm, ref); + // } + // }, itemRowClasses: function(item) { let ret = ""; const isDeleted = @@ -386,9 +382,9 @@ export default { showTable: function() { return this.value.items[this.activeWoItemIndex].partRequests.length > 1; }, - canAdd: function() { - return this.pvm.rights.change && this.pvm.subRights.partRequests.create; - }, + // canAdd: function() { + // return this.pvm.rights.change && this.pvm.subRights.partRequests.create; + // }, canDelete: function() { return ( this.activeItemIndex != null && diff --git a/ayanova/src/components/work-order-items.vue b/ayanova/src/components/work-order-items.vue index 2fbd379c..13b824e7 100644 --- a/ayanova/src/components/work-order-items.vue +++ b/ayanova/src/components/work-order-items.vue @@ -396,7 +396,7 @@ @@ -409,7 +409,21 @@ /> - + + +