super-page-runtime 2.3.5-rc1 → 2.3.5-sit2

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 (31) hide show
  1. package/dist/es/components/runtime/utils/api/page-expose-util.js +50 -50
  2. package/dist/es/components/runtime/utils/events/event-util.js +3 -3
  3. package/dist/es/components/runtime/utils/events/print-label.js +25 -26
  4. package/dist/es/components/runtime/utils/events/standard-event.js +18 -18
  5. package/dist/es/components/runtime/utils/events/validator-util.js +1 -1
  6. package/dist/es/components/runtime/utils/page-init-util.js +24 -25
  7. package/dist/es/components/runtime/utils/page-store.js +10 -10
  8. package/dist/es/components/runtime/utils/table-utils.js +1 -1
  9. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +6 -10
  10. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +6 -8
  11. package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue2.js +17 -17
  12. package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +7 -12
  13. package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +128 -129
  14. package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +9 -11
  15. package/dist/es/components/runtime/views/assemblys/container/fixed/YxAffix.vue2.js +0 -2
  16. package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +10 -12
  17. package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +9 -10
  18. package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +43 -52
  19. package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +15 -15
  20. package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +4 -4
  21. package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +32 -32
  22. package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +1 -1
  23. package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +45 -46
  24. package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +3 -5
  25. package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +0 -1
  26. package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +0 -1
  27. package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +60 -51
  28. package/dist/es/components/runtime/views/home-chart.vue.js +7 -7
  29. package/dist/es/components/runtime/views/super-page-dialog.vue.js +0 -1
  30. package/dist/es/components/runtime/views/super-page.vue2.js +11 -12
  31. package/package.json +2 -2
@@ -3,13 +3,12 @@ import { Search as p } from "@element-plus/icons-vue";
3
3
  import g from "./common-chart-header-group.vue.js";
4
4
  import m from "./common-chart-header-breadcrumb.vue.js";
5
5
  import b from "./common-homepage-search.vue.js";
6
- import { setVariableValueWithProp as v, getValueFromSource as y, setValueForVariableName as O } from "../../../../utils/page-helper-util.js";
7
- const w = { class: "amb-widget-chart-header" }, x = { class: "amb-widget-chart-header-item" }, k = { class: "amb-widget-chart-header-item amb-widget-chart-header-center" }, j = { class: "amb-widget-chart-header-item" }, C = { key: 0, class: "amb-widget-chart-header-item" }, P = e({ __name: "common-chart-header", props: { headerInfo: { type: Object, required: true }, configure: { type: Object, required: true }, pageContext: { type: Object, required: true } }, emits: ["drill-end"], setup(e2, { expose: P2, emit: _ }) {
6
+ import { setVariableValueWithProp as v, getValueFromSource as y, setValueForVariableName as w } from "../../../../utils/page-helper-util.js";
7
+ const x = { class: "amb-widget-chart-header" }, O = { class: "amb-widget-chart-header-item" }, k = { class: "amb-widget-chart-header-item amb-widget-chart-header-center" }, j = { class: "amb-widget-chart-header-item" }, C = { key: 0, class: "amb-widget-chart-header-item" }, P = e({ __name: "common-chart-header", props: { headerInfo: { type: Object, required: true }, configure: { type: Object, required: true }, pageContext: { type: Object, required: true } }, emits: ["drill-end"], setup(e2, { expose: P2, emit: _ }) {
8
8
  const N = e2, D = o(null), A = o(), R = _;
9
9
  function S(e3) {
10
10
  const o2 = N.headerInfo.drillOptions.length;
11
- if (e3 >= o2) N.headerInfo.drillOptions;
12
- else {
11
+ if (!(e3 >= o2)) {
13
12
  for (let r2 = o2 - 1; r2 >= e3; r2--) N.headerInfo.drillOptions.splice(r2, 1);
14
13
  q(e3);
15
14
  }
@@ -35,7 +34,7 @@ const w = { class: "amb-widget-chart-header" }, x = { class: "amb-widget-chart-h
35
34
  for (let e4 of o2.variables) {
36
35
  if (!e4.fieldName || !e4.variable) continue;
37
36
  const o3 = y(r2, e4.fieldName, void 0);
38
- O(N.pageContext.entity, e4.variable, o3);
37
+ w(N.pageContext.entity, e4.variable, o3);
39
38
  }
40
39
  }
41
40
  N.headerInfo.drillOptions || (N.headerInfo.drillOptions = []);
@@ -47,12 +46,11 @@ const w = { class: "amb-widget-chart-header" }, x = { class: "amb-widget-chart-h
47
46
  if (r2 + 1 >= N.headerInfo.options.length) {
48
47
  return F(o2 && e3.dataIndex < o2.length ? o2[e3.dataIndex] : void 0), void R("drill-end", e3);
49
48
  }
50
- N.headerInfo.options;
51
49
  const n2 = N.headerInfo.options[r2], t2 = o2 && e3.dataIndex < o2.length ? o2[e3.dataIndex] : null, a2 = { fieldName: n2.target ? n2.target.replace(".", "_") : "", rawFieldName: n2.target ? n2.target : "", label: e3.name, value: e3.name, data: t2 };
52
50
  N.headerInfo.drillOptions.push(a2), q(r2 + 1);
53
51
  }, closeDrill: S }), (o2, v2) => {
54
- const y2 = r("el-icon"), O2 = r("el-tooltip");
55
- return t(), n("div", w, [a("div", x, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && (!e2.headerInfo.textAlign || "left" == e2.headerInfo.textAlign)]]), !e2.headerInfo.showDrill || e2.headerInfo.groupPosition && "left" != e2.headerInfo.groupPosition ? l("", true) : (t(), d(m, { key: 0, ref_key: "drillObjRef", ref: D, headerInfo: e2.headerInfo, onCloseDrill: S }, null, 8, ["headerInfo"])), !e2.headerInfo.showGroup || e2.headerInfo.groupPosition && "left" != e2.headerInfo.groupPosition ? l("", true) : (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"]))]), a("div", k, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && "center" == e2.headerInfo.textAlign]]), e2.headerInfo.showDrill && "center" == e2.headerInfo.groupPosition ? (t(), d(m, { key: 0, headerInfo: e2.headerInfo, onCloseDrill: S, ref_key: "drillObjRef", ref: D }, null, 8, ["headerInfo"])) : l("", true), e2.headerInfo.showGroup && "center" == e2.headerInfo.groupPosition ? (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"])) : l("", true)]), a("div", j, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && "right" == e2.headerInfo.textAlign]]), e2.headerInfo.showDrill && "right" == e2.headerInfo.groupPosition ? (t(), d(m, { key: 0, headerInfo: e2.headerInfo, onCloseDrill: S, ref_key: "drillObjRef", ref: D }, null, 8, ["headerInfo"])) : l("", true), e2.headerInfo.showGroup && "right" == e2.headerInfo.groupPosition ? (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"])) : l("", true)]), e2.pageContext.showHomepageSearch ? (t(), n("div", C, [c(O2, { content: "打开查询弹窗", effect: "light" }, { default: I(() => [c(y2, { onClick: G }, { default: I(() => [c(u(p))]), _: 1 })]), _: 1 }), c(b, { ref_key: "commonHomepageSearchRef", ref: A, configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["configure", "pageContext"])])) : l("", true)]);
52
+ const y2 = r("el-icon"), w2 = r("el-tooltip");
53
+ return t(), n("div", x, [a("div", O, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && (!e2.headerInfo.textAlign || "left" == e2.headerInfo.textAlign)]]), !e2.headerInfo.showDrill || e2.headerInfo.groupPosition && "left" != e2.headerInfo.groupPosition ? l("", true) : (t(), d(m, { key: 0, ref_key: "drillObjRef", ref: D, headerInfo: e2.headerInfo, onCloseDrill: S }, null, 8, ["headerInfo"])), !e2.headerInfo.showGroup || e2.headerInfo.groupPosition && "left" != e2.headerInfo.groupPosition ? l("", true) : (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"]))]), a("div", k, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && "center" == e2.headerInfo.textAlign]]), e2.headerInfo.showDrill && "center" == e2.headerInfo.groupPosition ? (t(), d(m, { key: 0, headerInfo: e2.headerInfo, onCloseDrill: S, ref_key: "drillObjRef", ref: D }, null, 8, ["headerInfo"])) : l("", true), e2.headerInfo.showGroup && "center" == e2.headerInfo.groupPosition ? (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"])) : l("", true)]), a("div", j, [i(a("label", { style: f(e2.headerInfo.style) }, h(e2.headerInfo.title) + "  ", 5), [[s, e2.headerInfo.title && "right" == e2.headerInfo.textAlign]]), e2.headerInfo.showDrill && "right" == e2.headerInfo.groupPosition ? (t(), d(m, { key: 0, headerInfo: e2.headerInfo, onCloseDrill: S, ref_key: "drillObjRef", ref: D }, null, 8, ["headerInfo"])) : l("", true), e2.headerInfo.showGroup && "right" == e2.headerInfo.groupPosition ? (t(), d(g, { key: 1, headerInfo: e2.headerInfo }, null, 8, ["headerInfo"])) : l("", true)]), e2.pageContext.showHomepageSearch ? (t(), n("div", C, [c(w2, { content: "打开查询弹窗", effect: "light" }, { default: I(() => [c(y2, { onClick: G }, { default: I(() => [c(u(p))]), _: 1 })]), _: 1 }), c(b, { ref_key: "commonHomepageSearchRef", ref: A, configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["configure", "pageContext"])])) : l("", true)]);
56
54
  };
57
55
  } });
58
56
  export {
@@ -14,50 +14,50 @@ import "vue-i18n";
14
14
  import "agilebuilder-ui/src/utils/auth";
15
15
  import "axios";
16
16
  import "../../../../utils/events/print-label.js";
17
- const _ = { style: { overflow: "auto", height: "calc(100vh - 140px)" }, ref: "dialogBody" }, b = { class: "dialog-footer" }, O = e({ __name: "common-homepage-search", props: { configure: { type: Object, required: true }, pageContext: { type: Object, default: () => {
18
- } } }, setup(e2, { expose: O2 }) {
19
- const x = e2, N = t(false), J = t({}), j = t(0);
17
+ const b = { style: { overflow: "auto", height: "calc(100vh - 140px)" }, ref: "dialogBody" }, O = { class: "dialog-footer" }, x = e({ __name: "common-homepage-search", props: { configure: { type: Object, required: true }, pageContext: { type: Object, default: () => {
18
+ } } }, setup(e2, { expose: x2 }) {
19
+ const N = e2, _ = t(false), J = t({}), j = t(0);
20
20
  let I;
21
21
  o(() => {
22
22
  I = setTimeout(() => {
23
- J.value = JSON.parse(JSON.stringify(x.pageContext.entity));
23
+ J.value = JSON.parse(JSON.stringify(N.pageContext.entity));
24
24
  }, 200);
25
25
  }), i(() => {
26
26
  I && clearTimeout(I);
27
27
  });
28
28
  const k = t([]), w = () => {
29
- N.value = false;
29
+ _.value = false;
30
30
  }, T = () => {
31
31
  const e3 = y.service({ lock: true, text: "Loading", background: "rgba(0, 0, 0, 0.7)" });
32
- v(x.pageContext, x.pageContext.initChartServiceConfigs, null, false).then(() => {
33
- N.value = false;
32
+ v(N.pageContext, N.pageContext.initChartServiceConfigs, null, false).then(() => {
33
+ _.value = false;
34
34
  }).finally(() => {
35
- N.value = false, e3.close();
35
+ _.value = false, e3.close();
36
36
  });
37
37
  };
38
38
  function H() {
39
- x.pageContext.entity = JSON.parse(JSON.stringify(J.value)), j.value++;
39
+ N.pageContext.entity = JSON.parse(JSON.stringify(J.value)), j.value++;
40
40
  }
41
41
  function A() {
42
42
  const e3 = {};
43
- x.pageContext.variables.forEach((t3) => {
43
+ N.pageContext.variables.forEach((t3) => {
44
44
  const o3 = "${page." + t3.name + "}";
45
- e3[o3] = h(x.pageContext.entity, o3, null);
45
+ e3[o3] = h(N.pageContext.entity, o3, null);
46
46
  });
47
47
  let t2 = window.localStorage.getItem("HOME_MY_CHARTS_CONDITIONS"), o2 = {};
48
- t2 && (o2 = JSON.parse(t2)), o2[x.configure.homeChartSettingUserId] = e3;
48
+ t2 && (o2 = JSON.parse(t2)), o2[N.configure.homeChartSettingUserId] = e3;
49
49
  const i2 = JSON.stringify(e3);
50
- window.localStorage.setItem("HOME_MY_CHARTS_CONDITIONS", JSON.stringify(o2)), J.value = JSON.parse(JSON.stringify(x.pageContext.entity)), S.post(window.$vueApp.config.globalProperties.baseAPI + "/component/home-chart-settings/search-conditions", { id: x.configure.homeChartSettingUserId, searchConditionsJson: i2 }).then((e4) => {
50
+ window.localStorage.setItem("HOME_MY_CHARTS_CONDITIONS", JSON.stringify(o2)), J.value = JSON.parse(JSON.stringify(N.pageContext.entity)), S.post(window.$vueApp.config.globalProperties.baseAPI + "/component/home-chart-settings/search-conditions", { id: N.configure.homeChartSettingUserId, searchConditionsJson: i2 }).then((e4) => {
51
51
  C.success("保存成功"), T();
52
52
  });
53
53
  }
54
- return O2({ openSearch: () => {
55
- N.value = true, k.value = x.configure.pushHomepage.searchConditions;
54
+ return x2({ openSearch: () => {
55
+ _.value = true, k.value = N.configure.pushHomepage.searchConditions;
56
56
  } }), (t2, o2) => {
57
57
  const i2 = l("el-empty"), v2 = l("el-form"), h2 = l("el-button"), y2 = l("el-dialog");
58
- return r(), a(y2, { modelValue: N.value, "onUpdate:modelValue": o2[0] || (o2[0] = (e3) => N.value = e3), title: "筛选", close: w, "append-to-body": "", fullscreen: "", top: "40vh", append: "", width: "70%", draggable: "" }, { default: n(() => [u("div", _, [k.value && 0 !== k.value.length ? c("", true) : (r(), a(i2, { key: 0, description: "未设置筛选条件", "image-size": 50 })), (r(), a(v2, { key: j.value }, { default: n(() => [(r(true), g(m, null, d(k.value, (t3) => (r(), a(f, { key: t3.uuid, configure: t3, pageContext: e2.pageContext }, null, 8, ["configure", "pageContext"]))), 128))]), _: 1 }))], 512)]), footer: n(() => [u("div", b, [s(h2, { type: "primary", onClick: T }, { default: n(() => o2[1] || (o2[1] = [p(" 确定 ", -1)])), _: 1, __: [1] }), s(h2, { type: "default", onClick: H }, { default: n(() => o2[2] || (o2[2] = [p("重置", -1)])), _: 1, __: [2] }), s(h2, { type: "primary", onClick: A }, { default: n(() => o2[3] || (o2[3] = [p(" 保存为默认条件 ", -1)])), _: 1, __: [3] })])]), _: 1 }, 8, ["modelValue"]);
58
+ return r(), a(y2, { modelValue: _.value, "onUpdate:modelValue": o2[0] || (o2[0] = (e3) => _.value = e3), title: "筛选", close: w, "append-to-body": "", fullscreen: "", top: "40vh", append: "", width: "70%", draggable: "" }, { default: n(() => [u("div", b, [k.value && 0 !== k.value.length ? c("", true) : (r(), a(i2, { key: 0, description: "未设置筛选条件", "image-size": 50 })), (r(), a(v2, { key: j.value }, { default: n(() => [(r(true), g(m, null, d(k.value, (t3) => (r(), a(f, { key: t3.uuid, configure: t3, pageContext: e2.pageContext }, null, 8, ["configure", "pageContext"]))), 128))]), _: 1 }))], 512)]), footer: n(() => [u("div", O, [s(h2, { type: "primary", onClick: T }, { default: n(() => o2[1] || (o2[1] = [p(" 确定 ")])), _: 1 }), s(h2, { type: "default", onClick: H }, { default: n(() => o2[2] || (o2[2] = [p("重置")])), _: 1 }), s(h2, { type: "primary", onClick: A }, { default: n(() => o2[3] || (o2[3] = [p(" 保存为默认条件 ")])), _: 1 })])]), _: 1 }, 8, ["modelValue"]);
59
59
  };
60
60
  } });
61
61
  export {
62
- O as default
62
+ x as default
63
63
  };
@@ -74,7 +74,7 @@ class ExpressionEvaluator {
74
74
  try {
75
75
  return eval(expression);
76
76
  } catch (e) {
77
- return console.error("表达式错误:", expression, e), false;
77
+ return false;
78
78
  }
79
79
  }
80
80
  }
@@ -115,7 +115,6 @@ function summaryStatistics(e, t, r, o) {
115
115
  const e2 = n2.apply(n2, [{ data: t, prop: r }]);
116
116
  a = e2 ? ` ${e2}` : " N/A";
117
117
  } catch (e2) {
118
- console.error("自定义函数脚本错误:", t, e2);
119
118
  }
120
119
  else a = " N/A";
121
120
  } else switch (n) {
@@ -148,8 +147,7 @@ function getHeaderCellStyleUtil(e, t, r) {
148
147
  const a2 = getCustomFunc(r.pageContext, t2.scopeFunc);
149
148
  if (a2) try {
150
149
  false !== a2.apply(a2, [{ item: t2, data: e }]) && copyStyle(o, t2);
151
- } catch (r2) {
152
- console.error("自定义函数脚本错误:", t2, e, r2);
150
+ } catch (e2) {
153
151
  }
154
152
  } else copyStyle(o, t2);
155
153
  }));
@@ -165,8 +163,7 @@ function getRowStyleUtil(e, t, r) {
165
163
  if (t3) try {
166
164
  const r2 = t3.apply(t3, [{ data: e }]);
167
165
  null != r2 && false !== r2 && copyStyle(o, a);
168
- } catch (t4) {
169
- console.error("自定义函数脚本错误:", e, t4);
166
+ } catch (e2) {
170
167
  }
171
168
  } else if (a.matchingCondition) {
172
169
  const t3 = ExpressionEvaluator.evaluate(r.pageContext, a.matchingCondition, e.row);
@@ -190,8 +187,7 @@ function getCellStyleUtil(e, t, r) {
190
187
  const t2 = getCustomFunc(r.pageContext, n.scopeFunc);
191
188
  if (t2) try {
192
189
  false !== t2.apply(t2, [{ data: e }]) && copyStyle(o, n);
193
- } catch (t3) {
194
- console.error("自定义函数脚本错误:", e, t3);
190
+ } catch (e2) {
195
191
  }
196
192
  } else if (n.matchingCondition) {
197
193
  const t2 = ExpressionEvaluator.evaluate(r.pageContext, n.matchingCondition, e.row);
@@ -315,7 +311,7 @@ function computeFormula(itemConfs, datas, entity) {
315
311
  r += Number(e2[t]);
316
312
  });
317
313
  } catch (e2) {
318
- console.error("计算错误:", e2), r = 0;
314
+ r = 0;
319
315
  }
320
316
  totalValueMap[e] = r;
321
317
  } else (e.startsWith("${page.") || e.startsWith("${data.") || e.startsWith("${row.") || e.startsWith("${request.") || e.startsWith("${context.") || e.startsWith("${system.") || e.startsWith("${fixed.")) && (totalValueMap[e] = getValueFromVariable(entity, e, data));
@@ -327,7 +323,7 @@ function computeFormula(itemConfs, datas, entity) {
327
323
  try {
328
324
  data[key] = eval(expr);
329
325
  } catch (e) {
330
- console.error(itemConfs[key] + " 计算错误, 替换后表达式为:" + expr, e), data[key] = 0;
326
+ data[key] = 0;
331
327
  }
332
328
  });
333
329
  });
@@ -367,8 +363,7 @@ function formatCustomFunc(e, t, r, o, a) {
367
363
  if (n) {
368
364
  try {
369
365
  return n.apply(n, [{ pageContext: o, configureObj: a, row: e, prop: r.props.base.prop }]);
370
- } catch (t2) {
371
- console.error("自定义函数脚本错误:", e, t2);
366
+ } catch (e2) {
372
367
  }
373
368
  return "";
374
369
  }
@@ -1,86 +1,86 @@
1
- import { defineComponent as e, ref as o, onMounted as n, watch as r, resolveComponent as t, createElementBlock as i, openBlock as a, normalizeClass as u, normalizeStyle as p, unref as l, withDirectives as s, createVNode as c, createBlock as g, createCommentVNode as f, vShow as m, withCtx as d, Fragment as h, renderList as v, h as y } from "vue";
2
- import C from "../common/common-chart-header.vue.js";
3
- import { getSizeConfig as b, getChartDatasFromPage as x, getValueFromVariable as O, isPromise as S, setValueForVariableName as w, updateChartDatasourcesByComponent as E, caculateShowCondition as j } from "../../../../utils/page-helper-util.js";
4
- import { getCustomFunc as $ } from "../../../../utils/events/event-util.js";
5
- import F from "./group-column.vue.js";
6
- import k from "./normal-column.vue.js";
7
- import I from "./table-pageination.vue.js";
8
- import { getSummaryTitleColumn as N, getSummaryDataColumn as R, rowDataToColumn as T, getColumnToRowTableConfig as H, colDataToRow as _, computeFormula as z, getNewColumnConfig as A, summaryStatistics as D, replacePlaceholders as J, getIndexColumn as P, getHeaderCellStyleUtil as U, getRowStyleUtil as V, getCellStyleUtil as G, formatColContent as K } from "./chart-table-util.js";
9
- import { deepCopy as L } from "../../../../utils/common-util.js";
10
- const q = e({ __name: "table-runtime", props: { configure: { type: Object, default: () => ({}) }, pageContext: { type: Object, default: () => ({}) } }, setup(e2, { expose: q2 }) {
1
+ import { defineComponent as e, ref as o, computed as n, onMounted as r, watch as t, resolveComponent as i, createElementBlock as a, openBlock as u, normalizeClass as p, normalizeStyle as l, unref as s, withDirectives as c, createVNode as g, createBlock as f, createCommentVNode as m, vShow as d, withCtx as h, Fragment as v, renderList as y, h as C } from "vue";
2
+ import b from "../common/common-chart-header.vue.js";
3
+ import { getSizeConfig as x, getChartDatasFromPage as O, getValueFromVariable as S, caculateShowCondition as w, isPromise as E, setValueForVariableName as j, updateChartDatasourcesByComponent as $ } from "../../../../utils/page-helper-util.js";
4
+ import { getCustomFunc as F } from "../../../../utils/events/event-util.js";
5
+ import k from "./group-column.vue.js";
6
+ import I from "./normal-column.vue.js";
7
+ import N from "./table-pageination.vue.js";
8
+ import { getSummaryTitleColumn as R, getSummaryDataColumn as T, rowDataToColumn as H, getColumnToRowTableConfig as _, colDataToRow as z, computeFormula as A, getNewColumnConfig as D, summaryStatistics as J, replacePlaceholders as P, getIndexColumn as U, getHeaderCellStyleUtil as V, getRowStyleUtil as G, getCellStyleUtil as K, formatColContent as L } from "./chart-table-util.js";
9
+ import { deepCopy as q } from "../../../../utils/common-util.js";
10
+ const B = e({ __name: "table-runtime", props: { configure: { type: Object, default: () => ({}) }, pageContext: { type: Object, default: () => ({}) } }, setup(e2, { expose: B2 }) {
11
11
  var _a;
12
- const B = e2, M = B.configure.runtime ? B.configure.runtime : {}, Q = M.style, W = M.class, X = M.dataConfig, Y = M.headerInfo ? M.headerInfo : {}, Z = o(null), ee = o(M.props.isEnableGroupHeader), oe = o([]), ne = o([]), re = o([]), te = o({}), ie = o(false), ae = o({}), ue = o({}), pe = o({}), le = [], se = o({}), ce = o({}), ge = o(null), fe = o(0);
13
- let me = [];
14
- if (!B.configure.props.modelCustom) {
15
- if (ee.value) {
12
+ const M = e2, Q = M.configure.runtime ? M.configure.runtime : {}, W = Q.style, X = Q.class, Y = Q.dataConfig, Z = Q.headerInfo ? Q.headerInfo : {}, ee = o(null), oe = o(Q.props.isEnableGroupHeader), ne = o([]), re = o([]), te = o([]), ie = o({}), ae = o(false), ue = o({}), pe = o({}), le = o({}), se = [], ce = o({}), ge = o({}), fe = o(null), me = n(() => oe.value ? te.value.filter((e3) => !e3.isLeaf || Re(ie[e3.columnUuid])) : re.value.filter((e3) => Re(e3))), de = o(0);
13
+ let he = [];
14
+ if (!M.configure.props.modelCustom) {
15
+ if (oe.value) {
16
16
  const e3 = [];
17
- B.configure.props.groupHeaders.forEach((o2) => {
17
+ M.configure.props.groupHeaders.forEach((o2) => {
18
18
  o2.parentUuid || e3.push(o2);
19
- }), e3.sort((e4, o2) => e4.displayOrder - o2.displayOrder), re.value = e3, function() {
20
- if (B.configure.props.base.showIndex) {
21
- re.value.unshift({ columnUuid: "$index", displayOrder: 0, isLeaf: true, prop: "$index", titleText: "序号", uuid: "$index" });
22
- const e4 = P();
23
- e4 && (te.value.$index = e4);
19
+ }), e3.sort((e4, o2) => e4.displayOrder - o2.displayOrder), te.value = e3, function() {
20
+ if (M.configure.props.base.showIndex) {
21
+ te.value.unshift({ columnUuid: "$index", displayOrder: 0, isLeaf: true, prop: "$index", titleText: "序号", uuid: "$index" });
22
+ const e4 = U();
23
+ e4 && (ie.value.$index = e4);
24
24
  }
25
25
  }();
26
- } else ne.value = B.configure.items;
27
- (_a = B.configure.items) == null ? void 0 : _a.forEach((e3) => {
28
- te.value[e3.uuid] = e3, Object.keys(e3.style).length > 0 && (se.value[e3.props.base.prop] = { cellStyle: e3.style, titleStyle: e3.titleStyle }), e3.formula && "" !== e3.formula.trim() && (ce.value[e3.props.base.prop] = e3.formula);
26
+ } else re.value = M.configure.items;
27
+ (_a = M.configure.items) == null ? void 0 : _a.forEach((e3) => {
28
+ ie.value[e3.uuid] = e3, Object.keys(e3.style).length > 0 && (ce.value[e3.props.base.prop] = { cellStyle: e3.style, titleStyle: e3.titleStyle }), e3.formula && "" !== e3.formula.trim() && (ge.value[e3.props.base.prop] = e3.formula);
29
29
  });
30
30
  }
31
- ie.value = B.configure.props.base.showSummary, (ie.value || B.configure.props.highOrder.groupField && B.configure.props.highOrder.groupField.length > 0) && (ae.value = N(B.configure), ie.value && (ue.value = R(B.configure, "table")), B.configure.props.highOrder.groupField && B.configure.props.highOrder.groupField.length > 0 && (pe.value = R(B.configure, "group")));
32
- let de = 300, he = b(B.pageContext, B.configure);
33
- function ve(e3) {
31
+ ae.value = M.configure.props.base.showSummary, (ae.value || M.configure.props.highOrder.groupField && M.configure.props.highOrder.groupField.length > 0) && (ue.value = R(M.configure), ae.value && (pe.value = T(M.configure, "table")), M.configure.props.highOrder.groupField && M.configure.props.highOrder.groupField.length > 0 && (le.value = T(M.configure, "group")));
32
+ let ve = 300, ye = x(M.pageContext, M.configure);
33
+ function Ce(e3) {
34
34
  e3 || (e3 = []), Array.isArray(e3) && (e3 = e3.length > 0 ? e3[0] : {}), e3 || (e3 = {}), e3.hasRender ? e3.hasRender = true : (!function(e4) {
35
35
  var _a2;
36
- Ne(e4), "service" === B.configure.props.dataOrigin.dataSource && e4.result ? me = e4.result[B.configure.props.dataOrigin.service.serviceDataField] : "variable" === B.configure.props.dataOrigin.dataSource && (me = O(B.pageContext.entity, B.configure.props.dataOrigin.variable));
37
- if (me) if (((_a2 = B.configure.props) == null ? void 0 : _a2.dataOrigin.limitEnable) && B.configure.props.dataOrigin.itemNumSource) {
36
+ Te(e4), "service" === M.configure.props.dataOrigin.dataSource && e4.result ? he = e4.result[M.configure.props.dataOrigin.service.serviceDataField] : "variable" === M.configure.props.dataOrigin.dataSource && (he = S(M.pageContext.entity, M.configure.props.dataOrigin.variable));
37
+ if (he) if (((_a2 = M.configure.props) == null ? void 0 : _a2.dataOrigin.limitEnable) && M.configure.props.dataOrigin.itemNumSource) {
38
38
  let o2 = 10;
39
- if ("fix" === B.configure.props.dataOrigin.itemNumSource) o2 = B.configure.props.dataOrigin.itemNumFix;
40
- else if ("variable" === B.configure.props.dataOrigin.itemNumSource) {
41
- o2 = Number(O(B.pageContext.entity, B.configure.props.dataOrigin.itemNumVariable));
42
- const n2 = B.configure.props.dataOrigin.itemNumVariable.match(/\${(.*?)}/), t2 = n2 ? n2[1].split(".") : [], i2 = JSON.parse(JSON.stringify(me));
43
- r(() => t2.reduce((e5, o3) => e5[o3], B.pageContext.entity), (o3) => {
44
- ye(o3, i2, e4);
39
+ if ("fix" === M.configure.props.dataOrigin.itemNumSource) o2 = M.configure.props.dataOrigin.itemNumFix;
40
+ else if ("variable" === M.configure.props.dataOrigin.itemNumSource) {
41
+ o2 = Number(S(M.pageContext.entity, M.configure.props.dataOrigin.itemNumVariable));
42
+ const n2 = M.configure.props.dataOrigin.itemNumVariable.match(/\${(.*?)}/), r2 = n2 ? n2[1].split(".") : [], i2 = JSON.parse(JSON.stringify(he));
43
+ t(() => r2.reduce((e5, o3) => e5[o3], M.pageContext.entity), (o3) => {
44
+ be(o3, i2, e4);
45
45
  });
46
46
  }
47
- ye(o2, me, e4);
48
- } else Ce(me, e4);
49
- }(e3), e3.hasRender = true, X && (X.autoRefresh = false));
47
+ be(o2, he, e4);
48
+ } else xe(he, e4);
49
+ }(e3), e3.hasRender = true, Y && (Y.autoRefresh = false));
50
50
  }
51
- function ye(e3, o2, n2) {
51
+ function be(e3, o2, n2) {
52
52
  var _a2;
53
53
  if (e3 && e3 < o2.length) {
54
54
  let r2 = [];
55
- if (((_a2 = B.configure.props.dataOrigin.limitCountColumns) == null ? void 0 : _a2.length) > 0) r2 = B.configure.props.dataOrigin.limitCountColumns;
55
+ if (((_a2 = M.configure.props.dataOrigin.limitCountColumns) == null ? void 0 : _a2.length) > 0) r2 = M.configure.props.dataOrigin.limitCountColumns;
56
56
  else {
57
- ne.value.filter((e4) => "number" === e4.props.base.dataType).forEach((e4) => {
57
+ re.value.filter((e4) => "number" === e4.props.base.dataType).forEach((e4) => {
58
58
  r2.push(e4.props.base.prop);
59
59
  });
60
60
  }
61
61
  if ((r2 == null ? void 0 : r2.length) > 0) {
62
62
  const n3 = o2.slice(e3 - 1, o2.length), t2 = {};
63
- let i2 = ne.value[0].props.base.prop;
64
- "$index" === i2 && (i2 = ne.value[1].props.base.prop), n3.forEach((e4) => {
63
+ let i2 = re.value[0].props.base.prop;
64
+ "$index" === i2 && (i2 = re.value[1].props.base.prop), n3.forEach((e4) => {
65
65
  r2.forEach((o3) => {
66
66
  void 0 === t2[o3] && (t2[o3] = 0), t2[o3] = t2[o3] + e4[o3];
67
67
  });
68
- }), o2.length > e3 && (o2 = o2.slice(0, e3 - 1)), t2[i2] = B.configure.props.dataOrigin.overItemAlias, o2.push(t2);
68
+ }), o2.length > e3 && (o2 = o2.slice(0, e3 - 1)), t2[i2] = M.configure.props.dataOrigin.overItemAlias, o2.push(t2);
69
69
  }
70
- Ce(o2, n2);
71
- } else Ce(o2, n2);
70
+ xe(o2, n2);
71
+ } else xe(o2, n2);
72
72
  }
73
- function Ce(e3, o2) {
73
+ function xe(e3, o2) {
74
74
  var _a2;
75
- if (be("rowToColumn")) {
76
- if (e3 = T(e3, B.configure, ne.value), !ee.value) {
75
+ if (Oe("rowToColumn")) {
76
+ if (e3 = H(e3, M.configure, re.value), !oe.value) {
77
77
  const o3 = function(e4, o4, n2) {
78
- const r2 = B.configure.props.dataOrigin.rowToColumn.titleColumns, t2 = B.configure.props.dataOrigin.rowToColumn.dataColumns, i2 = e4.props.dataOrigin.groupField;
78
+ const r2 = M.configure.props.dataOrigin.rowToColumn.titleColumns, t2 = M.configure.props.dataOrigin.rowToColumn.dataColumns, i2 = e4.props.dataOrigin.groupField;
79
79
  if ((!i2 || 0 === i2.length) && n2.length > 0) {
80
80
  const e5 = [];
81
- return e5.push(A("$GroupColumn", B.configure.props.dataOrigin.rowToColumn.firstColumnTitle, 0, "string")), Object.keys(n2[0]).forEach((o5, n3) => {
81
+ return e5.push(D("$GroupColumn", M.configure.props.dataOrigin.rowToColumn.firstColumnTitle, 0, "string")), Object.keys(n2[0]).forEach((o5, n3) => {
82
82
  if ("$GroupColumn" === o5) return;
83
- const r3 = A(o5, o5, n3 + 1, "string");
83
+ const r3 = D(o5, o5, n3 + 1, "string");
84
84
  e5.push(r3);
85
85
  }), e5;
86
86
  }
@@ -96,30 +96,30 @@ const q = e({ __name: "table-runtime", props: { configure: { type: Object, defau
96
96
  }), a2.forEach((o5) => {
97
97
  t2.forEach((r3) => {
98
98
  var _a3;
99
- const t3 = (_a3 = ne.value.find((e6) => e6.props.base.prop === r3)) == null ? void 0 : _a3.props.base.name, i4 = A(`${o5}${r3}`, `${o5}${t3}`, e5.length + 1, "number" == typeof n2[0][`${o5}${r3}`] ? "number" : "string");
99
+ const t3 = (_a3 = re.value.find((e6) => e6.props.base.prop === r3)) == null ? void 0 : _a3.props.base.name, i4 = D(`${o5}${r3}`, `${o5}${t3}`, e5.length + 1, "number" == typeof n2[0][`${o5}${r3}`] ? "number" : "string");
100
100
  e5.push(i4);
101
101
  });
102
102
  }), e5;
103
103
  }
104
- }(B.configure, ne.value, e3);
105
- ne.value = o3;
104
+ }(M.configure, re.value, e3);
105
+ re.value = o3;
106
106
  }
107
- } else be("columnToRow") && (ee.value || (ne.value = H(B.configure)), e3 = _(e3, B.configure));
108
- if (B.configure.props.dataOrigin.dataFormatting) {
109
- const o3 = $(B.pageContext, B.configure.props.dataOrigin.dataFormatting);
107
+ } else Oe("columnToRow") && (oe.value || (re.value = _(M.configure)), e3 = z(e3, M.configure));
108
+ if (M.configure.props.dataOrigin.dataFormatting) {
109
+ const o3 = F(M.pageContext, M.configure.props.dataOrigin.dataFormatting);
110
110
  if (o3) {
111
111
  const n2 = o3.apply(o3, [{ tableData: e3 }]);
112
112
  n2 && (e3 = n2);
113
113
  }
114
114
  }
115
- if (Object.keys(ce.value).length > 0 && e3 && e3.length > 0 && z(ce.value, e3, B.pageContext.entity), ((_a2 = B.configure.pageination) == null ? void 0 : _a2.enable) ? function(e4) {
116
- "frontend" === B.configure.pageination.type ? (fe.value = me.length, Fe(1, B.configure.pageination.pageSize)) : "backend" === B.configure.pageination.type && (oe.value = me, B.configure.pageination.totalFrom && (fe.value = e4.result[B.configure.pageination.totalFrom]));
117
- }(o2) : oe.value = e3, B.configure.props.highOrder.groupField && B.configure.props.highOrder.groupField.length > 0) {
118
- const e4 = B.configure.props.highOrder.groupField;
119
- oe.value = function(e5, o3) {
115
+ if (Object.keys(ge.value).length > 0 && e3 && e3.length > 0 && A(ge.value, e3, M.pageContext.entity), ((_a2 = M.configure.pageination) == null ? void 0 : _a2.enable) ? function(e4) {
116
+ "frontend" === M.configure.pageination.type ? (de.value = he.length, Ie(1, M.configure.pageination.pageSize)) : "backend" === M.configure.pageination.type && (ne.value = he, M.configure.pageination.totalFrom && (de.value = e4.result[M.configure.pageination.totalFrom]));
117
+ }(o2) : ne.value = e3, M.configure.props.highOrder.groupField && M.configure.props.highOrder.groupField.length > 0) {
118
+ const e4 = M.configure.props.highOrder.groupField;
119
+ ne.value = function(e5, o3) {
120
120
  var _a3, _b;
121
- if (0 === pe.value.length) return e5;
122
- const n2 = [], r2 = (_a3 = B.configure.items) == null ? void 0 : _a3.filter((e6) => o3.includes(e6.props.base.prop)), t2 = (_b = B.configure.items) == null ? void 0 : _b.filter((e6) => true === e6.props.base.groupSummary), i2 = {};
121
+ if (0 === le.value.length) return e5;
122
+ const n2 = [], r2 = (_a3 = M.configure.items) == null ? void 0 : _a3.filter((e6) => o3.includes(e6.props.base.prop)), t2 = (_b = M.configure.items) == null ? void 0 : _b.filter((e6) => true === e6.props.base.groupSummary), i2 = {};
123
123
  e5.forEach((e6) => {
124
124
  const n3 = o3.map((o4) => e6[o4]).join("|");
125
125
  i2[n3] || (i2[n3] = []), i2[n3].push(e6);
@@ -128,128 +128,127 @@ const q = e({ __name: "table-runtime", props: { configure: { type: Object, defau
128
128
  for (let e6 = 0; e6 < a2.length; e6++) {
129
129
  const o4 = a2[e6], i3 = {};
130
130
  t2 == null ? void 0 : t2.forEach((e7) => {
131
- const n3 = e7.props.base.prop, r3 = D(pe.value[n3], o4, n3, B.pageContext);
131
+ const n3 = e7.props.base.prop, r3 = J(le.value[n3], o4, n3, M.pageContext);
132
132
  i3[n3] = r3;
133
133
  }), n2.push(...o4), r2 == null ? void 0 : r2.forEach((e7) => {
134
134
  const n3 = e7.props.base.prop;
135
- i3[n3] = J(e7.props.base.summaryTitle, o4[0]);
136
- }), n2.push(i3), le.push(n2.length - 1);
135
+ i3[n3] = P(e7.props.base.summaryTitle, o4[0]);
136
+ }), n2.push(i3), se.push(n2.length - 1);
137
137
  }
138
138
  return n2;
139
- }(oe.value, e4);
139
+ }(ne.value, e4);
140
140
  }
141
141
  !function(e4) {
142
- if (B.configure.props.base.showIndex && -1 === e4.findIndex((e5) => "$index" === e5.props.base.prop)) {
143
- const o3 = P();
142
+ if (M.configure.props.base.showIndex && -1 === e4.findIndex((e5) => "$index" === e5.props.base.prop)) {
143
+ const o3 = U();
144
144
  o3 && e4.unshift(o3);
145
145
  }
146
- }(ne.value);
147
- }
148
- function be(e3) {
149
- return B.configure.props.dataOrigin.transition === e3 && B.configure.props.dataOrigin[e3].titleColumns && B.configure.props.dataOrigin[e3].titleColumns.length > 0 && B.configure.props.dataOrigin[e3].dataColumns && B.configure.props.dataOrigin[e3].dataColumns.length > 0;
150
- }
151
- function xe(e3) {
152
- const o2 = se.value[e3.column.property] ? se.value[e3.column.property].titleStyle : null, n2 = Q == null ? void 0 : Q.titleStyle;
153
- return U(e3, { cellTitleStyle: o2, titleStyle: n2 }, B);
146
+ }(re.value);
154
147
  }
155
148
  function Oe(e3) {
156
- return V(e3, le, B);
149
+ return M.configure.props.dataOrigin.transition === e3 && M.configure.props.dataOrigin[e3].titleColumns && M.configure.props.dataOrigin[e3].titleColumns.length > 0 && M.configure.props.dataOrigin[e3].dataColumns && M.configure.props.dataOrigin[e3].dataColumns.length > 0;
157
150
  }
158
151
  function Se(e3) {
159
- const o2 = se.value[e3.column.property] ? se.value[e3.column.property].cellStyle : null;
160
- return G(e3, o2, B);
152
+ const o2 = ce.value[e3.column.property] ? ce.value[e3.column.property].titleStyle : null, n2 = W == null ? void 0 : W.titleStyle;
153
+ return V(e3, { cellTitleStyle: o2, titleStyle: n2 }, M);
154
+ }
155
+ function we(e3) {
156
+ return G(e3, se, M);
161
157
  }
162
- he && he.fixHeight && (de = he.fixHeight), he && he.maxHeight && (de = he.maxHeight), de && (de = Number(de + "")), n(() => {
163
- const e3 = x(B.pageContext, B.configure);
164
- if (e3) ve(e3);
165
- else if ("variable" === B.configure.props.dataOrigin.dataSource) {
158
+ function Ee(e3) {
159
+ const o2 = ce.value[e3.column.property] ? ce.value[e3.column.property].cellStyle : null;
160
+ return K(e3, o2, M);
161
+ }
162
+ ye && ye.fixHeight && (ve = ye.fixHeight), ye && ye.maxHeight && (ve = ye.maxHeight), ve && (ve = Number(ve + "")), r(() => {
163
+ const e3 = O(M.pageContext, M.configure);
164
+ if (e3) Ce(e3);
165
+ else if ("variable" === M.configure.props.dataOrigin.dataSource) {
166
166
  !function() {
167
- const e4 = B.configure.props.dataOrigin.variable.match(/\${(.*?)}/), o3 = e4 ? e4[1].split(".") : [];
168
- r(() => o3.reduce((e5, o4) => e5[o4], B.pageContext.entity), (e5) => {
169
- e5 ? ve(JSON.parse(JSON.stringify(e5))) : (oe.value = [], B.configure.props.modelCustom ? Ne(null) : ee.value ? re.value = B.configure.props.groupHeaders : ne.value = B.configure.items);
167
+ const e4 = M.configure.props.dataOrigin.variable.match(/\${(.*?)}/), o3 = e4 ? e4[1].split(".") : [];
168
+ t(() => o3.reduce((e5, o4) => e5[o4], M.pageContext.entity), (e5) => {
169
+ e5 ? Ce(JSON.parse(JSON.stringify(e5))) : (ne.value = [], M.configure.props.modelCustom ? Te(null) : oe.value ? te.value = M.configure.props.groupHeaders : re.value = M.configure.items);
170
170
  });
171
171
  }();
172
- const o2 = O(B.pageContext.entity, B.configure.props.dataOrigin.variable);
173
- o2 && Ce(o2, e3);
172
+ const o2 = S(M.pageContext.entity, M.configure.props.dataOrigin.variable);
173
+ o2 && xe(o2, e3);
174
174
  }
175
175
  });
176
- const we = (e3) => {
176
+ const je = (e3) => {
177
177
  const { columns: o2, data: n2 } = e3, r2 = [];
178
178
  return o2.forEach((e4, o3) => {
179
- if (ae.value[e4.property]) {
180
- const t2 = ae.value[e4.property].label;
181
- return void (r2[o3] = y("div", {}, [J(t2, n2)]));
182
- }
183
179
  if (ue.value[e4.property]) {
184
- const t2 = n2.filter((e5, o4) => !le.includes(o4));
185
- r2[o3] = D(ue.value[e4.property], t2, e4.property, B.pageContext);
180
+ const t2 = ue.value[e4.property].label;
181
+ r2[o3] = C("div", {}, [P(t2, n2)]);
182
+ } else if (pe.value[e4.property]) {
183
+ const t2 = n2.filter((e5, o4) => !se.includes(o4));
184
+ r2[o3] = J(pe.value[e4.property], t2, e4.property, M.pageContext);
186
185
  }
187
186
  }), r2;
188
187
  };
189
- function Ee({ row: e3, column: o2, rowIndex: n2, columnIndex: r2 }) {
190
- const t2 = o2.property, i2 = B.configure.props.highOrder;
188
+ function $e({ row: e3, column: o2, rowIndex: n2, columnIndex: r2 }) {
189
+ const t2 = o2.property, i2 = M.configure.props.highOrder;
191
190
  if (i2.scopeFunc) {
192
- const t3 = $(B.pageContext, i2.scopeFunc);
191
+ const t3 = F(M.pageContext, i2.scopeFunc);
193
192
  if (t3) {
194
- const i3 = t3.apply(t3, [{ tableData: oe.value, row: e3, column: o2, rowIndex: n2, columnIndex: r2 }]);
193
+ const i3 = t3.apply(t3, [{ tableData: ne.value, row: e3, column: o2, rowIndex: n2, columnIndex: r2 }]);
195
194
  if (i3) return i3;
196
195
  }
197
- } else if (i2 && i2.mergeColumn, i2 && i2.mergeRow && i2.mergeRow.includes(t2) && 0 === n2) return { rowspan: oe.value.length, colspan: 1 };
198
- }
199
- function je(e3, o2) {
200
- "frontend" === B.configure.pageination.type ? Fe(e3, o2) : ke(e3, o2);
201
- }
202
- function $e(e3, o2) {
203
- "frontend" === B.configure.pageination.type ? Fe(e3, o2) : ke(e3, o2);
196
+ } else if (i2 && i2.mergeColumn, i2 && i2.mergeRow && i2.mergeRow.includes(t2) && 0 === n2) return { rowspan: ne.value.length, colspan: 1 };
204
197
  }
205
198
  function Fe(e3, o2) {
206
- me && (oe.value = me.slice((e3 - 1) * o2, e3 * o2));
199
+ "frontend" === M.configure.pageination.type ? Ie(e3, o2) : Ne(e3, o2);
207
200
  }
208
201
  function ke(e3, o2) {
209
- B.configure.pageination.currentPageSet && w(B.pageContext.entity, B.configure.pageination.currentPageSet, e3), B.configure.pageination.pageSizeSet && w(B.pageContext.entity, B.configure.pageination.pageSizeSet, o2), E(B.pageContext, B.configure.uuid);
202
+ "frontend" === M.configure.pageination.type ? Ie(e3, o2) : Ne(e3, o2);
203
+ }
204
+ function Ie(e3, o2) {
205
+ he && (ne.value = he.slice((e3 - 1) * o2, e3 * o2));
206
+ }
207
+ function Ne(e3, o2) {
208
+ M.configure.pageination.currentPageSet && j(M.pageContext.entity, M.configure.pageination.currentPageSet, e3), M.configure.pageination.pageSizeSet && j(M.pageContext.entity, M.configure.pageination.pageSizeSet, o2), $(M.pageContext, M.configure.uuid);
210
209
  }
211
- function Ie(e3) {
210
+ function Re(e3) {
212
211
  const o2 = e3.showCondition;
213
- return j(B.pageContext, o2);
212
+ return w(M.pageContext, o2);
214
213
  }
215
- function Ne(e3) {
216
- if (B.configure.props.modelCustom) {
217
- const o2 = $(B.pageContext, B.configure.props.modelCustom);
214
+ function Te(e3) {
215
+ if (M.configure.props.modelCustom) {
216
+ const o2 = F(M.pageContext, M.configure.props.modelCustom);
218
217
  if (o2) {
219
- const n2 = o2.apply(o2, [{ pageContext: B.pageContext, configureObj: B.configure, value: e3 }]);
220
- S(n2) ? n2.then((e4) => {
221
- ne.value = e4.columns;
222
- }) : ne.value = n2.columns;
218
+ const n2 = o2.apply(o2, [{ pageContext: M.pageContext, configureObj: M.configure, value: e3 }]);
219
+ E(n2) ? n2.then((e4) => {
220
+ re.value = e4.columns;
221
+ }) : re.value = n2.columns;
223
222
  }
224
223
  }
225
224
  }
226
- function Re(e3, o2, n2) {
225
+ function He(e3, o2, n2) {
227
226
  e3.forEach((e4) => {
228
227
  const r2 = e4.props.base.prop, t2 = e4.props.base.name;
229
228
  let i2 = { name: r2, label: t2, i18nKey: t2 };
230
- e4.children && e4.childern.length > 0 && (i2.children = [], Re(e4.children, i2.children, n2)), e4.props.format && e4.props.format.type && n2.push(e4), o2.push(i2);
229
+ e4.children && e4.childern.length > 0 && (i2.children = [], He(e4.children, i2.children, n2)), e4.props.format && e4.props.format.type && n2.push(e4), o2.push(i2);
231
230
  });
232
231
  }
233
- return q2({ updateChartDatas: ve, exportChart: function() {
232
+ return B2({ updateChartDatas: Ce, exportChart: function() {
234
233
  let e3 = [], o2 = [];
235
- o2 = ee.value ? B.configure.props.groupHeaders : B.configure.items;
234
+ o2 = oe.value ? M.configure.props.groupHeaders : me.value;
236
235
  let n2 = [];
237
- Re(o2, e3, n2);
236
+ He(o2, e3, n2);
238
237
  return { isTable: true, dataArr: function(e4) {
239
238
  let o3 = [];
240
- oe.value && (o3 = L(oe.value), o3.forEach((o4) => {
239
+ ne.value && (o3 = q(ne.value), o3.forEach((o4) => {
241
240
  e4.forEach((e5) => {
242
- const n3 = K(o4, e5.props.format, e5, B.pageContext, B.configure);
241
+ const n3 = L(o4, e5.props.format, e5, M.pageContext, M.configure);
243
242
  o4[e5.props.base.prop] = n3;
244
243
  });
245
244
  }));
246
245
  return o3;
247
246
  }(n2), columns: e3 };
248
247
  } }), (o2, n2) => {
249
- const r2 = t("el-table");
250
- return a(), i("div", { style: p(l(Q)), class: u([l(W), "amb-widget-chart amb-widget-flex"]), ref: "thisRef" }, [s(c(C, { ref_key: "headerRef", ref: Z, headerInfo: l(Y), configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["headerInfo", "configure", "pageContext"]), [[m, l(Y).showHeader || e2.pageContext.showHomepageSearch]]), c(r2, { ref_key: "gridRef", ref: ge, data: oe.value, style: { width: "100%" }, "max-height": l(de), "header-cell-style": xe, "row-style": Oe, "cell-style": Se, "show-summary": ie.value, stripe: e2.configure.props.base.stripe, "summary-method": we, "span-method": Ee }, { default: d(() => [ee.value ? (a(true), i(h, { key: 0 }, v(re.value, (o3, n3) => (a(), i(h, { key: n3 }, [o3.isLeaf ? Ie(te.value[o3.columnUuid]) ? (a(), g(k, { key: 1, configure: e2.configure, pageContext: e2.pageContext, column: te.value[o3.columnUuid] }, null, 8, ["configure", "pageContext", "column"])) : f("", true) : (a(), g(F, { key: 0, configure: e2.configure, pageContext: e2.pageContext, groupColumn: o3, columnsConfigKeyValues: te.value }, null, 8, ["configure", "pageContext", "groupColumn", "columnsConfigKeyValues"]))], 64))), 128)) : (a(true), i(h, { key: 1 }, v(ne.value, (o3, n3) => (a(), i(h, { key: n3 }, [Ie(o3) ? (a(), g(k, { key: 0, column: o3, configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["column", "configure", "pageContext"])) : f("", true)], 64))), 128))]), _: 1 }, 8, ["data", "max-height", "show-summary", "stripe"]), e2.configure.pageination && e2.configure.pageination.enable ? (a(), g(I, { key: 0, configure: e2.configure, "table-data": oe.value, total: fe.value, onPageChange: je, onPageSizeChange: $e }, null, 8, ["configure", "table-data", "total"])) : f("", true)], 6);
248
+ const r2 = i("el-table");
249
+ return u(), a("div", { style: l(s(W)), class: p([s(X), "amb-widget-chart amb-widget-flex"]), ref: "thisRef" }, [c(g(b, { ref_key: "headerRef", ref: ee, headerInfo: s(Z), configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["headerInfo", "configure", "pageContext"]), [[d, s(Z).showHeader || e2.pageContext.showHomepageSearch]]), g(r2, { ref_key: "gridRef", ref: fe, data: ne.value, style: { width: "100%" }, "max-height": s(ve), "header-cell-style": Se, "row-style": we, "cell-style": Ee, "show-summary": ae.value, stripe: e2.configure.props.base.stripe, "summary-method": je, "span-method": $e }, { default: h(() => [oe.value ? (u(true), a(v, { key: 0 }, y(te.value, (o3, n3) => (u(), a(v, { key: n3 }, [o3.isLeaf ? (u(), f(I, { key: 1, configure: e2.configure, pageContext: e2.pageContext, column: ie.value[o3.columnUuid] }, null, 8, ["configure", "pageContext", "column"])) : (u(), f(k, { key: 0, configure: e2.configure, pageContext: e2.pageContext, groupColumn: o3, columnsConfigKeyValues: ie.value }, null, 8, ["configure", "pageContext", "groupColumn", "columnsConfigKeyValues"]))], 64))), 128)) : (u(true), a(v, { key: 1 }, y(me.value, (o3, n3) => (u(), f(I, { key: n3, column: o3, configure: e2.configure, pageContext: e2.pageContext }, null, 8, ["column", "configure", "pageContext"]))), 128))]), _: 1 }, 8, ["data", "max-height", "show-summary", "stripe"]), e2.configure.pageination && e2.configure.pageination.enable ? (u(), f(N, { key: 0, configure: e2.configure, "table-data": ne.value, total: de.value, onPageChange: Fe, onPageSizeChange: ke }, null, 8, ["configure", "table-data", "total"])) : m("", true)], 6);
251
250
  };
252
251
  } });
253
252
  export {
254
- q as default
253
+ B as default
255
254
  };