super-page-runtime 2.3.16 → 2.3.17-sit1
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/components/runtime/utils/api/page-expose-util.js +66 -61
- package/dist/es/components/runtime/utils/events/event-util.js +3 -3
- package/dist/es/components/runtime/utils/events/print-label.js +25 -26
- package/dist/es/components/runtime/utils/events/standard-event.js +18 -18
- package/dist/es/components/runtime/utils/events/validator-util.js +1 -1
- package/dist/es/components/runtime/utils/page-init-util.js +129 -100
- package/dist/es/components/runtime/utils/page-store.js +10 -10
- package/dist/es/components/runtime/utils/table-utils.js +1 -1
- package/dist/es/components/runtime/views/assemblys/button/button/button-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/button/button-group/buttongroup-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/button/dropdown/dropdown-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/button/export-pdf/exportpdf-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/button/print-label/printlabel-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/chart/column-line/column-line-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header-group.vue.js +6 -10
- package/dist/es/components/runtime/views/assemblys/chart/common/common-chart-header.vue.js +6 -8
- package/dist/es/components/runtime/views/assemblys/chart/common/common-homepage-search.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/gauge/gauge-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/pie/pie-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/radar/radar-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/scatter/scatter-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/chart/table/chart-table-util.js +93 -98
- package/dist/es/components/runtime/views/assemblys/chart/table/table-runtime.vue2.js +2 -3
- package/dist/es/components/runtime/views/assemblys/common/export-form-report-dialog.vue.js +9 -11
- package/dist/es/components/runtime/views/assemblys/common/save-chart-condition-dialog.vue.js +1 -1
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/collapse/collapse-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/container/container-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/fixed/YxAffix.vue2.js +0 -2
- package/dist/es/components/runtime/views/assemblys/container/flex/flex-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/form/form-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/iframe/iframe-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/container/tabs/tabs-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/data/bar-code/barcode-runtime.vue2.js +10 -12
- package/dist/es/components/runtime/views/assemblys/data/table/main-table-runtime.vue.js +8 -8
- package/dist/es/components/runtime/views/assemblys/data/table/sub-table-runtime.vue.js +9 -9
- package/dist/es/components/runtime/views/assemblys/data/table/table-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/data/tree/tree-runtime.vue2.js +16 -16
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +33 -19
- package/dist/es/components/runtime/views/assemblys/form/common/title-suffix-element.vue.js +3 -3
- package/dist/es/components/runtime/views/assemblys/form/custom/custom-runtime.vue2.js +6 -6
- package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js +37 -37
- package/dist/es/components/runtime/views/assemblys/form/dept-tree/depttree-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/form/divider/divider-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/form/file-upload/fileupload-runtime.vue2.js +4 -4
- package/dist/es/components/runtime/views/assemblys/form/input-number/input-number-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/form/input-text/inputtext-runtime.vue2.js +37 -38
- package/dist/es/components/runtime/views/assemblys/form/label/label-runtime.vue2.js +5 -7
- package/dist/es/components/runtime/views/assemblys/form/link/link-runtime.vue2.js +3 -4
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +27 -18
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue.js +2 -1
- package/dist/es/components/runtime/views/assemblys/form/rich-text/richtext-runtime.vue2.js +155 -89
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +25 -25
- package/dist/es/components/runtime/views/assemblys/form/separatelabel/separatelabel-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/form/switch/switch-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/form/tag/tag-runtime.vue2.js +11 -11
- package/dist/es/components/runtime/views/assemblys/form/textarea/textarea-runtime.vue2.js +3 -3
- package/dist/es/components/runtime/views/assemblys/home-chart-render.vue.js +3 -3
- package/dist/es/components/runtime/views/assemblys/object-render.vue.js +1 -1
- package/dist/es/components/runtime/views/assemblys/workflow/extract-workflow/extract-workflow-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/assemblys/workflow/workflow-button/workflowbutton-runtime.vue2.js +1 -1
- package/dist/es/components/runtime/views/home-chart.vue.js +7 -7
- package/dist/es/components/runtime/views/super-page-dialog.vue.js +0 -1
- package/dist/es/components/runtime/views/super-page.vue.js +1 -1
- package/dist/es/components/runtime/views/super-page.vue2.js +73 -74
- package/dist/es/style.css +336 -78
- package/package.json +2 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as e, computed as t, ref as
|
|
1
|
+
import { defineComponent as e, computed as t, ref as a, onMounted as r, watch as l, resolveComponent as o, createBlock as u, openBlock as n, normalizeStyle as i, normalizeClass as s, unref as p, withCtx as c, createElementBlock as m, createCommentVNode as f, toDisplayString as g } from "vue";
|
|
2
2
|
import d from "qrcode";
|
|
3
3
|
import v from "jsbarcode";
|
|
4
4
|
import { getFormModelFields as y } from "../../../../utils/page-init-util.js";
|
|
@@ -12,7 +12,7 @@ const j = ["src"], D = e({ __name: "barcode-runtime", props: { pageContext: {},
|
|
|
12
12
|
let k = y(q.pageContext, q.configure);
|
|
13
13
|
const A = t({ get: () => x(N, k), set(e3) {
|
|
14
14
|
h(N, k, e3);
|
|
15
|
-
} }), E = q.configure.runtime ? q.configure.runtime : {}, _ =
|
|
15
|
+
} }), E = q.configure.runtime ? q.configure.runtime : {}, _ = a(E.props ? E.props : {}), O = E.style, P = E.class, S = E.headerStyle, $ = a(""), I = a(null), Q = a(_.value.brCodeFormat ?? "CODE128"), V = a([]);
|
|
16
16
|
function F(e3) {
|
|
17
17
|
return h(N, k, e3);
|
|
18
18
|
}
|
|
@@ -22,32 +22,31 @@ const j = ["src"], D = e({ __name: "barcode-runtime", props: { pageContext: {},
|
|
|
22
22
|
function L(e3) {
|
|
23
23
|
var t2;
|
|
24
24
|
"QR-code" === _.value.type ? (t2 = e3, d.toDataURL(t2, (e4, t3) => {
|
|
25
|
-
e4
|
|
25
|
+
e4 || ($.value = t3);
|
|
26
26
|
})) : function(e4) {
|
|
27
27
|
try {
|
|
28
28
|
v(I.value, e4, { format: Q.value });
|
|
29
29
|
} catch (e5) {
|
|
30
|
-
console.error("生成条形码时发生错误:", e5);
|
|
31
30
|
}
|
|
32
31
|
}(e3);
|
|
33
32
|
}
|
|
34
|
-
return
|
|
33
|
+
return r(() => {
|
|
35
34
|
_.value.generateRule && ("fixed" === _.value.generateRuleType ? (V.value = Array.from(_.value.generateRule.matchAll(/\$\{(\w+)\}/g), (e3) => e3[1]), V.value.forEach((e3) => {
|
|
36
|
-
|
|
35
|
+
l(() => q.pageContext.entity.data[e3], (e4, t2) => {
|
|
37
36
|
null != e4 && function() {
|
|
38
37
|
let e5 = true;
|
|
39
38
|
V.value.forEach((t3) => {
|
|
40
39
|
q.pageContext.entity.data[t3] || (e5 = false);
|
|
41
40
|
}), e5 && J(function(e6, t3) {
|
|
42
|
-
const
|
|
43
|
-
return e6.replace(
|
|
41
|
+
const a2 = /\$\{(\w+)\}/g;
|
|
42
|
+
return e6.replace(a2, (e7, a3) => t3.hasOwnProperty(a3) ? t3[a3] : e7);
|
|
44
43
|
}(_.value.generateRule, q.pageContext.entity.data));
|
|
45
44
|
}();
|
|
46
45
|
});
|
|
47
46
|
})) : w.get(window.$vueApp.config.globalProperties.baseAPI + "/dc/setting-barcode-models/by-code/" + _.value.generateRule).then((e3) => {
|
|
48
47
|
const t2 = JSON.parse(e3.barcodeModelItems);
|
|
49
48
|
t2.forEach((e4) => {
|
|
50
|
-
"-1" !== e4.propDbName && -1 !== e4.propDbName && (V.value.push(e4.propDbName),
|
|
49
|
+
"-1" !== e4.propDbName && -1 !== e4.propDbName && (V.value.push(e4.propDbName), l(() => q.pageContext.entity.data[e4.propDbName], (e5, a2) => {
|
|
51
50
|
if (null != e5) {
|
|
52
51
|
const e6 = b(t2, q.pageContext.entity.data);
|
|
53
52
|
e6 && J(e6);
|
|
@@ -55,13 +54,12 @@ const j = ["src"], D = e({ __name: "barcode-runtime", props: { pageContext: {},
|
|
|
55
54
|
}));
|
|
56
55
|
});
|
|
57
56
|
}).catch((e3) => {
|
|
58
|
-
console.error("获取条码规则失败:", e3);
|
|
59
57
|
})), A.value && L(A.value);
|
|
60
58
|
}), D2({ getValue: function() {
|
|
61
59
|
return x(N, k);
|
|
62
60
|
}, setValue: F }), (e3, t2) => {
|
|
63
|
-
const
|
|
64
|
-
return
|
|
61
|
+
const a2 = o("el-form-item");
|
|
62
|
+
return n(), u(a2, { required: !!_.value.required, class: s(p(P)), "label-width": _.value.labelWidth, style: i(p(O)) }, { label: c(() => [_.value.tittleShow ? (n(), m("div", { key: 0, style: i({ ...p(S) }) }, g(p(R)(_.value.title)), 5)) : f("", true)]), default: c(() => ["QR-code" === _.value.type ? (n(), m("img", { key: 0, src: $.value }, null, 8, j)) : (n(), m("canvas", { key: 1, ref_key: "barcode", ref: I }, null, 512))]), _: 1 }, 8, ["required", "class", "label-width", "style"]);
|
|
65
63
|
};
|
|
66
64
|
} });
|
|
67
65
|
export {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as e, ref as t, onMounted as n, watch as o, onUnmounted as i, resolveComponent as a, createElementBlock as l, openBlock as r, unref as u, createVNode as s } from "vue";
|
|
2
|
-
import { setTableEvents as c, canExecuteButton as p, doAfterClickEvent as d, doBeforeClickEvent as f, gridSelectRecord as g, gridSelectAllRecords as m, gridSelectionChange as v, cellClick as h, cellDblClick as b, rowClick as
|
|
2
|
+
import { setTableEvents as c, canExecuteButton as p, doAfterClickEvent as d, doBeforeClickEvent as f, gridSelectRecord as g, gridSelectAllRecords as m, gridSelectionChange as v, cellClick as h, cellDblClick as b, rowClick as w, rowDblClick as S, headerClick as C, getEventNameByType as y, getEventFuncByType as x, getHandleEvent as D } from "../../../../utils/events/event-util.js";
|
|
3
3
|
import { getBaseUrl as E, getListCode as T, getRealRestApiPath as O, isWorkflowPage as R, isVariableInvalidValue as k } from "../../../../utils/common-util.js";
|
|
4
4
|
import { getAdditionalParamMap as I, getSaveFormRequestWithRow as V, standardEvents as j } from "../../../../utils/events/standard-event.js";
|
|
5
5
|
import { isPromise as N } from "agilebuilder-ui/src/utils/common-util";
|
|
@@ -23,7 +23,7 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
23
23
|
const e3 = Y.systemCode, t2 = Y.code;
|
|
24
24
|
let n2 = J.props && J.props.dataOrigin && "[]" !== J.props.dataOrigin.sqlFilterCondition ? J.props.dataOrigin.sqlFilterCondition : null;
|
|
25
25
|
null == n2 && (n2 = []);
|
|
26
|
-
const o2 = (_a = J.props) == null ? void 0 : _a.dataOrigin.principalLinkage, i2 = { isSql: true, optionTableHeight: 0, rowKeyProp: o2, extraParam: { beanName: Y.beanName, functionCode: t2 + ".listData", tableName: ne, systemCode: e3, pageCode: Y.code, pageVersion: Y.version }, initSearchForm: n2, lineEditOptions: { aftersaveIsCreateRow: false, autoSave: false, enter:
|
|
26
|
+
const o2 = (_a = J.props) == null ? void 0 : _a.dataOrigin.principalLinkage, i2 = { isSql: true, optionTableHeight: 0, rowKeyProp: o2, extraParam: { beanName: Y.beanName, functionCode: t2 + ".listData", tableName: ne, systemCode: e3, pageCode: Y.code, pageVersion: Y.version }, initSearchForm: n2, lineEditOptions: { aftersaveIsCreateRow: false, autoSave: false, enter: Se, esc: Ee }, indexContinuous: !(!J.props || !J.props.otherSettings) && J.props.otherSettings.serialNumberContinuous, initSearch: !J.props || false !== J.props.dataOrigin.initializationQuery, resizeHeight: je, pageCode: Y.code, pageVersion: Y.version, additionalParamMap: I(Y), showOverflowTooltip: !(!J.props || !J.props.otherSettings || void 0 !== J.props.otherSettings.isBreakLine && false !== J.props.otherSettings.isBreakLine), isEnableEnterEvent: J.props && J.props.otherSettings && J.props.otherSettings.isEnableEnterEvent, isWithDataPermission: !!(J.props && J.props.otherSettings && J.props.otherSettings.isWithDataPermission) && J.props.otherSettings.isWithDataPermission, pageDevMode: false, isWorkflowEntity: R(Y), tableClass: Z, tableStyle: X, pageContext: Y, configureObj: J, backendUrl: oe, cellStyleRender: qe, rowStyleRender: We, titleStyleRender: Qe, validateEitConditions: Xe };
|
|
27
27
|
return function(e4) {
|
|
28
28
|
var _a2;
|
|
29
29
|
((_a2 = J.props.highOrder) == null ? void 0 : _a2.mergeFields) && J.props.highOrder.mergeFields.length > 0 && (e4.mergeFields = J.props.highOrder.mergeFields.join(","));
|
|
@@ -60,7 +60,7 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
60
60
|
e3 && (e3 = O(e3, ee, te, Y.isTest));
|
|
61
61
|
return e3;
|
|
62
62
|
}(), ce = T(Y.code, Y.version, J.uuid), pe = Y.code + "_" + ce, de = t([]), fe = Y.entity.page, ge = t({ data: [] }), me = Y.superGridItems, ve = me ? me[J.uuid] : null, he = t(false), be = q;
|
|
63
|
-
function
|
|
63
|
+
function we() {
|
|
64
64
|
J.props.linkages && J.props.linkages.length > 0 && (J.props.linkages.forEach((e3) => {
|
|
65
65
|
const t2 = M(e3.fieldName);
|
|
66
66
|
t2 && t2.length > 1 && ae.push(t2[1]);
|
|
@@ -84,7 +84,7 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
84
84
|
}
|
|
85
85
|
}());
|
|
86
86
|
}
|
|
87
|
-
function
|
|
87
|
+
function Se({ rowIndex: e3, column: t2, row: n2, orgRow: o2 }) {
|
|
88
88
|
Ce(null, null, n2, t2, e3);
|
|
89
89
|
}
|
|
90
90
|
function Ce(e3, t2, n2, o2, i2) {
|
|
@@ -244,10 +244,10 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
244
244
|
b(Y, J, { row: e3, column: t2, cell: n2, event: o2 });
|
|
245
245
|
}
|
|
246
246
|
function $e(e3, t2, n2) {
|
|
247
|
-
|
|
247
|
+
w(Y, J, { row: e3, column: t2, event: n2 });
|
|
248
248
|
}
|
|
249
249
|
function _e(e3, t2, n2) {
|
|
250
|
-
|
|
250
|
+
S(Y, J, { row: e3, column: t2, event: n2 });
|
|
251
251
|
}
|
|
252
252
|
function Ae(e3, t2) {
|
|
253
253
|
C(Y, J, { column: e3, event: t2 });
|
|
@@ -283,7 +283,7 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
283
283
|
}
|
|
284
284
|
n(() => {
|
|
285
285
|
const e3 = Ke();
|
|
286
|
-
ue.value && e3 && e3.distanceToBottom && (ue.value.tableHeight = e3.distanceToBottom - 110), Q.pageContext.pageRuntimeStyle
|
|
286
|
+
ue.value && e3 && e3.distanceToBottom && (ue.value.tableHeight = e3.distanceToBottom - 110), Q.pageContext.pageRuntimeStyle, window.addEventListener("message", Pe), F.$on(pe + "-close-component-page-dialog", function({ jumpInfo: e4, popEntity: t2, popPageCode: n2 }) {
|
|
287
287
|
ue.value.closePageDialog({ entity: t2, pageCode: n2, jumpInfo: e4 });
|
|
288
288
|
}), F.$on(pe + "_close-dialog-get-entity", () => {
|
|
289
289
|
F.$emit(pe + "_close-super-dialog");
|
|
@@ -370,7 +370,7 @@ const z = ["id"], W = e({ __name: "main-table-runtime", props: { pageContext: {}
|
|
|
370
370
|
return (_a = ue.value) == null ? void 0 : _a.handleSearch(e3, t2);
|
|
371
371
|
} }), (e3, t2) => {
|
|
372
372
|
const n2 = a("super-grid");
|
|
373
|
-
return r(), l("div", { ref_key: "tableDivRef", ref: re, id: u(ce) + "_tableDiv" }, [s(n2, { ref_key: "gridRef", ref: ue, url: u(se), options: le.value, code: u(ce), settings: u(ve), "search-form-info": ge.value, "list-toolbar-form-data": u(fe), onSelect: Fe, onSelectAll: He, onSelectionChange: Ue, onCellClick: Le, onCellDblclick: Me, onRowClick: $e, onRowDblclick: _e, onHeaderClick: Ae, onRefresh: Ge, onNewOpenGridDialog: u(P), onCanShowMobileSearch: ze, onGridOnmounted:
|
|
373
|
+
return r(), l("div", { ref_key: "tableDivRef", ref: re, id: u(ce) + "_tableDiv" }, [s(n2, { ref_key: "gridRef", ref: ue, url: u(se), options: le.value, code: u(ce), settings: u(ve), "search-form-info": ge.value, "list-toolbar-form-data": u(fe), isDialog: u(Y).isDialog, onSelect: Fe, onSelectAll: He, onSelectionChange: Ue, onCellClick: Le, onCellDblclick: Me, onRowClick: $e, onRowDblclick: _e, onHeaderClick: Ae, onRefresh: Ge, onNewOpenGridDialog: u(P), onCanShowMobileSearch: ze, onGridOnmounted: we }, null, 8, ["url", "options", "code", "settings", "search-form-info", "list-toolbar-form-data", "isDialog", "onNewOpenGridDialog"])], 8, z);
|
|
374
374
|
};
|
|
375
375
|
} });
|
|
376
376
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as e, ref as t, onMounted as n, onUnmounted as o, resolveComponent as l, createElementBlock as a, openBlock as i, createBlock as u, createCommentVNode as r, unref as s } from "vue";
|
|
2
2
|
import { setTableEvents as c, gridSelectRecord as p, gridSelectAllRecords as d, gridSelectionChange as f, cellClick as v, cellDblClick as b, rowClick as g, rowDblClick as m, headerClick as h, getHandleEvent as S } from "../../../../utils/events/event-util.js";
|
|
3
|
-
import { caculateShowCondition as w, setVariableValue as T, getVariableValue as x, getSizeConfig as
|
|
4
|
-
import { getModelFields as
|
|
3
|
+
import { caculateShowCondition as w, setVariableValue as T, getVariableValue as x, getSizeConfig as D } from "../../../../utils/page-helper-util.js";
|
|
4
|
+
import { getModelFields as C, getDefaultValue as y } from "../../../../utils/page-init-util.js";
|
|
5
5
|
import P from "../../../../utils/eventBus.js";
|
|
6
6
|
import { popupToPage as R, getOperationButtons as I } from "../../../../utils/table-utils.js";
|
|
7
7
|
import { getListCode as O, getBaseUrl as _ } from "../../../../utils/common-util.js";
|
|
@@ -14,7 +14,7 @@ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure:
|
|
|
14
14
|
const E = L.configure.runtime ? L.configure.runtime : {};
|
|
15
15
|
B.isTest ? E.value = L.configure.runtime ? L.configure.runtime : {} : B.tableRuntimes && B.tableRuntimes[N.uuid] && (N = JSON.parse(B.tableRuntimes[N.uuid].configure), E.value = N.runtime ? N.runtime : {});
|
|
16
16
|
const G = O(B.code, B.version, N.uuid), H = B.entity.data, V = N.code ? N.code : G, U = k(B), z = E && E.events ? E.events : [], q = t([]), J = B.superGridItems, K = J ? J[N.uuid] : null, Q = E.style, W = E.class, X = L.pageContext.entity ? L.pageContext.entity : {};
|
|
17
|
-
let Y =
|
|
17
|
+
let Y = C(L.configure, V), Z = _(B.backendUrl, B.isTest);
|
|
18
18
|
Z || (Z = window.$vueApp.config.globalProperties.baseURL);
|
|
19
19
|
const ee = t(false);
|
|
20
20
|
let te = t(0);
|
|
@@ -37,7 +37,7 @@ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure:
|
|
|
37
37
|
e4 ? e4.push("operation") : e4 = ["operation"], oe.value.hiddenColumns = e4;
|
|
38
38
|
}
|
|
39
39
|
oe.value.showOperationButton = !(!N.props || !N.props.base) && N.props.base.showOperation, oe.value.isPdfEditor = false, oe.value.tableRecordMaxNum = N.props && N.props.otherSettings ? N.props.otherSettings.tableRecordMaxNum : null;
|
|
40
|
-
let t2 =
|
|
40
|
+
let t2 = D(B, N);
|
|
41
41
|
t2 && t2.fixHeight && (oe.value.formSetHeight = t2.fixHeight), t2 && t2.maxHeight && (oe.value.formSetMaxHeight = t2.maxHeight), oe.value.validateEitConditions = Ge;
|
|
42
42
|
}
|
|
43
43
|
function re() {
|
|
@@ -84,11 +84,11 @@ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure:
|
|
|
84
84
|
const n2 = function() {
|
|
85
85
|
let e5 = [], t3 = w(L.pageContext, N.props.base.showOperationCondition);
|
|
86
86
|
if (t3 && Se(null, null, null, null, null, true, "canAdd")) {
|
|
87
|
-
const t4 = { props: { elementType: "el-button", icon: "Plus", type: "primary", circle: true, size: "mini", permission: "true" }, onClick:
|
|
87
|
+
const t4 = { props: { elementType: "el-button", icon: "Plus", type: "primary", circle: true, size: "mini", permission: "true" }, onClick: De, isShow: we };
|
|
88
88
|
e5.push(t4);
|
|
89
89
|
}
|
|
90
90
|
if (t3 && Te(null, null, null, null, null, true)) {
|
|
91
|
-
const t4 = { props: { elementType: "el-button", icon: "Minus", type: "danger", circle: true, size: "mini", permission: "true" }, onClick:
|
|
91
|
+
const t4 = { props: { elementType: "el-button", icon: "Minus", type: "danger", circle: true, size: "mini", permission: "true" }, onClick: Ce, isShow: xe };
|
|
92
92
|
e5.push(t4);
|
|
93
93
|
}
|
|
94
94
|
return I(B, N, e5, me), e5;
|
|
@@ -178,10 +178,10 @@ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure:
|
|
|
178
178
|
let i2 = Te(0, 0, n2, 0, 0, a2);
|
|
179
179
|
return true === i2 && (i2 = w(L.pageContext, N.props.base.showDeleteBtnCondition, n2)), i2;
|
|
180
180
|
}
|
|
181
|
-
function
|
|
181
|
+
function De(e3, t2, n2, o2, l2) {
|
|
182
182
|
ae.value.createRow(G, {}, { getDefaultValueFunc: y }, { originalValue: e3, formatValue: t2, row: n2, column: o2, rowIndex: l2 });
|
|
183
183
|
}
|
|
184
|
-
function
|
|
184
|
+
function Ce(e3, t2, n2, o2, l2) {
|
|
185
185
|
ae.value.deleteRow(l2, G, false);
|
|
186
186
|
}
|
|
187
187
|
function ye(e3) {
|
|
@@ -293,7 +293,7 @@ const $ = e({ __name: "sub-table-runtime", props: { pageContext: {}, configure:
|
|
|
293
293
|
(_a2 = ae.value) == null ? void 0 : _a2.addRequiredClass(e3, G, t2, n2);
|
|
294
294
|
} }), (e3, t2) => {
|
|
295
295
|
const n2 = l("super-grid");
|
|
296
|
-
return i(), a("div", null, [ee.value ? (i(), u(n2, { key: 0, ref_key: "gridRef", ref: ae, url: s(Z) + "/dsc/commons/sub-table", options: oe.value, code: s(G), settings: s(K), onSelect: _e, onSelectAll: ke, onSelectionChange: Me, onCellClick: Ae, onCellDblclick: Fe, onRowClick: $e, onRowDblclick: je, onHeaderClick: Le, onFnProhibitToEdit: Ie, onChangeGridData: ye, onReloadGrid: fe, onRefresMainTableFields: Oe, onSetSelectOptions: Re, onChangeRowsPerPage: Pe, onNewOpenGridDialog: s(R), onChangeFormData: Be }, null, 8, ["url", "options", "code", "settings", "onNewOpenGridDialog"])) : r("", true)]);
|
|
296
|
+
return i(), a("div", null, [ee.value ? (i(), u(n2, { key: 0, ref_key: "gridRef", ref: ae, url: s(Z) + "/dsc/commons/sub-table", options: oe.value, code: s(G), settings: s(K), isDialog: s(B).isDialog, onSelect: _e, onSelectAll: ke, onSelectionChange: Me, onCellClick: Ae, onCellDblclick: Fe, onRowClick: $e, onRowDblclick: je, onHeaderClick: Le, onFnProhibitToEdit: Ie, onChangeGridData: ye, onReloadGrid: fe, onRefresMainTableFields: Oe, onSetSelectOptions: Re, onChangeRowsPerPage: Pe, onNewOpenGridDialog: s(R), onChangeFormData: Be }, null, 8, ["url", "options", "code", "settings", "isDialog", "onNewOpenGridDialog"])) : r("", true)]);
|
|
297
297
|
};
|
|
298
298
|
} });
|
|
299
299
|
export {
|
|
@@ -75,7 +75,7 @@ const f = e({ __name: "table-runtime", props: { pageContext: {}, configure: {} }
|
|
|
75
75
|
}, handleSearch: function(e3, t2) {
|
|
76
76
|
var _a;
|
|
77
77
|
(_a = b.value) == null ? void 0 : _a.handleSearch(e3, t2);
|
|
78
|
-
} }), (
|
|
78
|
+
} }), (e3, t2) => (a(), u("div", null, [r(g) && "form" === r(g) && C.value ? (a(), o(i, { key: 0, ref_key: "gridRef", ref: b, pageContext: e3.pageContext, configure: d.value, onSetSafeDeleteTableCode: E }, null, 8, ["pageContext", "configure"])) : r(g) && "form" === r(g) ? l("", true) : (a(), o(c, { key: 1, ref_key: "gridRef", ref: b, pageContext: e3.pageContext, configure: d.value, onSetSafeDeleteTableCode: E }, null, 8, ["pageContext", "configure"]))]));
|
|
79
79
|
} });
|
|
80
80
|
export {
|
|
81
81
|
f as default
|
|
@@ -104,29 +104,29 @@ const P = { key: 0, class: "custom-tree-node" }, W = ["title"], R = { key: 0, cl
|
|
|
104
104
|
te.value.setCheckedKeys(e3, t2);
|
|
105
105
|
}, setChecked: (e3, t2, a2) => {
|
|
106
106
|
te.value.setChecked(e3, t2, a2);
|
|
107
|
-
}, getCurrentKey: () => te.value.getCurrentKey(), getCurrentNode: () => te.value.getCurrentNode(), setCurrentKey: (e3, t2 = true) => te.value.setCurrentKey(e3, t2), setCurrentNode: (e3, t2 = true) => te.value.setCurrentNode(e3, t2) }), (
|
|
107
|
+
}, getCurrentKey: () => te.value.getCurrentKey(), getCurrentNode: () => te.value.getCurrentNode(), setCurrentKey: (e3, t2 = true) => te.value.setCurrentKey(e3, t2), setCurrentNode: (e3, t2 = true) => te.value.setCurrentNode(e3, t2) }), (e3, t2) => {
|
|
108
108
|
var _a2;
|
|
109
|
-
const
|
|
110
|
-
return i(), u("div", { class: s(["amb-tree-runtime-main", r(ee)]) }, [ae.value.filter ? (i(), c(
|
|
111
|
-
"" !== ce.value ? (
|
|
112
|
-
ye(
|
|
113
|
-
}) : E(
|
|
114
|
-
ye(
|
|
109
|
+
const a2 = d("el-input"), n2 = d("el-button"), l2 = d("SuperIcon"), o2 = d("el-tree");
|
|
110
|
+
return i(), u("div", { class: s(["amb-tree-runtime-main", r(ee)]) }, [ae.value.filter ? (i(), c(a2, { key: 0, modelValue: ue.value, "onUpdate:modelValue": t2[0] || (t2[0] = (e4) => ue.value = e4), style: { width: "100%" }, placeholder: "请输入查询条件" }, null, 8, ["modelValue"])) : p("", true), le.value ? (i(), c(o2, { key: 1, ref_key: "menuTreeRef", ref: te, style: f(r(Z)), load: fe, data: oe.value, "node-key": "nodeId", props: ne.value, "default-expand-all": ae.value.defaultExpandAll, "expand-on-click-node": ae.value.expandOnClickNode, indent: ae.value.retractWidth ? ae.value.retractWidth : 18, accordion: ae.value.accordion, "show-checkbox": !!ae.value.showCheckbox, "highlight-current": "", lazy: J.value, "filter-node-method": pe, onNodeClick: ve, onNodeContextmenu: me }, { default: g(({ node: o3, data: d2 }) => [d2.nodeId === se.value ? (i(), u("div", P, [m(a2, { modelValue: ce.value, "onUpdate:modelValue": t2[1] || (t2[1] = (e4) => ce.value = e4), size: "small" }, null, 8, ["modelValue"]), h("div", null, [m(n2, { type: "primary", link: "", onClick: (e4) => ((e5) => {
|
|
111
|
+
"" !== ce.value ? (e5.data.name = ce.value, re.value && e5.data.nodeId === re.value ? w(e5, X.configure, X.pageContext).then((t3) => {
|
|
112
|
+
ye(e5, t3.currentNode), Ce(), z.success("保存成功!");
|
|
113
|
+
}) : E(e5, X.configure, X.pageContext).then((t3) => {
|
|
114
|
+
ye(e5, t3.currentNode), Ce(), z.success("保存成功!");
|
|
115
115
|
})) : z.warning("请输入节点名称");
|
|
116
|
-
})(
|
|
117
|
-
re.value &&
|
|
118
|
-
})(
|
|
119
|
-
if (ge.value && "standard" ===
|
|
120
|
-
else if ("delete" ===
|
|
121
|
-
ke(
|
|
116
|
+
})(o3) }, { default: g(() => t2[2] || (t2[2] = [y(" 保存 ")])), _: 2 }, 1032, ["onClick"]), m(n2, { style: { "margin-left": "4px" }, type: "primary", link: "", onClick: (t3) => ((e4) => {
|
|
117
|
+
re.value && e4.data.nodeId === re.value && te.value.remove(e4), Ce();
|
|
118
|
+
})(o3, e3.configure, e3.pageContext) }, { default: g(() => t2[3] || (t2[3] = [y(" 撤销 ")])), _: 2 }, 1032, ["onClick"])])])) : (i(), u("span", { key: 1, title: o3.label, class: "ellipsis" }, [d2.iconValue ? (i(), c(l2, { key: 0, iconType: d2.iconType, iconValue: d2.iconValue }, null, 8, ["iconType", "iconValue"])) : ae.value.iconValue ? (i(), c(l2, { key: 1, iconType: ae.value.iconType, iconValue: ae.value.iconValue }, null, 8, ["iconType", "iconValue"])) : (i(), u(C, { key: 2 }, [d2.isLeaf ? (i(), u("div", H, [t2[5] || (t2[5] = h("img", { src: I, class: "file" }, null, -1)), h("span", null, x(d2.name), 1)])) : (i(), u("div", R, [h("div", D, [t2[4] || (t2[4] = h("img", { src: T, class: "file" }, null, -1)), h("span", null, x(d2.name), 1)])]))], 64))], 8, W))]), _: 1 }, 8, ["style", "data", "props", "default-expand-all", "expand-on-click-node", "indent", "accordion", "show-checkbox", "lazy"])) : p("", true), v(h("div", null, [h("ul", { ref_key: "contxtMenuRef", ref: $, class: "context-menu" }, [(i(true), u(C, null, k(q.value, (e4, t3) => (i(), u("li", { key: t3, tabindex: "-1", class: "menu__item", onClick: (t4) => ((e5) => {
|
|
119
|
+
if (ge.value && "standard" === e5.type && e5.standardEvent) if ("edit" === e5.standardEvent) se.value = ge.value.data.nodeId, ce.value = ge.value.data.name;
|
|
120
|
+
else if ("delete" === e5.standardEvent) ge.value.childNodes && ge.value.childNodes.length > 0 && e5.deleteParentNodeTip ? (e5.deleteParentNodeTipMessage || (e5.deleteParentNodeTipMessage = "当前节点下有子节点,确认删除?"), S.confirm(e5.deleteParentNodeTipMessage, { confirmButtonText: "确定", cancelButtonText: "取消", type: "error" }).then(() => {
|
|
121
|
+
ke(e5);
|
|
122
122
|
}).catch(() => {
|
|
123
123
|
ge.value = null;
|
|
124
|
-
})) : ke(
|
|
124
|
+
})) : ke(e5);
|
|
125
125
|
else {
|
|
126
126
|
const t5 = xe();
|
|
127
|
-
se.value = t5.nodeId, re.value = t5.nodeId, ce.value = t5.name, "addSiblingNode" ===
|
|
127
|
+
se.value = t5.nodeId, re.value = t5.nodeId, ce.value = t5.name, "addSiblingNode" === e5.standardEvent ? (t5.isLeaf = ge.value.data.isLeaf, ge.value.parent && ge.value.parent.level > 0 ? te.value.append(t5, ge.value.parent) : oe.value.push(t5)) : "addChildNode" === e5.standardEvent && (t5.isLeaf = true, ge.value.data.isLeaf = false, te.value.append(t5, ge.value), te.value.setCurrentKey(t5.nodeId, true));
|
|
128
128
|
}
|
|
129
|
-
})(
|
|
129
|
+
})(e4) }, [h("span", null, x(e4.name), 1)], 8, O))), 128))], 512)], 512), [[N, A.value && ((_a2 = q.value) == null ? void 0 : _a2.length) > 0]])], 2);
|
|
130
130
|
};
|
|
131
131
|
} });
|
|
132
132
|
export {
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { defineComponent as e, ref as t, computed as l, onMounted as o, nextTick as n, resolveComponent as a, createBlock as u, openBlock as i, normalizeStyle as r, normalizeClass as s, unref as p, withCtx as c, createVNode as f, createElementBlock as g, Fragment as v, renderList as d, createCommentVNode as m, toDisplayString as h } from "vue";
|
|
2
|
-
import { setVariableValue as y, getVariableValue as x, getOptionDatasFromPage as
|
|
3
|
-
import { getFormModelFields as
|
|
4
|
-
import { handleFormEvent as
|
|
5
|
-
import { $t as
|
|
6
|
-
import { addRequiredClassUtil as
|
|
2
|
+
import { setVariableValue as y, getVariableValue as x, getOptionDatasFromPage as b, monitorFieldChange as C, autoSetAfterSelect as k, queryOptionDatasources as S } from "../../../../utils/page-helper-util.js";
|
|
3
|
+
import { getFormModelFields as j } from "../../../../utils/page-init-util.js";
|
|
4
|
+
import { handleFormEvent as R, handleAfterInitEvent as _ } from "../../../../utils/events/event-util.js";
|
|
5
|
+
import { $t as I } from "../../../../utils/i18n-util.js";
|
|
6
|
+
import { addRequiredClassUtil as q } from "../../../../utils/common-util.js";
|
|
7
7
|
const V = e({ __name: "checkbox-runtime", props: { pageContext: {}, configure: {} }, setup(e2, { expose: V2 }) {
|
|
8
8
|
const w = e2, z = t(null), D = w.pageContext.entity ? w.pageContext.entity : {};
|
|
9
|
-
let
|
|
10
|
-
const
|
|
11
|
-
let e3 = x(D,
|
|
9
|
+
let E = j(w.pageContext, w.configure);
|
|
10
|
+
const O = l({ get() {
|
|
11
|
+
let e3 = x(D, E);
|
|
12
12
|
return e3 && "string" == typeof e3 && (e3 = e3.split(",")), e3;
|
|
13
13
|
}, set(e3) {
|
|
14
|
-
e3 && e3.length > 0 && (e3 = e3.join(",")), y(D,
|
|
15
|
-
} }),
|
|
14
|
+
e3 && e3.length > 0 && (e3 = e3.join(",")), y(D, E, e3), null != e3 && (z.value = "");
|
|
15
|
+
} }), A = w.configure.runtime ? w.configure.runtime : {}, M = A.style, P = A.class, T = A.headerStyle, F = A.titleExceedStyle, U = t(A.props ? A.props : {}), W = t(U.value.options ? U.value.options : []), B = b(w.pageContext, w.configure);
|
|
16
16
|
B.length > 0 && (W.value = B);
|
|
17
17
|
const G = w.configure.props && w.configure.props.dataOrigin ? w.configure.props.dataOrigin : {}, H = G.optionValueSetType;
|
|
18
18
|
let J = [];
|
|
@@ -22,27 +22,41 @@ const V = e({ __name: "checkbox-runtime", props: { pageContext: {}, configure: {
|
|
|
22
22
|
let t2 = null;
|
|
23
23
|
W.value && null != e3 && null != e3 && (t2 = W.value.filter((t3) => Array.isArray(e3) ? e3.includes(t3.value) : e3 === t3.value)), k(w.configure, w.pageContext, J, t2);
|
|
24
24
|
}
|
|
25
|
-
|
|
25
|
+
R(e3, w.pageContext, w.configure, "change");
|
|
26
26
|
};
|
|
27
27
|
const K = U.value.optionconfigInfo ? U.value.optionconfigInfo : {};
|
|
28
28
|
const L = U.value.monitorFields;
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
C(w.pageContext, L, function() {
|
|
30
|
+
S(w.pageContext, K, void 0).then((e3) => {
|
|
31
31
|
});
|
|
32
32
|
});
|
|
33
33
|
const N = t(null), Q = t(null), X = t(null);
|
|
34
34
|
return o(() => {
|
|
35
35
|
n(() => {
|
|
36
|
-
const e3 =
|
|
37
|
-
|
|
36
|
+
const e3 = O.value;
|
|
37
|
+
_(e3, w.pageContext, w.configure, { formItemRef: N.value, componentRef: Q.value, titleRef: X.value, value: e3, entity: w.pageContext.entity.data, pageData: w.pageContext.entity.page });
|
|
38
38
|
});
|
|
39
39
|
}), V2({ updateOptions: function(e3) {
|
|
40
40
|
W.value = e3 || [];
|
|
41
41
|
}, addRequiredClass: function() {
|
|
42
|
-
z.value =
|
|
43
|
-
}
|
|
44
|
-
const
|
|
45
|
-
|
|
42
|
+
z.value = q();
|
|
43
|
+
}, getSelectItemsTitle: function() {
|
|
44
|
+
const e3 = function() {
|
|
45
|
+
let e4 = x(D, E);
|
|
46
|
+
return null != e4 && (e4 = String(e4)), e4;
|
|
47
|
+
}();
|
|
48
|
+
if (null != e3 && "" !== e3 && e3.length > 0) {
|
|
49
|
+
let t2 = "";
|
|
50
|
+
const l2 = e3.split(",");
|
|
51
|
+
return W.value.length > 0 ? (W.value.forEach((e4) => {
|
|
52
|
+
l2.forEach((l3) => {
|
|
53
|
+
e4.value === l3 && (t2 = t2 + e4.label + ",");
|
|
54
|
+
});
|
|
55
|
+
}), t2 = t2.slice(0, t2.length - 1)) : t2 = e3.join(","), t2;
|
|
56
|
+
}
|
|
57
|
+
} }), (e3, t2) => {
|
|
58
|
+
const l2 = a("el-checkbox"), o2 = a("el-checkbox-group"), n2 = a("el-form-item");
|
|
59
|
+
return i(), u(n2, { ref_key: "formItemRef", ref: N, class: s(p(P) + (z.value ? " " + z.value : "")), required: !!U.value.required, "label-width": U.value.labelWidth, style: r(p(M)) }, { label: c(() => [U.value.tittleShow ? (i(), g("div", { key: 0, ref_key: "titleRef", ref: X, style: r({ ...p(T), ...p(F) }) }, h(p(I)(U.value.title)), 5)) : m("", true)]), default: c(() => [f(o2, { ref_key: "componentRef", ref: Q, disabled: "disabled" === U.value.state, size: U.value.size, onChange: U.value.changeMethod, modelValue: O.value, "onUpdate:modelValue": t2[0] || (t2[0] = (e4) => O.value = e4) }, { default: c(() => [(i(true), g(v, null, d(W.value, (t3) => (i(), u(l2, { key: t3.value, value: t3.value, label: t3.label, onClick: (l3) => p(R)(t3.value, e3.pageContext, e3.configure, "click", { values: O.value }) }, null, 8, ["value", "label", "onClick"]))), 128))]), _: 1 }, 8, ["disabled", "size", "onChange", "modelValue"])]), _: 1 }, 8, ["class", "required", "label-width", "style"]);
|
|
46
60
|
};
|
|
47
61
|
} });
|
|
48
62
|
export {
|
|
@@ -28,9 +28,9 @@ const x = e({ __name: "title-suffix-element", props: { pageContext: {}, property
|
|
|
28
28
|
const r2 = l2.indexOf(h);
|
|
29
29
|
e3 ? -1 == r2 && l2.push(h) : r2 > -1 && l2.splice(r2, 1), y(c, d, l2);
|
|
30
30
|
} else y(c, d, e3);
|
|
31
|
-
} })), (
|
|
32
|
-
const
|
|
33
|
-
return p(), t(o, null, ["radio" ===
|
|
31
|
+
} })), (e3, l2) => {
|
|
32
|
+
const s2 = r("el-radio"), y2 = r("el-checkbox");
|
|
33
|
+
return p(), t(o, null, ["radio" === e3.property.prefixType ? (p(), u(s2, { key: 0, value: e3.property.prefixValue, label: e3.property.title, modelValue: i(b), "onUpdate:modelValue": l2[0] || (l2[0] = (e4) => n(b) ? b.value = e4 : b = e4) }, null, 8, ["value", "label", "modelValue"])) : a("", true), "checkbox" === e3.property.prefixType ? (p(), u(y2, { key: 1, label: e3.property.title, value: e3.property.prefixValue, modelValue: i(b), "onUpdate:modelValue": l2[1] || (l2[1] = (e4) => n(b) ? b.value = e4 : b = e4) }, null, 8, ["label", "value", "modelValue"])) : a("", true)], 64);
|
|
34
34
|
};
|
|
35
35
|
} });
|
|
36
36
|
export {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as e, computed as t, ref as o, onMounted as n, nextTick as a, onUnmounted as i, resolveComponent as u, createBlock as l, createElementBlock as r, createCommentVNode as s, openBlock as p, normalizeStyle as c, normalizeClass as f, unref as
|
|
1
|
+
import { defineComponent as e, computed as t, ref as o, onMounted as n, nextTick as a, onUnmounted as i, resolveComponent as u, createBlock as l, createElementBlock as r, createCommentVNode as s, openBlock as p, normalizeStyle as c, normalizeClass as f, unref as m, withCtx as d, resolveDynamicComponent as g, toDisplayString as v } from "vue";
|
|
2
2
|
import { getFormModelFields as C } from "../../../../utils/page-init-util.js";
|
|
3
3
|
import { setVariableValue as x, getVariableValue as y, formatVariableValue as b, getFormPropName as h, setVariableValueWithProp as j } from "../../../../utils/page-helper-util.js";
|
|
4
4
|
import { handleAfterInitEvent as R, handleEvent as k } from "../../../../utils/events/event-util.js";
|
|
@@ -24,7 +24,7 @@ const U = { key: 0, style: { width: "100%", height: "100%" } }, q = { key: 1, st
|
|
|
24
24
|
j(z, e3, t2);
|
|
25
25
|
}
|
|
26
26
|
function N(e3) {
|
|
27
|
-
S.isHasFieldAuthPermission(O.configure)
|
|
27
|
+
S.isHasFieldAuthPermission(O.configure) && V(O.pageContext, e3);
|
|
28
28
|
}
|
|
29
29
|
function Q() {
|
|
30
30
|
const e3 = O.pageContext.tableUuids;
|
|
@@ -43,7 +43,7 @@ const U = { key: 0, style: { width: "100%", height: "100%" } }, q = { key: 1, st
|
|
|
43
43
|
const t2 = e3.result;
|
|
44
44
|
x(z, G, t2);
|
|
45
45
|
}), F.$on(X.value + "-pickFileDone", (e3) => {
|
|
46
|
-
|
|
46
|
+
Y.value.pickFileDone(e3);
|
|
47
47
|
}), a(() => {
|
|
48
48
|
const e3 = H.value;
|
|
49
49
|
R(e3, O.pageContext, O.configure, { formItemRef: Z.value, componentRef: Y.value, titleRef: ee.value, value: e3, entity: O.pageContext.entity.data, pageData: O.pageContext.entity.page });
|
|
@@ -59,9 +59,9 @@ const U = { key: 0, style: { width: "100%", height: "100%" } }, q = { key: 1, st
|
|
|
59
59
|
return Y.value && "function" == typeof Y.value[e3];
|
|
60
60
|
}, addRequiredClass: function() {
|
|
61
61
|
requiredClass.value = addRequiredClassUtil();
|
|
62
|
-
} }), (
|
|
63
|
-
const
|
|
64
|
-
return W.value.tittleShow ? (p(), l(
|
|
62
|
+
} }), (e3, t2) => {
|
|
63
|
+
const o2 = u("el-form-item");
|
|
64
|
+
return W.value.tittleShow ? (p(), l(o2, { key: 0, ref_key: "formItemRef", ref: Z, required: W.value.required, class: f(m(A)), "label-width": W.value.labelWidth, style: c(m(I)) }, { label: d(() => [W.value.tittleShow ? (p(), r("div", { key: 0, ref_key: "titleRef", ref: ee, style: c({ ...m(B) }) }, v(m(E)(W.value.title)), 5)) : s("", true)]), default: d(() => [L.value ? (p(), r("div", U, [(p(), l(g(L.value), { ref_key: "customRef", ref: Y, size: W.value.size, entity: e3.pageContext.entity.data, pageData: e3.pageContext.entity.page, pageContext: e3.pageContext, configureObj: e3.configure, prop: m(h)(e3.configure.props && e3.configure.props.base ? e3.configure.props.base.prop : null), "custom-params": m(J), modelValue: H.value, "onUpdate:modelValue": t2[0] || (t2[0] = (e4) => H.value = e4), disabled: "disabled" === W.value.state, "additional-param-map": m(K), "component-id": X.value, onSetEntityValue: M, onSetCustomRules: N, onRestoreGridEdit: Q, onHandleEvent: te, onChange: t2[1] || (t2[1] = (t3) => m(k)(H.value, e3.pageContext, e3.configure, "change")) }, null, 40, ["size", "entity", "pageData", "pageContext", "configureObj", "prop", "custom-params", "modelValue", "disabled", "additional-param-map", "component-id"]))])) : s("", true)]), _: 1 }, 8, ["required", "class", "label-width", "style"])) : L.value ? (p(), r("div", q, [(p(), l(g(L.value), { ref_key: "customRef", ref: Y, entity: e3.pageContext.entity.data, pageData: e3.pageContext.entity.page, pageContext: e3.pageContext, configureObj: e3.configure, prop: m(h)(e3.configure.props && e3.configure.props.base ? e3.configure.props.base.prop : null), "custom-params": m(J), modelValue: H.value, "onUpdate:modelValue": t2[2] || (t2[2] = (e4) => H.value = e4), disabled: "disabled" === W.value.state, "additional-param-map": m(K), "component-id": X.value, onSetEntityValue: M, onSetCustomRules: N, onRestoreGridEdit: Q, onHandleEvent: te, onChange: t2[3] || (t2[3] = (t3) => m(k)(H.value, e3.pageContext, e3.configure, "change")) }, null, 40, ["entity", "pageData", "pageContext", "configureObj", "prop", "custom-params", "modelValue", "disabled", "additional-param-map", "component-id"]))])) : s("", true);
|
|
65
65
|
};
|
|
66
66
|
} });
|
|
67
67
|
export {
|
package/dist/es/components/runtime/views/assemblys/form/date-picker/datepicker-runtime.vue2.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as e, ref as a, onMounted as l, nextTick as t, computed as o, resolveComponent as u, createBlock as r, openBlock as n, normalizeStyle as i, normalizeClass as
|
|
1
|
+
import { defineComponent as e, ref as a, onMounted as l, nextTick as t, computed as o, resolveComponent as u, createBlock as r, openBlock as n, normalizeStyle as i, normalizeClass as p, unref as s, withCtx as c, createElementBlock as d, createCommentVNode as v, Fragment as f, createTextVNode as g, toDisplayString as m } from "vue";
|
|
2
2
|
import { getFormModelFields as h } from "../../../../utils/page-init-util.js";
|
|
3
3
|
import { getDateShortCuts as y } from "../../../../utils/form/date-shortcuts.js";
|
|
4
|
-
import { getModelFieldFromPageContext as C, getValueFromVariable as x, setVariableValue as b, getVariableValue as
|
|
4
|
+
import { getModelFieldFromPageContext as C, getValueFromVariable as x, setVariableValue as b, getVariableValue as k, isDateDataType as F } from "../../../../utils/page-helper-util.js";
|
|
5
5
|
import { handleAfterInitEvent as T, getCustomFunc as V, handleFormEvent as j } from "../../../../utils/events/event-util.js";
|
|
6
6
|
import R from "../common/title-suffix-element.vue.js";
|
|
7
7
|
import Y from "dayjs";
|
|
@@ -9,30 +9,30 @@ import { $t as _ } from "../../../../utils/i18n-util.js";
|
|
|
9
9
|
import { addRequiredClassUtil as z } from "../../../../utils/common-util.js";
|
|
10
10
|
const D = e({ __name: "datepicker-runtime", props: { pageContext: {}, configure: {} }, setup(e2, { expose: D2 }) {
|
|
11
11
|
var _a;
|
|
12
|
-
const P = e2, S = a(null), w = P.pageContext.entity ? P.pageContext.entity : {}, q = P.configure.runtime ? P.configure.runtime : {}, A = q.style,
|
|
13
|
-
let
|
|
14
|
-
if (P.pageContext.modelFieldsMap &&
|
|
15
|
-
const e3 = C(
|
|
12
|
+
const P = e2, S = a(null), w = P.pageContext.entity ? P.pageContext.entity : {}, q = P.configure.runtime ? P.configure.runtime : {}, A = q.style, I = q.class, M = q.headerStyle, B = q.titleExceedStyle, N = a(q.props ? q.props : {});
|
|
13
|
+
let U = h(P.pageContext, P.configure, N.value.prop);
|
|
14
|
+
if (P.pageContext.modelFieldsMap && U && U.length > 0 && "data" === U[0]) {
|
|
15
|
+
const e3 = C(U, P.pageContext);
|
|
16
16
|
e3 && function(e4) {
|
|
17
17
|
const a2 = e4.dataType;
|
|
18
|
-
|
|
18
|
+
F(a2) && ("year" === N.value.dateType && "YYYY" === N.value.valueFormat || "month" === N.value.dateType && "YYYY-MM" === N.value.valueFormat) && (N.value.valueFormat = "x");
|
|
19
19
|
}(e3);
|
|
20
20
|
}
|
|
21
|
-
let
|
|
22
|
-
if (
|
|
23
|
-
|
|
24
|
-
let e3 =
|
|
21
|
+
let W = null, $ = false;
|
|
22
|
+
if (N.value.dateType && N.value.dateType.includes("range")) {
|
|
23
|
+
$ = true;
|
|
24
|
+
let e3 = N.value.prop2;
|
|
25
25
|
e3 && e3.startsWith("${") || (e3 = "${page." + P.configure.uuid + "-2}");
|
|
26
26
|
const a2 = x(w, e3, null);
|
|
27
|
-
if (e3 = e3.substring(2, e3.length - 1),
|
|
28
|
-
const e4 = x(w,
|
|
29
|
-
if (null != e4 && "" !== e4) b(w,
|
|
30
|
-
else if (((_a =
|
|
31
|
-
const e5 =
|
|
27
|
+
if (e3 = e3.substring(2, e3.length - 1), W = e3.split("."), !(a2 || w.data && (w.data.id || w.data.ID)) && N.value.defaultValue2) {
|
|
28
|
+
const e4 = x(w, N.value.defaultValue2);
|
|
29
|
+
if (null != e4 && "" !== e4) b(w, W, e4);
|
|
30
|
+
else if (((_a = N.value.moreDefaultValue2) == null ? void 0 : _a.length) > 0) {
|
|
31
|
+
const e5 = N.value.moreDefaultValue2;
|
|
32
32
|
for (let a3 = 0; a3 < e5.length; a3++) {
|
|
33
33
|
const l2 = x(w, e5[a3]);
|
|
34
34
|
if (null != l2 && "" !== l2) {
|
|
35
|
-
b(w,
|
|
35
|
+
b(w, W, l2);
|
|
36
36
|
break;
|
|
37
37
|
}
|
|
38
38
|
}
|
|
@@ -49,7 +49,7 @@ const D = e({ __name: "datepicker-runtime", props: { pageContext: {}, configure:
|
|
|
49
49
|
let t2 = null;
|
|
50
50
|
return t2 = "x" === a2 ? l2.toDate().getTime() : Y(e3).format(a2), t2;
|
|
51
51
|
} catch (a3) {
|
|
52
|
-
return
|
|
52
|
+
return e3;
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
return e3;
|
|
@@ -59,28 +59,28 @@ const D = e({ __name: "datepicker-runtime", props: { pageContext: {}, configure:
|
|
|
59
59
|
const e3 = J.value;
|
|
60
60
|
T(e3, P.pageContext, P.configure, { formItemRef: E.value, componentRef: O.value, titleRef: G.value, value: e3, entity: P.pageContext.entity.data, pageData: P.pageContext.entity.page });
|
|
61
61
|
});
|
|
62
|
-
}),
|
|
63
|
-
const e3 =
|
|
64
|
-
e3 !== a2 && b(w, N, a2);
|
|
65
|
-
}
|
|
66
|
-
if (U) {
|
|
67
|
-
const e3 = F(w, U), a2 = H(e3, B.value.valueFormat);
|
|
62
|
+
}), U) {
|
|
63
|
+
const e3 = k(w, U), a2 = H(e3, N.value.valueFormat);
|
|
68
64
|
e3 !== a2 && b(w, U, a2);
|
|
69
65
|
}
|
|
66
|
+
if (W) {
|
|
67
|
+
const e3 = k(w, W), a2 = H(e3, N.value.valueFormat);
|
|
68
|
+
e3 !== a2 && b(w, W, a2);
|
|
69
|
+
}
|
|
70
70
|
const J = o({ get() {
|
|
71
|
-
if (
|
|
71
|
+
if ($) {
|
|
72
72
|
const e3 = [];
|
|
73
|
-
let a2 =
|
|
74
|
-
e3.push(H(a2,
|
|
75
|
-
let l2 =
|
|
76
|
-
return e3.push(H(l2,
|
|
73
|
+
let a2 = k(w, U);
|
|
74
|
+
e3.push(H(a2, N.value.valueFormat));
|
|
75
|
+
let l2 = k(w, W);
|
|
76
|
+
return e3.push(H(l2, N.value.valueFormat)), e3;
|
|
77
77
|
}
|
|
78
|
-
return H(
|
|
78
|
+
return H(k(w, U), N.value.valueFormat);
|
|
79
79
|
}, set(e3) {
|
|
80
|
-
|
|
81
|
-
} }), K = a(y(
|
|
82
|
-
if (
|
|
83
|
-
const e3 = V(P.pageContext,
|
|
80
|
+
$ ? Array.isArray(e3) ? (b(w, U, e3[0]), b(w, W, e3[1]), S.value = "") : null === e3 && (b(w, U, null), b(w, W, null)) : (b(w, U, e3), null != e3 && (S.value = ""));
|
|
81
|
+
} }), K = a(y(N.value.dateScopeDetails, N.value.sourceType, N.value.dateType));
|
|
82
|
+
if (N.value.shortcutsFunc) {
|
|
83
|
+
const e3 = V(P.pageContext, N.value.shortcutsFunc);
|
|
84
84
|
if (e3) {
|
|
85
85
|
let a2 = e3.apply(e3, [{ pageContext: P.pageContext, configureObj: P.configure }]);
|
|
86
86
|
if (a2) {
|
|
@@ -91,9 +91,9 @@ const D = e({ __name: "datepicker-runtime", props: { pageContext: {}, configure:
|
|
|
91
91
|
}
|
|
92
92
|
return D2({ addRequiredClass: function() {
|
|
93
93
|
S.value = z();
|
|
94
|
-
} }), (
|
|
95
|
-
const
|
|
96
|
-
return n(), r(
|
|
94
|
+
} }), (e3, a2) => {
|
|
95
|
+
const l2 = u("el-time-picker"), t2 = u("el-date-picker"), o2 = u("el-form-item");
|
|
96
|
+
return n(), r(o2, { ref_key: "formItemRef", ref: E, required: N.value.required, class: p(s(I) + (S.value ? " " + S.value : "")), "label-width": N.value.labelWidth, style: i(s(A)) }, { label: c(() => [N.value.tittleShow ? (n(), d("div", { key: 0, ref_key: "titleRef", ref: G, style: i({ ...s(M), ...s(B) }) }, [N.value.prefixType ? (n(), r(R, { key: 0, pageContext: e3.pageContext, property: N.value }, null, 8, ["pageContext", "property"])) : (n(), d(f, { key: 1 }, [g(m(s(_)(N.value.title)), 1)], 64))], 4)) : v("", true)]), default: c(() => ["time" == N.value.dateType || "timerange" == N.value.dateType ? (n(), r(l2, { key: 0, ref_key: "componentRef", ref: O, "is-range": "timerange" == N.value.dateType, style: { width: "100%" }, "range-separator": "-", clearable: N.value.clearable, disabled: "disabled" === N.value.state, readonly: "readonly" === N.value.state, size: N.value.size, placeholder: N.value.placeholder, "start-placeholder": N.value.placeholder, "end-placeholder": N.value.endPlaceholder ? N.value.endPlaceholder : N.value.placeholder, "unlink-panels": true, format: N.value.format, "value-format": N.value.valueFormat, modelValue: J.value, "onUpdate:modelValue": a2[0] || (a2[0] = (e4) => J.value = e4), shortcuts: K.value, type: N.value.dateType, onChange: a2[1] || (a2[1] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "change")), onBlur: a2[2] || (a2[2] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "blur")), onFocus: a2[3] || (a2[3] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "focus")), onVisibleChange: a2[4] || (a2[4] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "visible-change")), onPanelChange: a2[5] || (a2[5] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "panel-change")), onClear: a2[6] || (a2[6] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "clear")) }, null, 8, ["is-range", "clearable", "disabled", "readonly", "size", "placeholder", "start-placeholder", "end-placeholder", "format", "value-format", "modelValue", "shortcuts", "type"])) : (n(), r(t2, { key: 1, ref_key: "componentRef", ref: O, clearable: N.value.clearable, style: { width: "100%" }, "unlink-panels": true, disabled: "disabled" === N.value.state, readonly: "readonly" === N.value.state, size: N.value.size, placeholder: N.value.placeholder, "start-placeholder": N.value.placeholder, "end-placeholder": N.value.endPlaceholder ? N.value.endPlaceholder : N.value.placeholder, format: N.value.format, "value-format": N.value.valueFormat, modelValue: J.value, "onUpdate:modelValue": a2[7] || (a2[7] = (e4) => J.value = e4), shortcuts: K.value, type: N.value.dateType, onChange: a2[8] || (a2[8] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "change")), onBlur: a2[9] || (a2[9] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "blur")), onFocus: a2[10] || (a2[10] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "focus")), onVisibleChange: a2[11] || (a2[11] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "visible-change")), onPanelChange: a2[12] || (a2[12] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "panel-change")), onClear: a2[13] || (a2[13] = (a3) => s(j)(a3, e3.pageContext, e3.configure, "clear")) }, null, 8, ["clearable", "disabled", "readonly", "size", "placeholder", "start-placeholder", "end-placeholder", "format", "value-format", "modelValue", "shortcuts", "type"]))]), _: 1 }, 8, ["required", "class", "label-width", "style"]);
|
|
97
97
|
};
|
|
98
98
|
} });
|
|
99
99
|
export {
|