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

🧹 Remove date from advanced search #127

Merged
merged 1 commit into from
Oct 23, 2023

Conversation

kirkkwang
Copy link

There is a known issue with the date facet in advanced search and the common approach is to remove it. This commit will remove the date from the advanced search form and also increase the character limit for the form fields. It was set to 4 but that was only enough for the year and didn't work for a date search like DD/MM/YYYY. Lastly, I moved the gem call for blacklight_range_limit out of the development group so it can be used in a deployed environment. Other than those changes, the search seems to be working as expected

Ref:

Expected Behavior Before Changes

Filtered advanced searches generally work as intended as the results show up in the catalog search view just like a regular search. However, the actual Search button does not work. It does work if you hit enter or return on your keyboard though. This is because it conflicts with the Blacklight Range Limit gem in that the Date facet also has a form element so it becomes a nested form tag which does some funky rendering.

Expected Behavior After Changes

Filtered advanced searches should still work but the Date facet is omitted so it doesn't cause conflicts. Date searches on the regular search is not just limited to 4 characters anymore.

Screenshots / Video

Before:

Screen.Recording.2023-10-21.at.09.19.14.mp4

After:

Screen.Recording.2023-10-21.at.09.16.56.mp4

There is a known issue with the date facet in advanced search and the
common approach is to remove it.  This commit will remove the date from
the advanced search form and also increase the character limit for the
form fields.  It was set to 4 but that was only enough for the year and
didn't work for a date search like DD/MM/YYYY.  Lastly, I moved the gem
call for `blacklight_range_limit` out of the development group so it can
be used in a deployed environment.  Other than those changes, the search
seems to be working as expected

Ref:
  - #100
  - LafayetteCollegeLibraries/spot#143
@kirkkwang kirkkwang merged commit 2dd90f8 into softserv-dev Oct 23, 2023
@kirkkwang kirkkwang deleted the i100-refine-advanced-search branch October 23, 2023 15:11
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.

2 participants