super-page-designer 2.2.76 → 2.2.77-sit4
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/design/utils/assemblys-config.js +2 -2
- package/dist/es/components/design/views/assemblys/button/button/button-attr-base.vue.js +33 -33
- package/dist/es/components/design/views/assemblys/button/button/button-design.vue2.js +21 -21
- package/dist/es/components/design/views/assemblys/button/button-group/buttongroup-attr-base.vue.js +8 -8
- package/dist/es/components/design/views/assemblys/button/button-group/buttongroup-design.vue.js +4 -1
- package/dist/es/components/design/views/assemblys/button/button-group/buttongroup-design.vue2.js +38 -34
- package/dist/es/components/design/views/assemblys/button/component/combination.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/button/component/condition-dialog.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/button/component/journal-set-dialog.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/button/component/journal-set-dialog.vue2.js +8 -8
- package/dist/es/components/design/views/assemblys/button/component/set-dialog.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/button/dropdown/dropdown-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/button/export-pdf/exportpdf-attr-base.vue.js +20 -19
- package/dist/es/components/design/views/assemblys/button/export-pdf/exportpdf-design.vue2.js +19 -19
- package/dist/es/components/design/views/assemblys/button/print-label/printlabel-attr-base.vue.js +9 -8
- package/dist/es/components/design/views/assemblys/button/print-label/printlabel-design.vue2.js +19 -19
- package/dist/es/components/design/views/assemblys/chart/column-line/column-line-design.vue2.js +9 -9
- package/dist/es/components/design/views/assemblys/chart/gauge/gauge-design.vue2.js +9 -9
- package/dist/es/components/design/views/assemblys/chart/pie/pie-design.vue2.js +8 -8
- package/dist/es/components/design/views/assemblys/chart/radar/radar-design.vue2.js +12 -12
- package/dist/es/components/design/views/assemblys/chart/scatter/scatter-design.vue2.js +11 -11
- package/dist/es/components/design/views/assemblys/chart/statistical-table/component/data-origin.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/chart/statistical-table/component/data-origin.vue2.js +39 -36
- package/dist/es/components/design/views/assemblys/chart/statistical-table/component/font-style-dialog.vue.js +12 -12
- package/dist/es/components/design/views/assemblys/chart/statistical-table/component/style-table.vue.js +14 -14
- package/dist/es/components/design/views/assemblys/chart/statistical-table/component/table-showcondition.vue.js +12 -12
- package/dist/es/components/design/views/assemblys/chart/statistical-table/statisticalTable-design.vue2.js +24 -23
- package/dist/es/components/design/views/assemblys/common/common-advanced-basic-showcondition.vue.js +6 -6
- package/dist/es/components/design/views/assemblys/common/common-attr-size.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/common/common-i18n-key-input.vue.js +11 -11
- package/dist/es/components/design/views/assemblys/common/common-icon-bind.vue.js +53 -53
- package/dist/es/components/design/views/assemblys/common/common-select-page.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/common/common-select-table.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/common/common-variable-bind.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/common/{common-variable-bind.vue3.js → common-variable-bind.vue2.js} +11 -11
- package/dist/es/components/design/views/assemblys/common/page-permission-select.vue.js +59 -59
- package/dist/es/components/design/views/assemblys/container/card/card-design.vue.js +4 -1
- package/dist/es/components/design/views/assemblys/container/card/card-design.vue2.js +43 -38
- package/dist/es/components/design/views/assemblys/container/iframe/iframe-attr-base.vue.js +4 -4
- package/dist/es/components/design/views/assemblys/container/tabs/tabs-design.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/container/tabs/tabs-design.vue2.js +26 -26
- package/dist/es/components/design/views/assemblys/data/component/column-config.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/data/component/composite-header.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/composite-header.vue2.js +30 -30
- package/dist/es/components/design/views/assemblys/data/component/configuration-value.vue.js +7 -7
- package/dist/es/components/design/views/assemblys/data/component/data-origin-tree.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/data-origin-tree.vue2.js +4 -4
- package/dist/es/components/design/views/assemblys/data/component/data-origin.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/data-origin.vue2.js +11 -11
- package/dist/es/components/design/views/assemblys/data/component/dynamic-column.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/component/formatting.vue.js +5 -5
- package/dist/es/components/design/views/assemblys/data/component/querySetting.vue.js +6 -6
- package/dist/es/components/design/views/assemblys/data/component/return-set-table.vue.js +8 -8
- package/dist/es/components/design/views/assemblys/data/component/table-children-column.vue.js +11 -11
- package/dist/es/components/design/views/assemblys/data/component/variate-select.vue.js +5 -5
- package/dist/es/components/design/views/assemblys/data/table/table-attr-advanced.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/data/table/table-attr-base.vue.js +9 -9
- package/dist/es/components/design/views/assemblys/data/table/table-attr.vue2.js +14 -11
- package/dist/es/components/design/views/assemblys/data/table/table-design.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/table/table-design.vue2.js +83 -80
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-attr-base.vue2.js +29 -9
- package/dist/es/components/design/views/assemblys/data/table/tablecolumn-dynamic-column.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/data/tree/tree-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/data/tree/tree-attr-context-menu.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/data/tree/tree-design.vue2.js +10 -10
- package/dist/es/components/design/views/assemblys/form/common/bar-code-rule.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/common/condition.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/form/common/data-format.vue.js +4 -4
- package/dist/es/components/design/views/assemblys/form/common/data-origin.vue.js +4 -4
- package/dist/es/components/design/views/assemblys/form/common/data-origin.vue2.js +1 -1
- package/dist/es/components/design/views/assemblys/form/common/dataorigin-input-table.vue.js +26 -2
- package/dist/es/components/design/views/assemblys/form/common/dataorigin-input-table.vue2.js +2 -26
- package/dist/es/components/design/views/assemblys/form/common/hyperlink-mult-config.vue.js +12 -12
- package/dist/es/components/design/views/assemblys/form/common/icon-set-dialog.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/common/icon-set-dialog.vue2.js +6 -6
- package/dist/es/components/design/views/assemblys/form/common/parameter-table.vue.js +33 -30
- package/dist/es/components/design/views/assemblys/form/common/suffixmodule.vue.js +14 -14
- package/dist/es/components/design/views/assemblys/form/common/verification-custom.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/dept-tree/depttree-attr-base.vue.js +3 -3
- package/dist/es/components/design/views/assemblys/form/file-upload/fileupload-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/input-number/input-number-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/input-text/inputtext-attr-base.vue.js +14 -14
- package/dist/es/components/design/views/assemblys/form/rich-text/richtext-attr-base.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/form/switch/switch-attr-base.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/object-design.vue.d.ts +4 -0
- package/dist/es/components/design/views/assemblys/object-design.vue.js +5 -138
- package/dist/es/components/design/views/assemblys/object-design.vue3.js +140 -0
- package/dist/es/components/design/views/assemblys/page/component/setting-form-rule-base-input.vue.js +2 -2
- package/dist/es/components/design/views/assemblys/page/component/weight-field-input.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/page/create-workflow-dialog.vue.js +8 -8
- package/dist/es/components/design/views/assemblys/page/page-attr-base.vue.js +8 -8
- package/dist/es/components/design/views/assemblys/page/variable-dialog.vue.js +1 -1
- package/dist/es/components/design/views/assemblys/workflow/component/combination.vue.js +9 -20
- package/dist/es/components/design/views/assemblys/workflow/workflow-button/workflowbutton-attr-base.vue.js +7 -7
- package/dist/es/components/design/views/assemblys/workflow/workflow-button/workflowbutton-design.vue.js +4 -1
- package/dist/es/components/design/views/assemblys/workflow/workflow-button/workflowbutton-design.vue2.js +22 -18
- package/dist/es/components/design/views/design/page-event/page-event-container.vue.js +36 -36
- package/dist/es/components/design/views/design/page-event/page-event-content.vue.js +64 -64
- package/dist/es/components/design/views/design/page-event/page-event-view.vue.js +10 -9
- package/dist/es/components/design/views/design/view/attr-container.vue.js +24 -24
- package/dist/es/components/design/views/design/view/components/el-aside-expand-component.vue.js +24 -0
- package/dist/es/components/design/views/design/view/components/i18n-setting-enabled.vue.js +2 -2
- package/dist/es/components/design/views/design/view/components/i18n-setting-page.vue.js +1 -1
- package/dist/es/components/design/views/design/view/components/i18n-setting-page.vue2.js +4 -4
- package/dist/es/components/design/views/design/view/components/i18n-setting.vue.js +4 -4
- package/dist/es/components/design/views/design/view/components/quick-add-dialog.vue.js +10 -9
- package/dist/es/components/design/views/design/view/components/translate-error-dialog.vue.js +8 -8
- package/dist/es/components/design/views/design/view/page-switch.vue.js +1 -1
- package/dist/es/components/design/views/design/view/page-switch.vue2.js +1 -1
- package/dist/es/components/design/views/design/view/view-design-display.vue.js +1 -1
- package/dist/es/components/design/views/design/view/view-design-preview.vue.js +1 -1
- package/dist/es/components/design/views/design/view/view-design-preview.vue2.js +2 -2
- package/dist/es/components/design/views/design/view/view-design.vue.js +27 -26
- package/dist/es/style.css +1826 -736
- package/package.json +5 -5
- package/dist/es/components/design/views/assemblys/object-design.vue2.js +0 -4
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { defineComponent as e, ref as l, computed as t, onMounted as a, onUnmounted as n, resolveComponent as o, createElementBlock as i, openBlock as s,
|
|
1
|
+
import { defineComponent as e, ref as l, computed as t, onMounted as a, onUnmounted as n, resolveComponent as o, createElementBlock as i, openBlock as s, createElementVNode as u, createVNode as r, withCtx as m, unref as p, isRef as d, normalizeStyle as c, toDisplayString as v, withDirectives as f, withModifiers as g, createTextVNode as h, vShow as b } from "vue";
|
|
2
2
|
import { Search as w } from "@element-plus/icons-vue";
|
|
3
3
|
import { ElMessageBox as x } from "element-plus";
|
|
4
|
-
import { getDesignConfByName as
|
|
5
|
-
import
|
|
4
|
+
import { getDesignConfByName as C } from "../../../utils/assemblys-config.js";
|
|
5
|
+
import y from "../view/assemblys-container-explore.vue.js";
|
|
6
6
|
import { deepCopy as _ } from "../../../utils/common-util.js";
|
|
7
7
|
import k from "../../../utils/eventBus.js";
|
|
8
8
|
import { usePageContextStore as E } from "../../../../../stores/page-store.js";
|
|
9
|
-
const V = { style: { "padding-top": "10px" } },
|
|
10
|
-
const
|
|
11
|
-
let
|
|
12
|
-
const
|
|
9
|
+
const V = { class: "amb-design-assembly-content", ref: "ambPageEventList" }, j = { style: { "padding-top": "10px" } }, $ = ["title"], L = ["title"], T = { key: 0 }, U = { key: 1 }, z = ["title"], S = ["title"], B = ["title"], I = e({ __name: "page-event-container", props: { configure: {}, configureObj: {}, editEvent: {} }, emits: ["add-event", "change-event"], setup(e2, { expose: I2, emit: N }) {
|
|
10
|
+
const P = E(), W = l(null), D = l(), F = l(false);
|
|
11
|
+
let O = l(["searchCollapse", "addCollapse", "unUseEventCollapse"]), R = l(null), H = l("");
|
|
12
|
+
const M = t(() => {
|
|
13
13
|
let e3 = "";
|
|
14
|
-
const l2 =
|
|
14
|
+
const l2 = R.value;
|
|
15
15
|
if ("page" === (l2 && "page" != l2.name ? l2.name : "page")) e3 = "页面";
|
|
16
16
|
else if (e3 = l2 && l2.label ? l2.label : "", l2 && l2.props && l2.props.base) {
|
|
17
17
|
const t2 = l2.props.base.title;
|
|
@@ -19,22 +19,22 @@ const V = { style: { "padding-top": "10px" } }, j = ["title"], $ = ["title"], L
|
|
|
19
19
|
}
|
|
20
20
|
return e3;
|
|
21
21
|
});
|
|
22
|
-
let
|
|
23
|
-
const
|
|
24
|
-
let e3 =
|
|
22
|
+
let q = t(() => W.value && W.value.customEvents ? W.value.customEvents.filter((e3) => "customFunc" == e3.name) : []);
|
|
23
|
+
const A = t(() => {
|
|
24
|
+
let e3 = R.value ? R.value.name : null;
|
|
25
25
|
e3 = e3 || "page";
|
|
26
|
-
const l2 =
|
|
26
|
+
const l2 = R.value ? R.value.uuid : null;
|
|
27
27
|
let t2 = [];
|
|
28
28
|
const a2 = [];
|
|
29
|
-
if (
|
|
29
|
+
if (W.value && W.value.customEvents) for (let n3 of W.value.customEvents) "customFunc" != n3.name && ("page" !== e3 && n3.uuid !== l2 || (t2.push(n3), a2.includes(n3.name) || a2.push(n3.name)));
|
|
30
30
|
let n2 = null;
|
|
31
|
-
if (n2 = "page" == e3 ?
|
|
31
|
+
if (n2 = "page" == e3 ? W.value ? W.value.events : null : R.value ? R.value.events : null, n2) {
|
|
32
32
|
for (let l4 of n2) {
|
|
33
|
-
l4.componentUuid || (l4.componentUuid =
|
|
33
|
+
l4.componentUuid || (l4.componentUuid = R.value && R.value.uuid ? R.value.uuid : "page"), l4.componentLabel || (l4.componentLabel = "page" == e3 ? "页面" : R.value ? R.value.label : "");
|
|
34
34
|
let n3 = "";
|
|
35
|
-
|
|
35
|
+
R.value && R.value.props && R.value.props.base && (n3 = R.value.props.base.title), l4.title = n3, a2.includes(l4.name) || (t2.push(l4), a2.push(l4.name));
|
|
36
36
|
}
|
|
37
|
-
let l3 =
|
|
37
|
+
let l3 = C(e3);
|
|
38
38
|
const o2 = [];
|
|
39
39
|
if (l3 && l3.events && l3.events.length > 0) {
|
|
40
40
|
for (let e4 of l3.events) if (o2.push(e4.name), !a2.includes(e4.name)) {
|
|
@@ -49,46 +49,46 @@ const V = { style: { "padding-top": "10px" } }, j = ["title"], $ = ["title"], L
|
|
|
49
49
|
}
|
|
50
50
|
} else t2 = [];
|
|
51
51
|
}
|
|
52
|
-
if (
|
|
52
|
+
if (H.value) {
|
|
53
53
|
const e4 = [];
|
|
54
|
-
for (let l3 of t2) (l3.name && l3.name.includes(
|
|
54
|
+
for (let l3 of t2) (l3.name && l3.name.includes(H.value) || l3.label && l3.label.includes(H.value)) && e4.push(l3);
|
|
55
55
|
return e4;
|
|
56
56
|
}
|
|
57
57
|
return t2;
|
|
58
|
-
}),
|
|
59
|
-
function
|
|
60
|
-
|
|
58
|
+
}), G = l([]);
|
|
59
|
+
function J(e3) {
|
|
60
|
+
W.value = e3, G.value = e3 && e3.items ? e3.items : [], Z(null, null);
|
|
61
61
|
}
|
|
62
|
-
function
|
|
62
|
+
function K(e3) {
|
|
63
63
|
x.confirm("确定要清除吗?", "确认", { confirmButtonText: "确定", cancelButtonText: "取消", type: "warning" }).then(() => {
|
|
64
64
|
k.$emit("clearEvent", e3);
|
|
65
65
|
});
|
|
66
66
|
}
|
|
67
|
-
function
|
|
67
|
+
function Q(e3) {
|
|
68
68
|
k.$emit("editEvent", e3);
|
|
69
69
|
}
|
|
70
|
-
function
|
|
70
|
+
function X(e3) {
|
|
71
71
|
k.$emit("editEvent", e3);
|
|
72
72
|
}
|
|
73
|
-
let
|
|
74
|
-
function
|
|
75
|
-
|
|
73
|
+
let Y;
|
|
74
|
+
function Z(e3, l2) {
|
|
75
|
+
R.value = l2, F.value = false;
|
|
76
76
|
}
|
|
77
77
|
return a(() => {
|
|
78
|
-
|
|
78
|
+
J(P.pageContext), D.value = window.innerHeight - 220;
|
|
79
79
|
}), k.$on("changePageDesign", () => {
|
|
80
|
-
|
|
80
|
+
J(P.pageContext);
|
|
81
81
|
}), k.$on("editComponentEvent", (e3) => {
|
|
82
|
-
|
|
82
|
+
Y && clearTimeout(Y), R.value = e3.configureObj, Y = setTimeout(function() {
|
|
83
83
|
k.$emit("editEvent", e3.event);
|
|
84
84
|
}, 100);
|
|
85
85
|
}), n(() => {
|
|
86
|
-
|
|
87
|
-
}),
|
|
88
|
-
const t2 = o("el-button"), a2 = o("el-input"), n2 = o("el-popover"), x2 = o("el-table-column"),
|
|
89
|
-
return s(), i("div",
|
|
86
|
+
Y && clearTimeout(Y), k.$off("changePageDesign"), k.$off("editComponentEvent");
|
|
87
|
+
}), I2({}), (e3, l2) => {
|
|
88
|
+
const t2 = o("el-button"), a2 = o("el-input"), n2 = o("el-popover"), x2 = o("el-table-column"), C2 = o("el-table"), _2 = o("el-collapse-item"), k2 = o("el-collapse");
|
|
89
|
+
return s(), i("div", V, [u("div", null, [u("div", j, [r(n2, { placement: "right", width: 300, visible: F.value, trigger: "manual" }, { reference: m(() => [r(a2, { size: "small", modelValue: M.value, "onUpdate:modelValue": l2[1] || (l2[1] = (e4) => M.value = e4), placeholder: "请选择组件", readonly: "", clearable: "", onClick: l2[2] || (l2[2] = (e4) => F.value = !F.value) }, { append: m(() => [r(t2, { type: "info", icon: p(w), circle: "", text: "", onClick: l2[0] || (l2[0] = (e4) => F.value = !F.value) }, null, 8, ["icon"])]), _: 1 }, 8, ["modelValue"])]), default: m(() => [r(y, { onSelectComponent: Z, treeMarginTop: "", headerSearchClass: "custom", designItems: G.value, selectWidget: e3.selectWidget }, null, 8, ["designItems", "selectWidget"])]), _: 1 }, 8, ["visible"])])]), u("div", null, [r(k2, { modelValue: p(O), "onUpdate:modelValue": l2[4] || (l2[4] = (e4) => d(O) ? O.value = e4 : O = e4), style: { "margin-top": "10px" } }, { default: m(() => [r(_2, { class: "amb-assembly-collapse-header", name: "searchCollapse", title: "事件列表" }, { default: m(() => [u("div", { style: c("max-height:" + D.value + "px") }, [r(a2, { modelValue: p(H), "onUpdate:modelValue": l2[3] || (l2[3] = (e4) => d(H) ? H.value = e4 : H = e4), placeholder: "名称/别名...", clearable: "", class: "input-with-select", style: { "margin-top": "10px", "margin-bottom": "10px" }, "suffix-icon": p(w) }, null, 8, ["modelValue", "suffix-icon"]), r(C2, { size: "small", data: A.value, style: { width: "100%" }, "max-height": D.value, "highlight-current-row": "", onRowClick: X }, { default: m(() => [r(x2, { label: "名称", width: "90" }, { default: m((e4) => [u("span", { title: e4.row.name }, v(e4.row.name), 9, $)]), _: 1 }), r(x2, { label: "别名", width: "60" }, { default: m((e4) => [u("span", { title: e4.row.label }, v(e4.row.label), 9, L)]), _: 1 }), r(x2, { label: "组件", width: "120", align: "left" }, { default: m((e4) => [e4.row.title || e4.row.componentLabel ? (s(), i("span", T, v(e4.row.title ? e4.row.title + "(" + e4.row.componentLabel + ")" : e4.row.componentLabel), 1)) : (s(), i("span", U, v(p(R) ? p(R).label : "页面"), 1))]), _: 1 }), r(x2, { label: "备注" }, { default: m((e4) => [u("span", { title: e4.row.remark }, v(e4.row.remark), 9, z)]), _: 1 }), r(x2, { fixed: "right", label: "", width: "40", align: "center" }, { default: m((e4) => [f(r(t2, { disabled: false === e4.row.isEdit, link: "", type: "danger", size: "small", onClick: g((l3) => K(e4.row), ["stop"]) }, { default: m(() => l2[5] || (l2[5] = [h("清除")])), _: 2 }, 1032, ["disabled", "onClick"]), [[b, e4.row.isStandard && e4.row.eventName || !e4.row.isStandard && e4.row.jsContent]])]), _: 1 })]), _: 1 }, 8, ["data", "max-height"])], 4)]), _: 1 }), r(_2, { class: "amb-assembly-collapse-header", name: "addCollapse", title: "自定义方法" }, { default: m(() => [r(C2, { size: "small", data: p(q), "highlight-current-row": "", style: { width: "100%" }, "max-height": D.value, onRowClick: Q }, { default: m(() => [r(x2, { prop: "label", label: "方法名", width: "90" }, { default: m((e4) => [u("span", { title: e4.row.eventName }, v(e4.row.eventName), 9, S)]), _: 1 }), r(x2, { prop: "label", label: "描述" }, { default: m((e4) => [u("span", { title: e4.row.remark }, v(e4.row.remark), 9, B)]), _: 1 }), r(x2, { fixed: "right", label: "", width: "50", align: "center" }, { default: m((e4) => [r(t2, { disabled: e4.row.disable, link: "", type: "primary", size: "small", onClick: g((l3) => K(e4.row), ["stop"]) }, { default: m(() => l2[6] || (l2[6] = [h("清除")])), _: 2 }, 1032, ["disabled", "onClick"])]), _: 1 })]), _: 1 }, 8, ["data", "max-height"])]), _: 1 })]), _: 1 }, 8, ["modelValue"])])], 512);
|
|
90
90
|
};
|
|
91
91
|
} });
|
|
92
92
|
export {
|
|
93
|
-
|
|
93
|
+
I as default
|
|
94
94
|
};
|
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { defineComponent as e, ref as t, onMounted as n, onUnmounted as a, watch as l, resolveComponent as u, createElementBlock as o, openBlock as s, createElementVNode as i, createVNode as r, withDirectives as
|
|
1
|
+
import { defineComponent as e, ref as t, onMounted as n, onUnmounted as a, watch as l, resolveComponent as u, createElementBlock as o, openBlock as s, createElementVNode as i, createVNode as r, withDirectives as m, withCtx as c, vShow as d, unref as v, createTextVNode as p, toDisplayString as f, Fragment as g, renderList as b, createBlock as y } from "vue";
|
|
2
2
|
import { ElMessageBox as x, ElMessage as h } from "element-plus";
|
|
3
3
|
import C from "./config.vue2.js";
|
|
4
4
|
import { standardButtonOperations as E } from "../../../utils/assemblys-config.js";
|
|
5
|
-
import { findDesignItemByUuid as S, getUuidv4 as
|
|
6
|
-
import { usePageContextStore as
|
|
5
|
+
import { findDesignItemByUuid as S, getUuidv4 as V, deepCopy as k } from "../../../utils/common-util.js";
|
|
6
|
+
import { usePageContextStore as _ } from "../../../../../stores/page-store.js";
|
|
7
7
|
import { undoRedo as T } from "../../../../../stores/event-undo-redo-store.js";
|
|
8
8
|
import U from "../../../utils/eventBus.js";
|
|
9
|
-
const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style: { "user-select": "none" } }, $ = { class: "amb-design-tool-item" }, j = { style: { "margin-left": "0px", display: "inline-block", width: "39px" } },
|
|
10
|
-
const
|
|
11
|
-
let
|
|
12
|
-
const
|
|
13
|
-
let
|
|
14
|
-
const
|
|
15
|
-
function
|
|
9
|
+
const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style: { "user-select": "none", "margin-bottom": "10px" } }, $ = { class: "amb-design-tool-item" }, j = { style: { "margin-left": "0px", display: "inline-block", width: "39px" } }, w = { class: "amb-design-tool-item", style: { "padding-right": "10px" } }, N = { style: { display: "flex", gap: "15px", padding: "0 20px" } }, B = { class: "codemirror", style: { "margin-left": "20px", "margin-top": "-10px" } }, J = e({ __name: "page-event-content", props: { eventForm: {}, configure: {}, customEvent: {}, handleType: {} }, emits: ["changeSelectEvent", "addEvent", "changeSelectStandardEvent"], setup(e2, { expose: J2, emit: A }) {
|
|
10
|
+
const L = e2, O = T(), P = _(), Z = t(null), I = t();
|
|
11
|
+
let q = t();
|
|
12
|
+
const R = E;
|
|
13
|
+
let H = L.customEvent;
|
|
14
|
+
const D = t({ jsContent: "" }), G = t({ jsContent: "" }), K = t(0), M = t(-1), Q = t();
|
|
15
|
+
function W() {
|
|
16
16
|
let e3 = false;
|
|
17
|
-
|
|
17
|
+
G.value && G.value.standardValues && G.value.standardValues.includes("true") && (e3 = true), G.value && (G.value.isStandard = e3);
|
|
18
18
|
}
|
|
19
|
-
function
|
|
20
|
-
const e3 =
|
|
19
|
+
function X() {
|
|
20
|
+
const e3 = D.value ? JSON.stringify(D.value) : null, t2 = G.value ? JSON.stringify(G.value) : null;
|
|
21
21
|
e3 && e3 !== t2 ? x.confirm("当前方法有修改,是否需要暂存?", "确认", { confirmButtonText: "确定", cancelButtonText: "忽略", type: "warning" }).then(() => {
|
|
22
|
-
false !==
|
|
22
|
+
false !== te() && Y();
|
|
23
23
|
}).catch((e4) => {
|
|
24
|
-
|
|
25
|
-
}) :
|
|
24
|
+
Y();
|
|
25
|
+
}) : Y();
|
|
26
26
|
}
|
|
27
|
-
function
|
|
27
|
+
function Y() {
|
|
28
28
|
const e3 = { name: "customFunc", isStandard: false, jsContent: "" };
|
|
29
|
-
e3.uuid =
|
|
29
|
+
e3.uuid = V(), ee(e3);
|
|
30
30
|
}
|
|
31
|
-
function
|
|
32
|
-
e3 = e3 || {},
|
|
31
|
+
function ee(e3) {
|
|
32
|
+
e3 = e3 || {}, D.value = e3, G.value = k(e3), Z.value && Z.value.updateJsContent && Z.value.updateJsContent(G.value), O.clearSnapshot(), O.addSnapshot(G), K.value = 1, M.value = 0;
|
|
33
33
|
}
|
|
34
|
-
function
|
|
35
|
-
if (!
|
|
36
|
-
const e3 =
|
|
34
|
+
function te() {
|
|
35
|
+
if (!G.value) return x.confirm("编辑对象不存在,不需要保存!", "提示", { confirmButtonText: "确定", showCancelButton: false, type: "error" }), false;
|
|
36
|
+
const e3 = P.pageContext;
|
|
37
37
|
if (!e3) return x.confirm("页面设计对象不存在,不可保存!", "提示", { confirmButtonText: "确定", showCancelButton: false, type: "error" }), false;
|
|
38
38
|
const t2 = function() {
|
|
39
|
-
const e4 =
|
|
39
|
+
const e4 = G.value;
|
|
40
40
|
if (!e4.isStandard && !e4.jsContent) return h({ message: "方法内容不能为空!", type: "error" }), false;
|
|
41
41
|
if ("customFunc" == e4.name) {
|
|
42
42
|
if (e4.eventName && (e4.eventName = e4.eventName.trim()), !e4.funcParam) return h({ message: "自定义方法参数名不能为空!", type: "error" }), false;
|
|
@@ -48,7 +48,7 @@ const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style:
|
|
|
48
48
|
if (n3) {
|
|
49
49
|
if (!/^([a-zA-Z_$][a-zA-Z0-9_$]*(?:,[a-zA-Z_$][a-zA-Z0-9_$]*)*)$/.test(n3)) return h({ message: "方法参数只能以字母、下划线或$开头,只能包含数字、字母或$!", type: "error" }), false;
|
|
50
50
|
}
|
|
51
|
-
const a3 =
|
|
51
|
+
const a3 = P.pageContext;
|
|
52
52
|
if (a3 && a3.customEvents) {
|
|
53
53
|
for (let n4 of a3.customEvents) if ("customFunc" == n4.name && n4.eventName == t3 && n4.uuid != e4.uuid) return h({ message: "存在相同的方法名!", type: "error" }), false;
|
|
54
54
|
}
|
|
@@ -56,7 +56,7 @@ const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style:
|
|
|
56
56
|
}();
|
|
57
57
|
if (false === t2) return false;
|
|
58
58
|
e3.customEvents || (e3.customEvents = []);
|
|
59
|
-
const n2 =
|
|
59
|
+
const n2 = G.value;
|
|
60
60
|
let a2 = null, l2 = -1;
|
|
61
61
|
for (let t3 = 0; t3 < e3.customEvents.length; t3++) {
|
|
62
62
|
const u2 = e3.customEvents[t3];
|
|
@@ -78,20 +78,20 @@ const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style:
|
|
|
78
78
|
e4 > -1 && (t3.events[e4] = a2);
|
|
79
79
|
}
|
|
80
80
|
}
|
|
81
|
-
} else Object.assign(
|
|
82
|
-
|
|
81
|
+
} else Object.assign(D.value, n2), e3.customEvents.push(D.value);
|
|
82
|
+
D.value = n2, G.value = k(n2), h({ message: "暂存成功!", type: "success" });
|
|
83
83
|
}
|
|
84
|
-
function
|
|
84
|
+
function ne() {
|
|
85
85
|
x.confirm("确定要清除吗?", "确认", { confirmButtonText: "确定", cancelButtonText: "取消", type: "warning" }).then(() => {
|
|
86
86
|
!function() {
|
|
87
|
-
|
|
88
|
-
|
|
87
|
+
G.value && ae(G.value);
|
|
88
|
+
Y();
|
|
89
89
|
}();
|
|
90
90
|
});
|
|
91
91
|
}
|
|
92
|
-
function
|
|
93
|
-
const t2 = e3, n2 =
|
|
94
|
-
if (e3.isStandard)
|
|
92
|
+
function ae(e3) {
|
|
93
|
+
const t2 = e3, n2 = P.pageContext;
|
|
94
|
+
if (e3.isStandard) le(e3), ue(t2, e3);
|
|
95
95
|
else if (n2 && n2.customEvents) for (let e4 = 0; e4 < n2.customEvents.length; e4++) {
|
|
96
96
|
let a2 = n2.customEvents[e4];
|
|
97
97
|
if ("customFunc" == t2.name) {
|
|
@@ -100,63 +100,63 @@ const F = { style: { margin: "10px" } }, z = { class: "amb-design-tool", style:
|
|
|
100
100
|
break;
|
|
101
101
|
}
|
|
102
102
|
} else if (a2.name == t2.name && t2.componentUuid == a2.componentUuid) {
|
|
103
|
-
|
|
103
|
+
le(a2), n2.customEvents.splice(e4, 1), ue(t2, a2);
|
|
104
104
|
break;
|
|
105
105
|
}
|
|
106
106
|
}
|
|
107
107
|
}
|
|
108
|
-
function
|
|
108
|
+
function le(e3) {
|
|
109
109
|
e3.eventName = null, e3.isStandard = false, e3.jsContent = "", e3.remark = "", e3.standardValues = [];
|
|
110
110
|
}
|
|
111
|
-
function
|
|
112
|
-
const n2 =
|
|
111
|
+
function ue(e3, t2) {
|
|
112
|
+
const n2 = P.pageContext, a2 = S(n2, e3.componentUuid);
|
|
113
113
|
if (a2 && a2.events) {
|
|
114
114
|
const n3 = a2.events.findIndex((t3) => t3.name == e3.name && t3.componentUuid == e3.componentUuid);
|
|
115
115
|
n3 > -1 && (a2.events[n3] = t2);
|
|
116
116
|
}
|
|
117
117
|
}
|
|
118
118
|
n(() => {
|
|
119
|
-
|
|
120
|
-
if (
|
|
121
|
-
const t2 =
|
|
122
|
-
"customFunc" == e3.name ? e3.uuid == t2.uuid &&
|
|
119
|
+
I.value = window.innerHeight, q.value = { overflow: "auto", height: I.value + "px" }, U.$on("clearEvent", (e3) => {
|
|
120
|
+
if (ae(e3), G.value) {
|
|
121
|
+
const t2 = G.value;
|
|
122
|
+
"customFunc" == e3.name ? e3.uuid == t2.uuid && Y() : e3.componentUuid == t2.componentUuid && e3.name == t2.name && Y();
|
|
123
123
|
}
|
|
124
124
|
}), U.$on("editEvent", (e3) => {
|
|
125
125
|
let t2 = false;
|
|
126
|
-
if (
|
|
126
|
+
if (G.value && ("customFunc" == e3.name ? G.value.uuid == e3.uuid && (t2 = true) : G.value.componentUuid == e3.componentUuid && e3.name == G.value.name && (t2 = true)), t2) return;
|
|
127
127
|
null == e3.jsContent && (e3.jsContent = ""), null == e3.isStandard && (e3.isStandard = false, e3.standardValues = []), e3.isStandard && !e3.standardValues && (e3.standardValues = ["true"]);
|
|
128
|
-
const n2 =
|
|
128
|
+
const n2 = D.value ? JSON.stringify(D.value) : null, a2 = G.value ? JSON.stringify(G.value) : null;
|
|
129
129
|
n2 && n2 !== a2 ? x.confirm("当前方法有修改,是否需要暂存?", "确认", { confirmButtonText: "确定", cancelButtonText: "忽略", type: "warning" }).then(() => {
|
|
130
|
-
false !==
|
|
130
|
+
false !== te() && ee(e3);
|
|
131
131
|
}).catch((t3) => {
|
|
132
|
-
|
|
133
|
-
}) :
|
|
132
|
+
ee(e3);
|
|
133
|
+
}) : ee(e3);
|
|
134
134
|
});
|
|
135
135
|
}), a(() => {
|
|
136
|
-
U.$off("clearEvent"), U.$off("editEvent"),
|
|
137
|
-
}),
|
|
138
|
-
let
|
|
139
|
-
function
|
|
140
|
-
|
|
141
|
-
|
|
136
|
+
U.$off("clearEvent"), U.$off("editEvent"), oe && clearTimeout(oe), se && clearTimeout(se), O.clearSnapshotTimeout();
|
|
137
|
+
}), Y();
|
|
138
|
+
let oe, se, ie = false;
|
|
139
|
+
function re() {
|
|
140
|
+
oe && clearTimeout(oe), ie = true, O.undo(G), K.value = O.getTotalLen(), M.value = O.getCurrentIndex(), Z.value && Z.value.updateJsContent && Z.value.updateJsContent(G.value), oe = setTimeout(() => {
|
|
141
|
+
ie = false;
|
|
142
142
|
}, 100);
|
|
143
143
|
}
|
|
144
|
-
function
|
|
145
|
-
|
|
146
|
-
|
|
144
|
+
function me() {
|
|
145
|
+
se && clearTimeout(se), ie = true, O.record(G), K.value = O.getTotalLen(), M.value = O.getCurrentIndex(), Z.value && Z.value.updateJsContent && Z.value.updateJsContent(G.value), se = setTimeout(() => {
|
|
146
|
+
ie = false;
|
|
147
147
|
}, 100);
|
|
148
148
|
}
|
|
149
|
-
return l(() =>
|
|
150
|
-
|
|
151
|
-
|
|
149
|
+
return l(() => G, (e3) => {
|
|
150
|
+
ie || O.addSnapshot(G, function() {
|
|
151
|
+
K.value = O.getTotalLen(), M.value = O.getCurrentIndex();
|
|
152
152
|
});
|
|
153
|
-
}, { deep: true }),
|
|
154
|
-
|
|
153
|
+
}, { deep: true }), J2({ resize: function() {
|
|
154
|
+
Z.value && Z.value.resize && Z.value.resize();
|
|
155
155
|
} }), (e3, t2) => {
|
|
156
|
-
const n2 = u("Plus"), a2 = u("el-icon"), l2 = u("el-divider"), x2 = u("Check"), h2 = u("View"), E2 = u("el-text"), S2 = u("el-input"),
|
|
157
|
-
return s(), o("div", F, [i("div", z, [i("div", $, [i("label", { class: "amb-page-type", onClick:
|
|
156
|
+
const n2 = u("Plus"), a2 = u("el-icon"), l2 = u("el-divider"), x2 = u("Check"), h2 = u("View"), E2 = u("el-text"), S2 = u("el-input"), V2 = u("el-form-item"), k2 = u("el-checkbox"), _2 = u("el-checkbox-group"), T2 = u("el-option"), U2 = u("el-option-group"), J3 = u("el-select"), A2 = u("el-form");
|
|
157
|
+
return s(), o("div", F, [i("div", z, [i("div", $, [i("label", { class: "amb-page-type", onClick: X }, [r(a2, { size: 18 }, { default: c(() => [r(n2)]), _: 1 }), t2[5] || (t2[5] = i("label", null, "添加自定义方法", -1))]), r(l2, { direction: "vertical" }), m(i("label", j, null, 512), [[d, M.value < 1]]), m(i("label", { class: "amb-page-type", style: { "margin-left": "0px" }, onClick: re }, t2[6] || (t2[6] = [i("span", { class: "iconfont icon-chexiaozuo", style: { "font-size": "20px" }, title: "撤销" }, null, -1)]), 512), [[d, M.value > 0]]), m(i("label", { class: "amb-page-type", onClick: me }, t2[7] || (t2[7] = [i("span", { class: "iconfont icon-chexiaoyou", style: { "font-size": "20px" }, title: "恢复" }, null, -1)]), 512), [[d, M.value > -1 && M.value + 1 < K.value]])]), m(i("div", w, [i("label", { class: "amb-page-type", onClick: t2[0] || (t2[0] = (e4) => te()) }, [r(a2, { size: 18 }, { default: c(() => [r(x2)]), _: 1 }), t2[8] || (t2[8] = i("label", null, "确定", -1))]), r(l2, { direction: "vertical" }), i("label", { class: "amb-page-type", style: { "margin-left": "0px" }, onClick: ne }, [r(a2, { size: 18 }, { default: c(() => [r(h2)]), _: 1 }), t2[9] || (t2[9] = i("label", null, "清除", -1))])], 512), [[d, G.value.name]])]), r(A2, { class: "amb-design-board", style: { "padding-top": "20px" }, ref_key: "formRef", ref: Q, size: "small", model: v(H), "inline-message": "", "label-width": "80px" }, { default: c(() => [i("div", N, [r(V2, { label: "名称", "label-width": "auto", style: { "min-width": "280px" }, required: "customFunc" == G.value.name }, { default: c(() => [m(r(E2, { type: "primary" }, { default: c(() => [p(f(G.value.title ? G.value.title + (G.value.componentLabel ? "(" + G.value.componentLabel + ")" : "") : G.value.componentLabel) + "." + f(G.value.name), 1)]), _: 1 }, 512), [[d, G.value.name && "customFunc" != G.value.name]]), m(r(S2, { modelValue: G.value.eventName, "onUpdate:modelValue": t2[1] || (t2[1] = (e4) => G.value.eventName = e4), title: "自定义方法名" }, null, 8, ["modelValue"]), [[d, "customFunc" == G.value.name]])]), _: 1 }, 8, ["required"]), m(r(_2, { modelValue: G.value.standardValues, "onUpdate:modelValue": t2[2] || (t2[2] = (e4) => G.value.standardValues = e4), onChange: W }, { default: c(() => [r(k2, { value: "true", label: "标准功能" })]), _: 1 }, 8, ["modelValue"]), [[d, "customFunc" != G.value.name]]), m(r(J3, { disabled: !G.value.isStandard, modelValue: G.value.eventName, "onUpdate:modelValue": t2[3] || (t2[3] = (e4) => G.value.eventName = e4), placeholder: "请选择", filterable: "", style: { width: "240px", "margin-left": "10px" } }, { default: c(() => [(s(true), o(g, null, b(v(R), (e4) => (s(), y(U2, { key: e4.label, label: e4.label }, { default: c(() => [(s(true), o(g, null, b(e4.options, (e5) => (s(), y(T2, { key: e5.value, label: e5.label, value: e5.value }, null, 8, ["label", "value"]))), 128))]), _: 2 }, 1032, ["label"]))), 128))]), _: 1 }, 8, ["disabled", "modelValue"]), [[d, "customFunc" != G.value.name]]), r(V2, { label: "描述", "label-width": "auto", style: { flex: "1 1 auto" } }, { default: c(() => [r(S2, { modelValue: G.value.remark, "onUpdate:modelValue": t2[4] || (t2[4] = (e4) => G.value.remark = e4) }, null, 8, ["modelValue"])]), _: 1 })]), m(i("div", B, [r(C, { eventForm: G.value, ref_key: "editorRef", ref: Z }, null, 8, ["eventForm"])], 512), [[d, "customFunc" == G.value.name || "customFunc" != G.value.name && !G.value.isStandard]])]), _: 1 }, 8, ["model"])]);
|
|
158
158
|
};
|
|
159
159
|
} });
|
|
160
160
|
export {
|
|
161
|
-
|
|
161
|
+
J as default
|
|
162
162
|
};
|
|
@@ -1,15 +1,16 @@
|
|
|
1
|
-
import { defineComponent as e, ref as n, resolveComponent as t, createBlock as
|
|
2
|
-
import
|
|
1
|
+
import { defineComponent as e, ref as n, resolveComponent as t, createBlock as o, openBlock as r, withCtx as a, createVNode as u } from "vue";
|
|
2
|
+
import i from "./page-event-container.vue.js";
|
|
3
3
|
import l from "./page-event-content.vue.js";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
import c from "../view/components/el-aside-expand-component.vue.js";
|
|
5
|
+
const f = e({ __name: "page-event-view", setup(e2, { expose: f2 }) {
|
|
6
|
+
const s = n(null);
|
|
7
|
+
return f2({ resize: function() {
|
|
8
|
+
s.value && s.value.resize && s.value.resize();
|
|
8
9
|
} }), (e3, n2) => {
|
|
9
|
-
const
|
|
10
|
-
return r(),
|
|
10
|
+
const f3 = t("el-main"), m = t("el-container");
|
|
11
|
+
return r(), o(m, { class: "amb-container" }, { default: a(() => [u(c, null, { default: a(() => [u(i, { ref: "pageEventContainerRef", configure: e3.configure }, null, 8, ["configure"])]), _: 1 }), u(f3, { class: "amb-container-main" }, { default: a(() => [u(l, { configure: {}, eventForm: {}, ref_key: "contentRef", ref: s }, null, 512)]), _: 1 })]), _: 1 });
|
|
11
12
|
};
|
|
12
13
|
} });
|
|
13
14
|
export {
|
|
14
|
-
|
|
15
|
+
f as default
|
|
15
16
|
};
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
import { defineComponent as e, ref as n,
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { getAttrComponentByName as m, getComponentEventOptions as
|
|
5
|
-
import { deepCopy as
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
const
|
|
10
|
-
function
|
|
1
|
+
import { defineComponent as e, ref as n, createBlock as s, openBlock as t, resolveDynamicComponent as a } from "vue";
|
|
2
|
+
import o from "../../assemblys/page/page-attr.vue.js";
|
|
3
|
+
import u from "../../assemblys/error-attr.vue.js";
|
|
4
|
+
import { getAttrComponentByName as m, getComponentEventOptions as l } from "../../../utils/assemblys-config.js";
|
|
5
|
+
import { deepCopy as r } from "../../../utils/common-util.js";
|
|
6
|
+
const i = e({ __name: "attr-container", props: { pageInfo: Object, system: Object }, setup(e2, { expose: i2 }) {
|
|
7
|
+
const f = e2, p = n({}), c = n({});
|
|
8
|
+
p.value = f.pageInfo, c.value = o;
|
|
9
|
+
const v = n({ index: 1 }), g = {};
|
|
10
|
+
function y(e3) {
|
|
11
11
|
if (e3 && e3.name && "page" !== e3.name) {
|
|
12
12
|
!function(e4) {
|
|
13
13
|
if (!e4 || !e4.name || !e4.events) return;
|
|
14
|
-
const n3 =
|
|
14
|
+
const n3 = l(e4.name);
|
|
15
15
|
if (!n3) return;
|
|
16
|
-
const
|
|
17
|
-
for (let n4 of e4.events)
|
|
18
|
-
for (let
|
|
19
|
-
if (t2
|
|
20
|
-
const n4 =
|
|
16
|
+
const s2 = {};
|
|
17
|
+
for (let n4 of e4.events) s2[n4.name] = n4;
|
|
18
|
+
for (let t2 of n3) {
|
|
19
|
+
if (s2[t2.name]) continue;
|
|
20
|
+
const n4 = r(t2);
|
|
21
21
|
e4.events.push(n4);
|
|
22
22
|
}
|
|
23
|
-
}(e3),
|
|
24
|
-
let n2 =
|
|
25
|
-
null == n2 && (n2 = m(e3.name)), null == n2 && (n2 =
|
|
26
|
-
} else
|
|
23
|
+
}(e3), p.value = e3;
|
|
24
|
+
let n2 = g[e3.name];
|
|
25
|
+
null == n2 && (n2 = m(e3.name)), null == n2 && (n2 = u), g[e3.name] = n2, c.value = n2;
|
|
26
|
+
} else p.value = f.pageInfo, c.value = o;
|
|
27
27
|
}
|
|
28
|
-
return
|
|
29
|
-
|
|
30
|
-
} }), (n2,
|
|
28
|
+
return i2({ changeAssembly: y, changeAssemblyByComponent: function(e3, n2) {
|
|
29
|
+
p.value = e3, c.value = n2;
|
|
30
|
+
} }), (n2, o2) => (t(), s(a(c.value), { key: "attr_" + p.value.uuid, indexObj: v.value, pageDesign: e2.pageInfo, system: e2.system, configure: p.value, onChangeAssembly: y }, null, 40, ["indexObj", "pageDesign", "system", "configure"]));
|
|
31
31
|
} });
|
|
32
32
|
export {
|
|
33
|
-
|
|
33
|
+
i as default
|
|
34
34
|
};
|
package/dist/es/components/design/views/design/view/components/el-aside-expand-component.vue.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { ref as e, onMounted as t, watch as a, resolveComponent as l, createBlock as n, openBlock as i, normalizeStyle as d, normalizeClass as o, withCtx as r, withDirectives as s, createCommentVNode as u, createVNode as c, createElementVNode as g, renderSlot as f, vShow as p } from "vue";
|
|
2
|
+
/* empty css */
|
|
3
|
+
import v from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const h = v({ __name: "el-aside-expand-component", props: { direction: { type: String, default: "right", validator: (e2) => ["left", "right"].includes(e2) }, width: { type: String, default: "280px" }, defaultExpanded: { type: Boolean, default: true }, toggleable: { type: Boolean, default: true } }, emits: ["expand-change"], setup(v2, { emit: h2 }) {
|
|
5
|
+
const m = v2, x = h2, y = e(null), _ = e(m.defaultExpanded), b = e(false), w = () => !!y.value && (y.value.children.length > 0 || y.value.textContent.trim().length > 0), k = () => {
|
|
6
|
+
m.toggleable && (_.value = !_.value, x("expand-change", _.value));
|
|
7
|
+
};
|
|
8
|
+
return t(() => {
|
|
9
|
+
b.value = w();
|
|
10
|
+
}), a(() => {
|
|
11
|
+
var _a;
|
|
12
|
+
return (_a = y.value) == null ? void 0 : _a.innerHTML;
|
|
13
|
+
}, () => {
|
|
14
|
+
b.value = w();
|
|
15
|
+
}), a(() => m.toggleable, (e2) => {
|
|
16
|
+
e2 || (_.value = true);
|
|
17
|
+
}), (e2, t2) => {
|
|
18
|
+
const a2 = l("el-scrollbar"), h3 = l("el-button"), m2 = l("el-aside");
|
|
19
|
+
return i(), n(m2, { class: o(["transition-all duration-300 ease-in-out el-aside-expand-container", ["right" === v2.direction ? "right-aside" : "left-aside", { expanded: _.value }]]), style: d({ maxWidth: v2.width }) }, { default: r(() => [s(c(a2, { class: "amd-el-aside-content-scrollbar", height: "100%", style: d({ width: v2.width }) }, { default: r(() => [g("div", { class: "amd-el-aside-content", ref_key: "contentRef", ref: y }, [f(e2.$slots, "default", {}, void 0, true)], 512)]), _: 3 }, 8, ["style"]), [[p, _.value]]), v2.toggleable && b.value ? (i(), n(h3, { key: 0, type: "primary", size: "small", class: o(["toggle-btn", ["right" === v2.direction ? "right-toggle-btn" : "left-toggle-btn", { expanded: _.value }]]), onClick: k }, { default: r(() => [g("i", { class: o(["right" === v2.direction ? _.value ? "fa fa-chevron-left" : "fa fa-chevron-right" : _.value ? "fa fa-chevron-right" : "fa fa-chevron-left", "text-white"]) }, null, 2)]), _: 1 }, 8, ["class"])) : u("", true)]), _: 3 }, 8, ["class", "style"]);
|
|
20
|
+
};
|
|
21
|
+
} }, [["__scopeId", "data-v-51944ec4"]]);
|
|
22
|
+
export {
|
|
23
|
+
h as default
|
|
24
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as e, ref as t, onMounted as o, nextTick as l, resolveComponent as a, resolveDirective as n, createElementBlock as i, openBlock as s, Fragment as r, createElementVNode as p, createVNode as c, withDirectives as u, createBlock as d, unref as m, withCtx as g, createTextVNode as f } from "vue";
|
|
2
|
-
import { Plus as
|
|
2
|
+
import { Plus as y, Delete as b, Refresh as v } from "@element-plus/icons";
|
|
3
3
|
import w from "agilebuilder-ui/src/utils/request";
|
|
4
4
|
import { ElMessageBox as h, ElMessage as C, ElLoading as k } from "element-plus";
|
|
5
5
|
const S = { style: { padding: "0 0 10px 0" } }, T = e({ __name: "i18n-setting-enabled", props: { systemCode: { type: String, default: "" } }, emits: ["close"], setup(e2, { expose: T2, emit: A }) {
|
|
@@ -52,7 +52,7 @@ const S = { style: { padding: "0 0 10px 0" } }, T = e({ __name: "i18n-setting-en
|
|
|
52
52
|
}), o(() => {
|
|
53
53
|
}), T2({}), (e3, t2) => {
|
|
54
54
|
const o2 = a("el-button"), l2 = a("super-grid"), w2 = n("loading");
|
|
55
|
-
return s(), i(r, null, [p("div", S, [u((s(), d(o2, { disabled: N.value, icon: m(
|
|
55
|
+
return s(), i(r, null, [p("div", S, [u((s(), d(o2, { disabled: N.value, icon: m(y), type: "primary", onClick: j }, { default: g(() => t2[0] || (t2[0] = [f(" 新建 ")])), _: 1 }, 8, ["disabled", "icon"])), [[w2, N.value]]), u((s(), d(o2, { disabled: N.value, icon: m(b), type: "danger", onClick: q }, { default: g(() => t2[1] || (t2[1] = [f(" 删除 ")])), _: 1 }, 8, ["disabled", "icon"])), [[w2, N.value]]), u((s(), d(o2, { type: "default", align: "left", class: "button--default", icon: m(v), onClick: H }, { default: g(() => t2[2] || (t2[2] = [f(" 更新缓存 ")])), _: 1 }, 8, ["icon"])), [[w2, N.value]])]), c(l2, { style: { width: "100%" }, ref_key: "grid", ref: x, url: m(_) + "/bs/language-package/list", options: D, code: "BS_LANGUAGE_PACKAGE", onSelect: B, onSelectAll: B }, null, 8, ["url"])], 64);
|
|
56
56
|
};
|
|
57
57
|
} });
|
|
58
58
|
export {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import e from "./i18n-setting-page.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../../../../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const p = t(e, [["__scopeId", "data-v-
|
|
4
|
+
const p = t(e, [["__scopeId", "data-v-68ce085a"]]);
|
|
5
5
|
export {
|
|
6
6
|
p as default
|
|
7
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as e, ref as l, reactive as a, computed as t, resolveComponent as
|
|
1
|
+
import { defineComponent as e, ref as l, reactive as a, computed as t, resolveComponent as u, resolveDirective as n, createElementBlock as o, openBlock as s, Fragment as i, createElementVNode as r, withDirectives as d, createBlock as p, createCommentVNode as c, createVNode as g, unref as v, withCtx as m, createTextVNode as f, renderList as y, toDisplayString as h } from "vue";
|
|
2
2
|
import { Plus as C, Reading as b, Refresh as w } from "@element-plus/icons-vue";
|
|
3
3
|
import { ElMessageBox as D, ElMessage as E } from "element-plus";
|
|
4
4
|
import k from "agilebuilder-ui/src/utils/request";
|
|
@@ -72,8 +72,8 @@ const _ = { style: { padding: "0 0 10px 0" }, class: "amb-design-attr-item-inlin
|
|
|
72
72
|
L.value = false, J();
|
|
73
73
|
};
|
|
74
74
|
return O2({}), (l2, a2) => {
|
|
75
|
-
const t2 =
|
|
76
|
-
return s(), o(i, null, [r("div", _, [d((s(), p(t2, { align: "left", type: "primary", icon: v(C), onClick: Y }, { default: m(() => a2[4] || (a2[4] = [f(" 新增 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { align: "left", type: "primary", icon: v(b), onClick: N }, { default: m(() => a2[5] || (a2[5] = [f(" 自动翻译 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { align: "left", class: "button--default", icon: v(w), onClick: H }, { default: m(() => a2[6] || (a2[6] = [f(" 更新缓存 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { align: "left", class: "button--default", icon: v(w), onClick: J }, { default: m(() => a2[7] || (a2[7] = [f(" 刷新 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), g(D2, { style: { width: "200px", "margin-left": "20px" }, modelValue: B.value, "onUpdate:modelValue": a2[0] || (a2[0] = (e3) => B.value = e3), clearable: "", placeholder: "筛选" }, null, 8, ["modelValue"])]), d((s(), p(O3, { data: G.value, border: "", stripe: "", onSelectionChange: X, style: { width: "100%" }, height: U.value, size: "small" }, { default: m(() => [g(k2, { type: "selection", width: "55", align: "center" }), g(k2, { type: "index", width: "50", align: "center", label: "序号" }), g(k2, { prop: "CODE", label: "国际化编码", width: "180", align: "center" }), (s(true), o(i, null,
|
|
75
|
+
const t2 = u("el-button"), D2 = u("el-input"), k2 = u("el-table-column"), O3 = u("el-table"), K2 = u("el-form-item"), I2 = u("el-form"), Q2 = u("el-dialog"), ae = n("loading");
|
|
76
|
+
return s(), o(i, null, [r("div", _, [d((s(), p(t2, { align: "left", type: "primary", icon: v(C), onClick: Y }, { default: m(() => a2[4] || (a2[4] = [f(" 新增 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { align: "left", type: "primary", icon: v(b), onClick: N }, { default: m(() => a2[5] || (a2[5] = [f(" 自动翻译 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { type: "default", align: "left", class: "button--default", icon: v(w), onClick: H }, { default: m(() => a2[6] || (a2[6] = [f(" 更新缓存 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), d((s(), p(t2, { type: "default", align: "left", class: "button--default", icon: v(w), onClick: J }, { default: m(() => a2[7] || (a2[7] = [f(" 刷新 ")])), _: 1 }, 8, ["icon"])), [[ae, T.value]]), g(D2, { style: { width: "200px", "margin-left": "20px" }, modelValue: B.value, "onUpdate:modelValue": a2[0] || (a2[0] = (e3) => B.value = e3), clearable: "", placeholder: "筛选" }, null, 8, ["modelValue"])]), d((s(), p(O3, { data: G.value, border: "", stripe: "", onSelectionChange: X, style: { width: "100%" }, height: U.value, size: "small" }, { default: m(() => [g(k2, { type: "selection", width: "55", align: "center" }), g(k2, { type: "index", width: "50", align: "center", label: "序号" }), g(k2, { prop: "CODE", label: "国际化编码", width: "180", align: "center" }), (s(true), o(i, null, y(z.value, (e3) => (s(), p(k2, { prop: e3.value, label: e3.name, align: "center" }, { default: m((l3) => [P.value === l3.$index ? (s(), p(D2, { key: 0, modelValue: l3.row[e3.value], "onUpdate:modelValue": (a3) => l3.row[e3.value] = a3, size: "small", style: { "text-align": "center" }, class: "centered-input" }, null, 8, ["modelValue", "onUpdate:modelValue"])) : (s(), o("span", x, h(l3.row[e3.value]), 1))]), _: 2 }, 1032, ["prop", "label"]))), 256)), g(k2, { prop: "REMARK", label: "备注", width: "180", align: "center" }, { default: m((e3) => [P.value === e3.$index ? (s(), p(D2, { key: 0, modelValue: e3.row.REMARK, "onUpdate:modelValue": (l3) => e3.row.REMARK = l3, size: "small", class: "centered-input" }, null, 8, ["modelValue", "onUpdate:modelValue"])) : (s(), o("span", A, h(e3.row.REMARK), 1))]), _: 1 }), g(k2, { prop: "TRANSLATED", label: "已翻译", width: "180", align: "center" }, { default: m((e3) => [f(h(true === e3.row.TRANSLATED ? "是" : "否"), 1)]), _: 1 }), g(k2, { align: "center", label: "操作" }, { default: m((e3) => [-1 === P.value || P.value !== e3.$index ? (s(), o(i, { key: 0 }, [g(t2, { type: "default", size: "small", onClick: (l3) => {
|
|
77
77
|
return a3 = e3.$index, e3.row, void (-1 === P.value ? P.value = a3 : E.warning("请先保存或取消当前编辑行"));
|
|
78
78
|
var a3;
|
|
79
79
|
} }, { default: m(() => a2[8] || (a2[8] = [f(" 修改 ")])), _: 2 }, 1032, ["onClick"]), g(t2, { size: "small", type: "danger", onClick: (l3) => {
|
|
@@ -86,7 +86,7 @@ const _ = { style: { padding: "0 0 10px 0" }, class: "amb-design-attr-item-inlin
|
|
|
86
86
|
E.error("保存失败");
|
|
87
87
|
});
|
|
88
88
|
var a3;
|
|
89
|
-
} }, { default: m(() => a2[10] || (a2[10] = [f(" 保存 ")])), _: 2 }, 1032, ["onClick"]), g(t2, { size: "small", onClick: (l3) => (e3.$index, e3.row, void (P.value = -1)) }, { default: m(() => a2[11] || (a2[11] = [f(" 取消编辑 ")])), _: 2 }, 1032, ["onClick"])], 64)) : c("", true)]), _: 1 })]), _: 1 }, 8, ["data", "height"])), [[ae, T.value]]), r("span", null, "总条数:" +
|
|
89
|
+
} }, { default: m(() => a2[10] || (a2[10] = [f(" 保存 ")])), _: 2 }, 1032, ["onClick"]), g(t2, { type: "default", size: "small", onClick: (l3) => (e3.$index, e3.row, void (P.value = -1)) }, { default: m(() => a2[11] || (a2[11] = [f(" 取消编辑 ")])), _: 2 }, 1032, ["onClick"])], 64)) : c("", true)]), _: 1 })]), _: 1 }, 8, ["data", "height"])), [[ae, T.value]]), r("span", null, "总条数:" + h(G.value.length), 1), L.value ? (s(), p(V, { key: 0, systemCode: e2.pageDesign.systemCode, languages: z.value, errorTranslateData: q.value, onClose: le }, null, 8, ["systemCode", "languages", "errorTranslateData"])) : c("", true), S.value ? (s(), p(Q2, { key: 1, modelValue: S.value, "onUpdate:modelValue": a2[3] || (a2[3] = (e3) => S.value = e3), width: "500", title: "新增", "append-to-body": "" }, { footer: m(() => [r("div", R, [g(t2, { type: "default", onClick: ee }, { default: m(() => a2[12] || (a2[12] = [f("取消")])), _: 1 }), g(t2, { type: "primary", onClick: Z }, { default: m(() => a2[13] || (a2[13] = [f(" 保存 ")])), _: 1 })])]), default: m(() => [g(I2, { ref: "addFormRef", style: { "max-width": "600px" }, model: j.value, rules: F, "label-width": "auto", class: "demo-addForm", size: "small", "status-icon": "" }, { default: m(() => [g(K2, { label: "编码", prop: "CODE" }, { default: m(() => [g(D2, { modelValue: j.value.CODE, "onUpdate:modelValue": a2[1] || (a2[1] = (e3) => j.value.CODE = e3) }, null, 8, ["modelValue"])]), _: 1 }), (s(true), o(i, null, y(z.value, (e3) => (s(), p(K2, { prop: e3.value, label: e3.name }, { default: m(() => [g(D2, { modelValue: j.value[e3.value], "onUpdate:modelValue": (l3) => j.value[e3.value] = l3 }, null, 8, ["modelValue", "onUpdate:modelValue"])]), _: 2 }, 1032, ["prop", "label"]))), 256)), g(K2, { label: "备注", prop: "REMARK" }, { default: m(() => [g(D2, { modelValue: j.value.REMARK, "onUpdate:modelValue": a2[2] || (a2[2] = (e3) => j.value.REMARK = e3) }, null, 8, ["modelValue"])]), _: 1 })]), _: 1 }, 8, ["model", "rules"])]), _: 1 }, 8, ["modelValue"])) : c("", true)], 64);
|
|
90
90
|
};
|
|
91
91
|
} });
|
|
92
92
|
export {
|