@datarailsshared/dr_renderer 1.2.265 → 1.2.268
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/.circleci/config.yml +9 -5
- package/package.json +1 -1
- package/src/highcharts_renderer.js +15 -2
package/.circleci/config.yml
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
version: 2
|
|
1
|
+
version: 2.1
|
|
2
|
+
|
|
3
|
+
orbs:
|
|
4
|
+
datarails-cicd-orb: datarails/datarails-cicd-orb@dev:primary
|
|
6
5
|
|
|
7
6
|
defaults: &defaults
|
|
8
7
|
working_directory: ~/repo
|
|
@@ -40,6 +39,11 @@ jobs:
|
|
|
40
39
|
- run:
|
|
41
40
|
name: Publish package
|
|
42
41
|
command: npm publish . --access=public
|
|
42
|
+
- datarails-cicd-orb/add-ssh-id:
|
|
43
|
+
private_key_env_var: bitbucket_deploy_private_encoded
|
|
44
|
+
public_key_env_var: bitbucket_deploy_pub_encoded
|
|
45
|
+
is_public_key_encoded: true
|
|
46
|
+
is_private_key_encoded: true
|
|
43
47
|
- run:
|
|
44
48
|
name: prepare git tag
|
|
45
49
|
command: |
|
package/package.json
CHANGED
|
@@ -493,6 +493,7 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
|
|
|
493
493
|
if (!cols && is_drill_down_pie) {
|
|
494
494
|
cols = this.point.name;
|
|
495
495
|
}
|
|
496
|
+
const row_n_keys = pivotData.getRowKeys();
|
|
496
497
|
|
|
497
498
|
if (!lodash.isArray(cols)) {
|
|
498
499
|
cols = [cols];
|
|
@@ -522,8 +523,20 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
|
|
|
522
523
|
}
|
|
523
524
|
|
|
524
525
|
if (labelOptions.show_out_of_data_series) {
|
|
525
|
-
|
|
526
|
-
|
|
526
|
+
let dataSeriesTotal;
|
|
527
|
+
let outOfDataSeriesPercentages;
|
|
528
|
+
|
|
529
|
+
if (this.series.options.className === SERIES_CLASSNAMES.WATERFALL_BREAKDOWN) {
|
|
530
|
+
dataSeriesTotal = row_n_keys.reduce((a, d) => {
|
|
531
|
+
return a + pivotData.getAggregator(d, []).value();
|
|
532
|
+
}, 0);
|
|
533
|
+
const axisTotal = pivotData.getAggregator([], cols).value();
|
|
534
|
+
outOfDataSeriesPercentages = !axisTotal ? Math.round(value / dataSeriesTotal * 100) + '%' : '';
|
|
535
|
+
} else {
|
|
536
|
+
dataSeriesTotal = pivotData.getAggregator(rows, []).value();
|
|
537
|
+
outOfDataSeriesPercentages = dataSeriesTotal ? Math.round(value / dataSeriesTotal * 100) + '%' : '';
|
|
538
|
+
}
|
|
539
|
+
|
|
527
540
|
outOfDataSeriesPercentages && percentageArray.push(outOfDataSeriesPercentages);
|
|
528
541
|
}
|
|
529
542
|
|