AnsweredAssumed Answered

Default search filter customization

Question asked by Caim Astraea on Feb 24, 2017
Latest reply on Feb 27, 2017 by Caim Astraea

A while back have changed the quicksearch_field to include more fields inside custom/modules/clients/base/filter/default/default.php 

$viewdefs['Accounts']['base']['filter']['default'] = array (

'default_filter' => 'all_records',

'quicksearch_field' => array('name', 'shipping_address_postalcode', 'shipping_address_city', 'ticker_symbol'), 'quicksearch_priority' => 2, 'default_filter' => 'all_records',


The problem I noticed is that the filter is definitely wrong by default is looks for records STARTING with my search term instead of records CONTAINING the term 



Is it possible to search for records containing the search terms ? 


Update: I'm thinking could make a custom filter as described here Creating Custom Filters In Sugar 7 « Sugar Developer Blog – SugarCRM  but there's lots of info I don't have. 

In this example the '$starts' => 'A' is hardcoded how to pass it the value from my search ? 

Also is there a '$contains' ?  I'm thinking there could be such a filter.