Results 1 to 2 of 2

Thread: SugarPro 624 : Custom Sugarwidget type field in Reports filters

  1. #1
    yannick038 is offline Sugar Community Member
    Join Date
    Nov 2009
    Posts
    49

    Default SugarPro 624 : Custom Sugarwidget type field in Reports filters

    Hello all,

    We're using SugarPro 624 and have created new fields to extend the base types of SugarCRM

    So we created a new fields' type "customType" (for example), and we added a new field of this given type to accounts using studio. This works well for edit/detail/list/search view.

    But we are using reports too, and so we wanted to filter's the results of the accounts using this new field.

    But when I'm trying to add the filter critera there's a problem in reports.js as the type "CustomType" is not definied in filter_defs[] javascript array.

    And so, as it's not defined, there's no filter's input, nor delete filter link, the module is freezed and we need to reload the page loosing all modifications. I've searched through all sugar code, to look where this filder_defs array could been defined but didn't find it (there's template.php in reports module, but I think this is old code not used anymore ?)

    I think we need to modify the reports module to tell sugar there's a new field's type so I'm looking on how to perform this steps, what are the files and if we were able to make the changes in an upgrade-safe way.

    If you have any information, thanks in advance for sharing it.

    Regards
    Attached Images Attached Images  

  2. #2
    Captivea's Avatar
    Captivea is offline Sugar Community Member
    Join Date
    Aug 2010
    Posts
    57

    Lightbulb Re: SugarPro 624 : Custom Sugarwidget type field in Reports filters

    Reports modules uses a JS cache file generated by PHP file to store all the fields defs per module and the filter's available per Sugarwidget type.

    Problem is that the code is not dynamic and so adding a new type using module loader will result in patching the PHP file in a not upgrade-safe way.

    cached JS file : cache/modules/modules_def_<lang>_<md5>.js
    php file generating the cache file : modules/Reports/templates/templates_modules_def_js.php

    Maybe Sugar should try to make an opened and dynamically built cache file based also on custom types ?
    Captivea
    Partenaire officiel SugarCRM France
    Découvrez nos solutions CRM basées sur SugarCRM
    -----
    695 av. Paul Louis Merlin - "Espace Merlin" - 73800 Montmélian
    Tél : 08 11 69 63 30 – Fax : 09 72 13 05 20

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Create custom subpanel sugarwidget
    By ac3t in forum Developer Help
    Replies: 0
    Last Post: 2011-06-17, 11:27 AM
  2. Replies: 1
    Last Post: 2010-08-31, 10:23 PM
  3. Adding filters in print reports
    By Systems Navigator in forum Feature Requests
    Replies: 0
    Last Post: 2009-09-22, 09:12 PM
  4. Replies: 0
    Last Post: 2009-02-23, 07:30 AM
  5. custom module custom field relate type error
    By kidpollo in forum General Discussion
    Replies: 0
    Last Post: 2007-03-24, 02:14 AM

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
  •