@syncfusion/ej2-pivotview 19.4.41 → 19.4.48

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.
Files changed (53) hide show
  1. package/CHANGELOG.md +31 -0
  2. package/dist/ej2-pivotview.umd.min.js +2 -2
  3. package/dist/ej2-pivotview.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-pivotview.es2015.js +162 -70
  5. package/dist/es6/ej2-pivotview.es2015.js.map +1 -1
  6. package/dist/es6/ej2-pivotview.es5.js +162 -70
  7. package/dist/es6/ej2-pivotview.es5.js.map +1 -1
  8. package/dist/global/ej2-pivotview.min.js +2 -2
  9. package/dist/global/ej2-pivotview.min.js.map +1 -1
  10. package/dist/global/index.d.ts +1 -1
  11. package/package.json +22 -22
  12. package/src/common/actions/dataSource-update.d.ts +1 -1
  13. package/src/common/actions/dataSource-update.js +5 -0
  14. package/src/common/actions/node-state-modified.js +1 -1
  15. package/src/common/grouping-bar/grouping-bar.js +1 -1
  16. package/src/common/popups/toolbar.js +12 -12
  17. package/src/pivotchart/base/pivotchart.js +1 -1
  18. package/src/pivotfieldlist/base/field-list.d.ts +2 -0
  19. package/src/pivotfieldlist/base/field-list.js +4 -2
  20. package/src/pivotfieldlist/renderer/axis-table-renderer.js +1 -1
  21. package/src/pivotfieldlist/renderer/tree-renderer.js +16 -11
  22. package/src/pivotview/actions/excel-export.js +54 -25
  23. package/src/pivotview/actions/pdf-export.js +45 -9
  24. package/src/pivotview/actions/virtualscroll.js +1 -1
  25. package/src/pivotview/base/pivotview.d.ts +2 -0
  26. package/src/pivotview/base/pivotview.js +21 -6
  27. package/styles/bootstrap-dark.css +30 -14
  28. package/styles/bootstrap.css +30 -14
  29. package/styles/bootstrap4.css +30 -14
  30. package/styles/bootstrap5-dark.css +30 -14
  31. package/styles/bootstrap5.css +30 -14
  32. package/styles/fabric-dark.css +30 -14
  33. package/styles/fabric.css +30 -14
  34. package/styles/highcontrast-light.css +30 -14
  35. package/styles/highcontrast.css +30 -14
  36. package/styles/material-dark.css +30 -14
  37. package/styles/material.css +30 -14
  38. package/styles/pivotfieldlist/_theme.scss +28 -12
  39. package/styles/pivotfieldlist/bootstrap-dark.css +30 -14
  40. package/styles/pivotfieldlist/bootstrap.css +30 -14
  41. package/styles/pivotfieldlist/bootstrap4.css +30 -14
  42. package/styles/pivotfieldlist/bootstrap5-dark.css +30 -14
  43. package/styles/pivotfieldlist/bootstrap5.css +30 -14
  44. package/styles/pivotfieldlist/fabric-dark.css +30 -14
  45. package/styles/pivotfieldlist/fabric.css +30 -14
  46. package/styles/pivotfieldlist/highcontrast-light.css +30 -14
  47. package/styles/pivotfieldlist/highcontrast.css +30 -14
  48. package/styles/pivotfieldlist/material-dark.css +30 -14
  49. package/styles/pivotfieldlist/material.css +30 -14
  50. package/styles/pivotfieldlist/tailwind-dark.css +30 -14
  51. package/styles/pivotfieldlist/tailwind.css +30 -14
  52. package/styles/tailwind-dark.css +30 -14
  53. package/styles/tailwind.css +30 -14
@@ -9939,7 +9939,7 @@ class NodeStateModified {
9939
9939
  this.parent.engineModule.updateFieldlistData(fieldName);
9940
9940
  }
9941
9941
  }
9942
- this.parent.dataSourceUpdate.updateDataSource(fieldName, droppedClass, droppedPosition);
9942
+ nodeDropped = this.parent.dataSourceUpdate.updateDataSource(fieldName, droppedClass, droppedPosition);
9943
9943
  return nodeDropped;
9944
9944
  }
9945
9945
  getButtonPosition(target, droppedClass) {
@@ -9986,6 +9986,7 @@ class DataSourceUpdate {
9986
9986
  let dataSourceItem;
9987
9987
  let draggedClass;
9988
9988
  let draggedPosition = -1;
9989
+ let nodeDropped = true;
9989
9990
  let row = this.parent.dataSourceSettings.rows;
9990
9991
  let column = this.parent.dataSourceSettings.columns;
9991
9992
  let value = this.parent.dataSourceSettings.values;
@@ -10112,7 +10113,11 @@ class DataSourceUpdate {
10112
10113
  });
10113
10114
  }
10114
10115
  }
10116
+ else {
10117
+ nodeDropped = false;
10118
+ }
10115
10119
  });
10120
+ return nodeDropped;
10116
10121
  }
10117
10122
  /**
10118
10123
  * Updates the dataSource by removing the given field from the dataSource.
@@ -12863,7 +12868,7 @@ class VirtualScroll$1 {
12863
12868
  let ele = this.parent.isAdaptive ? mCont : mCont.parentElement.parentElement.querySelector('.' + MOVABLESCROLL_DIV);
12864
12869
  EventHandler.add(ele, 'scroll touchmove pointermove', this.onHorizondalScroll(mHdr, mCont, fCont), this);
12865
12870
  EventHandler.add(mCont.parentElement, 'scroll wheel touchmove pointermove keyup keydown', this.onVerticalScroll(fCont, mCont), this);
12866
- EventHandler.add(mCont.parentElement.parentElement, 'mouseup touchend', this.common(mHdr, mCont, fCont), this);
12871
+ EventHandler.add(mCont, 'mouseup touchend scroll', this.common(mHdr, mCont, fCont), this);
12867
12872
  EventHandler.add(mScrollBar, 'scroll', this.onCustomScrollbarScroll(mCont, mHdr), this);
12868
12873
  EventHandler.add(mCont, 'scroll', this.onCustomScrollbarScroll(mScrollBar, mHdr), this);
12869
12874
  EventHandler.add(mHdr, 'scroll', this.onCustomScrollbarScroll(mScrollBar, mCont), this);
@@ -15609,7 +15614,7 @@ class PivotChart {
15609
15614
  if (this.parent && this.parent.isDestroyed) {
15610
15615
  return;
15611
15616
  }
15612
- if (this.engineModule) {
15617
+ if (this.engineModule && !this.parent.destroyEngine) {
15613
15618
  this.engineModule.fieldList = {};
15614
15619
  this.engineModule = {};
15615
15620
  }
@@ -21853,6 +21858,8 @@ let PivotView = class PivotView extends Component {
21853
21858
  this.isServerWaitingPopup = false;
21854
21859
  /** @hidden */
21855
21860
  this.actionObj = {};
21861
+ /** @hidden */
21862
+ this.destroyEngine = false;
21856
21863
  this.pivotView = this;
21857
21864
  setValue('mergePersistData', this.mergePersistPivotData, this);
21858
21865
  }
@@ -22999,24 +23006,37 @@ let PivotView = class PivotView extends Component {
22999
23006
  this.displayOption.primary : newProp.displayOption.view);
23000
23007
  if (this.showGroupingBar || this.showFieldList) {
23001
23008
  if (this.showFieldList && this.pivotFieldListModule) {
23009
+ this.pivotFieldListModule.destroyEngine = true;
23002
23010
  this.pivotFieldListModule.destroy();
23011
+ this.pivotFieldListModule.destroyEngine = false;
23003
23012
  }
23004
- if (this.showGroupingBar && this.groupingBarModule) {
23005
- this.groupingBarModule.destroy();
23006
- }
23013
+ /**
23014
+ * Below lines are affected the grouping bar render between table and chart.
23015
+ * In "Init subcomponent" function, grouping bar rendered properly for table and chart view.
23016
+ * So, The below lines are commanded out.
23017
+ */
23018
+ // if (this.showGroupingBar && this.groupingBarModule) {
23019
+ // this.groupingBarModule.destroy();
23020
+ // }
23007
23021
  this.notify(initSubComponent, this);
23008
23022
  }
23009
23023
  if (!this.grid && newProp.displayOption.view !== 'Chart') {
23010
23024
  this.renderEmptyGrid();
23011
23025
  if (newProp.displayOption.view === 'Table') {
23012
23026
  if (this.pivotChartModule) {
23027
+ this.destroyEngine = true;
23013
23028
  this.pivotChartModule.destroy();
23029
+ this.destroyEngine = false;
23014
23030
  this.chart = undefined;
23015
23031
  this.pivotChartModule = undefined;
23016
23032
  }
23017
23033
  }
23018
23034
  }
23019
23035
  else if (!this.pivotChartModule && this.displayOption.view !== 'Table') {
23036
+ if (this.grid) {
23037
+ this.grid.destroy();
23038
+ this.grid = undefined;
23039
+ }
23020
23040
  this.pivotChartModule = new PivotChart();
23021
23041
  }
23022
23042
  }
@@ -24014,12 +24034,12 @@ let PivotView = class PivotView extends Component {
24014
24034
  let hasField = false;
24015
24035
  if (cell && this.dataType === 'olap') {
24016
24036
  let measureName = cell.actualText;
24017
- if (!isNullOrUndefined(measureName) && !this.olapEngineModule.fieldList[measureName]) {
24037
+ if (!isNullOrUndefined(measureName) && this.olapEngineModule.fieldList && !this.olapEngineModule.fieldList[measureName]) {
24018
24038
  let tupleInfo = this.olapEngineModule.tupRowInfo;
24019
24039
  measureName = cell.rowOrdinal > -1 && tupleInfo.length > 0 && tupleInfo[cell.rowOrdinal] &&
24020
24040
  !isNullOrUndefined(tupleInfo[cell.rowOrdinal].measureName) ? tupleInfo[cell.rowOrdinal].measureName : measureName;
24021
24041
  }
24022
- if (this.olapEngineModule.fieldList[measureName]) {
24042
+ if (this.olapEngineModule.fieldList && this.olapEngineModule.fieldList[measureName]) {
24023
24043
  let field = this.olapEngineModule.fieldList[measureName];
24024
24044
  aggregateType = field.isCalculatedField ? field.type : field.aggregateType;
24025
24045
  caption = (this.olapEngineModule.dataFields[measureName] &&
@@ -24029,7 +24049,7 @@ let PivotView = class PivotView extends Component {
24029
24049
  }
24030
24050
  }
24031
24051
  else {
24032
- if (cell && this.engineModule.fieldList[cell.actualText]) {
24052
+ if (cell && this.engineModule.fieldList && this.engineModule.fieldList[cell.actualText]) {
24033
24053
  let field = this.engineModule.fieldList[cell.actualText];
24034
24054
  aggregateType = field.aggregateType;
24035
24055
  if ((aggregateType !== 'DistinctCount') && (field.type !== 'number' || field.type === 'include' ||
@@ -26284,9 +26304,6 @@ class ExcelExport$1 {
26284
26304
  let clonedValues;
26285
26305
  let currentPivotValues = PivotExportUtil.getClonedPivotValues(this.engine.pivotValues);
26286
26306
  let customFileName = isFileNameSet ? exportProperties.fileName : 'default.xlsx';
26287
- if (isHeaderSet) {
26288
- this.addHeaderAndFooter(exportProperties.header, '', 'header', exportProperties.header.headerRows);
26289
- }
26290
26307
  if (this.parent.exportAllPages && this.parent.enableVirtualization && this.parent.dataType !== 'olap') {
26291
26308
  let pageSettings = this.engine.pageSettings;
26292
26309
  this.engine.pageSettings = null;
@@ -26300,7 +26317,7 @@ class ExcelExport$1 {
26300
26317
  clonedValues = currentPivotValues;
26301
26318
  }
26302
26319
  let args = {
26303
- fileName: customFileName, header: '', footer: '', dataCollections: [clonedValues]
26320
+ fileName: customFileName, header: '', footer: '', dataCollections: [clonedValues], excelExportProperties: exportProperties
26304
26321
  };
26305
26322
  let fileName;
26306
26323
  let header;
@@ -26334,6 +26351,14 @@ class ExcelExport$1 {
26334
26351
  for (let cCnt = 0; cCnt < colLen; cCnt++) {
26335
26352
  if (pivotValues[rCnt][cCnt]) {
26336
26353
  let pivotCell = pivotValues[rCnt][cCnt];
26354
+ let field = (this.parent.dataSourceSettings.valueAxis === 'row' &&
26355
+ this.parent.dataType === 'olap' && pivotCell.rowOrdinal &&
26356
+ this.engine.tupRowInfo[pivotCell.rowOrdinal]) ?
26357
+ this.engine.tupRowInfo[pivotCell.rowOrdinal].measureName :
26358
+ pivotCell.actualText;
26359
+ let styles = (pivotCell.axis == 'row') ? { hAlign: 'Left', bold: true, wrapText: true } : { numberFormat: formatList[field], bold: false, wrapText: true };
26360
+ let pivotCells = currentPivotValues[rCnt][cCnt];
26361
+ let headerStyle = { bold: true, vAlign: 'Center', wrapText: true, indent: cCnt === 0 ? pivotCell.level * 10 : 0 };
26337
26362
  if (!(pivotCell.level === -1 && !pivotCell.rowSpan)) {
26338
26363
  let cellValue = pivotCell.axis === 'value' ? pivotCell.value : pivotCell.formattedText;
26339
26364
  let isgetValuesHeader = ((this.parent.dataSourceSettings.rows.length === 0 && this.parent.dataSourceSettings.valueAxis === 'row')
@@ -26353,33 +26378,21 @@ class ExcelExport$1 {
26353
26378
  index: cCnt + 1, value: cellValue,
26354
26379
  colSpan: pivotCell.colSpan, rowSpan: (pivotCell.rowSpan === -1 ? 1 : pivotCell.rowSpan),
26355
26380
  });
26381
+ let lastCell = cells[cells.length - 1];
26356
26382
  if (pivotCell.axis === 'value') {
26357
26383
  if (isNaN(pivotCell.value) || pivotCell.formattedText === '' ||
26358
26384
  pivotCell.formattedText === undefined || isNullOrUndefined(pivotCell.value)) {
26359
- cells[cells.length - 1].value = type === 'Excel' ? null : '';
26360
- }
26361
- let field = (this.parent.dataSourceSettings.valueAxis === 'row' &&
26362
- this.parent.dataType === 'olap' && pivotCell.rowOrdinal &&
26363
- this.engine.tupRowInfo[pivotCell.rowOrdinal]) ?
26364
- this.engine.tupRowInfo[pivotCell.rowOrdinal].measureName :
26365
- pivotCell.actualText;
26366
- cells[cells.length - 1].style = !isNullOrUndefined(cells[cells.length - 1].value) ? { numberFormat: formatList[field], bold: false, wrapText: true } : { bold: false, wrapText: true };
26367
- if (pivotCell.style) {
26368
- cells[cells.length - 1].style.backColor = pivotCell.style.backgroundColor;
26369
- cells[cells.length - 1].style.fontColor = pivotCell.style.color;
26370
- cells[cells.length - 1].style.fontName = pivotCell.style.fontFamily;
26371
- cells[cells.length - 1].style.fontSize = Number(pivotCell.style.fontSize.split('px')[0]);
26385
+ lastCell.value = type === 'Excel' ? null : '';
26372
26386
  }
26387
+ lastCell.style = !isNullOrUndefined(lastCell.value) ? styles : { bold: false, wrapText: true };
26373
26388
  }
26374
26389
  else {
26375
- cells[cells.length - 1].style = {
26376
- bold: true, vAlign: 'Center', wrapText: true, indent: cCnt === 0 ? pivotCell.level * 10 : 0
26377
- };
26390
+ lastCell.style = headerStyle;
26378
26391
  if (pivotCell.axis === 'row' && cCnt === 0) {
26379
- cells[cells.length - 1].style.hAlign = 'Left';
26392
+ lastCell.style = styles;
26380
26393
  if (this.parent.dataType === 'olap') {
26381
26394
  let indent = this.parent.renderModule.indentCollection[rCnt];
26382
- cells[cells.length - 1].style.indent = indent * 2;
26395
+ lastCell.style.indent = indent * 2;
26383
26396
  maxLevel = maxLevel > indent ? maxLevel : indent;
26384
26397
  }
26385
26398
  else {
@@ -26389,19 +26402,55 @@ class ExcelExport$1 {
26389
26402
  let levelPosition = levelName.split(this.parent.dataSourceSettings.valueSortSettings.headerDelimiter).length -
26390
26403
  (memberPos ? memberPos - 1 : memberPos);
26391
26404
  let level = levelPosition ? (levelPosition - 1) : 0;
26392
- cells[cells.length - 1].style.indent = level * 2;
26405
+ lastCell.style.indent = level * 2;
26393
26406
  maxLevel = level > maxLevel ? level : maxLevel;
26394
26407
  }
26395
26408
  }
26396
26409
  }
26397
- cells[cells.length - 1].style.borders = { color: '#000000', lineStyle: 'Thin' };
26410
+ if (pivotCell.style || lastCell.style.backgroundColor || lastCell.style.fontColor || lastCell.style.fontName || lastCell.style.fontSize) {
26411
+ lastCell.style.backgroundColor = lastCell.style.backgroundColor ? lastCell.style.backgroundColor : pivotCell.style.backgroundColor;
26412
+ lastCell.style.fontColor = lastCell.style.fontColor ? lastCell.style.fontColor : pivotCell.style.color;
26413
+ lastCell.style.fontName = lastCell.style.fontName ? lastCell.style.fontName : pivotCell.style.fontFamily;
26414
+ lastCell.style.fontSize = lastCell.style.fontSize ? Number(lastCell.style.fontSize) : Number(pivotCell.style.fontSize.split('px')[0]);
26415
+ }
26416
+ lastCell.style.borders = { color: '#000000', lineStyle: 'Thin' };
26417
+ let excelHeaderQueryCellInfoArgs;
26418
+ let excelQueryCellInfoArgs;
26419
+ if (pivotCell.axis === 'column') {
26420
+ excelHeaderQueryCellInfoArgs = {
26421
+ style: headerStyle,
26422
+ cell: pivotCells,
26423
+ };
26424
+ this.parent.trigger(excelHeaderQueryCellInfo, excelHeaderQueryCellInfoArgs);
26425
+ }
26426
+ else {
26427
+ excelQueryCellInfoArgs = {
26428
+ style: styles,
26429
+ cell: pivotCells,
26430
+ column: undefined,
26431
+ data: pivotValues,
26432
+ value: cellValue
26433
+ };
26434
+ this.parent.trigger(excelQueryCellInfo, excelQueryCellInfoArgs);
26435
+ }
26436
+ lastCell.value = (pivotCell.axis == 'column') ? excelHeaderQueryCellInfoArgs.cell.formattedText : excelQueryCellInfoArgs.value;
26437
+ lastCell.style = (pivotCell.axis == 'column') ? excelHeaderQueryCellInfoArgs.style : excelQueryCellInfoArgs.style;
26398
26438
  }
26399
26439
  }
26400
26440
  cCnt = cCnt + (pivotCell.colSpan ? (pivotCell.colSpan - 1) : 0);
26401
26441
  }
26402
26442
  else {
26443
+ let pivotCell = { formattedText: "" };
26444
+ let excelHeaderQueryCellInfoArgs;
26445
+ if (pivotCell) {
26446
+ excelHeaderQueryCellInfoArgs = {
26447
+ style: undefined,
26448
+ cell: pivotCell,
26449
+ };
26450
+ this.parent.trigger(excelHeaderQueryCellInfo, excelHeaderQueryCellInfoArgs);
26451
+ }
26403
26452
  cells.push({
26404
- index: cCnt + 1, value: '', colSpan: 1, rowSpan: 1,
26453
+ index: cCnt + 1, colSpan: 1, rowSpan: 1, value: pivotCell.formattedText, style: excelHeaderQueryCellInfoArgs.style
26405
26454
  });
26406
26455
  }
26407
26456
  }
@@ -26472,14 +26521,21 @@ class PDFExport {
26472
26521
  let footer = (!isNullOrUndefined(pdfExportProperties) && !isNullOrUndefined(pdfExportProperties.footer) && !isNullOrUndefined(pdfExportProperties.footer.contents) && !isNullOrUndefined(pdfExportProperties.footer.contents[0].value)) ?
26473
26522
  pdfExportProperties.footer.contents[0].value : eventParams.args.footer;
26474
26523
  let font = new PdfStandardFont(PdfFontFamily.TimesRoman, 15, PdfFontStyle.Regular);
26475
- let brush = new PdfSolidBrush(new PdfColor(0, 0, 0));
26524
+ let headerCondition = (!isNullOrUndefined(pdfExportProperties) && !isNullOrUndefined(pdfExportProperties.header)
26525
+ && !isNullOrUndefined(pdfExportProperties.header.contents) && !isNullOrUndefined(pdfExportProperties.header.contents[0].style));
26526
+ let footerCondition = (!isNullOrUndefined(pdfExportProperties) && !isNullOrUndefined(pdfExportProperties.footer)
26527
+ && !isNullOrUndefined(pdfExportProperties.footer.contents) && !isNullOrUndefined(pdfExportProperties.footer.contents[0].style));
26528
+ let headerColor = (headerCondition) ? this.hexDecToRgb(pdfExportProperties.header.contents[0].style.textBrushColor) : (new PdfColor(0, 0, 0));
26529
+ let brushHeader = (headerCondition) ? new PdfSolidBrush(new PdfColor(headerColor.r, headerColor.g, headerColor.b)) : new PdfSolidBrush(new PdfColor(0, 0, 0));
26530
+ let footerColor = (footerCondition) ? this.hexDecToRgb(pdfExportProperties.footer.contents[0].style.textBrushColor) : (new PdfColor(0, 0, 0));
26531
+ let brushFooter = (footerCondition) ? new PdfSolidBrush(new PdfColor(footerColor.r, footerColor.g, footerColor.b)) : new PdfSolidBrush(new PdfColor(0, 0, 0));
26476
26532
  let pen = new PdfPen(new PdfColor(0, 0, 0), .5);
26477
26533
  /** Header and Footer to be set */
26478
26534
  let headerTemplate = new PdfPageTemplateElement(new RectangleF(0, 0, page.graphics.clientSize.width, 20));
26479
- headerTemplate.graphics.drawString(header, font, pen, brush, 0, 0, new PdfStringFormat(PdfTextAlignment.Center));
26535
+ headerTemplate.graphics.drawString(header, font, pen, brushHeader, 0, 0, new PdfStringFormat(PdfTextAlignment.Center));
26480
26536
  eventParams.document.template.top = headerTemplate;
26481
26537
  let footerTemplate = new PdfPageTemplateElement(new RectangleF(0, 0, page.graphics.clientSize.width, 20));
26482
- footerTemplate.graphics.drawString(footer, font, pen, brush, 0, 0, new PdfStringFormat(PdfTextAlignment.Center));
26538
+ footerTemplate.graphics.drawString(footer, font, pen, brushFooter, 0, 0, new PdfStringFormat(PdfTextAlignment.Center));
26483
26539
  eventParams.document.template.bottom = footerTemplate;
26484
26540
  return page;
26485
26541
  }
@@ -26661,12 +26717,12 @@ class PDFExport {
26661
26717
  let isValueCell = false;
26662
26718
  if (pivotValues[rCnt][cCnt]) {
26663
26719
  let pivotCell = pivotValues[rCnt][cCnt];
26720
+ let cellValue = pivotCell.formattedText;
26721
+ cellValue = (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) ? this.parent.getValuesHeader(pivotCell, 'value') : cellValue;
26722
+ cellValue = pivotCell.type === 'grand sum' ? (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) ? this.parent.getValuesHeader(pivotCell, 'grandTotal') :
26723
+ this.parent.localeObj.getConstant('grandTotal') : (pivotCell.type === 'sum' ?
26724
+ cellValue.toString().replace('Total', this.parent.localeObj.getConstant('total')) : cellValue);
26664
26725
  if (!(pivotCell.level === -1 && !pivotCell.rowSpan)) {
26665
- let cellValue = pivotCell.formattedText;
26666
- cellValue = (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) ? this.parent.getValuesHeader(pivotCell, 'value') : cellValue;
26667
- cellValue = pivotCell.type === 'grand sum' ? (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) ? this.parent.getValuesHeader(pivotCell, 'grandTotal') :
26668
- this.parent.localeObj.getConstant('grandTotal') : (pivotCell.type === 'sum' ?
26669
- cellValue.toString().replace('Total', this.parent.localeObj.getConstant('total')) : cellValue);
26670
26726
  if (!(pivotCell.level === -1 && !pivotCell.rowSpan)) {
26671
26727
  pdfGridRow.cells.getCell(localCnt).columnSpan = pivotCell.colSpan ?
26672
26728
  (pageSize - localCnt < pivotCell.colSpan ? pageSize - localCnt : pivotCell.colSpan) : 1;
@@ -26689,11 +26745,31 @@ class PDFExport {
26689
26745
  pdfGridRow = this.applyStyle(pdfGridRow, pivotCell, localCnt);
26690
26746
  }
26691
26747
  let args = {
26692
- style: (pivotCell && pivotCell.isSum) ? { bold: true } : undefined,
26748
+ style: (pivotCell.axis == "column") ? { bold: false } : ((pivotCell && pivotCell.isSum) || (pivotCell.axis == "row")) ? { bold: true } : undefined,
26693
26749
  pivotCell: pivotCell,
26694
26750
  cell: pdfGridRow.cells.getCell(localCnt)
26695
26751
  };
26696
26752
  this.parent.trigger(onPdfCellRender, args);
26753
+ if (pivotCell.axis == "column") {
26754
+ args = {
26755
+ style: args.style,
26756
+ cell: args.cell,
26757
+ gridCell: args.pivotCell
26758
+ };
26759
+ this.parent.trigger(pdfHeaderQueryCellInfo, args);
26760
+ pdfGridRow.cells.getCell(localCnt).value = args.gridCell.formattedText ? args.gridCell.formattedText : cellValue;
26761
+ }
26762
+ else {
26763
+ args = {
26764
+ style: args.style,
26765
+ cell: args.cell,
26766
+ column: undefined,
26767
+ data: args.pivotCell,
26768
+ value: cellValue,
26769
+ };
26770
+ this.parent.trigger(pdfQueryCellInfo, args);
26771
+ pdfGridRow.cells.getCell(localCnt).value = args.value ? args.value : cellValue;
26772
+ }
26697
26773
  if (args.style) {
26698
26774
  this.processCellStyle(pdfGridRow.cells.getCell(localCnt), args);
26699
26775
  }
@@ -26705,6 +26781,15 @@ class PDFExport {
26705
26781
  cell: pdfGridRow.cells.getCell(localCnt)
26706
26782
  };
26707
26783
  this.parent.trigger(onPdfCellRender, args);
26784
+ let pivotCell = { formattedText: "" };
26785
+ if (pivotCell.axis == "column") {
26786
+ args = {
26787
+ style: args.style,
26788
+ cell: args.cell,
26789
+ gridCell: args.pivotCell
26790
+ };
26791
+ this.parent.trigger(pdfHeaderQueryCellInfo, args);
26792
+ }
26708
26793
  if (args.style) {
26709
26794
  this.processCellStyle(pdfGridRow.cells.getCell(localCnt), args);
26710
26795
  }
@@ -27940,6 +28025,9 @@ class TreeViewRenderer {
27940
28025
  return buttonElement;
27941
28026
  }
27942
28027
  nodeStateChange(args) {
28028
+ if (!args.isInteracted) {
28029
+ return;
28030
+ }
27943
28031
  let node = closest(args.node, '.' + TEXT_CONTENT_CLASS);
27944
28032
  if (!isNullOrUndefined(node)) {
27945
28033
  let li = closest(node, 'li');
@@ -27971,7 +28059,7 @@ class TreeViewRenderer {
27971
28059
  this.updateNodeStateChange(id, args, selectedNode);
27972
28060
  }
27973
28061
  else {
27974
- this.updateCheckState(selectedNode);
28062
+ this.updateCheckState(selectedNode, args.action);
27975
28063
  }
27976
28064
  });
27977
28065
  }
@@ -27998,7 +28086,7 @@ class TreeViewRenderer {
27998
28086
  this.updateNodeStateChange(id, args, selectedNode);
27999
28087
  }
28000
28088
  else {
28001
- this.updateCheckState(selectedNode);
28089
+ this.updateCheckState(selectedNode, args.action);
28002
28090
  }
28003
28091
  });
28004
28092
  }
@@ -28055,19 +28143,17 @@ class TreeViewRenderer {
28055
28143
  break;
28056
28144
  }
28057
28145
  }
28058
- updateCheckState(selectedNode) {
28146
+ updateCheckState(selectedNode, action) {
28059
28147
  let chkState = this.fieldTable.element.querySelectorAll('.e-checkbox-wrapper');
28060
28148
  let innerText = this.fieldTable.element.querySelectorAll('.e-list-text');
28061
28149
  let checkClass = this.fieldTable.element.querySelectorAll('.e-frame');
28062
28150
  for (let i = 0; i < chkState.length; i++) {
28063
28151
  if (selectedNode.caption === innerText[i].textContent) {
28064
- if (chkState[i].getAttribute('aria-checked') === 'false') {
28065
- chkState[i].setAttribute('aria-checked', 'false');
28066
- checkClass[i].classList.add(NODE_CHECK_CLASS);
28152
+ if (action === 'check') {
28153
+ this.fieldTable.uncheckAll([selectedNode['id']]);
28067
28154
  }
28068
28155
  else {
28069
- chkState[i].setAttribute('aria-checked', 'true');
28070
- checkClass[i].classList.remove(NODE_CHECK_CLASS);
28156
+ this.fieldTable.checkAll([selectedNode['id']]);
28071
28157
  }
28072
28158
  }
28073
28159
  }
@@ -28116,6 +28202,9 @@ class TreeViewRenderer {
28116
28202
  }
28117
28203
  }
28118
28204
  addNode(args) {
28205
+ if (!args.isInteracted) {
28206
+ return;
28207
+ }
28119
28208
  /* eslint-disable */
28120
28209
  let fieldList = this.parent.pivotFieldList;
28121
28210
  let selectedNode = fieldList[args.data[0].id.toString()];
@@ -28123,17 +28212,18 @@ class TreeViewRenderer {
28123
28212
  let fieldInfo = PivotUtil.getFieldInfo(selectedNode.id.toString(), this.parent);
28124
28213
  let control = this.parent.isPopupView ? this.parent.pivotGridModule : this.parent;
28125
28214
  if (args.action === 'check') {
28215
+ let axis = ['filters', 'columns', 'rows', 'values'];
28126
28216
  let eventdrop = {
28127
28217
  fieldName: fieldInfo.fieldName, dropField: fieldInfo.fieldItem,
28128
28218
  dataSourceSettings: PivotUtil.getClonedDataSourceSettings(this.parent.dataSourceSettings),
28129
- dropAxis: 'rows', draggedAxis: 'fieldlist', cancel: false
28219
+ dropAxis: axis[this.parent.dialogRenderer.adaptiveElement.selectedItem], draggedAxis: 'fieldlist', cancel: false
28130
28220
  };
28131
28221
  control.trigger(fieldDrop, eventdrop, (observedArgs) => {
28132
28222
  if (!observedArgs.cancel) {
28133
28223
  this.selectedNodes.push(selectedNode.id.toString());
28134
28224
  }
28135
28225
  else {
28136
- this.updateCheckState(selectedNode);
28226
+ this.updateCheckState(selectedNode, args.action);
28137
28227
  }
28138
28228
  });
28139
28229
  }
@@ -28154,7 +28244,7 @@ class TreeViewRenderer {
28154
28244
  }
28155
28245
  }
28156
28246
  else {
28157
- this.updateCheckState(selectedNode);
28247
+ this.updateCheckState(selectedNode, args.action);
28158
28248
  }
28159
28249
  });
28160
28250
  }
@@ -28547,7 +28637,7 @@ class AxisTableRenderer {
28547
28637
  addClass([element[element.length - 1].querySelector('.' + DROP_INDICATOR_CLASS + '-last')], INDICATOR_HOVER_CLASS);
28548
28638
  }
28549
28639
  }
28550
- else if (e.type === 'mouseleave') {
28640
+ else if (!this.parent.isDragging || (!e.target.classList.contains(DROPPABLE_CLASS) && e.type === 'mouseleave')) {
28551
28641
  removeClass([].slice.call(parentElement.querySelectorAll('.' + DROP_INDICATOR_CLASS)), INDICATOR_HOVER_CLASS);
28552
28642
  removeClass([].slice.call(parentElement.querySelectorAll('.' + DROP_INDICATOR_CLASS + '-last')), INDICATOR_HOVER_CLASS);
28553
28643
  }
@@ -30205,6 +30295,8 @@ let PivotFieldList = class PivotFieldList extends Component {
30205
30295
  this.remoteData = [];
30206
30296
  /** @hidden */
30207
30297
  this.actionObj = {};
30298
+ /** @hidden */
30299
+ this.destroyEngine = false;
30208
30300
  }
30209
30301
  /**
30210
30302
  * To provide the array of modules needed for control rendering
@@ -31286,7 +31378,7 @@ let PivotFieldList = class PivotFieldList extends Component {
31286
31378
  */
31287
31379
  destroy() {
31288
31380
  this.unWireEvent();
31289
- if (this.engineModule) {
31381
+ if (this.engineModule && !this.destroyEngine) {
31290
31382
  this.engineModule.fieldList = {};
31291
31383
  this.engineModule.rMembers = null;
31292
31384
  this.engineModule.cMembers = null;
@@ -31294,7 +31386,7 @@ let PivotFieldList = class PivotFieldList extends Component {
31294
31386
  this.engineModule.indexMatrix = null;
31295
31387
  this.engineModule = {};
31296
31388
  }
31297
- if (this.olapEngineModule) {
31389
+ if (this.olapEngineModule && !this.destroyEngine) {
31298
31390
  this.olapEngineModule.fieldList = {};
31299
31391
  this.olapEngineModule = {};
31300
31392
  }
@@ -34252,7 +34344,7 @@ class GroupingBar {
34252
34344
  }
34253
34345
  dropIndicatorUpdate(e) {
34254
34346
  if ((this.parent.isDragging && e.target.classList.contains(DROPPABLE_CLASS) && e.type === 'mouseover') ||
34255
- e.type === 'mouseleave') {
34347
+ (!this.parent.isDragging || (!e.target.classList.contains(DROPPABLE_CLASS) && e.type === 'mouseleave'))) {
34256
34348
  removeClass([].slice.call(this.parent.element.querySelectorAll('.' + DROP_INDICATOR_CLASS)), INDICATOR_HOVER_CLASS);
34257
34349
  removeClass([].slice.call(this.parent.element.querySelectorAll('.' + DROP_INDICATOR_CLASS + '-last')), INDICATOR_HOVER_CLASS);
34258
34350
  }
@@ -35272,10 +35364,10 @@ class Toolbar$2 {
35272
35364
  }
35273
35365
  }
35274
35366
  actionClick(args) {
35275
- let actionName = (args.item.id == "PivotViewnew") ? addNewReport : (args.item.id == "PivotViewsave") ? saveCurrentReport : (args.item.id == "PivotViewsaveas") ? saveAsCurrentReport
35276
- : (args.item.id == "PivotViewrename") ? renameCurrentReport : (args.item.id == "PivotViewremove") ? removeCurrentReport : (args.item.id == "PivotViewload") ? loadReports
35277
- : (args.item.id == "PivotViewformatting") ? openConditionalFormatting : (args.item.id == "PivotViewnumberFormatting") ? openNumberFormatting
35278
- : (args.item.id == "PivotViewmdxQuery") ? MdxQuery : (args.item.id == "PivotViewfieldlist") ? showFieldList : '';
35367
+ let actionName = (args.item.id == this.parent.element.id + 'new') ? addNewReport : (args.item.id == this.parent.element.id + 'save') ? saveCurrentReport : (args.item.id == this.parent.element.id + 'saveas') ? saveAsCurrentReport
35368
+ : (args.item.id == this.parent.element.id + 'rename') ? renameCurrentReport : (args.item.id == this.parent.element.id + 'remove') ? removeCurrentReport : (args.item.id == this.parent.element.id + 'load') ? loadReports
35369
+ : (args.item.id == this.parent.element.id + 'formatting') ? openConditionalFormatting : (args.item.id == this.parent.element.id + 'numberFormatting') ? openNumberFormatting
35370
+ : (args.item.id == this.parent.element.id + 'mdxQuery') ? MdxQuery : (args.item.id == this.parent.element.id + 'fieldlist') ? showFieldList : '';
35279
35371
  this.parent.actionObj.actionName = actionName;
35280
35372
  if (this.parent.actionBeginMethod()) {
35281
35373
  return;
@@ -36111,14 +36203,14 @@ class Toolbar$2 {
36111
36203
  menuItemClick(args) {
36112
36204
  let exportArgs = {};
36113
36205
  let type;
36114
- let actionName = (args.item.id == "PivotViewgrid") ? tableView : (args.item.id == "PivotView_Column") ? chartView : (args.item.id == "PivotView_Bar") ? chartView : (args.item.id == "PivotView_Line") ? chartView
36115
- : (args.item.id == "PivotView_Area") ? chartView : (args.item.id == "PivotView_Scatter") ? chartView : (args.item.id == "PivotView_Polar") ? chartView : (args.item.id == "PivotView_ChartMoreOption") ? chartView
36116
- : (args.item.id == "PivotView_multipleAxes") ? multipleAxis : (args.item.id == "PivotView_showLegend") ? showLegend : (args.item.id == "PivotViewpdf") ? pdfExport : (args.item.id == "PivotViewpng") ? pngExport
36117
- : (args.item.id == "PivotViewexcel") ? excelExport : (args.item.id == "PivotViewcsv") ? csvExport : (args.item.id == "PivotViewjpeg") ? jpegExport : (args.item.id == "PivotViewsvg") ? svgExport
36118
- : (args.item.id == "PivotViewnotsubtotal") ? hideSubTotals : (args.item.id == "PivotViewsubtotalrow") ? subTotalsRow : (args.item.id == "PivotViewsubtotalcolumn") ? subTotalsColumn
36119
- : (args.item.id == "PivotViewsubtotal") ? showSubTotals : (args.item.id == "PivotViewnotgrandtotal") ? hideGrandTotals : (args.item.id == "PivotViewgrandtotalrow") ? grandTotalsRow
36120
- : (args.item.id == "PivotViewgrandtotalcolumn") ? grandTotalsColumn : (args.item.id == "PivotViewgrandtotal") ? showGrandTotals
36121
- : (args.item.id == "PivotViewnumberFormattingMenu") ? numberFormattingMenu : (args.item.id == "PivotViewconditionalFormattingMenu") ? conditionalFormattingMenu : '';
36206
+ let actionName = (args.item.id == this.parent.element.id + 'grid') ? tableView : (args.item.id == this.parent.element.id + '_' + "Column") ? chartView : (args.item.id == this.parent.element.id + '_' + "Bar") ? chartView : (args.item.id == this.parent.element.id + '_' + "Line") ? chartView
36207
+ : (args.item.id == this.parent.element.id + '_' + "Area") ? chartView : (args.item.id == this.parent.element.id + '_' + "Scatter") ? chartView : (args.item.id == this.parent.element.id + '_' + "Polar") ? chartView : (args.item.id == this.parent.element.id + '_' + "ChartMoreOption") ? chartView
36208
+ : (args.item.id == this.parent.element.id + '_' + "multipleAxes") ? multipleAxis : (args.item.id == this.parent.element.id + '_' + "showLegend") ? showLegend : (args.item.id == this.parent.element.id + "pdf") ? pdfExport : (args.item.id == this.parent.element.id + "png") ? pngExport
36209
+ : (args.item.id == this.parent.element.id + "excel") ? excelExport : (args.item.id == this.parent.element.id + "csv") ? csvExport : (args.item.id == this.parent.element.id + "jpeg") ? jpegExport : (args.item.id == this.parent.element.id + "svg") ? svgExport
36210
+ : (args.item.id == this.parent.element.id + "notsubtotal") ? hideSubTotals : (args.item.id == this.parent.element.id + "subtotalrow") ? subTotalsRow : (args.item.id == this.parent.element.id + "subtotalcolumn") ? subTotalsColumn
36211
+ : (args.item.id == this.parent.element.id + "subtotal") ? showSubTotals : (args.item.id == this.parent.element.id + "notgrandtotal") ? hideGrandTotals : (args.item.id == this.parent.element.id + "grandtotalrow") ? grandTotalsRow
36212
+ : (args.item.id == this.parent.element.id + "grandtotalcolumn") ? grandTotalsColumn : (args.item.id == this.parent.element.id + "grandtotal") ? showGrandTotals
36213
+ : (args.item.id == this.parent.element.id + "numberFormattingMenu") ? numberFormattingMenu : (args.item.id == this.parent.element.id + "conditionalFormattingMenu") ? conditionalFormattingMenu : '';
36122
36214
  this.parent.actionObj.actionName = actionName;
36123
36215
  if (this.parent.actionBeginMethod()) {
36124
36216
  return;