Closed arthwood closed 10 years ago
Hi there!
= f.datepicker :voucher_expires_at
should work without problems.. Could you post a gist (https://gist.github.com) with the whole view?
Thanks!
I possibly have the same issue, except with a slightly different error: wrong number of arguments (1 for 0)
This might be because I'm using Rails 4 & Ruby 2, however. I forked this repo in an attempt to make it compatible - it may be an issue with that.
https://github.com/hale/jquery_datepicker/commit/5219d1defd62cf4ccc447ee4f7eeb5de00a6e052
Here's the full view:
https://github.com/hale/budgeter/blob/master/app/views/transactions/_form.html.haml
Okay it's bound to be different - missed that the OP made the issue 7 months ago. I'm attempting to make this compatible with Rails 4 anyway - i'll make a new thread.
@albertopq here's the gist: https://gist.github.com/arthwood/5890816 I reduced it to minimum so it's simple as that. The project is in Rails 3.2.10. I'll try to upgrade to 11 or remove some other gems since they may be in conflict with jquery_datepicker
That's weird... this test just try to check that case:
https://github.com/albertopq/jquery_datepicker/blob/master/spec/jquery_datepicker_spec.rb#L223
I don't think Rails 3.2.10 is the problem, probably the conflict with another gem is the case. It's not going to be easy to reproduce for me, so if you can try to minimize the use case (reducing gems), I'll be glad to help.
Thanks!
Might have something to do with HAML? Could you please try to use ERB instead, just for testing?
ok, got it, here's the source of the issue:
gem 'galetahub-simple_captcha', require: 'simple_captcha'
I have in haml template:
but it gives:
as if it would expect:
which actually works, but syntactically makes no sense and doesn't set proper value of text_field unless I use:
Maybe it conflicts with other gems? My Gemfile:
gem 'haml' gem 'uglifier' gem 'execjs' gem 'therubyracer', :platform => :ruby gem 'acts-as-taggable-on' gem 'rinku', :require => 'rails_rinku' gem 'authlogic' gem 'jquery-rails' gem 'jquery_datepicker' gem 'paperclip' gem 'kaminari' gem 'dynamic_form' gem 'galetahub-simple_captcha', :require => 'simple_captcha', :git => 'git://github.com/galetahub/simple-captcha.git' gem 'money' gem 'quiet_assets'