Make search_form_for's default :as option respect custom search_key #470

Merged
merged 1 commit into from Nov 15, 2014

Conversation

Projects
None yet
2 participants
@rspeicher
Contributor

rspeicher commented Nov 15, 2014

Prior to this change, if you set a custom search_key option in the initializer, you'd have to also pass an as: :whatever option to all of your search forms.

Fixes #92

jonatack added a commit that referenced this pull request Nov 15, 2014

Merge pull request #470 from tsigo/rs-form-helper-custom-search-key
Make #search_form_for default `:as` option respect custom search_key

@jonatack jonatack merged commit 05ee13b into activerecord-hackery:master Nov 15, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details
@jonatack

This comment has been minimized.

Show comment
Hide comment
@jonatack

jonatack Nov 15, 2014

Member

Thank you @tsigo 💚

This improvement and clarification very slightly changes the API, but probably not in a way that will bother anyone. We'll need to update the change log and wiki and possibly add a test in ransack and mongoid configuration_spec.rb.

Member

jonatack commented Nov 15, 2014

Thank you @tsigo 💚

This improvement and clarification very slightly changes the API, but probably not in a way that will bother anyone. We'll need to update the change log and wiki and possibly add a test in ransack and mongoid configuration_spec.rb.

@rspeicher rspeicher deleted the rspeicher:rs-form-helper-custom-search-key branch Nov 16, 2014

jonatack added a commit that referenced this pull request Nov 16, 2014

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