super-page-runtime 2.3.39 → 2.3.40-cdn1
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 +2 -2
- package/dist/es/components/runtime/utils/events/standard-event.d.ts +8 -1
- package/dist/es/components/runtime/utils/events/standard-event.js +449 -441
- package/dist/es/components/runtime/utils/page-helper-util.d.ts +7 -0
- package/dist/es/components/runtime/utils/page-helper-util.js +4 -0
- package/dist/es/components/runtime/utils/page-store.js +9 -9
- package/dist/es/components/runtime/views/assemblys/common/task-informition-dialog.vue.js +7 -7
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue.js +3 -3
- package/dist/es/components/runtime/views/assemblys/container/card/card-runtime.vue2.js +22 -15
- package/dist/es/components/runtime/views/assemblys/form/checkbox/checkbox-runtime.vue2.js +37 -35
- package/dist/es/components/runtime/views/assemblys/form/radio/radio-runtime.vue2.js +47 -45
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue.js +1 -1
- package/dist/es/components/runtime/views/assemblys/form/select/select-runtime.vue2.js +87 -87
- package/dist/es/components/runtime/views/assemblys/workflow/component/workflow-opinion-box.vue.js +1 -1
- package/dist/es/components/runtime/views/super-page.vue.js +1 -1
- package/dist/es/components/runtime/views/super-page.vue2.js +66 -64
- package/dist/es/style.css +102 -102
- package/package.json +2 -2
|
@@ -57,6 +57,13 @@ export declare function getComponentOptionDatasFromPage(pageContext: PageContext
|
|
|
57
57
|
* @param configure
|
|
58
58
|
*/
|
|
59
59
|
export declare function getOptionDatasSourceMap(pageContext: PageContext): any;
|
|
60
|
+
/**
|
|
61
|
+
* 将查询到的选项组数据缓存到页面上下文中
|
|
62
|
+
* @param pageContext
|
|
63
|
+
* @param configureUuid
|
|
64
|
+
* @param options
|
|
65
|
+
*/
|
|
66
|
+
export declare function putToOptionSourceMap(pageContext: PageContext, configureUuid: string, options: any): void;
|
|
60
67
|
/**
|
|
61
68
|
* 从页面缓存中获取查询到的统计图数据
|
|
62
69
|
* @param pageContext
|
|
@@ -138,6 +138,9 @@ function getOptionDatasSourceMap(t) {
|
|
|
138
138
|
const e = t.optionSourceMap;
|
|
139
139
|
return e || {};
|
|
140
140
|
}
|
|
141
|
+
function putToOptionSourceMap(t, e, o) {
|
|
142
|
+
t.optionSourceMap || (t.optionSourceMap = {}), t.optionSourceMap[e] = o;
|
|
143
|
+
}
|
|
141
144
|
function getChartDatasFromPage(t, e) {
|
|
142
145
|
if (!t || !t.chartDataSourceMap || !e) return null;
|
|
143
146
|
return t.chartDataSourceMap[e.uuid];
|
|
@@ -377,6 +380,7 @@ export {
|
|
|
377
380
|
isNumberDataType,
|
|
378
381
|
isPromise,
|
|
379
382
|
monitorFieldChange,
|
|
383
|
+
putToOptionSourceMap,
|
|
380
384
|
queryOptionDatasources,
|
|
381
385
|
setValueForVariableName,
|
|
382
386
|
setVariableValue,
|
|
@@ -4,33 +4,33 @@ import n from "./eventBus.js";
|
|
|
4
4
|
const u = t("pageContextUtil", () => {
|
|
5
5
|
const t2 = e({ systemCode: "", systemVersion: -1 }), u2 = e(false), a = e(false), i = e(false), l = e([]), r = e(0), s = e(0);
|
|
6
6
|
let v = null, c = -1, d = -1, m = 0;
|
|
7
|
-
function
|
|
7
|
+
function p() {
|
|
8
8
|
v && clearTimeout(v), v = setTimeout(() => {
|
|
9
9
|
o(() => {
|
|
10
10
|
!function() {
|
|
11
11
|
const e2 = r.value, o2 = s.value;
|
|
12
|
-
if (m++, m >= 100) return void (e2 > 0 && e2 === o2 &&
|
|
12
|
+
if (m++, m >= 100) return void (e2 > 0 && e2 === o2 && f(true));
|
|
13
13
|
if (e2 > 0 && e2 === o2) {
|
|
14
|
-
if (e2 === c && o2 === d && !u2.value) return void
|
|
15
|
-
c = e2, d = o2,
|
|
16
|
-
} else c = -1, d = -1,
|
|
14
|
+
if (e2 === c && o2 === d && !u2.value) return void f(true);
|
|
15
|
+
c = e2, d = o2, p();
|
|
16
|
+
} else c = -1, d = -1, p();
|
|
17
17
|
}();
|
|
18
18
|
});
|
|
19
19
|
}, 30);
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function f(e2) {
|
|
22
22
|
u2.value = e2, C();
|
|
23
23
|
}
|
|
24
24
|
function C() {
|
|
25
|
-
u2.value
|
|
25
|
+
!u2.value || !a.value && "list" !== t2.value.pageType || i.value || (n.$emit("pageLoaded"), i.value = true);
|
|
26
26
|
}
|
|
27
27
|
return { pageContext: t2, setPageContext: function(e2) {
|
|
28
28
|
t2.value = e2;
|
|
29
29
|
}, countComponentsTotalNmber: function() {
|
|
30
30
|
r.value++, u2.value = false, i.value = false;
|
|
31
31
|
}, countComponentsLoadedNumber: function() {
|
|
32
|
-
s.value++,
|
|
33
|
-
}, componentsTotalNmber: r, componentsLoadedNumber: s, setPageComponentsLoaded:
|
|
32
|
+
s.value++, p();
|
|
33
|
+
}, componentsTotalNmber: r, componentsLoadedNumber: s, setPageComponentsLoaded: f, setFormPageDataLoadState: function(e2) {
|
|
34
34
|
a.value = e2, C();
|
|
35
35
|
}, formPageDataLoaded: a, pageComponentsLoaded: u2, restorePageLoadState: function() {
|
|
36
36
|
u2.value = false, a.value = false, i.value = false;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { defineComponent as e, ref as l, resolveComponent as t, createElementBlock as a, openBlock as o, createVNode as n, withCtx as s, createTextVNode as u, toDisplayString as
|
|
1
|
+
import { defineComponent as e, ref as l, resolveComponent as t, createElementBlock as a, openBlock as o, createVNode as n, withCtx as s, createTextVNode as u, toDisplayString as i, createElementVNode as d } from "vue";
|
|
2
2
|
import { ElMessage as r } from "element-plus";
|
|
3
|
-
import { useI18n as
|
|
4
|
-
const
|
|
5
|
-
const { t: f } =
|
|
3
|
+
import { useI18n as m } from "vue-i18n";
|
|
4
|
+
const p = { class: "dialog-footer" }, c = e({ __name: "task-informition-dialog", props: { taskInformitions: { type: Array, default: null } }, emits: ["open", "opend", "close", "closed", "result"], setup(e2, { emit: c2 }) {
|
|
5
|
+
const { t: f } = m(), g = e2, b = c2, v = l(null), h = l();
|
|
6
6
|
function y() {
|
|
7
7
|
v.value ? b("result", v.value) : r({ showClose: true, type: "warning", message: f("superPageRuntimeMessage.pleaseSelectNode") });
|
|
8
8
|
}
|
|
9
|
-
function
|
|
9
|
+
function _(e3) {
|
|
10
10
|
v.value = g.taskInformitions[e3];
|
|
11
11
|
}
|
|
12
12
|
return (l2, r2) => {
|
|
13
|
-
const
|
|
14
|
-
return o(), a("div", null, [n(v2, { "model-value": "", title: l2.$t("superPageRuntimeMessage.selectNode"), "close-on-click-modal": false, "append-to-body": "", width: "50%", "max-height": "400", onOpen: r2[2] || (r2[2] = (e3) => b("open")), onOpend: r2[3] || (r2[3] = (e3) => b("opend")), onClose: r2[4] || (r2[4] = (e3) => b("close")), onClosed: r2[5] || (r2[5] = (e3) => b("closed")) }, { footer: s(() => [
|
|
13
|
+
const m2 = t("el-radio"), c3 = t("el-table-column"), f2 = t("el-table"), g2 = t("el-button"), v2 = t("el-dialog");
|
|
14
|
+
return o(), a("div", null, [n(v2, { "model-value": "", title: l2.$t("superPageRuntimeMessage.selectNode"), "close-on-click-modal": false, "append-to-body": "", width: "50%", "max-height": "400", onOpen: r2[2] || (r2[2] = (e3) => b("open")), onOpend: r2[3] || (r2[3] = (e3) => b("opend")), onClose: r2[4] || (r2[4] = (e3) => b("close")), onClosed: r2[5] || (r2[5] = (e3) => b("closed")) }, { footer: s(() => [d("div", p, [n(g2, { type: "primary", onClick: y }, { default: s(() => [u(i(l2.$t("superPageRuntimeMessage.sure")), 1)]), _: 1 }), n(g2, { type: "default", onClick: r2[1] || (r2[1] = (e3) => b("close")) }, { default: s(() => [u(i(l2.$t("superPageRuntimeMessage.cancel")), 1)]), _: 1 })])]), default: s(() => [n(f2, { data: e2.taskInformitions, border: "", style: { width: "100%" } }, { default: s(() => [n(c3, { fixed: "", width: "60" }, { default: s((e3) => [n(m2, { modelValue: h.value, "onUpdate:modelValue": r2[0] || (r2[0] = (e4) => h.value = e4), label: e3.$index, onChange: _ }, { default: s(() => [u(i(e3.$index + 1), 1)]), _: 2 }, 1032, ["modelValue", "label"])]), _: 1 }), n(c3, { prop: "nodeName", label: l2.$t("superPageRuntimeMessage.nodeName"), width: "180" }, null, 8, ["label"]), n(c3, { prop: "transactorNames", label: l2.$t("superPageRuntimeMessage.transactorNames") }, null, 8, ["label"])]), _: 1 }, 8, ["data"])]), _: 1 }, 8, ["title"])]);
|
|
15
15
|
};
|
|
16
16
|
} });
|
|
17
17
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import
|
|
1
|
+
import r from "./card-runtime.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const t = r
|
|
3
|
+
import e from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const t = e(r, [["__scopeId", "data-v-8157d835"]]);
|
|
5
5
|
export {
|
|
6
6
|
t as default
|
|
7
7
|
};
|
|
@@ -1,29 +1,36 @@
|
|
|
1
|
-
import { defineComponent as e,
|
|
1
|
+
import { defineComponent as e, ref as o, computed as t, onMounted as i, nextTick as n, resolveComponent as r, createBlock as l, openBlock as s, unref as a, normalizeClass as u, normalizeStyle as p, createSlots as c, withCtx as f, createElementVNode as g, createElementBlock as m, Fragment as y, renderList as d, createCommentVNode as x, createTextVNode as v, toDisplayString as C } from "vue";
|
|
2
2
|
import { ElCard as b } from "element-plus";
|
|
3
3
|
import { SuperIcon as h } from "agilebuilder-ui";
|
|
4
|
-
import { ArrowUp as k, ArrowDown as
|
|
5
|
-
import
|
|
4
|
+
import { ArrowUp as k, ArrowDown as T } from "@element-plus/icons-vue";
|
|
5
|
+
import w from "../../object-render.vue.js";
|
|
6
6
|
import { $t as j } from "../../../../utils/i18n-util.js";
|
|
7
|
-
import { handleAfterInitEvent as
|
|
8
|
-
|
|
7
|
+
import { handleAfterInitEvent as S } from "../../../../utils/events/event-util.js";
|
|
8
|
+
import { getValueFromVariable as V } from "../../../../utils/page-helper-util.js";
|
|
9
|
+
const _ = e({ __name: "card-runtime", props: { pageContext: {}, configure: {} }, setup(e2, { expose: _2 }) {
|
|
9
10
|
var _a, _b;
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
const R = e2, z = o("");
|
|
12
|
+
if (R.configure.props.base.dynamicTexts && R.configure.props.base.dynamicTexts.length > 0) {
|
|
13
|
+
let e3 = "";
|
|
14
|
+
R.configure.props.base.dynamicTexts.forEach((o2) => {
|
|
15
|
+
e3 += V(R.pageContext.entity, o2);
|
|
16
|
+
}), z.value = e3;
|
|
17
|
+
} else z.value = j(R.configure.props.base.title);
|
|
18
|
+
R.configure.items || (R.configure.items = []);
|
|
19
|
+
const D = t(() => {
|
|
13
20
|
var _a2;
|
|
14
|
-
return [true, void 0].includes((_a2 =
|
|
15
|
-
}),
|
|
21
|
+
return [true, void 0].includes((_a2 = R.configure.props) == null ? void 0 : _a2.isCollapse);
|
|
22
|
+
}), E = o(null), q = o(!((_a = R.configure.props) == null ? void 0 : _a.isCollapse) || false !== ((_b = R.configure.props) == null ? void 0 : _b.isCollapseShow)), A = R.configure.runtime ? R.configure.runtime : {}, B = A.style, F = A.class, G = A.headerStyle, H = A.contentStyle, I = () => D.value && (q.value = !q.value);
|
|
16
23
|
return i(() => {
|
|
17
24
|
n(() => {
|
|
18
|
-
|
|
25
|
+
S(null, R.pageContext, R.configure, { componentRef: E.value, entity: R.pageContext.entity.data, pageData: R.pageContext.entity.page });
|
|
19
26
|
});
|
|
20
|
-
}),
|
|
21
|
-
|
|
27
|
+
}), _2({ test: function() {
|
|
28
|
+
R.configure.props.title = "teee";
|
|
22
29
|
} }), (o2, t2) => {
|
|
23
30
|
const i2 = r("el-link");
|
|
24
|
-
return s(), l(
|
|
31
|
+
return s(), l(a(b), { ref_key: "thisRef", ref: E, style: p(a(B)), "data-collapse": String(q.value), class: u(["yx-card-box-view-main", a(F)]) }, c({ default: f(() => [g("div", { class: "yx-card-box-view-context", style: p(a(H)) }, [(s(true), m(y, null, d(e2.configure.items, (o3, t3) => (s(), l(w, { key: o3.uuid, pageContext: e2.pageContext, configure: o3 }, null, 8, ["pageContext", "configure"]))), 128))], 4)]), _: 2 }, [e2.configure.props.base.tittleShow ? { name: "header", fn: f(() => [g("div", { class: "yx-card-box-view-header", onClick: I }, [g("div", { class: "yx-card-box-view-title", style: p(a(G)) }, [e2.configure.props.iconType && e2.configure.props.iconValue ? (s(), l(a(h), { key: 0, iconType: e2.configure.props.iconType, iconValue: e2.configure.props.iconValue, style: { "margin-right": "2px" } }, null, 8, ["iconType", "iconValue"])) : x("", true), v(" " + C(z.value), 1)], 4), D.value ? (s(), l(i2, { key: 0, underline: false, icon: q.value ? a(k) : a(T), style: { margin: "-15px 0", "z-index": "1" } }, null, 8, ["icon"])) : x("", true)])]), key: "0" } : void 0]), 1032, ["style", "data-collapse", "class"]);
|
|
25
32
|
};
|
|
26
33
|
} });
|
|
27
34
|
export {
|
|
28
|
-
|
|
35
|
+
_ as default
|
|
29
36
|
};
|
|
@@ -1,54 +1,56 @@
|
|
|
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
|
|
2
|
-
import { setVariableValue as b, getVariableValue as x, getOptionDatasFromPage as C,
|
|
3
|
-
import { getFormModelFields as
|
|
4
|
-
import { handleFormEvent as
|
|
5
|
-
import { $t as
|
|
6
|
-
import { addRequiredClassUtil as
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
let
|
|
10
|
-
const
|
|
11
|
-
let e3 = x(
|
|
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 c, createSlots as p, withCtx as f, createVNode as g, createElementBlock as v, Fragment as d, renderList as m, createElementVNode as h, toDisplayString as y } from "vue";
|
|
2
|
+
import { setVariableValue as b, getVariableValue as x, getOptionDatasFromPage as C, putToOptionSourceMap as k, monitorFieldChange as S, autoSetAfterSelect as j, queryOptionDatasources as R } from "../../../../utils/page-helper-util.js";
|
|
3
|
+
import { getFormModelFields as _ } from "../../../../utils/page-init-util.js";
|
|
4
|
+
import { handleFormEvent as I, handleAfterInitEvent as q } from "../../../../utils/events/event-util.js";
|
|
5
|
+
import { $t as V } from "../../../../utils/i18n-util.js";
|
|
6
|
+
import { addRequiredClassUtil as w } from "../../../../utils/common-util.js";
|
|
7
|
+
const z = e({ __name: "checkbox-runtime", props: { pageContext: {}, configure: {} }, setup(e2, { expose: z2 }) {
|
|
8
|
+
const D = e2, E = t(null), O = D.pageContext.entity ? D.pageContext.entity : {};
|
|
9
|
+
let A = _(D.pageContext, D.configure);
|
|
10
|
+
const M = l({ get() {
|
|
11
|
+
let e3 = x(O, A);
|
|
12
12
|
return e3 && "string" == typeof e3 && (e3 = e3.split(",")), e3;
|
|
13
13
|
}, set(e3) {
|
|
14
|
-
e3 && e3.length > 0 && (e3 = e3.join(",")), b(
|
|
15
|
-
} }),
|
|
16
|
-
|
|
17
|
-
const
|
|
18
|
-
let
|
|
19
|
-
if (
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
e3 && e3.length > 0 && (e3 = e3.join(",")), b(O, A, e3), null != e3 && (E.value = "");
|
|
15
|
+
} }), P = D.configure.runtime ? D.configure.runtime : {}, T = P.style, F = P.class, U = P.headerStyle, W = P.titleExceedStyle, B = t(P.props ? P.props : {}), G = t(B.value.options ? B.value.options : []), H = C(D.pageContext, D.configure);
|
|
16
|
+
H.length > 0 && (G.value = H);
|
|
17
|
+
const J = D.configure.props && D.configure.props.dataOrigin ? D.configure.props.dataOrigin : {}, K = J.optionValueSetType;
|
|
18
|
+
let L = [];
|
|
19
|
+
if ("dynamicData" == K || "dynamicData" == K || "service" == K) {
|
|
20
|
+
if (J.autoSets) for (let e3 of J.autoSets) e3.source && L.push(e3);
|
|
21
|
+
} else "static" == K && k(D.pageContext, D.configure.uuid, G.value);
|
|
22
|
+
D.configure && D.configure.props && D.configure.props.base && D.configure.props.base.optionProp && L.push({ source: "label", target: D.configure.props.base.optionProp }), B.value.changeMethod = function(e3) {
|
|
23
|
+
if (L.length > -1) {
|
|
22
24
|
let t2 = null;
|
|
23
|
-
|
|
25
|
+
G.value && null != e3 && null != e3 && (t2 = G.value.filter((t3) => Array.isArray(e3) ? e3.includes(t3.value) : e3 === t3.value)), j(D.configure, D.pageContext, L, t2);
|
|
24
26
|
}
|
|
25
|
-
|
|
27
|
+
I(e3, D.pageContext, D.configure, "change");
|
|
26
28
|
};
|
|
27
|
-
const
|
|
28
|
-
const
|
|
29
|
-
|
|
30
|
-
|
|
29
|
+
const N = B.value.optionconfigInfo ? B.value.optionconfigInfo : {};
|
|
30
|
+
const Q = B.value.monitorFields;
|
|
31
|
+
S(D.pageContext, Q, function() {
|
|
32
|
+
R(D.pageContext, N, void 0).then((e3) => {
|
|
31
33
|
});
|
|
32
34
|
});
|
|
33
|
-
const
|
|
35
|
+
const X = t(null), Y = t(null), Z = t(null);
|
|
34
36
|
return o(() => {
|
|
35
37
|
n(() => {
|
|
36
|
-
const e3 =
|
|
37
|
-
|
|
38
|
+
const e3 = M.value;
|
|
39
|
+
q(e3, D.pageContext, D.configure, { formItemRef: X.value, componentRef: Y.value, titleRef: Z.value, value: e3, entity: D.pageContext.entity.data, pageData: D.pageContext.entity.page });
|
|
38
40
|
});
|
|
39
|
-
}),
|
|
40
|
-
|
|
41
|
+
}), z2({ updateOptions: function(e3) {
|
|
42
|
+
G.value = e3 || [];
|
|
41
43
|
}, addRequiredClass: function() {
|
|
42
|
-
|
|
44
|
+
E.value = w();
|
|
43
45
|
}, getSelectItemsTitle: function() {
|
|
44
46
|
const e3 = function() {
|
|
45
|
-
let e4 = x(
|
|
47
|
+
let e4 = x(O, A);
|
|
46
48
|
return null != e4 && (e4 = String(e4)), e4;
|
|
47
49
|
}();
|
|
48
50
|
if (null != e3 && "" !== e3 && e3.length > 0) {
|
|
49
51
|
let t2 = "";
|
|
50
52
|
const l2 = e3.split(",");
|
|
51
|
-
return
|
|
53
|
+
return G.value.length > 0 ? (G.value.forEach((e4) => {
|
|
52
54
|
l2.forEach((l3) => {
|
|
53
55
|
e4.value === l3 && (t2 = t2 + e4.label + ",");
|
|
54
56
|
});
|
|
@@ -56,9 +58,9 @@ const w = e({ __name: "checkbox-runtime", props: { pageContext: {}, configure: {
|
|
|
56
58
|
}
|
|
57
59
|
} }), (t2, l2) => {
|
|
58
60
|
const o2 = a("el-checkbox"), n2 = a("el-checkbox-group"), b2 = a("el-form-item");
|
|
59
|
-
return i(), u(b2, { ref_key: "formItemRef", ref:
|
|
61
|
+
return i(), u(b2, { ref_key: "formItemRef", ref: X, class: s(c(F) + (E.value ? " " + E.value : "")), required: !!B.value.required, "label-width": B.value.labelWidth, style: r(c(T)) }, p({ default: f(() => [g(n2, { ref_key: "componentRef", ref: Y, disabled: "disabled" === B.value.state, size: B.value.size, onChange: B.value.changeMethod, modelValue: M.value, "onUpdate:modelValue": l2[0] || (l2[0] = (e3) => M.value = e3) }, { default: f(() => [(i(true), v(d, null, m(G.value, (t3) => (i(), u(o2, { key: t3.value, value: t3.value, label: t3.label, onClick: (l3) => c(I)(t3.value, e2.pageContext, e2.configure, "click", { values: M.value }) }, null, 8, ["value", "label", "onClick"]))), 128))]), _: 1 }, 8, ["disabled", "size", "onChange", "modelValue"])]), _: 2 }, [B.value.tittleShow ? { name: "label", fn: f(() => [h("div", { ref_key: "titleRef", ref: Z, style: r({ ...c(U), ...c(W) }), class: "amb-form-item-label" }, y(c(V)(B.value.title)), 5)]), key: "0" } : void 0]), 1032, ["class", "required", "label-width", "style"]);
|
|
60
62
|
};
|
|
61
63
|
} });
|
|
62
64
|
export {
|
|
63
|
-
|
|
65
|
+
z as default
|
|
64
66
|
};
|
|
@@ -1,82 +1,84 @@
|
|
|
1
1
|
import { defineComponent as e, ref as t, computed as l, watch as o, onUnmounted as n, onMounted as a, nextTick as u, resolveComponent as i, createBlock as r, openBlock as s, normalizeStyle as f, normalizeClass as p, unref as c, createSlots as g, withCtx as v, createVNode as d, createElementBlock as m, Fragment as h, renderList as b, createTextVNode as y, toDisplayString as C, createElementVNode as x } from "vue";
|
|
2
|
-
import { setVariableValue as k, getVariableValue as _, getOptionDatasFromPage as S,
|
|
3
|
-
import { getFormModelFields as
|
|
4
|
-
import { handleFormEvent as
|
|
5
|
-
import { $t as
|
|
6
|
-
import { addRequiredClassUtil as
|
|
7
|
-
const
|
|
8
|
-
const
|
|
9
|
-
let
|
|
10
|
-
const
|
|
11
|
-
let e3 = _(
|
|
2
|
+
import { setVariableValue as k, getVariableValue as _, getOptionDatasFromPage as S, putToOptionSourceMap as R, autoSetAfterSelect as j, queryOptionDatasources as T } from "../../../../utils/page-helper-util.js";
|
|
3
|
+
import { getFormModelFields as I } from "../../../../utils/page-init-util.js";
|
|
4
|
+
import { handleFormEvent as q, handleAfterInitEvent as V } from "../../../../utils/events/event-util.js";
|
|
5
|
+
import { $t as w } from "../../../../utils/i18n-util.js";
|
|
6
|
+
import { addRequiredClassUtil as z } from "../../../../utils/common-util.js";
|
|
7
|
+
const O = e({ __name: "radio-runtime", props: { pageContext: {}, configure: {} }, setup(e2, { expose: O2 }) {
|
|
8
|
+
const D = e2, E = t(null), M = D.pageContext.entity ? D.pageContext.entity : {};
|
|
9
|
+
let P = I(D.pageContext, D.configure);
|
|
10
|
+
const W = l({ get() {
|
|
11
|
+
let e3 = _(M, P);
|
|
12
12
|
return null != e3 && (e3 += ""), e3;
|
|
13
13
|
}, set(e3) {
|
|
14
|
-
k(
|
|
15
|
-
} }),
|
|
16
|
-
|
|
17
|
-
const
|
|
18
|
-
let
|
|
19
|
-
if (
|
|
20
|
-
|
|
21
|
-
|
|
14
|
+
k(M, P, e3), null != e3 && (E.value = "");
|
|
15
|
+
} }), F = D.configure.runtime ? D.configure.runtime : {}, U = F.style, $ = F.class, A = F.headerStyle, B = F.titleExceedStyle, G = t(F.props ? F.props : {}), H = t(G.value.options ? G.value.options : []), J = S(D.pageContext, D.configure);
|
|
16
|
+
J.length > 0 && (H.value = J);
|
|
17
|
+
const K = D.configure.props && D.configure.props.dataOrigin ? D.configure.props.dataOrigin : {}, L = K.optionValueSetType;
|
|
18
|
+
let N = [];
|
|
19
|
+
if ("dynamicData" == L || "dataTable" == L || "service" == L) {
|
|
20
|
+
if (K.autoSets) for (let e3 of K.autoSets) e3.source && N.push(e3);
|
|
21
|
+
} else "static" == L && R(D.pageContext, D.configure.uuid, H.value);
|
|
22
|
+
D.configure && D.configure.props && D.configure.props.base && D.configure.props.base.optionProp && N.push({ source: "label", target: D.configure.props.base.optionProp }), G.value.changeMethod = function(e3) {
|
|
23
|
+
if (N.length > 0) {
|
|
22
24
|
let t2 = null;
|
|
23
|
-
|
|
25
|
+
H.value && null != e3 && null != e3 && (t2 = H.value.filter((t3) => e3 === t3.value)), j(D.configure, D.pageContext, N, t2);
|
|
24
26
|
}
|
|
25
|
-
|
|
27
|
+
q(e3, D.pageContext, D.configure, "change");
|
|
26
28
|
};
|
|
27
|
-
const
|
|
28
|
-
if (
|
|
29
|
+
const Q = G.value.monitorFields, X = [];
|
|
30
|
+
if (Q) {
|
|
29
31
|
const e3 = [];
|
|
30
|
-
for (let t2 of
|
|
32
|
+
for (let t2 of Q) if (t2.startsWith("${")) {
|
|
31
33
|
t2 = t2.substring(2, t2.length - 1);
|
|
32
34
|
const l2 = t2.split(".");
|
|
33
|
-
"page" !== l2[0] && "task" !== l2[0] && "data" !== l2[0] || (
|
|
35
|
+
"page" !== l2[0] && "task" !== l2[0] && "data" !== l2[0] || (X.push(l2), e3.includes(l2[0]) || e3.push(l2[0]));
|
|
34
36
|
}
|
|
35
|
-
for (let t2 of e3) o(
|
|
36
|
-
|
|
37
|
+
for (let t2 of e3) o(M[t2], () => {
|
|
38
|
+
le();
|
|
37
39
|
});
|
|
38
40
|
}
|
|
39
|
-
function
|
|
41
|
+
function Y() {
|
|
40
42
|
let e3 = "";
|
|
41
|
-
for (let t2 of
|
|
43
|
+
for (let t2 of X) e3 += "_" + _(M, t2);
|
|
42
44
|
return e3;
|
|
43
45
|
}
|
|
44
|
-
let
|
|
45
|
-
const
|
|
46
|
-
function
|
|
47
|
-
|
|
48
|
-
const e3 =
|
|
49
|
-
e3 !=
|
|
46
|
+
let Z = Y(), ee = false;
|
|
47
|
+
const te = G.value.optionconfigInfo ? G.value.optionconfigInfo : {};
|
|
48
|
+
function le() {
|
|
49
|
+
ee && clearTimeout(ee), ee = setTimeout(function() {
|
|
50
|
+
const e3 = Y();
|
|
51
|
+
e3 != Z && (Z = e3, T(D.pageContext, te, void 0).then((e4) => {
|
|
50
52
|
}));
|
|
51
53
|
}, 200);
|
|
52
54
|
}
|
|
53
55
|
n(() => {
|
|
54
|
-
|
|
56
|
+
ee && clearTimeout(ee);
|
|
55
57
|
});
|
|
56
|
-
const
|
|
58
|
+
const oe = t(null), ne = t(null), ae = t(null);
|
|
57
59
|
return a(() => {
|
|
58
60
|
u(() => {
|
|
59
|
-
const e3 =
|
|
60
|
-
|
|
61
|
+
const e3 = W.value;
|
|
62
|
+
V(e3, D.pageContext, D.configure, { formItemRef: oe.value, componentRef: ne.value, titleRef: ae.value, value: e3, entity: D.pageContext.entity.data, pageData: D.pageContext.entity.page });
|
|
61
63
|
});
|
|
62
|
-
}),
|
|
63
|
-
|
|
64
|
+
}), O2({ updateOptions: function(e3) {
|
|
65
|
+
H.value = e3 || [];
|
|
64
66
|
}, addRequiredClass: function() {
|
|
65
|
-
|
|
67
|
+
E.value = z();
|
|
66
68
|
}, getSelectItemsTitle: function() {
|
|
67
|
-
let e3 = _(
|
|
69
|
+
let e3 = _(M, P);
|
|
68
70
|
if (null == e3) return "";
|
|
69
71
|
if (e3 = String(e3), null != e3 && "" !== e3 && e3.length > 0) {
|
|
70
72
|
let t2 = "";
|
|
71
|
-
return
|
|
73
|
+
return H.value.length > 0 ? (H.value.forEach((l2) => {
|
|
72
74
|
l2.value === e3 && (t2 = t2 + l2.label + ",");
|
|
73
75
|
}), t2 = t2.slice(0, t2.length - 1)) : t2 = e3.join(","), t2;
|
|
74
76
|
}
|
|
75
77
|
} }), (t2, l2) => {
|
|
76
78
|
const o2 = i("el-radio"), n2 = i("el-radio-group"), a2 = i("el-form-item");
|
|
77
|
-
return s(), r(a2, { ref_key: "formItemRef", ref:
|
|
79
|
+
return s(), r(a2, { ref_key: "formItemRef", ref: oe, required: G.value.required, class: p(c($) + (E.value ? " " + E.value : "")), "label-width": G.value.labelWidth, style: f(c(U)) }, g({ default: v(() => [d(n2, { ref_key: "componentRef", ref: ne, disabled: "disabled" === G.value.state, size: G.value.size, onChange: G.value.changeMethod, modelValue: W.value, "onUpdate:modelValue": l2[0] || (l2[0] = (e3) => W.value = e3) }, { default: v(() => [(s(true), m(h, null, b(H.value, (t3) => (s(), r(o2, { key: t3.value, label: t3.value, onClick: (l3) => c(q)(t3.value, e2.pageContext, e2.configure, "click", { values: W.value }) }, { default: v(() => [y(C(t3.label), 1)]), _: 2 }, 1032, ["label", "onClick"]))), 128))]), _: 1 }, 8, ["disabled", "size", "onChange", "modelValue"])]), _: 2 }, [G.value.tittleShow ? { name: "label", fn: v(() => [x("div", { ref_key: "titleRef", ref: ae, style: f({ ...c(A), ...c(B) }), class: "amb-form-item-label" }, C(c(w)(G.value.title)), 5)]), key: "0" } : void 0]), 1032, ["required", "class", "label-width", "style"]);
|
|
78
80
|
};
|
|
79
81
|
} });
|
|
80
82
|
export {
|
|
81
|
-
|
|
83
|
+
O as default
|
|
82
84
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "./select-runtime.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const r = t(e, [["__scopeId", "data-v-
|
|
4
|
+
const r = t(e, [["__scopeId", "data-v-ccac4657"]]);
|
|
5
5
|
export {
|
|
6
6
|
r as default
|
|
7
7
|
};
|