@datarailsshared/dr_renderer 1.2.202-dragons → 1.2.204-dragons

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datarailsshared/dr_renderer",
3
- "version": "1.2.202-dragons",
3
+ "version": "1.2.204-dragons",
4
4
  "description": "DataRails charts and tables renderer",
5
5
  "keywords": [
6
6
  "datarails",
@@ -1348,7 +1348,6 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1348
1348
  const chart_series = [];
1349
1349
  const row_n_keys = pivotData.getRowKeys();
1350
1350
  const col_n_keys = pivotData.getColKeys();
1351
- const hasBreakdownValues = lodash.get(opts, 'breakdown_options.values.breakdown.length');
1352
1351
 
1353
1352
  let resultObject = {
1354
1353
  data: [],
@@ -1366,11 +1365,8 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1366
1365
 
1367
1366
  lodash.forEach(col_n_keys, function(col_n_value, col_index) {
1368
1367
 
1369
- const totalColumnValue = pivotData.colTotals[col_n_value].sum;
1370
- const nextTotalColumnKey = col_n_keys[col_index + 1];
1371
- const nextTotalColumnValue = nextTotalColumnKey ? pivotData.colTotals[nextTotalColumnKey].sum : null;
1372
1368
  resultObject.data.push({
1373
- y: totalColumnValue,
1369
+ y: pivotData.colTotals[col_n_value].sum,
1374
1370
  name: lodash.unescape(col_n_value).replace('DR_Others', highchartsRenderer.getOthersName(opts)),
1375
1371
  isSum: !!col_index,
1376
1372
  isTotal: true,
@@ -1380,9 +1376,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1380
1376
  if (col_index !== col_n_keys.length - 1) {
1381
1377
  lodash.forEach(row_n_keys, function (row_n_value) {
1382
1378
  const agg = pivotData.getAggregator(row_n_value, col_n_value);
1383
- let val = hasBreakdownValues
1384
- ? agg.value()
1385
- : nextTotalColumnValue - totalColumnValue;
1379
+ let val = agg.value();
1386
1380
 
1387
1381
  val = $.isNumeric(val) ? parseFloat(val) : 0;
1388
1382
  if (val) {
@@ -1407,7 +1401,6 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
1407
1401
  });
1408
1402
 
1409
1403
  chart_series.push(resultObject);
1410
-
1411
1404
  opts.chart_series = [];
1412
1405
  if (!lodash.isEqual(row_n_keys, EMPTY_ROW_N_KEYS)) {
1413
1406
  chart_series.forEach(series => {