Monday 4 December 2017

Including Customized Modules/Fields in Global search in Sugarcrm/SuiteCRM

Defaultly in CRM, all modules & customized fields wont be available for global search . For making this module available for global search we have to do some tweaks..

First of all For enabling the modules we have to navigate to

CRM/custom/modules/

Open a file called unified_search_modules_display.php

Check or eg; if we want to enable search for Agreement module, then:-

'Agreement' => 
  array (
    'visible' => true,
  ),

Include this line in that file if you want to show that particular module....

If you didnt want to include taht module change to:-

'Agreement' => 
  array (
    'visible' => false,
  ),


So After Quick Repair & Rebuild this module will come in the List...

Now For enabling specific customized fields in Search.. For eg: agreementref_c in search then:-

1) Navigate to CRM/custom/Extension/modules/Agreement/Ext/Vardefs/

Create a file named customGlobalSearchFields.php

in That Include:-

<?php
$dictionary['Agreement']['fields']['agreementref_c']['unified_search'] = true;

?>


2) Now Go to CRM/custom/modules/Agreement/metadata/

open File called SearchFields.php

In That Include:-

'agreementref_c' => 
  array (
    'query_type' => 'default',
  ),

  So After Quick Repair & Rebuild , and do a search the result will come...

No comments:

Post a Comment