Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

rails-i18n date_select error

In my view I have:

<%= f.date_select :start %>

and I get the error message: can't convert Symbol into String

I know that it's related to it.date.order rule, but I see that rails-i18n include it: https://github.com/svenfuchs/rails-i18n/blob/master/rails/locale/it.yml#L51

what's wrong here?

full back trace: https://gist.github.com/4007557

EDIT: running I18n.t 'date.order' in the console give me => [:day, :month, :year]. That it's correct... so why date_select doesn't works?

issue on GitHub repo: https://github.com/svenfuchs/rails-i18n/issues/273

like image 992
enricostn Avatar asked Feb 18 '23 14:02

enricostn


1 Answers

I had a similar if not the same issue in the past. At the time I fixed it by using the following:

date:
  order: [ !ruby/symbol day, !ruby/symbol month, !ruby/symbol year ]
like image 147
vise Avatar answered Feb 27 '23 00:02

vise