From 3a884c8f20c98a09e2282487a85139119a9e613b Mon Sep 17 00:00:00 2001 From: Bill Erickson Date: Mon, 3 Dec 2018 11:18:13 -0500 Subject: [PATCH] Hide location selector when searching root org Signed-off-by: Bill Erickson --- Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.ts b/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.ts index b339da2c1f..eb7608665e 100644 --- a/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/catalog/search-form.component.ts @@ -94,7 +94,10 @@ export class SearchFormComponent implements OnInit, AfterViewInit { // TODO: is this how we avoid displaying too many locations? const org = this.searchContext.searchOrg; - if (org.id() === this.org.root().id()) { return; } + if (org.id() === this.org.root().id()) { + this.copyLocations = []; + return; + } this.cat.fetchCopyLocations(org).then(() => this.copyLocations = this.cat.copyLocations -- 2.11.0