halo-pc 1.0.39 → 1.0.40
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/{Article-DZlstqWL.js → Article-CqtkXVmQ.js} +37 -36
- package/dist/{ArticleFooter-BkduiKh8.js → ArticleFooter-DeJdTtZD.js} +12 -13
- package/dist/{Autocomplete-DMKnFezN.js → Autocomplete-0fxB2_FC.js} +1 -1
- package/dist/Autocomplete-BfhYwZ5G.js +49 -0
- package/dist/{Autocomplete-0Yf6lJQ7.js → Autocomplete-LQiKcvz1.js} +10 -11
- package/dist/{CSharp-q8eOBm4y.js → CSharp-BIFRQLaK.js} +1 -1
- package/dist/{Calender-CseGNCuW.js → Calender-DPNTn-S4.js} +2 -2
- package/dist/Callback-Ci5KrWOC.js +20 -0
- package/dist/Cascader-CnOEgPDf.js +41 -0
- package/dist/{Cascader-BG5ev35M.js → Cascader-Vhc81TDV.js} +17 -18
- package/dist/{Checkbox-CsCA6iQb.js → Checkbox-CIim5NiB.js} +1 -1
- package/dist/{Checkbox-dw8RNAGt.js → Checkbox-D9Sp6ZGQ.js} +11 -12
- package/dist/Code-BEjqqeFZ.js +54 -0
- package/dist/Code-BSrEPuXk.js +4 -0
- package/dist/Code-Dp1-k8sW.js +36 -0
- package/dist/{Code-BE8YLGaE.js → Code-yDKaH1uF.js} +10 -8
- package/dist/Code.vue_vue_type_style_index_0_lang-CmkomJXY.js +59 -0
- package/dist/Column-B0ViSver.js +69 -0
- package/dist/{Comment-kTmfTlbF.js → Comment-tU2wBvGO.js} +22 -26
- package/dist/{Compare-DlyQBCat.js → Compare-D7Gz-lE9.js} +10 -11
- package/dist/{Compare-DVWaiCUC.js → Compare-DqvGyQWA.js} +8 -9
- package/dist/Copy-Dm1LH9qB.js +43 -0
- package/dist/Custom-CLKAPWEo.js +49 -0
- package/dist/{DataExport-Um1wXyRe.js → DataExport-BDftKI0U.js} +1 -1
- package/dist/{DataExport.vue_vue_type_script_setup_true_lang-2YoqwEmA.js → DataExport.vue_vue_type_script_setup_true_lang-Dzy9UC11.js} +27 -28
- package/dist/{DataImport-CPMLup4P.js → DataImport-CRYaaQfA.js} +1 -1
- package/dist/{DataImport.vue_vue_type_script_setup_true_lang-DsCp0vWo.js → DataImport.vue_vue_type_script_setup_true_lang-D7UdCnBM.js} +30 -31
- package/dist/{Date-BhZ8ltgp.js → Date-DPPiYLWw.js} +7 -8
- package/dist/{Date-Cj9lCW_Y.js → Date-Dlh1_S7p.js} +1 -1
- package/dist/{DateRange-Bw_Oyawz.js → DateRange-BgF_T3ls.js} +5 -6
- package/dist/{DateTime-Cv-SRE88.js → DateTime-CNjPeK9t.js} +1 -1
- package/dist/{DateTime-BU6JaBPk.js → DateTime-DP-VfmtN.js} +7 -8
- package/dist/{DateTimeRange-B4Ah6LQY.js → DateTimeRange-DbEpW4nB.js} +9 -10
- package/dist/{Daterange-CSZe4XGO.js → Daterange-DHVjhrK9.js} +4 -5
- package/dist/{Decimal-DSDuwW9Z.js → Decimal-BDEWVSsK.js} +1 -1
- package/dist/{Delete-CjPgg-5G.js → Delete-Bl0GmthL.js} +19 -20
- package/dist/{Detail-gj--ICe8.js → Detail-BozyhOTt.js} +10 -11
- package/dist/{Dictionary-Ck_02mWa.js → Dictionary-CJwZPQz6.js} +9 -15
- package/dist/{Email-BSQbDvh1.js → Email-D5X1SzuJ.js} +11 -12
- package/dist/{File-FW4usX43.js → File-DixK0K7p.js} +44 -43
- package/dist/Image-BrelhCGo.js +9 -0
- package/dist/Index-BeM6hKX9.js +4 -0
- package/dist/Index-BkfLyqpm.js +173 -0
- package/dist/{Index-MUgqP8jJ.js → Index-D2FOeoNQ.js} +1 -1
- package/dist/Index-D8UVsXwf.js +4 -0
- package/dist/{Index-Dq5Vp-ts.js → Index-DbXgnBz6.js} +15 -16
- package/dist/Index-FL-dxfFB.js +4 -0
- package/dist/Index-fWOqfFkG.js +4 -0
- package/dist/{Index-BibWDRoP.js → Index-j15c7lwJ.js} +1 -1
- package/dist/Index.vue_vue_type_script_setup_true_lang-ByxBNAdg.js +80 -0
- package/dist/{Index.vue_vue_type_script_setup_true_lang-CiBvC9Cu.js → Index.vue_vue_type_script_setup_true_lang-DT7eOyjs.js} +21 -22
- package/dist/{Install-Cpp3BDCS.js → Install-WR3b4IfI.js} +13 -14
- package/dist/{Int-Ck1SvK7R.js → Int-CWsDtoxE.js} +9 -10
- package/dist/{Int-DcQsipaO.js → Int-GGWiUqO2.js} +13 -14
- package/dist/List-kRCsHp6d.js +71 -0
- package/dist/Maintaince-BG8MUi3A.js +14 -0
- package/dist/{Markdown-BEUz4VZ7.js → Markdown-nVfQs7kc.js} +1 -1
- package/dist/Month-B1icZmL4.js +37 -0
- package/dist/{Month-DmUiyF1G.js → Month-CxKMP4kO.js} +1 -1
- package/dist/{Month-DJGGGrZr.js → Month-DnYlAi7k.js} +10 -11
- package/dist/{Normal-ACcTHsXb.js → Normal-RcqEyIFN.js} +47 -46
- package/dist/Paging-DrdGzxeP.js +94 -0
- package/dist/{PagingHeader-DDkmqv98.js → PagingHeader-C8UpM9Kj.js} +18 -17
- package/dist/{PagingRow-B4Nfa2Vk.js → PagingRow-oQWCofO4.js} +13 -14
- package/dist/{Racebar-LfnPLNOY.js → Racebar-CvoF2ySW.js} +32 -36
- package/dist/{Radio-DcEZI4m7.js → Radio-DhjfkC14.js} +1 -1
- package/dist/{Register-B4x_zgyH.js → Register-B0Vx60wY.js} +55 -56
- package/dist/RichText-4wrLw9cy.js +41 -0
- package/dist/{SearchForm-DU5QLTbe.js → SearchForm-BHVnQaSL.js} +1 -1
- package/dist/{SearchForm.vue_vue_type_style_index_0_lang-BHZrYG6_.js → SearchForm.vue_vue_type_style_index_0_lang-ByICIL6w.js} +50 -51
- package/dist/SearchHeader-C9yovXli.js +4 -0
- package/dist/SearchHeader.vue_vue_type_style_index_0_lang-CHAg97-Y.js +60 -0
- package/dist/{Select-C3gUeHmu.js → Select-BDoCqD3I.js} +10 -11
- package/dist/{Select-CMxubJIV.js → Select-CX4i5KPQ.js} +1 -1
- package/dist/{Select-DrDDVJtz.js → Select-vgwpegBi.js} +20 -21
- package/dist/{Single-De-YyuVk.js → Single-C3629BdC.js} +127 -128
- package/dist/{Statistic-CTxHNeof.js → Statistic-Dxa-CZ8G.js} +10 -8
- package/dist/{Statistic-SvjQ7uGI.js → Statistic-WPezAlUn.js} +34 -33
- package/dist/{Stock-C2b9p3-N.js → Stock-BD5Acf8y.js} +8 -6
- package/dist/{Stock-XZkBSQw1.js → Stock-EPM3j2f_.js} +1 -1
- package/dist/{Stock.vue_vue_type_style_index_0_lang-DwxyyM7p.js → Stock.vue_vue_type_style_index_0_lang-D5RR2MRP.js} +22 -21
- package/dist/{Switch-PJT-5dDt.js → Switch-B0XN4K-9.js} +1 -1
- package/dist/{Table-Dy1H2IHN.js → Table-BklK1hSh.js} +142 -136
- package/dist/{Table-CkoZ8OjZ.js → Table-JFdOXuME.js} +61 -60
- package/dist/Text-CNtHdodK.js +4 -0
- package/dist/{Text-CytgR_l_.js → Text-DrJkdxZF.js} +12 -13
- package/dist/Text-KAuEjP7I.js +48 -0
- package/dist/Text.vue_vue_type_style_index_0_lang-BJIbv4kF.js +53 -0
- package/dist/{TextLink-DINdFWzs.js → TextLink-BnijIoEJ.js} +8 -9
- package/dist/{Textarea-DakZXfN6.js → Textarea-3SWLqQvO.js} +1 -1
- package/dist/{Time-Bn1Av2wo.js → Time-C3qlNZkJ.js} +9 -10
- package/dist/{Timeline-B32cUvwI.js → Timeline-B6hUIYhL.js} +11 -15
- package/dist/{Tree-BGfHm4k_.js → Tree-DBvFF4Rj.js} +77 -76
- package/dist/{Tree-BItAXuSC.js → Tree-JexLPBXX.js} +38 -42
- package/dist/{TreeNode-DmiM_a2n.js → TreeNode-BOWB2WN9.js} +9 -10
- package/dist/{Update-DSTmaeT8.js → Update-CDLYYwgj.js} +5 -6
- package/dist/{UpdateChild-BgBJJwT3.js → UpdateChild-DUG7pAuO.js} +19 -20
- package/dist/{Upload-DMqlcxCt.js → Upload-B2hbxDsT.js} +46 -47
- package/dist/Upload-mlk6Y4Po.js +65 -0
- package/dist/{Year-DckBNPK_.js → Year-BRsJ7b1J.js} +1 -1
- package/dist/{Year-Cv92J5pF.js → Year-BUF60NmB.js} +7 -8
- package/dist/assets/{clipboard-DjQPoCBJ.js → clipboard-ClN4QccS.js} +1 -3
- package/dist/main-DymfKjqO.js +16480 -0
- package/dist/main.js +144 -142
- package/dist/style.css +1 -1
- package/esm/coms/commons/Table.vue.d.ts +1 -1
- package/esm/coms/drivers/Index.vue.d.ts +2 -2
- package/esm/coms/globals/Menu.vue.d.ts +1 -1
- package/esm/coms/globals/MenuItem.vue.d.ts +1 -1
- package/esm/coms/headers/@types/HeaderProps.d.ts +1 -1
- package/esm/coms/headers/Index.vue.d.ts +1 -1
- package/esm/coms/layouts/Index.vue.d.ts +3 -3
- package/esm/coms/layouts/Side.vue.d.ts +2 -2
- package/esm/coms/layouts/Top.vue.d.ts +1 -1
- package/esm/coms/lists/Racebar.vue.d.ts +1 -1
- package/esm/coms/lists/Statistic.vue.d.ts +1 -1
- package/esm/coms/lists/Tree.vue.d.ts +3 -3
- package/esm/coms/pages/@types/SchemaProps.d.ts +2 -1
- package/esm/coms/pages/Column.vue.d.ts +1 -1
- package/esm/coms/pages/Custom.vue.d.ts +6 -6
- package/esm/coms/pages/List.vue.d.ts +5 -3
- package/esm/coms/pages/Paging.vue.d.ts +5 -3
- package/esm/coms/pages/Single.vue.d.ts +3 -3
- package/esm/coms/pagings/@types/SearchHeaderProps.d.ts +9 -0
- package/esm/coms/pagings/@types/index.d.ts +2 -2
- package/esm/coms/pagings/Article.vue.d.ts +2 -2
- package/esm/coms/pagings/Index.vue.d.ts +4 -2
- package/esm/coms/pagings/SearchForm.vue.d.ts +1 -1
- package/esm/coms/pagings/SearchHeader.vue.d.ts +19 -0
- package/esm/coms/pagings/Table.vue.d.ts +4 -2
- package/esm/coms/partials/@types/PagingHeaderProps.d.ts +2 -1
- package/esm/coms/singles/Index.vue.d.ts +1 -1
- package/esm/coms/singles/Normal.vue.d.ts +1 -1
- package/esm/coms/singles/Table.vue.d.ts +1 -1
- package/esm/coms/singles/Tree.vue.d.ts +1 -1
- package/package.json +6 -6
- package/dist/Autocomplete-bc-9LfGa.js +0 -50
- package/dist/Callback-D_dFJlfv.js +0 -21
- package/dist/Cascader-Dzeoz7ss.js +0 -47
- package/dist/Code-BRe68AIa.js +0 -42
- package/dist/Code-C5QfTMNw.js +0 -60
- package/dist/Code-_XoN6vQE.js +0 -4
- package/dist/Code.vue_vue_type_style_index_0_lang-D2hJ7lYF.js +0 -63
- package/dist/Column-C-NHhT2v.js +0 -75
- package/dist/Copy-DQFJy3uX.js +0 -44
- package/dist/Custom-D5HoD0nQ.js +0 -59
- package/dist/Image-DiAw_6jM.js +0 -9
- package/dist/Index-B_5hshjJ.js +0 -4
- package/dist/Index-BtlD6ocN.js +0 -4
- package/dist/Index-C3f38zw0.js +0 -4
- package/dist/Index-CB_TnEaw.js +0 -4
- package/dist/Index-hgTZyQps.js +0 -174
- package/dist/Index.vue_vue_type_script_setup_true_lang-BzPCaYCg.js +0 -82
- package/dist/List-hWB41wF_.js +0 -72
- package/dist/Maintaince-l-Tdveur.js +0 -20
- package/dist/Month-DkafiRHq.js +0 -38
- package/dist/Paging-Vfz2RDBo.js +0 -93
- package/dist/RichText-B1Iogpgr.js +0 -47
- package/dist/SearchFooter-CmM8qnxP.js +0 -4
- package/dist/SearchFooter.vue_vue_type_style_index_0_lang-fRS96yRX.js +0 -55
- package/dist/Text-Bt5jL_KV.js +0 -49
- package/dist/Text-vHouxGHU.js +0 -4
- package/dist/Text.vue_vue_type_style_index_0_lang-CgxtY5ch.js +0 -59
- package/dist/Upload-DpQu3z1T.js +0 -71
- package/dist/assets/clone-BZn0cTAu.js +0 -134
- package/dist/assets/file-saver-CwlpTZSc.js +0 -74
- package/dist/assets/liquidjs-C2HVw1Ra.js +0 -2901
- package/dist/assets/moment-h96o7c8I.js +0 -2578
- package/dist/assets/sprintf-js-BPTdvBYM.js +0 -148
- package/dist/assets/underscore-B0BCaBxV.js +0 -1070
- package/dist/assets/underscore.string-DVXD2SZo.js +0 -425
- package/dist/assets/util-deprecate-Dzun97re.js +0 -28
- package/dist/main-KNkwb0pq.js +0 -10515
@@ -1,10 +1,9 @@
|
|
1
|
-
import { defineComponent as
|
2
|
-
import {
|
3
|
-
import "./assets/moment-h96o7c8I.js";
|
1
|
+
import { defineComponent as Q, toRefs as W, ref as p, onMounted as Y, computed as k, watch as Z, resolveComponent as x, openBlock as I, createElementBlock as A, normalizeClass as ee, unref as t, createVNode as B, withCtx as F, createBlock as le, createTextVNode as ae, toDisplayString as te, isRef as oe, createElementVNode as re } from "vue";
|
2
|
+
import { p as ue, K as P, i as ne, _ as R, l as ie, d as i, h as C, X as U, u as O, k as se } from "./main-DymfKjqO.js";
|
4
3
|
const de = {
|
5
4
|
key: 0,
|
6
5
|
class: "fa fa-upload"
|
7
|
-
}, pe = ["src"],
|
6
|
+
}, pe = ["src"], fe = /* @__PURE__ */ Q({
|
8
7
|
__name: "Upload",
|
9
8
|
props: {
|
10
9
|
schema: {},
|
@@ -15,39 +14,39 @@ const de = {
|
|
15
14
|
modelValue: {}
|
16
15
|
},
|
17
16
|
emits: ["submit", "change", "update:modelValue"],
|
18
|
-
setup(
|
19
|
-
let h =
|
17
|
+
setup(S, { emit: $ }) {
|
18
|
+
let h = $, z = S, { table: d, field: u, row: g, set: me, modelValue: E } = W(z), m = p(!1), j = p({}), c = p([]), N = p(), L = p(), f = !0, y = p({ action: "", data: null }), H = (e) => {
|
20
19
|
let l = se.getUploadToken();
|
21
20
|
e.forEach((o) => {
|
22
|
-
let a = `${
|
21
|
+
let a = `${U.upload.address}/api/objects/download?slug=${o[0]}&token=${l}`;
|
23
22
|
c.value.push({ name: o[1], url: a });
|
24
23
|
});
|
25
|
-
},
|
24
|
+
}, K = async (e) => {
|
26
25
|
f = !1;
|
27
26
|
let l = `/upload?table=${d.value.name}&field=${u.value.name}`;
|
28
|
-
y.value.action =
|
27
|
+
y.value.action = P.api.url + l;
|
29
28
|
let o = new ne();
|
30
|
-
o.path = l, o.method = "POST", await
|
29
|
+
o.path = l, o.method = "POST", await R.prepareAsync(o);
|
31
30
|
let a = o.getHeader("Authorization");
|
32
31
|
return j.value.Authorization = a, u.value.control.fileType == "Image" ? e.type.indexOf("image") == 0 ? Promise.resolve() : (ie.error("请上传正确的图片文件"), Promise.reject()) : Promise.resolve();
|
33
|
-
},
|
32
|
+
}, X = (e, l) => {
|
34
33
|
f = !1;
|
35
|
-
let a = [e.name.replace(
|
36
|
-
return
|
34
|
+
let a = [e.name.replace(P.api.url, "")];
|
35
|
+
return R.post("/upload/delete", { files: a }).then(({ data: r }) => {
|
37
36
|
let n = l.indexOf(e), _ = i.array.removeIndex(s.value, n, ",");
|
38
37
|
if (h("update:modelValue", _), u.value.control.name) {
|
39
|
-
let v = d.value.fields.find((w) => w.name == u.value.control.name), b =
|
40
|
-
|
38
|
+
let v = d.value.fields.find((w) => w.name == u.value.control.name), b = C.getValue(r.value, n, d.value, v), V = i.array.removeIndex(b, n, ",");
|
39
|
+
C.setValue(V, r.value, d.value, n, v);
|
41
40
|
}
|
42
41
|
return Promise.resolve();
|
43
42
|
}).catch(() => Promise.reject());
|
44
|
-
},
|
45
|
-
m.value = !0,
|
46
|
-
},
|
47
|
-
},
|
48
|
-
|
43
|
+
}, q = (e) => {
|
44
|
+
m.value = !0, N.value = e.url;
|
45
|
+
}, D = (e, l, o) => {
|
46
|
+
}, M = (e, l) => {
|
47
|
+
R.handleResponseBody(e).then((o) => {
|
49
48
|
let { name: a, url: r } = o.data[0];
|
50
|
-
|
49
|
+
U.upload.method == "box" || i.file.isImage(r) || (l.url = O.getFileIcon(r));
|
51
50
|
let _ = i.array.split(s.value, ",", r).join(",");
|
52
51
|
if (s.value = _, u.value.control.name) {
|
53
52
|
let v = d.value.fields.find((w) => w.name == u.value.control.name), b = g.value[v.value], V = i.array.split(b, ",", a);
|
@@ -58,7 +57,7 @@ const de = {
|
|
58
57
|
}).finally(() => {
|
59
58
|
f = !0;
|
60
59
|
});
|
61
|
-
},
|
60
|
+
}, T = () => {
|
62
61
|
if (c.value = [], !s.value)
|
63
62
|
return;
|
64
63
|
let e = i.array.split(s.value, ","), l = [];
|
@@ -67,53 +66,53 @@ const de = {
|
|
67
66
|
l = i.array.split(r, ",");
|
68
67
|
}
|
69
68
|
let o = i.array.combine(e, l);
|
70
|
-
if (
|
71
|
-
|
69
|
+
if (U.upload.method == "box")
|
70
|
+
H(o);
|
72
71
|
else {
|
73
|
-
let a = i.url.httpOrHttps(s.value) ? s.value :
|
74
|
-
i.file.isImage(a) ? r.url = a : r.url =
|
72
|
+
let a = i.url.httpOrHttps(s.value) ? s.value : P.api.url + s.value, r = { name: a, url: null };
|
73
|
+
i.file.isImage(a) ? r.url = a : r.url = O.getFileIcon(a), c.value.push(r);
|
75
74
|
}
|
76
75
|
};
|
77
76
|
Y(() => {
|
78
|
-
|
77
|
+
T();
|
79
78
|
});
|
80
|
-
let s =
|
79
|
+
let s = k({
|
81
80
|
get() {
|
82
81
|
return E.value;
|
83
82
|
},
|
84
83
|
set(e) {
|
85
84
|
h("update:modelValue", e), h("change", e);
|
86
85
|
}
|
87
|
-
}),
|
86
|
+
}), G = k(() => u.value.control.preview ? "picture-card" : null), J = k(() => J);
|
88
87
|
return Z(() => s.value, (e, l) => {
|
89
|
-
f &&
|
88
|
+
f && T();
|
90
89
|
}), (e, l) => {
|
91
|
-
const o =
|
92
|
-
return
|
90
|
+
const o = x("el-button"), a = x("el-upload"), r = x("el-dialog");
|
91
|
+
return I(), A("div", {
|
93
92
|
class: ee(t(u).control.preview ? "control-file-preview" : "control-file")
|
94
93
|
}, [
|
95
|
-
|
94
|
+
B(a, {
|
96
95
|
ref_key: "uploadRef",
|
97
|
-
ref:
|
98
|
-
"list-type": t(
|
96
|
+
ref: L,
|
97
|
+
"list-type": t(G),
|
99
98
|
action: t(y).action,
|
100
99
|
headers: t(j),
|
101
100
|
data: t(y).data,
|
102
101
|
"file-list": t(c),
|
103
|
-
"before-upload": t(
|
104
|
-
"before-remove": t(
|
105
|
-
"on-preview": t(
|
106
|
-
"on-success": t(
|
107
|
-
"on-progress": t(
|
102
|
+
"before-upload": t(K),
|
103
|
+
"before-remove": t(X),
|
104
|
+
"on-preview": t(q),
|
105
|
+
"on-success": t(M),
|
106
|
+
"on-progress": t(D),
|
108
107
|
disabled: t(u).readonly
|
109
108
|
}, {
|
110
|
-
default:
|
111
|
-
t(u).control.preview ? (
|
109
|
+
default: F(() => [
|
110
|
+
t(u).control.preview ? (I(), A("i", de)) : (I(), le(o, {
|
112
111
|
key: 1,
|
113
112
|
icon: "el-icon-upload",
|
114
113
|
type: "primary"
|
115
114
|
}, {
|
116
|
-
default:
|
115
|
+
default: F(() => [
|
117
116
|
ae(te(t(ue)("common.click_upload")), 1)
|
118
117
|
]),
|
119
118
|
_: 1
|
@@ -121,16 +120,16 @@ const de = {
|
|
121
120
|
]),
|
122
121
|
_: 1
|
123
122
|
}, 8, ["list-type", "action", "headers", "data", "file-list", "before-upload", "before-remove", "on-preview", "on-success", "on-progress", "disabled"]),
|
124
|
-
|
123
|
+
B(r, {
|
125
124
|
draggable: "",
|
126
125
|
"append-to-body": "",
|
127
126
|
modelValue: t(m),
|
128
127
|
"onUpdate:modelValue": l[0] || (l[0] = (n) => oe(m) ? m.value = n : m = n)
|
129
128
|
}, {
|
130
|
-
default:
|
129
|
+
default: F(() => [
|
131
130
|
re("img", {
|
132
131
|
width: "100%",
|
133
|
-
src: t(
|
132
|
+
src: t(N),
|
134
133
|
alt: ""
|
135
134
|
}, null, 8, pe)
|
136
135
|
]),
|
@@ -141,5 +140,5 @@ const de = {
|
|
141
140
|
}
|
142
141
|
});
|
143
142
|
export {
|
144
|
-
|
143
|
+
fe as default
|
145
144
|
};
|
@@ -0,0 +1,65 @@
|
|
1
|
+
import { defineComponent as b, toRefs as w, ref as r, onMounted as U, computed as x, resolveComponent as C, openBlock as d, createElementBlock as n, Fragment as E, renderList as F, unref as s, createVNode as $, isRef as y, withCtx as B, createElementVNode as I } from "vue";
|
2
|
+
import { X as c, k as K, d as v, K as N, u as R } from "./main-DymfKjqO.js";
|
3
|
+
const X = { class: "text-upload" }, j = ["src", "onClick", "alt"], A = ["src"], z = /* @__PURE__ */ b({
|
4
|
+
__name: "Upload",
|
5
|
+
props: {
|
6
|
+
schema: {},
|
7
|
+
table: {},
|
8
|
+
field: {},
|
9
|
+
set: {},
|
10
|
+
row: {},
|
11
|
+
modelValue: {}
|
12
|
+
},
|
13
|
+
setup(f) {
|
14
|
+
let g = f, { table: H, field: L, set: M, row: O, modelValue: _ } = w(g), i = r(), t = r(!1), p = r([]), m = r(), h = (e) => {
|
15
|
+
t.value = !0, m.value = e.url;
|
16
|
+
}, k = () => {
|
17
|
+
if (o.value)
|
18
|
+
if (c.upload.method == "box")
|
19
|
+
K.getUploadToken().then((e) => {
|
20
|
+
o.value.split(",").forEach((a) => {
|
21
|
+
let l = `${c.upload.address}/api/objects/download?slug=${a}&token=${e}`;
|
22
|
+
p.value.push({ name: a, url: l });
|
23
|
+
});
|
24
|
+
});
|
25
|
+
else {
|
26
|
+
let e = v.url.httpOrHttps(o.value) ? o.value : N.api.url + o.value;
|
27
|
+
v.file.isImage(e) ? i.value = e : i.value = R.getFileIcon(e);
|
28
|
+
}
|
29
|
+
};
|
30
|
+
U(() => {
|
31
|
+
k();
|
32
|
+
});
|
33
|
+
let o = x(() => _.value);
|
34
|
+
return (e, u) => {
|
35
|
+
const a = C("el-dialog");
|
36
|
+
return d(), n("div", X, [
|
37
|
+
(d(!0), n(E, null, F(s(p), (l, V) => (d(), n("img", {
|
38
|
+
class: "detail-image",
|
39
|
+
src: l.url,
|
40
|
+
onClick: (S) => s(h)(l),
|
41
|
+
alt: l.name,
|
42
|
+
key: V
|
43
|
+
}, null, 8, j))), 128)),
|
44
|
+
$(a, {
|
45
|
+
draggable: "",
|
46
|
+
"append-to-body": "",
|
47
|
+
top: "5vh",
|
48
|
+
modelValue: s(t),
|
49
|
+
"onUpdate:modelValue": u[0] || (u[0] = (l) => y(t) ? t.value = l : t = l)
|
50
|
+
}, {
|
51
|
+
default: B(() => [
|
52
|
+
I("img", {
|
53
|
+
width: "100%",
|
54
|
+
src: s(m)
|
55
|
+
}, null, 8, A)
|
56
|
+
]),
|
57
|
+
_: 1
|
58
|
+
}, 8, ["modelValue"])
|
59
|
+
]);
|
60
|
+
};
|
61
|
+
}
|
62
|
+
});
|
63
|
+
export {
|
64
|
+
z as default
|
65
|
+
};
|
@@ -10,7 +10,7 @@ const h = /* @__PURE__ */ u({
|
|
10
10
|
modelValue: {}
|
11
11
|
},
|
12
12
|
setup(a) {
|
13
|
-
let r = i(() => import("./Text-
|
13
|
+
let r = i(() => import("./Text-CNtHdodK.js")), s = a, { schema: m, table: n, field: d, set: f, row: p, modelValue: l } = c(s);
|
14
14
|
return (x, t) => (V(), b(e(r), {
|
15
15
|
schema: e(m),
|
16
16
|
table: e(n),
|
@@ -1,7 +1,6 @@
|
|
1
1
|
import { defineComponent as f, toRefs as _, computed as h, resolveComponent as V, openBlock as b, createBlock as g, unref as e, isRef as Y } from "vue";
|
2
|
-
import {
|
3
|
-
|
4
|
-
const B = /* @__PURE__ */ f({
|
2
|
+
import { T as k } from "./main-DymfKjqO.js";
|
3
|
+
const x = /* @__PURE__ */ f({
|
5
4
|
__name: "Year",
|
6
5
|
props: {
|
7
6
|
schema: {},
|
@@ -12,8 +11,8 @@ const B = /* @__PURE__ */ f({
|
|
12
11
|
modelValue: {}
|
13
12
|
},
|
14
13
|
emits: ["submit", "change", "update:modelValue"],
|
15
|
-
setup(
|
16
|
-
let o = d,
|
14
|
+
setup(r, { emit: d }) {
|
15
|
+
let o = d, u = r, { table: p, field: a, row: C, set: y, modelValue: s } = _(u), c = () => {
|
17
16
|
o("submit");
|
18
17
|
}, l = h({
|
19
18
|
get() {
|
@@ -27,16 +26,16 @@ const B = /* @__PURE__ */ f({
|
|
27
26
|
const i = V("el-date-picker");
|
28
27
|
return b(), g(i, {
|
29
28
|
type: "year",
|
30
|
-
placeholder: e(k)(e(
|
29
|
+
placeholder: e(k)(e(p).name, e(a).name),
|
31
30
|
"value-format": "YYYY",
|
32
31
|
disabled: e(a).control.readonly,
|
33
32
|
onChange: e(c),
|
34
33
|
modelValue: e(l),
|
35
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
34
|
+
"onUpdate:modelValue": n[0] || (n[0] = (m) => Y(l) ? l.value = m : l = m)
|
36
35
|
}, null, 8, ["placeholder", "disabled", "onChange", "modelValue"]);
|
37
36
|
};
|
38
37
|
}
|
39
38
|
});
|
40
39
|
export {
|
41
|
-
|
40
|
+
x as default
|
42
41
|
};
|