From 926dcd60988fa0ca7b7d50209ae6151fac5303b4 Mon Sep 17 00:00:00 2001 From: John Cardinal Date: Tue, 6 Jul 2021 19:51:32 +0000 Subject: [PATCH] --- ayanova/devdocs/todo.txt | 9 +-- .../src/components/work-order-item-units.vue | 58 +++++++++---------- 2 files changed, 34 insertions(+), 33 deletions(-) diff --git a/ayanova/devdocs/todo.txt b/ayanova/devdocs/todo.txt index 8043ff19..d3fb1f02 100644 --- a/ayanova/devdocs/todo.txt +++ b/ayanova/devdocs/todo.txt @@ -420,7 +420,8 @@ todo: many biz objects are not using new PUT methodology -CURRENTLY DOING: +CURRENTLY DOING: + todo 2-3: cases 3501 / 3867 both - bulk add units by tag Do this as a separate popup dialog accessible from woitemunits list menu @@ -1245,10 +1246,10 @@ MID CENTURY MODERN TUNES - https://www.allmusic.com/album/ultra-lounge-vol-14-bo BUILD CHANGES OF NOTE -BUILD 112 +BUILD 113 -- All object edit forms new record page is now *not* added to the browser navigation history so creating new record then hitting back will return user to page immediately before new record, not new record itself -- Fixed regression with report designer where it was failing to set the report type resulting in reports being saved with NOType rather than actual type +- WorkorderItemUnits "Add multiple Units" feature implemented. Accessible from context menu in woitemunits list header in workorder +- Fixed regression with workorderitem descendant report data include all children where it was not populating the woitem properly diff --git a/ayanova/src/components/work-order-item-units.vue b/ayanova/src/components/work-order-item-units.vue index f7c8d95e..c12bb1f8 100644 --- a/ayanova/src/components/work-order-item-units.vue +++ b/ayanova/src/components/work-order-item-units.vue @@ -249,7 +249,7 @@ v-model="selectedBulkUnits" :headers="bulkUnitTableHeaders" :items="availableBulkUnits" - class="elevation-4" + class="my-10" :disable-filtering="true" hide-default-footer :no-data-text="$ay.t('NoData')" @@ -379,33 +379,24 @@ export default { this.availableBulkUnits = res.data; } }, - addSelectedBulkUnits() { if (this.selectedBulkUnits.length > 0) { let newIndex = this.value.items[this.activeWoItemIndex].units.length; - res.data.items.forEach(z => { + this.selectedBulkUnits.forEach(z => { newIndex++; - // this.value.items[this.activeWoItemIndex].parts.push({ - // id: 0, - // concurrency: 0, - // userId: null, - // description: null, - // serials: null, - // partId: z.partId, - // partWarehouseId: this.selectedPartWarehouse, - // quantity: z.quantity, - // taxPartSaleId: null, - // price: 0, - // priceOverride: null, - // cost: 0, - // listPrice: 0, - // isDirty: true, - // workOrderItemId: this.value.items[this.activeWoItemIndex].id, - // uid: Date.now(), - // partWarehouseViz: null, - // partViz: z.partViz, - // taxCodeViz: null - // }); + this.value.items[this.activeWoItemIndex].units.push({ + id: 0, + concurrency: 0, + wiki: null, + customFields: "{}", + tags: [], + notes: null, + unitId: z.unitId, //zero to break rule on new + isDirty: true, + workOrderItemId: this.value.items[this.activeWoItemIndex].id, + uid: Date.now(), + unitViz: z.unitSerial + }); }); this.$emit("change"); this.selectedRow = [{ index: newIndex }]; @@ -420,6 +411,19 @@ export default { }, newItem() { let newIndex = this.value.items[this.activeWoItemIndex].units.length; + // { + // "0": { + // "id": 53, + // "concurrency": 9586762, + // "notes": "Aut modi molestias molestiae ipsa id.", + // "wiki": null, + // "customFields": null, + // "tags": [], + // "unitId": 4, + // "unitViz": "83429560", + // "workOrderItemId": 22 + // } + // } this.value.items[this.activeWoItemIndex].units.push({ id: 0, @@ -427,12 +431,8 @@ export default { wiki: null, customFields: "{}", tags: [], - userId: null, + notes: null, unitId: 0, //zero to break rule on new - estimatedQuantity: 0, - startDate: null, - stopDate: null, - serviceRateId: null, isDirty: true, workOrderItemId: this.value.items[this.activeWoItemIndex].id, uid: Date.now(),