inveniosoftware / react-invenio-forms

React component library for Formik components.
https://react-invenio-forms.readthedocs.io
MIT License
0 stars 28 forks source link

search: allowing search param key to be modified #243

Closed 0einstein0 closed 5 months ago

0einstein0 commented 5 months ago

:heart: Thank you for your contribution!

Description

Related to https://github.com/zenodo/zenodo-rdm/issues/890

Makes the searchParamKey configurable to make it more accurate, previously it was set to suggest, which did not work well for certain endpoints e.g. api/awards

https://127.0.0.1:5000/api/awards?q=micro - returns 10 records containing the word micro in title whereas, https://127.0.0.1:5000/api/awards?suggest=micro - returns 0 records this would cause problems when users are searching for relevant results

Checklist

Ticks in all boxes and 🟢 on all GitHub actions status checks are required to merge:

Frontend

Reminder

By using GitHub, you have already agreed to the GitHub’s Terms of Service including that:

  1. You license your contribution under the same terms as the current repository’s license.
  2. You agree that you have the right to license your contribution under the current repository’s license.
0einstein0 commented 5 months ago

Closed as we will introduce a separate component in the future that doesn't use the suggestion api.