Results 1 to 3 of 3

Thread: Sub-panel not displaying

  1. #1
    jmugauri is offline Sugar Community Member
    Join Date
    Feb 2007
    Location
    Lusaka, Zambia
    Posts
    29

    Red face Sub-panel now displaying.. but no auto link to account on create

    Hi, all

    I've created a custom module (AccountSLAs), and would like it to be displayed in the Account detail view subpanel. I've followed the instructions listed at http://www.sugarcrm.com/wiki/index.php?title=Subpanels to no avail.

    It is a subpanel for a module with one-to-many relationships with account and my modules/Accounts/vardefs.php has been amended with the following extra lines in the field array:

    'accountslas' => array (
    'name' => 'accountslas',
    'type' => 'link',
    'relationship' => 'account_accountslas',
    'module'=>'AccountSLAs',
    'bean_name'=>'AccountSLA',
    'source'=>'non-db',
    'vname'=>'LBL_ACCOUNTSLAS',
    ),

    and the relationships array in the same file:

    ,'account_accountslas' => array('lhs_module'=> 'Accounts', 'lhs_table'=> 'accounts', 'lhs_key' => 'id',
    'rhs_module'=> 'AccountSLAs', 'rhs_table'=> 'accountslas', 'rhs_key' => 'account',
    'relationship_type'=>'one-to-many', 'relationship_role_column'=>'parent_type',
    'relationship_role_column_value'=>'Accounts')

    modules/Accounts/layout_defs.php has these new lines:

    'accountslas' => array(
    'order' => 120,
    'module' => 'AccountSLAs',
    'subpanel_name' => 'default',
    'get_subpanel_data' => 'accountslas',
    'add_subpanel_data' => 'id',
    'title_key' => 'LBL_ACCOUNTSLAS_SUBPANEL_TITLE',
    'top_buttons' => array(
    array('widget_class' => 'SubPanelTopButtonQuickCreate'),
    ),
    ),

    Am using SugarOS 4.5.1b, and have 'repaired relationships' in admin to no avail. Any ideas out there?
    Last edited by jmugauri; 2007-09-18 at 06:32 PM. Reason: Original problem sorted - new problems abound
    JamesTM

    OS: CentOS 5.2
    Sugar: 5.1
    Apache 2.2
    PHP 5.1
    MySQL 5

  2. #2
    Superman's Avatar
    Superman is offline Sugar Community Member
    Join Date
    Oct 2005
    Location
    Kazakhstan
    Posts
    852

    Default Re: Sub-panel not displaying

    1. What error is being shown?
    2. Have you created /modules/{your_module}/subpanels/default.php file w/ subpanel setup instructions?
    Farkhad Rakhimzhanov
    E-mail: farkhad@gmail.com
    Skype: rakikama

    SuperTimesheet and Invoicing — timesheet tool with invoicing for SugarCRM.
    Book time against Cases, Project Tasks and Projects.
    Create invoice regarding booked time, print it in PDF or HTML,
    customize template as you like.

  3. #3
    jmugauri is offline Sugar Community Member
    Join Date
    Feb 2007
    Location
    Lusaka, Zambia
    Posts
    29

    Question Re: Sub-panel now displaying

    Hi all,

    Sorry for the bother. Because i was using the 'new' Builder wizard, and making extensive revisions throughout, the fields in y table were not corresponding to the fields in the definitions above. Restarted the whole process and the subpanel's now displaying correctly.

    New problem: When i click 'Full Form' to add a new AccountSLA (custom module), the account information is not passed to the new form as it is in other subpanel forms. How do I resolve this?

    In anticipation of your help.
    Last edited by jmugauri; 2007-09-18 at 08:37 AM. Reason: New problems
    JamesTM

    OS: CentOS 5.2
    Sugar: 5.1
    Apache 2.2
    PHP 5.1
    MySQL 5

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Unable to Hide 'Mass Update' panel
    By HomeTeam in forum General Discussion
    Replies: 13
    Last Post: 2009-04-26, 03:55 AM
  2. Popup and panel issues
    By bingomanatee in forum Help
    Replies: 3
    Last Post: 2007-06-26, 10:30 PM
  3. Moving Related Information Panel from Enter Business Card UI
    By mcharudatta in forum Developer Help
    Replies: 0
    Last Post: 2006-07-05, 08:57 AM
  4. Replies: 0
    Last Post: 2006-06-15, 01:34 PM
  5. Replies: 1
    Last Post: 2006-03-05, 01:54 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
  •