@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.
- package/CHANGELOG.md +8 -0
- package/dist/ej2-pivotview.umd.min.js +2 -2
- package/dist/ej2-pivotview.umd.min.js.map +1 -1
- package/dist/es6/ej2-pivotview.es2015.js +18 -4
- package/dist/es6/ej2-pivotview.es2015.js.map +1 -1
- package/dist/es6/ej2-pivotview.es5.js +18 -4
- package/dist/es6/ej2-pivotview.es5.js.map +1 -1
- package/dist/global/ej2-pivotview.min.js +2 -2
- package/dist/global/ej2-pivotview.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +12 -12
- package/src/base/engine.js +1 -0
- package/src/pivotview/actions/excel-export.js +2 -1
- package/src/pivotview/renderer/render.js +15 -3
|
@@ -5236,6 +5236,7 @@ var PivotEngine = /** @__PURE__ @class */ (function () {
|
|
|
5236
5236
|
isNaN(value) && !isNullOrUndefined(value) &&
|
|
5237
5237
|
(['PopulationStDev', 'SampleStDev', 'PopulationVar', 'SampleVar']).indexOf(aggregate) !== -1) {
|
|
5238
5238
|
formattedText = '#DIV/0!';
|
|
5239
|
+
value = 0;
|
|
5239
5240
|
}
|
|
5240
5241
|
//dln = data[tnum].length;
|
|
5241
5242
|
formattedText = (cellDetails.skipFormatting ? isNullOrUndefined(value) ?
|
|
@@ -9196,6 +9197,12 @@ var Render = /** @__PURE__ @class */ (function () {
|
|
|
9196
9197
|
}
|
|
9197
9198
|
}
|
|
9198
9199
|
else {
|
|
9200
|
+
if ((['PercentageOfDifferenceFrom', 'PercentageOfRowTotal', 'PercentageOfColumnTotal', 'PercentageOfGrandTotal', 'PercentageOfParentRowTotal', 'PercentageOfParentColumnTotal', 'PercentageOfParentTotal']).indexOf(field.type) > -1) {
|
|
9201
|
+
format = 'P2';
|
|
9202
|
+
}
|
|
9203
|
+
else if (['PopulationStDev', 'SampleStDev', 'PopulationVar', 'SampleVar', 'Index'].indexOf(field.type) > -1) {
|
|
9204
|
+
format = undefined;
|
|
9205
|
+
}
|
|
9199
9206
|
if (this.parent.dataSourceSettings.formatSettings.length > 0) {
|
|
9200
9207
|
for (var fCnt = 0; fCnt < this.parent.dataSourceSettings.formatSettings.length; fCnt++) {
|
|
9201
9208
|
var formatSettings = this.parent.dataSourceSettings.formatSettings[fCnt];
|
|
@@ -9290,12 +9297,18 @@ var Render = /** @__PURE__ @class */ (function () {
|
|
|
9290
9297
|
else {
|
|
9291
9298
|
this.colPos++;
|
|
9292
9299
|
/* eslint-disable-next-line */
|
|
9293
|
-
|
|
9300
|
+
var pivotValue = args.data[this.colPos];
|
|
9301
|
+
if (isNullOrUndefined(pivotValue.value) || isNullOrUndefined(pivotValue.formattedText) || pivotValue.formattedText === "") {
|
|
9294
9302
|
args.value = this.parent.exportType === 'Excel' ? null : '';
|
|
9295
9303
|
}
|
|
9296
9304
|
else {
|
|
9297
|
-
|
|
9298
|
-
|
|
9305
|
+
var aggMatrix = this.parent.engineModule.aggregatedValueMatrix;
|
|
9306
|
+
if (aggMatrix[pivotValue.rowIndex] && aggMatrix[pivotValue.rowIndex][pivotValue.colIndex]) {
|
|
9307
|
+
args.value = aggMatrix[pivotValue.rowIndex][pivotValue.colIndex];
|
|
9308
|
+
}
|
|
9309
|
+
else {
|
|
9310
|
+
args.value = !isNullOrUndefined(pivotValue.value) ? (pivotValue.formattedText === '#DIV/0!' ? pivotValue.formattedText : pivotValue.value) : pivotValue.formattedText;
|
|
9311
|
+
}
|
|
9299
9312
|
}
|
|
9300
9313
|
}
|
|
9301
9314
|
args = this.exportContentEvent(args);
|
|
@@ -27614,7 +27627,8 @@ var ExcelExport$1 = /** @__PURE__ @class */ (function () {
|
|
|
27614
27627
|
var styles = (pivotCell.axis == 'row') ? { hAlign: 'Left', bold: true, wrapText: true } : { numberFormat: formatList[field], bold: false, wrapText: true };
|
|
27615
27628
|
var headerStyle = { bold: true, vAlign: 'Center', wrapText: true, indent: cCnt === 0 ? pivotCell.level * 10 : 0 };
|
|
27616
27629
|
if (!(pivotCell.level === -1 && !pivotCell.rowSpan)) {
|
|
27617
|
-
var
|
|
27630
|
+
var aggMatrix = this.parent.engineModule.aggregatedValueMatrix;
|
|
27631
|
+
var cellValue = pivotCell.axis === 'value' ? ((aggMatrix[rCnt] && aggMatrix[rCnt][cCnt]) ? aggMatrix[rCnt][cCnt] : (pivotCell.formattedText === '#DIV/0!' ? pivotCell.formattedText : pivotCell.value)) : pivotCell.formattedText;
|
|
27618
27632
|
var isgetValuesHeader = ((this.parent.dataSourceSettings.rows.length === 0 && this.parent.dataSourceSettings.valueAxis === 'row')
|
|
27619
27633
|
|| (this.parent.dataSourceSettings.columns.length === 0 && this.parent.dataSourceSettings.valueAxis === 'column'));
|
|
27620
27634
|
if (pivotCell.type === 'grand sum' && !(this.parent.dataSourceSettings.values.length === 1 && this.parent.dataSourceSettings.valueAxis === 'row' && pivotCell.axis === 'column')) {
|