How to hide header in SugarCRM community edition

Actually i am new to sugarcrm and zend frame work too .if anything not able to understand my following question means comment here . Now I am go for my query actually I need to hide the my header portion in all the page . So I followed this link

http://sugarcrm-customization-ash.blogspot.in/2012/06/how-to-hide-all-tab-from-menu-bar.html

mine version is : sugarcrm community Version 6.5.23

Its work charm but its hide the header part in list view and some pages only when I go detail view or edit view its showing all header again not hiding header part in detail view . so I want the hide the header part in each and every page . I don’t have much knowledge about sugarcrm and zend too so . what can do where can I do . Sorry for my bad English

thanks advance

Parents
  • In custom/include/MVC/View/views/view.detail.php add the following file:

    <?php

    /*
    * Your installation or use of this SugarCRM file is subject to the applicable
    * terms available at
    * http://support.sugarcrm.com/06_Customer_Center/10_Master_Subscription_Agreements/.
    * If you do not agree to all of the applicable terms or do not have the
    * authority to bind the entity as an authorized representative, then do not
    * install or use this SugarCRM file.
    *
    * Copyright (C) SugarCRM Inc. All rights reserved.
    */


    require_once('include/MVC/View/views/view.detail.php');

    class CustomViewDetail extends ViewDetail {

        /**
         * @see SugarView::display()
         */

        public function displayHeader() {
            parent::displayHeader();
            unset($groupTabs['All']);
            $ss->assign("groupTabs",$groupTabs);
        }

    }

    Override the editview in the same way. In some modules, you'll have to override detailview and editview in that module (i.e. copy modules/<module>/views/view.detail.php to custom/modules/<module>/views/view.detail.php and override the displayHeader class).

Reply
  • In custom/include/MVC/View/views/view.detail.php add the following file:

    <?php

    /*
    * Your installation or use of this SugarCRM file is subject to the applicable
    * terms available at
    * http://support.sugarcrm.com/06_Customer_Center/10_Master_Subscription_Agreements/.
    * If you do not agree to all of the applicable terms or do not have the
    * authority to bind the entity as an authorized representative, then do not
    * install or use this SugarCRM file.
    *
    * Copyright (C) SugarCRM Inc. All rights reserved.
    */


    require_once('include/MVC/View/views/view.detail.php');

    class CustomViewDetail extends ViewDetail {

        /**
         * @see SugarView::display()
         */

        public function displayHeader() {
            parent::displayHeader();
            unset($groupTabs['All']);
            $ss->assign("groupTabs",$groupTabs);
        }

    }

    Override the editview in the same way. In some modules, you'll have to override detailview and editview in that module (i.e. copy modules/<module>/views/view.detail.php to custom/modules/<module>/views/view.detail.php and override the displayHeader class).

Children
  • As per your suggestion i added following code in this file (custom/modules/Leads/views)

    view.detail.php 

    require_once('include/MVC/View/views/view.detail.php');

    class LeadsViewDetail extends ViewDetail
    {

    // function display()
    // {
    // global $sugar_config;

    // If the convert lead action has been disabled for already converted leads, disable the action link.
    // $disableConvert = ($this->bean->status == 'Converted' && !empty($sugar_config['disable_convert_lead'])) ? TRUE : FALSE;
    // $this->ss->assign("DISABLE_CONVERT_ACTION", $disableConvert);
    // parent::display();
    // }

    public function displayHeader() {
    parent::displayHeader();
    unset($groupTabs['All']);
    $ss->assign("groupTabs",$groupTabs);
    }


    }

    but its showing pop up error  that "There was an error processing your request, please try again at a later time."  what's wrong with that .

  • For anyone else coming to this thread, the correct answer, in addition to the changes in the blogpost is to edit SugarView and remove:

    $ss->assign('USE_GROUP_TABS', $usingGroupTabs);

    And replace it with:

    $ss->assign('USE_GROUP_TABS', false);