Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: Custom fields in history subpanels ver: 6.5.4

  1. #1
    mediabiz Guest

    Angry Custom fields in history subpanels ver: 6.5.4

    Hi All,

    I have struggled for days to get custom categories visible in the History subpanel under Accounts. I have followed two great instructions from the Developer blog:
    SugarCRM Developer Blog » Blog Archive » HOWTO: Making upgrade-safe changes to the History subpanel

    SugarCRM Developer Blog » Blog Archive » Adding custom fields to the Activities or History subpanels but I can’t get any output in the History list.

    Added the file “custom/Extension/modules/Accounts/Ext/Layoutdefs/history_change.php”
    And loaded only history meetings for testing:
    $layout_defs['Accounts']["subpanel_setup"]["history"]["collection_list"] = array(
    'meetings' => array(
    'module' => 'Meetings',
    'subpanel_name' => 'ForHistory_mb',
    'get_subpanel_data' => 'meetings',
    ),
    );

    Copied the original ForHistory file to “custom/modules/Meetings/metadata/subpanels/ForHistory_mb.php”

    And all worked OK.

    The I tried to get the custom categories in the History list and added

    'categories' => array (
    'force_blank' => true,
    'force_exists' => true,
    'vname' => 'LBL_LIST_CATEGORIES',
    'force_default' => '(SELECT meetingcategories_c FROM meetings_cstm WHERE meetings_cstm.id_c=meetings.id) AS',
    ),

    The columns heading for categories are visible but no data!
    Pleas give me a hint.

    Regards
    John

  2. #2
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,491

    Default Re: Custom fields in history subpanels ver: 6.5.4

    Could you go over exactly what you are looking for on the screen and where it comes from on your system. It appears that you want a custom field (meetingcategories_c) from meetings to show up, is this correct?
    Kenneth Brill - Help Forum Moderator

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

    Look for these SugarCRM Tools
    SweetDBAdmin 1.9 - Intuitive web interface for your SugarCRM 6.4+ database (MySQL, SQL Server, Oracle and DB2)
    SweetUndelete 1.0 - The very best Undelete module for SugarCRM 6.4+. Allows admins and Users to undelete records and relationships
    SweetTinyMCEUpgrade - Upgrades your SugarCRM's TinyMCE installation to 3.5.8 (currently it's 3.4.4)
    SweetActivities 0.8 beta - An example of how to create a View on Calls, Meetings, Tasks and Emails so they can be viewed and reported on as one module. NOT FOR MSSQL YET



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

    Default Re: Custom fields in history subpanels ver: 6.5.4

    Harald Kuske
    Senior Sales Engineer Central Europe

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

    PLEASE SWITCH TO
    https://community.sugarcrm.com/, the FORUMS will be closed !


  4. #4
    khudabux Guest

    Default Re: Custom fields in history subpanels ver: 6.5.4

    Hi Dudes
    first of all i am little bit confused how can i add new thread that's why i am adding in this way ...
    I want to add a sub panel in account detail view(like contact), in which i want to show 4 columns(1,recently filed cases(5 days interval), 2-open cases,3-For Support cases, 4- Deploy able on cases)), means not whole data just number of recently filed cases, and number of open case (like 6 are open cases) , and on number a link should be when i click on number one popup appear and in popup open cases detail should be is it possible...? i am waiting for your replay..

  5. #5
    mediabiz Guest

    Unhappy Re: Custom fields in history subpanels ver: 6.5.4

    Dear Mr Brill

    Yes I want a custom field (meetingcategories_c) from meetings (db meetings_cstm) to show up, it is this correct?




    Dear Mr Kuske

    As you can see from my first post I have taken the cod from the article "Adding custom fields to the Activities or History subpanels"
    But I do not get any custom data in the History column "Categories".

    Do I need to declare the new array "categories" as a part of the array "subpanel_layout" some where else?

    Thanks for help
    John

  6. #6
    mediabiz Guest

    Angry Re: Custom fields in history subpanels ver: 6.5.4

    Anwer to Kenneth Brill

    Yes I want a custom field (meetingcategories_c) from meetings (db meetings_cstm) to show up, it is correct?



    Anwer to Harald Kuske

    As you can see from my first post I have taken the cod from the article "Adding custom fields to the Activities or History subpanels"
    But I do not get any custom data in the History column "Categories" in my example.

    Do I need to declare the new array "categories" as a part of the array "subpanel_layout" some where else?


    What more confusing, when I made a similar test to get custom data from the Tasks module with same code the fist column "start_date" works OK but not the column "categorie"! Se the code below:

    The date in second row comes from start_c in tasks_cstm but the data from categorie_c in same reccord does not turn up in next column "Kategori" (Swedish)!
    Name:  History_test.jpg
Views: 511
Size:  77.0 KB

    File “custom/modules/Tasks/metadata/subpanels/ForHistory_mb.php”
    Code:
          
           'date_start'=>array(
                    'force_blank' => true,
                    'force_exists' => true,
                    'vname' => 'LBL_LIST_KATEGORI',
                    'force_default' => '(SELECT start_c FROM tasks_cstm WHERE tasks_cstm.id_c=tasks.id) AS',
                       'vname' => 'LBL_DATE',
                            'width' => '10%',
            ),
    
           'categorie' =>  array (
                 'force_blank' => true,
                 'force_exists' => true,
                 'force_default' => '(SELECT categorie_c FROM tasks_cstm WHERE tasks_cstm.id_c=tasks.id) AS',  
                  'vname' => 'LBL_LIST_KATEGORI',
                   ),


    Does the datatype make a different maybee, varchar or date ?

    Pleas help

  7. #7
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,491

    Default Re: Custom fields in history subpanels ver: 6.5.4

    I'll look into this over the weekend.
    Kenneth Brill - Help Forum Moderator

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

    Look for these SugarCRM Tools
    SweetDBAdmin 1.9 - Intuitive web interface for your SugarCRM 6.4+ database (MySQL, SQL Server, Oracle and DB2)
    SweetUndelete 1.0 - The very best Undelete module for SugarCRM 6.4+. Allows admins and Users to undelete records and relationships
    SweetTinyMCEUpgrade - Upgrades your SugarCRM's TinyMCE installation to 3.5.8 (currently it's 3.4.4)
    SweetActivities 0.8 beta - An example of how to create a View on Calls, Meetings, Tasks and Emails so they can be viewed and reported on as one module. NOT FOR MSSQL YET



  8. #8
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,491

    Default Re: Custom fields in history subpanels ver: 6.5.4

    Can you set your log level to 'info' and send me a copy of your log after running the subpanel. I want to look at the generated SQL.
    Kenneth Brill - Help Forum Moderator

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

    Look for these SugarCRM Tools
    SweetDBAdmin 1.9 - Intuitive web interface for your SugarCRM 6.4+ database (MySQL, SQL Server, Oracle and DB2)
    SweetUndelete 1.0 - The very best Undelete module for SugarCRM 6.4+. Allows admins and Users to undelete records and relationships
    SweetTinyMCEUpgrade - Upgrades your SugarCRM's TinyMCE installation to 3.5.8 (currently it's 3.4.4)
    SweetActivities 0.8 beta - An example of how to create a View on Calls, Meetings, Tasks and Emails so they can be viewed and reported on as one module. NOT FOR MSSQL YET



  9. #9
    mediabiz Guest

    Unhappy Re: Custom fields in history subpanels ver: 6.5.4

    Tank you for your time!

    The developmen server ara now SugarCRM Version 6.5.2 (Build 8410).
    The case are to add custom categories to the History and Activities sub panels for Accounts and change date to start, sent and so on. The modules with custom categories are Meetings and Tasks.

    When the customer implemented Tasks categories via studio the “date_start” suddenly was stored in “tasks_custm.start_c” .
    ( "tasks_cstm" structure = id_c, kategori_c, huskategori_c, vu_c, start_c, slut_c, medarbetare_c )

    The following code fixed the date_start OK, but I could not get any data to the categories array.
    From “custom/modules/Tasks/metadata/subpanels/ForHistory_mb.php”
    Code:
    
    
           'date_start'=>array(
                     'force_blank' => true,
                     'force_exists' => true,
                     'force_default' => '(SELECT start_c FROM tasks_cstm WHERE tasks_cstm.id_c=tasks.id) AS',
                     'vname' => 'LBL_LIST_DATE',
                     'width' => '10%',
         ),
     
    
            'categories' =>  array (
                      'force_blank' => true,
                     'force_exists' => true,
                     'force_default' => '(SELECT kategori_c FROM tasks_cstm WHERE tasks_cstm.id_c=tasks.id) AS',   
                     'vname' => 'LBL_LIST_KATEGORI',
                     'width' => '15%',
                    ),
    And from “custom/modules/Meetings/metadata/subpanels/ForHistory_mb.php”
    Code:
     'categories' =>  array (
    
                     'force_blank' => true,
                     'force_exists' => true,
                     'force_default' => '(SELECT meetingkategori_c FROM meetings_cstm WHERE meetings_cstm.id_c=meetings.id) AS',        
                     'vname' => 'LBL_LIST_KATEGORI',
                     'width' => '15%',
                             ),
    ( Table structure for "meetings_cstm" = id_c, meetingkategori_c, contact_id_c, user_id_c )


    Some problems was solved when I changed the array names to “meetingkategori_c” and “kategori_c”!
    But only one modules custom categories are visible at the same time. I get the Meeting categories if the module are defined first in the array $layout_defs['Accounts']["subpanel_setup"]["history"]["collection_list"]

    In file “custom/Extensions/modules/Accounts/Ext/Layoutdefs/History_change.php”
    And the same happens for the Activities subpanel.

    Attachments: custom files and a log from loading an Account custom_subpanels.zipsugarcrm_log.zip

    Best Regars
    John

  10. #10
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,491

    Default Re: Custom fields in history subpanels ver: 6.5.4

    I will try to look at these tonight and get back to you.
    Kenneth Brill - Help Forum Moderator

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

    Look for these SugarCRM Tools
    SweetDBAdmin 1.9 - Intuitive web interface for your SugarCRM 6.4+ database (MySQL, SQL Server, Oracle and DB2)
    SweetUndelete 1.0 - The very best Undelete module for SugarCRM 6.4+. Allows admins and Users to undelete records and relationships
    SweetTinyMCEUpgrade - Upgrades your SugarCRM's TinyMCE installation to 3.5.8 (currently it's 3.4.4)
    SweetActivities 0.8 beta - An example of how to create a View on Calls, Meetings, Tasks and Emails so they can be viewed and reported on as one module. NOT FOR MSSQL YET



Page 1 of 2 12 LastLast

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Custom SubPanels History problem showing field
    By anotine in forum Developer Help
    Replies: 0
    Last Post: 2011-04-29, 03:02 PM
  2. Replies: 5
    Last Post: 2009-10-23, 10:43 AM
  3. Activities and History Subpanels in Custom Modules
    By cnielsenlev in forum Developer Help
    Replies: 13
    Last Post: 2008-09-23, 03:24 AM
  4. History of custom fields
    By duffy in forum General Discussion
    Replies: 2
    Last Post: 2008-07-30, 08:18 AM
  5. Custom fields in subpanels
    By dricrm in forum Developer Help
    Replies: 1
    Last Post: 2006-10-24, 01:46 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
  •