I am trying to simplify the SugarCRM interface for use by our internal staff an I wanted to remove the features not needed for them.  2 of the features I wanted to remove were the Site Map drop-down and the Search which are both in the top-right corner.
In order to do this, I created a new theme.  I did this making a copy of the default theme.  I made a new directory called custom/themes/NewTheme/.  In here I copied all of the files and directories from themes/Sugar5/.  This included the following:
css/
images/
js/
layout_utils.php
themedefs.php
tpls/
Now, I edited themedefs.php in order to reflect the name of my new theme.  In order to do this, just change the line 'name'  => "Classic".  I changed my theme to be named Theme1.  So my new line looked like the following:
'name' => "Theme1",
In order to now see this theme, you will want to choose it in the Admin.  In order to do this, click on Administrator->Themes.  Choose the new theme Theme1.  Then, click Save.
You will now see the changes you make to the new theme that you created.  In order to get rid of the 2 elements from above, we would need to edit custom/themes/TEJAS1/tpls/_headerSearch.tpl.  In this file, remove the following code:
<div id="search">
    <form name='UnifiedSearch' onsubmit='return SUGAR.unifiedSearchAdvanced.checkUsaAdvanced()'>
        <input type="hidden" name="action" value="UnifiedSearch">
        <input type="hidden" name="module" value="Home">
        <input type="hidden" name="search_form" value="false">
        <input type="hidden" name="advanced" value="false">
        <img id="unified_search_advanced_img" src="{sugar_getimagepath file='searchMore.gif'}" border="0" alt="{$APP.LBL_SEARCH}"> 
        <input type="text" name="query_string" id="query_string" size="20" value="{$SEARCH}"> 
        <input type="submit" class="button" value="{$APP.LBL_SEARCH}">
    </form><br />
    <div id="unified_search_advanced_div"> </div>
</div>
<div id="sitemapLink">
    <span id="sitemapLinkSpan">
        {$APP.LBL_SITEMAP}
        <img src="{sugar_getimagepath file='MoreDetail.png'}">
    </span>
</div>
You may also want to add some other code in here in the same place for spacing.  The 2 elements should now be gone.
 
 
This comment has been removed by a blog administrator.
ReplyDelete