Description
Rails admin half of the time displays and allows to select a time, even for fields of type date
and not datetime
. This is what it sometimes shows (correct):
But just when reloading the page, sometimes it shows this, apparently randomly:
The same display issue applies to the edit page.
But more importantly, when editing the record, randomly the date gets deleted upon saving. So because of this, any time I edit a record, I need to go and check if the date was preserved, otherwise I need to go and enter it again (hoping I remember what the value was).
Using rails_admin 1.4.2 and DB schema:
create_table "testimonials", force: :cascade do |t|
....
t.date "date"
end
EDIT: the issue remains (and even gets worse) if the type is set explicitly in the config:
config.model 'Testimonial' do
list do
...
field :date, :date
end
end
Even in that case the time is shown:
But more importantly, in this case the date field then gets silently nullified every single time when the record is edited.