Change default date formatter in active admin

activeadmin, localization, ruby-on-rails

Solution

please, ensure you have next lines in your config/locales/en.yml

en:
  date:
    formats:
      long: "%Y-%m-%d"
  time:
    formats:
      long: "%Y-%m-%d %H:%M:%S"

Also if you want to change Filter default date formats Try this Active Admin date filter date format customisation

Problem

In ActiveAdmin dates are printed in the, supposedly American, format `%B %d, %Y %H:%M`. E.g. `March 19, 2013 13:25` However, my "default" frontend prints this using the default Rails (ISO) format, `2013-03-07 14:12:31 UTC`, as seen when dropping a `<%= Date.new %>` anywhere in a view. - What is defining the format for the ActiveAdmin dates? - Where or how can this be changed, if possible, simply following a global Rails wide i18n setting.

Original source

Related problems