From 63e20d284855f9e40706e94dc8d17558eb18e1e4 Mon Sep 17 00:00:00 2001 From: Vlatka Pavisic Date: Tue, 3 Jan 2017 16:55:24 +0100 Subject: Refs #2265 Refs #2262 : Calendars search and CRUD --- app/controllers/calendars_controller.rb | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'app/controllers/calendars_controller.rb') diff --git a/app/controllers/calendars_controller.rb b/app/controllers/calendars_controller.rb index 697d8a507..579a48e1d 100644 --- a/app/controllers/calendars_controller.rb +++ b/app/controllers/calendars_controller.rb @@ -7,7 +7,7 @@ class CalendarsController < BreadcrumbController private def calendar_params - params.require(:calendar).permit(:id, :name, :short_name, :shared, periods_attributes: [:id, :begin, :end, :_destroy], dates: []) + params.require(:calendar).permit(:id, :name, :short_name, :shared, periods_attributes: [:id, :begin, :end, :_destroy], date_values_attributes: [:id, :value, :_destroy]) end def sort_column @@ -31,10 +31,6 @@ class CalendarsController < BreadcrumbController def collection return @calendars if @calendars - if params[:q] - params[:q].delete(:shared_eq) if params[:q][:shared_eq] == '' - params[:q].delete(:short_name_cont) if params[:q][:short_name_cont] == '' - end @q = current_organisation.calendars.search(params[:q]) calendars = @q.result -- cgit v1.2.3