Update polls translatable fields
The `:name` attribute is still allowed in the controller because some forks use it when creating a poll from a budget.
This commit is contained in:
@@ -61,10 +61,10 @@ class Admin::Poll::PollsController < Admin::Poll::BaseController
|
||||
|
||||
def poll_params
|
||||
image_attributes = [:id, :title, :attachment, :cached_attachment, :user_id, :_destroy]
|
||||
attributes = [:name, :starts_at, :ends_at, :geozone_restricted, :summary, :description,
|
||||
:results_enabled, :stats_enabled, geozone_ids: [],
|
||||
attributes = [:name, :starts_at, :ends_at, :geozone_restricted, :results_enabled,
|
||||
:stats_enabled, geozone_ids: [],
|
||||
image_attributes: image_attributes]
|
||||
params.require(:poll).permit(*attributes, *translation_params(Poll))
|
||||
params.require(:poll).permit(*attributes, translation_params(Poll))
|
||||
end
|
||||
|
||||
def search_params
|
||||
|
||||
Reference in New Issue
Block a user