From: Galen Charlton Date: Sun, 19 Jan 2020 20:20:48 +0000 (-0500) Subject: hook up __age, __starts, and __ends operators X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=a184c2472b8bf47db3260b52c14fbb0925196f84;p=working%2FEvergreen.git hook up __age, __starts, and __ends operators Signed-off-by: Galen Charlton --- diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.html b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.html index 3138a5faaa..2d686b5229 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.html +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.html @@ -12,13 +12,17 @@
- + + +
@@ -38,9 +42,10 @@ [idlClass]="searchFieldLinkedClasses[t.field]" (onChange)="t.value1 = $event ? $event.id : ''"> - +
diff --git a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts index f1e962303b..9b9211728d 100644 --- a/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts +++ b/Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts @@ -91,6 +91,14 @@ export class AcqSearchFormComponent implements OnInit, AfterViewInit { term.value2 = ''; term.is_date = false; } + // conditionally clear the search term after changing + // to selected search operators + clearSearchTermValueAfterOpChange(term: AcqSearchTerm) { + if (term.op === '__age') { + term.value1 = ''; + term.value2 = ''; + } + } setOrgUnitSearchValue(org: IdlObject, term: AcqSearchTerm) { if (org == null) {