From e0d52892b1aa320c7b4ff2c276b334dce59cc86c Mon Sep 17 00:00:00 2001
From: Galen Charlton <gmc@equinoxinitiative.org>
Date: Wed, 6 Nov 2019 11:35:58 -0500
Subject: [PATCH] LP#1851524: fix adding a bucket when saving a new carousel

This patch fixes a regression where saving a new carousel
would not result in its bucket being created due to the
post-save callback never getting invoked.

This patch does not fix any carousels that do not have
buckets due to this bug. Because such carousels will
not function anyway, they should be deleted and
recreated by the local admin.

To test
-------
[1] Create a new carousel in local adminstration. Open it
    in the edit modal again and note that no record bucket
    is linked to it.
[2] Apply the patch and repeat step 1. This time, the
    bucket should be created.

Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>

Signed-off-by: Chris Sharp <csharp@georgialibraries.org>
---
 .../src/eg2/src/app/staff/admin/local/admin-carousel.component.html     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html b/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html
index 6c3e7834d1..64714af755 100644
--- a/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html
+++ b/Open-ILS/src/eg2/src/app/staff/admin/local/admin-carousel.component.html
@@ -90,7 +90,7 @@
 <eg-fm-record-editor #editDialog idlClass="{{idlClass}}" 
     [preloadLinkedValues]="true" readonlyFields="last_refresh_time"
     hiddenFieldsList="creator,editor,create_time,edit_time"
-    [preSave]="mungeCarousel" (onSave$)="postSave($event)"
+    [preSave]="mungeCarousel" (recordSaved)="postSave($event)"
     readonlyFields="last_refresh_time"
     [fieldOptions]="{bucket:{customTemplate:{template:bucketTemplate}},copy_location_filter:{customTemplate:{template:locationTemplate}},owning_lib_filter:{customTemplate:{template:orgTemplate}}}"
 ></eg-fm-record-editor>
-- 
2.11.0