@syncfusion/ej2-pivotview 20.1.57 → 20.1.58

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,6 @@
1
1
  /*!
2
2
  * filename: index.d.ts
3
- * version : 20.1.57
3
+ * version : 20.1.58
4
4
  * Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
5
5
  * Use of this code is subject to the terms of our license.
6
6
  * A copy of the current license can be obtained at any time by e-mailing
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "_from": "@syncfusion/ej2-pivotview@*",
3
- "_id": "@syncfusion/ej2-pivotview@20.1.56",
3
+ "_id": "@syncfusion/ej2-pivotview@20.1.57",
4
4
  "_inBundle": false,
5
- "_integrity": "sha512-AsjhIqLyM06wqRDY9pgyfqJuKE6EAzts9GOXrgDko+5joxKkBFwURw35lbZrqn3eTFkhBPxAt358DUsU3v42Rw==",
5
+ "_integrity": "sha512-PY/G2CSBc4ZFKlOQj+AGcnaoiRU5+GaYjusvYrtPj9U5L6u3cM0rxFAQbYZK5bfCrraCpnWQVEmn75WFOo4vdw==",
6
6
  "_location": "/@syncfusion/ej2-pivotview",
7
7
  "_phantomChildren": {},
8
8
  "_requested": {
@@ -23,8 +23,8 @@
23
23
  "/@syncfusion/ej2-react-pivotview",
24
24
  "/@syncfusion/ej2-vue-pivotview"
25
25
  ],
26
- "_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-pivotview/-/ej2-pivotview-20.1.56.tgz",
27
- "_shasum": "ba38c5a5526c0ab562e38a1618ecea1ecfe9e8af",
26
+ "_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-pivotview/-/ej2-pivotview-20.1.57.tgz",
27
+ "_shasum": "6d6b8d7f33c1d0ac7e440b33cf4e90d825c3d218",
28
28
  "_spec": "@syncfusion/ej2-pivotview@*",
29
29
  "_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
30
30
  "author": {
@@ -35,21 +35,21 @@
35
35
  },
36
36
  "bundleDependencies": false,
37
37
  "dependencies": {
38
- "@syncfusion/ej2-base": "~20.1.56",
38
+ "@syncfusion/ej2-base": "~20.1.57",
39
39
  "@syncfusion/ej2-buttons": "~20.1.55",
40
- "@syncfusion/ej2-calendars": "~20.1.57",
40
+ "@syncfusion/ej2-calendars": "~20.1.58",
41
41
  "@syncfusion/ej2-charts": "~20.1.57",
42
42
  "@syncfusion/ej2-compression": "~20.1.55",
43
43
  "@syncfusion/ej2-data": "~20.1.55",
44
- "@syncfusion/ej2-dropdowns": "~20.1.57",
44
+ "@syncfusion/ej2-dropdowns": "~20.1.58",
45
45
  "@syncfusion/ej2-excel-export": "~20.1.55",
46
46
  "@syncfusion/ej2-file-utils": "~20.1.55",
47
- "@syncfusion/ej2-grids": "~20.1.57",
48
- "@syncfusion/ej2-inputs": "~20.1.55",
47
+ "@syncfusion/ej2-grids": "~20.1.58",
48
+ "@syncfusion/ej2-inputs": "~20.1.58",
49
49
  "@syncfusion/ej2-lists": "~20.1.55",
50
- "@syncfusion/ej2-navigations": "~20.1.57",
50
+ "@syncfusion/ej2-navigations": "~20.1.58",
51
51
  "@syncfusion/ej2-pdf-export": "~20.1.55",
52
- "@syncfusion/ej2-popups": "~20.1.57",
52
+ "@syncfusion/ej2-popups": "~20.1.58",
53
53
  "@syncfusion/ej2-splitbuttons": "~20.1.57",
54
54
  "@syncfusion/ej2-svg-base": "~20.1.55"
55
55
  },
@@ -78,6 +78,6 @@
78
78
  "url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
79
79
  },
80
80
  "typings": "index.d.ts",
81
- "version": "20.1.57",
81
+ "version": "20.1.58",
82
82
  "sideEffects": false
83
83
  }
@@ -4350,6 +4350,7 @@ var PivotEngine = /** @class */ (function () {
4350
4350
  isNaN(value) && !isNullOrUndefined(value) &&
4351
4351
  (['PopulationStDev', 'SampleStDev', 'PopulationVar', 'SampleVar']).indexOf(aggregate) !== -1) {
4352
4352
  formattedText = '#DIV/0!';
4353
+ value = 0;
4353
4354
  }
4354
4355
  //dln = data[tnum].length;
4355
4356
  formattedText = (cellDetails.skipFormatting ? isNullOrUndefined(value) ?
@@ -129,7 +129,8 @@ var ExcelExport = /** @class */ (function () {
129
129
  var styles = (pivotCell.axis == 'row') ? { hAlign: 'Left', bold: true, wrapText: true } : { numberFormat: formatList[field], bold: false, wrapText: true };
130
130
  var headerStyle = { bold: true, vAlign: 'Center', wrapText: true, indent: cCnt === 0 ? pivotCell.level * 10 : 0 };
131
131
  if (!(pivotCell.level === -1 && !pivotCell.rowSpan)) {
132
- var cellValue = pivotCell.axis === 'value' ? pivotCell.value : pivotCell.formattedText;
132
+ var aggMatrix = this.parent.engineModule.aggregatedValueMatrix;
133
+ var cellValue = pivotCell.axis === 'value' ? ((aggMatrix[rCnt] && aggMatrix[rCnt][cCnt]) ? aggMatrix[rCnt][cCnt] : (pivotCell.formattedText === '#DIV/0!' ? pivotCell.formattedText : pivotCell.value)) : pivotCell.formattedText;
133
134
  var isgetValuesHeader = ((this.parent.dataSourceSettings.rows.length === 0 && this.parent.dataSourceSettings.valueAxis === 'row')
134
135
  || (this.parent.dataSourceSettings.columns.length === 0 && this.parent.dataSourceSettings.valueAxis === 'column'));
135
136
  if (pivotCell.type === 'grand sum' && !(this.parent.dataSourceSettings.values.length === 1 && this.parent.dataSourceSettings.valueAxis === 'row' && pivotCell.axis === 'column')) {
@@ -1820,6 +1820,12 @@ var Render = /** @class */ (function () {
1820
1820
  }
1821
1821
  }
1822
1822
  else {
1823
+ if ((['PercentageOfDifferenceFrom', 'PercentageOfRowTotal', 'PercentageOfColumnTotal', 'PercentageOfGrandTotal', 'PercentageOfParentRowTotal', 'PercentageOfParentColumnTotal', 'PercentageOfParentTotal']).indexOf(field.type) > -1) {
1824
+ format = 'P2';
1825
+ }
1826
+ else if (['PopulationStDev', 'SampleStDev', 'PopulationVar', 'SampleVar', 'Index'].indexOf(field.type) > -1) {
1827
+ format = undefined;
1828
+ }
1823
1829
  if (this.parent.dataSourceSettings.formatSettings.length > 0) {
1824
1830
  for (var fCnt = 0; fCnt < this.parent.dataSourceSettings.formatSettings.length; fCnt++) {
1825
1831
  var formatSettings = this.parent.dataSourceSettings.formatSettings[fCnt];
@@ -1914,12 +1920,18 @@ var Render = /** @class */ (function () {
1914
1920
  else {
1915
1921
  this.colPos++;
1916
1922
  /* eslint-disable-next-line */
1917
- if (isNullOrUndefined(args.data[this.colPos].value) || isNullOrUndefined(args.data[this.colPos].formattedText) || args.data[this.colPos].formattedText === "") {
1923
+ var pivotValue = args.data[this.colPos];
1924
+ if (isNullOrUndefined(pivotValue.value) || isNullOrUndefined(pivotValue.formattedText) || pivotValue.formattedText === "") {
1918
1925
  args.value = this.parent.exportType === 'Excel' ? null : '';
1919
1926
  }
1920
1927
  else {
1921
- /* eslint-disable-next-line */
1922
- args.value = !isNullOrUndefined(args.data[this.colPos].value) ? args.data[this.colPos].value : args.data[this.colPos].formattedText;
1928
+ var aggMatrix = this.parent.engineModule.aggregatedValueMatrix;
1929
+ if (aggMatrix[pivotValue.rowIndex] && aggMatrix[pivotValue.rowIndex][pivotValue.colIndex]) {
1930
+ args.value = aggMatrix[pivotValue.rowIndex][pivotValue.colIndex];
1931
+ }
1932
+ else {
1933
+ args.value = !isNullOrUndefined(pivotValue.value) ? (pivotValue.formattedText === '#DIV/0!' ? pivotValue.formattedText : pivotValue.value) : pivotValue.formattedText;
1934
+ }
1923
1935
  }
1924
1936
  }
1925
1937
  args = this.exportContentEvent(args);