Friday, 1 February 2013

Display more than 10 records in SQS search.

SugarCRM by default displays 10 records as a search result after SQS. As an example, we take Opportunities module with after_ui_frame logic hook.

Step 1 : Create logic hook entry as follows

$hook_array['after_ui_frame'] = Array();
$hook_array['after_ui_frame'][] = Array(5, 'Change SQS result records', 'custom/modules/Opportunities/logic_hooks/changeSQSRecordCount.php','changeSQSRecordCountC','changeSQSRecordCountF');


Step 2 : Open custom/modules/Opportunities/logic_hooks/changeSQSRecordCount.php and write following code into it.

class changeSQSRecordCountC
{
    function changeSQSRecordCountF()
    {
        echo "<script language='javascript'>YAHOO.widget.AutoComplete.prototype.maxResultsDisplayed=20;</script>";
    }
}

Before
After
Feel free to leave comments.

No comments:

Post a Comment

Urdhva Tech Pvt. Ltd. Powered by Blogger.

Urdhva Tech

My photo
SugarCRM Consultants Contact us at contact@urdhva-tech.com Skype : urdhvatech

Search This Blog

Stay connected Socially

     

Total Pageviews

Popular Posts