Skip to content
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

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

Merged
merged 1 commit into from
Nov 15, 2014
Merged

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

merged 1 commit into from
Nov 15, 2014

Conversation

rspeicher
Copy link
Contributor

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
Make #search_form_for default `:as` option respect custom search_key
@jonatack jonatack merged commit 05ee13b into activerecord-hackery:master Nov 15, 2014
@jonatack
Copy link
Contributor

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.

jonatack added a commit that referenced this pull request Nov 15, 2014
@rspeicher rspeicher deleted the rs-form-helper-custom-search-key branch November 16, 2014 00:59
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
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Custom search parameter key changing.. not working
2 participants