@web-utils/component 3.0.2 → 3.0.3
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/address-input/index.mjs +14 -14
- package/chat/index.mjs +39 -40
- package/chunk-file-uploader/index.mjs +35 -594
- package/chunk-file-uploader/style.css +1 -1
- package/chunks/FormTemp.d079292b.mjs +139 -0
- package/chunks/{dataformat.816df805.mjs → dataformat.e655611c.mjs} +6 -6
- package/chunks/detail.d6f8e347.mjs +29 -0
- package/chunks/{dic.3b4ba802.mjs → dic.eaac0823.mjs} +40 -40
- package/chunks/{event.4377230d.mjs → event.10295951.mjs} +2 -2
- package/chunks/form-input-mixin.78a567bc.mjs +24 -0
- package/chunks/form-item-mixin.57cb2019.mjs +140 -0
- package/chunks/{index.d91bd77a.mjs → index.57f871af.mjs} +7 -7
- package/chunks/{init.f0a03127.mjs → init.47f219b4.mjs} +2 -2
- package/chunks/input-number-mixin.41a066be.mjs +60 -0
- package/chunks/{util.7844e2c2.mjs → util.ae730cde.mjs} +21 -21
- package/count-up/index.mjs +17 -14
- package/data-box/index.mjs +18 -19
- package/data-display/index.mjs +17 -18
- package/data-icons/index.mjs +16 -17
- package/data-panel/index.mjs +20 -21
- package/data-pay/index.mjs +15 -16
- package/data-progress/index.mjs +19 -20
- package/data-rotate/index.mjs +35 -36
- package/data-table-picker/index.mjs +23 -25
- package/data-tabs/index.mjs +15 -16
- package/dialog-form/index.mjs +11 -12
- package/dynamic-table/index.mjs +34 -35
- package/easy-popup/index.mjs +56 -29
- package/editable-tree/index.mjs +485 -134
- package/element-dialog/index.mjs +127 -37
- package/empty-view/index.mjs +31 -13
- package/flex-column/index.mjs +1 -1
- package/flex-item/index.mjs +1 -1
- package/flex-row/index.mjs +1 -1
- package/flow/index.mjs +40 -105
- package/flow-designer/index.mjs +555 -615
- package/flow-node/index.mjs +47 -15
- package/flow-viewer/index.mjs +78 -167
- package/form-cascader/index.mjs +24 -24
- package/form-checkbox-group/index.mjs +35 -79
- package/form-date-picker/index.mjs +22 -22
- package/form-holder/index.mjs +1 -1
- package/form-input/index.mjs +86 -28
- package/form-input-email/index.mjs +18 -18
- package/form-input-id-card/index.mjs +27 -27
- package/form-input-number/index.mjs +59 -219
- package/form-input-phone-number/index.mjs +27 -27
- package/form-input-tag/index.mjs +38 -160
- package/form-input-time/index.mjs +16 -16
- package/form-item/index.mjs +146 -15
- package/form-item-group/index.mjs +164 -14
- package/form-radio-group/index.mjs +41 -41
- package/form-select/index.mjs +20 -20
- package/form-switch/index.mjs +19 -19
- package/form-textarea/index.mjs +29 -29
- package/form-view/index.mjs +42 -46
- package/fy-array/index.mjs +2 -2
- package/fy-cascader/index.mjs +15 -15
- package/fy-checkbox/index.mjs +1 -1
- package/fy-code/index.mjs +1 -1
- package/fy-curd/index.mjs +2824 -210
- package/fy-date/index.mjs +59 -17
- package/fy-draggable/index.mjs +1 -1
- package/fy-dynamic/index.mjs +208 -64
- package/fy-empty/index.mjs +29 -12
- package/fy-form/index.mjs +743 -178
- package/fy-form-design/index.mjs +1013 -1540
- package/fy-input/index.mjs +105 -17
- package/fy-input-color/index.mjs +67 -16
- package/fy-input-icon/index.mjs +119 -23
- package/fy-input-map/index.mjs +14 -15
- package/fy-input-number/index.mjs +1 -1
- package/fy-input-table/index.mjs +19 -21
- package/fy-input-tree/index.mjs +3 -3
- package/fy-radio/index.mjs +1 -1
- package/fy-rate/index.mjs +50 -16
- package/fy-select/index.mjs +126 -29
- package/fy-slider/index.mjs +2 -2
- package/fy-switch/index.mjs +1 -1
- package/fy-tabs/index.mjs +51 -15
- package/fy-time/index.mjs +1 -1
- package/fy-title/index.mjs +1 -1
- package/fy-tree/index.mjs +23 -25
- package/fy-u-editor/index.mjs +1 -1
- package/fy-upload/index.mjs +2 -2
- package/highlight-j-s/index.mjs +29 -19
- package/icon-temp/index.mjs +30 -12
- package/iframe-window/index.mjs +18 -19
- package/image-cropper/index.mjs +22 -23
- package/image-preview/index.mjs +1 -1
- package/input-number/index.mjs +173 -63
- package/license/index.mjs +1 -1
- package/loading-view/index.mjs +33 -15
- package/login/index.mjs +1 -1
- package/nav-bar/index.mjs +31 -15
- package/package.json +1 -1
- package/page/index.mjs +20 -12
- package/page-header/index.mjs +34 -13
- package/page-index-top/index.mjs +53 -100
- package/page-skeleton/index.mjs +35 -18
- package/page-skeleton-new/index.mjs +15 -16
- package/pageable-table/index.mjs +228 -86
- package/pageable-view/index.mjs +1 -1
- package/present-view/index.mjs +71 -75
- package/record-video/index.mjs +1 -1
- package/resize-observer/index.mjs +29 -21
- package/search/index.mjs +9 -9
- package/search-popover/index.mjs +1 -1
- package/sign/index.mjs +1 -1
- package/split-pane/index.mjs +45 -40
- package/swiper/index.mjs +13 -14
- package/table-view/index.mjs +97 -631
- package/text-ellipsis/index.mjs +1 -1
- package/tinymce-editor/index.mjs +63 -63
- package/toolbar/index.mjs +208 -15
- package/toolbar-button/index.mjs +56 -30
- package/verify/index.mjs +1 -1
- package/watermark/index.mjs +1 -1
- package/web-types.json +1 -1
- package/x-input-tag/index.mjs +118 -49
- package/chunks/CountUp.f1a19f35.mjs +0 -124
- package/chunks/CountUp.vue_vue_type_template_lang.1f68c96e.mjs +0 -8
- package/chunks/EasyPopup.vue_vue_type_style_index_0_lang.89350bda.mjs +0 -32
- package/chunks/EditableTree.vue_vue_type_style_index_0_lang.5dba9f89.mjs +0 -356
- package/chunks/ElementDialog.d8f3105c.mjs +0 -211
- package/chunks/ElementDialog.vue_vue_type_style_index_0_lang.57cb8e07.mjs +0 -95
- package/chunks/EmptyView.e2430422.mjs +0 -51
- package/chunks/EmptyView.vue_vue_type_style_index_0_lang.ffa84770.mjs +0 -23
- package/chunks/FlowNode.vue_vue_type_template_lang.662bdcfa.mjs +0 -37
- package/chunks/FormInput.vue_vue_type_template_lang.3cb79386.mjs +0 -65
- package/chunks/FormItem.2920ac0c.mjs +0 -45
- package/chunks/FormItem.vue_vue_type_style_index_0_lang.970bd712.mjs +0 -258
- package/chunks/FormItemGroup.41daddb6.mjs +0 -64
- package/chunks/FormItemGroup.vue_vue_type_style_index_0_lang.b588a8ea.mjs +0 -155
- package/chunks/FyCurd.8acd2983.mjs +0 -548
- package/chunks/FyCurd.vue_vue_type_style_index_0_lang.4fbd4b30.mjs +0 -2945
- package/chunks/FyDate.vue_vue_type_style_index_0_lang.429c03e3.mjs +0 -47
- package/chunks/FyDynamic.vue_vue_type_style_index_0_lang.304417ce.mjs +0 -151
- package/chunks/FyEmpty.vue_vue_type_style_index_0_lang.fc8bd24c.mjs +0 -22
- package/chunks/FyForm.0294e494.mjs +0 -439
- package/chunks/FyForm.vue_vue_type_style_index_0_lang.6e64daee.mjs +0 -737
- package/chunks/FyInput.vue_vue_type_template_lang.d2c56811.mjs +0 -93
- package/chunks/FyInputColor.vue_vue_type_template_lang.6eca0ddd.mjs +0 -56
- package/chunks/FyInputIcon.vue_vue_type_style_index_0_lang.11a6a221.mjs +0 -158
- package/chunks/FyRate.vue_vue_type_style_index_0_lang.82174185.mjs +0 -39
- package/chunks/FySelect.vue_vue_type_style_index_0_lang.5f0f3244.mjs +0 -102
- package/chunks/FyTabs.vue_vue_type_template_lang.66af5ac9.mjs +0 -41
- package/chunks/HighlightJS.vue_vue_type_style_index_0_lang.fefeaa3b.mjs +0 -15
- package/chunks/IconTemp.42c48e1f.mjs +0 -32
- package/chunks/IconTemp.vue_vue_type_style_index_0_lang.a0777b31.mjs +0 -23
- package/chunks/InputNumber.vue_vue_type_style_index_0_lang.18046bd3.mjs +0 -172
- package/chunks/LoadingView.vue_vue_type_style_index_0_lang.4c3fff2a.mjs +0 -23
- package/chunks/NavBar.vue_vue_type_style_index_0_lang.e21b57f3.mjs +0 -21
- package/chunks/Page.81f4b8d9.mjs +0 -32
- package/chunks/Page.vue_vue_type_style_index_0_lang.cb4f9bf2.mjs +0 -13
- package/chunks/PageHeader.vue_vue_type_style_index_0_lang.3bcca5aa.mjs +0 -26
- package/chunks/PageSkeleton.vue_vue_type_style_index_0_lang.8621381f.mjs +0 -88
- package/chunks/PageableTable.333cbdc1.mjs +0 -335
- package/chunks/PageableTable.vue_vue_type_style_index_0_lang.fd89fb43.mjs +0 -148
- package/chunks/ResizeObserver.60f728f0.mjs +0 -54
- package/chunks/ResizeObserver.vue_vue_type_style_index_0_lang.7079029c.mjs +0 -13
- package/chunks/TableColumn.8503272e.mjs +0 -106
- package/chunks/Toolbar.5c539dbb.mjs +0 -24
- package/chunks/Toolbar.vue_vue_type_style_index_0_lang.7594243c.mjs +0 -275
- package/chunks/ToolbarButton.vue_vue_type_style_index_0_lang.e2cb14ba.mjs +0 -31
- package/chunks/XInputTag.vue_vue_type_style_index_0_lang.7ad045b3.mjs +0 -74
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
import "@web-utils/component/fy-u-editor/style.css";
|
|
2
|
+
import { b as a, d as u } from "./dataformat.e655611c.mjs";
|
|
3
|
+
import { s as p } from "./slot.4b391395.mjs";
|
|
4
|
+
import { u as s } from "./util.ae730cde.mjs";
|
|
5
|
+
import { n as m } from "./vueComponentNormalizer.446f5dc4.mjs";
|
|
6
|
+
var c = function() {
|
|
7
|
+
var e = this, n = e.$createElement, o = e._self._c || n;
|
|
8
|
+
return o(e.getComponent(e.column.type, e.column.component), e._g(e._b({
|
|
9
|
+
ref: "temp",
|
|
10
|
+
tag: "Component",
|
|
11
|
+
attrs: {
|
|
12
|
+
column: Object.assign(e.column, e.params),
|
|
13
|
+
dic: e.dic,
|
|
14
|
+
disabled: e.column.disabled || e.disabled,
|
|
15
|
+
readonly: e.column.readonly || e.readonly,
|
|
16
|
+
placeholder: e.getPlaceholder(e.column),
|
|
17
|
+
props: e.column.props || e.props,
|
|
18
|
+
"props-http": e.column.propsHttp || e.propsHttp,
|
|
19
|
+
size: e.column.size || e.size,
|
|
20
|
+
"table-data": e.tableData,
|
|
21
|
+
type: e.type || e.column.type,
|
|
22
|
+
"column-slot": e.columnSlot
|
|
23
|
+
},
|
|
24
|
+
nativeOn: {
|
|
25
|
+
keyup: function(t) {
|
|
26
|
+
return !t.type.indexOf("key") && e._k(t.keyCode, "enter", 13, t.key, "Enter") ? null : e.enterChange.apply(null, arguments);
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
scopedSlots: e._u([e._l(e.columnSlot, function(t) {
|
|
30
|
+
return {
|
|
31
|
+
key: t,
|
|
32
|
+
fn: function(l) {
|
|
33
|
+
return [e._t(t, null, null, l)];
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
})], null, !0),
|
|
37
|
+
model: {
|
|
38
|
+
value: e.text,
|
|
39
|
+
callback: function(t) {
|
|
40
|
+
e.text = t;
|
|
41
|
+
},
|
|
42
|
+
expression: "text"
|
|
43
|
+
}
|
|
44
|
+
}, "Component", Object.assign(e.column, e.uploadFun(e.column)), !1), e.event), [e.params.html ? o("span", {
|
|
45
|
+
domProps: {
|
|
46
|
+
innerHTML: e._s(e.params.html)
|
|
47
|
+
}
|
|
48
|
+
}) : e._e()]);
|
|
49
|
+
}, i = [];
|
|
50
|
+
const d = {
|
|
51
|
+
name: "FormTemp",
|
|
52
|
+
components: { FyUEditor: () => import("@web-utils/component/fy-u-editor") },
|
|
53
|
+
mixins: [p],
|
|
54
|
+
props: {
|
|
55
|
+
value: [String, Object, Number, Boolean, Array],
|
|
56
|
+
columnSlot: {
|
|
57
|
+
type: Array,
|
|
58
|
+
default: () => []
|
|
59
|
+
},
|
|
60
|
+
tableData: {
|
|
61
|
+
type: Object,
|
|
62
|
+
default: () => ({})
|
|
63
|
+
},
|
|
64
|
+
enter: {
|
|
65
|
+
type: Boolean,
|
|
66
|
+
default: !1
|
|
67
|
+
},
|
|
68
|
+
type: {
|
|
69
|
+
type: String
|
|
70
|
+
},
|
|
71
|
+
propsHttp: {
|
|
72
|
+
type: Object,
|
|
73
|
+
default: () => ({})
|
|
74
|
+
},
|
|
75
|
+
props: {
|
|
76
|
+
type: Object
|
|
77
|
+
},
|
|
78
|
+
dic: {
|
|
79
|
+
type: Array
|
|
80
|
+
},
|
|
81
|
+
size: {
|
|
82
|
+
type: String
|
|
83
|
+
},
|
|
84
|
+
disabled: {
|
|
85
|
+
type: Boolean
|
|
86
|
+
},
|
|
87
|
+
readonly: {
|
|
88
|
+
type: Boolean
|
|
89
|
+
},
|
|
90
|
+
column: {
|
|
91
|
+
type: Object,
|
|
92
|
+
default: () => ({})
|
|
93
|
+
}
|
|
94
|
+
},
|
|
95
|
+
computed: {
|
|
96
|
+
params() {
|
|
97
|
+
return this.column.params || {};
|
|
98
|
+
},
|
|
99
|
+
event() {
|
|
100
|
+
return this.column.event || {};
|
|
101
|
+
},
|
|
102
|
+
text: {
|
|
103
|
+
get() {
|
|
104
|
+
return this.value;
|
|
105
|
+
},
|
|
106
|
+
set(e) {
|
|
107
|
+
this.$emit("input", e), this.$emit("change", e);
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
},
|
|
111
|
+
methods: {
|
|
112
|
+
uploadFun: s,
|
|
113
|
+
getComponent: a,
|
|
114
|
+
getPlaceholder: u,
|
|
115
|
+
enterChange() {
|
|
116
|
+
typeof this.column.enter == "function" ? this.column.enter({ value: this.text, column: this.column }) : this.enter && this.$emit("enter");
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}, r = {};
|
|
120
|
+
var y = /* @__PURE__ */ m(
|
|
121
|
+
d,
|
|
122
|
+
c,
|
|
123
|
+
i,
|
|
124
|
+
!1,
|
|
125
|
+
f,
|
|
126
|
+
null,
|
|
127
|
+
null,
|
|
128
|
+
null
|
|
129
|
+
);
|
|
130
|
+
function f(e) {
|
|
131
|
+
for (let n in r)
|
|
132
|
+
this[n] = r[n];
|
|
133
|
+
}
|
|
134
|
+
const x = /* @__PURE__ */ function() {
|
|
135
|
+
return y.exports;
|
|
136
|
+
}();
|
|
137
|
+
export {
|
|
138
|
+
x as default
|
|
139
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { isBlank as l } from "@web-utils/core";
|
|
2
|
-
import {
|
|
2
|
+
import { f as E, M as f, A as h, R as T, c as p, e as m, K as A, g as I, S as L, b as S, h as B, I as _ } from "./util.ae730cde.mjs";
|
|
3
3
|
const P = {
|
|
4
4
|
common: {
|
|
5
5
|
condition: "条件",
|
|
@@ -147,12 +147,12 @@ const v = (e, n = 12, t = !1) => {
|
|
|
147
147
|
return l(n) ? L.includes(e.type) ? `${u("tip.select")} ${t}` : `${u("tip.input")} ${t}` : n;
|
|
148
148
|
};
|
|
149
149
|
export {
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
150
|
+
v as a,
|
|
151
|
+
N as b,
|
|
152
|
+
R as c,
|
|
153
|
+
O as d,
|
|
154
154
|
M as f,
|
|
155
|
-
|
|
155
|
+
$ as g,
|
|
156
156
|
C as i,
|
|
157
157
|
u as t
|
|
158
158
|
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { isBlank as Y } from "@web-utils/core";
|
|
2
|
+
import { formatDate as f } from "@web-utils/integrations/dayjs";
|
|
3
|
+
import { p as D, M as I, A as L, b as y, q as _, e as S, k as n, t as $, h as b, v as h } from "./util.ae730cde.mjs";
|
|
4
|
+
const R = (r = {}, t = {}, l = {}, A = []) => {
|
|
5
|
+
let e = r[t.prop];
|
|
6
|
+
const a = t.type, s = t.separator;
|
|
7
|
+
if (t.bind && (e = D(r, t.bind)), Y(e))
|
|
8
|
+
e = "";
|
|
9
|
+
else {
|
|
10
|
+
const g = I.includes(t.type) && t.multiple, T = L.includes(t.type);
|
|
11
|
+
if ((["string", "number"].includes(t.dataType) || g || T) && !Array.isArray(e) && (e = `${e}`.split(s || y), t.dataType === "number" && (e = _(e))), S.includes(a))
|
|
12
|
+
Array.isArray(e) ? e = e.join(s || n) : e = e.split(s || y).join(s || n);
|
|
13
|
+
else if (a === "password")
|
|
14
|
+
e = $(e, "*");
|
|
15
|
+
else if (b.includes(a) && t.format) {
|
|
16
|
+
const d = t.format.replace("dd", "DD").replace("yyyy", "YYYY"), o = f(Date.now(), "YYYY-MM-DD");
|
|
17
|
+
if (a.indexOf("range") !== -1) {
|
|
18
|
+
let i = e[0] || "", p = e[1] || "";
|
|
19
|
+
a === "timerange" && i.length <= 8 && p.length < 8 && (i = `${o} ${i}`, p = `${o} ${p}`), e = [f(i, d), f(p, d)].join(t.separator || "~");
|
|
20
|
+
} else
|
|
21
|
+
a === "time" && e.length <= 8 && (e = `${o} ${e}`), e = f(e, d);
|
|
22
|
+
}
|
|
23
|
+
e = h(A, e, t.props || l.props);
|
|
24
|
+
}
|
|
25
|
+
return t.formatter && typeof t.formatter == "function" && (e = t.formatter(r, r[t.prop], e, t)), e;
|
|
26
|
+
};
|
|
27
|
+
export {
|
|
28
|
+
R as d
|
|
29
|
+
};
|
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
import { isBlank as P } from "@web-utils/core";
|
|
2
|
-
import {
|
|
3
|
-
const F = (n,
|
|
2
|
+
import { m as w, n as E } from "./util.ae730cde.mjs";
|
|
3
|
+
const F = (n, t = []) => new Promise((i) => {
|
|
4
4
|
const c = [], s = [], a = {};
|
|
5
|
-
n.forEach((
|
|
6
|
-
|
|
7
|
-
}),
|
|
5
|
+
n.forEach((r) => {
|
|
6
|
+
r.parentProp && c.push(r);
|
|
7
|
+
}), t.forEach((r, e) => {
|
|
8
8
|
c.forEach((o) => {
|
|
9
9
|
o.hide !== !0 && o.dicFlag !== !1 && s.push(
|
|
10
10
|
new Promise((d) => {
|
|
11
|
-
P(
|
|
11
|
+
P(r[o.parentProp]) ? d({
|
|
12
12
|
prop: o.prop,
|
|
13
13
|
data: [],
|
|
14
14
|
index: e
|
|
15
15
|
}) : o.dicUrl && D({
|
|
16
|
-
url: `${o.dicUrl.replace("{{key}}",
|
|
16
|
+
url: `${o.dicUrl.replace("{{key}}", r[o.parentProp])}`,
|
|
17
17
|
props: o.props,
|
|
18
18
|
method: o.dicMethod,
|
|
19
19
|
headers: o.dicHeaders,
|
|
20
20
|
formatter: o.dicFormatter,
|
|
21
21
|
query: o.dicQuery,
|
|
22
|
-
form:
|
|
22
|
+
form: r
|
|
23
23
|
}).then((u) => {
|
|
24
24
|
d({
|
|
25
25
|
prop: o.prop,
|
|
@@ -30,36 +30,36 @@ const F = (n, r = []) => new Promise((i) => {
|
|
|
30
30
|
})
|
|
31
31
|
);
|
|
32
32
|
});
|
|
33
|
-
}), Promise.all(s).then((
|
|
34
|
-
|
|
33
|
+
}), Promise.all(s).then((r) => {
|
|
34
|
+
r.forEach((e) => {
|
|
35
35
|
P(a[e.index]) && (a[e.index] = {}), a[e.index][e.prop] = e.data;
|
|
36
36
|
}), i(a);
|
|
37
37
|
});
|
|
38
38
|
}), U = (n) => {
|
|
39
|
-
let
|
|
39
|
+
let t = [];
|
|
40
40
|
return new Promise((i, c) => {
|
|
41
|
-
|
|
41
|
+
t = k(n).ajaxdic, x(t).then((a) => {
|
|
42
42
|
i(a);
|
|
43
43
|
}).catch((a) => {
|
|
44
44
|
c(a);
|
|
45
45
|
});
|
|
46
46
|
});
|
|
47
|
-
},
|
|
48
|
-
const
|
|
47
|
+
}, K = (n) => {
|
|
48
|
+
const t = {}, i = n.dicData || {};
|
|
49
49
|
return n.column.forEach((c) => {
|
|
50
|
-
c.dicData && (
|
|
51
|
-
}), Object.assign(i,
|
|
50
|
+
c.dicData && (t[c.prop] = w(c.dicData, c.props, c.dataType));
|
|
51
|
+
}), Object.assign(i, t);
|
|
52
52
|
};
|
|
53
53
|
function k(n) {
|
|
54
|
-
const
|
|
54
|
+
const t = n.column || [], i = [], c = {};
|
|
55
55
|
let s = [];
|
|
56
|
-
return
|
|
57
|
-
const
|
|
58
|
-
s = s.concat(a.cascader || []), Array.isArray(
|
|
56
|
+
return t.forEach((a) => {
|
|
57
|
+
const r = a.dicData, e = a.dicUrl, o = a.prop, d = a.parentProp;
|
|
58
|
+
s = s.concat(a.cascader || []), Array.isArray(r) && (c[o] = r), !(a.dicFlag === !1 || a.lazy === !0 || s.includes(o)) && e && !d && i.push({
|
|
59
59
|
url: e,
|
|
60
60
|
name: o,
|
|
61
61
|
method: a.dicMethod,
|
|
62
|
-
headers:
|
|
62
|
+
headers: t.dicHeaders,
|
|
63
63
|
formatter: a.dicFormatter,
|
|
64
64
|
props: a.props,
|
|
65
65
|
dataType: a.dataType,
|
|
@@ -72,7 +72,7 @@ function k(n) {
|
|
|
72
72
|
};
|
|
73
73
|
}
|
|
74
74
|
function x(n) {
|
|
75
|
-
const
|
|
75
|
+
const t = {}, i = [];
|
|
76
76
|
return new Promise((c) => {
|
|
77
77
|
n.forEach((s) => {
|
|
78
78
|
i.push(
|
|
@@ -81,41 +81,41 @@ function x(n) {
|
|
|
81
81
|
Object.assign(s, {
|
|
82
82
|
url: `${s.url.replace("{{key}}", "")}`
|
|
83
83
|
})
|
|
84
|
-
).then((
|
|
85
|
-
|
|
84
|
+
).then((r) => {
|
|
85
|
+
r = w(r, s.props, s.dataType), a(r);
|
|
86
86
|
}).catch(() => {
|
|
87
87
|
a([]);
|
|
88
88
|
});
|
|
89
89
|
})
|
|
90
90
|
);
|
|
91
91
|
}), Promise.all(i).then((s) => {
|
|
92
|
-
n.forEach((a,
|
|
93
|
-
|
|
94
|
-
}), c(
|
|
92
|
+
n.forEach((a, r) => {
|
|
93
|
+
t[a.name] = s[r];
|
|
94
|
+
}), c(t);
|
|
95
95
|
});
|
|
96
96
|
});
|
|
97
97
|
}
|
|
98
98
|
const D = (n) => {
|
|
99
|
-
let { url:
|
|
100
|
-
d && (
|
|
99
|
+
let { url: t, query: i, method: c, resKey: s, props: a, formatter: r, headers: e = {}, value: o = "", column: d, form: u = {} } = n;
|
|
100
|
+
d && (t = d.dicUrl, c = d.dicMethod, e = d.headers || {}, i = d.dicQuery || {}, r = d.dicFormatter, a = d.props);
|
|
101
101
|
const g = "key";
|
|
102
|
-
|
|
103
|
-
let
|
|
104
|
-
const
|
|
105
|
-
return
|
|
102
|
+
t = t || "";
|
|
103
|
+
let m;
|
|
104
|
+
const y = {};
|
|
105
|
+
return m = t.match(/[^{}]+(?=})/g) || [], m.forEach((p) => {
|
|
106
106
|
const f = `{{${p}}}`, h = u[p];
|
|
107
|
-
p === g ?
|
|
108
|
-
}), c === "post" && (
|
|
107
|
+
p === g ? t = t.replace(f, o) : t = t.replace(f, h);
|
|
108
|
+
}), c === "post" && (m = Object.keys(i), m.forEach((p) => {
|
|
109
109
|
const f = i[p];
|
|
110
|
-
typeof f == "string" && f.match(/\{{|}}/g) ?
|
|
110
|
+
typeof f == "string" && f.match(/\{{|}}/g) ? y[p] = u[f.replace(/\{{|}}/g, "")] : y[p] = f;
|
|
111
111
|
})), a && (s = (a || {}).res || s), new Promise((p) => {
|
|
112
112
|
const f = (h) => {
|
|
113
113
|
let l = [];
|
|
114
|
-
typeof
|
|
114
|
+
typeof r == "function" ? l = r(h.data) : l = E(h.data, s), p(l);
|
|
115
115
|
};
|
|
116
|
-
c === "post" ? window.axios.post(
|
|
116
|
+
c === "post" ? window.axios.post(t, y, { headers: e }).then(function(h) {
|
|
117
117
|
f(h);
|
|
118
|
-
}).catch(() => [p([])]) : window.axios.get(
|
|
118
|
+
}).catch(() => [p([])]) : window.axios.get(t, { params: i, headers: e }).then(function(h) {
|
|
119
119
|
f(h);
|
|
120
120
|
}).catch(() => [p([])]);
|
|
121
121
|
});
|
|
@@ -123,6 +123,6 @@ const D = (n) => {
|
|
|
123
123
|
export {
|
|
124
124
|
U as a,
|
|
125
125
|
F as b,
|
|
126
|
-
|
|
126
|
+
K as l,
|
|
127
127
|
D as s
|
|
128
128
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { D as r, a as i, b as a } from "./util.ae730cde.mjs";
|
|
2
2
|
import { s as l } from "./slot.4b391395.mjs";
|
|
3
3
|
import { isBlank as s } from "@web-utils/core";
|
|
4
|
-
import { i as p } from "./dataformat.
|
|
4
|
+
import { i as p } from "./dataformat.e655611c.mjs";
|
|
5
5
|
const f = {
|
|
6
6
|
mixins: [l],
|
|
7
7
|
data() {
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { f as e } from "./form-item-mixin.57cb2019.mjs";
|
|
2
|
+
import { d as r } from "./index.57f871af.mjs";
|
|
3
|
+
const o = {
|
|
4
|
+
mixins: [e],
|
|
5
|
+
props: {
|
|
6
|
+
value: [Boolean, String, Array, Number, Object, Date],
|
|
7
|
+
readonly: Boolean,
|
|
8
|
+
disabled: Boolean
|
|
9
|
+
},
|
|
10
|
+
computed: {
|
|
11
|
+
computePlaceholder() {
|
|
12
|
+
return this.placeholder === !0 ? this.message : this.placeholder;
|
|
13
|
+
},
|
|
14
|
+
listeners() {
|
|
15
|
+
return r(this.$listeners, "input", !1);
|
|
16
|
+
},
|
|
17
|
+
inputDisabled() {
|
|
18
|
+
return this.disabled;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
export {
|
|
23
|
+
o as f
|
|
24
|
+
};
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
var m = Object.defineProperty;
|
|
2
|
+
var l = Object.getOwnPropertySymbols;
|
|
3
|
+
var f = Object.prototype.hasOwnProperty, c = Object.prototype.propertyIsEnumerable;
|
|
4
|
+
var i = (e, t, r) => t in e ? m(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, s = (e, t) => {
|
|
5
|
+
for (var r in t || (t = {}))
|
|
6
|
+
f.call(t, r) && i(e, r, t[r]);
|
|
7
|
+
if (l)
|
|
8
|
+
for (var r of l(t))
|
|
9
|
+
c.call(t, r) && i(e, r, t[r]);
|
|
10
|
+
return e;
|
|
11
|
+
};
|
|
12
|
+
import { d as o } from "./index.57f871af.mjs";
|
|
13
|
+
import n from "element-ui/lib/col";
|
|
14
|
+
import u from "element-ui/lib/form-item";
|
|
15
|
+
const d = ["span"], a = [...Object.keys(n.props || n.default.props)], h = a.filter((e) => !d.includes(e)), g = ["label", "prop", "rules", "labelWidth", "required"], p = [...Object.keys(u.props || u.default.props)], b = p.filter((e) => !g.includes(e)), y = [
|
|
16
|
+
"wrapCol",
|
|
17
|
+
"wrapFormItem",
|
|
18
|
+
"unwrap",
|
|
19
|
+
"prefixConfig",
|
|
20
|
+
"block",
|
|
21
|
+
"placeholder",
|
|
22
|
+
"prefixPick",
|
|
23
|
+
"half",
|
|
24
|
+
...a,
|
|
25
|
+
...p
|
|
26
|
+
], C = {
|
|
27
|
+
inject: {
|
|
28
|
+
elForm: {
|
|
29
|
+
default: {}
|
|
30
|
+
},
|
|
31
|
+
formItemGroup: {
|
|
32
|
+
default: {}
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
props: {
|
|
36
|
+
disabled: Boolean,
|
|
37
|
+
wrapCol: {
|
|
38
|
+
type: Boolean,
|
|
39
|
+
default: !0
|
|
40
|
+
},
|
|
41
|
+
wrapFormItem: {
|
|
42
|
+
type: Boolean,
|
|
43
|
+
default: !0
|
|
44
|
+
},
|
|
45
|
+
unwrap: Boolean,
|
|
46
|
+
half: Boolean,
|
|
47
|
+
prefixConfig: Boolean,
|
|
48
|
+
block: Boolean,
|
|
49
|
+
placeholder: {
|
|
50
|
+
type: [Boolean, String],
|
|
51
|
+
default: !0
|
|
52
|
+
},
|
|
53
|
+
formItemClass: String,
|
|
54
|
+
prefixPick: Boolean,
|
|
55
|
+
// el-form-item
|
|
56
|
+
label: String,
|
|
57
|
+
labelWidth: String,
|
|
58
|
+
prop: String,
|
|
59
|
+
required: Boolean,
|
|
60
|
+
rules: [Object, Array],
|
|
61
|
+
error: String,
|
|
62
|
+
validateStatus: String,
|
|
63
|
+
for: String,
|
|
64
|
+
inlineMessage: {
|
|
65
|
+
type: [String, Boolean],
|
|
66
|
+
default: ""
|
|
67
|
+
},
|
|
68
|
+
showMessage: {
|
|
69
|
+
type: Boolean,
|
|
70
|
+
default: !0
|
|
71
|
+
},
|
|
72
|
+
size: String,
|
|
73
|
+
// el-col
|
|
74
|
+
span: {
|
|
75
|
+
type: Number,
|
|
76
|
+
default: 12
|
|
77
|
+
},
|
|
78
|
+
tag: {
|
|
79
|
+
type: String,
|
|
80
|
+
default: "div"
|
|
81
|
+
},
|
|
82
|
+
offset: Number,
|
|
83
|
+
pull: Number,
|
|
84
|
+
push: Number,
|
|
85
|
+
xs: [Number, Object],
|
|
86
|
+
sm: [Number, Object],
|
|
87
|
+
md: [Number, Object],
|
|
88
|
+
lg: [Number, Object],
|
|
89
|
+
xl: [Number, Object]
|
|
90
|
+
},
|
|
91
|
+
computed: {
|
|
92
|
+
prefix() {
|
|
93
|
+
return this.prefixConfig ? "请配置" : this.prefixPick ? "请选择" : "请输入";
|
|
94
|
+
},
|
|
95
|
+
message() {
|
|
96
|
+
var e;
|
|
97
|
+
return `${this.prefix}${((e = this.label) == null ? void 0 : e.replace(":", "")) || ""}`;
|
|
98
|
+
},
|
|
99
|
+
computeRules() {
|
|
100
|
+
const e = [...this.rules || []];
|
|
101
|
+
if (this.required) {
|
|
102
|
+
const t = e.find((r) => r.required);
|
|
103
|
+
t ? t.ref ? t.label = t.label || this.label : t.message = e.message || this.message : e.unshift(this.getRequireRule());
|
|
104
|
+
}
|
|
105
|
+
return e.concat(this.getRules());
|
|
106
|
+
},
|
|
107
|
+
computeSpan() {
|
|
108
|
+
return this.block ? 24 : this.span;
|
|
109
|
+
},
|
|
110
|
+
formItemProps() {
|
|
111
|
+
return o(s(s({}, this.$props), this.$attrs), y);
|
|
112
|
+
},
|
|
113
|
+
elFormItemProps() {
|
|
114
|
+
return o(s(s({}, this.$props), this.$attrs), b);
|
|
115
|
+
},
|
|
116
|
+
elColProps() {
|
|
117
|
+
return o(s(s({}, this.$props), this.$attrs), h);
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
watch: {
|
|
121
|
+
computeRules() {
|
|
122
|
+
var e, t;
|
|
123
|
+
(t = (e = this.elForm) == null ? void 0 : e.clearValidate) == null || t.call(e, this.prop);
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
methods: {
|
|
127
|
+
getRules() {
|
|
128
|
+
return [];
|
|
129
|
+
},
|
|
130
|
+
getRequireRule() {
|
|
131
|
+
return {
|
|
132
|
+
required: !0,
|
|
133
|
+
message: this.message
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
};
|
|
138
|
+
export {
|
|
139
|
+
C as f
|
|
140
|
+
};
|
|
@@ -170,15 +170,15 @@ const I = (e, r) => {
|
|
|
170
170
|
});
|
|
171
171
|
}, M = (e, r) => m(e) ? c(e(r), r) : a(e) ? c(e, r) : null;
|
|
172
172
|
export {
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
173
|
+
S as a,
|
|
174
|
+
F as b,
|
|
175
|
+
z as c,
|
|
176
|
+
s as d,
|
|
177
|
+
I as e,
|
|
178
178
|
K as f,
|
|
179
179
|
T as g,
|
|
180
|
-
|
|
181
|
-
|
|
180
|
+
V as h,
|
|
181
|
+
R as i,
|
|
182
182
|
E as j,
|
|
183
183
|
M as k,
|
|
184
184
|
A as n
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { s as a, l as n, a as h, b as r } from "./dic.
|
|
2
|
-
import { d,
|
|
1
|
+
import { s as a, l as n, a as h, b as r } from "./dic.eaac0823.mjs";
|
|
2
|
+
import { d, a as c } from "./util.ae730cde.mjs";
|
|
3
3
|
import { s as l } from "./slot.4b391395.mjs";
|
|
4
4
|
import { isBlank as s } from "@web-utils/core";
|
|
5
5
|
const f = {
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
const t = {
|
|
2
|
+
props: {
|
|
3
|
+
suffixIcon: {
|
|
4
|
+
type: String
|
|
5
|
+
},
|
|
6
|
+
prefixIcon: {
|
|
7
|
+
type: String
|
|
8
|
+
},
|
|
9
|
+
step: {
|
|
10
|
+
type: Number,
|
|
11
|
+
default: 1
|
|
12
|
+
},
|
|
13
|
+
stepStrictly: {
|
|
14
|
+
type: Boolean,
|
|
15
|
+
default: !1
|
|
16
|
+
},
|
|
17
|
+
max: {
|
|
18
|
+
type: Number,
|
|
19
|
+
default: 1 / 0
|
|
20
|
+
},
|
|
21
|
+
min: {
|
|
22
|
+
type: Number,
|
|
23
|
+
default: -1 / 0
|
|
24
|
+
},
|
|
25
|
+
value: {
|
|
26
|
+
type: [Number, String]
|
|
27
|
+
},
|
|
28
|
+
disabled: Boolean,
|
|
29
|
+
size: {
|
|
30
|
+
type: String
|
|
31
|
+
},
|
|
32
|
+
controls: {
|
|
33
|
+
type: Boolean,
|
|
34
|
+
default: !0
|
|
35
|
+
},
|
|
36
|
+
controlsPosition: {
|
|
37
|
+
type: String,
|
|
38
|
+
default: ""
|
|
39
|
+
},
|
|
40
|
+
name: {
|
|
41
|
+
type: String
|
|
42
|
+
},
|
|
43
|
+
label: {
|
|
44
|
+
type: String
|
|
45
|
+
},
|
|
46
|
+
placeholder: {
|
|
47
|
+
type: String
|
|
48
|
+
},
|
|
49
|
+
precision: {
|
|
50
|
+
type: Number,
|
|
51
|
+
default: void 0,
|
|
52
|
+
validator(e) {
|
|
53
|
+
return e >= 0 && e === parseInt(e, 10);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
export {
|
|
59
|
+
t as i
|
|
60
|
+
};
|
|
@@ -230,36 +230,36 @@ export {
|
|
|
230
230
|
V as A,
|
|
231
231
|
q as B,
|
|
232
232
|
W as C,
|
|
233
|
-
|
|
233
|
+
M as D,
|
|
234
234
|
R as I,
|
|
235
235
|
D as K,
|
|
236
236
|
k as M,
|
|
237
237
|
K as R,
|
|
238
238
|
F as S,
|
|
239
|
-
|
|
239
|
+
f as a,
|
|
240
240
|
B as b,
|
|
241
|
-
|
|
241
|
+
O as c,
|
|
242
242
|
u as d,
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
243
|
+
L as e,
|
|
244
|
+
z as f,
|
|
245
|
+
H as g,
|
|
246
|
+
I as h,
|
|
247
|
+
G as i,
|
|
248
|
+
ee as j,
|
|
249
|
+
T as k,
|
|
250
|
+
re as l,
|
|
251
|
+
_ as m,
|
|
252
|
+
te as n,
|
|
253
253
|
oe as o,
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
254
|
+
v as p,
|
|
255
|
+
Y as q,
|
|
256
|
+
Q as r,
|
|
257
257
|
X as s,
|
|
258
|
-
|
|
258
|
+
ne as t,
|
|
259
259
|
ie as u,
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
260
|
+
Z as v,
|
|
261
|
+
U as w,
|
|
262
|
+
J as x,
|
|
263
|
+
se as y,
|
|
264
264
|
x as z
|
|
265
265
|
};
|