Notes posted by nachokb
RSS feed
Second example is correct
@taryneast, the second example is correct. The receiver’s #size limits the result’s.
nachokb

Doc in ActionView::Helpers::FormHelper
See ActionView::Helpers::FormHelper’s check_box for documentation.

Mapping Order
Something I always forget is the order in which each mapping should be specified.
The first item is the attribute name in the ActiveRecord model, and the second is the name of the attribute in the ValueObject (the writer uses it to read from the VO).
Furthermore, the order in which mapping pairs are specified should be the same as the order the attributes are specified in the ValueObject’s initialize method (for the reader to be able to instantiate a VO with the record’s values).
nachokb