LP1816475: Add a Create Reservation button to the Create Reservation screen
authorJane Sandberg <sandbej@linnbenton.edu>
Mon, 9 Sep 2019 12:11:15 +0000 (05:11 -0700)
committerGalen Charlton <gmc@equinoxinitiative.org>
Mon, 21 Oct 2019 19:42:52 +0000 (15:42 -0400)
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/eg2/src/app/share/grid/grid-toolbar.component.ts
Open-ILS/src/eg2/src/app/staff/booking/create-reservation.component.html

index ae55c56..b9c1d30 100644 (file)
@@ -78,7 +78,7 @@ export class GridToolbarComponent implements OnInit {
 
     performButtonAction(button: GridToolbarButton) {
         const rows = this.gridContext.getSelectedRows();
-        button.onClick.emit();
+        button.onClick.emit(rows);
         if (button.action) { button.action(); }
     }
 
index 64bbdf8..104e82d 100644 (file)
     [rowFlairCallback]="resourceAvailabilityIcon"
     [disablePaging]="true"
     persistKey="disabled">
+    <eg-grid-toolbar-button label="Create Reservation" i18n-label (onClick)="openTheDialog($event)"></eg-grid-toolbar-button>
     <eg-grid-toolbar-action label="Create Reservation" i18n-label (onClick)="openTheDialog($event)"></eg-grid-toolbar-action>
     <eg-grid-column path="time" [index]="true" name="Time" i18n-name [cellTemplate]="timeTemplate" ></eg-grid-column>
     <eg-grid-column *ngFor="let resource of resources" path="{{resource.barcode()}}" [cellTemplate]="reservationsTemplate" [disableTooltip]="true"></eg-grid-column>