@visactor/vtable 1.14.4-alpha.3 → 1.14.4-alpha.5

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 (163) hide show
  1. package/cjs/ListTable.d.ts +5 -1
  2. package/cjs/ListTable.js +15 -4
  3. package/cjs/ListTable.js.map +1 -1
  4. package/cjs/PivotTable.d.ts +4 -0
  5. package/cjs/PivotTable.js +17 -7
  6. package/cjs/PivotTable.js.map +1 -1
  7. package/cjs/components/empty-tip/empty-tip.js +4 -2
  8. package/cjs/components/empty-tip/empty-tip.js.map +1 -1
  9. package/cjs/core/BaseTable.d.ts +4 -0
  10. package/cjs/core/BaseTable.js +51 -21
  11. package/cjs/core/BaseTable.js.map +1 -1
  12. package/cjs/core/tableHelper.d.ts +1 -0
  13. package/cjs/core/tableHelper.js +13 -2
  14. package/cjs/core/tableHelper.js.map +1 -1
  15. package/cjs/core/utils/get-custom-merge-cell-func.d.ts +2 -0
  16. package/cjs/core/utils/get-custom-merge-cell-func.js +14 -0
  17. package/cjs/core/utils/get-custom-merge-cell-func.js.map +1 -0
  18. package/cjs/data/DataSource.d.ts +2 -2
  19. package/cjs/data/DataSource.js +11 -11
  20. package/cjs/data/DataSource.js.map +1 -1
  21. package/cjs/dataset/dataset-pivot-table.d.ts +1 -1
  22. package/cjs/dataset/dataset-pivot-table.js +11 -11
  23. package/cjs/dataset/dataset-pivot-table.js.map +1 -1
  24. package/cjs/dataset/dataset.d.ts +1 -15
  25. package/cjs/dataset/dataset.js +78 -75
  26. package/cjs/dataset/dataset.js.map +1 -1
  27. package/cjs/event/list-table/checkbox.js +15 -3
  28. package/cjs/event/list-table/checkbox.js.map +1 -1
  29. package/cjs/event/listener/table-group.js.map +1 -1
  30. package/cjs/header-helper/style.js +2 -1
  31. package/cjs/index.d.ts +2 -1
  32. package/cjs/index.js +13 -4
  33. package/cjs/index.js.map +1 -1
  34. package/cjs/layout/index.js +1 -2
  35. package/cjs/layout/pivot-header-layout.js +3 -1
  36. package/cjs/layout/pivot-header-layout.js.map +1 -1
  37. package/cjs/layout/simple-header-layout.d.ts +5 -1
  38. package/cjs/layout/simple-header-layout.js +15 -1
  39. package/cjs/layout/simple-header-layout.js.map +1 -1
  40. package/cjs/plugins/chartModules.js +1 -1
  41. package/cjs/register.d.ts +8 -0
  42. package/cjs/register.js +9 -4
  43. package/cjs/register.js.map +1 -1
  44. package/cjs/scenegraph/graphic/icon.js +1 -1
  45. package/cjs/scenegraph/graphic/icon.js.map +1 -1
  46. package/cjs/scenegraph/group-creater/progress/create-group-for-first-screen.js +1 -1
  47. package/cjs/scenegraph/group-creater/progress/create-group-for-first-screen.js.map +1 -1
  48. package/cjs/scenegraph/group-creater/progress/proxy.js.map +1 -1
  49. package/cjs/scenegraph/layout/compute-col-width.js +1 -0
  50. package/cjs/scenegraph/layout/compute-col-width.js.map +1 -1
  51. package/cjs/scenegraph/layout/frozen-react.js +9 -4
  52. package/cjs/scenegraph/layout/frozen-react.js.map +1 -1
  53. package/cjs/state/checkbox/checkbox.js +1 -1
  54. package/cjs/state/checkbox/checkbox.js.map +1 -1
  55. package/cjs/state/state.d.ts +1 -1
  56. package/cjs/state/state.js +10 -8
  57. package/cjs/state/state.js.map +1 -1
  58. package/cjs/ts-types/base-table.d.ts +22 -6
  59. package/cjs/ts-types/base-table.js.map +1 -1
  60. package/cjs/ts-types/component/empty-tip.d.ts +1 -0
  61. package/cjs/ts-types/component/empty-tip.js.map +1 -1
  62. package/cjs/{dataset/statistics-helper.d.ts → ts-types/dataset/aggregation.d.ts} +24 -10
  63. package/cjs/{dataset/statistics-helper.js → ts-types/dataset/aggregation.js} +49 -49
  64. package/cjs/ts-types/dataset/aggregation.js.map +1 -0
  65. package/cjs/ts-types/dataset/index.d.ts +1 -0
  66. package/cjs/ts-types/dataset/index.js +21 -0
  67. package/cjs/ts-types/dataset/index.js.map +1 -0
  68. package/cjs/ts-types/index.d.ts +1 -0
  69. package/cjs/ts-types/index.js +1 -1
  70. package/cjs/ts-types/index.js.map +1 -1
  71. package/cjs/ts-types/list-table/define/basic-define.d.ts +1 -0
  72. package/cjs/ts-types/list-table/define/basic-define.js.map +1 -1
  73. package/cjs/ts-types/list-table/layout-map/api.d.ts +1 -1
  74. package/cjs/ts-types/list-table/layout-map/api.js.map +1 -1
  75. package/cjs/ts-types/new-data-set.d.ts +3 -2
  76. package/cjs/ts-types/new-data-set.js.map +1 -1
  77. package/cjs/ts-types/table-engine.d.ts +21 -2
  78. package/cjs/ts-types/table-engine.js.map +1 -1
  79. package/cjs/vrender.js.map +1 -1
  80. package/dist/vtable.js +4661 -4414
  81. package/dist/vtable.min.js +2 -2
  82. package/es/ListTable.d.ts +5 -1
  83. package/es/ListTable.js +16 -4
  84. package/es/ListTable.js.map +1 -1
  85. package/es/PivotTable.d.ts +4 -0
  86. package/es/PivotTable.js +17 -7
  87. package/es/PivotTable.js.map +1 -1
  88. package/es/components/empty-tip/empty-tip.js +4 -3
  89. package/es/components/empty-tip/empty-tip.js.map +1 -1
  90. package/es/core/BaseTable.d.ts +4 -0
  91. package/es/core/BaseTable.js +55 -21
  92. package/es/core/BaseTable.js.map +1 -1
  93. package/es/core/tableHelper.d.ts +1 -0
  94. package/es/core/tableHelper.js +10 -0
  95. package/es/core/tableHelper.js.map +1 -1
  96. package/es/core/utils/get-custom-merge-cell-func.d.ts +2 -0
  97. package/es/core/utils/get-custom-merge-cell-func.js +6 -0
  98. package/es/core/utils/get-custom-merge-cell-func.js.map +1 -0
  99. package/es/data/DataSource.d.ts +2 -2
  100. package/es/data/DataSource.js +3 -3
  101. package/es/data/DataSource.js.map +1 -1
  102. package/es/dataset/dataset-pivot-table.d.ts +1 -1
  103. package/es/dataset/dataset-pivot-table.js +2 -2
  104. package/es/dataset/dataset-pivot-table.js.map +1 -1
  105. package/es/dataset/dataset.d.ts +1 -15
  106. package/es/dataset/dataset.js +68 -65
  107. package/es/dataset/dataset.js.map +1 -1
  108. package/es/event/list-table/checkbox.js +15 -2
  109. package/es/event/list-table/checkbox.js.map +1 -1
  110. package/es/event/listener/table-group.js.map +1 -1
  111. package/es/header-helper/style.js +2 -1
  112. package/es/index.d.ts +2 -1
  113. package/es/index.js +3 -1
  114. package/es/index.js.map +1 -1
  115. package/es/layout/index.js +1 -2
  116. package/es/layout/pivot-header-layout.js +1 -1
  117. package/es/layout/pivot-header-layout.js.map +1 -1
  118. package/es/layout/simple-header-layout.d.ts +5 -1
  119. package/es/layout/simple-header-layout.js +15 -1
  120. package/es/layout/simple-header-layout.js.map +1 -1
  121. package/es/plugins/chartModules.js +1 -1
  122. package/es/register.d.ts +8 -0
  123. package/es/register.js +8 -1
  124. package/es/register.js.map +1 -1
  125. package/es/scenegraph/graphic/icon.js +1 -1
  126. package/es/scenegraph/graphic/icon.js.map +1 -1
  127. package/es/scenegraph/group-creater/progress/create-group-for-first-screen.js +1 -1
  128. package/es/scenegraph/group-creater/progress/create-group-for-first-screen.js.map +1 -1
  129. package/es/scenegraph/group-creater/progress/proxy.js.map +1 -1
  130. package/es/scenegraph/layout/compute-col-width.js +1 -0
  131. package/es/scenegraph/layout/compute-col-width.js.map +1 -1
  132. package/es/scenegraph/layout/frozen-react.js +9 -4
  133. package/es/scenegraph/layout/frozen-react.js.map +1 -1
  134. package/es/state/checkbox/checkbox.js +1 -1
  135. package/es/state/checkbox/checkbox.js.map +1 -1
  136. package/es/state/state.d.ts +1 -1
  137. package/es/state/state.js +10 -8
  138. package/es/state/state.js.map +1 -1
  139. package/es/ts-types/base-table.d.ts +22 -6
  140. package/es/ts-types/base-table.js.map +1 -1
  141. package/es/ts-types/component/empty-tip.d.ts +1 -0
  142. package/es/ts-types/component/empty-tip.js.map +1 -1
  143. package/es/{dataset/statistics-helper.d.ts → ts-types/dataset/aggregation.d.ts} +24 -10
  144. package/es/{dataset/statistics-helper.js → ts-types/dataset/aggregation.js} +31 -31
  145. package/es/ts-types/dataset/aggregation.js.map +1 -0
  146. package/es/ts-types/dataset/index.d.ts +1 -0
  147. package/es/ts-types/dataset/index.js +2 -0
  148. package/es/ts-types/dataset/index.js.map +1 -0
  149. package/es/ts-types/index.d.ts +1 -0
  150. package/es/ts-types/index.js +2 -0
  151. package/es/ts-types/index.js.map +1 -1
  152. package/es/ts-types/list-table/define/basic-define.d.ts +1 -0
  153. package/es/ts-types/list-table/define/basic-define.js.map +1 -1
  154. package/es/ts-types/list-table/layout-map/api.d.ts +1 -1
  155. package/es/ts-types/list-table/layout-map/api.js.map +1 -1
  156. package/es/ts-types/new-data-set.d.ts +3 -2
  157. package/es/ts-types/new-data-set.js.map +1 -1
  158. package/es/ts-types/table-engine.d.ts +21 -2
  159. package/es/ts-types/table-engine.js.map +1 -1
  160. package/es/vrender.js.map +1 -1
  161. package/package.json +7 -7
  162. package/cjs/dataset/statistics-helper.js.map +0 -1
  163. package/es/dataset/statistics-helper.js.map +0 -1
@@ -2,7 +2,7 @@ import { isValid } from "@visactor/vutils";
2
2
 
3
3
  import { AggregationType } from "../ts-types";
4
4
 
5
- import { AvgAggregator, CountAggregator, MaxAggregator, MinAggregator, NoneAggregator, RecalculateAggregator, RecordAggregator, SumAggregator, naturalSort, sortBy, typeSort } from "./statistics-helper";
5
+ import { registeredAggregators, AvgAggregator, CountAggregator, CustomAggregator, MaxAggregator, MinAggregator, NoneAggregator, RecalculateAggregator, RecordAggregator, SumAggregator, naturalSort, sortBy, typeSort } from "../ts-types/dataset/aggregation";
6
6
 
7
7
  import { IndicatorDimensionKeyPlaceholder } from "../tools/global";
8
8
 
@@ -14,10 +14,9 @@ export class Dataset {
14
14
  this.tree = {}, this.changedTree = {}, this.colFlatKeys = {}, this.rowFlatKeys = {},
15
15
  this.colKeys = [], this.rowKeys = [], this.colKeys_normal = [], this.rowKeys_normal = [],
16
16
  this.rowOrder = "key_a_to_z", this.colOrder = "key_a_to_z", this.sorted = !1, this.indicatorStatistics = [],
17
- this.aggregators = {}, this.stringJoinChar = String.fromCharCode(0), this.rowsIsTotal = [],
18
- this.colsIsTotal = [], this.collectedValues = {}, this.cacheCollectedValues = {},
19
- this.totalRecordsTree = {}, this.registerAggregators(), this.dataConfig = dataConfig,
20
- this.filterRules = null === (_a = this.dataConfig) || void 0 === _a ? void 0 : _a.filterRules,
17
+ this.stringJoinChar = String.fromCharCode(0), this.rowsIsTotal = [], this.colsIsTotal = [],
18
+ this.collectedValues = {}, this.cacheCollectedValues = {}, this.totalRecordsTree = {},
19
+ this.registerAggregators(), this.dataConfig = dataConfig, this.filterRules = null === (_a = this.dataConfig) || void 0 === _a ? void 0 : _a.filterRules,
21
20
  this.rowHierarchyType = null != rowHierarchyType ? rowHierarchyType : "grid", this.sortRules = null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.sortRules,
22
21
  this.aggregationRules = null === (_c = this.dataConfig) || void 0 === _c ? void 0 : _c.aggregationRules,
23
22
  this.derivedFieldRules = null === (_d = this.dataConfig) || void 0 === _d ? void 0 : _d.derivedFieldRules,
@@ -57,7 +56,7 @@ export class Dataset {
57
56
  if (this.records = records, this.collectedValues = {}, this.cacheCollectedValues = {},
58
57
  this.totalRecordsTree = {}, this.tree = {}, this.colFlatKeys = {}, this.rowFlatKeys = {},
59
58
  this.colKeys = [], this.rowKeys = [], this.rowsHasValue = [], this.columnsHasValue = [],
60
- records) {
59
+ this.sorted = !1, records) {
61
60
  this.records = records;
62
61
  "undefined" != typeof window && window.performance.now();
63
62
  this.processRecords(), this.processCollectedValuesWithSumBy(), this.generateCollectedValuesSortRule(),
@@ -76,13 +75,14 @@ export class Dataset {
76
75
  }
77
76
  }
78
77
  registerAggregator(type, aggregator) {
79
- this.aggregators[type] = aggregator;
78
+ registeredAggregators[type] = aggregator;
80
79
  }
81
80
  registerAggregators() {
82
81
  this.registerAggregator(AggregationType.RECORD, RecordAggregator), this.registerAggregator(AggregationType.SUM, SumAggregator),
83
82
  this.registerAggregator(AggregationType.COUNT, CountAggregator), this.registerAggregator(AggregationType.MAX, MaxAggregator),
84
83
  this.registerAggregator(AggregationType.MIN, MinAggregator), this.registerAggregator(AggregationType.AVG, AvgAggregator),
85
- this.registerAggregator(AggregationType.NONE, NoneAggregator), this.registerAggregator(AggregationType.RECALCULATE, RecalculateAggregator);
84
+ this.registerAggregator(AggregationType.NONE, NoneAggregator), this.registerAggregator(AggregationType.RECALCULATE, RecalculateAggregator),
85
+ this.registerAggregator(AggregationType.CUSTOM, CustomAggregator);
86
86
  }
87
87
  processCollectedValuesWithSumBy() {
88
88
  var _a, _b, _c, _d, _e, _f;
@@ -156,7 +156,7 @@ export class Dataset {
156
156
  return isReserved;
157
157
  }
158
158
  processRecord(record, assignedIndicatorKey) {
159
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40;
159
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41;
160
160
  null === (_a = this.derivedFieldRules) || void 0 === _a || _a.forEach(((derivedFieldRule, i) => {
161
161
  derivedFieldRule.fieldName && derivedFieldRule.derivedFunc && (record[derivedFieldRule.fieldName] = derivedFieldRule.derivedFunc(record));
162
162
  }));
@@ -167,10 +167,10 @@ export class Dataset {
167
167
  min: Number.MAX_SAFE_INTEGER,
168
168
  max: Number.MIN_SAFE_INTEGER
169
169
  } : this.collectedValues[field][collectKeys] = []), this.collectValuesBy[field].sumBy) {
170
- const sumByKeys = this.collectValuesBy[field].sumBy.map((byField => record[byField])).join(this.stringJoinChar);
171
- this.collectedValues[field][collectKeys][sumByKeys] || (this.collectedValues[field][collectKeys][sumByKeys] = new this.aggregators[AggregationType.SUM]({
170
+ const sumByKeys = null === (_b = this.collectValuesBy[field].sumBy) || void 0 === _b ? void 0 : _b.map((byField => record[byField])).join(this.stringJoinChar);
171
+ this.collectedValues[field][collectKeys][sumByKeys] || (this.collectedValues[field][collectKeys][sumByKeys] = new registeredAggregators[AggregationType.SUM]({
172
172
  key: field,
173
- dimension: field,
173
+ field: field,
174
174
  isRecord: void 0,
175
175
  needSplitPositiveAndNegative: this.needSplitPositiveAndNegative
176
176
  })), this.collectedValues[field][collectKeys][sumByKeys].push(record);
@@ -184,7 +184,7 @@ export class Dataset {
184
184
  }
185
185
  let isToTalRecord = !1;
186
186
  const colKeys = [], rowKeys = [];
187
- if (!this.parseCustomTreeToMatchRecords || (null === (_b = this.dataConfig) || void 0 === _b ? void 0 : _b.isPivotChart) || !(null === (_c = this.customRowTree) || void 0 === _c ? void 0 : _c.length) || assignedIndicatorKey || this.hasExtensionRowTree) {
187
+ if (!this.parseCustomTreeToMatchRecords || (null === (_c = this.dataConfig) || void 0 === _c ? void 0 : _c.isPivotChart) || !(null === (_d = this.customRowTree) || void 0 === _d ? void 0 : _d.length) || assignedIndicatorKey || this.hasExtensionRowTree) {
188
188
  const rowKey = [];
189
189
  rowKeys.push({
190
190
  rowKey: rowKey,
@@ -193,11 +193,11 @@ export class Dataset {
193
193
  for (let l = 0, len1 = this.rows.length; l < len1; l++) {
194
194
  const rowAttr = this.rows[l];
195
195
  if (rowAttr in record) this.rowsHasValue[l] = !0, rowKey.push(record[rowAttr]); else if (rowAttr !== IndicatorDimensionKeyPlaceholder) {
196
- if ((null === (_f = null === (_e = null === (_d = this.dataConfig) || void 0 === _d ? void 0 : _d.totals) || void 0 === _e ? void 0 : _e.row) || void 0 === _f ? void 0 : _f.showGrandTotals) && 0 === l && !this.rows.find((rk => rk in record))) {
196
+ if ((null === (_g = null === (_f = null === (_e = this.dataConfig) || void 0 === _e ? void 0 : _e.totals) || void 0 === _f ? void 0 : _f.row) || void 0 === _g ? void 0 : _g.showGrandTotals) && 0 === l && !this.rows.find((rk => rk in record))) {
197
197
  rowKey.push(this.rowGrandTotalLabel), isToTalRecord = !0;
198
198
  break;
199
199
  }
200
- if ((null === (_j = null === (_h = null === (_g = this.dataConfig) || void 0 === _g ? void 0 : _g.totals) || void 0 === _h ? void 0 : _h.row) || void 0 === _j ? void 0 : _j.subTotalsDimensions) && (null === (_m = null === (_l = null === (_k = this.dataConfig) || void 0 === _k ? void 0 : _k.totals) || void 0 === _l ? void 0 : _l.row) || void 0 === _m ? void 0 : _m.subTotalsDimensions.indexOf(this.rows[l - 1])) >= 0) {
200
+ if ((null === (_k = null === (_j = null === (_h = this.dataConfig) || void 0 === _h ? void 0 : _h.totals) || void 0 === _j ? void 0 : _j.row) || void 0 === _k ? void 0 : _k.subTotalsDimensions) && (null === (_o = null === (_m = null === (_l = this.dataConfig) || void 0 === _l ? void 0 : _l.totals) || void 0 === _m ? void 0 : _m.row) || void 0 === _o ? void 0 : _o.subTotalsDimensions.indexOf(this.rows[l - 1])) >= 0) {
201
201
  "grid" === this.rowHierarchyType && rowKey.push(this.rowSubTotalLabel), isToTalRecord = !0;
202
202
  break;
203
203
  }
@@ -215,7 +215,7 @@ export class Dataset {
215
215
  });
216
216
  }
217
217
  }
218
- if (!this.parseCustomTreeToMatchRecords || (null === (_o = this.dataConfig) || void 0 === _o ? void 0 : _o.isPivotChart) || !(null === (_p = this.customColTree) || void 0 === _p ? void 0 : _p.length) || assignedIndicatorKey || this.hasExtensionRowTree) {
218
+ if (!this.parseCustomTreeToMatchRecords || (null === (_p = this.dataConfig) || void 0 === _p ? void 0 : _p.isPivotChart) || !(null === (_q = this.customColTree) || void 0 === _q ? void 0 : _q.length) || assignedIndicatorKey || this.hasExtensionRowTree) {
219
219
  const colKey = [];
220
220
  colKeys.push({
221
221
  colKey: colKey,
@@ -224,11 +224,11 @@ export class Dataset {
224
224
  for (let n = 0, len2 = this.columns.length; n < len2; n++) {
225
225
  const colAttr = this.columns[n];
226
226
  if (colAttr in record) this.columnsHasValue[n] = !0, colKey.push(record[colAttr]); else if (colAttr !== IndicatorDimensionKeyPlaceholder) {
227
- if ((null === (_s = null === (_r = null === (_q = this.dataConfig) || void 0 === _q ? void 0 : _q.totals) || void 0 === _r ? void 0 : _r.column) || void 0 === _s ? void 0 : _s.showGrandTotals) && 0 === n && !this.columns.find((ck => ck in record))) {
227
+ if ((null === (_t = null === (_s = null === (_r = this.dataConfig) || void 0 === _r ? void 0 : _r.totals) || void 0 === _s ? void 0 : _s.column) || void 0 === _t ? void 0 : _t.showGrandTotals) && 0 === n && !this.columns.find((ck => ck in record))) {
228
228
  colKey.push(this.colGrandTotalLabel), isToTalRecord = !0;
229
229
  break;
230
230
  }
231
- if ((null === (_v = null === (_u = null === (_t = this.dataConfig) || void 0 === _t ? void 0 : _t.totals) || void 0 === _u ? void 0 : _u.column) || void 0 === _v ? void 0 : _v.subTotalsDimensions) && (null === (_y = null === (_x = null === (_w = this.dataConfig) || void 0 === _w ? void 0 : _w.totals) || void 0 === _x ? void 0 : _x.column) || void 0 === _y ? void 0 : _y.subTotalsDimensions.indexOf(this.columns[n - 1])) >= 0) {
231
+ if ((null === (_w = null === (_v = null === (_u = this.dataConfig) || void 0 === _u ? void 0 : _u.totals) || void 0 === _v ? void 0 : _v.column) || void 0 === _w ? void 0 : _w.subTotalsDimensions) && (null === (_z = null === (_y = null === (_x = this.dataConfig) || void 0 === _x ? void 0 : _x.totals) || void 0 === _y ? void 0 : _y.column) || void 0 === _z ? void 0 : _z.subTotalsDimensions.indexOf(this.columns[n - 1])) >= 0) {
232
232
  colKey.push(this.colSubTotalLabel), isToTalRecord = !0;
233
233
  break;
234
234
  }
@@ -258,75 +258,78 @@ export class Dataset {
258
258
  this.totalRecordsTree[flatRowKey] || (this.totalRecordsTree[flatRowKey] = {}), this.totalRecordsTree[flatRowKey][flatColKey] || (this.totalRecordsTree[flatRowKey][flatColKey] = []);
259
259
  const toComputeIndicatorKeys = this.indicatorKeysIncludeCalculatedFieldDependIndicatorKeys;
260
260
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
261
- const calculatedFieldRule = null === (_z = this.calculatedFieldRules) || void 0 === _z ? void 0 : _z.find((rule => rule.key === toComputeIndicatorKeys[i]));
262
- (null === (_1 = null === (_0 = this.totalRecordsTree[flatRowKey]) || void 0 === _0 ? void 0 : _0[flatColKey]) || void 0 === _1 ? void 0 : _1[i]) || (this.totalRecordsTree[flatRowKey][flatColKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
261
+ const calculatedFieldRule = null === (_0 = this.calculatedFieldRules) || void 0 === _0 ? void 0 : _0.find((rule => rule.key === toComputeIndicatorKeys[i]));
262
+ (null === (_2 = null === (_1 = this.totalRecordsTree[flatRowKey]) || void 0 === _1 ? void 0 : _1[flatColKey]) || void 0 === _2 ? void 0 : _2[i]) || (this.totalRecordsTree[flatRowKey][flatColKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
263
263
  key: toComputeIndicatorKeys[i],
264
- dimension: toComputeIndicatorKeys[i],
264
+ field: toComputeIndicatorKeys[i],
265
265
  isRecord: !0,
266
- formatFun: null === (_3 = null === (_2 = this.indicators) || void 0 === _2 ? void 0 : _2.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _3 ? void 0 : _3.format,
266
+ formatFun: null === (_4 = null === (_3 = this.indicators) || void 0 === _3 ? void 0 : _3.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _4 ? void 0 : _4.format,
267
267
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
268
268
  dependAggregators: this.totalRecordsTree[flatRowKey][flatColKey],
269
269
  dependIndicatorKeys: null == calculatedFieldRule ? void 0 : calculatedFieldRule.dependIndicatorKeys
270
- })), toComputeIndicatorKeys[i] in record && (null === (_5 = null === (_4 = this.totalRecordsTree[flatRowKey]) || void 0 === _4 ? void 0 : _4[flatColKey]) || void 0 === _5 || _5[i].push(record));
270
+ })), toComputeIndicatorKeys[i] in record && (null === (_6 = null === (_5 = this.totalRecordsTree[flatRowKey]) || void 0 === _5 ? void 0 : _5[flatColKey]) || void 0 === _6 || _6[i].push(record));
271
271
  } else {
272
272
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
273
- (null === (_7 = null === (_6 = this.totalRecordsTree[flatRowKey]) || void 0 === _6 ? void 0 : _6[flatColKey]) || void 0 === _7 ? void 0 : _7[i]) || (this.totalRecordsTree[flatRowKey][flatColKey][i] = new this.aggregators[null !== (_8 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _8 ? _8 : AggregationType.SUM]({
273
+ (null === (_8 = null === (_7 = this.totalRecordsTree[flatRowKey]) || void 0 === _7 ? void 0 : _7[flatColKey]) || void 0 === _8 ? void 0 : _8[i]) || (this.totalRecordsTree[flatRowKey][flatColKey][i] = new registeredAggregators[null !== (_9 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _9 ? _9 : AggregationType.SUM]({
274
274
  key: toComputeIndicatorKeys[i],
275
- dimension: null !== (_9 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _9 ? _9 : toComputeIndicatorKeys[i],
276
- formatFun: null !== (_10 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _10 ? _10 : null === (_12 = null === (_11 = this.indicators) || void 0 === _11 ? void 0 : _11.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _12 ? void 0 : _12.format
277
- })), toComputeIndicatorKeys[i] in record && (null === (_14 = null === (_13 = this.totalRecordsTree[flatRowKey]) || void 0 === _13 ? void 0 : _13[flatColKey]) || void 0 === _14 || _14[i].push(record));
275
+ field: null !== (_10 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _10 ? _10 : toComputeIndicatorKeys[i],
276
+ aggregationFun: null == aggRule ? void 0 : aggRule.aggregationFun,
277
+ formatFun: null !== (_11 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _11 ? _11 : null === (_13 = null === (_12 = this.indicators) || void 0 === _12 ? void 0 : _12.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _13 ? void 0 : _13.format
278
+ })), toComputeIndicatorKeys[i] in record && (null === (_15 = null === (_14 = this.totalRecordsTree[flatRowKey]) || void 0 === _14 ? void 0 : _14[flatColKey]) || void 0 === _15 || _15[i].push(record));
278
279
  }
279
280
  return;
280
281
  }
281
282
  0 !== rowKey.length && (this.rowFlatKeys[flatRowKey] || (this.rowKeys.push(rowKey),
282
283
  this.rowFlatKeys[flatRowKey] = 1)), 0 !== colKey.length && (this.colFlatKeys[flatColKey] || (this.colKeys.push(colKey),
283
284
  this.colFlatKeys[flatColKey] = 1)), this.tree[flatRowKey] || (this.tree[flatRowKey] = {}),
284
- (null === (_15 = this.tree[flatRowKey]) || void 0 === _15 ? void 0 : _15[flatColKey]) || (this.tree[flatRowKey][flatColKey] = []);
285
+ (null === (_16 = this.tree[flatRowKey]) || void 0 === _16 ? void 0 : _16[flatColKey]) || (this.tree[flatRowKey][flatColKey] = []);
285
286
  const toComputeIndicatorKeys = this.indicatorKeysIncludeCalculatedFieldDependIndicatorKeys;
286
287
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
287
- const calculatedFieldRule = null === (_16 = this.calculatedFieldRules) || void 0 === _16 ? void 0 : _16.find((rule => rule.key === toComputeIndicatorKeys[i]));
288
- (null === (_18 = null === (_17 = this.tree[flatRowKey]) || void 0 === _17 ? void 0 : _17[flatColKey]) || void 0 === _18 ? void 0 : _18[i]) || (this.tree[flatRowKey][flatColKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
288
+ const calculatedFieldRule = null === (_17 = this.calculatedFieldRules) || void 0 === _17 ? void 0 : _17.find((rule => rule.key === toComputeIndicatorKeys[i]));
289
+ (null === (_19 = null === (_18 = this.tree[flatRowKey]) || void 0 === _18 ? void 0 : _18[flatColKey]) || void 0 === _19 ? void 0 : _19[i]) || (this.tree[flatRowKey][flatColKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
289
290
  key: toComputeIndicatorKeys[i],
290
- dimension: toComputeIndicatorKeys[i],
291
+ field: toComputeIndicatorKeys[i],
291
292
  isRecord: !0,
292
- formatFun: null === (_20 = null === (_19 = this.indicators) || void 0 === _19 ? void 0 : _19.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _20 ? void 0 : _20.format,
293
+ formatFun: null === (_21 = null === (_20 = this.indicators) || void 0 === _20 ? void 0 : _20.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _21 ? void 0 : _21.format,
293
294
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
294
295
  dependAggregators: this.tree[flatRowKey][flatColKey],
295
296
  dependIndicatorKeys: null == calculatedFieldRule ? void 0 : calculatedFieldRule.dependIndicatorKeys
296
- })), null === (_22 = null === (_21 = this.tree[flatRowKey]) || void 0 === _21 ? void 0 : _21[flatColKey]) || void 0 === _22 || _22[i].push(record);
297
+ })), null === (_23 = null === (_22 = this.tree[flatRowKey]) || void 0 === _22 ? void 0 : _22[flatColKey]) || void 0 === _23 || _23[i].push(record);
297
298
  } else {
298
299
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
299
300
  let needAddToAggregator = !1;
300
301
  if (assignedIndicatorKey_value) assignedIndicatorKey === assignedIndicatorKey_value ? toComputeIndicatorKeys[i] === assignedIndicatorKey_value && (needAddToAggregator = !0) : toComputeIndicatorKeys[i] === assignedIndicatorKey_value && toComputeIndicatorKeys[i] in record && (needAddToAggregator = !0); else if (null == aggRule ? void 0 : aggRule.field) if ("string" == typeof (null == aggRule ? void 0 : aggRule.field)) (null == aggRule ? void 0 : aggRule.field) in record && (needAddToAggregator = !0); else {
301
302
  (null == aggRule ? void 0 : aggRule.field.find((field => field in record))) && (needAddToAggregator = !0);
302
303
  } else toComputeIndicatorKeys[i] in record && (needAddToAggregator = !0);
303
- !(null === (_24 = null === (_23 = this.tree[flatRowKey]) || void 0 === _23 ? void 0 : _23[flatColKey]) || void 0 === _24 ? void 0 : _24[i]) && needAddToAggregator && (this.tree[flatRowKey][flatColKey][i] = new this.aggregators[null !== (_25 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _25 ? _25 : AggregationType.SUM]({
304
+ !(null === (_25 = null === (_24 = this.tree[flatRowKey]) || void 0 === _24 ? void 0 : _24[flatColKey]) || void 0 === _25 ? void 0 : _25[i]) && needAddToAggregator && (this.tree[flatRowKey][flatColKey][i] = new registeredAggregators[null !== (_26 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _26 ? _26 : AggregationType.SUM]({
304
305
  key: toComputeIndicatorKeys[i],
305
- dimension: null !== (_26 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _26 ? _26 : toComputeIndicatorKeys[i],
306
- formatFun: null !== (_27 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _27 ? _27 : null === (_29 = null === (_28 = this.indicators) || void 0 === _28 ? void 0 : _28.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _29 ? void 0 : _29.format
307
- })), needAddToAggregator && (null === (_31 = null === (_30 = this.tree[flatRowKey]) || void 0 === _30 ? void 0 : _30[flatColKey]) || void 0 === _31 || _31[i].push(record));
306
+ field: null !== (_27 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _27 ? _27 : toComputeIndicatorKeys[i],
307
+ aggregationFun: null == aggRule ? void 0 : aggRule.aggregationFun,
308
+ formatFun: null !== (_28 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _28 ? _28 : null === (_30 = null === (_29 = this.indicators) || void 0 === _29 ? void 0 : _29.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _30 ? void 0 : _30.format
309
+ })), needAddToAggregator && (null === (_32 = null === (_31 = this.tree[flatRowKey]) || void 0 === _31 ? void 0 : _31[flatColKey]) || void 0 === _32 || _32[i].push(record));
308
310
  }
309
311
  if (this.mappingRules) for (let i = 0; i < this.indicatorKeys.length; i++) {
310
312
  if (!this.indicatorStatistics[i]) {
311
313
  const aggRule = this.getAggregatorRule(this.indicatorKeys[i]);
312
314
  this.indicatorStatistics[i] = {
313
- max: new this.aggregators[AggregationType.MAX]({
315
+ max: new registeredAggregators[AggregationType.MAX]({
314
316
  key: this.indicatorKeys[i],
315
- dimension: this.indicatorKeys[i]
317
+ field: this.indicatorKeys[i]
316
318
  }),
317
- min: new this.aggregators[AggregationType.MIN]({
319
+ min: new registeredAggregators[AggregationType.MIN]({
318
320
  key: this.indicatorKeys[i],
319
- dimension: this.indicatorKeys[i]
321
+ field: this.indicatorKeys[i]
320
322
  }),
321
- total: new this.aggregators[null !== (_32 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _32 ? _32 : AggregationType.SUM]({
323
+ total: new registeredAggregators[null !== (_33 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _33 ? _33 : AggregationType.SUM]({
322
324
  key: this.indicatorKeys[i],
323
- dimension: null !== (_33 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _33 ? _33 : this.indicatorKeys[i],
324
- formatFun: null !== (_34 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _34 ? _34 : null === (_36 = null === (_35 = this.indicators) || void 0 === _35 ? void 0 : _35.find((indicator => "string" != typeof indicator && indicator.indicatorKey === this.indicatorKeys[i]))) || void 0 === _36 ? void 0 : _36.format
325
+ field: null !== (_34 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _34 ? _34 : this.indicatorKeys[i],
326
+ aggregationFun: null == aggRule ? void 0 : aggRule.aggregationFun,
327
+ formatFun: null !== (_35 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _35 ? _35 : null === (_37 = null === (_36 = this.indicators) || void 0 === _36 ? void 0 : _36.find((indicator => "string" != typeof indicator && indicator.indicatorKey === this.indicatorKeys[i]))) || void 0 === _37 ? void 0 : _37.format
325
328
  })
326
329
  };
327
330
  }
328
- this.indicatorStatistics[i].max.push(null === (_38 = null === (_37 = this.tree[flatRowKey]) || void 0 === _37 ? void 0 : _37[flatColKey]) || void 0 === _38 ? void 0 : _38[i].value()),
329
- this.indicatorStatistics[i].min.push(null === (_40 = null === (_39 = this.tree[flatRowKey]) || void 0 === _39 ? void 0 : _39[flatColKey]) || void 0 === _40 ? void 0 : _40[i].value()),
331
+ this.indicatorStatistics[i].max.push(null === (_39 = null === (_38 = this.tree[flatRowKey]) || void 0 === _38 ? void 0 : _38[flatColKey]) || void 0 === _39 ? void 0 : _39[i].value()),
332
+ this.indicatorStatistics[i].min.push(null === (_41 = null === (_40 = this.tree[flatRowKey]) || void 0 === _40 ? void 0 : _40[flatColKey]) || void 0 === _41 ? void 0 : _41[i].value()),
330
333
  this.indicatorStatistics[i].total.push(record);
331
334
  }
332
335
  }
@@ -364,7 +367,6 @@ export class Dataset {
364
367
  formatValue: agg.formatValue,
365
368
  formatFun: agg.formatFun,
366
369
  records: agg.records,
367
- className: "",
368
370
  recalculate() {},
369
371
  push() {},
370
372
  deleteRecord() {},
@@ -372,8 +374,8 @@ export class Dataset {
372
374
  clearCacheValue() {},
373
375
  reset() {}
374
376
  } : {
377
+ records: [],
375
378
  value: () => changeValue,
376
- className: "",
377
379
  push() {},
378
380
  deleteRecord() {},
379
381
  updateRecord() {},
@@ -384,7 +386,7 @@ export class Dataset {
384
386
  };
385
387
  }
386
388
  return agg || {
387
- className: "",
389
+ records: [],
388
390
  push() {},
389
391
  deleteRecord() {},
390
392
  updateRecord() {},
@@ -464,9 +466,9 @@ export class Dataset {
464
466
  const toComputeIndicatorKeys = this.indicatorKeysIncludeCalculatedFieldDependIndicatorKeys;
465
467
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
466
468
  const calculatedFieldRule = null === (_s = this.calculatedFieldRules) || void 0 === _s ? void 0 : _s.find((rule => rule.key === toComputeIndicatorKeys[i]));
467
- (null === (_u = null === (_t = this.tree[flatRowKey]) || void 0 === _t ? void 0 : _t[flatColTotalKey]) || void 0 === _u ? void 0 : _u[i]) || (this.tree[flatRowKey][flatColTotalKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
469
+ (null === (_u = null === (_t = this.tree[flatRowKey]) || void 0 === _t ? void 0 : _t[flatColTotalKey]) || void 0 === _u ? void 0 : _u[i]) || (this.tree[flatRowKey][flatColTotalKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
468
470
  key: toComputeIndicatorKeys[i],
469
- dimension: toComputeIndicatorKeys[i],
471
+ field: toComputeIndicatorKeys[i],
470
472
  isRecord: !0,
471
473
  formatFun: null === (_w = null === (_v = this.indicators) || void 0 === _v ? void 0 : _v.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _w ? void 0 : _w.format,
472
474
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
@@ -476,9 +478,10 @@ export class Dataset {
476
478
  } else {
477
479
  if (!this.tree[flatRowKey][flatColTotalKey][i]) {
478
480
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
479
- this.tree[flatRowKey][flatColTotalKey][i] = new this.aggregators[null !== (_z = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _z ? _z : AggregationType.SUM]({
481
+ this.tree[flatRowKey][flatColTotalKey][i] = new registeredAggregators[null !== (_z = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _z ? _z : AggregationType.SUM]({
480
482
  key: toComputeIndicatorKeys[i],
481
- dimension: null !== (_0 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _0 ? _0 : toComputeIndicatorKeys[i],
483
+ field: null !== (_0 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _0 ? _0 : toComputeIndicatorKeys[i],
484
+ aggregationFun: null == aggRule ? void 0 : aggRule.aggregationFun,
482
485
  formatFun: null !== (_1 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _1 ? _1 : null === (_3 = null === (_2 = this.indicators) || void 0 === _2 ? void 0 : _2.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _3 ? void 0 : _3.format
483
486
  });
484
487
  }
@@ -493,9 +496,9 @@ export class Dataset {
493
496
  const toComputeIndicatorKeys = this.indicatorKeysIncludeCalculatedFieldDependIndicatorKeys;
494
497
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
495
498
  const calculatedFieldRule = null === (_12 = this.calculatedFieldRules) || void 0 === _12 ? void 0 : _12.find((rule => rule.key === toComputeIndicatorKeys[i]));
496
- (null === (_14 = null === (_13 = this.tree[flatRowKey]) || void 0 === _13 ? void 0 : _13[flatColTotalKey]) || void 0 === _14 ? void 0 : _14[i]) || (this.tree[flatRowKey][flatColTotalKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
499
+ (null === (_14 = null === (_13 = this.tree[flatRowKey]) || void 0 === _13 ? void 0 : _13[flatColTotalKey]) || void 0 === _14 ? void 0 : _14[i]) || (this.tree[flatRowKey][flatColTotalKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
497
500
  key: toComputeIndicatorKeys[i],
498
- dimension: toComputeIndicatorKeys[i],
501
+ field: toComputeIndicatorKeys[i],
499
502
  isRecord: !0,
500
503
  formatFun: null === (_16 = null === (_15 = this.indicators) || void 0 === _15 ? void 0 : _15.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _16 ? void 0 : _16.format,
501
504
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
@@ -505,9 +508,9 @@ export class Dataset {
505
508
  } else {
506
509
  if (!this.tree[flatRowKey][flatColTotalKey][i]) {
507
510
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
508
- this.tree[flatRowKey][flatColTotalKey][i] = new this.aggregators[null !== (_19 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _19 ? _19 : AggregationType.SUM]({
511
+ this.tree[flatRowKey][flatColTotalKey][i] = new registeredAggregators[null !== (_19 = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _19 ? _19 : AggregationType.SUM]({
509
512
  key: toComputeIndicatorKeys[i],
510
- dimension: null !== (_20 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _20 ? _20 : toComputeIndicatorKeys[i],
513
+ field: null !== (_20 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _20 ? _20 : toComputeIndicatorKeys[i],
511
514
  formatFun: null !== (_21 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _21 ? _21 : null === (_23 = null === (_22 = this.indicators) || void 0 === _22 ? void 0 : _22.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _23 ? void 0 : _23.format
512
515
  });
513
516
  }
@@ -533,9 +536,9 @@ export class Dataset {
533
536
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) {
534
537
  if (!this.tree[flatRowTotalKey][flatColKey][i]) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
535
538
  const calculatedFieldRule = null === (_j = this.calculatedFieldRules) || void 0 === _j ? void 0 : _j.find((rule => rule.key === toComputeIndicatorKeys[i]));
536
- this.tree[flatRowTotalKey][flatColKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
539
+ this.tree[flatRowTotalKey][flatColKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
537
540
  key: toComputeIndicatorKeys[i],
538
- dimension: toComputeIndicatorKeys[i],
541
+ field: toComputeIndicatorKeys[i],
539
542
  isRecord: !0,
540
543
  formatFun: null === (_l = null === (_k = this.indicators) || void 0 === _k ? void 0 : _k.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _l ? void 0 : _l.format,
541
544
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
@@ -544,9 +547,9 @@ export class Dataset {
544
547
  });
545
548
  } else {
546
549
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
547
- this.tree[flatRowTotalKey][flatColKey][i] = new this.aggregators[null !== (_m = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _m ? _m : AggregationType.SUM]({
550
+ this.tree[flatRowTotalKey][flatColKey][i] = new registeredAggregators[null !== (_m = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _m ? _m : AggregationType.SUM]({
548
551
  key: toComputeIndicatorKeys[i],
549
- dimension: null !== (_o = null == aggRule ? void 0 : aggRule.field) && void 0 !== _o ? _o : toComputeIndicatorKeys[i],
552
+ field: null !== (_o = null == aggRule ? void 0 : aggRule.field) && void 0 !== _o ? _o : toComputeIndicatorKeys[i],
550
553
  formatFun: null !== (_p = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _p ? _p : null === (_r = null === (_q = this.indicators) || void 0 === _q ? void 0 : _q.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _r ? void 0 : _r.format
551
554
  });
552
555
  }
@@ -562,9 +565,9 @@ export class Dataset {
562
565
  for (let i = 0; i < toComputeIndicatorKeys.length; i++) {
563
566
  if (!this.tree[flatRowTotalKey][flatColKey][i]) if (this.calculatedFiledKeys.indexOf(toComputeIndicatorKeys[i]) >= 0) {
564
567
  const calculatedFieldRule = null === (_w = this.calculatedFieldRules) || void 0 === _w ? void 0 : _w.find((rule => rule.key === toComputeIndicatorKeys[i]));
565
- this.tree[flatRowTotalKey][flatColKey][i] = new this.aggregators[AggregationType.RECALCULATE]({
568
+ this.tree[flatRowTotalKey][flatColKey][i] = new registeredAggregators[AggregationType.RECALCULATE]({
566
569
  key: toComputeIndicatorKeys[i],
567
- dimension: toComputeIndicatorKeys[i],
570
+ field: toComputeIndicatorKeys[i],
568
571
  isRecord: !0,
569
572
  formatFun: null === (_y = null === (_x = this.indicators) || void 0 === _x ? void 0 : _x.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _y ? void 0 : _y.format,
570
573
  calculateFun: null == calculatedFieldRule ? void 0 : calculatedFieldRule.calculateFun,
@@ -573,9 +576,9 @@ export class Dataset {
573
576
  });
574
577
  } else {
575
578
  const aggRule = this.getAggregatorRule(toComputeIndicatorKeys[i]);
576
- this.tree[flatRowTotalKey][flatColKey][i] = new this.aggregators[null !== (_z = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _z ? _z : AggregationType.SUM]({
579
+ this.tree[flatRowTotalKey][flatColKey][i] = new registeredAggregators[null !== (_z = null == aggRule ? void 0 : aggRule.aggregationType) && void 0 !== _z ? _z : AggregationType.SUM]({
577
580
  key: toComputeIndicatorKeys[i],
578
- dimension: null !== (_0 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _0 ? _0 : toComputeIndicatorKeys[i],
581
+ field: null !== (_0 = null == aggRule ? void 0 : aggRule.field) && void 0 !== _0 ? _0 : toComputeIndicatorKeys[i],
579
582
  formatFun: null !== (_1 = null == aggRule ? void 0 : aggRule.formatFun) && void 0 !== _1 ? _1 : null === (_3 = null === (_2 = this.indicators) || void 0 === _2 ? void 0 : _2.find((indicator => "string" != typeof indicator && indicator.indicatorKey === toComputeIndicatorKeys[i]))) || void 0 === _3 ? void 0 : _3.format
580
583
  });
581
584
  }