Results 1 to 5 of 5

Thread: hide 'all' tab in detail view.

  1. #1
    spg82 is offline Junior Member
    Join Date
    Oct 2008
    Posts
    1

    Default hide 'all' tab in detail view.

    Hello,

    I want to remove the 'all' tabs from detail views of all my modules. I have used Admin->Configure Group Tabs to group my subpanels into different tabs and this works fine except that I still have everywhere 'All' tab containing all my subpanels. Is there a way to get rid of it?

    I'm using Sugar 5.1

    Thanks and regards,
    Steliyan

  2. #2
    r.douglas@uq.edu.au is offline Sugar Community Member
    Join Date
    Jul 2011
    Posts
    16

    Default Re: hide 'all' tab in detail view.

    Quote Originally Posted by spg82 View Post
    Hello,

    I want to remove the 'all' tabs from detail views of all my modules. I have used Admin->Configure Group Tabs to group my subpanels into different tabs and this works fine except that I still have everywhere 'All' tab containing all my subpanels. Is there a way to get rid of it?

    I'm using Sugar 5.1

    Thanks and regards,
    Steliyan
    Any updates on this? How about changing the order of these tabs to put the All tab last? I'm using Version 6.2, Corporate edition

  3. #3
    kuske's Avatar
    kuske is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Germany
    Posts
    2,597

    Default Re: hide 'all' tab in detail view.

    You can change the module include/SubPanel/SubPanelTilesTabs.php as follows:

    1st patch (line ~167):
    PHP Code:
            /* Add the 'All' group.
             * Note that if a tab group already exists with the name 'All',
             * it will be overwritten in this union operation.
             */
            
    if(count($groups) <= 1)
             
    $groups = array(translate('LBL_TABGROUP_ALL') => array('label' => translate('LBL_TABGROUP_ALL'), 'modules' => $tabs));
            else
    //KUSKE begin patch
    //          $groups = array(translate('LBL_TABGROUP_ALL') => array('label' => translate('LBL_TABGROUP_ALL'), 'modules' => $tabs)) + $groups;
    //KUSKE end patch
            /* Note - all $display checking and array_intersects with $tabs
             * are now redundant (thanks to GroupedTabStructure), and could
             * be removed for performance, but for now can stay to help ensure
             * that the tabs get renedered correctly.
             */ 
    2nd patch (line ~237):
    PHP Code:
                if(empty($displayTabs) && !empty($otherTabs))
                {
                    
    //WDong Bug: 12258 "All" tab in the middle of a record's detail view is not localized.
    //KUSKE begin patch
    //              $selectedGroup = translate('LBL_TABGROUP_ALL');
                    
    $otherKeys array_keys($otherTabs);
                    
    $selectedGroup $otherKeys['0'];
    //KUSKE end patch
                    
    $displayTabs $otherTabs[$selectedGroup]['tabs'];
                    
    $sugarTabs[$selectedGroup]['type'] = 'current';
                    
    $retTabs array_intersect($tabsarray_map('strtolower'$groups[$selectedGroup]['modules']));
                } 
    Harald Kuske
    Pre-Sales Engineer Central Europe

    SUGARCRM Deutschland GmbH
    Erika-Mann-Str. 53, 80636 Munich, Germany
    Email: hkuske@sugarcrm.com
    Home: http://www.sugarcrm.com


  4. #4
    r.douglas@uq.edu.au is offline Sugar Community Member
    Join Date
    Jul 2011
    Posts
    16

    Default Re: hide 'all' tab in detail view.

    Quote Originally Posted by kuske View Post
    You can change the module include/SubPanel/SubPanelTilesTabs.php as follows:

    1st patch (line ~167):
    PHP Code:
            /* Add the 'All' group.
             * Note that if a tab group already exists with the name 'All',
             * it will be overwritten in this union operation.
             */
            
    if(count($groups) <= 1)
             
    $groups = array(translate('LBL_TABGROUP_ALL') => array('label' => translate('LBL_TABGROUP_ALL'), 'modules' => $tabs));
            else
    //KUSKE begin patch
    //          $groups = array(translate('LBL_TABGROUP_ALL') => array('label' => translate('LBL_TABGROUP_ALL'), 'modules' => $tabs)) + $groups;
    //KUSKE end patch
            /* Note - all $display checking and array_intersects with $tabs
             * are now redundant (thanks to GroupedTabStructure), and could
             * be removed for performance, but for now can stay to help ensure
             * that the tabs get renedered correctly.
             */ 
    2nd patch (line ~237):
    PHP Code:
                if(empty($displayTabs) && !empty($otherTabs))
                {
                    
    //WDong Bug: 12258 "All" tab in the middle of a record's detail view is not localized.
    //KUSKE begin patch
    //              $selectedGroup = translate('LBL_TABGROUP_ALL');
                    
    $otherKeys array_keys($otherTabs);
                    
    $selectedGroup $otherKeys['0'];
    //KUSKE end patch
                    
    $displayTabs $otherTabs[$selectedGroup]['tabs'];
                    
    $sugarTabs[$selectedGroup]['type'] = 'current';
                    
    $retTabs array_intersect($tabsarray_map('strtolower'$groups[$selectedGroup]['modules']));
                } 
    Hey Kuske, thanks for the direction. Is this method upgrade safe or should the file be copied into a folder somewhere in the custom directory? thanks again for the heads up

  5. #5
    kuske's Avatar
    kuske is offline Sugar Community Member
    Join Date
    Oct 2007
    Location
    Germany
    Posts
    2,597

    Default Re: hide 'all' tab in detail view.

    This is a core patch, which is NOT upgrade safe.
    There is no possibility at the moment to implement it upgrade safe.
    Harald Kuske
    Pre-Sales Engineer Central Europe

    SUGARCRM Deutschland GmbH
    Erika-Mann-Str. 53, 80636 Munich, Germany
    Email: hkuske@sugarcrm.com
    Home: http://www.sugarcrm.com


Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How do I put edit view data in detail view link
    By spyro187 in forum Developer Help
    Replies: 1
    Last Post: 2011-10-19, 04:57 PM
  2. Replies: 0
    Last Post: 2008-07-11, 05:33 PM
  3. Replies: 13
    Last Post: 2007-10-04, 05:53 AM
  4. Replies: 0
    Last Post: 2007-08-09, 06:34 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •