Searchable Fields in Modules

Hello everyone,

In SuiteCRM 8, how do we make additional fields (such as description) or Custom fields within modules searchable?

Thanks!

Hi @Yar

If I need to create a Custom Field, I go to Admin >> Developer Tools >> Studio

In Studio you will be able to customize any module fields (such as description), layouts and relationships.
You can also translate what each field will show in different languages for the titles and the placeholders.

I did look into there but didnt see the option, as an example, i went to Studio > Contacts > Fields > Description but there is no option to make it searchable. We did create custom Fields as well but dont see the option to make them searchable.

See the screenshot below:

Thanks for looking into this @domiserver

1 Like

Hi @Yar

I always make sure I SAVE & DEPLOY the new fields.
In Studio > Contacts > Layouts > Filter, select: Quick Filter or Advanced Filter.

Inside the filter chosen, you can select the new field for the DEFAULT column and the search layout you want to be shown.

Then the “Search Forms will contain fields chosen for filtering records”

Thanks @domiserver .

I did go into Quick Filter, add Description to the default column under Leads, clicked Saved and Deploy, however, when I do a search, it doesnt seem to search in the Lead’s description.

Hi @Yar

Did you Check and repair SuiteCRM after making those changes?
Go to Admin > Admin Tools > Repair >> Quick Repair and Rebuild

Here you will “repair and rebuild the Database, Extensions, Vardefs and SuiteCRM Dashlets” including the new field.

Just did and it seems it didnt work.

Will continue to look around.

Thanks for your assistance @domiserver , it is greatly appreciated.

1 Like

Hello everyone,

It seems we are unable to get this to work.

Any assistance is appreciated!

Hey
I tried to add description in Advanced Search from studio and it Worked. it shows the description in the filters. I did do a hard refresh on the Leads listview page using Ctrl+F5.
Also the default search on text works as
description like '{search_value}%'
if you want to search within description text you need to add the extra % yourself
For Example
let’s say a lead has description as 12345
if you search 123 the lead will appear
if you search 234 the lead will not appear
if you search %234 the lead will appear

Thanks @abuzarfaris for your response.

Can you provide screenshots for your configuration so i can attempt to replicate it? Please note I am using SuiteCRM 8.1.3.

Thanks again for your assistance.

I also noticed that you post a screenshot of quick filter
In Suitecrm 8 you have to edit The advanced filter because quick filter is no longer used

Hi @Yar

  1. Check the custom field has the Inline Editing checked. Then Save and Deploy.
  2. In Studio > Contacts > Layouts > Filter, select: Advanced Filter.
  3. And finally: Go to Admin > Admin Tools > Repair >> Quick Repair and Rebuild
    or at least Rebuild the SuiteCRM dashlets.
  4. Logout and enter again.
  5. Verify when you do a search, the Lead’s description will be listed.

Thanks again for your time @domiserver .

I did follow your recommended steps but doesnt seem to work.


2


I did save and deploy and I did log out and logged back in.

Thanks for looking into this. - Suite CRM Version is 8.1.3

My Apologies I was thinking you are doing a module filter

For enabling description in unified search you need to modify the ‘public/legacy/custom/modules/Leads/metadata/SearchFields.php’ file
if it does not exist copy it from
‘public/legacy/modules/Leads/metadata/SearchFields.php’

add

'description' =>
        array (
            'query_type' => 'default',
            'force_unifiedsearch'=>true
        ),

in the $searchFields['Leads'] array
Do a repair and rebuild and the CRM will start searching in the Description column as well


To make sure that you see the description column in search results do add it in the listview from studio

2 Likes

That did the trick @abuzarfaris !!

Thanks for your assistance and time!

One last question, when an upgrade is processed, do we need to redo this?

What kind of changes need to be re-entered when SuiteCRM is upgraded?

All of these changes are upgrade safe
A simple check for changes is that if you did changes in the custom folder or via studio they are upgrade safe

1 Like