super-page-runtime 2.1.92 → 2.1.95
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.
- package/dist/es/_virtual/_plugin-vue_export-helper.js +6 -7
- package/dist/es/assets/chart-themes/theme1.js +2 -6
- package/dist/es/assets/chart-themes/theme2.js +2 -6
- package/dist/es/assets/chart-themes/theme3.js +2 -6
- package/dist/es/components/runtime/utils/api/api-util.js +4 -7
- package/dist/es/components/runtime/utils/api/page-expose-util.js +137 -433
- package/dist/es/components/runtime/utils/assemblys-config.js +12 -366
- package/dist/es/components/runtime/utils/barcode-util.js +10 -33
- package/dist/es/components/runtime/utils/charts/chart-columnline-util.js +138 -303
- package/dist/es/components/runtime/utils/charts/chart-gauge-util.js +29 -66
- package/dist/es/components/runtime/utils/charts/chart-pie-util.js +71 -147
- package/dist/es/components/runtime/utils/charts/chart-radar-util.js +52 -122
- package/dist/es/components/runtime/utils/charts/chart-scatter-util.js +40 -98
- package/dist/es/components/runtime/utils/charts/chart-util.js +237 -478
- package/dist/es/components/runtime/utils/common-util.js +82 -152
- package/dist/es/components/runtime/utils/eventBus.js +3 -9
- package/dist/es/components/runtime/utils/events/event-util.js +361 -727
- package/dist/es/components/runtime/utils/events/print-label.js +73 -140
- package/dist/es/components/runtime/utils/events/standard-event.js +835 -2283
- package/dist/es/components/runtime/utils/events/validator-util.js +236 -555
- package/dist/es/components/runtime/utils/form/date-shortcuts.js +29 -88
- package/dist/es/components/runtime/utils/form/scan-util.js +60 -154
- package/dist/es/components/runtime/utils/global-refs.js +45 -69
- package/dist/es/components/runtime/utils/i18n-util.js +12 -20
- package/dist/es/components/runtime/utils/interfaces/page-design-types.js +2 -7
- package/dist/es/components/runtime/utils/page-helper-util.js +295 -603
- package/dist/es/components/runtime/utils/page-init-util.js +134 -369
- package/dist/es/components/runtime/utils/page-permission-util.js +24 -531
- package/dist/es/components/runtime/utils/page-store.js +8 -12
- package/dist/es/components/runtime/utils/store-util.js +9 -13
- package/dist/es/components/runtime/utils/store.js +2 -2
- package/dist/es/components/runtime/utils/table-utils.js +49 -84
- package/dist/es/components/runtime/utils/tree-utils.js +18 -36
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue2.js +19 -75
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue2.js +14 -46
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue2.js +37 -132
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue2.js +4 -18
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue2.js +17 -107
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +54 -198
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue.js +12 -42
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-breadcrumb.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +7 -60
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +48 -169
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +32 -107
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +43 -164
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +32 -115
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +32 -116
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +208 -439
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue.js +4 -42
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column-item.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue.js +8 -62
- package/dist/es/components/runtime/views/assemblys/chart/table/group-column.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue.js +63 -226
- package/dist/es/components/runtime/views/assemblys/chart/table/normal-column.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue.js +13 -62
- package/dist/es/components/runtime/views/assemblys/chart/table/table-pageination.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +168 -513
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +29 -139
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue.js +23 -125
- package/dist/es/components/runtime/views/assemblys/common/remove-signer-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.js +16 -102
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +18 -81
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue2.js +17 -82
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue2.js +14 -86
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue2.js +21 -79
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue2.js +16 -61
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue2.js +10 -37
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue2.js +38 -127
- package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/container/tools/tools-runtime.vue2.js +28 -76
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +61 -178
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +311 -800
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +251 -592
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +43 -115
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +56 -216
- package/dist/es/components/runtime/views/assemblys/error-render.vue.js +3 -21
- package/dist/es/components/runtime/views/assemblys/error-render.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +44 -154
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue.js +36 -98
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +54 -200
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +69 -239
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +28 -98
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue2.js +22 -59
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +52 -173
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +22 -103
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +58 -249
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +34 -174
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +28 -107
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue.js +4 -4
- package/dist/es/components/runtime/views/assemblys/form/placeholder/placeholder-runtime.vue2.js +13 -50
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +66 -189
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +91 -243
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +82 -261
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue2.js +13 -57
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +30 -155
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue2.js +41 -129
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +22 -107
- package/dist/es/components/runtime/views/assemblys/object-render.vue.js +133 -252
- package/dist/es/components/runtime/views/assemblys/object-render.vue2.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/picture-flow/pictureflow-runtime.vue2.js +19 -46
- package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/text-history/textflow-runtime.vue2.js +22 -49
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue2.js +21 -58
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue.js +2 -2
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-node/workflownode-runtime.vue2.js +16 -53
- package/dist/es/components/runtime/views/super-page-dialog.vue.js +18 -134
- package/dist/es/components/runtime/views/super-page-dialog.vue2.js +2 -2
- package/dist/es/components/runtime/views/super-page.vue.js +232 -708
- package/dist/es/components/runtime/views/super-page.vue2.js +2 -2
- package/dist/es/i18n/langs/cn.js +2 -55
- package/dist/es/i18n/langs/en.js +2 -55
- package/package.json +74 -73
|
@@ -1,823 +1,334 @@
|
|
|
1
|
-
import { defineComponent, ref, onMounted, watch, onUnmounted, resolveComponent, openBlock, createElementBlock, createVNode, unref } from "vue";
|
|
2
|
-
import { setTableEvents, canExecuteButton, doAfterClickEvent, doBeforeClickEvent, getEventNameByType, getEventFuncByType, getHandleEvent, gridSelectRecord, gridSelectAllRecords, gridSelectionChange, cellClick, cellDblClick, rowClick, rowDblClick, headerClick } from "../../../../utils/events/event-util.js";
|
|
3
|
-
import { getBaseUrl, getListCode, getRealRestApiPath, isWorkflowPage, isVariableInvalidValue } from "../../../../utils/common-util.js";
|
|
4
|
-
import { getAdditionalParamMap, getSaveFormRequestWithRow, standardEvents } from "../../../../utils/events/standard-event.js";
|
|
5
|
-
import { isPromise } from "agilebuilder-ui/src/utils/common-util";
|
|
6
|
-
import { getOperationButtons, popupToPage } from "../../../../utils/table-utils.js";
|
|
7
|
-
import
|
|
8
|
-
import { getDefaultValue } from "../../../../utils/page-init-util.js";
|
|
9
|
-
import { decomposeVariable
|
|
10
|
-
import { getRowStyleUtil, getCellStyleUtil, getHeaderCellStyleUtil } from "../../chart/table/chart-table-util.js";
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
const gridRef = ref();
|
|
45
|
-
const urlToListData = getUrlToListData();
|
|
46
|
-
const listCode = getListCode(pageContext.code, pageContext.version, configure.uuid);
|
|
47
|
-
const myPageCode = pageContext.code;
|
|
48
|
-
const eventPageInfo = myPageCode + "_" + listCode;
|
|
49
|
-
const selections = ref([]);
|
|
50
|
-
const listToolbarFormData = pageContext.entity.page;
|
|
51
|
-
const searchFormInfo = ref({ data: [] });
|
|
52
|
-
const superGridItems = pageContext.superGridItems;
|
|
53
|
-
const superGridSetting = superGridItems ? superGridItems[configure.uuid] : null;
|
|
54
|
-
console.log("superGridSetting1111===", superGridItems, superGridSetting);
|
|
55
|
-
const isCanShowMobileSearch = ref(false);
|
|
56
|
-
const $emit = __emit;
|
|
57
|
-
onMounted(() => {
|
|
58
|
-
window.addEventListener("message", recieveMessage);
|
|
59
|
-
eventBus.$on(
|
|
60
|
-
eventPageInfo + "-close-component-page-dialog",
|
|
61
|
-
function({ jumpInfo, popEntity, popPageCode }) {
|
|
62
|
-
gridRef.value.closePageDialog({
|
|
63
|
-
entity: popEntity,
|
|
64
|
-
pageCode: popPageCode,
|
|
65
|
-
jumpInfo
|
|
66
|
-
});
|
|
67
|
-
}
|
|
68
|
-
);
|
|
69
|
-
eventBus.$on(eventPageInfo + "_close-dialog-get-entity", () => {
|
|
70
|
-
eventBus.$emit(eventPageInfo + "_close-super-dialog");
|
|
71
|
-
});
|
|
72
|
-
eventBus.$on(listCode + "-pickFileDone", (data) => {
|
|
73
|
-
console.log("superPage5555---listCode---pickFileDone--listCode=", listCode, "data=", data);
|
|
74
|
-
gridRef.value.pickFileDone(data);
|
|
75
|
-
});
|
|
76
|
-
eventBus.$on(listCode + "-scanDone", (data) => {
|
|
77
|
-
console.log("superPage5555---listCode---scanDone--listCode=", listCode, "data=", data);
|
|
78
|
-
gridRef.value.scanDone(data);
|
|
79
|
-
});
|
|
80
|
-
listOptions.value["formSetMaxHeight"] = getComponentHeight();
|
|
81
|
-
if (listOptions.value && listOptions.value.configureObj.props.base && listOptions.value.configureObj.props.base.isSafeDelete) {
|
|
82
|
-
$emit("setSafeDeleteTableCode", listOptions.value.extraParam.tableName);
|
|
83
|
-
}
|
|
84
|
-
});
|
|
85
|
-
watch(
|
|
86
|
-
() => props.pageContext.searchFormData,
|
|
87
|
-
(searchFormData) => {
|
|
88
|
-
searchFormInfo.value.data = searchFormData;
|
|
89
|
-
}
|
|
90
|
-
);
|
|
91
|
-
watch(
|
|
92
|
-
() => props.pageContext.entity.data,
|
|
93
|
-
(searchFormData) => {
|
|
94
|
-
searchGridData(props.pageContext.entity.data);
|
|
95
|
-
}
|
|
96
|
-
);
|
|
97
|
-
onUnmounted(() => {
|
|
98
|
-
eventBus.$off(eventPageInfo + "-close-component-page-dialog");
|
|
99
|
-
eventBus.$off(eventPageInfo + "_close-dialog-get-entity");
|
|
100
|
-
eventBus.$off(listCode + "-pickFileDone");
|
|
101
|
-
eventBus.$off(listCode + "-scanDone");
|
|
102
|
-
});
|
|
103
|
-
function getUrlToListData() {
|
|
104
|
-
let urlToListData2 = baseURL + "/dsc/commons/list";
|
|
105
|
-
if (urlToListData2) {
|
|
106
|
-
urlToListData2 = getRealRestApiPath(urlToListData2, systemCode, backendUrl, pageContext.isTest);
|
|
107
|
-
}
|
|
108
|
-
return urlToListData2;
|
|
109
|
-
}
|
|
110
|
-
function getOptions() {
|
|
111
|
-
const systemCode2 = pageContext.systemCode;
|
|
112
|
-
const permissionPrefix = pageContext.code;
|
|
113
|
-
let initSearchForm = configure.props && configure.props.dataOrigin && configure.props.dataOrigin.sqlFilterCondition !== "[]" ? configure.props.dataOrigin.sqlFilterCondition : null;
|
|
114
|
-
if (typeof initSearchForm === "undefined" || initSearchForm === null) {
|
|
115
|
-
initSearchForm = [];
|
|
116
|
-
}
|
|
117
|
-
const options = {
|
|
118
|
-
isSql: true,
|
|
119
|
-
extraParam: {
|
|
120
|
-
beanName: pageContext.beanName,
|
|
121
|
-
functionCode: permissionPrefix + ".listData",
|
|
122
|
-
tableName,
|
|
123
|
-
systemCode: systemCode2,
|
|
124
|
-
// 系统编码传给列表数据后台请求
|
|
125
|
-
pageCode: pageContext.code,
|
|
126
|
-
pageVersion: pageContext.version
|
|
127
|
-
},
|
|
128
|
-
initSearchForm,
|
|
129
|
-
lineEditOptions: {
|
|
130
|
-
aftersaveIsCreateRow: false,
|
|
131
|
-
autoSave: false,
|
|
132
|
-
enter: enterSave,
|
|
133
|
-
esc: escRestorRow
|
|
134
|
-
},
|
|
135
|
-
indexContinuous: configure.props && configure.props.otherSettings ? configure.props.otherSettings.serialNumberContinuous : false,
|
|
136
|
-
initSearch: configure.props && configure.props.dataOrigin.initializationQuery === false ? false : true,
|
|
137
|
-
// 初始化时是否查询,默认是查询
|
|
138
|
-
resizeHeight: resizeListHeight,
|
|
139
|
-
pageCode: pageContext.code,
|
|
140
|
-
pageVersion: pageContext.version,
|
|
141
|
-
// pageHeight: pageHeight, // 页面的高度 //TODO: pageHeight如何获得,页面高度,计算列表高度应该会用
|
|
142
|
-
additionalParamMap: getAdditionalParamMap(pageContext),
|
|
143
|
-
// 将路由参数传给列表组件
|
|
144
|
-
showOverflowTooltip: !!(configure.props && configure.props.otherSettings && (configure.props.otherSettings.isBreakLine === void 0 || configure.props.otherSettings.isBreakLine === false)),
|
|
145
|
-
// 单元格内容是否换行显示
|
|
146
|
-
isEnableEnterEvent: configure.props && configure.props.otherSettings && configure.props.otherSettings.isEnableEnterEvent,
|
|
147
|
-
// 是否启用回车事件
|
|
148
|
-
isWithDataPermission: configure.props && configure.props.otherSettings && configure.props.otherSettings.isWithDataPermission ? configure.props.otherSettings.isWithDataPermission : false,
|
|
149
|
-
pageDevMode: false,
|
|
150
|
-
isWorkflowEntity: isWorkflowPage(pageContext),
|
|
151
|
-
tableClass: runtimeClass,
|
|
152
|
-
tableStyle: runtimeStyle,
|
|
153
|
-
pageContext,
|
|
154
|
-
configureObj: configure,
|
|
155
|
-
backendUrl: baseURL,
|
|
156
|
-
cellStyleRender: getCellStyle,
|
|
157
|
-
rowStyleRender: getRowStyle,
|
|
158
|
-
titleStyleRender: getTitleStyle
|
|
159
|
-
};
|
|
160
|
-
setOperationButtons(options);
|
|
161
|
-
setSortInfo(options);
|
|
162
|
-
if (configure.props.linkages && configure.props.linkages.length > 0) {
|
|
163
|
-
configure.props.linkages.forEach((linkage) => {
|
|
164
|
-
const variablePath = decomposeVariable(linkage.fieldName);
|
|
165
|
-
if (variablePath && variablePath.length > 1) {
|
|
166
|
-
linkageVariable.push(variablePath[1]);
|
|
1
|
+
import { defineComponent as e, ref as t, onMounted as n, watch as o, onUnmounted as i, resolveComponent as a, openBlock as l, createElementBlock as r, createVNode as u, unref as s } from "vue";
|
|
2
|
+
import { setTableEvents as c, canExecuteButton as p, doAfterClickEvent as f, doBeforeClickEvent as d, getEventNameByType as g, getEventFuncByType as m, getHandleEvent as v, gridSelectRecord as h, gridSelectAllRecords as b, gridSelectionChange as w, cellClick as S, cellDblClick as C, rowClick as y, rowDblClick as x, headerClick as E } from "../../../../utils/events/event-util.js";
|
|
3
|
+
import { getBaseUrl as D, getListCode as O, getRealRestApiPath as k, isWorkflowPage as I, isVariableInvalidValue as T } from "../../../../utils/common-util.js";
|
|
4
|
+
import { getAdditionalParamMap as R, getSaveFormRequestWithRow as V, standardEvents as j } from "../../../../utils/events/standard-event.js";
|
|
5
|
+
import { isPromise as N } from "agilebuilder-ui/src/utils/common-util";
|
|
6
|
+
import { getOperationButtons as P, popupToPage as U } from "../../../../utils/table-utils.js";
|
|
7
|
+
import B from "../../../../utils/eventBus.js";
|
|
8
|
+
import { getDefaultValue as M } from "../../../../utils/page-init-util.js";
|
|
9
|
+
import { decomposeVariable as $, getSizeConfig as F } from "../../../../utils/page-helper-util.js";
|
|
10
|
+
import { getRowStyleUtil as _, getCellStyleUtil as L, getHeaderCellStyleUtil as A } from "../../chart/table/chart-table-util.js";
|
|
11
|
+
const H = e({ __name: "main-table-runtime", props: { pageContext: {}, configure: {} }, emits: ["setSafeDeleteTableCode"], setup(e2, { expose: H2, emit: z }) {
|
|
12
|
+
const W = e2, q = W.pageContext;
|
|
13
|
+
let G = W.configure;
|
|
14
|
+
const Q = t({});
|
|
15
|
+
q.isTest ? Q.value = W.configure.runtime ? W.configure.runtime : {} : q.tableRuntimes && q.tableRuntimes[G.uuid] && (G = JSON.parse(q.tableRuntimes[G.uuid].configure), Q.value = G.runtime ? G.runtime : {});
|
|
16
|
+
const J = Q.value.style, X = Q.value.class, K = q.systemCode, Y = q.backendUrl, Z = G.props && G.props.dataOrigin && G.props.dataOrigin.tableName;
|
|
17
|
+
let ee = D(q.backendUrl, q.isTest);
|
|
18
|
+
ee || (ee = window.$vueApp.config.globalProperties.baseURL);
|
|
19
|
+
const te = t({}), ne = [], oe = t({});
|
|
20
|
+
oe.value = function() {
|
|
21
|
+
const e3 = q.systemCode, t2 = q.code;
|
|
22
|
+
let n2 = G.props && G.props.dataOrigin && "[]" !== G.props.dataOrigin.sqlFilterCondition ? G.props.dataOrigin.sqlFilterCondition : null;
|
|
23
|
+
null == n2 && (n2 = []);
|
|
24
|
+
const i2 = { isSql: true, extraParam: { beanName: q.beanName, functionCode: t2 + ".listData", tableName: Z, systemCode: e3, pageCode: q.code, pageVersion: q.version }, initSearchForm: n2, lineEditOptions: { aftersaveIsCreateRow: false, autoSave: false, enter: me, esc: Se }, indexContinuous: !(!G.props || !G.props.otherSettings) && G.props.otherSettings.serialNumberContinuous, initSearch: !G.props || false !== G.props.dataOrigin.initializationQuery, resizeHeight: ke, pageCode: q.code, pageVersion: q.version, additionalParamMap: R(q), showOverflowTooltip: !(!G.props || !G.props.otherSettings || void 0 !== G.props.otherSettings.isBreakLine && false !== G.props.otherSettings.isBreakLine), isEnableEnterEvent: G.props && G.props.otherSettings && G.props.otherSettings.isEnableEnterEvent, isWithDataPermission: !!(G.props && G.props.otherSettings && G.props.otherSettings.isWithDataPermission) && G.props.otherSettings.isWithDataPermission, pageDevMode: false, isWorkflowEntity: I(q), tableClass: X, tableStyle: J, pageContext: q, configureObj: G, backendUrl: ee, cellStyleRender: Ae, rowStyleRender: Le, titleStyleRender: He };
|
|
25
|
+
(function(e4) {
|
|
26
|
+
const t3 = [];
|
|
27
|
+
e4.operations || (e4.operations = {});
|
|
28
|
+
P(q, G, t3, he), e4.operations.operation = t3;
|
|
29
|
+
})(i2), function(e4) {
|
|
30
|
+
G.props && G.props.dataOrigin && G.props.dataOrigin.sortFields && (e4.initSortInfo = [], this.colSetting.options.sortFields.forEach((t3) => {
|
|
31
|
+
const n3 = { order: t3.sortOrder };
|
|
32
|
+
n3.prop = t3.propDbName, e4.initSortInfo.push(n3);
|
|
33
|
+
}));
|
|
34
|
+
}(i2), G.props.linkages && G.props.linkages.length > 0 && (G.props.linkages.forEach((e4) => {
|
|
35
|
+
const t3 = $(e4.fieldName);
|
|
36
|
+
t3 && t3.length > 1 && ne.push(t3[1]);
|
|
37
|
+
}), ne.length > 0 && function() {
|
|
38
|
+
if (W.pageContext.toolsInputComponents && W.pageContext.toolsInputComponents.length > 0) {
|
|
39
|
+
let e4 = [];
|
|
40
|
+
if (W.pageContext.toolsInputComponents.forEach((t3) => {
|
|
41
|
+
if (G.props.linkages.some((e5) => e5.fieldName === t3.prop) && t3.defaultValue) {
|
|
42
|
+
const n3 = $(t3.prop);
|
|
43
|
+
n3 && n3.length > 1 && e4.push(n3[1]);
|
|
167
44
|
}
|
|
168
|
-
})
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
function setSortInfo(options) {
|
|
178
|
-
if (configure.props && configure.props.dataOrigin && configure.props.dataOrigin.sortFields) {
|
|
179
|
-
options.initSortInfo = [];
|
|
180
|
-
this.colSetting.options.sortFields.forEach((item) => {
|
|
181
|
-
const sortInfo = {
|
|
182
|
-
order: item.sortOrder
|
|
183
|
-
};
|
|
184
|
-
sortInfo["prop"] = item.propDbName;
|
|
185
|
-
options.initSortInfo.push(sortInfo);
|
|
186
|
-
});
|
|
187
|
-
}
|
|
188
|
-
}
|
|
189
|
-
function setOperationButtons(options) {
|
|
190
|
-
const operationButtons = [];
|
|
191
|
-
if (!options.operations) {
|
|
192
|
-
options.operations = {};
|
|
193
|
-
}
|
|
194
|
-
getOperationButtons(pageContext, configure, operationButtons, getOperationButtonClickEvent);
|
|
195
|
-
options.operations.operation = operationButtons;
|
|
196
|
-
}
|
|
197
|
-
function setTreeSetting(options) {
|
|
198
|
-
const dataOrigin = configure.props ? configure.props.dataOrigin : {};
|
|
199
|
-
if (dataOrigin.treeTable) {
|
|
200
|
-
let parentPropDbName;
|
|
201
|
-
const parentPropInfo = dataOrigin.rowKey;
|
|
202
|
-
if (parentPropInfo && parentPropInfo.indexOf("~~") > 0) {
|
|
203
|
-
parentPropDbName = parentPropInfo.substring(parentPropInfo.indexOf("~~") + 2);
|
|
204
|
-
} else {
|
|
205
|
-
parentPropDbName = parentPropInfo;
|
|
206
|
-
}
|
|
207
|
-
options.parentProp = parentPropDbName;
|
|
208
|
-
if (options.parentProp) {
|
|
209
|
-
const isLazy = dataOrigin.lazy;
|
|
210
|
-
const defaultExpandAll = dataOrigin.defaultExpandAll;
|
|
211
|
-
if (isLazy === void 0 || isLazy === null) {
|
|
212
|
-
options.lazy = true;
|
|
213
|
-
} else {
|
|
214
|
-
options.lazy = isLazy;
|
|
215
|
-
}
|
|
216
|
-
if (defaultExpandAll === void 0 || defaultExpandAll === null) {
|
|
217
|
-
options.defaultExpandAll = false;
|
|
218
|
-
} else {
|
|
219
|
-
options.defaultExpandAll = defaultExpandAll;
|
|
220
|
-
}
|
|
221
|
-
const listViewTreeTableSetting = {
|
|
222
|
-
parentProp: parentPropDbName,
|
|
223
|
-
lazy: options.lazy,
|
|
224
|
-
defaultExpandAll: options.defaultExpandAll
|
|
225
|
-
};
|
|
226
|
-
options.extraParam.listViewTreeSetting = JSON.stringify(listViewTreeTableSetting);
|
|
227
|
-
options.subRowUrl = baseURL + "/dsc/commons/list-subs";
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
}
|
|
231
|
-
function setGridEvents(options) {
|
|
232
|
-
const tableEvents = configure.runtime && configure.runtime.events ? configure.runtime.events : [];
|
|
233
|
-
setTableEvents(options, tableEvents, pageContext, configure);
|
|
234
|
-
const customEvents = pageContext.customEvents;
|
|
235
|
-
if (customEvents) {
|
|
236
|
-
options.eventCallBack = customEvents;
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
function enterSave({ rowIndex, column, row, orgRow }) {
|
|
240
|
-
saveRow(null, null, row, column, rowIndex);
|
|
241
|
-
}
|
|
242
|
-
function saveRow(originalValue, formatValue, row, column, rowIndex) {
|
|
243
|
-
const buttonConfigure = operationButtonObj.value["lineEditSave"];
|
|
244
|
-
const tableConfigure = configure;
|
|
245
|
-
buttonConfigure.props.base.tableUuid = tableConfigure.uuid;
|
|
246
|
-
listOptions.value["lineEditOptions"]["beforeSave"] = beforeSaveRow;
|
|
247
|
-
pageContext.editData = row;
|
|
248
|
-
canExecuteButton({ pageContext, configureObj: buttonConfigure }).then((result) => {
|
|
249
|
-
if (result["canExecute"] === true) {
|
|
250
|
-
listOptions.value["lineEditOptions"]["saveRow"] = saveLineEditRow;
|
|
251
|
-
gridRef.value.saveRow(rowIndex, listCode).then(() => {
|
|
252
|
-
const otherParams = {
|
|
253
|
-
originalValue,
|
|
254
|
-
formatValue,
|
|
255
|
-
row,
|
|
256
|
-
column,
|
|
257
|
-
rowIndex
|
|
258
|
-
};
|
|
259
|
-
doAfterClickEvent(pageContext, buttonConfigure, otherParams);
|
|
45
|
+
}), 0 === e4.length)
|
|
46
|
+
We();
|
|
47
|
+
else {
|
|
48
|
+
const t3 = ze();
|
|
49
|
+
e4 = e4.filter((e5) => T(t3, e5)), 0 === e4.length ? (Oe(t3), We()) : ne.forEach((t4) => {
|
|
50
|
+
o(() => W.pageContext.entity.page[t4], () => {
|
|
51
|
+
const t5 = ze();
|
|
52
|
+
0 === e4.length ? Oe(t5) : (e4 = e4.filter((e5) => T(t5, e5)), 0 === e4.length && Oe(t5));
|
|
53
|
+
}, { immediate: true });
|
|
260
54
|
});
|
|
261
55
|
}
|
|
262
|
-
}).finally(() => {
|
|
263
|
-
pageContext.editData = null;
|
|
264
|
-
});
|
|
265
|
-
}
|
|
266
|
-
function getOperationButtonClickEvent(buttonConfigure) {
|
|
267
|
-
if (!buttonConfigure) {
|
|
268
|
-
return;
|
|
269
56
|
}
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
onClick = deleteRow;
|
|
282
|
-
}
|
|
283
|
-
if (!onClick) {
|
|
284
|
-
const eventFunc = getEventFuncByType(pageContext, buttonConfigure.events, "click");
|
|
285
|
-
onClick = eventFunc;
|
|
57
|
+
}());
|
|
58
|
+
return function(e4) {
|
|
59
|
+
const t3 = G.props ? G.props.dataOrigin : {};
|
|
60
|
+
if (t3.treeTable) {
|
|
61
|
+
let n3;
|
|
62
|
+
const o2 = t3.rowKey;
|
|
63
|
+
if (n3 = o2 && o2.indexOf("~~") > 0 ? o2.substring(o2.indexOf("~~") + 2) : o2, e4.parentProp = n3, e4.parentProp) {
|
|
64
|
+
const o3 = t3.lazy, i3 = t3.defaultExpandAll;
|
|
65
|
+
e4.lazy = null == o3 || o3, e4.defaultExpandAll = null != i3 && i3;
|
|
66
|
+
const a2 = { parentProp: n3, lazy: e4.lazy, defaultExpandAll: e4.defaultExpandAll };
|
|
67
|
+
e4.extraParam.listViewTreeSetting = JSON.stringify(a2), e4.subRowUrl = ee + "/dsc/commons/list-subs";
|
|
286
68
|
}
|
|
287
|
-
} else {
|
|
288
|
-
operationButtonObj.value[buttonConfigure.uuid] = buttonConfigure;
|
|
289
|
-
onClick = customButtonClick;
|
|
290
69
|
}
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
const
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
70
|
+
}(i2), function(e4) {
|
|
71
|
+
const t3 = G.runtime && G.runtime.events ? G.runtime.events : [];
|
|
72
|
+
c(e4, t3, q, G);
|
|
73
|
+
const n3 = q.customEvents;
|
|
74
|
+
n3 && (e4.eventCallBack = n3);
|
|
75
|
+
}(i2), i2;
|
|
76
|
+
}();
|
|
77
|
+
const ie = t(), ae = function() {
|
|
78
|
+
let e3 = ee + "/dsc/commons/list";
|
|
79
|
+
e3 && (e3 = k(e3, K, Y, q.isTest));
|
|
80
|
+
return e3;
|
|
81
|
+
}(), le = O(q.code, q.version, G.uuid), re = q.code + "_" + le, ue = t([]), se = q.entity.page, ce = t({ data: [] }), pe = q.superGridItems, fe = pe ? pe[G.uuid] : null, de = t(false), ge = z;
|
|
82
|
+
function me({ rowIndex: e3, column: t2, row: n2, orgRow: o2 }) {
|
|
83
|
+
ve(null, null, n2, t2, e3);
|
|
84
|
+
}
|
|
85
|
+
function ve(e3, t2, n2, o2, i2) {
|
|
86
|
+
const a2 = te.value.lineEditSave, l2 = G;
|
|
87
|
+
a2.props.base.tableUuid = l2.uuid, oe.value.lineEditOptions.beforeSave = be, q.editData = n2, p({ pageContext: q, configureObj: a2 }).then((l3) => {
|
|
88
|
+
true === l3.canExecute && (oe.value.lineEditOptions.saveRow = we, ie.value.saveRow(i2, le).then(() => {
|
|
89
|
+
f(q, a2, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
90
|
+
}));
|
|
91
|
+
}).finally(() => {
|
|
92
|
+
q.editData = null;
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
function he(e3) {
|
|
96
|
+
if (!e3)
|
|
97
|
+
return;
|
|
98
|
+
let t2;
|
|
99
|
+
const n2 = g(e3.events, "click");
|
|
100
|
+
if (n2) {
|
|
101
|
+
if (te.value[n2] = e3, "lineEditSave" === n2 ? t2 = ve : "restoreEdit" === n2 ? t2 = Ce : "lineEditUpdate" === n2 ? t2 = ye : "lineEditDelete" === n2 && (t2 = Ee), !t2) {
|
|
102
|
+
t2 = m(q, e3.events, "click");
|
|
103
|
+
}
|
|
104
|
+
} else
|
|
105
|
+
te.value[e3.uuid] = e3, t2 = Te;
|
|
106
|
+
return t2;
|
|
107
|
+
}
|
|
108
|
+
function be({ row: e3, columns: t2, additionalParamMap: n2 }) {
|
|
109
|
+
const o2 = te.value.lineEditSave, i2 = G;
|
|
110
|
+
o2.props.base.tableUuid = i2.uuid;
|
|
111
|
+
return d(q, o2, { row: e3, columns: t2 });
|
|
112
|
+
}
|
|
113
|
+
function we({ row: e3, columns: t2, dataTypeMap: n2, dynamicColumnInfo: o2, additionalParamMap: i2, mainDefaultValueColumns: a2 }) {
|
|
114
|
+
const l2 = te.value.lineEditSave, r2 = G;
|
|
115
|
+
return l2.props.base.tableUuid = r2.uuid, new Promise((t3, n3) => {
|
|
116
|
+
const i3 = { tableName: r2.props.dataOrigin.tableName };
|
|
117
|
+
V(q, l2, "/dsc/commons", false, a2, o2, e3, i3).then((e4) => {
|
|
118
|
+
t3(e4 ? e4.entity : {});
|
|
119
|
+
}).catch((e4) => {
|
|
120
|
+
n3(e4);
|
|
334
121
|
});
|
|
335
|
-
}
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
const beforeClickResult = doBeforeClickEvent(pageContext, buttonConfigure, otherParams);
|
|
384
|
-
if (!beforeClickResult) {
|
|
385
|
-
return;
|
|
386
|
-
}
|
|
387
|
-
if (isPromise(beforeClickResult)) {
|
|
388
|
-
beforeClickResult.then((result) => {
|
|
389
|
-
if (result) {
|
|
390
|
-
editRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure);
|
|
391
|
-
}
|
|
392
|
-
});
|
|
393
|
-
} else {
|
|
394
|
-
editRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure);
|
|
395
|
-
}
|
|
396
|
-
}
|
|
397
|
-
function editRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure) {
|
|
398
|
-
pageContext.editData = row;
|
|
399
|
-
canExecuteButton({ pageContext, configureObj: buttonConfigure }).then((result) => {
|
|
400
|
-
if (result["canExecute"] === true) {
|
|
401
|
-
gridRef.value.editRow(rowIndex, listCode);
|
|
402
|
-
const afterOtherParams = {
|
|
403
|
-
originalValue,
|
|
404
|
-
formatValue,
|
|
405
|
-
row,
|
|
406
|
-
column,
|
|
407
|
-
rowIndex
|
|
408
|
-
};
|
|
409
|
-
doAfterClickEvent(pageContext, configure, afterOtherParams);
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
function Se({ rowIndex: e3, column: t2, row: n2, orgRow: o2 }) {
|
|
125
|
+
Ce(null, null, n2, t2, e3);
|
|
126
|
+
}
|
|
127
|
+
function Ce(e3, t2, n2, o2, i2) {
|
|
128
|
+
const a2 = te.value.restoreEdit, l2 = G;
|
|
129
|
+
a2.props.base.tableUuid = l2.uuid;
|
|
130
|
+
const r2 = d(q, a2, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
131
|
+
if (!r2)
|
|
132
|
+
return;
|
|
133
|
+
N(r2) ? r2.then((e4) => {
|
|
134
|
+
e4 && ie.value.restoreRow(i2, le);
|
|
135
|
+
}) : ie.value.restoreRow(i2, le);
|
|
136
|
+
f(q, G, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
137
|
+
}
|
|
138
|
+
function ye(e3, t2, n2, o2, i2) {
|
|
139
|
+
const a2 = te.value.lineEditUpdate, l2 = G;
|
|
140
|
+
a2.props.base.tableUuid = l2.uuid;
|
|
141
|
+
const r2 = d(q, a2, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
142
|
+
r2 && (N(r2) ? r2.then((l3) => {
|
|
143
|
+
l3 && xe(e3, t2, n2, o2, i2, a2);
|
|
144
|
+
}) : xe(e3, t2, n2, o2, i2, a2));
|
|
145
|
+
}
|
|
146
|
+
function xe(e3, t2, n2, o2, i2, a2) {
|
|
147
|
+
q.editData = n2, p({ pageContext: q, configureObj: a2 }).then((a3) => {
|
|
148
|
+
if (true === a3.canExecute) {
|
|
149
|
+
ie.value.editRow(i2, le);
|
|
150
|
+
f(q, G, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
151
|
+
}
|
|
152
|
+
}).finally(() => {
|
|
153
|
+
q.editData = null;
|
|
154
|
+
});
|
|
155
|
+
}
|
|
156
|
+
function Ee(e3, t2, n2, o2, i2) {
|
|
157
|
+
const a2 = te.value.lineEditDelete, l2 = G;
|
|
158
|
+
a2.props.base.tableUuid = l2.uuid;
|
|
159
|
+
const r2 = d(q, a2, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
160
|
+
r2 && (N(r2) ? r2.then((l3) => {
|
|
161
|
+
l3 && De(e3, t2, n2, o2, i2, a2);
|
|
162
|
+
}) : De(e3, t2, n2, o2, i2, a2));
|
|
163
|
+
}
|
|
164
|
+
function De(e3, t2, n2, o2, i2, a2) {
|
|
165
|
+
if (n2.id || n2.ID)
|
|
166
|
+
q.editData = n2, p({ pageContext: q, configureObj: a2 }).then((e4) => {
|
|
167
|
+
if (true === e4.canExecute) {
|
|
168
|
+
const e5 = [];
|
|
169
|
+
n2.id ? e5.push(n2.id) : e5.push(n2.ID), j.delete({ pageContext: q, configureObj: a2, ids: e5 });
|
|
410
170
|
}
|
|
411
171
|
}).finally(() => {
|
|
412
|
-
|
|
172
|
+
q.editData = null;
|
|
413
173
|
});
|
|
174
|
+
else {
|
|
175
|
+
Ce(e3, t2, n2, o2, i2);
|
|
176
|
+
f(q, G, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2 });
|
|
414
177
|
}
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
beforeClickResult.then((result) => {
|
|
432
|
-
if (result) {
|
|
433
|
-
deleteRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure);
|
|
434
|
-
}
|
|
435
|
-
});
|
|
436
|
-
} else {
|
|
437
|
-
deleteRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure);
|
|
438
|
-
}
|
|
439
|
-
}
|
|
440
|
-
function deleteRowReal(originalValue, formatValue, row, column, rowIndex, buttonConfigure) {
|
|
441
|
-
if (row.id || row.ID) {
|
|
442
|
-
pageContext.editData = row;
|
|
443
|
-
canExecuteButton({ pageContext, configureObj: buttonConfigure }).then((result) => {
|
|
444
|
-
if (result["canExecute"] === true) {
|
|
445
|
-
const ids = [];
|
|
446
|
-
if (row.id) {
|
|
447
|
-
ids.push(row.id);
|
|
448
|
-
} else {
|
|
449
|
-
ids.push(row.ID);
|
|
450
|
-
}
|
|
451
|
-
standardEvents.delete({
|
|
452
|
-
pageContext,
|
|
453
|
-
configureObj: buttonConfigure,
|
|
454
|
-
ids
|
|
455
|
-
});
|
|
456
|
-
}
|
|
457
|
-
}).finally(() => {
|
|
458
|
-
pageContext.editData = null;
|
|
459
|
-
});
|
|
460
|
-
} else {
|
|
461
|
-
restoreRow(originalValue, formatValue, row, column, rowIndex);
|
|
462
|
-
const afterOtherParams = {
|
|
463
|
-
originalValue,
|
|
464
|
-
formatValue,
|
|
465
|
-
row,
|
|
466
|
-
column,
|
|
467
|
-
rowIndex
|
|
468
|
-
};
|
|
469
|
-
doAfterClickEvent(pageContext, configure, afterOtherParams);
|
|
470
|
-
}
|
|
471
|
-
}
|
|
472
|
-
function searchGridData(data) {
|
|
473
|
-
if (!pageContext["dataTypeMaps"]) {
|
|
474
|
-
console.log("!pageContext['dataTypeMaps'] || !pageContext['dataTypeMaps'][tableName]");
|
|
475
|
-
return;
|
|
476
|
-
}
|
|
477
|
-
const dataTypeObj = pageContext["dataTypeMaps"];
|
|
478
|
-
let toolbarFieldParam = [];
|
|
479
|
-
if (data) {
|
|
480
|
-
for (var key in data) {
|
|
481
|
-
const value = data[key];
|
|
482
|
-
if (value !== null && value !== void 0 && value !== "") {
|
|
483
|
-
if (value instanceof Array) {
|
|
484
|
-
if (value.length > 0) {
|
|
485
|
-
const multipleFieldParam = [];
|
|
486
|
-
for (var i = 0; i < value.length; i++) {
|
|
487
|
-
const fieldParam = {};
|
|
488
|
-
if (i === 0) {
|
|
489
|
-
fieldParam["leftBracket"] = "((";
|
|
490
|
-
} else {
|
|
491
|
-
fieldParam["leftBracket"] = "(";
|
|
492
|
-
}
|
|
493
|
-
fieldParam["propName"] = key;
|
|
494
|
-
fieldParam["propDbName"] = key;
|
|
495
|
-
fieldParam["dataType"] = dataTypeObj[key] ? dataTypeObj[key] : "TEXT";
|
|
496
|
-
fieldParam["operator"] = "EQ";
|
|
497
|
-
fieldParam["propValue"] = value[i];
|
|
498
|
-
if (i === value.length - 1) {
|
|
499
|
-
fieldParam["rightBracket"] = "))";
|
|
500
|
-
fieldParam["joinSign"] = "and";
|
|
501
|
-
} else {
|
|
502
|
-
fieldParam["rightBracket"] = ")";
|
|
503
|
-
fieldParam["joinSign"] = "or";
|
|
504
|
-
}
|
|
505
|
-
multipleFieldParam.push(fieldParam);
|
|
506
|
-
}
|
|
507
|
-
toolbarFieldParam = toolbarFieldParam.concat(multipleFieldParam);
|
|
178
|
+
}
|
|
179
|
+
function Oe(e3) {
|
|
180
|
+
if (!q.dataTypeMaps)
|
|
181
|
+
return;
|
|
182
|
+
const t2 = q.dataTypeMaps;
|
|
183
|
+
let n2 = [];
|
|
184
|
+
if (e3)
|
|
185
|
+
for (var o2 in e3) {
|
|
186
|
+
const a2 = e3[o2];
|
|
187
|
+
if (null != a2 && "" !== a2)
|
|
188
|
+
if (a2 instanceof Array) {
|
|
189
|
+
if (a2.length > 0) {
|
|
190
|
+
const e4 = [];
|
|
191
|
+
for (var i2 = 0; i2 < a2.length; i2++) {
|
|
192
|
+
const n3 = {};
|
|
193
|
+
n3.leftBracket = 0 === i2 ? "((" : "(", n3.propName = o2, n3.propDbName = o2, n3.dataType = t2[o2] ? t2[o2] : "TEXT", n3.operator = "EQ", n3.propValue = a2[i2], i2 === a2.length - 1 ? (n3.rightBracket = "))", n3.joinSign = "and") : (n3.rightBracket = ")", n3.joinSign = "or"), e4.push(n3);
|
|
508
194
|
}
|
|
509
|
-
|
|
510
|
-
const fieldParam = {};
|
|
511
|
-
fieldParam["leftBracket"] = "(";
|
|
512
|
-
fieldParam["propName"] = key;
|
|
513
|
-
fieldParam["propDbName"] = key;
|
|
514
|
-
fieldParam["dataType"] = dataTypeObj[key] ? dataTypeObj[key] : "TEXT";
|
|
515
|
-
fieldParam["operator"] = "EQ";
|
|
516
|
-
fieldParam["propValue"] = value;
|
|
517
|
-
fieldParam["rightBracket"] = ")";
|
|
518
|
-
fieldParam["joinSign"] = "and";
|
|
519
|
-
toolbarFieldParam.push(fieldParam);
|
|
195
|
+
n2 = n2.concat(e4);
|
|
520
196
|
}
|
|
197
|
+
} else {
|
|
198
|
+
const e4 = { leftBracket: "(" };
|
|
199
|
+
e4.propName = o2, e4.propDbName = o2, e4.dataType = t2[o2] ? t2[o2] : "TEXT", e4.operator = "EQ", e4.propValue = a2, e4.rightBracket = ")", e4.joinSign = "and", n2.push(e4);
|
|
521
200
|
}
|
|
522
|
-
}
|
|
523
|
-
}
|
|
524
|
-
console.log("toolbarRefresh");
|
|
525
|
-
gridRef.value.toolbarRefresh(null, null, toolbarFieldParam);
|
|
526
|
-
}
|
|
527
|
-
function resizeListHeight(params) {
|
|
528
|
-
const contentHeight = getComponentHeight();
|
|
529
|
-
if (contentHeight) {
|
|
530
|
-
let searchHeight = 0;
|
|
531
|
-
if (params.searchHeight) {
|
|
532
|
-
searchHeight = params.searchHeight;
|
|
533
|
-
}
|
|
534
|
-
return contentHeight - 20 - searchHeight;
|
|
535
201
|
}
|
|
202
|
+
ie.value.toolbarRefresh(null, null, n2);
|
|
203
|
+
}
|
|
204
|
+
function ke(e3) {
|
|
205
|
+
const t2 = Ie();
|
|
206
|
+
if (t2) {
|
|
207
|
+
let n2 = 0;
|
|
208
|
+
return e3.searchHeight && (n2 = e3.searchHeight), t2 - 20 - n2;
|
|
536
209
|
}
|
|
537
|
-
|
|
538
|
-
|
|
210
|
+
}
|
|
211
|
+
function Ie() {
|
|
212
|
+
if (!ie.value)
|
|
213
|
+
return;
|
|
214
|
+
const e3 = F(W.pageContext, W.configure);
|
|
215
|
+
if (e3 && e3.isCalcHeight) {
|
|
216
|
+
let e4 = ie.value.$el;
|
|
217
|
+
if (e4 || (e4 = ie.value), !e4)
|
|
539
218
|
return;
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
"objectRender---configure.name=",
|
|
543
|
-
props.configure.name,
|
|
544
|
-
"props.configure=",
|
|
545
|
-
props.configure,
|
|
546
|
-
"runtimeStyle.value=",
|
|
547
|
-
runtimeStyle
|
|
548
|
-
);
|
|
549
|
-
const sizeConfig = getSizeConfig(props.pageContext, props.configure);
|
|
550
|
-
if (sizeConfig && sizeConfig["isCalcHeight"]) {
|
|
551
|
-
let thisRefDom = gridRef.value.$el;
|
|
552
|
-
if (!thisRefDom) {
|
|
553
|
-
thisRefDom = gridRef.value;
|
|
554
|
-
}
|
|
555
|
-
if (!thisRefDom) {
|
|
556
|
-
return;
|
|
557
|
-
}
|
|
558
|
-
const rect = thisRefDom.getBoundingClientRect();
|
|
559
|
-
return window.innerHeight - rect.y - 90;
|
|
560
|
-
}
|
|
561
|
-
}
|
|
562
|
-
function customButtonClick(originalValue, formatValue, row, column, rowIndex, button) {
|
|
563
|
-
const otherParams = {
|
|
564
|
-
originalValue,
|
|
565
|
-
formatValue,
|
|
566
|
-
row,
|
|
567
|
-
column,
|
|
568
|
-
rowIndex,
|
|
569
|
-
button
|
|
570
|
-
};
|
|
571
|
-
const buttonConfigure = operationButtonObj.value[button.sourceButton.uuid];
|
|
572
|
-
const tableConfigure = configure;
|
|
573
|
-
buttonConfigure.props.base.tableUuid = tableConfigure.uuid;
|
|
574
|
-
getHandleEvent(null, pageContext, buttonConfigure, "click", otherParams);
|
|
575
|
-
}
|
|
576
|
-
function recieveMessage(event) {
|
|
577
|
-
if (event.data === "close_open_win") {
|
|
578
|
-
if (gridRef.value) {
|
|
579
|
-
gridRef.value.refresh();
|
|
580
|
-
}
|
|
581
|
-
}
|
|
582
|
-
}
|
|
583
|
-
function select(selection, row) {
|
|
584
|
-
selections.value = selection;
|
|
585
|
-
const params = {
|
|
586
|
-
selection,
|
|
587
|
-
row
|
|
588
|
-
};
|
|
589
|
-
gridSelectRecord(pageContext, configure, params);
|
|
590
|
-
}
|
|
591
|
-
function selectAll(selection) {
|
|
592
|
-
selections.value = selection;
|
|
593
|
-
const params = {
|
|
594
|
-
selection
|
|
595
|
-
};
|
|
596
|
-
gridSelectAllRecords(pageContext, configure, params);
|
|
597
|
-
}
|
|
598
|
-
function selectionChange(newSelection) {
|
|
599
|
-
const params = {
|
|
600
|
-
newSelection
|
|
601
|
-
};
|
|
602
|
-
gridSelectionChange(pageContext, configure, params);
|
|
603
|
-
}
|
|
604
|
-
function cellClickEvent(row, column, cell, event) {
|
|
605
|
-
const params = {
|
|
606
|
-
row,
|
|
607
|
-
column,
|
|
608
|
-
cell,
|
|
609
|
-
event
|
|
610
|
-
};
|
|
611
|
-
cellClick(pageContext, configure, params);
|
|
612
|
-
}
|
|
613
|
-
function cellDblClickEvent(row, column, cell, event) {
|
|
614
|
-
const params = {
|
|
615
|
-
row,
|
|
616
|
-
column,
|
|
617
|
-
cell,
|
|
618
|
-
event
|
|
619
|
-
};
|
|
620
|
-
cellDblClick(pageContext, configure, params);
|
|
621
|
-
}
|
|
622
|
-
function rowClickEvent(row, column, event) {
|
|
623
|
-
const params = {
|
|
624
|
-
row,
|
|
625
|
-
column,
|
|
626
|
-
event
|
|
627
|
-
};
|
|
628
|
-
rowClick(pageContext, configure, params);
|
|
629
|
-
}
|
|
630
|
-
function rowDblClickEvent(row, column, event) {
|
|
631
|
-
const params = {
|
|
632
|
-
row,
|
|
633
|
-
column,
|
|
634
|
-
event
|
|
635
|
-
};
|
|
636
|
-
rowDblClick(pageContext, configure, params);
|
|
637
|
-
}
|
|
638
|
-
function headerClickEvent(column, event) {
|
|
639
|
-
const params = {
|
|
640
|
-
column,
|
|
641
|
-
event
|
|
642
|
-
};
|
|
643
|
-
headerClick(pageContext, configure, params);
|
|
644
|
-
}
|
|
645
|
-
function validatorSunTableListData() {
|
|
646
|
-
return gridRef.value.validatorSunTableListData();
|
|
647
|
-
}
|
|
648
|
-
function clearSelections() {
|
|
649
|
-
selections.value = [];
|
|
650
|
-
}
|
|
651
|
-
function refresh() {
|
|
652
|
-
return gridRef.value.refresh();
|
|
653
|
-
}
|
|
654
|
-
function createRow() {
|
|
655
|
-
return gridRef.value.createRow(listCode, {}, { getDefaultValueFunc: getDefaultValue });
|
|
656
|
-
}
|
|
657
|
-
function getSelections() {
|
|
658
|
-
return selections.value;
|
|
659
|
-
}
|
|
660
|
-
function getSelectionIds() {
|
|
661
|
-
const dataIds = [];
|
|
662
|
-
if (selections.value !== null) {
|
|
663
|
-
selections.value.forEach((item) => {
|
|
664
|
-
dataIds.push(item.id ? item.id : item.ID ? item.ID : null);
|
|
665
|
-
});
|
|
666
|
-
}
|
|
667
|
-
return dataIds;
|
|
668
|
-
}
|
|
669
|
-
function getTableConfigure() {
|
|
670
|
-
return configure;
|
|
671
|
-
}
|
|
672
|
-
function isDeleteChange(value) {
|
|
673
|
-
gridRef.value.isDeleteChange(value);
|
|
674
|
-
}
|
|
675
|
-
function showMobileSearch() {
|
|
676
|
-
if (isCanShowMobileSearch.value) {
|
|
677
|
-
gridRef.value.showMobileSearch();
|
|
678
|
-
}
|
|
679
|
-
}
|
|
680
|
-
function canShowMobileSearchFunc(listCode2) {
|
|
681
|
-
isCanShowMobileSearch.value = true;
|
|
219
|
+
const t2 = e4.getBoundingClientRect();
|
|
220
|
+
return window.innerHeight - t2.y - 90;
|
|
682
221
|
}
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
}
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
}
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
}
|
|
744
|
-
}
|
|
745
|
-
},
|
|
746
|
-
{ immediate: true }
|
|
747
|
-
);
|
|
748
|
-
});
|
|
749
|
-
}
|
|
750
|
-
}
|
|
751
|
-
}
|
|
752
|
-
}
|
|
753
|
-
function linkageVariableWatch() {
|
|
754
|
-
linkageVariable.forEach((variable) => {
|
|
755
|
-
watch(
|
|
756
|
-
() => props.pageContext.entity.page[variable],
|
|
757
|
-
() => {
|
|
758
|
-
const values = getLinkageVariableValues();
|
|
759
|
-
searchGridData(values);
|
|
760
|
-
}
|
|
761
|
-
);
|
|
222
|
+
}
|
|
223
|
+
function Te(e3, t2, n2, o2, i2, a2) {
|
|
224
|
+
const l2 = { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: i2, button: a2 }, r2 = te.value[a2.sourceButton.uuid], u2 = G;
|
|
225
|
+
r2.props.base.tableUuid = u2.uuid, v(null, q, r2, "click", l2);
|
|
226
|
+
}
|
|
227
|
+
function Re(e3) {
|
|
228
|
+
"close_open_win" === e3.data && ie.value && ie.value.refresh();
|
|
229
|
+
}
|
|
230
|
+
function Ve(e3, t2) {
|
|
231
|
+
ue.value = e3;
|
|
232
|
+
h(q, G, { selection: e3, row: t2 });
|
|
233
|
+
}
|
|
234
|
+
function je(e3) {
|
|
235
|
+
ue.value = e3;
|
|
236
|
+
b(q, G, { selection: e3 });
|
|
237
|
+
}
|
|
238
|
+
function Ne(e3) {
|
|
239
|
+
w(q, G, { newSelection: e3 });
|
|
240
|
+
}
|
|
241
|
+
function Pe(e3, t2, n2, o2) {
|
|
242
|
+
S(q, G, { row: e3, column: t2, cell: n2, event: o2 });
|
|
243
|
+
}
|
|
244
|
+
function Ue(e3, t2, n2, o2) {
|
|
245
|
+
C(q, G, { row: e3, column: t2, cell: n2, event: o2 });
|
|
246
|
+
}
|
|
247
|
+
function Be(e3, t2, n2) {
|
|
248
|
+
y(q, G, { row: e3, column: t2, event: n2 });
|
|
249
|
+
}
|
|
250
|
+
function Me(e3, t2, n2) {
|
|
251
|
+
x(q, G, { row: e3, column: t2, event: n2 });
|
|
252
|
+
}
|
|
253
|
+
function $e(e3, t2) {
|
|
254
|
+
E(q, G, { column: e3, event: t2 });
|
|
255
|
+
}
|
|
256
|
+
function Fe() {
|
|
257
|
+
ue.value = [];
|
|
258
|
+
}
|
|
259
|
+
function _e(e3) {
|
|
260
|
+
de.value = true;
|
|
261
|
+
}
|
|
262
|
+
function Le(e3) {
|
|
263
|
+
return _(e3, [], W);
|
|
264
|
+
}
|
|
265
|
+
function Ae(e3) {
|
|
266
|
+
return L(e3, e3.cellStyle, W);
|
|
267
|
+
}
|
|
268
|
+
function He(e3) {
|
|
269
|
+
const t2 = e3.titleStyle, n2 = W.configure.style.titleStyle;
|
|
270
|
+
return A(e3, { cellTitleStyle: t2, titleStyle: n2 }, W);
|
|
271
|
+
}
|
|
272
|
+
function ze() {
|
|
273
|
+
const e3 = {};
|
|
274
|
+
return ne.forEach((t2) => {
|
|
275
|
+
e3[t2] = W.pageContext.entity.page[t2];
|
|
276
|
+
}), e3;
|
|
277
|
+
}
|
|
278
|
+
function We() {
|
|
279
|
+
ne.forEach((e3) => {
|
|
280
|
+
o(() => W.pageContext.entity.page[e3], () => {
|
|
281
|
+
Oe(ze());
|
|
762
282
|
});
|
|
763
|
-
}
|
|
764
|
-
function getTableSelectOptions() {
|
|
765
|
-
if (gridRef.value) {
|
|
766
|
-
return gridRef.value.getTableSelectOptions(listCode);
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
|
-
function dynamicControlTableEdit(pageContext2, customRules, listCode2) {
|
|
770
|
-
if (gridRef.value) {
|
|
771
|
-
gridRef.value.dynamicControlTableEdit(pageContext2, customRules, listCode2);
|
|
772
|
-
}
|
|
773
|
-
}
|
|
774
|
-
function doLayout(hiddenColumns) {
|
|
775
|
-
if (gridRef.value) {
|
|
776
|
-
gridRef.value.doLayout(hiddenColumns);
|
|
777
|
-
}
|
|
778
|
-
}
|
|
779
|
-
__expose({
|
|
780
|
-
refresh,
|
|
781
|
-
createRow,
|
|
782
|
-
clearSelections,
|
|
783
|
-
getSelections,
|
|
784
|
-
getSelectionIds,
|
|
785
|
-
getTableConfigure,
|
|
786
|
-
isDeleteChange,
|
|
787
|
-
validatorSunTableListData,
|
|
788
|
-
showMobileSearch,
|
|
789
|
-
getTableSelectOptions,
|
|
790
|
-
dynamicControlTableEdit,
|
|
791
|
-
doLayout
|
|
792
283
|
});
|
|
793
|
-
return (_ctx, _cache) => {
|
|
794
|
-
const _component_super_grid = resolveComponent("super-grid");
|
|
795
|
-
return openBlock(), createElementBlock("div", null, [
|
|
796
|
-
createVNode(_component_super_grid, {
|
|
797
|
-
ref_key: "gridRef",
|
|
798
|
-
ref: gridRef,
|
|
799
|
-
url: unref(urlToListData),
|
|
800
|
-
options: listOptions.value,
|
|
801
|
-
code: unref(listCode),
|
|
802
|
-
settings: unref(superGridSetting),
|
|
803
|
-
"search-form-info": searchFormInfo.value,
|
|
804
|
-
"list-toolbar-form-data": unref(listToolbarFormData),
|
|
805
|
-
onSelect: select,
|
|
806
|
-
onSelectAll: selectAll,
|
|
807
|
-
onSelectionChange: selectionChange,
|
|
808
|
-
onCellClick: cellClickEvent,
|
|
809
|
-
onCellDblclick: cellDblClickEvent,
|
|
810
|
-
onRowClick: rowClickEvent,
|
|
811
|
-
onRowDblclick: rowDblClickEvent,
|
|
812
|
-
onHeaderClick: headerClickEvent,
|
|
813
|
-
onRefresh: clearSelections,
|
|
814
|
-
onNewOpenGridDialog: unref(popupToPage),
|
|
815
|
-
onCanShowMobileSearch: canShowMobileSearchFunc
|
|
816
|
-
}, null, 8, ["url", "options", "code", "settings", "search-form-info", "list-toolbar-form-data", "onNewOpenGridDialog"])
|
|
817
|
-
]);
|
|
818
|
-
};
|
|
819
284
|
}
|
|
820
|
-
|
|
285
|
+
return n(() => {
|
|
286
|
+
window.addEventListener("message", Re), B.$on(re + "-close-component-page-dialog", function({ jumpInfo: e3, popEntity: t2, popPageCode: n2 }) {
|
|
287
|
+
ie.value.closePageDialog({ entity: t2, pageCode: n2, jumpInfo: e3 });
|
|
288
|
+
}), B.$on(re + "_close-dialog-get-entity", () => {
|
|
289
|
+
B.$emit(re + "_close-super-dialog");
|
|
290
|
+
}), B.$on(le + "-pickFileDone", (e3) => {
|
|
291
|
+
ie.value.pickFileDone(e3);
|
|
292
|
+
}), B.$on(le + "-scanDone", (e3) => {
|
|
293
|
+
ie.value.scanDone(e3);
|
|
294
|
+
}), oe.value.formSetMaxHeight = Ie(), oe.value && oe.value.configureObj.props.base && oe.value.configureObj.props.base.isSafeDelete && ge("setSafeDeleteTableCode", oe.value.extraParam.tableName);
|
|
295
|
+
}), o(() => W.pageContext.searchFormData, (e3) => {
|
|
296
|
+
ce.value.data = e3;
|
|
297
|
+
}), o(() => W.pageContext.entity.data, (e3) => {
|
|
298
|
+
Oe(W.pageContext.entity.data);
|
|
299
|
+
}), i(() => {
|
|
300
|
+
B.$off(re + "-close-component-page-dialog"), B.$off(re + "_close-dialog-get-entity"), B.$off(le + "-pickFileDone"), B.$off(le + "-scanDone");
|
|
301
|
+
}), H2({ refresh: function() {
|
|
302
|
+
return ie.value.refresh();
|
|
303
|
+
}, createRow: function() {
|
|
304
|
+
return ie.value.createRow(le, {}, { getDefaultValueFunc: M });
|
|
305
|
+
}, clearSelections: Fe, getSelections: function() {
|
|
306
|
+
return ue.value;
|
|
307
|
+
}, getSelectionIds: function() {
|
|
308
|
+
const e3 = [];
|
|
309
|
+
return null !== ue.value && ue.value.forEach((t2) => {
|
|
310
|
+
e3.push(t2.id ? t2.id : t2.ID ? t2.ID : null);
|
|
311
|
+
}), e3;
|
|
312
|
+
}, getTableConfigure: function() {
|
|
313
|
+
return G;
|
|
314
|
+
}, isDeleteChange: function(e3) {
|
|
315
|
+
ie.value.isDeleteChange(e3);
|
|
316
|
+
}, validatorSunTableListData: function() {
|
|
317
|
+
return ie.value.validatorSunTableListData();
|
|
318
|
+
}, showMobileSearch: function() {
|
|
319
|
+
de.value && ie.value.showMobileSearch();
|
|
320
|
+
}, getTableSelectOptions: function() {
|
|
321
|
+
if (ie.value)
|
|
322
|
+
return ie.value.getTableSelectOptions(le);
|
|
323
|
+
}, dynamicControlTableEdit: function(e3, t2, n2) {
|
|
324
|
+
ie.value && ie.value.dynamicControlTableEdit(e3, t2, n2);
|
|
325
|
+
}, doLayout: function(e3) {
|
|
326
|
+
ie.value && ie.value.doLayout(e3);
|
|
327
|
+
} }), (e3, t2) => {
|
|
328
|
+
const n2 = a("super-grid");
|
|
329
|
+
return l(), r("div", null, [u(n2, { ref_key: "gridRef", ref: ie, url: s(ae), options: oe.value, code: s(le), settings: s(fe), "search-form-info": ce.value, "list-toolbar-form-data": s(se), onSelect: Ve, onSelectAll: je, onSelectionChange: Ne, onCellClick: Pe, onCellDblclick: Ue, onRowClick: Be, onRowDblclick: Me, onHeaderClick: $e, onRefresh: Fe, onNewOpenGridDialog: s(U), onCanShowMobileSearch: _e }, null, 8, ["url", "options", "code", "settings", "search-form-info", "list-toolbar-form-data", "onNewOpenGridDialog"])]);
|
|
330
|
+
};
|
|
331
|
+
} });
|
|
821
332
|
export {
|
|
822
|
-
|
|
333
|
+
H as default
|
|
823
334
|
};
|