0
0
Fork 0

Move admin action log type list generation to helper (#32178)

This commit is contained in:
Matt Jankowski 2024-10-02 10:47:00 -04:00 committed by GitHub
parent 7d6b9ccd34
commit cec8961372
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 1 deletions

View file

@ -35,4 +35,11 @@ module Admin::ActionLogsHelper
end
end
end
def sorted_action_log_types
Admin::ActionLogFilter::ACTION_TYPE_MAP
.keys
.map { |key| [I18n.t("admin.action_logs.action_types.#{key}"), key] }
.sort_by(&:first)
end
end