Fix admin edition filtering #386

merged 4 commits into from Mar 25, 2013

2 participants



There was a difference between not explicitly choosing a state and choosing "all" when hitting the admin edition index. Made "all" be the default if no state param is provided.

Took the opportunity to also do the same for world_location_ids (default to "all") and tidy up UI so that all dropdowns (org, world location, etc) will pass on other options (state, type, etc).

h-lame added some commits Mar 25, 2013
@h-lame h-lame EditionsController adds a default state param of 'active'
This is to avoid selecting 'all' from the filter menu and not having anything selected presenting different results.

@h-lame h-lame EditionsController adds a default world_location_ids param of 'all'
This is so the front end will highlight "All" world locations even if you didn't select one.

@h-lame h-lame Tidy up admin edition filtering UI
1. make sure each filter option that is rendered as a form has hidden fields for the filter options that make sense (state, type, etc..)
2. use the @filter.options instead of params to query values (because we now inject some defaults)
3. highlight the 'world location ids' options if selected
@h-lame h-lame Remove meaningless test for admin edition filter ui 838376f

👍for stripping all the hidden field nonsense.

@bradwright bradwright merged commit 162fc6b into master Mar 25, 2013

1 check passed

Details default The Travis build passed
@bradwright bradwright deleted the fix_admin_edition_filtering branch Mar 25, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment