Open
Description
Description
Global Search isn't working for me in Twill 3. I verified that it loops through all the items on the dashboard, but the SQL query that is generated doesn't include a condition for title
for any of the models. It is only checking where "[model]"."deleted_at" is null
. Looking at the cmsSearch()
method in ModuleController, it's using the FreeTextSearch model and setting:
$searchFilter->queryString($search);
$searchFilter->searchColumns($fields);
$searchFilter->searchQuery($query);
The FreeTextSearch model, however, has a condition that requires searchString
to not be empty, and that value is never set in cmsSearch(). It gets set by the searchFor()
method which never gets called.
Adding:
$searchFilter->searchFor($search);
Makes global search work as expected for me.
Metadata
Metadata
Assignees
Labels
No labels