Jump to content
We've recently updated our Privacy Statement, available here ×

Yuriy Plakosh

Jaspersoft Staff
  • Posts

    15
  • Joined

  • Last visited

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Posts posted by Yuriy Plakosh

  1. No references to 3rd party libraries in the global scope

    Starting JRS 8.0.0 the libraries used by JRS will not be exposed to the global scope. Because of that, an attempt to use jQuery from the global scope will not work unless jQuery is added to the global scope by your custom code.

    Use DOM API instead

    In JSP where your JavaScript code is, replace:

    jQuery(document).on("controls:initialized", function(event, controlsViewModel) {[/code]

    with

    document.addEventListener("controls:initialized", function(event, others) {        var controlsViewModel = event.detail;[/code]
  2. 1) You can modify default color palette used for Ad Hoc View based charts in scripts/adhoc/highchart.datamapper.js file:

        //
        // the highcharts default color palette
        //
        colors: [
                              '#4572A7',
                              '#AA4643',
                              '#89A54E',
                              '#80699B',
                              '#3D96AE',
                              '#DB843D',
                              '#92A8CD',
                              '#A47D7C',
                              '#B5CA92'
                            ],
     
    You can modify these colors, add new and/or remove existing ones.
     
    2) You can disable legend by adding 
            legend: {
                enabled: false
            },
    option to default options used in scripts/adhoc/highcharts.api.js file:
     
    var highchartsOptions = {
                chart: {
                    renderTo: 'chartContainer',
                    zoomType: 'xy',
                    jrstype: chartState.chartType,
                    type: HighchartsDataMapper.cast[chartState.chartType]
                },
           legend: {
                enabled: false
            },
     
                credits: {
                    enabled: false
                },
     
                tooltip: {
                    valueDecimals: 2
                },
     
                title: {
                    // Skip internal Highcharts title.
                    text: null
                }
            };

    Have in mind that changes will be applied to all Ad Hoc View based charts.

×
×
  • Create New...