New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

check_box_group, radio_button_group helpers #27

Closed
nesquena opened this Issue Dec 1, 2009 · 5 comments

Comments

Projects
None yet
4 participants
@nesquena
Member

nesquena commented Dec 1, 2009

Helpers for check_box_group, radio_button_group which create a set of checkboxes or radio buttons for a form. Pass in a set of options (similar to select helper now) and it returns a set of the checkboxes or radio buttons. add tests as well.

f.radio_button_group :attr, :caption => "...", :options => "same as select options"
f.check_box_group   :attr, :caption => "...", :options => "same as select options"
@WaYdotNET

This comment has been minimized.

Show comment
Hide comment
@WaYdotNET

WaYdotNET Dec 9, 2010

Contributor

up

Contributor

WaYdotNET commented Dec 9, 2010

up

@ghost ghost assigned nesquena Apr 10, 2011

ujifgc added a commit to ujifgc/padrino-framework that referenced this issue Jan 10, 2013

dariocravero added a commit that referenced this issue Jan 12, 2013

Merge pull request #994 from ujifgc/groups
Implementing #27, some basic tests
@dariocravero

This comment has been minimized.

Show comment
Hide comment
@dariocravero

dariocravero Jan 12, 2013

Contributor

There's one thing we might be missing from what @nesquena proposed and it's the caption. Did you mean to have something like a fieldset with a legend Nathan?

EDIT: We should also consider :uncheck_value => '0' on check_boxes_group to make it the same as the check_box helper?

I'll update the docs tomorrow.

Contributor

dariocravero commented Jan 12, 2013

There's one thing we might be missing from what @nesquena proposed and it's the caption. Did you mean to have something like a fieldset with a legend Nathan?

EDIT: We should also consider :uncheck_value => '0' on check_boxes_group to make it the same as the check_box helper?

I'll update the docs tomorrow.

@ujifgc

This comment has been minimized.

Show comment
Hide comment
@ujifgc

ujifgc Jan 12, 2013

Member

No other AbstractFormBuilder helper shows caption, so why should these? I intended f.*_group builders to work like f.select. Actually field_set_tag works outside FormBuilder and has nothing to do with controls.

Also check_boxes_group doesn't need :uncheck_value => '0' because it generates html which sends an array to params: empty or with some values. Originally hidden input was needed to send a zero to params if the only checkbox was not checked.

Member

ujifgc commented Jan 12, 2013

No other AbstractFormBuilder helper shows caption, so why should these? I intended f.*_group builders to work like f.select. Actually field_set_tag works outside FormBuilder and has nothing to do with controls.

Also check_boxes_group doesn't need :uncheck_value => '0' because it generates html which sends an array to params: empty or with some values. Originally hidden input was needed to send a zero to params if the only checkbox was not checked.

@dariocravero

This comment has been minimized.

Show comment
Hide comment
@dariocravero

dariocravero Jan 12, 2013

Contributor

@ujifgc makes sense. Let's leave it as it is then. Here're the docs. Thanks! :)

Contributor

dariocravero commented Jan 12, 2013

@ujifgc makes sense. Let's leave it as it is then. Here're the docs. Thanks! :)

@nesquena

This comment has been minimized.

Show comment
Hide comment
@nesquena

nesquena Jan 12, 2013

Member

Awesome, this is one of our oldest issues / wishlist ideas finally closed 👍

Member

nesquena commented Jan 12, 2013

Awesome, this is one of our oldest issues / wishlist ideas finally closed 👍

nesquena added a commit that referenced this issue Oct 16, 2014

Merge pull request #27 from Ortuna/controller-generator-options
Added newly created controller generation options
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment