wawimundo / ChainSelects

ChainSelects is a Ruby on Rails plugin which allows easy creation of dependent or "chained" selects.
http://chainselects.hypermediasoft.com/
MIT License
39 stars 6 forks source link

postrgresql fails with '1' #1

Closed peterberkenbosch closed 14 years ago

peterberkenbosch commented 14 years ago

http://github.com/diwadm/ChainSelects/blob/master/lib/chain_selects/acts_as_chainable.rb#L73

This is hardcoded to "1", but is should be something like this:

conditions = (self.chain_select_conditions or ['?',true])

With Postgresql this renders an error, because it is expecting a boolean value, not an integer.

wawimundo commented 14 years ago

Thanks Peter. I'll have your patch uploaded this weekend.