Is there an option to enable %keyword% search by default... if not which files to edit?
Option to enable %keyword% search by default
Collapse
X
-
Tags: None
-
If you find EspoCRM good, we would greatly appreciate if you could give the project a star on GitHub. We believe our work truly deserves more recognition. Thanks. -
Awesome
/#Admin/settings
Use 'contains' operator when filtering varchar fields
If not checked then 'starts with' operator is used. You can use the wildcard '%'.Comment
-
It would be nice to have an option to prefix the % in the search as option indeed as suggested below.
---------------------------
From the Espocrm.com customer portal documents/tips section :
Open file application/Espo/Controllers/GlobalSearch.php
Find:
$query = $request->get('q');
Add content below:
$query = trim($query, '%');
$query = '%'. $query .'%';
Do the initial trim in case someone has already added the wildcard to the beginning or end, since this makes it a global wildcard.
You can also do it on the record list as well by making the very simple change below.
Open file application/Espo/Core/SelectManagers/Base.php
Go to line 1248 and change...
$expression = $textFilter . '%';
to
$expression = '%'. $textFilter . '%';Comment
Comment