Results 1 to 7 of 7

Thread: QuickCreate button for new module

  1. #1
    Antanas0001 is offline Sugar Community Member
    Join Date
    Aug 2007
    Location
    Lithuania
    Posts
    41

    Default QuickCreate button for new module

    Hello,

    Using SugarCRM 5.1.0a we have created new module Products and made a relationship with Opportunities module.
    Now when in Opportunities module detailview we would like to open quick create subpanel for this new Product module, instead of default transfer to Product module editView form. How to do it?

    Sincerely,

    Antanas

  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: QuickCreate button for new module

    Hi Antanas

    You need to go to custom/Extension/modules/Opportunities/Ext/Layoutdefs/<package_name>.ext.php and modify the create button for your Products module.
    The new value should be: "SubPanelTopCreateButton".
    If there is not definition for the button inside this file you can edit it into modules/<Product Module>/metadata/subpanels/default.php.

    Then you need to go to Admin -> Repair -> Rebuild Extension.

    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
    Antanas0001 is offline Sugar Community Member
    Join Date
    Aug 2007
    Location
    Lithuania
    Posts
    41

    Default Re: QuickCreate button for new module

    Hi André,

    SubPanelTopCreateButton is alreay automatically defined in metadata\subpanels\default.php

    Now if I add SubPanelTopButtonQuickCreate into custom\modules\Opportunities\Ext\Layoutdefs\layout defs.ext.php
    the product subpanel create button foces "loading" to appear, but subpanel quick create form itself still does not appear. Why?

    'top_buttons' => array(
    array('widget_class' => 'SubPanelTopButtonQuickCreate'),
    ),

  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: QuickCreate button for new module

    Quote Originally Posted by Antanas0001
    Hi André,

    SubPanelTopCreateButton is alreay automatically defined in metadata\subpanels\default.php

    Now if I add SubPanelTopButtonQuickCreate into custom\modules\Opportunities\Ext\Layoutdefs\layout defs.ext.php
    the product subpanel create button foces "loading" to appear, but subpanel quick create form itself still does not appear. Why?

    'top_buttons' => array(
    array('widget_class' => 'SubPanelTopButtonQuickCreate'),
    ),
    Hi Antanas

    My bad! The correct really should be "SubPanelTopButtonQuickCreate"!
    If the text "Loading" appear and the quick create form not then it is possible there is some php error into editviewdefs.php of your custom module which unable SugarCRM ajax to retrieve the form.
    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.

  5. #5
    Antanas0001 is offline Sugar Community Member
    Join Date
    Aug 2007
    Location
    Lithuania
    Posts
    41

    Default Re: QuickCreate button for new module

    Hi André,

    There is a bug in SugarWidgetSubPanelTopButtonQuickCreate.php on line 80:

    $button = '<form onsubmit="return SUGAR.subpanelUtils.sendAndRetrieve(this.id, \'subpanel_' . strtolower($defines['child_module_name']) . '\',

    here child_module_name is incorrectly is assigned.

    i fixed it here and it now opens the quick create subpanel, but after saving it it doesn't close yet properly.
    Somewhere else must be another bug.

  6. #6
    lchassot is offline Member
    Join Date
    Nov 2008
    Posts
    5

    Default Re: QuickCreate button for new module

    Hello, I am having the same issue with Sugar Entreprise 5.1 with two new modules built with Module builder.
    I created a relationship with Accounts module, and did the modifications described
    here . But it does not work. A "loading" message appears but no quick create form

    There is something bizarre as well: The generated tpl in the cache/modules/SPEG0_AidesAccordees/ is named form_QuickCreate_SPEG0_AidesAccordees.tpl instead of QuickCreate.tpl. Is it normal ?

    Thank you in advance !
    Regards,
    Laurent Chassot.

  7. #7
    lukio's Avatar
    lukio is offline Sugar Community Member
    Join Date
    Jan 2008
    Location
    Argentina
    Posts
    32

    Default Re: QuickCreate button for new module

    Quote Originally Posted by Antanas0001 View Post
    Hi André,

    SubPanelTopCreateButton is alreay automatically defined in metadata\subpanels\default.php

    Now if I add SubPanelTopButtonQuickCreate into custom\modules\Opportunities\Ext\Layoutdefs\layout defs.ext.php
    the product subpanel create button foces "loading" to appear, but subpanel quick create form itself still does not appear. Why?

    'top_buttons' => array(
    array('widget_class' => 'SubPanelTopButtonQuickCreate'),
    ),
    Hello, I'm having the exact problem[0]. Did you resolved it ? Have any idea?

    [0] http://www.sugarcrm.com/forums/showthread.php?t=41175

    thanks in advance!
    Luciano Rossi
    gcoop - Cooperativa de Software Libre
    www.gcoop.com.ar

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Add a button in Contacts module
    By chinmayshah in forum Help
    Replies: 11
    Last Post: 2011-04-08, 08:01 AM
  2. I Can't Get Passed the Logon Page!
    By whatistocome in forum Help
    Replies: 109
    Last Post: 2010-12-28, 07:37 AM
  3. How to add a button to Cases module?
    By username2345 in forum Developer Help
    Replies: 4
    Last Post: 2008-08-29, 07:06 PM
  4. Replies: 0
    Last Post: 2007-11-21, 12:08 PM
  5. QuickCreate Task Button for Project Tasks
    By lougaou in forum Developer Help
    Replies: 4
    Last Post: 2007-06-28, 04:57 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
  •