super-page-runtime 2.1.932 → 2.2.0

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 (160) hide show
  1. package/dist/es/_virtual/_plugin-vue_export-helper.js +6 -7
  2. package/dist/es/assets/chart-themes/theme1.js +2 -6
  3. package/dist/es/assets/chart-themes/theme2.js +2 -6
  4. package/dist/es/assets/chart-themes/theme3.js +2 -6
  5. package/dist/es/components/runtime/utils/api/api-util.js +4 -7
  6. package/dist/es/components/runtime/utils/api/page-expose-util.js +137 -433
  7. package/dist/es/components/runtime/utils/assemblys-config.js +12 -366
  8. package/dist/es/components/runtime/utils/barcode-util.js +10 -33
  9. package/dist/es/components/runtime/utils/charts/chart-columnline-util.js +138 -300
  10. package/dist/es/components/runtime/utils/charts/chart-gauge-util.js +29 -66
  11. package/dist/es/components/runtime/utils/charts/chart-pie-util.js +71 -147
  12. package/dist/es/components/runtime/utils/charts/chart-radar-util.js +52 -122
  13. package/dist/es/components/runtime/utils/charts/chart-scatter-util.js +40 -98
  14. package/dist/es/components/runtime/utils/charts/chart-util.js +237 -478
  15. package/dist/es/components/runtime/utils/common-util.js +82 -152
  16. package/dist/es/components/runtime/utils/eventBus.js +3 -9
  17. package/dist/es/components/runtime/utils/events/event-util.js +361 -727
  18. package/dist/es/components/runtime/utils/events/print-label.js +73 -140
  19. package/dist/es/components/runtime/utils/events/standard-event.js +838 -2285
  20. package/dist/es/components/runtime/utils/events/validator-util.js +237 -536
  21. package/dist/es/components/runtime/utils/form/date-shortcuts.js +29 -88
  22. package/dist/es/components/runtime/utils/form/scan-util.js +60 -154
  23. package/dist/es/components/runtime/utils/global-refs.js +45 -69
  24. package/dist/es/components/runtime/utils/i18n-util.js +12 -20
  25. package/dist/es/components/runtime/utils/interfaces/page-design-types.js +2 -7
  26. package/dist/es/components/runtime/utils/page-helper-util.js +298 -628
  27. package/dist/es/components/runtime/utils/page-init-util.js +134 -368
  28. package/dist/es/components/runtime/utils/page-permission-util.js +24 -531
  29. package/dist/es/components/runtime/utils/page-store.js +8 -12
  30. package/dist/es/components/runtime/utils/store-util.js +9 -13
  31. package/dist/es/components/runtime/utils/store.js +2 -2
  32. package/dist/es/components/runtime/utils/table-utils.js +49 -84
  33. package/dist/es/components/runtime/utils/tree-utils.js +18 -36
  34. package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue.js +2 -2
  35. package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue2.js +19 -75
  36. package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue.js +2 -2
  37. package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue2.js +14 -46
  38. package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue.js +2 -2
  39. package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue2.js +37 -132
  40. package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue.js +2 -2
  41. package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue2.js +4 -18
  42. package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue.js +2 -2
  43. package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue2.js +17 -107
  44. package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue.js +2 -2
  45. package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +54 -198
  46. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue.js +12 -42
  47. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue2.js +2 -2
  48. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +7 -60
  49. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue2.js +2 -2
  50. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +48 -169
  51. package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue2.js +2 -2
  52. package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue.js +2 -2
  53. package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +32 -107
  54. package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue.js +2 -2
  55. package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +43 -164
  56. package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue.js +2 -2
  57. package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +32 -115
  58. package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue.js +2 -2
  59. package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +32 -116
  60. package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +208 -439
  61. package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue.js +4 -42
  62. package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue2.js +2 -2
  63. package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue.js +8 -62
  64. package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue2.js +2 -2
  65. package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue.js +63 -226
  66. package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue2.js +2 -2
  67. package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue.js +13 -62
  68. package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue2.js +2 -2
  69. package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue.js +2 -2
  70. package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +168 -512
  71. package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +29 -139
  72. package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue2.js +2 -2
  73. package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue.js +23 -125
  74. package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue2.js +2 -2
  75. package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.js +16 -102
  76. package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue2.js +2 -2
  77. package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue.js +2 -2
  78. package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +18 -81
  79. package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue.js +2 -2
  80. package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue2.js +17 -82
  81. package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue.js +2 -2
  82. package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue2.js +14 -86
  83. package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue.js +2 -2
  84. package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue2.js +21 -79
  85. package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue.js +2 -2
  86. package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue2.js +16 -61
  87. package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue.js +2 -2
  88. package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue2.js +10 -37
  89. package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue.js +2 -2
  90. package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue2.js +38 -127
  91. package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue.js +2 -2
  92. package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue2.js +28 -76
  93. package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue.js +2 -2
  94. package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +61 -178
  95. package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +311 -800
  96. package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue2.js +2 -2
  97. package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +251 -592
  98. package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue2.js +2 -2
  99. package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue.js +2 -2
  100. package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +43 -115
  101. package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue.js +2 -2
  102. package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +56 -215
  103. package/dist/es/components/runtime/views/assemblys/error-render.vue.js +3 -21
  104. package/dist/es/components/runtime/views/assemblys/error-render.vue2.js +2 -2
  105. package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue.js +2 -2
  106. package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +44 -154
  107. package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue.js +36 -98
  108. package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue2.js +2 -2
  109. package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue.js +2 -2
  110. package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +54 -200
  111. package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue.js +2 -2
  112. package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +69 -239
  113. package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue.js +2 -2
  114. package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +28 -98
  115. package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue.js +2 -2
  116. package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue2.js +22 -59
  117. package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue.js +2 -2
  118. package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +52 -173
  119. package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue.js +2 -2
  120. package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +22 -103
  121. package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue.js +2 -2
  122. package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +58 -249
  123. package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue.js +2 -2
  124. package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +34 -174
  125. package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue.js +2 -2
  126. package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +28 -107
  127. package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue.js +5 -5
  128. package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue2.js +13 -50
  129. package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue3.js +1 -0
  130. package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue.js +2 -2
  131. package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +66 -189
  132. package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue.js +2 -2
  133. package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +91 -243
  134. package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue.js +2 -2
  135. package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +82 -261
  136. package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue.js +2 -2
  137. package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue2.js +13 -57
  138. package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue.js +2 -2
  139. package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +30 -155
  140. package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue.js +2 -2
  141. package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue2.js +41 -129
  142. package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue.js +2 -2
  143. package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +22 -107
  144. package/dist/es/components/runtime/views/assemblys/object-render.vue.js +133 -252
  145. package/dist/es/components/runtime/views/assemblys/object-render.vue2.js +2 -2
  146. package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue.js +2 -2
  147. package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue2.js +19 -46
  148. package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue.js +2 -2
  149. package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue2.js +22 -49
  150. package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue.js +2 -2
  151. package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue2.js +21 -58
  152. package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue.js +2 -2
  153. package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue2.js +16 -53
  154. package/dist/es/components/runtime/views/super-page-dialog.vue.js +18 -134
  155. package/dist/es/components/runtime/views/super-page-dialog.vue2.js +2 -2
  156. package/dist/es/components/runtime/views/super-page.vue.js +233 -708
  157. package/dist/es/components/runtime/views/super-page.vue2.js +2 -2
  158. package/dist/es/i18n/langs/cn.js +2 -55
  159. package/dist/es/i18n/langs/en.js +2 -55
  160. package/package.json +74 -73
@@ -1,604 +1,263 @@
1
- import { defineComponent, ref, onMounted, onUnmounted, resolveComponent, openBlock, createElementBlock, createBlock, unref, createCommentVNode } from "vue";
2
- import { setTableEvents, gridSelectRecord, gridSelectAllRecords, gridSelectionChange, cellClick, cellDblClick, rowClick, rowDblClick, headerClick } from "../../../../utils/events/event-util.js";
3
- import { caculateShowCondition, setVariableValue, getVariableValue, getSizeConfig } from "../../../../utils/page-helper-util.js";
4
- import { getModelFields, getDefaultValue } from "../../../../utils/page-init-util.js";
5
- import eventBus from "../../../../utils/eventBus.js";
6
- import { popupToPage, getOperationButtons } from "../../../../utils/table-utils.js";
7
- import { getListCode, getBaseUrl } from "../../../../utils/common-util.js";
8
- import { getAdditionalParamMap } from "../../../../utils/events/standard-event.js";
9
- import { getRowStyleUtil, getCellStyleUtil, getHeaderCellStyleUtil } from "../../chart/table/chart-table-util.js";
10
- const _sfc_main = /* @__PURE__ */ defineComponent({
11
- __name: "sub-table-runtime",
12
- props: {
13
- pageContext: {},
14
- configure: {}
15
- },
16
- emits: ["setSafeDeleteTableCode"],
17
- setup(__props, { expose: __expose, emit: __emit }) {
18
- const props = __props;
19
- const pageContext = props.pageContext;
20
- const configure = props.configure;
21
- const listCode = getListCode(pageContext.code, pageContext.version, configure.uuid);
22
- const dataModel = pageContext.entity.data;
23
- const prop = configure.code ? configure.code : listCode;
24
- const additionalParamMap = getAdditionalParamMap(pageContext);
25
- const tableEvents = configure.runtime && configure.runtime.events ? configure.runtime.events : [];
26
- const selections = ref([]);
27
- const superGridItems = pageContext.superGridItems;
28
- const superGridSetting = superGridItems ? superGridItems[configure.uuid] : null;
29
- console.log("superGridSetting===", superGridItems, superGridSetting);
30
- const runtimeInfo = props.configure.runtime ? props.configure.runtime : {};
31
- const runtimeStyle = runtimeInfo.style;
32
- const runtimeClass = runtimeInfo.class;
33
- const entity = props.pageContext.entity ? props.pageContext.entity : {};
34
- let dynamicFields = getModelFields(props.configure, prop);
35
- let baseURL = getBaseUrl(pageContext.backendUrl, pageContext.isTest);
36
- if (!baseURL) {
37
- baseURL = window["$vueApp"].config.globalProperties.baseURL;
38
- }
39
- const listViewShowFlag = ref(false);
40
- let componentKey = ref(0);
41
- const listViewOptions = ref({
42
- isSql: true,
43
- subTableData: null,
44
- extraParam: {},
45
- operations: {},
46
- hiddenColumns: [],
47
- pageCode: pageContext.code,
48
- pageVersion: pageContext.version,
49
- pageContext,
50
- configureObj: configure,
51
- showPageArea: false,
52
- showRowForm: false,
53
- showOverflowTooltip: !!(configure.props && configure.props.otherSettings && (configure.props.otherSettings.isBreakLine === void 0 || configure.props.otherSettings.isBreakLine === false)),
54
- // 单元格内容是否换行显示
55
- backendUrl: baseURL,
56
- cellStyleRender: getCellStyle,
57
- rowStyleRender: getRowStyle,
58
- titleStyleRender: getTitleStyle
59
- });
60
- const $emit = __emit;
61
- if (runtimeStyle) {
62
- listViewOptions.value["tableStyle"] = runtimeStyle;
63
- }
64
- if (runtimeClass) {
65
- listViewOptions.value["tableClass"] = runtimeClass;
66
- }
67
- if (configure.props && configure.props.base && configure.props.base.subPaging === true) {
68
- listViewOptions.value.showPageArea = true;
69
- } else {
70
- listViewOptions.value.showPageArea = false;
71
- }
72
- if (configure.props.base.showRowForm) {
73
- listViewOptions.value.showRowForm = configure.props.base.showRowForm;
74
- }
75
- const gridRef = ref(null);
76
- onMounted(() => {
77
- const tableUuid = configure.uuid;
78
- const subTableWatchProps = pageContext.subTableWatchProps;
79
- eventBus.$on("_refreshSubTable_" + tableUuid, (params) => {
80
- console.log("-_refreshSubTable--tableUuid=", tableUuid, "params=", params);
81
- const propName = params.propName;
82
- if (subTableWatchProps && subTableWatchProps[tableUuid] && subTableWatchProps[tableUuid].length > 0) {
83
- const mainFormProps = subTableWatchProps[tableUuid];
84
- if (mainFormProps.indexOf(propName) >= 0) {
85
- reloadSubTableData();
86
- }
87
- }
88
- });
89
- eventBus.$on("_refreshSubTableHandle_" + tableUuid, (params) => {
90
- console.log("-_refreshSubTableHandle_--tableUuid=", tableUuid, "params=", params);
91
- reloadSubTableData();
92
- });
93
- eventBus.$on(
94
- "_refreshChildData_" + tableUuid,
95
- (gridData) => {
96
- console.log("-_refreshChildData_--tableUuid=", tableUuid);
97
- refreshChildTableData(gridData);
1
+ import { defineComponent as e, ref as t, onMounted as n, onUnmounted as o, resolveComponent as a, openBlock as i, createElementBlock as l, createBlock as s, unref as u, createCommentVNode as r } from "vue";
2
+ import { setTableEvents as c, gridSelectRecord as p, gridSelectAllRecords as f, gridSelectionChange as d, cellClick as b, cellDblClick as v, rowClick as g, rowDblClick as m, headerClick as h } from "../../../../utils/events/event-util.js";
3
+ import { caculateShowCondition as S, setVariableValue as w, getVariableValue as x, getSizeConfig as T } from "../../../../utils/page-helper-util.js";
4
+ import { getModelFields as D, getDefaultValue as C } from "../../../../utils/page-init-util.js";
5
+ import y from "../../../../utils/eventBus.js";
6
+ import { popupToPage as P, getOperationButtons as I } from "../../../../utils/table-utils.js";
7
+ import { getListCode as R, getBaseUrl as _ } from "../../../../utils/common-util.js";
8
+ import { getAdditionalParamMap as O } from "../../../../utils/events/standard-event.js";
9
+ import { getRowStyleUtil as k, getCellStyleUtil as M, getHeaderCellStyleUtil as F } from "../../chart/table/chart-table-util.js";
10
+ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure: {} }, emits: ["setSafeDeleteTableCode"], setup(e2, { expose: $2, emit: j }) {
11
+ const A = e2, H = A.pageContext, N = A.configure, E = R(H.code, H.version, N.uuid), L = H.entity.data, z = N.code ? N.code : E, B = O(H), U = N.runtime && N.runtime.events ? N.runtime.events : [], G = t([]), V = H.superGridItems, q = V ? V[N.uuid] : null, J = A.configure.runtime ? A.configure.runtime : {}, Q = J.style, W = J.class, K = A.pageContext.entity ? A.pageContext.entity : {};
12
+ let X = D(A.configure, z), Y = _(H.backendUrl, H.isTest);
13
+ Y || (Y = window.$vueApp.config.globalProperties.baseURL);
14
+ const Z = t(false);
15
+ let ee = t(0);
16
+ const te = t({ isSql: true, subTableData: null, extraParam: {}, operations: {}, hiddenColumns: [], pageCode: H.code, pageVersion: H.version, pageContext: H, configureObj: N, showPageArea: false, showRowForm: false, showOverflowTooltip: !(!N.props || !N.props.otherSettings || void 0 !== N.props.otherSettings.isBreakLine && false !== N.props.otherSettings.isBreakLine), backendUrl: Y, cellStyleRender: function(e3) {
17
+ return M(e3, e3.cellStyle, A);
18
+ }, rowStyleRender: function(e3) {
19
+ return k(e3, null, A);
20
+ }, titleStyleRender: function(e3) {
21
+ const t2 = e3.titleStyle, n2 = A.configure.style.titleStyle;
22
+ return F(e3, { cellTitleStyle: t2, titleStyle: n2 }, A);
23
+ } }), ne = j;
24
+ Q && (te.value.tableStyle = Q), W && (te.value.tableClass = W), N.props && N.props.base && true === N.props.base.subPaging ? te.value.showPageArea = true : te.value.showPageArea = false, N.props.base.showRowForm && (te.value.showRowForm = N.props.base.showRowForm);
25
+ const oe = t(null);
26
+ function ae() {
27
+ oe.value && (te.value.subTableData = null, oe.value.reloadSubTableData(E));
28
+ }
29
+ function ie(e3) {
30
+ if (void 0 === e3 && (e3 = le()), te.value.isPageInfo = false, te.value.isFormSubTable = true, te.value.canRrefreshSubtableData = e3, te.value.getFormData = se, te.value.getGridData = ue, te.value.extraParam.subTableListViewCode = E, te.value.extraParam.beanName = H.beanName, te.value.extraParam.subtableSetting = N.props && N.props.otherSettings ? JSON.stringify(N.props.otherSettings) : null, te.value.extraParam.additionalParamMap = B, te.value.extraParam.entityMap = H.entity.data, te.value.extraParam.contextMap = H.entity.context, te.value.extraParam.taskMap = H.entity.task, !(N.props && N.props.base && N.props.base.showOperation)) {
31
+ let e4 = te.value.hiddenColumns;
32
+ e4 ? e4.push("operation") : e4 = ["operation"], te.value.hiddenColumns = e4;
33
+ }
34
+ te.value.showOperationButton = !(!N.props || !N.props.base) && N.props.base.showOperation, te.value.isPdfEditor = false, te.value.tableRecordMaxNum = N.props && N.props.otherSettings ? N.props.otherSettings.tableRecordMaxNum : null;
35
+ let t2 = T(H, N);
36
+ t2 && t2.fixHeight && (te.value.formSetHeight = t2.fixHeight), t2 && t2.maxHeight && (te.value.formSetMaxHeight = t2.maxHeight);
37
+ }
38
+ function le() {
39
+ if (N.props && N.props.otherSettings) {
40
+ if (N.props.otherSettings.sourceQueryTableData && N.props.otherSettings.timeToInitializeSubTable && N.props.otherSettings.timeToInitializeSubTable.length > 0) {
41
+ let e3 = false;
42
+ if (-1 !== N.props.otherSettings.timeToInitializeSubTable.indexOf("create") && (e3 = !L.id && !L.ID), -1 !== N.props.otherSettings.timeToInitializeSubTable.indexOf("noData")) {
43
+ const t2 = L[z];
44
+ (!t2 || t2.length <= 0) && (e3 = true);
98
45
  }
99
- );
100
- eventBus.$on(listCode + "-pickFileDone", (data) => {
101
- console.log("superPage5555---listCode---pickFileDone--listCode=", listCode, "data=", data);
102
- gridRef.value.pickFileDone(data);
103
- });
104
- eventBus.$on(listCode + "-scanDone", (data) => {
105
- console.log("superPage5555---listCode---scanDone--listCode=", listCode, "data=", data);
106
- gridRef.value.scanDone(data);
107
- });
108
- if (listViewOptions.value && listViewOptions.value.configureObj.props.base && listViewOptions.value.configureObj.props.base.isSafeDelete) {
109
- $emit("setSafeDeleteTableCode", listViewOptions.value.extraParam.tableName);
110
- }
111
- });
112
- function reloadSubTableData() {
113
- if (gridRef.value) {
114
- listViewOptions.value["subTableData"] = null;
115
- gridRef.value.reloadSubTableData(listCode);
46
+ return e3;
116
47
  }
48
+ return false;
117
49
  }
118
- onUnmounted(() => {
119
- const tableUuid = configure.uuid;
120
- eventBus.$off("_refreshSubTable_" + tableUuid);
121
- eventBus.$off("_refreshSubTableHandle_" + tableUuid);
122
- eventBus.$off("_refreshChildData_" + tableUuid);
123
- eventBus.$off(listCode + "-pickFileDone");
124
- eventBus.$off(listCode + "-scanDone");
125
- });
126
- function currencyListViewSetting(canRrefreshSubtableData) {
127
- if (canRrefreshSubtableData === void 0) {
128
- canRrefreshSubtableData = judgeInitializationSubTable();
129
- }
130
- listViewOptions.value["isPageInfo"] = false;
131
- listViewOptions.value["isFormSubTable"] = true;
132
- listViewOptions.value["canRrefreshSubtableData"] = canRrefreshSubtableData;
133
- listViewOptions.value["getFormData"] = getParentFormData;
134
- listViewOptions.value["getGridData"] = getGridData;
135
- listViewOptions.value.extraParam["subTableListViewCode"] = listCode;
136
- listViewOptions.value.extraParam["beanName"] = pageContext.beanName;
137
- listViewOptions.value.extraParam["subtableSetting"] = configure.props && configure.props.otherSettings ? JSON.stringify(configure.props.otherSettings) : null;
138
- listViewOptions.value.extraParam["additionalParamMap"] = additionalParamMap;
139
- listViewOptions.value.extraParam["entityMap"] = pageContext.entity.data;
140
- listViewOptions.value.extraParam["contextMap"] = pageContext.entity.context;
141
- listViewOptions.value.extraParam["taskMap"] = pageContext.entity.task;
142
- if (!(configure.props && configure.props.base && configure.props.base.showOperation)) {
143
- let hiddenColumns = listViewOptions.value.hiddenColumns;
144
- if (!hiddenColumns) {
145
- hiddenColumns = ["operation"];
146
- } else {
147
- hiddenColumns.push("operation");
50
+ }
51
+ function se() {
52
+ return H.entity.data;
53
+ }
54
+ function ue() {
55
+ return x(K, X);
56
+ }
57
+ function re(e3) {
58
+ ie(e3), te.value.subTableData = null, ce(), Z.value = false, setTimeout(() => {
59
+ Z.value = true, ee.value = ee.value + 1, pe();
60
+ }, 10);
61
+ }
62
+ function ce() {
63
+ !function() {
64
+ const e4 = H.fieldPermissionMap, t2 = H.actionPermissionMap;
65
+ if (e4 && null != e4) {
66
+ let t3 = e4.get(z);
67
+ if (!t3) {
68
+ const n3 = e4.get("all_fields");
69
+ n3 && (t3 = [n3]);
148
70
  }
149
- listViewOptions.value["hiddenColumns"] = hiddenColumns;
150
- }
151
- listViewOptions.value["showOperationButton"] = configure.props && configure.props.base ? configure.props.base.showOperation : false;
152
- listViewOptions.value["isPdfEditor"] = false;
153
- listViewOptions.value["tableRecordMaxNum"] = configure.props && configure.props.otherSettings ? configure.props.otherSettings.tableRecordMaxNum : null;
154
- let sizeConfig = getSizeConfig(pageContext, configure);
155
- if (sizeConfig && sizeConfig.fixHeight) {
156
- listViewOptions.value["formSetHeight"] = sizeConfig.fixHeight;
157
- }
158
- if (sizeConfig && sizeConfig.maxHeight) {
159
- listViewOptions.value["formSetMaxHeight"] = sizeConfig.maxHeight;
160
- }
161
- }
162
- function judgeInitializationSubTable() {
163
- if (!configure.props || !configure.props.otherSettings) {
164
- return;
165
- }
166
- if (configure.props.otherSettings.sourceQueryTableData && configure.props.otherSettings.timeToInitializeSubTable && configure.props.otherSettings.timeToInitializeSubTable.length > 0) {
167
- let flag = false;
168
- if (configure.props.otherSettings.timeToInitializeSubTable.indexOf("create") !== -1) {
169
- if (dataModel.id || dataModel.ID) {
170
- flag = false;
171
- } else {
172
- flag = true;
173
- }
71
+ te.value.validateRules = t3 || null;
72
+ }
73
+ if (t2 && null != t2) {
74
+ let e5 = t2.get(z);
75
+ e5 || (e5 = t2.get("all_sub_tables")), te.value.actionPermission = e5;
76
+ }
77
+ te.value.operations || (te.value.operations = {});
78
+ const n2 = function() {
79
+ let e5 = [], t3 = S(A.pageContext, N.props.base.showOperationCondition);
80
+ if (t3 && fe()) {
81
+ const t4 = { props: { elementType: "el-button", icon: "Plus", type: "primary", circle: true, size: "mini", permission: "true" }, onClick: ge, isShow: de };
82
+ e5.push(t4);
174
83
  }
175
- if (configure.props.otherSettings.timeToInitializeSubTable.indexOf("noData") !== -1) {
176
- const tableData = dataModel[prop];
177
- if (!tableData || tableData.length <= 0) {
178
- flag = true;
179
- }
84
+ if (t3 && be(null, null, null, null, null, true)) {
85
+ const t4 = { props: { elementType: "el-button", icon: "Minus", type: "danger", circle: true, size: "mini", permission: "true" }, onClick: me, isShow: ve };
86
+ e5.push(t4);
180
87
  }
181
- return flag;
182
- } else {
183
- return false;
184
- }
185
- }
186
- function getParentFormData() {
187
- return pageContext.entity.data;
188
- }
189
- function getGridData() {
190
- return getVariableValue(entity, dynamicFields);
191
- }
192
- function initializationSubTable() {
193
- const canRrefreshSubtableData = judgeInitializationSubTable();
194
- if (canRrefreshSubtableData) {
195
- changeInitializationSubTable(canRrefreshSubtableData);
196
- } else {
197
- currencyListViewSetting(canRrefreshSubtableData);
198
- listViewOptions.value["isPageInfo"] = false;
199
- listViewOptions.value["subTableData"] = getValue();
200
- setGridDataEventOptions();
201
- }
202
- }
203
- function changeInitializationSubTable(canRrefreshSubtableData) {
204
- currencyListViewSetting(canRrefreshSubtableData);
205
- listViewOptions.value["subTableData"] = null;
206
- setGridDataEventOptions();
207
- listViewShowFlag.value = false;
208
- setTimeout(() => {
209
- listViewShowFlag.value = true;
210
- componentKey.value = componentKey.value + 1;
211
- setGridToStore();
212
- }, 10);
213
- }
214
- function setGridDataEventOptions() {
215
- setSubTableValidateInfo();
216
- setTableEvents(listViewOptions.value, tableEvents, pageContext, configure);
217
- const customEvents = pageContext.customEvents;
218
- if (customEvents) {
219
- listViewOptions.value["eventCallBack"] = customEvents;
220
- }
221
- listViewShowFlag.value = true;
222
- setGridToStore();
223
- }
224
- function setSubTableValidateInfo() {
225
- const fieldPermissionMap = pageContext.fieldPermissionMap;
226
- const actionPermissionMap = pageContext.actionPermissionMap;
227
- if (fieldPermissionMap && fieldPermissionMap != null) {
228
- let validateRules = fieldPermissionMap.get(prop);
229
- if (!validateRules) {
230
- const allValidateRules = fieldPermissionMap.get("all_fields");
231
- if (allValidateRules) {
232
- validateRules = [allValidateRules];
88
+ return I(H, N, e5), e5;
89
+ }();
90
+ te.value.operations.operation = n2, te.value.subTableCanAdd = fe();
91
+ }(), c(te.value, U, H, N);
92
+ const e3 = H.customEvents;
93
+ e3 && (te.value.eventCallBack = e3), Z.value = true, pe();
94
+ }
95
+ function pe() {
96
+ H.tableUuids || (H.tableUuids = []), H.tableUuids.indexOf(N.uuid) < 0 && H.tableUuids.push(N.uuid);
97
+ }
98
+ function fe(e3, t2, n2, o2, a2, i2) {
99
+ if (!S(A.pageContext, N.props.base.showOperationCondition))
100
+ return false;
101
+ const l2 = H.fieldPermissionMap, s2 = H.actionPermissionMap;
102
+ let u2 = true;
103
+ if (l2 && null !== l2) {
104
+ const e4 = l2.get("all_fields");
105
+ void 0 === e4 || false !== e4.canEdit || void 0 !== e4.rowIndexes && null !== e4.rowIndexes && 0 !== e4.rowIndexes.length || (u2 = false);
106
+ }
107
+ if (true === u2 && z && s2 && null !== s2) {
108
+ let e4 = s2.get(z);
109
+ e4 || (e4 = s2.get("all_sub_tables")), e4 && void 0 !== e4.canAdd && false === e4.canAdd && (u2 = false);
110
+ }
111
+ return u2;
112
+ }
113
+ function de(e3, t2, n2, o2, a2, i2) {
114
+ let l2 = fe();
115
+ return true === l2 && (l2 = S(A.pageContext, N.props.base.showAddBtnCondition, n2)), l2;
116
+ }
117
+ function be(e3, t2, n2, o2, a2, i2) {
118
+ const l2 = H.fieldPermissionMap, s2 = H.actionPermissionMap;
119
+ let u2 = true;
120
+ if (l2 && null !== l2) {
121
+ const e4 = l2.get("all_fields");
122
+ void 0 === e4 || false !== e4.canEdit || void 0 !== e4.rowIndexes && null !== e4.rowIndexes && 0 !== e4.rowIndexes.length || (u2 = false);
123
+ }
124
+ if (true === u2 && z && s2 && null !== s2) {
125
+ let e4 = s2.get(z);
126
+ if (e4 || (e4 = s2.get("all_sub_tables")), e4 && void 0 !== e4.canDelete && false === e4.canDelete && (u2 = false), e4 && void 0 !== e4.canDelete && true === e4.canDelete && e4.deleteRowIndexes)
127
+ if (e4.deleteRowIndexes.length > 0)
128
+ if (i2)
129
+ u2 = true;
130
+ else {
131
+ const t3 = function(e5) {
132
+ return e5 && e5.id ? e5.id : e5 && e5.ID ? e5.ID : void 0;
133
+ }(n2);
134
+ u2 = void 0 !== t3 && e4.deleteRowIndexes.indexOf(t3) >= 0;
233
135
  }
234
- }
235
- if (validateRules) {
236
- listViewOptions.value["validateRules"] = validateRules;
237
- } else {
238
- listViewOptions.value["validateRules"] = null;
239
- }
240
- }
241
- if (actionPermissionMap && actionPermissionMap != null) {
242
- let actionPermission = actionPermissionMap.get(prop);
243
- if (!actionPermission) {
244
- actionPermission = actionPermissionMap.get("all_sub_tables");
245
- }
246
- listViewOptions.value["actionPermission"] = actionPermission;
247
- }
248
- if (!listViewOptions.value["operations"]) {
249
- listViewOptions.value["operations"] = {};
250
- }
251
- const subTableOperations = getOperations();
252
- listViewOptions.value["operations"]["operation"] = subTableOperations;
253
- listViewOptions.value["subTableCanAdd"] = isShowAddWf();
254
- }
255
- function setGridToStore() {
256
- if (!pageContext.tableUuids) {
257
- pageContext.tableUuids = [];
258
- }
259
- if (pageContext.tableUuids.indexOf(configure.uuid) < 0) {
260
- pageContext.tableUuids.push(configure.uuid);
261
- }
262
- }
263
- function getOperations() {
264
- let operations = [];
265
- let isShowOperation = caculateShowCondition(props.pageContext, configure.props.base.showOperationCondition);
266
- if (isShowOperation && isShowAddWf()) {
267
- const addButton = {
268
- props: {
269
- elementType: "el-button",
270
- icon: "Plus",
271
- type: "primary",
272
- circle: true,
273
- size: "mini",
274
- permission: "true"
275
- },
276
- onClick: addSubTableData,
277
- isShow: isShowAdd
278
- };
279
- operations.push(addButton);
280
- }
281
- if (isShowOperation && isShowDeleteWf(null, null, null, null, null, true)) {
282
- const removeButton = {
283
- props: {
284
- elementType: "el-button",
285
- icon: "Minus",
286
- type: "danger",
287
- circle: true,
288
- size: "mini",
289
- permission: "true"
290
- },
291
- onClick: removeSubTableData,
292
- isShow: isShowDelete
293
- };
294
- operations.push(removeButton);
295
- }
296
- getOperationButtons(pageContext, configure, operations);
297
- return operations;
298
- }
299
- initializationSubTable();
300
- function getEntityId(row) {
301
- if (row && row.id) {
302
- return row.id;
303
- } else if (row && row.ID) {
304
- return row.ID;
305
- }
306
- }
307
- function isShowAddWf(originalValue, formatValue, row, column, rowIndex, isFormJudge) {
308
- const isShowOperation = caculateShowCondition(props.pageContext, configure.props.base.showOperationCondition);
309
- if (!isShowOperation) {
310
- return false;
311
- }
312
- const fieldPermissionMap = pageContext.fieldPermissionMap;
313
- const actionPermissionMap = pageContext.actionPermissionMap;
314
- let canAdd = true;
315
- if (fieldPermissionMap && fieldPermissionMap !== null) {
316
- const allFieldPermission = fieldPermissionMap.get("all_fields");
317
- if (typeof allFieldPermission !== "undefined" && allFieldPermission.canEdit === false && (allFieldPermission.rowIndexes === void 0 || allFieldPermission.rowIndexes === null || allFieldPermission.rowIndexes.length === 0)) {
318
- canAdd = false;
319
- }
320
- }
321
- if (canAdd === true && prop && actionPermissionMap && actionPermissionMap !== null) {
322
- let oneTableActionPermission = actionPermissionMap.get(prop);
323
- if (!oneTableActionPermission) {
324
- oneTableActionPermission = actionPermissionMap.get("all_sub_tables");
325
- }
326
- if (oneTableActionPermission && oneTableActionPermission.canAdd !== void 0 && oneTableActionPermission.canAdd === false) {
327
- canAdd = false;
328
- }
329
- }
330
- return canAdd;
136
+ else
137
+ u2 = false;
331
138
  }
332
- function isShowAdd(originalValue, formatValue, row, column, rowIndex, isFormJudge) {
333
- let canAdd = isShowAddWf();
334
- if (canAdd === true) {
335
- canAdd = caculateShowCondition(props.pageContext, configure.props.base.showAddBtnCondition, row);
336
- }
337
- return canAdd;
338
- }
339
- function isShowDeleteWf(originalValue, formatValue, row, column, rowIndex, isFormJudge) {
340
- const fieldPermissionMap = pageContext.fieldPermissionMap;
341
- const actionPermissionMap = pageContext.actionPermissionMap;
342
- let canDelete = true;
343
- if (fieldPermissionMap && fieldPermissionMap !== null) {
344
- const allFieldPermission = fieldPermissionMap.get("all_fields");
345
- if (typeof allFieldPermission !== "undefined" && allFieldPermission.canEdit === false && (allFieldPermission.rowIndexes === void 0 || allFieldPermission.rowIndexes === null || allFieldPermission.rowIndexes.length === 0)) {
346
- canDelete = false;
347
- }
348
- }
349
- if (canDelete === true && prop && actionPermissionMap && actionPermissionMap !== null) {
350
- let oneTableActionPermission = actionPermissionMap.get(prop);
351
- if (!oneTableActionPermission) {
352
- oneTableActionPermission = actionPermissionMap.get("all_sub_tables");
353
- }
354
- if (oneTableActionPermission && oneTableActionPermission.canDelete !== void 0 && oneTableActionPermission.canDelete === false) {
355
- canDelete = false;
356
- }
357
- if (oneTableActionPermission && oneTableActionPermission.canDelete !== void 0 && oneTableActionPermission.canDelete === true) {
358
- if (oneTableActionPermission.deleteRowIndexes) {
359
- if (oneTableActionPermission.deleteRowIndexes.length > 0) {
360
- if (isFormJudge) {
361
- canDelete = true;
362
- } else {
363
- const rowId = getEntityId(row);
364
- if (rowId !== void 0 && oneTableActionPermission.deleteRowIndexes.indexOf(rowId) >= 0) {
365
- canDelete = true;
366
- } else {
367
- canDelete = false;
368
- }
369
- }
370
- } else {
371
- canDelete = false;
372
- }
373
- }
374
- }
375
- }
376
- return canDelete;
377
- }
378
- function isShowDelete(originalValue, formatValue, row, column, rowIndex, isFormJudge) {
379
- let canDelete = isShowDeleteWf(originalValue, formatValue, row, column, rowIndex, isFormJudge);
380
- if (canDelete === true) {
381
- canDelete = caculateShowCondition(props.pageContext, configure.props.base.showDeleteBtnCondition, row);
382
- }
383
- return canDelete;
384
- }
385
- function addSubTableData(originalValue, formatValue, row, column, rowIndex) {
386
- gridRef.value.createRow(listCode, {}, { getDefaultValueFunc: getDefaultValue });
387
- }
388
- function removeSubTableData(originalValue, formatValue, row, column, rowIndex) {
389
- gridRef.value.deleteRow(rowIndex, listCode, false);
390
- }
391
- function changeGridData(gridData) {
392
- setVariableValue(entity, dynamicFields, gridData);
393
- console.log("changeGridData----gridData=", gridData, "entity=", entity);
394
- }
395
- function changeRowsPerpage(pageSize) {
396
- console.log("表单组件--Item--changeRowsPerpage==pageSize=", pageSize);
397
- if (!pageContext.subTablePageInfo) {
398
- pageContext.subTablePageInfo = {};
399
- }
400
- pageContext.subTablePageInfo[prop] = { pageSize };
401
- }
402
- function setSelectOptions(valueSetOptions) {
403
- const propName = valueSetOptions.key;
404
- const options = valueSetOptions.value;
405
- if (!pageContext.selectOptions) {
406
- pageContext.selectOptions = {};
407
- }
408
- pageContext.selectOptions[propName] = options;
409
- }
410
- function fnProhibitToEdit(data) {
411
- const myPageCode = pageContext.code;
412
- const eventPageInfo = myPageCode + "_";
413
- eventBus.$emit(eventPageInfo + "prohibit-edit", data);
414
- }
415
- function refresMainTableFields(entity2) {
416
- const dataModel2 = pageContext.entity.data;
417
- if (entity2) {
418
- for (const key in entity2) {
419
- dataModel2[key] = entity2[key];
420
- }
421
- }
422
- }
423
- function select(selection, row) {
424
- if (row !== void 0) {
425
- selections.value = selection;
426
- const params = {
427
- selection,
428
- row
429
- };
430
- gridSelectRecord(pageContext, configure, params);
431
- }
432
- }
433
- function selectAll(selection) {
434
- selections.value = selection;
435
- const params = {
436
- selection
437
- };
438
- gridSelectAllRecords(pageContext, configure, params);
439
- }
440
- function selectionChange(newSelection) {
441
- const params = {
442
- newSelection
443
- };
444
- gridSelectionChange(pageContext, configure, params);
445
- }
446
- function cellClickEvent(row, column, cell, event) {
447
- const params = {
448
- row,
449
- column,
450
- cell,
451
- event
452
- };
453
- cellClick(pageContext, configure, params);
454
- }
455
- function cellDblClickEvent(row, column, cell, event) {
456
- const params = {
457
- row,
458
- column,
459
- cell,
460
- event
461
- };
462
- cellDblClick(pageContext, configure, params);
463
- }
464
- function rowClickEvent(row, column, event) {
465
- const params = {
466
- row,
467
- column,
468
- event
469
- };
470
- rowClick(pageContext, configure, params);
471
- }
472
- function rowDblClickEvent(row, column, event) {
473
- const params = {
474
- row,
475
- column,
476
- event
477
- };
478
- rowDblClick(pageContext, configure, params);
479
- }
480
- function headerClickEvent(column, event) {
481
- const params = {
482
- column,
483
- event
484
- };
485
- headerClick(pageContext, configure, params);
486
- }
487
- function changeFormData(formData) {
488
- pageContext.entity.data = formData;
489
- }
490
- function validatorSunTableListData() {
491
- return gridRef.value.validatorSunTableListData();
492
- }
493
- function createRow() {
494
- return gridRef.value.createRow(listCode);
495
- }
496
- function getSelections() {
497
- return selections.value;
498
- }
499
- function getSelectionIds() {
500
- const dataIds = [];
501
- if (selections.value) {
502
- selections.value.forEach((item) => {
503
- dataIds.push(item.id ? item.id : item.ID ? item.ID : null);
504
- });
505
- }
506
- return dataIds;
507
- }
508
- function clearSelections() {
509
- selections.value = [];
510
- }
511
- function getTableConfigure() {
512
- return configure;
513
- }
514
- function getValue() {
515
- return getVariableValue(entity, dynamicFields);
516
- }
517
- function setValue(value) {
518
- return setVariableValue(entity, dynamicFields, value);
519
- }
520
- function refreshChildTableData(gridData) {
521
- setValue(gridData);
522
- setTimeout(() => {
523
- if (gridRef.value) {
524
- gridRef.value.refreshChildData(listCode, gridData, configure.props && configure.props.base && configure.props.base.subPaging === true);
525
- listViewOptions.value.extraParam["entityMap"] = pageContext.entity.data;
526
- }
527
- }, 10);
528
- }
529
- function getRowStyle(data) {
530
- const style = getRowStyleUtil(data, null, props);
531
- console.log("getRowStyle----style=", style);
532
- return style;
533
- }
534
- function getCellStyle(data) {
535
- return getCellStyleUtil(data, data.cellStyle, props);
536
- }
537
- function getTitleStyle(data) {
538
- const cellTitleStyle = data.titleStyle;
539
- const rowTitleStyle = props.configure.style.titleStyle;
540
- return getHeaderCellStyleUtil(data, { cellTitleStyle, titleStyle: rowTitleStyle }, props);
541
- }
542
- function getTableSelectOptions() {
543
- if (gridRef.value) {
544
- return gridRef.value.getTableSelectOptions(listCode);
545
- }
546
- }
547
- function dynamicControlTableEdit(pageContext2, customRules, listCode2) {
548
- if (gridRef.value) {
549
- gridRef.value.dynamicControlTableEdit(pageContext2, customRules, listCode2);
550
- }
551
- }
552
- function doLayout(hiddenColumns) {
553
- if (gridRef.value) {
554
- gridRef.value.doLayout(hiddenColumns);
555
- }
139
+ return u2;
140
+ }
141
+ function ve(e3, t2, n2, o2, a2, i2) {
142
+ let l2 = be(0, 0, n2, 0, 0, i2);
143
+ return true === l2 && (l2 = S(A.pageContext, N.props.base.showDeleteBtnCondition, n2)), l2;
144
+ }
145
+ function ge(e3, t2, n2, o2, a2) {
146
+ oe.value.createRow(E, {}, { getDefaultValueFunc: C });
147
+ }
148
+ function me(e3, t2, n2, o2, a2) {
149
+ oe.value.deleteRow(a2, E, false);
150
+ }
151
+ function he(e3) {
152
+ w(K, X, e3);
153
+ }
154
+ function Se(e3) {
155
+ H.subTablePageInfo || (H.subTablePageInfo = {}), H.subTablePageInfo[z] = { pageSize: e3 };
156
+ }
157
+ function we(e3) {
158
+ const t2 = e3.key, n2 = e3.value;
159
+ H.selectOptions || (H.selectOptions = {}), H.selectOptions[t2] = n2;
160
+ }
161
+ function xe(e3) {
162
+ const t2 = H.code + "_";
163
+ y.$emit(t2 + "prohibit-edit", e3);
164
+ }
165
+ function Te(e3) {
166
+ const t2 = H.entity.data;
167
+ if (e3)
168
+ for (const n2 in e3)
169
+ t2[n2] = e3[n2];
170
+ }
171
+ function De(e3, t2) {
172
+ if (void 0 !== t2) {
173
+ G.value = e3;
174
+ p(H, N, { selection: e3, row: t2 });
556
175
  }
557
- __expose({
558
- createRow,
559
- getSelections,
560
- getSelectionIds,
561
- clearSelections,
562
- getTableConfigure,
563
- validatorSunTableListData,
564
- getValue,
565
- setValue,
566
- getTableSelectOptions,
567
- dynamicControlTableEdit,
568
- doLayout
569
- });
570
- return (_ctx, _cache) => {
571
- const _component_super_grid = resolveComponent("super-grid");
572
- return openBlock(), createElementBlock("div", null, [
573
- listViewShowFlag.value ? (openBlock(), createBlock(_component_super_grid, {
574
- key: 0,
575
- ref_key: "gridRef",
576
- ref: gridRef,
577
- url: unref(baseURL) + "/dsc/commons/sub-table",
578
- options: listViewOptions.value,
579
- code: unref(listCode),
580
- settings: unref(superGridSetting),
581
- onSelect: select,
582
- onSelectAll: selectAll,
583
- onSelectionChange: selectionChange,
584
- onCellClick: cellClickEvent,
585
- onCellDblclick: cellDblClickEvent,
586
- onRowClick: rowClickEvent,
587
- onRowDblclick: rowDblClickEvent,
588
- onHeaderClick: headerClickEvent,
589
- onFnProhibitToEdit: fnProhibitToEdit,
590
- onChangeGridData: changeGridData,
591
- onReloadGrid: changeInitializationSubTable,
592
- onRefresMainTableFields: refresMainTableFields,
593
- onSetSelectOptions: setSelectOptions,
594
- onChangeRowsPerPage: changeRowsPerpage,
595
- onNewOpenGridDialog: unref(popupToPage),
596
- onChangeFormData: changeFormData
597
- }, null, 8, ["url", "options", "code", "settings", "onNewOpenGridDialog"])) : createCommentVNode("", true)
598
- ]);
599
- };
600
176
  }
601
- });
177
+ function Ce(e3) {
178
+ G.value = e3;
179
+ f(H, N, { selection: e3 });
180
+ }
181
+ function ye(e3) {
182
+ d(H, N, { newSelection: e3 });
183
+ }
184
+ function Pe(e3, t2, n2, o2) {
185
+ b(H, N, { row: e3, column: t2, cell: n2, event: o2 });
186
+ }
187
+ function Ie(e3, t2, n2, o2) {
188
+ v(H, N, { row: e3, column: t2, cell: n2, event: o2 });
189
+ }
190
+ function Re(e3, t2, n2) {
191
+ g(H, N, { row: e3, column: t2, event: n2 });
192
+ }
193
+ function _e(e3, t2, n2) {
194
+ m(H, N, { row: e3, column: t2, event: n2 });
195
+ }
196
+ function Oe(e3, t2) {
197
+ h(H, N, { column: e3, event: t2 });
198
+ }
199
+ function ke(e3) {
200
+ H.entity.data = e3;
201
+ }
202
+ function Me() {
203
+ return x(K, X);
204
+ }
205
+ function Fe(e3) {
206
+ return w(K, X, e3);
207
+ }
208
+ return n(() => {
209
+ const e3 = N.uuid, t2 = H.subTableWatchProps;
210
+ y.$on("_refreshSubTable_" + e3, (n2) => {
211
+ const o2 = n2.propName;
212
+ if (t2 && t2[e3] && t2[e3].length > 0) {
213
+ t2[e3].indexOf(o2) >= 0 && ae();
214
+ }
215
+ }), y.$on("_refreshSubTableHandle_" + e3, (e4) => {
216
+ ae();
217
+ }), y.$on("_refreshChildData_" + e3, (e4) => {
218
+ !function(e5) {
219
+ Fe(e5), setTimeout(() => {
220
+ oe.value && (oe.value.refreshChildData(E, e5, N.props && N.props.base && true === N.props.base.subPaging), te.value.extraParam.entityMap = H.entity.data);
221
+ }, 10);
222
+ }(e4);
223
+ }), y.$on(E + "-pickFileDone", (e4) => {
224
+ oe.value.pickFileDone(e4);
225
+ }), y.$on(E + "-scanDone", (e4) => {
226
+ oe.value.scanDone(e4);
227
+ }), te.value && te.value.configureObj.props.base && te.value.configureObj.props.base.isSafeDelete && ne("setSafeDeleteTableCode", te.value.extraParam.tableName);
228
+ }), o(() => {
229
+ const e3 = N.uuid;
230
+ y.$off("_refreshSubTable_" + e3), y.$off("_refreshSubTableHandle_" + e3), y.$off("_refreshChildData_" + e3), y.$off(E + "-pickFileDone"), y.$off(E + "-scanDone");
231
+ }), function() {
232
+ const e3 = le();
233
+ e3 ? re(e3) : (ie(e3), te.value.isPageInfo = false, te.value.subTableData = Me(), ce());
234
+ }(), $2({ createRow: function() {
235
+ return oe.value.createRow(E);
236
+ }, getSelections: function() {
237
+ return G.value;
238
+ }, getSelectionIds: function() {
239
+ const e3 = [];
240
+ return G.value && G.value.forEach((t2) => {
241
+ e3.push(t2.id ? t2.id : t2.ID ? t2.ID : null);
242
+ }), e3;
243
+ }, clearSelections: function() {
244
+ G.value = [];
245
+ }, getTableConfigure: function() {
246
+ return N;
247
+ }, validatorSunTableListData: function() {
248
+ return oe.value.validatorSunTableListData();
249
+ }, getValue: Me, setValue: Fe, getTableSelectOptions: function() {
250
+ if (oe.value)
251
+ return oe.value.getTableSelectOptions(E);
252
+ }, dynamicControlTableEdit: function(e3, t2, n2) {
253
+ oe.value && oe.value.dynamicControlTableEdit(e3, t2, n2);
254
+ }, doLayout: function(e3) {
255
+ oe.value && oe.value.doLayout(e3);
256
+ } }), (e3, t2) => {
257
+ const n2 = a("super-grid");
258
+ return i(), l("div", null, [Z.value ? (i(), s(n2, { key: 0, ref_key: "gridRef", ref: oe, url: u(Y) + "/dsc/commons/sub-table", options: te.value, code: u(E), settings: u(q), onSelect: De, onSelectAll: Ce, onSelectionChange: ye, onCellClick: Pe, onCellDblclick: Ie, onRowClick: Re, onRowDblclick: _e, onHeaderClick: Oe, onFnProhibitToEdit: xe, onChangeGridData: he, onReloadGrid: re, onRefresMainTableFields: Te, onSetSelectOptions: we, onChangeRowsPerPage: Se, onNewOpenGridDialog: u(P), onChangeFormData: ke }, null, 8, ["url", "options", "code", "settings", "onNewOpenGridDialog"])) : r("", true)]);
259
+ };
260
+ } });
602
261
  export {
603
- _sfc_main as default
262
+ $ as default
604
263
  };