google-code-export / globalite

Automatically exported from code.google.com/p/globalite
1 stars 0 forks source link

select_month need a third parameter definition #22

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
in my case, using date_select, <%= form.date_select :birthday %> fails,
because, there are too many parameters given to the select_month method

the call breaks with the error 
"wrong number of arguments (3 for 2)"

application trace:

vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:651:in
`select_month'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:651:in `send'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:651:in
`date_or_time_select'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:646:in `each'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:646:in
`date_or_time_select'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:602:in
`to_date_select_tag_without_error_wrapping'
vendor/rails/actionpack/lib/action_view/helpers/active_record_helper.rb:225:in
`to_date_select_tag'
vendor/plugins/globalite/lib/rails/localized_action_view.rb:87:in `date_select'
vendor/rails/actionpack/lib/action_view/helpers/date_helper.rb:698:in
`date_select'
app/views/users/edit.html.erb:36:in
`_run_erb_47app47views47users47edit46html46erb'
app/views/users/edit.html.erb:2:in
`_run_erb_47app47views47users47edit46html46erb'

change:
def select_month(date, options = {})

to:
def select_month(date, options = {}, html_options = {})

somebody of the globalite developers should review and test it

best regards

Original issue reported on code.google.com by orth1...@googlemail.com on 12 Apr 2008 at 11:38

GoogleCodeExporter commented 9 years ago
I'll work on it asap. I'm importing the repo into github and will fix all these 
tiny
issues before porting the plugin to Merb.

Original comment by mattAimo...@gmail.com on 16 Apr 2008 at 3:51

GoogleCodeExporter commented 9 years ago
modification added and everything seems fine now, I'm working on porting the 
sample
app to the latest version of rails and rspec so I can properly test that the 
plugin
works fine with Rails 2.1

Original comment by mattAimo...@gmail.com on 16 Apr 2008 at 7:48