@syncfusion/ej2-pivotview 19.3.43 → 19.3.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.
@@ -1,4 +1,4 @@
1
- import { Property, Browser, Component, ModuleDeclaration, createElement, setStyleAttribute } from '@syncfusion/ej2-base';import { EmitType, EventHandler, Complex, extend, ChildProperty, Collection, isNullOrUndefined, remove } from '@syncfusion/ej2-base';import { Internationalization, L10n, NotifyPropertyChanges, INotifyPropertyChanged, compile, formatUnit } from '@syncfusion/ej2-base';import { removeClass, addClass, Event, KeyboardEventArgs, setValue, closest, select } from '@syncfusion/ej2-base';import { MouseEventArgs } from '@syncfusion/ej2-base';import { PivotEngine, IPivotValues, IAxisSet, IDataOptions, IDataSet } from '../../base/engine';import { IPageSettings, IGroupSettings, IGridValues, IFieldListOptions, IValueSortSettings } from '../../base/engine';import { IDrilledItem, ICustomProperties, ISort, IFilter, IFieldOptions, ICalculatedFields, IDrillOptions } from '../../base/engine';import { IConditionalFormatSettings, IStringIndex, IField, IFormatSettings } from '../../base/engine';import { Tooltip, TooltipEventArgs, createSpinner, showSpinner, hideSpinner } from '@syncfusion/ej2-popups';import * as events from '../../common/base/constant';import * as cls from '../../common/base/css-constant';import { AxisFields } from '../../common/grouping-bar/axis-field-renderer';import { LoadEventArgs, EnginePopulatingEventArgs, DrillThroughEventArgs, PivotColumn, ChartLabelInfo, EditCompletedEventArgs, MultiLevelLabelClickEventArgs, BeforeServiceInvokeEventArgs, FetchRawDataArgs, UpdateRawDataArgs } from '../../common/base/interface';import { FetchReportArgs, LoadReportArgs, RenameReportArgs, RemoveReportArgs, ToolbarArgs } from '../../common/base/interface';import { PdfCellRenderArgs, NewReportArgs, ChartSeriesCreatedEventArgs, AggregateEventArgs } from '../../common/base/interface';import { ResizeInfo, ScrollInfo, ColumnRenderEventArgs, PivotCellSelectedEventArgs, SaveReportArgs } from '../../common/base/interface';import { CellClickEventArgs, FieldDroppedEventArgs, HyperCellClickEventArgs, CellTemplateArgs } from '../../common/base/interface';import { BeforeExportEventArgs, EnginePopulatedEventArgs, BeginDrillThroughEventArgs, DrillArgs } from '../../common/base/interface';import { FieldListRefreshedEventArgs, MemberFilteringEventArgs, FieldDropEventArgs } from '../../common/base/interface';import { MemberEditorOpenEventArgs, FieldRemoveEventArgs, AggregateMenuOpenEventArgs } from '../../common/base/interface';import { CalculatedFieldCreateEventArgs, NumberFormattingEventArgs, FieldDragStartEventArgs } from '../../common/base/interface';import { Render } from '../renderer/render';import { PivotCommon } from '../../common/base/pivot-common';import { Common } from '../../common/actions/common';import { GroupingBar } from '../../common/grouping-bar/grouping-bar';import { DataSourceSettingsModel, DrillOptionsModel, FormatSettingsModel } from '../model/datasourcesettings-model';import { DataSourceSettings } from '../model/datasourcesettings';import { GridSettings } from '../model/gridsettings';import { GridSettingsModel } from '../model/gridsettings-model';import { PivotButton } from '../../common/actions/pivot-button';import { PivotFieldList } from '../../pivotfieldlist/base/field-list';import { Grid, QueryCellInfoEventArgs, ColumnModel, Reorder, Resize, getObject } from '@syncfusion/ej2-grids';import { SelectionType, ContextMenuItemModel } from '@syncfusion/ej2-grids';import { CellSelectEventArgs, RowSelectEventArgs, ResizeArgs } from '@syncfusion/ej2-grids';import { RowDeselectEventArgs, ContextMenuClickEventArgs } from '@syncfusion/ej2-grids';import { EditSettingsModel, HeaderCellInfoEventArgs, CellDeselectEventArgs } from '@syncfusion/ej2-grids';import { PdfExportProperties, ExcelExportProperties, ExcelQueryCellInfoEventArgs, ColumnDragEventArgs } from '@syncfusion/ej2-grids';import { ExcelHeaderQueryCellInfoEventArgs, PdfQueryCellInfoEventArgs, PdfHeaderQueryCellInfoEventArgs } from '@syncfusion/ej2-grids';import { ExcelExport } from '../actions/excel-export';import { PDFExport } from '../actions/pdf-export';import { CalculatedField } from '../../common/calculatedfield/calculated-field';import { KeyboardInteraction } from '../actions/keyboard';import { PivotContextMenu } from '../../common/popups/context-menu';import { DataManager, ReturnOption, Query } from '@syncfusion/ej2-data';import { ConditionalFormatting } from '../../common/conditionalformatting/conditional-formatting';import { VirtualScroll } from '../actions/virtualscroll';import { DrillThrough } from '../actions/drill-through';import { Condition, GroupType } from '../../base/types';import { EditMode, ToolbarItems, View, Primary, AggregateTypes, ChartSeriesType, PivotTableContextMenuItem } from '../../common';import { PivotUtil } from '../../base/util';import { Toolbar } from '../../common/popups/toolbar';import { PivotChart } from '../../pivotchart/index';import { ChartSettings } from '../model/chartsettings';import { ChartSettingsModel } from '../model/chartsettings-model';import { Chart, ITooltipRenderEventArgs, ILoadedEventArgs, IPointEventArgs, AccumulationChart } from '@syncfusion/ej2-charts';import { IResizeEventArgs, IAxisLabelRenderEventArgs, ExportType } from '@syncfusion/ej2-charts';import { PdfPageOrientation } from '@syncfusion/ej2-pdf-export';import { ClickEventArgs, BeforeOpenCloseMenuEventArgs, ItemModel } from '@syncfusion/ej2-navigations';import { OlapEngine, IOlapCustomProperties, ITupInfo, IDrillInfo, IOlapField } from '../../base/olap/engine';import { NumberFormatting } from '../../common/popups/formatting-dialog';import { Grouping } from '../../common/popups/grouping';
1
+ import { Property, Browser, Component, ModuleDeclaration, createElement, setStyleAttribute } from '@syncfusion/ej2-base';import { EmitType, EventHandler, Complex, extend, ChildProperty, Collection, isNullOrUndefined, remove } from '@syncfusion/ej2-base';import { Internationalization, L10n, NotifyPropertyChanges, INotifyPropertyChanged, compile, formatUnit } from '@syncfusion/ej2-base';import { removeClass, addClass, Event, KeyboardEventArgs, setValue, closest, select } from '@syncfusion/ej2-base';import { MouseEventArgs } from '@syncfusion/ej2-base';import { PivotEngine, IPivotValues, IAxisSet, IDataOptions, IDataSet } from '../../base/engine';import { IPageSettings, IGroupSettings, IGridValues, IFieldListOptions, IValueSortSettings } from '../../base/engine';import { IDrilledItem, ICustomProperties, ISort, IFilter, IFieldOptions, ICalculatedFields, IDrillOptions } from '../../base/engine';import { IConditionalFormatSettings, IStringIndex, IField, IFormatSettings } from '../../base/engine';import { Tooltip, TooltipEventArgs, createSpinner, showSpinner, hideSpinner } from '@syncfusion/ej2-popups';import * as events from '../../common/base/constant';import * as cls from '../../common/base/css-constant';import { AxisFields } from '../../common/grouping-bar/axis-field-renderer';import { LoadEventArgs, EnginePopulatingEventArgs, DrillThroughEventArgs, PivotColumn, ChartLabelInfo, EditCompletedEventArgs, MultiLevelLabelClickEventArgs, BeforeServiceInvokeEventArgs, FetchRawDataArgs, UpdateRawDataArgs } from '../../common/base/interface';import { FetchReportArgs, LoadReportArgs, RenameReportArgs, RemoveReportArgs, ToolbarArgs } from '../../common/base/interface';import { PdfCellRenderArgs, NewReportArgs, ChartSeriesCreatedEventArgs, AggregateEventArgs } from '../../common/base/interface';import { ResizeInfo, ScrollInfo, ColumnRenderEventArgs, PivotCellSelectedEventArgs, SaveReportArgs } from '../../common/base/interface';import { CellClickEventArgs, FieldDroppedEventArgs, HyperCellClickEventArgs, CellTemplateArgs } from '../../common/base/interface';import { BeforeExportEventArgs, EnginePopulatedEventArgs, BeginDrillThroughEventArgs, DrillArgs } from '../../common/base/interface';import { FieldListRefreshedEventArgs, MemberFilteringEventArgs, FieldDropEventArgs } from '../../common/base/interface';import { MemberEditorOpenEventArgs, FieldRemoveEventArgs, AggregateMenuOpenEventArgs } from '../../common/base/interface';import { CalculatedFieldCreateEventArgs, NumberFormattingEventArgs, FieldDragStartEventArgs } from '../../common/base/interface';import { Render } from '../renderer/render';import { PivotCommon } from '../../common/base/pivot-common';import { Common } from '../../common/actions/common';import { GroupingBar } from '../../common/grouping-bar/grouping-bar';import { DataSourceSettingsModel, DrillOptionsModel, FieldOptionsModel, FormatSettingsModel } from '../model/datasourcesettings-model';import { DataSourceSettings } from '../model/datasourcesettings';import { GridSettings } from '../model/gridsettings';import { GridSettingsModel } from '../model/gridsettings-model';import { PivotButton } from '../../common/actions/pivot-button';import { PivotFieldList } from '../../pivotfieldlist/base/field-list';import { Grid, QueryCellInfoEventArgs, ColumnModel, Reorder, Resize, getObject } from '@syncfusion/ej2-grids';import { SelectionType, ContextMenuItemModel } from '@syncfusion/ej2-grids';import { CellSelectEventArgs, RowSelectEventArgs, ResizeArgs } from '@syncfusion/ej2-grids';import { RowDeselectEventArgs, ContextMenuClickEventArgs } from '@syncfusion/ej2-grids';import { EditSettingsModel, HeaderCellInfoEventArgs, CellDeselectEventArgs } from '@syncfusion/ej2-grids';import { PdfExportProperties, ExcelExportProperties, ExcelQueryCellInfoEventArgs, ColumnDragEventArgs } from '@syncfusion/ej2-grids';import { ExcelHeaderQueryCellInfoEventArgs, PdfQueryCellInfoEventArgs, PdfHeaderQueryCellInfoEventArgs } from '@syncfusion/ej2-grids';import { ExcelExport } from '../actions/excel-export';import { PDFExport } from '../actions/pdf-export';import { CalculatedField } from '../../common/calculatedfield/calculated-field';import { KeyboardInteraction } from '../actions/keyboard';import { PivotContextMenu } from '../../common/popups/context-menu';import { DataManager, ReturnOption, Query } from '@syncfusion/ej2-data';import { ConditionalFormatting } from '../../common/conditionalformatting/conditional-formatting';import { VirtualScroll } from '../actions/virtualscroll';import { DrillThrough } from '../actions/drill-through';import { Condition, GroupType } from '../../base/types';import { EditMode, ToolbarItems, View, Primary, AggregateTypes, ChartSeriesType, PivotTableContextMenuItem } from '../../common';import { PivotUtil } from '../../base/util';import { Toolbar } from '../../common/popups/toolbar';import { PivotChart } from '../../pivotchart/index';import { ChartSettings } from '../model/chartsettings';import { ChartSettingsModel } from '../model/chartsettings-model';import { Chart, ITooltipRenderEventArgs, ILoadedEventArgs, IPointEventArgs, AccumulationChart } from '@syncfusion/ej2-charts';import { IResizeEventArgs, IAxisLabelRenderEventArgs, ExportType } from '@syncfusion/ej2-charts';import { PdfPageOrientation } from '@syncfusion/ej2-pdf-export';import { ClickEventArgs, BeforeOpenCloseMenuEventArgs, ItemModel } from '@syncfusion/ej2-navigations';import { OlapEngine, IOlapCustomProperties, ITupInfo, IDrillInfo, IOlapField } from '../../base/olap/engine';import { NumberFormatting } from '../../common/popups/formatting-dialog';import { Grouping } from '../../common/popups/grouping';
2
2
  import {ComponentModel} from '@syncfusion/ej2-base';
3
3
 
4
4
  /**
@@ -1505,7 +1505,7 @@ export declare class PivotView extends Component<HTMLElement> implements INotify
1505
1505
  /** @hidden */
1506
1506
  getHeaderField(rowIndex: number, colIndex: number, axis: string): string;
1507
1507
  private getLevel;
1508
- private getRowText;
1508
+ getRowText(rowIndex: number, colIndex: number): string;
1509
1509
  private getColText;
1510
1510
  private updateClass;
1511
1511
  private mouseRclickHandler;
@@ -1585,4 +1585,6 @@ export declare class PivotView extends Component<HTMLElement> implements INotify
1585
1585
  * @returns {void}
1586
1586
  */
1587
1587
  showNumberFormattingDialog(): void;
1588
+ /** @hidden */
1589
+ getValuesHeader(pivotCell: IAxisSet, type: string): string;
1588
1590
  }
@@ -2506,13 +2506,21 @@ var PivotView = /** @class */ (function (_super) {
2506
2506
  var cell = this.pivotValues[rowIndex][colIndex];
2507
2507
  var level = this.getLevel(cell);
2508
2508
  var rowText = cell.type === 'grand sum' ? this.localeObj.getConstant('grandTotal') : cell.formattedText;
2509
- while (level > 0 || cell.index === undefined) {
2510
- rowIndex--;
2511
- cell = this.pivotValues[rowIndex][colIndex];
2512
- if (cell.index !== undefined) {
2513
- if (level > cell.level) {
2514
- rowText = rowText + ' - ' + cell.formattedText;
2515
- level = level - 1;
2509
+ if (this.dataSourceSettings.valueAxis === 'row') {
2510
+ rowText = (this.dataSourceSettings.rows.length === 0 && this.dataSourceSettings.values.length > 1) ? this.pivotValues[rowIndex][0].valueSort.levelName.toString().slice((this.localeObj.getConstant('grandTotal')
2511
+ + this.dataSourceSettings.valueSortSettings.headerDelimiter).length).toString() : this.dataSourceSettings.values.length === 1 ? !isNullOrUndefined(this.dataSourceSettings.values[0].caption) ?
2512
+ this.dataSourceSettings.values[0].caption : this.dataSourceSettings.values[0].name : this.pivotValues[rowIndex][0].valueSort.levelName.toString();
2513
+ return rowText.split(this.dataSourceSettings.valueSortSettings.headerDelimiter).join(' - ');
2514
+ }
2515
+ else {
2516
+ while (level > 0 || cell.index === undefined) {
2517
+ rowIndex--;
2518
+ cell = this.pivotValues[rowIndex][colIndex];
2519
+ if (cell.index !== undefined) {
2520
+ if (level > cell.level) {
2521
+ rowText = rowText + ' - ' + cell.formattedText;
2522
+ level = level - 1;
2523
+ }
2516
2524
  }
2517
2525
  }
2518
2526
  }
@@ -2970,7 +2978,7 @@ var PivotView = /** @class */ (function (_super) {
2970
2978
  ele = target;
2971
2979
  }
2972
2980
  else if (target.classList.contains('e-stackedheadercelldiv') || target.classList.contains('e-cellvalue') ||
2973
- target.classList.contains('e-headercelldiv')) {
2981
+ target.classList.contains('e-headercelldiv') || target.classList.contains('e-sortfilterdiv')) {
2974
2982
  ele = target.parentElement;
2975
2983
  }
2976
2984
  else if (target.classList.contains('e-headertext')) {
@@ -3915,6 +3923,22 @@ var PivotView = /** @class */ (function (_super) {
3915
3923
  this.numberFormattingModule.showNumberFormattingDialog();
3916
3924
  }
3917
3925
  };
3926
+ /** @hidden */
3927
+ PivotView.prototype.getValuesHeader = function (pivotCell, type) {
3928
+ var values = this.dataSourceSettings.values;
3929
+ if (type === 'value' && !isNullOrUndefined(pivotCell.valueSort) && (this.localeObj.getConstant('grandTotal') + this.dataSourceSettings.valueSortSettings.headerDelimiter + pivotCell.formattedText)
3930
+ === pivotCell.valueSort.levelName && ((pivotCell.axis === 'column' && this.dataSourceSettings.columns.length === 0 && this.dataSourceSettings.valueAxis === 'column') || (pivotCell.axis === 'row' &&
3931
+ this.dataSourceSettings.rows.length === 0 && this.dataSourceSettings.valueAxis === 'row'))) {
3932
+ return this.localeObj.getConstant('total') + ' ' + this.localeObj.getConstant(this.engineModule.fieldList[pivotCell.actualText].aggregateType) + ' ' +
3933
+ this.localeObj.getConstant('of') + ' ' + pivotCell.formattedText;
3934
+ }
3935
+ else if (type === 'grandTotal' && values.length === 1 && this.dataSourceSettings.valueAxis === 'row' && pivotCell.formattedText === this.localeObj.getConstant('grandTotal')) {
3936
+ return this.localeObj.getConstant('total') + ' ' + this.localeObj.getConstant(values[values.length - 1].type) + ' ' +
3937
+ this.localeObj.getConstant('of') + ' ' + (!isNullOrUndefined(values[values.length - 1].caption) ? values[values.length - 1].caption
3938
+ : values[values.length - 1].name);
3939
+ }
3940
+ return pivotCell.formattedText;
3941
+ };
3918
3942
  __decorate([
3919
3943
  Property('USD')
3920
3944
  ], PivotView.prototype, "currencyCode", void 0);
@@ -111,6 +111,7 @@ export declare class Render {
111
111
  getFormatList(): {
112
112
  [key: string]: string;
113
113
  };
114
+ private getValidHeader;
114
115
  private excelColumnEvent;
115
116
  private pdfColumnEvent;
116
117
  private excelRowEvent;
@@ -1003,6 +1003,8 @@ var Render = /** @class */ (function () {
1003
1003
  if (tCell && (this.parent.notEmpty) && this.engine.headerContent) {
1004
1004
  var customClass = this.parent.hyperlinkSettings.cssClass;
1005
1005
  var cell = args.data[0];
1006
+ var isRowFieldsAvail = cell.valueSort && cell.valueSort.levelName === (this.parent.dataSourceSettings.rows.length === 0 && this.parent.dataSourceSettings.valueAxis === 'row' &&
1007
+ this.parent.localeObj.getConstant('grandTotal') + (this.parent.dataSourceSettings.valueSortSettings.headerDelimiter) + (cell.formattedText));
1006
1008
  tCell.setAttribute('index', cell.rowIndex ? cell.rowIndex.toString() : '0');
1007
1009
  if (tCell.getAttribute('aria-colindex') === '0') {
1008
1010
  if (this.parent.dataType === 'pivot') {
@@ -1057,11 +1059,17 @@ var Render = /** @class */ (function () {
1057
1059
  if (cell.type === 'grand sum') {
1058
1060
  this.rowGrandPos = cell.rowIndex;
1059
1061
  tCell.classList.add('e-gtot');
1060
- localizedText = isNullOrUndefined(cell.valueSort.axis) ? this.parent.localeObj.getConstant('grandTotal') : cell.formattedText;
1062
+ var values = this.parent.dataSourceSettings.values;
1063
+ localizedText = isNullOrUndefined(cell.valueSort.axis) ? (this.parent.dataSourceSettings.rows.length === 0 && values.length === 1 && this.parent.dataSourceSettings.valueAxis === 'row') ?
1064
+ this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(values[values.length - 1].type) + ' ' +
1065
+ this.parent.localeObj.getConstant('of') + ' ' + (!isNullOrUndefined(values[values.length - 1].caption) ? values[values.length - 1].caption : values[values.length - 1].name) :
1066
+ this.parent.localeObj.getConstant('grandTotal') : cell.formattedText;
1061
1067
  }
1062
1068
  else if (cell.valueSort.levelName === (this.parent.localeObj.getConstant('grandTotal') +
1063
1069
  (this.parent.dataSourceSettings.valueSortSettings.headerDelimiter) + (cell.formattedText))) {
1064
1070
  tCell.classList.add('e-gtot');
1071
+ localizedText = isRowFieldsAvail ? this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(this.parent.engineModule.fieldList[cell.actualText].aggregateType) + ' '
1072
+ + this.parent.localeObj.getConstant('of') + ' ' + cell.formattedText : localizedText;
1065
1073
  }
1066
1074
  else {
1067
1075
  tCell.classList.add('e-stot');
@@ -1083,8 +1091,9 @@ var Render = /** @class */ (function () {
1083
1091
  }));
1084
1092
  var vSort = this.parent.pivotView.dataSourceSettings.valueSortSettings;
1085
1093
  if (this.parent.enableValueSorting) {
1086
- if (vSort && vSort.headerText && this.parent.dataSourceSettings.valueAxis === 'row'
1087
- && this.parent.pivotValues[Number(tCell.getAttribute('index'))][0].valueSort.levelName) {
1094
+ if (vSort && vSort.headerText && this.parent.dataSourceSettings.valueAxis === 'row' &&
1095
+ this.parent.pivotValues[Number(tCell.getAttribute('index'))][0] &&
1096
+ this.parent.pivotValues[Number(tCell.getAttribute('index'))][0].valueSort.levelName) {
1088
1097
  if (this.parent.pivotValues[Number(tCell.getAttribute('index'))][0].valueSort.levelName
1089
1098
  === vSort.headerText) {
1090
1099
  var style = (tCell.querySelector('.e-expand') || tCell.querySelector('.e-collapse')) ?
@@ -1105,6 +1114,7 @@ var Render = /** @class */ (function () {
1105
1114
  tCell.classList.add(cls.VALUESCONTENT);
1106
1115
  cell = args.data[Number(tCell.getAttribute('aria-colindex'))];
1107
1116
  cell = isNullOrUndefined(cell) ? args.column.customAttributes.cell : cell;
1117
+ cell.isGrandSum = isRowFieldsAvail ? true : cell.isGrandSum;
1108
1118
  if (cell.isSum) {
1109
1119
  tCell.classList.add(cls.SUMMARY);
1110
1120
  }
@@ -1315,16 +1325,20 @@ var Render = /** @class */ (function () {
1315
1325
  else {
1316
1326
  tCell = this.onOlapColumnCellBoundEvent(tCell, cell);
1317
1327
  }
1318
- if (cell.type) {
1328
+ var isColumnFieldsAvail = (this.parent.dataSourceSettings.columns.length === 0 && this.parent.dataSourceSettings.valueAxis === 'column' && cell.valueSort &&
1329
+ cell.valueSort.levelName === (this.parent.localeObj.getConstant('grandTotal') + (this.parent.dataSourceSettings.valueSortSettings.headerDelimiter) + (cell.formattedText)));
1330
+ if (cell.type || isColumnFieldsAvail) {
1319
1331
  tCell.classList.add(cell.type === 'grand sum' ? 'e-gtot' : 'e-stot');
1320
1332
  if (cell.type === 'grand sum') {
1321
1333
  this.colGrandPos = cell.colIndex;
1322
1334
  }
1323
- else {
1335
+ else if (cell.type) {
1324
1336
  tCell.classList.add('e-colstot');
1325
1337
  }
1326
1338
  var localizedText = cell.type === 'grand sum' ? (isNullOrUndefined(cell.valueSort.axis) ? this.parent.localeObj.getConstant('grandTotal') : cell.formattedText) :
1327
1339
  cell.formattedText.split('Total')[0] + this.parent.localeObj.getConstant('total');
1340
+ localizedText = isColumnFieldsAvail ? this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(this.parent.engineModule.fieldList[cell.actualText].aggregateType)
1341
+ + ' ' + this.parent.localeObj.getConstant('of') + ' ' + cell.formattedText : localizedText;
1328
1342
  if (tCell.querySelector('.e-headertext') !== null) {
1329
1343
  tCell.querySelector('.e-headertext').innerText = localizedText;
1330
1344
  }
@@ -1763,8 +1777,39 @@ var Render = /** @class */ (function () {
1763
1777
  }
1764
1778
  return formatArray;
1765
1779
  };
1780
+ Render.prototype.getValidHeader = function (args, axis) {
1781
+ var values = this.parent.dataSourceSettings.values;
1782
+ if (axis === 'row') {
1783
+ var cellInfo = args;
1784
+ if (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) {
1785
+ if (this.parent.dataSourceSettings.rows.length === 0 && this.parent.dataSourceSettings.valueAxis === 'row' && (this.parent.localeObj.getConstant('grandTotal') +
1786
+ this.parent.dataSourceSettings.valueSortSettings.headerDelimiter + cellInfo.value) === cellInfo.data[0].valueSort.levelName) {
1787
+ return this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(this.parent.engineModule.fieldList[cellInfo.value.toString()].aggregateType)
1788
+ + ' ' + this.parent.localeObj.getConstant('of') + ' ' + cellInfo.value.toString();
1789
+ }
1790
+ else if (values.length === 1) {
1791
+ return this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(values[values.length - 1].type)
1792
+ + ' ' + this.parent.localeObj.getConstant('of') + ' ' + (!isNullOrUndefined(values[values.length - 1].caption) ? values[values.length - 1].caption : values[values.length - 1].name);
1793
+ }
1794
+ }
1795
+ return cellInfo.value;
1796
+ }
1797
+ else if (axis === 'column') {
1798
+ var cellInfo = args;
1799
+ if (this.parent.dataSourceSettings.rows.length === 0 || this.parent.dataSourceSettings.columns.length === 0) {
1800
+ if (!isNullOrUndefined(args.gridCell.column.customAttributes) && this.parent.dataSourceSettings.columns.length === 0 && this.parent.dataSourceSettings.valueAxis === 'column' &&
1801
+ (this.parent.localeObj.getConstant('grandTotal') + this.parent.dataSourceSettings.valueSortSettings.headerDelimiter + cellInfo.gridCell.column.customAttributes.cell.formattedText)
1802
+ === cellInfo.gridCell.column.customAttributes.cell.valueSort.levelName) {
1803
+ return this.parent.localeObj.getConstant('total') + ' ' + this.parent.localeObj.getConstant(this.parent.engineModule.fieldList[cellInfo
1804
+ .gridCell.column.customAttributes.cell.actualText].aggregateType) + ' ' + this.parent.localeObj.getConstant('of') + ' ' + cellInfo.gridCell.column.customAttributes.cell.formattedText;
1805
+ }
1806
+ }
1807
+ return (cellInfo.cell).value;
1808
+ }
1809
+ };
1766
1810
  /* eslint-disable */
1767
1811
  Render.prototype.excelColumnEvent = function (args) {
1812
+ (args.cell).value = this.getValidHeader(args, 'column');
1768
1813
  if (args.gridCell !== undefined && args.gridCell.column.width === 'auto') {
1769
1814
  this.parent.lastColumn = args.gridCell.column;
1770
1815
  args.gridCell.column.width = args.gridCell.column.minWidth;
@@ -1773,6 +1818,7 @@ var Render = /** @class */ (function () {
1773
1818
  this.parent.trigger(events.excelHeaderQueryCellInfo, args);
1774
1819
  };
1775
1820
  Render.prototype.pdfColumnEvent = function (args) {
1821
+ (args.cell).value = this.getValidHeader(args, 'column');
1776
1822
  if (args.gridCell !== undefined && args.gridCell.column.width === 'auto') {
1777
1823
  this.parent.lastColumn = args.gridCell.column;
1778
1824
  args.gridCell.column.width = args.gridCell.column.minWidth;
@@ -1813,6 +1859,7 @@ var Render = /** @class */ (function () {
1813
1859
  }
1814
1860
  }
1815
1861
  args = this.exportContentEvent(args);
1862
+ args.value = args.column.field === '0.formattedText' ? this.getValidHeader(args, 'row') : args.value;
1816
1863
  this.parent.trigger(events.excelQueryCellInfo, args);
1817
1864
  };
1818
1865
  /* eslint-disable @typescript-eslint/no-explicit-any */
@@ -1836,6 +1883,7 @@ var Render = /** @class */ (function () {
1836
1883
  }
1837
1884
  args.style = { paragraphIndent: level * 10 };
1838
1885
  this.lastSpan = isValueCell ? this.lastSpan : level;
1886
+ args.value = this.getValidHeader(args, 'row');
1839
1887
  }
1840
1888
  this.parent.trigger(events.pdfQueryCellInfo, args);
1841
1889
  };