zjh-web-ui 1.0.10 → 1.0.12
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/README.md +1 -1
- package/config/resolver.js +1 -1
- package/dist/components/HuiAMapMassMarkers/HuiAMapMassMarkers.vue.js +23 -23
- package/dist/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue.js +2 -2
- package/dist/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue2.js +27 -27
- package/dist/components/HuiAMapSearchAddressDialog/HuiAMapSearchAddressDialog.vue.js +38 -38
- package/dist/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue.js +2 -2
- package/dist/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue2.js +80 -80
- package/dist/components/HuiAMapSelectAddressDialog/HuiAMapSelectAddressDialog.vue.js +23 -23
- package/dist/components/HuiCountDownButton/HuiCountDownButton.vue.js +14 -14
- package/dist/components/HuiDataView/HuiDataView.vue2.js +37 -37
- package/dist/components/HuiGridForm/HuiGridForm.vue.js +2 -2
- package/dist/components/HuiGridForm/HuiGridForm.vue2.js +103 -103
- package/dist/components/HuiGridForm/HuiGridFormHooks.js +1 -1
- package/dist/components/HuiLineEditDialog/HuiLineEditDialog.vue2.js +69 -69
- package/dist/components/HuiLineEditPopover/HuiLineEditPopover.vue2.js +47 -47
- package/dist/components/HuiPreviewRichTextDialog/HuiPreviewRichTextDialog.vue.js +21 -21
- package/dist/components/HuiRegionTreeDialog/HuiRegionTreeDialog.vue.js +49 -49
- package/dist/components/HuiRegionTreeSelect/HuiRegionTreeSelect.vue.js +2 -2
- package/dist/components/HuiRegionTreeSelect/HuiRegionTreeSelect.vue2.js +3 -3
- package/dist/components/HuiSelectLoadStatus/HuiSelectLoadStatus.vue.js +14 -14
- package/dist/components/HuiShowUrlDialog/HuiShowUrlDialog.vue.js +18 -18
- package/dist/components/HuiStringArrayInputDialog/HuiStringArrayInputDialog.vue.js +50 -50
- package/dist/components/HuiTags/HuiTags.vue2.js +9 -9
- package/dist/components/HuiTagsMore/HuiTagsMore.vue.js +12 -16
- package/dist/components/HuiTinymce/HuiTinymce.vue.js +10 -10
- package/dist/components/HuiTinymce/HuiTinymceLinkHooks.js +1 -1
- package/dist/components/HuiTinymce/HuiTinymceSettingHooks.js +1 -1
- package/dist/components/HuiTinymceDialog/HuiTinymceDialog.vue.js +43 -43
- package/dist/components/HuiTip/HuiTip.vue.js +15 -15
- package/dist/hooks/useHuiFormDialog/useHuiFormDialog.js +1 -1
- package/dist/index.d.ts +2116 -0
- package/dist/style.css +1 -1
- package/dist/utils/hui-rules.js +1 -1
- package/dist/utils/hui-tool/message-box/index.js +7 -7
- package/dist/utils/hui-tool/message-box/message-box.vue2.js +112 -0
- package/dist/utils/hui-tool/message-box/message-box.vue3.js +2 -2
- package/global.d.ts +21 -21
- package/package.json +2 -2
- package/src/css/common-font.scss +3 -3
- package/types/index.d.ts +2115 -12
- package/dist/utils/hui-tool/message-box/message-box.vue.js +0 -112
- package/types/components/AMapConfig.d.ts +0 -2
- package/types/components/HuiAMapMassMarkers/HuiAMapMassMarkers.vue.d.ts +0 -105
- package/types/components/HuiAMapMassMarkers/index.d.ts +0 -107
- package/types/components/HuiAMapMassMarkers/type.d.ts +0 -58
- package/types/components/HuiAMapSearchAddress/HuiAMapSearchAddress.vue.d.ts +0 -76
- package/types/components/HuiAMapSearchAddress/index.d.ts +0 -77
- package/types/components/HuiAMapSearchAddress/type.d.ts +0 -19
- package/types/components/HuiAMapSearchAddressDialog/HuiAMapSearchAddressDialog.vue.d.ts +0 -38
- package/types/components/HuiAMapSearchAddressDialog/index.d.ts +0 -71
- package/types/components/HuiAMapSearchAddressDialog/type.d.ts +0 -17
- package/types/components/HuiAMapSelectAddress/HuiAMapSelectAddress.vue.d.ts +0 -76
- package/types/components/HuiAMapSelectAddress/index.d.ts +0 -77
- package/types/components/HuiAMapSelectAddress/type.d.ts +0 -19
- package/types/components/HuiAMapSelectAddressDialog/HuiAMapSelectAddressDialog.vue.d.ts +0 -38
- package/types/components/HuiAMapSelectAddressDialog/index.d.ts +0 -71
- package/types/components/HuiAMapSelectAddressDialog/type.d.ts +0 -17
- package/types/components/HuiCountDownButton/HuiCountDownButton.vue.d.ts +0 -44
- package/types/components/HuiCountDownButton/index.d.ts +0 -76
- package/types/components/HuiCountDownButton/type.d.ts +0 -20
- package/types/components/HuiDataView/HuiDataView.vue.d.ts +0 -60
- package/types/components/HuiDataView/index.d.ts +0 -109
- package/types/components/HuiDataView/type.d.ts +0 -49
- package/types/components/HuiGridForm/HuiGridForm.vue.d.ts +0 -77
- package/types/components/HuiGridForm/HuiGridFormHooks.d.ts +0 -4
- package/types/components/HuiGridForm/index.d.ts +0 -175
- package/types/components/HuiGridForm/type.d.ts +0 -67
- package/types/components/HuiLineEditDialog/HuiLineEditDialog.vue.d.ts +0 -75
- package/types/components/HuiLineEditDialog/index.d.ts +0 -173
- package/types/components/HuiLineEditDialog/type.d.ts +0 -86
- package/types/components/HuiLineEditPopover/HuiLineEditPopover.vue.d.ts +0 -74
- package/types/components/HuiLineEditPopover/index.d.ts +0 -133
- package/types/components/HuiLineEditPopover/type.d.ts +0 -23
- package/types/components/HuiPreviewRichTextDialog/HuiPreviewRichTextDialog.vue.d.ts +0 -31
- package/types/components/HuiPreviewRichTextDialog/index.d.ts +0 -22
- package/types/components/HuiPreviewRichTextDialog/type.d.ts +0 -4
- package/types/components/HuiRegionTreeDialog/HuiRegionTreeDialog.vue.d.ts +0 -53
- package/types/components/HuiRegionTreeDialog/index.d.ts +0 -68
- package/types/components/HuiRegionTreeDialog/type.d.ts +0 -24
- package/types/components/HuiRegionTreeSelect/HuiRegionTreeSelect.vue.d.ts +0 -25
- package/types/components/HuiRegionTreeSelect/index.d.ts +0 -29
- package/types/components/HuiRegionTreeSelect/type.d.ts +0 -6
- package/types/components/HuiSelectLoadStatus/HuiSelectLoadStatus.vue.d.ts +0 -14
- package/types/components/HuiSelectLoadStatus/index.d.ts +0 -33
- package/types/components/HuiSelectLoadStatus/type.d.ts +0 -11
- package/types/components/HuiShowUrlDialog/HuiShowUrlDialog.vue.d.ts +0 -37
- package/types/components/HuiShowUrlDialog/index.d.ts +0 -40
- package/types/components/HuiShowUrlDialog/type.d.ts +0 -11
- package/types/components/HuiStringArrayInputDialog/HuiStringArrayInputDialog.vue.d.ts +0 -44
- package/types/components/HuiStringArrayInputDialog/index.d.ts +0 -67
- package/types/components/HuiStringArrayInputDialog/type.d.ts +0 -33
- package/types/components/HuiTags/HuiTags.vue.d.ts +0 -37
- package/types/components/HuiTags/index.d.ts +0 -36
- package/types/components/HuiTagsMore/HuiTagsMore.vue.d.ts +0 -93
- package/types/components/HuiTagsMore/index.d.ts +0 -92
- package/types/components/HuiTinymce/HuiTinymce.vue.d.ts +0 -62
- package/types/components/HuiTinymce/HuiTinymceLinkHooks.d.ts +0 -3
- package/types/components/HuiTinymce/HuiTinymceSettingHooks.d.ts +0 -3
- package/types/components/HuiTinymce/index.d.ts +0 -66
- package/types/components/HuiTinymce/type.d.ts +0 -51
- package/types/components/HuiTinymceDialog/HuiTinymceDialog.vue.d.ts +0 -53
- package/types/components/HuiTinymceDialog/index.d.ts +0 -78
- package/types/components/HuiTinymceDialog/type.d.ts +0 -12
- package/types/components/HuiTip/HuiTip.vue.d.ts +0 -22
- package/types/components/HuiTip/index.d.ts +0 -99
- package/types/components/HuiTip/type.d.ts +0 -14
- package/types/components-install-list.d.ts +0 -3328
- package/types/components.d.ts +0 -21
- package/types/delegate.d.ts +0 -41
- package/types/directives/index.d.ts +0 -4
- package/types/directives/install-loadmore.d.ts +0 -7
- package/types/directives/select-loadmore.d.ts +0 -7
- package/types/hooks/index.d.ts +0 -3
- package/types/hooks/useHuiDialog/useHuiDialog.d.ts +0 -18
- package/types/hooks/useHuiFormDialog/formDialogPropsDef.d.ts +0 -3
- package/types/hooks/useHuiFormDialog/type.d.ts +0 -90
- package/types/hooks/useHuiFormDialog/useHuiFormDialog.d.ts +0 -32
- package/types/install-helper/install.d.ts +0 -18
- package/types/install-helper/typescript.d.ts +0 -14
- package/types/utils/hui-rules.d.ts +0 -80
- package/types/utils/hui-tool/index.d.ts +0 -8
- package/types/utils/hui-tool/message-box/index.d.ts +0 -18
- package/types/utils/hui-tool/message-box/message-box.vue.d.ts +0 -36
- package/types/utils/hui-tool/msg-tool.d.ts +0 -26
- package/types/utils/index.d.ts +0 -2
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ElDialog as K,
|
|
1
|
+
import { defineComponent as U, ref as g, reactive as A, computed as p, createBlock as m, openBlock as s, unref as o, isRef as W, withCtx as i, createVNode as f, mergeProps as D, createCommentVNode as x, createElementBlock as q, Fragment as $, renderList as j, createElementVNode as G, createTextVNode as B, nextTick as J } from "vue";
|
|
2
|
+
import { ElDialog as K, ElForm as Q, ElFormItem as X, ElInput as Y, ElSelect as Z, ElOption as _, ElButton as S, ElMessage as h } from "element-plus";
|
|
3
3
|
import { useHuiDialog as ee } from "../../hooks/useHuiDialog/useHuiDialog.js";
|
|
4
4
|
import { HuiTool as le } from "../../utils/hui-tool/index.js";
|
|
5
|
-
import "
|
|
6
|
-
const ie = /* @__PURE__ */
|
|
5
|
+
import "zjh-utils";
|
|
6
|
+
const ie = /* @__PURE__ */ U({
|
|
7
7
|
name: "HuiLineEditDialog",
|
|
8
8
|
__name: "HuiLineEditDialog",
|
|
9
9
|
props: {
|
|
@@ -23,134 +23,134 @@ const ie = /* @__PURE__ */ x({
|
|
|
23
23
|
permission: { default: () => ({}) }
|
|
24
24
|
},
|
|
25
25
|
emits: ["onValueChange", "onSubmit"],
|
|
26
|
-
setup(
|
|
27
|
-
const e =
|
|
26
|
+
setup(a, { expose: H, emit: R }) {
|
|
27
|
+
const e = a, c = R, { show: v, open: T, close: n, payload: b, confirmLoading: N } = ee(), y = g(), C = g(), u = g(null), r = A({
|
|
28
28
|
inputData: null
|
|
29
|
-
}),
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
|
|
29
|
+
}), V = p(() => e.type === "input" || e.type === "textarea"), P = p(() => e.type === "select"), k = p(() => e.placeholder || `请输入${e.label}`), F = p(() => ({ inputData: e.rules })), E = () => {
|
|
30
|
+
c("onValueChange", r, u.value);
|
|
31
|
+
}, I = async () => {
|
|
32
|
+
L() && y.value.validate(async (l) => {
|
|
33
33
|
if (l)
|
|
34
|
-
if (
|
|
34
|
+
if (u.value[e.prop] = r.inputData, e.isNeedDoubleConfirm) {
|
|
35
35
|
const [, t] = await le.msgBox(e.doubleConfirmTips);
|
|
36
|
-
t ? (
|
|
36
|
+
t ? (c("onSubmit", u.value, e.prop), n()) : h({
|
|
37
37
|
type: "info",
|
|
38
38
|
message: "操作已取消"
|
|
39
39
|
});
|
|
40
40
|
} else
|
|
41
|
-
|
|
41
|
+
c("onSubmit", u.value, e.prop), n();
|
|
42
42
|
else
|
|
43
|
-
return
|
|
43
|
+
return h.error("验证未通过"), !1;
|
|
44
44
|
});
|
|
45
45
|
};
|
|
46
|
-
function
|
|
47
|
-
const { code:
|
|
46
|
+
function L() {
|
|
47
|
+
const { code: d, tip: l, checkRight: t } = e.permission;
|
|
48
48
|
if (t)
|
|
49
49
|
return t();
|
|
50
|
-
if (!
|
|
51
|
-
const
|
|
52
|
-
return
|
|
50
|
+
if (!d) return !0;
|
|
51
|
+
const w = window.huiDelegate.getBtnPermission()[d] ?? !1;
|
|
52
|
+
return w || h.error(l || "暂无权限,请联系管理员!"), w;
|
|
53
53
|
}
|
|
54
|
-
const
|
|
55
|
-
if (!
|
|
54
|
+
const M = () => {
|
|
55
|
+
if (!b) {
|
|
56
56
|
n();
|
|
57
57
|
return;
|
|
58
58
|
}
|
|
59
|
-
|
|
60
|
-
|
|
59
|
+
u.value = b.value, r.inputData = u.value[e.prop] >= 0 || u.value[e.prop] ? u.value[e.prop] : "", J(() => {
|
|
60
|
+
V.value && C.value.focus();
|
|
61
61
|
});
|
|
62
|
+
}, z = () => {
|
|
63
|
+
y.value.resetFields(), u.value = null, r.inputData = "", b.value = {};
|
|
62
64
|
}, O = () => {
|
|
63
|
-
b.value.resetFields(), r.value = null, u.inputData = "", v.value = {};
|
|
64
|
-
}, U = () => {
|
|
65
65
|
n();
|
|
66
66
|
};
|
|
67
|
-
return
|
|
68
|
-
open:
|
|
67
|
+
return H({
|
|
68
|
+
open: T,
|
|
69
69
|
close: n
|
|
70
|
-
}), (
|
|
71
|
-
modelValue:
|
|
72
|
-
"onUpdate:modelValue": l[2] || (l[2] = (t) => W(
|
|
73
|
-
title:
|
|
70
|
+
}), (d, l) => (s(), m(o(K), {
|
|
71
|
+
modelValue: o(v),
|
|
72
|
+
"onUpdate:modelValue": l[2] || (l[2] = (t) => W(v) ? v.value = t : null),
|
|
73
|
+
title: a.title,
|
|
74
74
|
width: "450px",
|
|
75
75
|
top: "35vh",
|
|
76
76
|
"modal-append-to-body": !1,
|
|
77
77
|
"append-to-body": "",
|
|
78
|
-
onOpen:
|
|
79
|
-
onClose:
|
|
78
|
+
onOpen: M,
|
|
79
|
+
onClose: z
|
|
80
80
|
}, {
|
|
81
81
|
footer: i(() => [
|
|
82
|
-
|
|
83
|
-
|
|
82
|
+
G("div", null, [
|
|
83
|
+
f(o(S), {
|
|
84
84
|
size: "large",
|
|
85
85
|
class: "!c-primary !border !border-1 !border-[theme(colors.primary)] !px-16 !text-14",
|
|
86
|
-
onClick:
|
|
86
|
+
onClick: O
|
|
87
87
|
}, {
|
|
88
|
-
default: i(() => l[3] || (l[3] = [
|
|
89
|
-
|
|
90
|
-
])),
|
|
88
|
+
default: i(() => [...l[3] || (l[3] = [
|
|
89
|
+
B("取 消", -1)
|
|
90
|
+
])]),
|
|
91
91
|
_: 1
|
|
92
92
|
}),
|
|
93
|
-
|
|
93
|
+
f(o(S), {
|
|
94
94
|
size: "large",
|
|
95
95
|
type: "primary",
|
|
96
|
-
loading:
|
|
96
|
+
loading: o(N),
|
|
97
97
|
class: "w-120 !ml-20",
|
|
98
|
-
onClick:
|
|
98
|
+
onClick: I
|
|
99
99
|
}, {
|
|
100
|
-
default: i(() => l[4] || (l[4] = [
|
|
101
|
-
|
|
102
|
-
])),
|
|
100
|
+
default: i(() => [...l[4] || (l[4] = [
|
|
101
|
+
B("确 定", -1)
|
|
102
|
+
])]),
|
|
103
103
|
_: 1
|
|
104
104
|
}, 8, ["loading"])
|
|
105
105
|
])
|
|
106
106
|
]),
|
|
107
107
|
default: i(() => [
|
|
108
|
-
|
|
108
|
+
f(o(Q), D({
|
|
109
109
|
ref_key: "formRef",
|
|
110
|
-
ref:
|
|
111
|
-
model:
|
|
112
|
-
rules:
|
|
113
|
-
},
|
|
110
|
+
ref: y,
|
|
111
|
+
model: r,
|
|
112
|
+
rules: F.value
|
|
113
|
+
}, a.formAttr, {
|
|
114
114
|
"require-asterisk-position": "right",
|
|
115
115
|
class: "mt-20",
|
|
116
|
-
"label-width":
|
|
116
|
+
"label-width": a.labelWidth
|
|
117
117
|
}), {
|
|
118
118
|
default: i(() => [
|
|
119
|
-
|
|
120
|
-
label:
|
|
119
|
+
f(o(X), {
|
|
120
|
+
label: a.label,
|
|
121
121
|
prop: "inputData"
|
|
122
122
|
}, {
|
|
123
123
|
default: i(() => [
|
|
124
|
-
|
|
124
|
+
V.value ? (s(), m(o(Y), D({ key: 0 }, a.attr, {
|
|
125
125
|
ref_key: "inputRef",
|
|
126
|
-
ref:
|
|
127
|
-
modelValue:
|
|
128
|
-
"onUpdate:modelValue": l[0] || (l[0] = (t) =>
|
|
126
|
+
ref: C,
|
|
127
|
+
modelValue: r.inputData,
|
|
128
|
+
"onUpdate:modelValue": l[0] || (l[0] = (t) => r.inputData = t),
|
|
129
129
|
modelModifiers: { trim: !0 },
|
|
130
|
-
type:
|
|
131
|
-
placeholder:
|
|
130
|
+
type: a.type,
|
|
131
|
+
placeholder: k.value,
|
|
132
132
|
clearable: "",
|
|
133
133
|
autosize: "",
|
|
134
|
-
onInput:
|
|
135
|
-
onFocus:
|
|
136
|
-
}), null, 16, ["modelValue", "type", "placeholder"])) :
|
|
137
|
-
|
|
138
|
-
modelValue:
|
|
139
|
-
"onUpdate:modelValue": l[1] || (l[1] = (t) =>
|
|
134
|
+
onInput: E,
|
|
135
|
+
onFocus: E
|
|
136
|
+
}), null, 16, ["modelValue", "type", "placeholder"])) : x("", !0),
|
|
137
|
+
P.value ? (s(), m(o(Z), D({ key: 1 }, a.attr, {
|
|
138
|
+
modelValue: r.inputData,
|
|
139
|
+
"onUpdate:modelValue": l[1] || (l[1] = (t) => r.inputData = t),
|
|
140
140
|
class: "w-100%",
|
|
141
141
|
filterable: "",
|
|
142
|
-
multiple:
|
|
143
|
-
placeholder:
|
|
142
|
+
multiple: a.isSelectMuti,
|
|
143
|
+
placeholder: k.value
|
|
144
144
|
}), {
|
|
145
145
|
default: i(() => [
|
|
146
|
-
(s(!0),
|
|
146
|
+
(s(!0), q($, null, j(a.selectDic, (t) => (s(), m(o(_), {
|
|
147
147
|
key: t.value,
|
|
148
148
|
label: t.label,
|
|
149
149
|
value: t.value
|
|
150
150
|
}, null, 8, ["label", "value"]))), 128))
|
|
151
151
|
]),
|
|
152
152
|
_: 1
|
|
153
|
-
}, 16, ["modelValue", "multiple", "placeholder"])) :
|
|
153
|
+
}, 16, ["modelValue", "multiple", "placeholder"])) : x("", !0)
|
|
154
154
|
]),
|
|
155
155
|
_: 1
|
|
156
156
|
}, 8, ["label"])
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as V, mergeModels as k, useModel as B, reactive as M, ref as
|
|
2
|
-
import { ElPopover as q, ElForm as A, ElFormItem as G, ElInput as J, ElButton as
|
|
1
|
+
import { defineComponent as V, mergeModels as k, useModel as B, reactive as M, ref as m, computed as R, onMounted as T, onBeforeUnmount as z, createBlock as F, openBlock as x, unref as n, withCtx as i, createVNode as s, createElementBlock as K, createCommentVNode as L, withKeys as N, withModifiers as P, createElementVNode as p, normalizeClass as S, renderSlot as U, createTextVNode as H, toDisplayString as I, nextTick as $, toValue as j } from "vue";
|
|
2
|
+
import { ElPopover as q, ElForm as A, ElFormItem as G, ElInput as J, ElButton as E } from "element-plus";
|
|
3
3
|
const O = {
|
|
4
4
|
key: 0,
|
|
5
5
|
class: "flex"
|
|
@@ -17,104 +17,104 @@ const O = {
|
|
|
17
17
|
rowModifiers: {}
|
|
18
18
|
}),
|
|
19
19
|
emits: /* @__PURE__ */ k(["confirm"], ["update:row"]),
|
|
20
|
-
setup(
|
|
21
|
-
const
|
|
20
|
+
setup(l, { emit: b }) {
|
|
21
|
+
const d = l, u = B(l, "row"), g = b, a = M({ inputData: null }), r = m(!1), c = m(null), v = m(null), C = R(() => ({ inputData: d.rules }));
|
|
22
22
|
T(() => {
|
|
23
23
|
window.addEventListener("keyup", y);
|
|
24
24
|
});
|
|
25
25
|
function h() {
|
|
26
|
-
|
|
27
|
-
var
|
|
28
|
-
(
|
|
26
|
+
a.inputData = u.value[d.field], setTimeout(() => {
|
|
27
|
+
var t;
|
|
28
|
+
(t = c.value) == null || t.focus();
|
|
29
29
|
}, 10);
|
|
30
30
|
}
|
|
31
|
-
async function D(
|
|
32
|
-
var
|
|
33
|
-
await $(), (
|
|
31
|
+
async function D(t) {
|
|
32
|
+
var e, o;
|
|
33
|
+
await $(), (e = t.currentTarget) != null && e.select() && ((o = t.currentTarget) == null || o.select());
|
|
34
34
|
}
|
|
35
35
|
function w() {
|
|
36
|
-
var
|
|
37
|
-
(
|
|
38
|
-
|
|
36
|
+
var t;
|
|
37
|
+
(t = v.value) == null || t.validate((e) => {
|
|
38
|
+
e && (u.value[d.field] = a.inputData, g("confirm", j(u)), f());
|
|
39
39
|
});
|
|
40
40
|
}
|
|
41
|
-
function
|
|
41
|
+
function f() {
|
|
42
42
|
r.value = !1;
|
|
43
43
|
}
|
|
44
|
-
function y(
|
|
45
|
-
(
|
|
44
|
+
function y(t) {
|
|
45
|
+
(t.keyCode == 27 || t.code == "Escape") && (f(), t.stopPropagation());
|
|
46
46
|
}
|
|
47
47
|
return z(() => {
|
|
48
48
|
window.removeEventListener("keyup", y);
|
|
49
|
-
}), (
|
|
49
|
+
}), (t, e) => (x(), F(n(q), {
|
|
50
50
|
visible: r.value,
|
|
51
|
-
"onUpdate:visible":
|
|
51
|
+
"onUpdate:visible": e[3] || (e[3] = (o) => r.value = o),
|
|
52
52
|
placement: "top",
|
|
53
|
-
width:
|
|
53
|
+
width: l.width,
|
|
54
54
|
trigger: "click",
|
|
55
|
-
disabled:
|
|
55
|
+
disabled: l.disabled,
|
|
56
56
|
"popper-style": "height:76px;",
|
|
57
57
|
onShow: h
|
|
58
58
|
}, {
|
|
59
|
-
reference:
|
|
60
|
-
|
|
61
|
-
class:
|
|
59
|
+
reference: i(() => [
|
|
60
|
+
p("span", {
|
|
61
|
+
class: S([l.baseClass, l.disabled ? "cursor-not-allowed" : "cursor-pointer"])
|
|
62
62
|
}, [
|
|
63
|
-
|
|
64
|
-
|
|
63
|
+
U(t.$slots, "default", {}, () => [
|
|
64
|
+
H(I(u.value[l.field]), 1)
|
|
65
65
|
], !0)
|
|
66
66
|
], 2)
|
|
67
67
|
]),
|
|
68
|
-
default:
|
|
69
|
-
s(
|
|
68
|
+
default: i(() => [
|
|
69
|
+
s(n(A), {
|
|
70
70
|
ref_key: "formRef",
|
|
71
71
|
ref: v,
|
|
72
|
-
model:
|
|
72
|
+
model: a,
|
|
73
73
|
rules: C.value
|
|
74
74
|
}, {
|
|
75
|
-
default:
|
|
76
|
-
r.value ? (
|
|
77
|
-
s(
|
|
78
|
-
default:
|
|
79
|
-
s(
|
|
75
|
+
default: i(() => [
|
|
76
|
+
r.value ? (x(), K("div", O, [
|
|
77
|
+
s(n(G), { prop: "inputData" }, {
|
|
78
|
+
default: i(() => [
|
|
79
|
+
s(n(J), {
|
|
80
80
|
ref_key: "inputRef",
|
|
81
81
|
ref: c,
|
|
82
|
-
modelValue:
|
|
83
|
-
"onUpdate:modelValue":
|
|
82
|
+
modelValue: a.inputData,
|
|
83
|
+
"onUpdate:modelValue": e[0] || (e[0] = (o) => a.inputData = o),
|
|
84
84
|
class: "!m-2 p-0",
|
|
85
85
|
size: "small",
|
|
86
|
-
onKeyup:
|
|
87
|
-
onFocus:
|
|
86
|
+
onKeyup: N(P(w, ["prevent"]), ["enter"]),
|
|
87
|
+
onFocus: e[1] || (e[1] = (o) => D(o))
|
|
88
88
|
}, null, 8, ["modelValue", "onKeyup"])
|
|
89
89
|
]),
|
|
90
90
|
_: 1
|
|
91
91
|
}),
|
|
92
|
-
s(
|
|
92
|
+
s(n(E), {
|
|
93
93
|
class: "!m-2 !w-32 !h-28 !text-18 !p-4 flex-shrink-0",
|
|
94
94
|
type: "primary",
|
|
95
95
|
onClick: w
|
|
96
96
|
}, {
|
|
97
|
-
default:
|
|
98
|
-
|
|
97
|
+
default: i(() => [...e[4] || (e[4] = [
|
|
98
|
+
p("i", {
|
|
99
99
|
class: "icon-com i-com-gou",
|
|
100
100
|
style: { "font-size": "12px" }
|
|
101
101
|
}, null, -1)
|
|
102
|
-
])),
|
|
102
|
+
])]),
|
|
103
103
|
_: 1
|
|
104
104
|
}),
|
|
105
|
-
s(
|
|
105
|
+
s(n(E), {
|
|
106
106
|
class: "!m-2 !w-32 !h-28 !text-18 !p-4 flex-shrink-0",
|
|
107
|
-
onClick:
|
|
107
|
+
onClick: e[2] || (e[2] = (o) => f())
|
|
108
108
|
}, {
|
|
109
|
-
default:
|
|
110
|
-
|
|
109
|
+
default: i(() => [...e[5] || (e[5] = [
|
|
110
|
+
p("i", {
|
|
111
111
|
class: "icon-com i-com-cha",
|
|
112
112
|
style: { "font-size": "12px" }
|
|
113
113
|
}, null, -1)
|
|
114
|
-
])),
|
|
114
|
+
])]),
|
|
115
115
|
_: 1
|
|
116
116
|
})
|
|
117
|
-
])) :
|
|
117
|
+
])) : L("", !0)
|
|
118
118
|
]),
|
|
119
119
|
_: 1
|
|
120
120
|
}, 8, ["model", "rules"])
|
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
import { defineComponent as v, ref as
|
|
2
|
-
import { ElDialog as
|
|
1
|
+
import { defineComponent as v, ref as x, createBlock as b, openBlock as h, unref as i, isRef as y, withCtx as r, createElementVNode as V, createVNode as w, createTextVNode as C, toValue as a } from "vue";
|
|
2
|
+
import { ElDialog as _, ElButton as g } from "element-plus";
|
|
3
3
|
import { useHuiDialog as H } from "../../hooks/useHuiDialog/useHuiDialog.js";
|
|
4
|
-
import { testUtils as T } from "
|
|
5
|
-
/* empty css
|
|
4
|
+
import { testUtils as T } from "zjh-utils";
|
|
5
|
+
/* empty css */
|
|
6
6
|
const D = ["innerHTML"], M = /* @__PURE__ */ v({
|
|
7
7
|
name: "HuiPreviewRichTextDialog",
|
|
8
8
|
__name: "HuiPreviewRichTextDialog",
|
|
9
9
|
props: {
|
|
10
10
|
title: { default: "内容预览" }
|
|
11
11
|
},
|
|
12
|
-
setup(
|
|
13
|
-
const { show: o, payload: t, open:
|
|
14
|
-
function
|
|
12
|
+
setup(u, { expose: d }) {
|
|
13
|
+
const { show: o, payload: t, open: p, close: l } = H(), n = x("");
|
|
14
|
+
function s() {
|
|
15
15
|
if (T.isEmpty(a(t))) {
|
|
16
16
|
l();
|
|
17
17
|
return;
|
|
18
18
|
}
|
|
19
19
|
n.value = a(t).content;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function f() {
|
|
22
22
|
n.value = "", t.value = {};
|
|
23
23
|
}
|
|
24
|
-
const
|
|
24
|
+
const m = () => {
|
|
25
25
|
l();
|
|
26
26
|
};
|
|
27
|
-
return
|
|
28
|
-
open:
|
|
27
|
+
return d({
|
|
28
|
+
open: p,
|
|
29
29
|
close: l
|
|
30
|
-
}), (
|
|
30
|
+
}), (E, e) => (h(), b(i(_), {
|
|
31
31
|
modelValue: i(o),
|
|
32
32
|
"onUpdate:modelValue": e[0] || (e[0] = (c) => y(o) ? o.value = c : null),
|
|
33
|
-
title:
|
|
33
|
+
title: u.title,
|
|
34
34
|
width: "80%",
|
|
35
35
|
top: "5vh",
|
|
36
36
|
"modal-append-to-body": "",
|
|
37
37
|
"append-to-body": "",
|
|
38
|
-
onOpen:
|
|
39
|
-
onClose:
|
|
38
|
+
onOpen: s,
|
|
39
|
+
onClose: f
|
|
40
40
|
}, {
|
|
41
41
|
footer: r(() => [
|
|
42
|
-
|
|
42
|
+
w(i(g), {
|
|
43
43
|
type: "primary",
|
|
44
44
|
size: "large",
|
|
45
|
-
onClick:
|
|
45
|
+
onClick: m
|
|
46
46
|
}, {
|
|
47
|
-
default: r(() => e[1] || (e[1] = [
|
|
48
|
-
|
|
49
|
-
])),
|
|
47
|
+
default: r(() => [...e[1] || (e[1] = [
|
|
48
|
+
C("关 闭", -1)
|
|
49
|
+
])]),
|
|
50
50
|
_: 1
|
|
51
51
|
})
|
|
52
52
|
]),
|
|
53
53
|
default: r(() => [
|
|
54
|
-
|
|
54
|
+
V("div", {
|
|
55
55
|
class: "rd-5 px-10 b b-solid b-ddd overflow-y-auto h-80vh",
|
|
56
56
|
innerHTML: n.value
|
|
57
57
|
}, null, 8, D)
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as q, ref as
|
|
2
|
-
import { ElDialog as X,
|
|
1
|
+
import { defineComponent as q, ref as k, onMounted as F, watch as G, createBlock as J, openBlock as P, unref as o, isRef as Q, withCtx as r, createVNode as d, createElementVNode as D, createTextVNode as E, nextTick as W, toValue as b } from "vue";
|
|
2
|
+
import { ElDialog as X, ElInput as Y, ElTree as Z, ElButton as _ } from "element-plus";
|
|
3
3
|
import { useHuiDialog as $ } from "../../hooks/useHuiDialog/useHuiDialog.js";
|
|
4
|
-
import "
|
|
5
|
-
/* empty css
|
|
4
|
+
import "zjh-utils";
|
|
5
|
+
/* empty css */
|
|
6
6
|
const ee = { class: "h-70vh overflow-y-scroll" }, le = { class: "mt-20" }, ie = /* @__PURE__ */ q({
|
|
7
7
|
name: "HuiRegionTreeDialog",
|
|
8
8
|
__name: "HuiRegionTreeDialog",
|
|
@@ -14,46 +14,46 @@ const ee = { class: "h-70vh overflow-y-scroll" }, le = { class: "mt-20" }, ie =
|
|
|
14
14
|
showCheckbox: { type: Boolean, default: !0 }
|
|
15
15
|
},
|
|
16
16
|
emits: ["onSubmit"],
|
|
17
|
-
setup(
|
|
18
|
-
const { id: S, show:
|
|
17
|
+
setup(u, { expose: N, emit: H }) {
|
|
18
|
+
const { id: S, show: f, open: z, close: c, payload: i, confirmLoading: p } = $(), a = u, O = H, m = k(""), y = k([]), h = k(null);
|
|
19
19
|
F(async () => {
|
|
20
|
-
|
|
21
|
-
}), G(
|
|
20
|
+
y.value = await window.huiDelegate.getRegionTree();
|
|
21
|
+
}), G(m, (t) => {
|
|
22
22
|
var l;
|
|
23
|
-
(l =
|
|
23
|
+
(l = h.value) == null || l.filter(t);
|
|
24
24
|
});
|
|
25
25
|
function U() {
|
|
26
|
-
const
|
|
27
|
-
|
|
26
|
+
const t = (l) => {
|
|
27
|
+
b(l).forEach((e) => {
|
|
28
28
|
var n, s;
|
|
29
|
-
e.hasChildren ?
|
|
29
|
+
e.hasChildren ? t(e.children) : e.disabled = (s = (n = b(i)) == null ? void 0 : n.disabledRegions) == null ? void 0 : s.includes(e.id);
|
|
30
30
|
});
|
|
31
31
|
};
|
|
32
32
|
W(() => {
|
|
33
|
-
|
|
33
|
+
t(y);
|
|
34
34
|
});
|
|
35
35
|
}
|
|
36
36
|
function A() {
|
|
37
|
-
i.value = {},
|
|
37
|
+
i.value = {}, p.value = !1;
|
|
38
38
|
}
|
|
39
39
|
function I() {
|
|
40
|
-
|
|
41
|
-
const
|
|
42
|
-
O("onSubmit", { id:
|
|
40
|
+
p.value = !0;
|
|
41
|
+
const t = h.value.getCheckedKeys(!0) || [];
|
|
42
|
+
O("onSubmit", { id: b(S), regionList: t }), a.isConfirmClose && c();
|
|
43
43
|
}
|
|
44
|
-
function M(
|
|
45
|
-
var
|
|
46
|
-
if (!
|
|
47
|
-
const n = (
|
|
48
|
-
let
|
|
49
|
-
return e.level === 1 ?
|
|
44
|
+
function M(t, l, e) {
|
|
45
|
+
var w, x, K, V, R, T, L, B;
|
|
46
|
+
if (!t) return !0;
|
|
47
|
+
const n = (w = l == null ? void 0 : l[a.treeLabelKey]) == null ? void 0 : w.includes(t), s = (V = (K = (x = e == null ? void 0 : e.parent) == null ? void 0 : x.data) == null ? void 0 : K[a.treeLabelKey]) == null ? void 0 : V.includes(t), j = (B = (L = (T = (R = e == null ? void 0 : e.parent) == null ? void 0 : R.parent) == null ? void 0 : T.data) == null ? void 0 : L[a.treeLabelKey]) == null ? void 0 : B.includes(t);
|
|
48
|
+
let g = !1, C = !1, v = !1;
|
|
49
|
+
return e.level === 1 ? g = n : e.level === 2 ? C = n || s : e.level === 3 && (v = n || s || j), g || C || v;
|
|
50
50
|
}
|
|
51
51
|
return N({
|
|
52
52
|
open: z,
|
|
53
|
-
close:
|
|
54
|
-
}), (
|
|
55
|
-
modelValue:
|
|
56
|
-
"onUpdate:modelValue": l[1] || (l[1] = (e) => Q(
|
|
53
|
+
close: c
|
|
54
|
+
}), (t, l) => (P(), J(o(X), {
|
|
55
|
+
modelValue: o(f),
|
|
56
|
+
"onUpdate:modelValue": l[1] || (l[1] = (e) => Q(f) ? f.value = e : null),
|
|
57
57
|
title: "地区选择",
|
|
58
58
|
width: "500px",
|
|
59
59
|
top: "5vh",
|
|
@@ -64,47 +64,47 @@ const ee = { class: "h-70vh overflow-y-scroll" }, le = { class: "mt-20" }, ie =
|
|
|
64
64
|
onClose: A
|
|
65
65
|
}, {
|
|
66
66
|
footer: r(() => [
|
|
67
|
-
|
|
68
|
-
d(
|
|
67
|
+
D("div", le, [
|
|
68
|
+
d(o(_), {
|
|
69
69
|
size: "large",
|
|
70
|
-
onClick:
|
|
70
|
+
onClick: o(c)
|
|
71
71
|
}, {
|
|
72
|
-
default: r(() => l[2] || (l[2] = [
|
|
73
|
-
|
|
74
|
-
])),
|
|
72
|
+
default: r(() => [...l[2] || (l[2] = [
|
|
73
|
+
E("取 消", -1)
|
|
74
|
+
])]),
|
|
75
75
|
_: 1
|
|
76
76
|
}, 8, ["onClick"]),
|
|
77
|
-
d(
|
|
77
|
+
d(o(_), {
|
|
78
78
|
type: "primary",
|
|
79
79
|
size: "large",
|
|
80
80
|
class: "w-100",
|
|
81
|
-
loading:
|
|
81
|
+
loading: o(p),
|
|
82
82
|
onClick: I
|
|
83
83
|
}, {
|
|
84
|
-
default: r(() => l[3] || (l[3] = [
|
|
85
|
-
|
|
86
|
-
])),
|
|
84
|
+
default: r(() => [...l[3] || (l[3] = [
|
|
85
|
+
E("提 交", -1)
|
|
86
|
+
])]),
|
|
87
87
|
_: 1
|
|
88
88
|
}, 8, ["loading"])
|
|
89
89
|
])
|
|
90
90
|
]),
|
|
91
91
|
default: r(() => [
|
|
92
|
-
d(
|
|
93
|
-
modelValue:
|
|
94
|
-
"onUpdate:modelValue": l[0] || (l[0] = (e) =>
|
|
92
|
+
d(o(Y), {
|
|
93
|
+
modelValue: m.value,
|
|
94
|
+
"onUpdate:modelValue": l[0] || (l[0] = (e) => m.value = e),
|
|
95
95
|
placeholder: "输入关键字进行过滤",
|
|
96
96
|
class: "my-10"
|
|
97
97
|
}, null, 8, ["modelValue"]),
|
|
98
|
-
|
|
99
|
-
d(
|
|
98
|
+
D("div", ee, [
|
|
99
|
+
d(o(Z), {
|
|
100
100
|
ref_key: "treeRef",
|
|
101
|
-
ref:
|
|
102
|
-
data:
|
|
103
|
-
"show-checkbox":
|
|
104
|
-
"node-key":
|
|
101
|
+
ref: h,
|
|
102
|
+
data: y.value,
|
|
103
|
+
"show-checkbox": u.showCheckbox,
|
|
104
|
+
"node-key": u.nodeKey,
|
|
105
105
|
props: { label: a.treeLabelKey },
|
|
106
|
-
"default-checked-keys":
|
|
107
|
-
"default-expanded-keys":
|
|
106
|
+
"default-checked-keys": o(i).defaultCheckedKeys,
|
|
107
|
+
"default-expanded-keys": o(i).defaultCheckedKeys,
|
|
108
108
|
"filter-node-method": M
|
|
109
109
|
}, null, 8, ["data", "show-checkbox", "node-key", "props", "default-checked-keys", "default-expanded-keys"])
|
|
110
110
|
])
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./HuiRegionTreeSelect.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import e from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const m = /* @__PURE__ */ e(o, [["__scopeId", "data-v-5ab2a1f0"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
m as default
|
|
7
7
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as m, mergeModels as g, useModel as f, ref as p, onMounted as h, nextTick as R, computed as b, watch as v,
|
|
1
|
+
import { defineComponent as m, mergeModels as g, useModel as f, ref as p, onMounted as h, nextTick as R, computed as b, watch as v, createBlock as T, openBlock as V, unref as D, withCtx as w, createElementVNode as x, toDisplayString as M } from "vue";
|
|
2
2
|
import { ElTreeSelect as C } from "element-plus";
|
|
3
3
|
import { getRegionNameByCodeWithTree as N } from "zjh-web-lib";
|
|
4
4
|
const B = /* @__PURE__ */ m({
|
|
@@ -38,10 +38,10 @@ const B = /* @__PURE__ */ m({
|
|
|
38
38
|
const c = (l, e) => e.fullName.includes(l);
|
|
39
39
|
return s({
|
|
40
40
|
selectedRegions: n
|
|
41
|
-
}), (l, e) => (
|
|
41
|
+
}), (l, e) => (V(), T(D(C), {
|
|
42
42
|
modelValue: n.value,
|
|
43
43
|
"onUpdate:modelValue": e[0] || (e[0] = (t) => n.value = t),
|
|
44
|
-
class: "
|
|
44
|
+
class: "zjhn-tree-select",
|
|
45
45
|
data: o.value,
|
|
46
46
|
"filter-node-method": c,
|
|
47
47
|
filterable: "",
|