update 'set as default seach buttons' to include search type
authorGalen Charlton <gmc@equinoxinitiative.org>
Sat, 25 Jan 2020 13:27:08 +0000 (08:27 -0500)
committerGalen Charlton <gmc@equinoxinitiative.org>
Sat, 25 Jan 2020 13:27:08 +0000 (08:27 -0500)
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.html
Open-ILS/src/eg2/src/app/staff/acq/search/acq-search-form.component.ts
Open-ILS/src/eg2/src/app/staff/acq/search/invoice-results.component.html
Open-ILS/src/eg2/src/app/staff/acq/search/lineitem-results.component.html
Open-ILS/src/eg2/src/app/staff/acq/search/picklist-results.component.html
Open-ILS/src/eg2/src/app/staff/acq/search/purchase-order-results.component.html

index 9b22f46..4f4221e 100644 (file)
     <div class="col-lg-2">
       <button class="form-control btn btn-success" (click)="submitSearch()" type="submit" i18n>Search</button>
     </div>
-    <div class="col-lg-8"></div>
-    <div class="col-lg-2">
-      <button class="form-control btn btn-primary" (click)="saveSearchAsDefault()" type="button" i18n>Set As Default Search</button>
+    <div class="col-lg-7"></div>
+    <div class="col-lg-3">
+      <button class="form-control btn btn-primary" (click)="saveSearchAsDefault()" type="button" i18n>Set As Default {{searchTypeLabel}} Search</button>
     </div>
   </div>
 </form>
index 5125c06..1a2c685 100644 (file)
@@ -17,6 +17,7 @@ export class AcqSearchFormComponent implements OnInit, AfterViewInit {
 
     @Input() initialSearchTerms: AcqSearchTerm[] = [];
     @Input() defaultSearchSetting = '';
+    @Input() searchTypeLabel = '';
 
     @Output() searchSubmitted = new EventEmitter<AcqSearch>();
 
index e85c382..ee5dc0e 100644 (file)
@@ -1,4 +1,5 @@
-<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms" defaultSearchSetting="eg.acq.search.default.invoices"></eg-acq-search-form>
+<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms"
+  i18n-searchTypeLabel searchTypeLabel="Invoice" defaultSearchSetting="eg.acq.search.default.invoices"></eg-acq-search-form>
 
 <ng-template #inv_identTmpl let-invoice="row">
   <a href="/eg/staff/acq/legacy/invoice/view/{{invoice.id()}}"
index 18eee2c..a4c90ad 100644 (file)
@@ -1,4 +1,5 @@
-<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms" defaultSearchSetting="eg.acq.search.default.lineitems"></eg-acq-search-form>
+<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms"
+  i18n-searchTypeLabel searchTypeLabel="Line Item" defaultSearchSetting="eg.acq.search.default.lineitems"></eg-acq-search-form>
 
 <ng-template #idTmpl let-lineitem="row">
   <a *ngIf="lineitem.purchase_order()" href="/eg/staff/acq/legacy/po/view/{{lineitem.purchase_order()}}?focus_li={{lineitem.id()}}"
index 9020e8d..9650811 100644 (file)
@@ -1,4 +1,5 @@
-<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms" defaultSearchSetting="eg.acq.search.default.selectionlists"></eg-acq-search-form>
+<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms"
+  i18n-searchTypeLabel searchTypeLabel="Selection List" defaultSearchSetting="eg.acq.search.default.selectionlists"></eg-acq-search-form>
 
 <eg-string #createSelectionListString i18n-text text="Selection List Created">
 </eg-string>
index 6ee6bda..b3c2528 100644 (file)
@@ -1,4 +1,5 @@
-<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms" defaultSearchSetting="eg.acq.search.default.purchaseorders"></eg-acq-search-form>
+<eg-acq-search-form (searchSubmitted)="doSearch($event)" [initialSearchTerms]="initialSearchTerms"
+  i18n-searchTypeLabel searchTypeLabel="Purchase Order" defaultSearchSetting="eg.acq.search.default.purchaseorders"></eg-acq-search-form>
 
 <ng-template #nameTmpl let-purchaseorder="row">
   <a href="/eg/staff/acq/legacy/po/view/{{purchaseorder.id()}}"