File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
app/Livewire/Partials/AdvancedSearch Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -140,6 +140,7 @@ public function savePredefinedFiltersModal(
140140
141141 // mock a filter to check if userHasTheCreatePermission
142142 if ($ this ->visibility === FilterVisibility::Public) {
143+ // TODO different === Public vs !== Private
143144
144145 // create dummy filter
145146 $ filter ->is_public = true ;
@@ -178,7 +179,12 @@ public function savePredefinedFiltersModal(
178179
179180 $ predefinedFilterService ->createFilter ($ validated );
180181
181-
182+ $ this ->dispatch ('showNotificationInFrontend ' , [
183+ 'type ' => 'success ' ,
184+ 'title ' => trans ('general.notification_success ' ),
185+ 'message ' => trans ('admin/predefinedFilters/message.create.success ' ),
186+ 'tag ' => 'predefinedFilter ' ,
187+ ]);
182188
183189 $ this ->dispatch ("savePredefinedFiltersModalEvent " );
184190 $ this ->dispatch ("closePredefinedFiltersModal " );
@@ -220,7 +226,8 @@ public function updatePredefinedFiltersModal(
220226 ]);
221227 return ;
222228 }
223-
229+
230+
224231 if (!$ predefinedFilter ->userHasPermission (auth ()->user (), 'edit ' )) {
225232 $ this ->dispatch ('showNotificationInFrontend ' , [
226233 'type ' => 'error ' ,
@@ -269,7 +276,6 @@ public function updatePredefinedFiltersModal(
269276 ]);
270277 }
271278
272-
273279 $ this ->dispatch ("updatePredefinedFiltersModalEvent " );
274280 $ this ->dispatch ("closePredefinedFiltersModal " );
275281 }
You can’t perform that action at this time.
0 commit comments