Do Json(Data type) shows on reports?

I am trying to create "Users with License type" reports, however when i add license type field on the reports it gives me error- " LayoutManager: Class not found:SugarWidgetFieldjson" , Any suggestion/advice will helpful.. 

Parents
  • Hello

    Can you share more details from your scenario? 
    Which Sugar version and deployment type are you running? 

    In a 13.0 version, I can't reproduce what you are describing as in the column picker in the Report the "License Type" is not exposed in the report editor: 




    With that in mind, if you are running an instance with IDM enabled the best way to retrieve this information is from the Users List view on the Sugar Cloud settings page: 






    Looking forward to hearing from you. 

    André

  • Hey André, 

    Thank you for investing your time here, I really appreciate it.

    Firstly, 'License Type' field needs to 'reportable' from the settings to show up on the reports.

    Secondly, I think I am on 12 version.

  • Hello

    Thanks for the extra clarification. 
    What settings are you referring to? I was only able to see this field selectable in the reports by creating the custom Vardef file with the following content: 

    custom/Extension/modules/Users/Ext/Vardefs/sugarfield_license_type.php 

    <?php
    $dictionary['User']['fields']['license_type']['reportable']=true;
     ?>
    


    After this customisation, I could finally reproduce the error that you are reporting. 
    This happens because Sugar can't find a widget to render the field in the report. 

    I could overcome this by creating a custom SugarWidget extending the SugarWidgetFieldMultiEnum widget

    custom/include/generic/SugarWidgets/SugarWidgetFieldjson.php

    After a quick repair and rebuild the values do show in the report, however, this will show the DB values that are different from the values that show in the list view. 




    If you want to pursue this approach, you can try editing this widget to use the function that the field originally is using getSystemLicenseTypesSelections() in User.php/ 

    But I still feel an easier approach to use the list view or the list view in the CloudSettings Wink.

    I hope this guides you in a good direction. 

    André

Reply
  • Hello

    Thanks for the extra clarification. 
    What settings are you referring to? I was only able to see this field selectable in the reports by creating the custom Vardef file with the following content: 

    custom/Extension/modules/Users/Ext/Vardefs/sugarfield_license_type.php 

    <?php
    $dictionary['User']['fields']['license_type']['reportable']=true;
     ?>
    


    After this customisation, I could finally reproduce the error that you are reporting. 
    This happens because Sugar can't find a widget to render the field in the report. 

    I could overcome this by creating a custom SugarWidget extending the SugarWidgetFieldMultiEnum widget

    custom/include/generic/SugarWidgets/SugarWidgetFieldjson.php

    After a quick repair and rebuild the values do show in the report, however, this will show the DB values that are different from the values that show in the list view. 




    If you want to pursue this approach, you can try editing this widget to use the function that the field originally is using getSystemLicenseTypesSelections() in User.php/ 

    But I still feel an easier approach to use the list view or the list view in the CloudSettings Wink.

    I hope this guides you in a good direction. 

    André

Children