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

ENHANCEMENT overload getResults() with extension point to change $booleanSearch param #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

muskie9
Copy link
Contributor

@muskie9 muskie9 commented Mar 17, 2022

resolves #22

@fonsekaean
Copy link
Member

@muskie9 can you explain whats the issue we are trying to solve here?

@muskie9
Copy link
Contributor Author

muskie9 commented Mar 17, 2022

@fonsekaean sure, and in all honesty it's more so something that should probably go into CMS vs this module.

I ran into a situation where searching a keyword that has - in it does not yield the expected results due to IN BOOLEAN MODE being set in searchEngine() from the passed param. This param is set in the SearchForm::getResults() method and relies on checking for 4 particular operators that are used for IN BOOLEAN MODE. These modifiers have special meaning at the beginning or end of words in the search string.

With the module already overriding SearchForm from CMS it was seemingly a lower barrier to open a pull request vs the CMS process. The getResults() method added in this pull request adds an extension point allowing for setting the param that affects the IN BOOLEAN MODE being included in the query. I still plan on raising a ticket in CMS to see if it's something that would be accepted but I figured others may find this useful in the meantime if using this module.

Hope that sheds some light on the issue and solve. No worries if it's something you'd rather not have in the module.

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.

ENHANCEMENT overload getResults() with extension point for changing $booleanSearch param
2 participants