@datarailsshared/dr_renderer 1.2.463 → 1.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,9 @@
1
1
  const helpers = require('./dr-renderer-helpers');
2
2
  const { DrGaugeChart, GAUGE_OPTIONS_DEFAULT } = require('./charts/dr_gauge_chart');
3
+ const { DrDonutChart } = require('./charts/dr_donut_chart');
3
4
  const seriesPointStylesHelper= require('./seriesPointStyles-helper');
5
+ const smartQueriesHelper = require('./smart_queries_helper');
6
+ const {DrGaugeCategoriesSummaryChart} = require("./charts/dr_gauge_categories_summary_chart");
4
7
 
5
8
  const mobileBrowserRegex = new RegExp([
6
9
  '(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)',
@@ -58,6 +61,7 @@ const CHART_TYPES = {
58
61
  GAUGE_SOLID_CHART: 'gauge-solid-chart',
59
62
  GAUGE_CHART: 'gauge-chart',
60
63
  GAUGE_CHART_ENHANCED: 'gauge-chart-enhanced',
64
+ GAUGE_CHART_CATEGORIES_SUMMARY: 'gauge-chart-categories-summary',
61
65
  KPI_WIDGET: 'kpi-widget',
62
66
  TEXT_WIDGET: 'text-widget',
63
67
  WATERFALL_BREAKDOWN: 'waterfall-chart-breakdown',
@@ -65,6 +69,7 @@ const CHART_TYPES = {
65
69
  PUBLISHED_ITEM: 'published_item',
66
70
  RICH_TEXT: 'rich_text',
67
71
  EXCEL_VIEWER: 'excel_viewer',
72
+ DONUT_CHART: 'donut-chart',
68
73
  }
69
74
 
70
75
  const HIGHCHARTS_CONSTANTS = {
@@ -397,6 +402,22 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
397
402
  return {};
398
403
  };
399
404
 
405
+ const isChartTypeSupportedForSmartQuery = (type) => {
406
+ if (!type) return null;
407
+ return [
408
+ 'line',
409
+ 'line-chart-forecast',
410
+ 'spline',
411
+ 'area',
412
+ 'areaspline',
413
+ highchartsRenderer.CHART_TYPES.LINE_CHART,
414
+ highchartsRenderer.CHART_TYPES.LINE_CHART_SMOOTH,
415
+ highchartsRenderer.CHART_TYPES.AREA_CHART,
416
+ highchartsRenderer.CHART_TYPES.AREA_CHART_SMOOTH,
417
+ ].includes(type);
418
+ };
419
+
420
+
400
421
  const chartHasVerticalDataLabelsOption = (type) => {
401
422
  return ![
402
423
  highchartsRenderer.CHART_TYPES.LINE_CHART,
@@ -1246,6 +1267,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1246
1267
  .replace(highchartsRenderer.DR_OTHERS_KEY, othersName);
1247
1268
  ob.name = highchartsRenderer.getFormattedRowKey(ob.initialName, pivotData);
1248
1269
  }
1270
+
1249
1271
  lodash.forEach(col_n_keys, function (col_n_value, index) {
1250
1272
  var agg = pivotData.getAggregator(row_n_value, col_n_value);
1251
1273
  var val = agg.value();
@@ -1256,13 +1278,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1256
1278
  if (val != null) {
1257
1279
  if ($.isNumeric(val)) {
1258
1280
  val = parseFloat(val);
1259
- // if (val > -1 && val < 1) {
1260
- // val = parseFloat(val.toPrecision(4));
1261
- // } else {
1262
- // val = parseFloat(val.toFixed(2));
1263
- // }
1264
1281
  }
1265
- } else {
1282
+ } else if (helpers.isShowingEmptyValues(additionOptions)) {
1266
1283
  if (onlyNumbers)
1267
1284
  val = NaN;
1268
1285
  else
@@ -1296,7 +1313,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1296
1313
  );
1297
1314
  });
1298
1315
 
1299
- if (colors && colors[i]) {
1316
+ if (additionOptions && additionOptions.series_colors) {
1317
+ ob.color = additionOptions.series_colors[row_n_value] || undefined;
1318
+ } else if (colors && colors[i]) {
1300
1319
  ob.color = colors[i];
1301
1320
  }
1302
1321
 
@@ -1398,6 +1417,22 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1398
1417
  chart_series = chart_series.concat(trendSerieses);
1399
1418
 
1400
1419
  highchartsRenderer.moveSeriesToSecondYAxisIfNeeded(chart_series, pivotData, chartOptions, additionOptions, opts, opts.total && opts.totalSeriesSettings && opts.totalSeriesSettings.secondaryAxis);
1420
+
1421
+ const chartType = chartOptions && chartOptions.chart && chartOptions.chart.type ? chartOptions.chart.type : null;
1422
+ const smartQuerySeries = isChartTypeSupportedForSmartQuery(chartType)
1423
+ ? smartQueriesHelper.createSingleDataSeriesForForecast(chart_series, opts.chartOptions, pivotData)
1424
+ : null;
1425
+
1426
+ if (smartQuerySeries) {
1427
+ if (chart_series.length > 1) {
1428
+ lodash.remove(chart_series, s =>
1429
+ (s.name && lodash.includes(s.name, 'SQ_Actuals')) || s.name === 'Forecast'
1430
+ );
1431
+ } else {
1432
+ chart_series = []
1433
+ }
1434
+ chart_series.push(smartQuerySeries);
1435
+ }
1401
1436
 
1402
1437
  return chart_series;
1403
1438
  };
@@ -1450,13 +1485,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1450
1485
  if (val != null) {
1451
1486
  if ($.isNumeric(val)) {
1452
1487
  val = parseFloat(val);
1453
- // if (val > -1 && val < 1) {
1454
- // val = parseFloat(val.toPrecision(4));
1455
- // } else {
1456
- // val = parseFloat(val.toFixed(2));
1457
- // }
1458
1488
  }
1459
- } else {
1489
+ } else if (helpers.isShowingEmptyValues(additionOptions)) {
1460
1490
  if (onlyNumbers)
1461
1491
  val = NaN;
1462
1492
  else
@@ -1489,7 +1519,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1489
1519
  ob.data.push(tmoobj);
1490
1520
  });
1491
1521
 
1492
- if (colors && colors[i]) {
1522
+ if (additionOptions && additionOptions.series_colors) {
1523
+ ob.color = additionOptions.series_colors[row_n_value] || undefined;
1524
+ } else if (colors && colors[i]) {
1493
1525
  ob.color = colors[i];
1494
1526
  }
1495
1527
 
@@ -1539,6 +1571,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1539
1571
  } else if (seriesIndex === chart_series.length - 1 && chart_series.length > 1 && !has_delta && !opts.total && !trendSerieses.length) {
1540
1572
  series.type = 'line';
1541
1573
  }
1574
+ series.connectNulls = !helpers.isShowingEmptyValues(additionOptions);
1542
1575
  });
1543
1576
  }
1544
1577
 
@@ -1917,6 +1950,10 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1917
1950
  // check string contains hebrew
1918
1951
  ob.initialName = (/[\u0590-\u05FF]/).test(key) ? ('\u200E' + key) : key;
1919
1952
 
1953
+ if (additionOptions && additionOptions.series_colors) {
1954
+ ob.color = additionOptions.series_colors[key] || undefined;
1955
+ }
1956
+
1920
1957
  if (ob.initialName === highchartsRenderer.DR_OTHERS_KEY) {
1921
1958
  ob.initialName = othersName;
1922
1959
  }
@@ -2067,8 +2104,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2067
2104
  opposite: true,
2068
2105
  tickPositioner: function () {
2069
2106
  const primaryAxisTicksCount = this.chart.yAxis[0].tickPositions.length;
2070
- const minFromSettings = parseInt(lodash.get(opts, 'comboOptions.secondaryAxisSettings.min'));
2071
- const maxFromSettings = parseInt(lodash.get(opts, 'comboOptions.secondaryAxisSettings.max'));
2107
+ const minFromSettings = parseFloat(lodash.get(opts, 'comboOptions.secondaryAxisSettings.min'));
2108
+ const maxFromSettings = parseFloat(lodash.get(opts, 'comboOptions.secondaryAxisSettings.max'));
2072
2109
  let secondaryAxisMin = !isNaN(minFromSettings) ? minFromSettings : this.tickPositions[0];
2073
2110
  let secondaryAxisMax = !isNaN(maxFromSettings) ? maxFromSettings : this.tickPositions[this.tickPositions.length - 1];
2074
2111
 
@@ -2193,6 +2230,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2193
2230
  }];
2194
2231
  chartOptions.legend = highchartsRenderer.getOptionsForLegends(additionOptions, 1, false, true);
2195
2232
 
2233
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2234
+
2196
2235
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2197
2236
  };
2198
2237
 
@@ -2226,9 +2265,6 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2226
2265
  return {aggfunc: aggfunc, base: base};
2227
2266
  }
2228
2267
 
2229
- highchartsRenderer.ptRenderSolidGauge = (pivotData, opts) => {
2230
- return highchartsRenderer.ptRenderGauge(pivotData, opts, true);
2231
- };
2232
2268
 
2233
2269
  highchartsRenderer.transformOldGaugeOptions = (oldOptions) => {
2234
2270
  const newOptions = highchartsRenderer.objectCopyJsonMethod(oldOptions);
@@ -2265,194 +2301,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2265
2301
  return new DrGaugeChart(pivotData, opts).render();
2266
2302
  };
2267
2303
 
2268
- highchartsRenderer.ptRenderGauge = (pivotData, opts, isSolidGauge = false) => {
2269
- const gaugeopts = opts.chartOptions
2270
- || highchartsRenderer.getDefaultValueForChart(isSolidGauge ? 'gauge-solid-chart' : 'gauge-chart');
2271
-
2272
- const chartOptions = {
2273
- chart: {
2274
- type: isSolidGauge ? 'solidgauge' : 'gauge',
2275
- animation: disableAnimation ? false : true,
2276
- },
2277
- plotOptions: {
2278
- solidgauge: {
2279
- allowPointSelect: true,
2280
- cursor: 'pointer',
2281
- dataLabels: {
2282
- allowOverlap: gaugeopts && gaugeopts.label
2283
- ? gaugeopts.label.overlap
2284
- : false,
2285
- y: 5,
2286
- borderWidth: 0,
2287
- useHTML: true,
2288
- style: highchartsRenderer.getDataLabelsStyle(gaugeopts),
2289
- },
2290
- },
2291
- series: {
2292
- animation: !disableAnimation,
2293
- },
2294
- },
2295
- credits: {
2296
- enabled: false,
2297
- },
2298
- xAxis: {
2299
- categories: highchartsRenderer.getFormattedColKeys(pivotData, null),
2300
- },
2301
- yAxis: isSolidGauge
2302
- ? {
2303
- min: 0,
2304
- max: gaugeopts.range.max,
2305
- stops: [
2306
- [gaugeopts.range.low / 100, '#55BF3B'], // green
2307
- [gaugeopts.range.medium / 100, '#DDDF0D'], // yellow
2308
- [gaugeopts.range.high / 100, '#DF5353'], // red
2309
- ],
2310
- lineWidth: 0,
2311
- minorTickInterval: null,
2312
- tickPixelInterval: 400,
2313
- tickWidth: 0,
2314
- labels: {
2315
- y: 16,
2316
- },
2317
- }
2318
- : {
2319
- min: 0,
2320
- max: gaugeopts.range.max,
2321
- minorTickInterval: 'auto',
2322
- minorTickWidth: 1,
2323
- minorTickLength: 10,
2324
- minorTickPosition: 'inside',
2325
- minorTickColor: CHART_COLORS.TICK_COLOR,
2326
- tickPixelInterval: 30,
2327
- tickWidth: 2,
2328
- tickPosition: 'inside',
2329
- tickLength: 10,
2330
- tickColor: CHART_COLORS.TICK_COLOR,
2331
- labels: {
2332
- step: 2,
2333
- rotation: 'auto',
2334
- },
2335
- title: {
2336
- text: '', //'km/h'
2337
- },
2338
- plotBands: [
2339
- {
2340
- from: 0,
2341
- to: (gaugeopts.range.max * gaugeopts.range.low) / 100,
2342
- color: '#55BF3B', // green
2343
- },
2344
- {
2345
- from: (gaugeopts.range.max * gaugeopts.range.low) / 100,
2346
- to: (gaugeopts.range.max * gaugeopts.range.medium) / 100,
2347
- color: '#DDDF0D', // yellow
2348
- },
2349
- {
2350
- from: (gaugeopts.range.max * gaugeopts.range.medium) / 100,
2351
- to: gaugeopts.range.max,
2352
- color: '#DF5353', // red
2353
- },
2354
- ],
2355
- },
2356
- pane: isSolidGauge
2357
- ? {
2358
- center: ['50%', '85%'],
2359
- size: '140%',
2360
- startAngle: -90,
2361
- endAngle: 90,
2362
- background: {
2363
- backgroundColor: (highchartsRenderer.highcharts_theme && highchartsRenderer.highcharts_theme .background2) || '#EEE',
2364
- innerRadius: '60%',
2365
- outerRadius: '100%',
2366
- shape: 'arc',
2367
- },
2368
- }
2369
- : {
2370
- startAngle: -150,
2371
- endAngle: 150,
2372
- background: [
2373
- {
2374
- backgroundColor: {
2375
- linearGradient: { x1: 0, y1: 0, x2: 0, y2: 1 },
2376
- stops: [
2377
- [0, CHART_COLORS.BACKGROUND],
2378
- [1, '#333'],
2379
- ],
2380
- },
2381
- borderWidth: 0,
2382
- outerRadius: '109%',
2383
- },
2384
- {
2385
- backgroundColor: {
2386
- linearGradient: { x1: 0, y1: 0, x2: 0, y2: 1 },
2387
- stops: [
2388
- [0, '#333'],
2389
- [1, CHART_COLORS.BACKGROUND],
2390
- ],
2391
- },
2392
- borderWidth: 1,
2393
- outerRadius: '107%',
2394
- },
2395
- {
2396
- // default background
2397
- },
2398
- {
2399
- backgroundColor: '#DDD',
2400
- borderWidth: 0,
2401
- outerRadius: '105%',
2402
- innerRadius: '103%',
2403
- },
2404
- ],
2405
- },
2406
- };
2407
-
2408
- chartOptions.series = highchartsRenderer.ptCreateGaugeSeries(pivotData, opts, chartOptions, gaugeopts, isSolidGauge);
2409
-
2410
- highchartsRenderer.setTitleAndSubTitle(chartOptions, opts, gaugeopts);
2411
- chartOptions.plotOptions.solidgauge = highchartsRenderer.getDataLabelsOptions(gaugeopts, chartOptions.plotOptions.solidgauge);
2412
-
2413
- return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2304
+ highchartsRenderer.ptRenderGaugeCategoriesSummary = (pivotData, opts) => {
2305
+ return new DrGaugeCategoriesSummaryChart(pivotData, opts).render();
2414
2306
  };
2415
-
2416
- highchartsRenderer.ptCreateGaugeSeries = (pivotData, opts, chartOptions, gaugeopts, isSolidGauge) => {
2417
- const lineSeries = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, true, null, null, opts, chartOptions);
2418
-
2419
- let total = [];
2420
- lodash.forEach(lineSeries, (obj) => {
2421
- lodash.forEach(obj.data, (arr2) => {
2422
- total = total.concat(arr2);
2423
- });
2424
- });
2425
- total = lodash.filter(total, value => !isNaN(value));
2426
-
2427
- let aggfunc = (a, b) => a + b;
2428
- let base = 0;
2429
- let __ret = highchartsRenderer.getSingleValueAgg(gaugeopts, aggfunc, base);
2430
-
2431
- aggfunc = __ret.aggfunc;
2432
- base = __ret.base;
2433
-
2434
- const aggregator = pivotData.getAggregator([], []);
2435
- const value = total.length > 0 ? total.reduce(aggfunc, base) : aggregator.value();
2436
- const valueFormatted = lodash.isNumber(value) ? aggregator.format(value, true) : value;
2437
-
2438
- let gaugeSeries = [
2439
- {
2440
- name: '',
2441
- colorByPoint: true,
2442
- data: [value],
2443
- dataLabels: {
2444
- format: `<div style="text-align:center"><span style="font-size:${ isSolidGauge ? 25 : 15 }px;color:black">`
2445
- + valueFormatted + '</span><br/><span style="font-size:12px;color:silver"></span></div>',
2446
- enabled: gaugeopts && gaugeopts.label && !isSolidGauge ? gaugeopts.label.show : true,
2447
- allowOverlap: gaugeopts && gaugeopts.label ? gaugeopts.label.overlap : false,
2448
- style: highchartsRenderer.getDataLabelsStyle(gaugeopts),
2449
- },
2450
- },
2451
- ];
2452
- gaugeSeries[0] = highchartsRenderer.getDataLabelsOptions(gaugeopts, gaugeSeries[0]);
2453
-
2454
- return gaugeSeries;
2455
- };
2456
2307
 
2457
2308
  highchartsRenderer.ptRenderKpi = function (pivotData, opts) {
2458
2309
  var chartOptions = {};
@@ -2600,10 +2451,16 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2600
2451
  else if (!pivotData.isDrillDownDisabled)
2601
2452
  chartOptions.drilldown = highchartsRenderer.ptCreateDrillDownSeriesToDrilldownChart(pivotData, chartOptions, additionOptions, opts);
2602
2453
 
2454
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2455
+
2603
2456
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2604
2457
 
2605
2458
  };
2606
2459
 
2460
+ highchartsRenderer.ptRenderDonut = function (pivotData, opts, drilldownFunc) {
2461
+ return new DrDonutChart(highchartsRenderer, pivotData, opts, drilldownFunc, disableAnimation).render();
2462
+ };
2463
+
2607
2464
  highchartsRenderer.setTitleAndSubTitle = function (chartOptions, opts, additionOptions) {
2608
2465
  chartOptions.title = opts.chartOptions.hideChartHeader ? { text: null } : {
2609
2466
  align: 'center',
@@ -2672,7 +2529,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2672
2529
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
2673
2530
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
2674
2531
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
2675
- }
2532
+ },
2533
+ connectNulls: !helpers.isShowingEmptyValues(additionOptions),
2676
2534
  }
2677
2535
  };
2678
2536
 
@@ -2709,6 +2567,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2709
2567
  if (opts.selectedPoint) {
2710
2568
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
2711
2569
  }
2570
+
2571
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2572
+
2712
2573
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2713
2574
  };
2714
2575
 
@@ -2758,7 +2619,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2758
2619
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
2759
2620
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
2760
2621
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
2761
- }
2622
+ },
2623
+ connectNulls: !helpers.isShowingEmptyValues(additionOptions),
2762
2624
  }
2763
2625
  };
2764
2626
 
@@ -2794,6 +2656,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2794
2656
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
2795
2657
  }
2796
2658
 
2659
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2660
+
2797
2661
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2798
2662
  };
2799
2663
 
@@ -2852,8 +2716,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2852
2716
  allowOverlap: additionOptions && additionOptions.label ? additionOptions.label.overlap : false,
2853
2717
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
2854
2718
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
2855
- style: highchartsRenderer.getDataLabelsStyle(additionOptions)
2856
- }
2719
+ style: highchartsRenderer.getDataLabelsStyle(additionOptions),
2720
+ },
2721
+ connectNulls: !helpers.isShowingEmptyValues(additionOptions),
2857
2722
  }
2858
2723
  };
2859
2724
 
@@ -2890,6 +2755,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2890
2755
  if (opts.selectedPoint) {
2891
2756
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
2892
2757
  }
2758
+
2759
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2760
+
2893
2761
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2894
2762
  };
2895
2763
 
@@ -2936,13 +2804,14 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2936
2804
  }
2937
2805
  };
2938
2806
  chartOptions = highchartsRenderer.prepareAxisX(chartOptions, additionOptions, pivotData.getColKeys());
2939
- chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, null, opts, chartOptions);
2807
+ chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, additionOptions, opts, chartOptions);
2940
2808
 
2941
2809
  highchartsRenderer.handleGridLines(additionOptions, chartOptions);
2942
2810
 
2811
+ const isShowingEmptyValues = helpers.isShowingEmptyValues(additionOptions);
2943
2812
  chartOptions.plotOptions = {
2944
2813
  [type === 'area-chart' ? 'area' : 'areaspline']: {
2945
- stacking: 'normal',
2814
+ stacking: isShowingEmptyValues ? 'normal' : undefined,
2946
2815
  lineColor: CHART_COLORS.TICK_COLOR,
2947
2816
  lineWidth: 1,
2948
2817
  marker: {
@@ -2957,7 +2826,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2957
2826
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
2958
2827
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
2959
2828
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
2960
- }
2829
+ },
2830
+ connectNulls: !isShowingEmptyValues,
2961
2831
  }
2962
2832
  };
2963
2833
 
@@ -2977,6 +2847,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
2977
2847
  if (opts.selectedPoint) {
2978
2848
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
2979
2849
  }
2850
+
2851
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2852
+
2980
2853
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
2981
2854
  };
2982
2855
 
@@ -3013,7 +2886,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3013
2886
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
3014
2887
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
3015
2888
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
3016
- }
2889
+ },
2890
+ connectNulls: !helpers.isShowingEmptyValues(additionOptions),
3017
2891
  }
3018
2892
  };
3019
2893
 
@@ -3040,10 +2914,12 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3040
2914
  },
3041
2915
  lineWidth: 0
3042
2916
  };
3043
- chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, null, opts, chartOptions);
2917
+ chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, additionOptions, opts, chartOptions);
3044
2918
 
3045
2919
  chartOptions.legend = highchartsRenderer.getOptionsForLegends(additionOptions, rowAttrs.length, false);
3046
2920
 
2921
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
2922
+
3047
2923
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3048
2924
  };
3049
2925
 
@@ -3108,7 +2984,6 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3108
2984
  highchartsRenderer.setYAxisMinMax(chartOptions.yAxis, additionOptions.axisY);
3109
2985
  }
3110
2986
 
3111
-
3112
2987
  chartOptions.tooltip = {
3113
2988
  formatter: highchartsRenderer.defaultFormatterToTooltip(pivotData, opts),
3114
2989
  valueDecimals: 2,
@@ -3139,7 +3014,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3139
3014
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
3140
3015
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
3141
3016
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
3142
- }
3017
+ },
3143
3018
  }
3144
3019
  };
3145
3020
  if (opts.drillDownListFunc) {
@@ -3161,6 +3036,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3161
3036
  chartOptions.legend = highchartsRenderer.getOptionsForLegends(additionOptions, rowAttrs.length, false);
3162
3037
 
3163
3038
  chartOptions.drilldown = highchartsRenderer.getDataLabelsStylesForDrillDown(additionOptions);
3039
+
3040
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3041
+
3164
3042
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3165
3043
  };
3166
3044
 
@@ -3306,7 +3184,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3306
3184
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
3307
3185
  }
3308
3186
 
3309
- highchartsRenderer.handleGridLines(additionOptions, chartOptions)
3187
+ highchartsRenderer.handleGridLines(additionOptions, chartOptions);
3188
+
3189
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3310
3190
 
3311
3191
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3312
3192
  };
@@ -3395,6 +3275,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3395
3275
 
3396
3276
  highchartsRenderer.handleGridLines(additionOptions, chartOptions)
3397
3277
 
3278
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3279
+
3398
3280
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3399
3281
  };
3400
3282
 
@@ -3439,7 +3321,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3439
3321
  },
3440
3322
  };
3441
3323
  chartOptions = highchartsRenderer.prepareAxisX(chartOptions, additionOptions, pivotData.getColKeys());
3442
- chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, null, opts, chartOptions);
3324
+ chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, additionOptions, opts, chartOptions);
3443
3325
 
3444
3326
  highchartsRenderer.handleGridLines(additionOptions, chartOptions)
3445
3327
 
@@ -3457,7 +3339,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3457
3339
  enabled: additionOptions && additionOptions.label ? additionOptions.label.show : true,
3458
3340
  formatter: highchartsRenderer.defaultDataLabelFormatter(pivotData, opts),
3459
3341
  style: highchartsRenderer.getDataLabelsStyle(additionOptions)
3460
- }
3342
+ },
3461
3343
  }
3462
3344
  };
3463
3345
 
@@ -3475,6 +3357,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3475
3357
  if (opts.selectedPoint) {
3476
3358
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
3477
3359
  }
3360
+
3361
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3362
+
3478
3363
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3479
3364
  };
3480
3365
 
@@ -3562,12 +3447,14 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3562
3447
  },
3563
3448
  };
3564
3449
  chartOptions = highchartsRenderer.prepareAxisX(chartOptions, additionOptions, pivotData.getColKeys());
3565
- chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, null, opts, chartOptions);
3450
+ chartOptions.series = highchartsRenderer.ptCreateBasicLineSeries(pivotData, null, null, null, additionOptions, opts, chartOptions);
3566
3451
 
3567
3452
  if (opts.selectedPoint) {
3568
3453
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
3569
3454
  }
3570
- highchartsRenderer.handleGridLines(additionOptions, chartOptions)
3455
+ highchartsRenderer.handleGridLines(additionOptions, chartOptions);
3456
+
3457
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3571
3458
 
3572
3459
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3573
3460
  };
@@ -3692,6 +3579,9 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3692
3579
  if (opts.selectedPoint) {
3693
3580
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
3694
3581
  }
3582
+
3583
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3584
+
3695
3585
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3696
3586
  };
3697
3587
 
@@ -3812,6 +3702,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
3812
3702
  seriesPointStylesHelper.setInitialPointStyles(opts, chartOptions.series);
3813
3703
  }
3814
3704
 
3705
+ helpers.disableLegendInteractionIfRequired(chartOptions, additionOptions);
3706
+
3815
3707
  return highchartsRenderer.ptCreateElementAndDraw(chartOptions, opts);
3816
3708
  }
3817
3709
 
@@ -4438,7 +4330,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
4438
4330
  let ret_str = '';
4439
4331
  if (options && options.total_value_options && options.total_value_options.filter_options && options.total_value_options.filter_options.axis == tr_axis) {
4440
4332
  //TODO add tooltip with description of filter
4441
- ret_str += '<i class="fa fa-filter"></i>';
4333
+ ret_str += '<i class="dr-icon-filter-old"></i>';
4442
4334
  }
4443
4335
 
4444
4336
  return ret_str;
@@ -6704,12 +6596,13 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
6704
6596
  category_class: 'google-visualization-charteditor-mini-more',
6705
6597
  category_label: 'Chart',
6706
6598
  category_type: 'chart',
6707
- elements: [{
6708
- element_type: 'input',
6709
- value_name: 'colors_offset',
6710
- element_label: 'Colors offset',
6711
- default_value: 0
6712
- },
6599
+ elements: [
6600
+ {
6601
+ element_type: 'input',
6602
+ value_name: 'colors_offset',
6603
+ element_label: 'Colors offset',
6604
+ default_value: 0
6605
+ },
6713
6606
  {
6714
6607
  element_type: 'radio',
6715
6608
  value_name: 'zoom_type',
@@ -6721,12 +6614,19 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
6721
6614
  {label: 'xy', value: 'xy'}
6722
6615
  ],
6723
6616
  default_value: 'None'
6724
- }, {
6617
+ },
6618
+ {
6725
6619
  element_type: 'checkbox',
6726
6620
  value_name: 'show',
6727
6621
  element_label: 'Show grid',
6728
6622
  default_value: true
6729
- }
6623
+ },
6624
+ {
6625
+ element_type: 'checkbox',
6626
+ value_name: 'dislay_empty_values',
6627
+ element_label: 'Display empty values',
6628
+ default_value: true
6629
+ },
6730
6630
  ]
6731
6631
  },
6732
6632
  'chart_grid': {
@@ -6748,8 +6648,115 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
6748
6648
  value_name: 'showAllLegends',
6749
6649
  element_label: 'Show legends over 10',
6750
6650
  default_value: false
6651
+ },
6652
+ {
6653
+ element_type: 'checkbox',
6654
+ value_name: 'dislay_empty_values',
6655
+ element_label: 'Display empty values',
6656
+ default_value: true
6657
+ },
6658
+ {
6659
+ element_type: 'devider',
6660
+ element_label: 'Chart Patterns',
6661
+ showFn: isChartTypeSupportedForSmartQuery
6662
+ },
6663
+ {
6664
+ element_type: 'toggle',
6665
+ element_label: 'Forecast Chart',
6666
+ value_name: 'smart_query',
6667
+ default_value: true,
6668
+ showFn: isChartTypeSupportedForSmartQuery
6669
+ },
6670
+ {
6671
+ element_type: 'select',
6672
+ value_name: 'actuals',
6673
+ element_label: 'Actuals',
6674
+ element_options: [
6675
+ {label: 'Solid', value: 'solid'},
6676
+ {label: 'Dash', value: 'dash'},
6677
+ ],
6678
+ default_value: 'Solid',
6679
+ showFn: isChartTypeSupportedForSmartQuery
6680
+ },
6681
+ {
6682
+ element_type: 'select',
6683
+ value_name: 'forecast',
6684
+ element_label: 'Forecast',
6685
+ element_options: [
6686
+ {label: 'Solid', value: 'solid'},
6687
+ {label: 'Dash', value: 'dash'},
6688
+ ],
6689
+ default_value: 'Dash',
6690
+ showFn: isChartTypeSupportedForSmartQuery
6691
+ }
6692
+ ]
6693
+ },
6694
+ 'total_value_label_donut': {
6695
+ category_class: 'google-visualization-charteditor-mini-more',
6696
+ category_label: 'Total Value Label',
6697
+ category_type: 'total_value_label',
6698
+ elements: [{
6699
+ element_type: 'input',
6700
+ value_name: 'total_value_label_text',
6701
+ element_label: 'Total value label text for donut chart',
6702
+ default_value: 'Total'
6751
6703
  }]
6752
6704
  },
6705
+ 'chart_position': {
6706
+ category_class: 'google-visualization-charteditor-mini-more',
6707
+ category_label: 'Chart position',
6708
+ category_type: 'chart_position',
6709
+ elements: [
6710
+ {
6711
+ element_type: 'input',
6712
+ value_name: 'margin_top',
6713
+ element_label: 'Marging top',
6714
+ default_value: 0,
6715
+ },
6716
+ {
6717
+ element_type: 'input',
6718
+ value_name: 'margin_right',
6719
+ element_label: 'Marging right',
6720
+ default_value: 0,
6721
+ },
6722
+ {
6723
+ element_type: 'input',
6724
+ value_name: 'margin_bottom',
6725
+ element_label: 'Marging bottom',
6726
+ default_value: 0,
6727
+ },
6728
+ {
6729
+ element_type: 'input',
6730
+ value_name: 'margin_left',
6731
+ element_label: 'Marging left',
6732
+ default_value: 0,
6733
+ },
6734
+ {
6735
+ element_type: 'input',
6736
+ value_name: 'spacing_top',
6737
+ element_label: 'Spacing top',
6738
+ default_value: 0,
6739
+ },
6740
+ {
6741
+ element_type: 'input',
6742
+ value_name: 'spacing_right',
6743
+ element_label: 'Spacing right',
6744
+ default_value: 0,
6745
+ },
6746
+ {
6747
+ element_type: 'input',
6748
+ value_name: 'spacing_bottom',
6749
+ element_label: 'Spacing bottom',
6750
+ default_value: 0,
6751
+ },
6752
+ {
6753
+ element_type: 'input',
6754
+ value_name: 'spacing_left',
6755
+ element_label: 'Spacing left',
6756
+ default_value: 0,
6757
+ },
6758
+ ]
6759
+ },
6753
6760
  'label': {
6754
6761
  category_class: 'google-visualization-charteditor-mini-more',
6755
6762
  category_label: 'Label',
@@ -7658,6 +7665,17 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
7658
7665
  axisTooltipTitle: 'Drag one or more fields here to create your x-axis.',
7659
7666
  legendTooltipTitle: 'Adding a field in this section will display lines for each item in that field.',
7660
7667
  },
7668
+ 'line-chart-forecast': {
7669
+ name: 'Combined Line',
7670
+ label: 'Combined Line',
7671
+ title: 'Show forecast over time.',
7672
+ description: 'For example, see how your Monthly Revenue evolves over a given period.',
7673
+ axisName: 'X - Axis',
7674
+ legendName: 'Data series',
7675
+ startedMessage: '“To get started, drag the Reporting Month field to the x-axis, include the Scenario Cycle field in the data series, and add one field to the value section.”',
7676
+ axisTooltipTitle: 'Drag one or more fields here to create your x-axis.',
7677
+ legendTooltipTitle: 'Adding a field in this section will display lines for each item in that field.',
7678
+ },
7661
7679
  'scatter-chart': {
7662
7680
  name: 'Scatter chart',
7663
7681
  label: 'Scatter Chart',
@@ -7762,7 +7780,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
7762
7780
  axisTooltipTitle: ' Best practice: we recommend no more than one segment.',
7763
7781
  legendTooltipTitle: 'To create a drill-down within this category, drag a field here.',
7764
7782
  },
7765
- 'gauge-solid-chart': {
7783
+ [highchartsRenderer.CHART_TYPES.GAUGE_CHART_ENHANCED]: {
7766
7784
  name: 'Gauge chart',
7767
7785
  label: 'Gauge',
7768
7786
  title: 'Measures progress toward a goal or a KPI.',
@@ -7770,20 +7788,13 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
7770
7788
  legendName: 'Data Series',
7771
7789
  startedMessage: 'To get started, drag one field to the value section. Best practice: Drag one field to the filter section, and filter as required.',
7772
7790
  },
7773
- 'gauge-chart': {
7774
- name: 'Gauge Speedometer',
7775
- label: 'Gauge Speedometer',
7776
- axisName: 'X-Axis',
7777
- legendName: 'Data Series',
7778
- startedMessage: 'To get started, drag one field to the value section. Best practice: Drag one field to the filter section, and filter as required.',
7779
- },
7780
- [highchartsRenderer.CHART_TYPES.GAUGE_CHART_ENHANCED]: {
7781
- name: 'Gauge chart',
7791
+ [highchartsRenderer.CHART_TYPES.GAUGE_CHART_CATEGORIES_SUMMARY]: {
7792
+ name: 'Gauge chart categories summary',
7782
7793
  label: 'Gauge',
7783
- title: 'Measures progress toward a goal or a KPI.',
7794
+ title: 'Gauge chart showing summary sections for different categories.',
7784
7795
  axisName: 'X-Axis',
7785
7796
  legendName: 'Data Series',
7786
- startedMessage: 'To get started, drag one field to the value section. Best practice: Drag one field to the filter section, and filter as required.',
7797
+ startedMessage: '',
7787
7798
  },
7788
7799
  'kpi-widget': {
7789
7800
  name: 'Kpi ',
@@ -7858,6 +7869,27 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
7858
7869
  highchartsRenderer.suboptions["legends"],
7859
7870
  ]
7860
7871
  },
7872
+ {
7873
+ type: 'line-chart-forecast',
7874
+ name: highchartsRenderer.chartsTypesInfo['line-chart-forecast'].name,
7875
+ class: 'google-visualization-charteditor-thumbs-linechart-forecast',
7876
+ render: highchartsRenderer.ptRenderSpLine,
7877
+ suboptions: [
7878
+ highchartsRenderer.suboptions["axisY"],
7879
+ highchartsRenderer.suboptions["axisX"],
7880
+ highchartsRenderer.suboptions["tooltips"],
7881
+ highchartsRenderer.suboptions["label"],
7882
+ highchartsRenderer.suboptions["subtitle"],
7883
+ highchartsRenderer.suboptions["widget_library"],
7884
+ highchartsRenderer.suboptions["table_options_transpose"],
7885
+ highchartsRenderer.suboptions["table_design_options"],
7886
+ highchartsRenderer.suboptions["chart_grid"],
7887
+ highchartsRenderer.suboptions["negative_number_format"],
7888
+ highchartsRenderer.suboptions["delta_column"],
7889
+ highchartsRenderer.suboptions["advanced"],
7890
+ highchartsRenderer.suboptions["legends"],
7891
+ ]
7892
+ },
7861
7893
  {
7862
7894
  type: 'scatter-chart',
7863
7895
  name: highchartsRenderer.chartsTypesInfo['scatter-chart'].name,
@@ -8094,25 +8126,26 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
8094
8126
  type: 'pie',
8095
8127
  name: 'Pie',
8096
8128
  class: 'google-visualization-charteditor-mini-pie',
8097
- subtypes: [{
8098
- type: 'pie-chart',
8099
- hidden: true,
8100
- name: highchartsRenderer.chartsTypesInfo['pie-chart'].name,
8101
- class: 'google-visualization-charteditor-thumbs-piechart',
8102
- render: highchartsRenderer.ptRenderBasicPie,
8103
- suboptions: [
8104
- highchartsRenderer.suboptions["tooltips_pie"],
8105
- highchartsRenderer.suboptions["label_pie"],
8106
- highchartsRenderer.suboptions["subtitle"],
8107
- highchartsRenderer.suboptions["widget_library"],
8108
- highchartsRenderer.suboptions["table_options_transpose"],
8109
- highchartsRenderer.suboptions["table_design_options"],
8110
- highchartsRenderer.suboptions["chart"],
8111
- highchartsRenderer.suboptions["negative_number_format"],
8112
- highchartsRenderer.suboptions["advanced"],
8113
- highchartsRenderer.suboptions["legends"],
8114
- ]
8115
- },
8129
+ subtypes: [
8130
+ {
8131
+ type: 'pie-chart',
8132
+ hidden: true,
8133
+ name: highchartsRenderer.chartsTypesInfo['pie-chart'].name,
8134
+ class: 'google-visualization-charteditor-thumbs-piechart',
8135
+ render: highchartsRenderer.ptRenderBasicPie,
8136
+ suboptions: [
8137
+ highchartsRenderer.suboptions["tooltips_pie"],
8138
+ highchartsRenderer.suboptions["label_pie"],
8139
+ highchartsRenderer.suboptions["subtitle"],
8140
+ highchartsRenderer.suboptions["widget_library"],
8141
+ highchartsRenderer.suboptions["table_options_transpose"],
8142
+ highchartsRenderer.suboptions["table_design_options"],
8143
+ highchartsRenderer.suboptions["chart"],
8144
+ highchartsRenderer.suboptions["negative_number_format"],
8145
+ highchartsRenderer.suboptions["advanced"],
8146
+ highchartsRenderer.suboptions["legends"],
8147
+ ]
8148
+ },
8116
8149
  {
8117
8150
  type: 'pie-chart-drilldown',
8118
8151
  name: highchartsRenderer.chartsTypesInfo['pie-chart-drilldown'].name,
@@ -8130,8 +8163,28 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
8130
8163
  highchartsRenderer.suboptions["advanced"],
8131
8164
  highchartsRenderer.suboptions["legends"],
8132
8165
  ]
8133
- }
8134
-
8166
+ },
8167
+ {
8168
+ type: highchartsRenderer.CHART_TYPES.DONUT_CHART,
8169
+ name: "Donut chart",
8170
+ class: "google-visualization-charteditor-thumbs-donutchart",
8171
+ render: highchartsRenderer.ptRenderDonut,
8172
+ suboptions: [
8173
+ highchartsRenderer.suboptions["tooltips_pie"],
8174
+ highchartsRenderer.suboptions["label_pie"],
8175
+ highchartsRenderer.suboptions["subtitle"],
8176
+ highchartsRenderer.suboptions["widget_library"],
8177
+ highchartsRenderer.suboptions["table_options_transpose"],
8178
+ highchartsRenderer.suboptions["table_design_options"],
8179
+ highchartsRenderer.suboptions["chart"],
8180
+ highchartsRenderer.suboptions["negative_number_format"],
8181
+ highchartsRenderer.suboptions["advanced"],
8182
+ highchartsRenderer.suboptions["legends"],
8183
+ highchartsRenderer.suboptions["chart_position"],
8184
+ highchartsRenderer.suboptions["total_value_label_donut"],
8185
+ ],
8186
+ hidden: true,
8187
+ },
8135
8188
  /*,
8136
8189
  {type:'pie-chart-3d', name:'3d pie chart', class:'google-visualization-charteditor-thumbs-piechart-3d', render:highchartsRenderer.ptRenderStackedBar},
8137
8190
  {type:'donut-chart', name:'Donut chart', class:'google-visualization-charteditor-thumbs-donutchart', render:highchartsRenderer.ptRenderStackedBar}*/
@@ -8142,47 +8195,10 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
8142
8195
  name: 'Gauge',
8143
8196
  class: 'google-visualization-charteditor-mini-gauge',
8144
8197
  subtypes: [
8145
- {
8146
- type: 'gauge-solid-chart',
8147
- name: highchartsRenderer.chartsTypesInfo['gauge-solid-chart'].name,
8148
- class: 'google-visualization-charteditor-thumbs-gauge-solid',
8149
- render: highchartsRenderer.ptRenderSolidGauge,
8150
- suboptions: [
8151
- highchartsRenderer.suboptions["value"],
8152
- highchartsRenderer.suboptions["range"],
8153
- highchartsRenderer.suboptions["tooltips"],
8154
- highchartsRenderer.suboptions["subtitle"],
8155
- highchartsRenderer.suboptions["widget_library"],
8156
- highchartsRenderer.suboptions["table_options_transpose"],
8157
- highchartsRenderer.suboptions["table_design_options"],
8158
- highchartsRenderer.suboptions["chart_grid"],
8159
- highchartsRenderer.suboptions["negative_number_format"],
8160
- highchartsRenderer.suboptions["legends"],
8161
- ]
8162
- },
8163
- {
8164
- type: 'gauge-chart',
8165
- name: highchartsRenderer.chartsTypesInfo['gauge-chart'].name,
8166
- class: 'google-visualization-charteditor-thumbs-gauge',
8167
- render: highchartsRenderer.ptRenderGauge,
8168
- suboptions: [
8169
- highchartsRenderer.suboptions["value"],
8170
- highchartsRenderer.suboptions["range"],
8171
- highchartsRenderer.suboptions["tooltips"],
8172
- highchartsRenderer.suboptions["subtitle"],
8173
- highchartsRenderer.suboptions["widget_library"],
8174
- highchartsRenderer.suboptions["table_options_transpose"],
8175
- highchartsRenderer.suboptions["table_design_options"],
8176
- highchartsRenderer.suboptions["chart_grid"],
8177
- highchartsRenderer.suboptions["negative_number_format"],
8178
- highchartsRenderer.suboptions["legends"],
8179
- ]
8180
- },
8181
8198
  {
8182
8199
  type: highchartsRenderer.CHART_TYPES.GAUGE_CHART_ENHANCED,
8183
8200
  name: highchartsRenderer.chartsTypesInfo[highchartsRenderer.CHART_TYPES.GAUGE_CHART_ENHANCED].name,
8184
8201
  class: 'google-visualization-charteditor-thumbs-gauge-solid',
8185
- hidden: true,
8186
8202
  render: highchartsRenderer.ptRenderGaugeEnhanced,
8187
8203
  suboptions: [
8188
8204
  highchartsRenderer.suboptions["label_gauge"],
@@ -8194,6 +8210,25 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
8194
8210
  },
8195
8211
  ]
8196
8212
  },
8213
+ {
8214
+ type: 'gauge-categories-summary',
8215
+ name: 'Gauge Categories Summary',
8216
+ class: 'google-visualization-charteditor-mini-gauge',
8217
+ hidden: true,
8218
+ subtypes: [
8219
+ {
8220
+ type: highchartsRenderer.CHART_TYPES.GAUGE_CHART_CATEGORIES_SUMMARY,
8221
+ name: highchartsRenderer.chartsTypesInfo[highchartsRenderer.CHART_TYPES.GAUGE_CHART_CATEGORIES_SUMMARY].name,
8222
+ class: 'google-visualization-charteditor-thumbs-gauge-solid',
8223
+ render: highchartsRenderer.ptRenderGaugeCategoriesSummary,
8224
+ suboptions: [
8225
+ highchartsRenderer.suboptions["label_gauge"],
8226
+ highchartsRenderer.suboptions["tooltips_gauge"],
8227
+ highchartsRenderer.suboptions["subtitle"]
8228
+ ]
8229
+ },
8230
+ ]
8231
+ },
8197
8232
  {
8198
8233
  type: 'kpi',
8199
8234
  name: 'KPI',
@@ -8286,6 +8321,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
8286
8321
  class: 'google-visualization-charteditor-thumbs-walkthrough',
8287
8322
  render: highchartsRenderer.ptRenderWaterfallWalkthrough,
8288
8323
  suboptions: [
8324
+ highchartsRenderer.suboptions["axisY"],
8289
8325
  highchartsRenderer.suboptions["axisX"],
8290
8326
  highchartsRenderer.suboptions["tooltips"],
8291
8327
  highchartsRenderer.suboptions["label"],
@@ -9877,6 +9913,13 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
9877
9913
  e.point = lodash.cloneDeep(e.point);
9878
9914
  e.point.name = e.point.initialName;
9879
9915
  e.point.series.name = lodash.get(e.point.series, 'userOptions.initialName', e.point.series.name);
9916
+ const seriesData = lodash.get(e.point.series, 'userOptions.data');
9917
+ const initialNameForSmartQueries = seriesData
9918
+ ? lodash.find(seriesData, obj => obj.name === e.point.name)
9919
+ : null;
9920
+ if (initialNameForSmartQueries && initialNameForSmartQueries.type) {
9921
+ e.point.series.name = initialNameForSmartQueries.type === "SQ_Actuals" ? 'Actuals' : 'Forecast';
9922
+ }
9880
9923
  lodash.set(e, 'point.category.userOptions', e.point.initialName.toString().split(highchartsRenderer.delimer));
9881
9924
  }
9882
9925
 
@@ -10008,6 +10051,10 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
10008
10051
  disableAnimation = disabled;
10009
10052
  };
10010
10053
 
10054
+ highchartsRenderer.chartAnimationsDisabled = function () {
10055
+ return disableAnimation;
10056
+ };
10057
+
10011
10058
  highchartsRenderer.adjustFormatToSupportedByMoment = function(format) {
10012
10059
  return typeof format === 'string'
10013
10060
  ? format.replace(/y/g, 'Y').replace(/d/g, 'D').replace(/h/g, 'H')