Results 1 to 4 of 4

Thread: Modifying subpanel view

  1. #1
    dusker is offline Senior Member
    Join Date
    Nov 2008
    Posts
    31

    Default Modifying subpanel view

    Hello,

    i've created a custom module related with opportunities module (many to many relation)
    now when i open detail view of an opportunity i get to see a subpanel for my module.
    is there a way to edit the view of it? for example i'd like the select button to be gone - we only need to be able to create items from there - select button would confuse people.
    is it possible to add some more columns to the subpanel? now it's just standard name and date modified, and i'd like it to present some more fields from custom module, and module builder and studio do not let me modify that subpanel.

    also would it be possible to remove 'save and continue' button from edit view globally - we won't need it at all and it can confuse users as well

    thanks for help
    greetings
    peter

  2. #2
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: Modifying subpanel view

    Hi Peter

    Edit the file modules/<ModuleUnderSubpanel>/metadata/subpanels/default.php and remove the 'SubPanelTopSelectButton' from top_buttons array.

    Regards
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

  3. #3
    dusker is offline Senior Member
    Join Date
    Nov 2008
    Posts
    31

    Default Re: Modifying subpanel view

    Quote Originally Posted by andopes
    Hi Peter

    Edit the file modules/<ModuleUnderSubpanel>/metadata/subpanels/default.php and remove the 'SubPanelTopSelectButton' from top_buttons array.

    Regards
    Thanks Andropes - You're extremely helpful! this worked!

    would anyone know the answer to two other questions?
    1. how to show some more columns in a subpanel of a custom module (do i put it in modules/<ModuleUnderSubpanel>/metadata/subpanels/default.php in list_fields array or its just an array of labels?)

    2. is there any way to remove either globally or in a paticular module button 'save and continue' from edit view?

    thanks in advance
    peter

  4. #4
    andopes's Avatar
    andopes is offline A Sugar Hero | Help Forum Moderator
    Join Date
    Jul 2006
    Location
    São Paulo - Brazil
    Posts
    8,335

    Default Re: Modifying subpanel view

    Hi Peter

    [QUOTE=dusker
    1. how to show some more columns in a subpanel of a custom module (do i put it in modules/<ModuleUnderSubpanel>/metadata/subpanels/default.php in list_fields array or its just an array of labels?)
    [/QUOTE]

    You can add new fields into the list_field array. The new fields should be displayed automatically.

    [QUOTE=dusker
    2. is there any way to remove either globally or in a paticular module button 'save and continue' from edit view?
    [/QUOTE]

    There is a fast but non-upgrade safe way to do that:
    Edit the file include/EditView/EditView2.php and change the line
    PHP Code:
    var $showVCRControl true
    to
    PHP Code:
    var $showVCRControl false
    There is an upgrade safe way to do that, but you need to create a custom view.edit.php for each module. Define into view.edit.php the function display() containing this code:

    PHP Code:
             $this->ev->showVCRControl false;
             
    parent::display(); 

    Regards
    André Lopes
    DevToolKit / Project of the Month - June 2009
    Lampada Global Services- Open Source Solutions
    Avenida Ipiranga, 318
    Bloco B - CJ 1602
    São Paulo, SP 01046-010
    Brazil
    Office: +55 11 3237-3110
    Mobile: +55 11 7636-5859
    e-mail: andre@lampadaglobal.com

    Lampada Global delivers offshore software development and support services to customers around the world.
    Lampada is proud to be a SugarCRM Gold Partner, revolutionizing Customer Relationship Management.

    I DO NOT answer questions through PM and Email. If you need some help post your question into SugarForum.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Replies: 1
    Last Post: 2011-01-20, 04:43 AM
  2. Missing subpanel in parent detail view
    By purplewave in forum Developer Help
    Replies: 0
    Last Post: 2008-02-18, 04:46 PM
  3. Detail View Record ID in a Subpanel Popup
    By baba_2002 in forum Developer Help
    Replies: 0
    Last Post: 2005-11-04, 02:22 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
  •