diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2020-03-12 17:57:59 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-12 17:57:59 +0100 |
commit | f556f79b7733834430b93109ac2c7f87529c8574 (patch) | |
tree | 27686f762b65eff63f06f173542a749e52991397 /app/controllers | |
parent | aeebbe90dc8224ae8bc9ac81fb68435105edb293 (diff) |
Add titles to warning presets in admin UI (#13252)
Diffstat (limited to 'app/controllers')
-rw-r--r-- | app/controllers/admin/warning_presets_controller.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/admin/warning_presets_controller.rb b/app/controllers/admin/warning_presets_controller.rb index 37be842c5..b376f8d9b 100644 --- a/app/controllers/admin/warning_presets_controller.rb +++ b/app/controllers/admin/warning_presets_controller.rb @@ -7,7 +7,7 @@ module Admin def index authorize :account_warning_preset, :index? - @warning_presets = AccountWarningPreset.all + @warning_presets = AccountWarningPreset.alphabetic @warning_preset = AccountWarningPreset.new end @@ -19,7 +19,7 @@ module Admin if @warning_preset.save redirect_to admin_warning_presets_path else - @warning_presets = AccountWarningPreset.all + @warning_presets = AccountWarningPreset.alphabetic render :index end end @@ -52,7 +52,7 @@ module Admin end def warning_preset_params - params.require(:account_warning_preset).permit(:text) + params.require(:account_warning_preset).permit(:title, :text) end end end |