From: Galen Charlton Date: Wed, 8 Jul 2020 21:07:49 +0000 (-0400) Subject: ensure that forms get result upon navigating to same tab via menu item X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=034245239ab9c433db0d942c817644abc48b1113;p=working%2FEvergreen.git ensure that forms get result upon navigating to same tab via menu item Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts index 43e3edbde1..964ae07f81 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search.component.ts @@ -29,7 +29,7 @@ export class AcqSearchComponent implements OnInit, AfterViewInit, OnDestroy { @ViewChildren(LineitemResultsComponent) liResults: QueryList; @ViewChildren(PurchaseOrderResultsComponent) poResults: QueryList; @ViewChildren(InvoiceResultsComponent) invResults: QueryList; - @ViewChildren(PicklistResultsComponent) plResults: QueryList; + @ViewChildren(PicklistResultsComponent) plResults: QueryList; previousUrl: string = null; public destroyed = new Subject(); @@ -88,15 +88,19 @@ export class AcqSearchComponent implements OnInit, AfterViewInit, OnDestroy { switch (newTab) { case 'lineitems': this.liResults.toArray()[0].gridSource.reset(); + this.liResults.toArray()[0].acqSearchForm.ngOnInit(); break; case 'purchaseorders': this.poResults.toArray()[0].gridSource.reset(); + this.poResults.toArray()[0].acqSearchForm.ngOnInit(); break; case 'invoices': this.invResults.toArray()[0].gridSource.reset(); + this.invResults.toArray()[0].acqSearchForm.ngOnInit(); break; case 'selectionlists': this.plResults.toArray()[0].gridSource.reset(); + this.plResults.toArray()[0].acqSearchForm.ngOnInit(); break; } } diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.html b/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.html index 5436176621..6f562e1440 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.html @@ -1,4 +1,4 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.ts index f921ac04fd..0f37552afb 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.ts @@ -24,6 +24,7 @@ export class InvoiceResultsComponent implements OnInit { @Input() initialSearchTerms: AcqSearchTerm[] = []; gridSource: GridDataSource; + @ViewChild('acqSearchForm', { static: true}) acqSearchForm: AcqSearchFormComponent; @ViewChild('acqSearchInvoicesGrid', { static: true }) invoiceResultsGrid: GridComponent; @ViewChild('printfail', { static: true }) private printfail: AlertDialogComponent; diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.html b/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.html index 4d16efcf40..142066cbb2 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.html @@ -1,4 +1,4 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.ts index d2e6757aaa..e1c7c5f894 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.ts @@ -21,6 +21,7 @@ export class LineitemResultsComponent implements OnInit { @Input() initialSearchTerms: AcqSearchTerm[] = []; gridSource: GridDataSource; + @ViewChild('acqSearchForm', { static: true}) acqSearchForm: AcqSearchFormComponent; @ViewChild('acqSearchLineitemsGrid', { static: true }) lineitemResultsGrid: GridComponent; cellTextGenerator: GridCellTextGenerator; diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.html b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.html index a6b46637a3..1ca2e47985 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.html @@ -1,4 +1,4 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.ts index 4eb8413a56..2bf19ee1f8 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.ts @@ -28,6 +28,7 @@ export class PicklistResultsComponent implements OnInit { @Input() initialSearchTerms: AcqSearchTerm[] = []; gridSource: GridDataSource; + @ViewChild('acqSearchForm', { static: true}) acqSearchForm: AcqSearchFormComponent; @ViewChild('acqSearchPicklistsGrid', { static: true }) picklistResultsGrid: GridComponent; @ViewChild('picklistCreateDialog', { static: true }) picklistCreateDialog: PicklistCreateDialogComponent; @ViewChild('picklistCloneDialog', { static: true }) picklistCloneDialog: PicklistCloneDialogComponent; diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.html b/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.html index b1413c3712..03816e48a8 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.html @@ -1,4 +1,4 @@ - diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.ts index 66413b9148..4b02c76e63 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.ts @@ -21,6 +21,7 @@ export class PurchaseOrderResultsComponent implements OnInit { @Input() initialSearchTerms: AcqSearchTerm[] = []; gridSource: GridDataSource; + @ViewChild('acqSearchForm', { static: true}) acqSearchForm: AcqSearchFormComponent; @ViewChild('acqSearchPurchaseOrdersGrid', { static: true }) purchaseOrderResultsGrid: GridComponent; cellTextGenerator: GridCellTextGenerator;