Added possibility to manually decide whether a check box is checked #909

wants to merge 1 commit into


None yet
2 participants

yuszuv commented Jan 12, 2013

I wanted the possibility to decide whether a check box is checked or not by passing the corresponding value (true or false) to the input. This now can be done by passing :input_html => { :checked => true/false }. Previously you only could check the input but not uncheck it, e.g. when builder.object.send(:method) returns true and you want the corresponding check box unchecked

I hope that helps.



justinfrench commented Jul 4, 2013

We don't have :checked options because it was impossible to apply them consistently. The correct approach is to set the model instance up with the default value either in the controller or as part of initialization. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment