sd-render 1.1.0 → 1.1.1
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.
|
@@ -4,14 +4,14 @@ import "element-plus/es/components/dialog/style/index";
|
|
|
4
4
|
import "element-plus/es/components/button/style/index";
|
|
5
5
|
import "element-plus/es/components/icon/style/index";
|
|
6
6
|
import "element-plus/es/components/image/style/index";
|
|
7
|
-
import { createElementBlock as w, openBlock as n, normalizeClass as X, createElementVNode as P, createCommentVNode as g, toDisplayString as O, defineComponent as L, markRaw as jl, capitalize as Go, normalizeStyle as te, ref as K, nextTick as yt, resolveComponent as Y, Fragment as E, createVNode as r, withCtx as s, createBlock as p, createTextVNode as S, inject as j, renderList as G, resolveDynamicComponent as pa, mergeProps as ae, toHandlers as Ul, withModifiers as R, renderSlot as
|
|
7
|
+
import { createElementBlock as w, openBlock as n, normalizeClass as X, createElementVNode as P, createCommentVNode as g, toDisplayString as O, defineComponent as L, markRaw as jl, capitalize as Go, normalizeStyle as te, ref as K, nextTick as yt, resolveComponent as Y, Fragment as E, createVNode as r, withCtx as s, createBlock as p, createTextVNode as S, inject as j, renderList as G, resolveDynamicComponent as pa, mergeProps as ae, toHandlers as Ul, withModifiers as R, renderSlot as he, computed as le, watch as Ke, provide as xe, unref as me, watchEffect as Yo, toRaw as Jo, withDirectives as Ve, vShow as Rl, reactive as ke, onMounted as Je, normalizeProps as Oa, guardReactiveProps as Na, createSlots as tt, defineAsyncComponent as Xo, resolveDirective as zl, withKeys as Qo } from "vue";
|
|
8
8
|
import { Editor as It, Node as ot, mergeAttributes as Xe, getMarkRange as Zo, Extension as He, isList as ei } from "@tiptap/core";
|
|
9
9
|
import We from "ace-builds";
|
|
10
10
|
import "ace-builds/src-min-noconflict/theme-tomorrow_night_eighties";
|
|
11
11
|
import "ace-builds/src-min-noconflict/theme-sqlserver";
|
|
12
12
|
import "ace-builds/src-min-noconflict/mode-html";
|
|
13
13
|
import "ace-builds/src-min-noconflict/ext-beautify";
|
|
14
|
-
import { useDark as
|
|
14
|
+
import { useDark as re } from "@vueuse/core";
|
|
15
15
|
import ti from "@tiptap/extension-list-item";
|
|
16
16
|
import Ka from "@tiptap/extension-text";
|
|
17
17
|
import Ga from "@tiptap/extension-paragraph";
|
|
@@ -102,7 +102,7 @@ import Vi from "@tiptap/extension-bullet-list";
|
|
|
102
102
|
import Ai from "@tiptap/extension-ordered-list";
|
|
103
103
|
import Oi from "@tiptap/extension-image";
|
|
104
104
|
import "element-plus/es/components/upload/style/index";
|
|
105
|
-
import
|
|
105
|
+
import ce from "axios";
|
|
106
106
|
import Ni from "@tiptap/extension-task-list";
|
|
107
107
|
import Ei from "@tiptap/extension-task-item";
|
|
108
108
|
import { Table as Li } from "@tiptap/extension-table";
|
|
@@ -495,7 +495,7 @@ function On(e, t, a, l, o, i) {
|
|
|
495
495
|
}, null, 4);
|
|
496
496
|
}
|
|
497
497
|
const Nn = /* @__PURE__ */ B(An, [["render", On]]);
|
|
498
|
-
var Ue = /* @__PURE__ */ ((e) => (e.None = "None", e.String = "String", e.Integer = "Integer", e.Number = "Number", e.Boolean = "Boolean", e.Array = "Array", e.Object = "Object", e.ObjectId = "ObjectId", e.StringDate = "StringDate", e.ArrayDate = "ArrayDate", e.Date = "Date", e.Timestamp = "Timestamp", e.Binary = "Binary", e.StringArray = "String|Array", e.ObjectArray = "Object|Array", e.Any = "Any", e))(Ue || {}),
|
|
498
|
+
var Ue = /* @__PURE__ */ ((e) => (e.None = "None", e.String = "String", e.Integer = "Integer", e.Number = "Number", e.Boolean = "Boolean", e.Array = "Array", e.Object = "Object", e.ObjectId = "ObjectId", e.StringDate = "StringDate", e.ArrayDate = "ArrayDate", e.Date = "Date", e.Timestamp = "Timestamp", e.Binary = "Binary", e.StringArray = "String|Array", e.ObjectArray = "Object|Array", e.Any = "Any", e))(Ue || {}), ue = /* @__PURE__ */ ((e) => (e.SYS = "SYS", e.FORM = "FORM", e.SQL = "SQL", e))(ue || {}), fe = /* @__PURE__ */ ((e) => (e.ASC = "ASC", e.DESC = "DESC", e))(fe || {});
|
|
499
499
|
const Kb = [
|
|
500
500
|
{
|
|
501
501
|
value: "user-list",
|
|
@@ -806,7 +806,7 @@ function $a(e, t, a) {
|
|
|
806
806
|
d && (i === l.length - 1 ? o[d] = a : ((!o[d] || typeof o[d] != "object" || Array.isArray(o[d])) && (o[d] = {}), o = o[d]));
|
|
807
807
|
}
|
|
808
808
|
}
|
|
809
|
-
function
|
|
809
|
+
function de(e, t) {
|
|
810
810
|
try {
|
|
811
811
|
let a = t.split("."), l = e;
|
|
812
812
|
for (let o = 0, i = a.length; o < i; o++) {
|
|
@@ -827,7 +827,7 @@ function ce(e, t) {
|
|
|
827
827
|
function Tt(e) {
|
|
828
828
|
return ri.sanitize(e, {});
|
|
829
829
|
}
|
|
830
|
-
function
|
|
830
|
+
function se(e, t) {
|
|
831
831
|
const a = (i) => `{{###~${i}~###}}`, l = Object.keys(t).map((i, d) => ({
|
|
832
832
|
key: i,
|
|
833
833
|
val: t[i],
|
|
@@ -1655,7 +1655,7 @@ const eo = /* @__PURE__ */ B(ys, [["render", vs]]), ws = L({
|
|
|
1655
1655
|
function _s(e, t, a, l, o, i) {
|
|
1656
1656
|
const d = eo, u = Zl, m = Ql;
|
|
1657
1657
|
return n(), w("div", Fs, [
|
|
1658
|
-
|
|
1658
|
+
he(e.$slots, "prepend"),
|
|
1659
1659
|
r(d, {
|
|
1660
1660
|
editor: e.editor,
|
|
1661
1661
|
url: e.linkAttrs.href
|
|
@@ -2098,8 +2098,8 @@ function Ts(e) {
|
|
|
2098
2098
|
l.value = h;
|
|
2099
2099
|
};
|
|
2100
2100
|
let i;
|
|
2101
|
-
const d =
|
|
2102
|
-
const h =
|
|
2101
|
+
const d = re(), u = () => {
|
|
2102
|
+
const h = me(e).extensionManager.extensions.find((b) => b.name === "codeView");
|
|
2103
2103
|
if (h) {
|
|
2104
2104
|
const { editorOptions: b } = h.options;
|
|
2105
2105
|
if (We) {
|
|
@@ -2117,7 +2117,7 @@ function Ts(e) {
|
|
|
2117
2117
|
wrap: _.wrap,
|
|
2118
2118
|
printMargin: _.printMargin,
|
|
2119
2119
|
useWorker: _.useWorker,
|
|
2120
|
-
value:
|
|
2120
|
+
value: me(e).getHTML()
|
|
2121
2121
|
})
|
|
2122
2122
|
), We.require("ace/ext/beautify").beautify(t.session);
|
|
2123
2123
|
}
|
|
@@ -2132,7 +2132,7 @@ function Ts(e) {
|
|
|
2132
2132
|
});
|
|
2133
2133
|
else if (t) {
|
|
2134
2134
|
const b = t.getValue();
|
|
2135
|
-
|
|
2135
|
+
me(e).commands.setContent(
|
|
2136
2136
|
b,
|
|
2137
2137
|
!0
|
|
2138
2138
|
/* emitUpdate */
|
|
@@ -2312,7 +2312,7 @@ const Ps = L({
|
|
|
2312
2312
|
onUpdate: i
|
|
2313
2313
|
});
|
|
2314
2314
|
Yo(() => {
|
|
2315
|
-
|
|
2315
|
+
me(d)?.setOptions({
|
|
2316
2316
|
editorProps: {
|
|
2317
2317
|
attributes: {
|
|
2318
2318
|
spellcheck: String(e.spellcheck)
|
|
@@ -2326,7 +2326,7 @@ const Ps = L({
|
|
|
2326
2326
|
xe("isFullscreen", h), xe("toggleFullscreen", b), xe("enableTooltip", e.tooltip), xe("userState", e.userState);
|
|
2327
2327
|
const { isCodeViewMode: _, aceAreaRef: C } = Ts(d);
|
|
2328
2328
|
xe("isCodeViewMode", _);
|
|
2329
|
-
const { characters: c } = $s(d), M = le(() => e.enableCharCount && !
|
|
2329
|
+
const { characters: c } = $s(d), M = le(() => e.enableCharCount && !me(_));
|
|
2330
2330
|
return xe("t", m), xe("et", this), {
|
|
2331
2331
|
t: m,
|
|
2332
2332
|
onUpdate: i,
|
|
@@ -2672,7 +2672,7 @@ const zs = Ci.extend({
|
|
|
2672
2672
|
previewIndex: 0
|
|
2673
2673
|
}), l = K([]), o = K(null), i = e, d = ke({
|
|
2674
2674
|
providerId: "getfiles-gallery",
|
|
2675
|
-
providerType:
|
|
2675
|
+
providerType: ue.SYS,
|
|
2676
2676
|
options: {
|
|
2677
2677
|
page: 1,
|
|
2678
2678
|
limit: i.perPage ? i.perPage : 30
|
|
@@ -2720,7 +2720,7 @@ const zs = Ci.extend({
|
|
|
2720
2720
|
fileGroup: I.file_group ? I.file_group : I.fileGroup ? I.fileGroup : "",
|
|
2721
2721
|
fileId: I._id ? I._id : I.fileId ? I.fileId : ""
|
|
2722
2722
|
};
|
|
2723
|
-
await
|
|
2723
|
+
await ce.delete(`${i.userState.host}${a.type[b.value].deleteUrl}`, {
|
|
2724
2724
|
data: V,
|
|
2725
2725
|
headers: {
|
|
2726
2726
|
Authorization: `Bearer ${i.userState.user?.token}`
|
|
@@ -2786,7 +2786,7 @@ const zs = Ci.extend({
|
|
|
2786
2786
|
"preview-teleported": ""
|
|
2787
2787
|
}, null, 8, ["src", "preview-src-list", "initial-index"]),
|
|
2788
2788
|
P("span", Ws, [
|
|
2789
|
-
|
|
2789
|
+
he(F.$slots, "action", { file: Me }, void 0, !0),
|
|
2790
2790
|
P("span", {
|
|
2791
2791
|
class: "el-upload-list__item-preview",
|
|
2792
2792
|
onClick: (U) => q(Me)
|
|
@@ -3673,7 +3673,7 @@ const $r = /* @__PURE__ */ B(kr, [["render", Ir]]), Tr = Ei.extend({
|
|
|
3673
3673
|
setup(e, { emit: t }) {
|
|
3674
3674
|
const a = j("t"), l = K(), o = K(!1);
|
|
3675
3675
|
return { t: a, popoverVisible: o, popoverRef: l, confirmCreateTable: (d, u) => {
|
|
3676
|
-
|
|
3676
|
+
me(l).hide(), t("createTable", { row: d, col: u });
|
|
3677
3677
|
} };
|
|
3678
3678
|
},
|
|
3679
3679
|
data() {
|
|
@@ -4308,7 +4308,7 @@ const Yr = /* @__PURE__ */ B(Kr, [["render", Gr]]), bl = xi.extend({
|
|
|
4308
4308
|
const t = j("t"), a = j("enableTooltip", !0), l = j("isCodeViewMode", !1), o = K(), i = K("");
|
|
4309
4309
|
function d(m) {
|
|
4310
4310
|
let h = e.editor.commands;
|
|
4311
|
-
m ? h.setColor(m) : h.unsetColor(),
|
|
4311
|
+
m ? h.setColor(m) : h.unsetColor(), me(o).hide();
|
|
4312
4312
|
}
|
|
4313
4313
|
const u = le(() => ca(e.editor.state, "textStyle").color || "");
|
|
4314
4314
|
return Ke(u, (m) => {
|
|
@@ -4433,7 +4433,7 @@ const ad = /* @__PURE__ */ B(Jr, [["render", td]]), gl = Wi.extend({
|
|
|
4433
4433
|
const t = j("t"), a = j("enableTooltip", !0), l = j("isCodeViewMode", !1), o = K(null), i = K(!1), d = K("");
|
|
4434
4434
|
function u(h) {
|
|
4435
4435
|
let b = e.editor.commands;
|
|
4436
|
-
h ? b.setHighlight({ color: h }) : b.unsetHighlight(),
|
|
4436
|
+
h ? b.setHighlight({ color: h }) : b.unsetHighlight(), me(o).hide();
|
|
4437
4437
|
}
|
|
4438
4438
|
const m = le(() => ca(e.editor.state, "highlight").color || "");
|
|
4439
4439
|
return Ke(m, (h) => {
|
|
@@ -5063,7 +5063,7 @@ const $d = /* @__PURE__ */ B(Dd, [["render", Id]]), Td = Yi.extend({
|
|
|
5063
5063
|
totalPage: 0
|
|
5064
5064
|
}), i = K([]), d = e, u = ke({
|
|
5065
5065
|
providerId: "getfiles-uploadfile",
|
|
5066
|
-
providerType:
|
|
5066
|
+
providerType: ue.SYS,
|
|
5067
5067
|
options: {
|
|
5068
5068
|
page: 1,
|
|
5069
5069
|
limit: d.perPage ? d.perPage : 30
|
|
@@ -5127,7 +5127,7 @@ const $d = /* @__PURE__ */ B(Dd, [["render", Id]]), Td = Yi.extend({
|
|
|
5127
5127
|
fileGroup: I.file_group ? I.file_group : I.fileGroup ? I.fileGroup : "",
|
|
5128
5128
|
fileId: I._id ? I._id : I.fileId ? I.fileId : ""
|
|
5129
5129
|
};
|
|
5130
|
-
|
|
5130
|
+
ce.delete(`${d.userState.host}${o.type[b.value].deleteUrl}`, {
|
|
5131
5131
|
data: V,
|
|
5132
5132
|
headers: {
|
|
5133
5133
|
Authorization: `Bearer ${d.userState.user?.token}`
|
|
@@ -5860,7 +5860,7 @@ const iu = /* @__PURE__ */ B(lu, [["render", ou]]), nu = {
|
|
|
5860
5860
|
props: we,
|
|
5861
5861
|
data() {
|
|
5862
5862
|
return {
|
|
5863
|
-
isDark:
|
|
5863
|
+
isDark: re()
|
|
5864
5864
|
};
|
|
5865
5865
|
},
|
|
5866
5866
|
mounted() {
|
|
@@ -6082,7 +6082,7 @@ const bu = /* @__PURE__ */ B(hu, [["render", cu]]), Il = ot.create({
|
|
|
6082
6082
|
},
|
|
6083
6083
|
props: we,
|
|
6084
6084
|
data() {
|
|
6085
|
-
return { isDark:
|
|
6085
|
+
return { isDark: re() };
|
|
6086
6086
|
},
|
|
6087
6087
|
mounted() {
|
|
6088
6088
|
},
|
|
@@ -6831,7 +6831,7 @@ function Mu(e, t, a, l, o, i) {
|
|
|
6831
6831
|
onPaste: t[6] || (t[6] = (...d) => e.onPaste && e.onPaste(...d))
|
|
6832
6832
|
}, null, 40, Tu);
|
|
6833
6833
|
}
|
|
6834
|
-
const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => await
|
|
6834
|
+
const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => await ce.post(
|
|
6835
6835
|
`${a.host}/widget/crud/getdata-all`,
|
|
6836
6836
|
{ sdProvider: e, totalEnable: t },
|
|
6837
6837
|
{
|
|
@@ -6839,7 +6839,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6839
6839
|
Authorization: `Bearer ${a.user?.token}`
|
|
6840
6840
|
}
|
|
6841
6841
|
}
|
|
6842
|
-
).then((o) => o.data && o.data.message ? { response: !0, data: o.data, message: o.data.message } : { response: !1, data: null, message: "Can't get data" }).catch((o) => o.response && o.response.data && o.response.data.message ? { response: !1, data: null, message: o.response.data.message } : { response: !1, data: null, message: "Can't get data (error)" }), Ot = async (e, t) => await
|
|
6842
|
+
).then((o) => o.data && o.data.message ? { response: !0, data: o.data, message: o.data.message } : { response: !1, data: null, message: "Can't get data" }).catch((o) => o.response && o.response.data && o.response.data.message ? { response: !1, data: null, message: o.response.data.message } : { response: !1, data: null, message: "Can't get data (error)" }), Ot = async (e, t) => await ce.post(
|
|
6843
6843
|
`${t.host}/widget/crud/getdata-one`,
|
|
6844
6844
|
{ sdProvider: e },
|
|
6845
6845
|
{
|
|
@@ -6847,7 +6847,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6847
6847
|
Authorization: `Bearer ${t.user?.token}`
|
|
6848
6848
|
}
|
|
6849
6849
|
}
|
|
6850
|
-
).then((l) => l.data && l.data.message ? { response: !0, data: l.data, message: l.data.message } : { response: !1, data: null, message: "Can't get data" }).catch((l) => l.response && l.response.data && l.response.data.message ? { response: !1, data: null, message: l.response.data.message } : { response: !1, data: null, message: "Can't get data" }), Ie = async (e, t) => await
|
|
6850
|
+
).then((l) => l.data && l.data.message ? { response: !0, data: l.data, message: l.data.message } : { response: !1, data: null, message: "Can't get data" }).catch((l) => l.response && l.response.data && l.response.data.message ? { response: !1, data: null, message: l.response.data.message } : { response: !1, data: null, message: "Can't get data" }), Ie = async (e, t) => await ce.post(
|
|
6851
6851
|
`${t.host}/widget/sdform/getform`,
|
|
6852
6852
|
{ formId: e },
|
|
6853
6853
|
{
|
|
@@ -6861,7 +6861,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6861
6861
|
return o.dataid = o._id, { response: !0, data: o, message: l.data.message };
|
|
6862
6862
|
} else
|
|
6863
6863
|
return { response: !1, data: void 0, message: "Can't get form" };
|
|
6864
|
-
}).catch((l) => l.response && l.response.data && l.response.data.message ? { response: !1, data: void 0, message: l.response.data.message } : { response: !1, data: void 0, message: "Can't get form" }), Pu = async (e, t, a) => await
|
|
6864
|
+
}).catch((l) => l.response && l.response.data && l.response.data.message ? { response: !1, data: void 0, message: l.response.data.message } : { response: !1, data: void 0, message: "Can't get form" }), Pu = async (e, t, a) => await ce.post(
|
|
6865
6865
|
`${a.host}/widget/sdform/getform-version`,
|
|
6866
6866
|
{ formId: e, versionName: t },
|
|
6867
6867
|
{
|
|
@@ -6875,7 +6875,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6875
6875
|
return i.dataid = i._id, { response: !0, data: i, message: o.data.message };
|
|
6876
6876
|
} else
|
|
6877
6877
|
return { response: !1, data: void 0, message: "Can't get form" };
|
|
6878
|
-
}).catch((o) => o.response && o.response.data && o.response.data.message ? { response: !1, data: void 0, message: o.response.data.message } : { response: !1, data: void 0, message: "Can't get form" }), wa = async (e, t) => await
|
|
6878
|
+
}).catch((o) => o.response && o.response.data && o.response.data.message ? { response: !1, data: void 0, message: o.response.data.message } : { response: !1, data: void 0, message: "Can't get form" }), wa = async (e, t) => await ce.post(
|
|
6879
6879
|
`${t.host}/widget/sdform/insert-empty`,
|
|
6880
6880
|
{ formId: e },
|
|
6881
6881
|
{
|
|
@@ -6889,12 +6889,12 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6889
6889
|
return o.dataid = l.data.id, o._id = l.data.id, o;
|
|
6890
6890
|
} else
|
|
6891
6891
|
return null;
|
|
6892
|
-
}).catch((l) => null), Vu = async (e, t, a) => await
|
|
6892
|
+
}).catch((l) => null), Vu = async (e, t, a) => await ce.delete(`${a.host}/widget/sdform/delete-empty`, {
|
|
6893
6893
|
headers: {
|
|
6894
6894
|
Authorization: `Bearer ${a.user?.token}`
|
|
6895
6895
|
},
|
|
6896
6896
|
data: { formId: e, dataId: t }
|
|
6897
|
-
}).then((o) => !0).catch((o) => !1), dt = async (e, t, a, l, o) => await
|
|
6897
|
+
}).then((o) => !0).catch((o) => !1), dt = async (e, t, a, l, o) => await ce.put(
|
|
6898
6898
|
`${o.host}/widget/sdform/save-data`,
|
|
6899
6899
|
{ formId: e, dataId: t, dataUpdate: a, rstat: l },
|
|
6900
6900
|
{
|
|
@@ -6908,12 +6908,12 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6908
6908
|
return u._id = d.data.id, u.dataid = u._id, { data: u, message: d.data.message };
|
|
6909
6909
|
} else
|
|
6910
6910
|
return { data: null, message: d.data.message };
|
|
6911
|
-
}).catch((d) => d.response && d.response.data && d.response.data.message ? { data: null, message: d.response.data.message } : { data: null, message: "Can't save data" }), ja = async (e, t, a) => await
|
|
6911
|
+
}).catch((d) => d.response && d.response.data && d.response.data.message ? { data: null, message: d.response.data.message } : { data: null, message: "Can't save data" }), ja = async (e, t, a) => await ce.delete(`${a.host}/widget/sdform/remove-data`, {
|
|
6912
6912
|
headers: {
|
|
6913
6913
|
Authorization: `Bearer ${a.user?.token}`
|
|
6914
6914
|
},
|
|
6915
6915
|
data: { formId: e, dataId: t }
|
|
6916
|
-
}).then((o) => !0).catch((o) => !1), ug = async (e, t, a) => await
|
|
6916
|
+
}).then((o) => !0).catch((o) => !1), ug = async (e, t, a) => await ce.delete(`${a.host}/widget/sdform/delete-data`, {
|
|
6917
6917
|
headers: {
|
|
6918
6918
|
Authorization: `Bearer ${a.user?.token}`
|
|
6919
6919
|
},
|
|
@@ -6941,7 +6941,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
6941
6941
|
], pg = (e, t) => e && Object.keys(e).length > 0 && e[t] && e[t].type ? e[t].type : ["_id", "xparentx"].includes(t) ? Ue.ObjectId : Ue.Any, co = (e, t) => {
|
|
6942
6942
|
const a = e && e.form_db && e.form_db.schema ? e.form_db.schema : null;
|
|
6943
6943
|
return a && Object.keys(a).length > 0 && t && a[t] && a[t].type ? a[t].type : ["_id", "xparentx"].includes(t) ? Ue.ObjectId : Ue.Any;
|
|
6944
|
-
}, Pl = (e, t) => ["_id", "xparentx"].includes(t) ? !0 : co(e, t) === "ObjectId", mg = async (e, t, a, l) => await
|
|
6944
|
+
}, Pl = (e, t) => ["_id", "xparentx"].includes(t) ? !0 : co(e, t) === "ObjectId", mg = async (e, t, a, l) => await ce.put(
|
|
6945
6945
|
`${l.host}/widget/sdform/check-parent`,
|
|
6946
6946
|
{ formId: e, dataId: t, formData: a },
|
|
6947
6947
|
{
|
|
@@ -7168,11 +7168,18 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
7168
7168
|
if (u[a] && u[a] === d) {
|
|
7169
7169
|
let m = [], h = {};
|
|
7170
7170
|
l.forEach((b) => {
|
|
7171
|
-
|
|
7172
|
-
|
|
7171
|
+
const _ = de(u, b);
|
|
7172
|
+
_ ? (m.push(_), h[`{{${b}}}`] = _) : h[`{{${b}}}`] = "";
|
|
7173
|
+
}), o && o != "" ? i.push(se(o, h)) : i.push(m.join(" "));
|
|
7173
7174
|
break;
|
|
7174
7175
|
}
|
|
7175
7176
|
return i.join(", ");
|
|
7177
|
+
}, fg = (e, t, a) => {
|
|
7178
|
+
let l = "", o = [], i = {};
|
|
7179
|
+
return t.forEach((d) => {
|
|
7180
|
+
const u = de(e, d);
|
|
7181
|
+
u ? (o.push(u), i[`{{${d}}}`] = u) : i[`{{${d}}}`] = "";
|
|
7182
|
+
}), a && a != "" ? l = se(a, i) : l = o.join(" "), l;
|
|
7176
7183
|
}, Eu = L({
|
|
7177
7184
|
name: "SdGridColumnDynamic",
|
|
7178
7185
|
components: {
|
|
@@ -7270,7 +7277,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
7270
7277
|
i = i.slice(0, d);
|
|
7271
7278
|
let b = i.length > 0 ? i.join(".") : i.join();
|
|
7272
7279
|
if (e[b] && e[b].type && e[b].type == "Array") {
|
|
7273
|
-
let _ =
|
|
7280
|
+
let _ = de(t, b), C = [];
|
|
7274
7281
|
for (const c in _)
|
|
7275
7282
|
if (Object.prototype.hasOwnProperty.call(_, c)) {
|
|
7276
7283
|
let f = _[c][h];
|
|
@@ -7281,7 +7288,7 @@ const dg = /* @__PURE__ */ B($u, [["render", Mu]]), at = async (e, t, a) => awai
|
|
|
7281
7288
|
}
|
|
7282
7289
|
let u = a;
|
|
7283
7290
|
this.subIndex > -1 && (u = `${this.parentName}.${this.subIndex}.${this.fieldName}`);
|
|
7284
|
-
let m =
|
|
7291
|
+
let m = de(t, u);
|
|
7285
7292
|
return this.rawValue ? m ?? null : Ae(m, a, l, o);
|
|
7286
7293
|
}
|
|
7287
7294
|
}
|
|
@@ -7696,7 +7703,7 @@ const xt = /* @__PURE__ */ B(Eu, [["render", Lu], ["__scopeId", "data-v-6f6b7a15
|
|
|
7696
7703
|
return (e, t) => {
|
|
7697
7704
|
let a = {}, l = this.sdformModel.form_db.schema;
|
|
7698
7705
|
for (const o in l) {
|
|
7699
|
-
let i =
|
|
7706
|
+
let i = de(t, o);
|
|
7700
7707
|
a[`{{${o}}}`] = Ae(i, o, this.sdformModel);
|
|
7701
7708
|
}
|
|
7702
7709
|
if (this.customValue) {
|
|
@@ -7705,7 +7712,7 @@ const xt = /* @__PURE__ */ B(Eu, [["render", Lu], ["__scopeId", "data-v-6f6b7a15
|
|
|
7705
7712
|
let i = this.customValue[o];
|
|
7706
7713
|
if (i.expressions)
|
|
7707
7714
|
try {
|
|
7708
|
-
const u = `return ${
|
|
7715
|
+
const u = `return ${se(i.expressions, a)}`, m = new Function("row", ...De, u);
|
|
7709
7716
|
a[`{{${i.fieldName}}}`] = m.call(this.sdformModel, t);
|
|
7710
7717
|
} catch (d) {
|
|
7711
7718
|
a[`{{${i.fieldName}}}`] = d;
|
|
@@ -7714,7 +7721,7 @@ const xt = /* @__PURE__ */ B(Eu, [["render", Lu], ["__scopeId", "data-v-6f6b7a15
|
|
|
7714
7721
|
a[`{{${i.fieldName}}}`] = "";
|
|
7715
7722
|
}
|
|
7716
7723
|
}
|
|
7717
|
-
return Tt(
|
|
7724
|
+
return Tt(se(e, a));
|
|
7718
7725
|
};
|
|
7719
7726
|
}
|
|
7720
7727
|
},
|
|
@@ -7762,9 +7769,9 @@ const xt = /* @__PURE__ */ B(Eu, [["render", Lu], ["__scopeId", "data-v-6f6b7a15
|
|
|
7762
7769
|
this.defaultParams = { ...t, ...e }, this.dpFormData.params = D(this.defaultParams), this.noMore || this.getDataList();
|
|
7763
7770
|
},
|
|
7764
7771
|
initForm(e) {
|
|
7765
|
-
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType =
|
|
7772
|
+
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType = ue.FORM), this.dpFormData.params || (this.dpFormData.params = {}), this.dpFormData.options ? (this.dpFormData.options.page || (this.dpFormData.options.page = 1), this.dpFormData.options.limit ? this.limit = this.dpFormData.options.limit : this.dpFormData.options.limit = this.limit, this.optionProvider = this.dpFormData.options) : this.dpFormData.options = this.optionProvider, this.parentId != "" && (this.params.xparentx = this.parentId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND xparentx = CONVERT(:xparentx, 'objectId')" : this.dpFormData.options.where = "xparentx = CONVERT(:xparentx, 'objectId')"), this.searchFields ? this.dpFormData.options.search = this.searchFields : this.dpFormData.options.search = this.sdformModel.form_options.search_fields ? this.sdformModel.form_options.search_fields : [];
|
|
7766
7773
|
const t = D(this.dpFormData.params), a = D(this.params);
|
|
7767
|
-
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort:
|
|
7774
|
+
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort: fe.DESC }]), this.noMore || this.getDataList(), this.enableWs && this.sdformModel.form_options && this.sdformModel.form_options.enable_websocket && (this.wsConn = this.userState.connectWebSocket("gridform", this.sdformModel.dataid, this.widgetId, (l) => {
|
|
7768
7775
|
if (l.from != "server" && (l.from != this.userState.user?.username || l.params && l.params.widget && l.params.widget !== this.widgetId)) {
|
|
7769
7776
|
let o = -1;
|
|
7770
7777
|
const i = D(l.data);
|
|
@@ -7882,7 +7889,7 @@ const xt = /* @__PURE__ */ B(Eu, [["render", Lu], ["__scopeId", "data-v-6f6b7a15
|
|
|
7882
7889
|
});
|
|
7883
7890
|
},
|
|
7884
7891
|
getValue(e, t) {
|
|
7885
|
-
let a =
|
|
7892
|
+
let a = de(e, t);
|
|
7886
7893
|
return a ? Ae(a, t, this.sdformModel) : "";
|
|
7887
7894
|
},
|
|
7888
7895
|
getSchema(e) {
|
|
@@ -8123,7 +8130,7 @@ function Tp(e, t, a, l, o, i) {
|
|
|
8123
8130
|
innerHTML: e.htmlValue(e.statusContent, V)
|
|
8124
8131
|
}, null, 12, Zu)) : g("", !0),
|
|
8125
8132
|
e.actionEnable ? (n(), w("span", ep, [
|
|
8126
|
-
|
|
8133
|
+
he(e.$slots, "actionBtnRow", {
|
|
8127
8134
|
row: V,
|
|
8128
8135
|
index: T
|
|
8129
8136
|
}, void 0, !0),
|
|
@@ -8521,7 +8528,7 @@ function Tp(e, t, a, l, o, i) {
|
|
|
8521
8528
|
}, null, 8, Ip))
|
|
8522
8529
|
], 4)) : g("", !0),
|
|
8523
8530
|
e.actionEnable ? (n(), w("span", $p, [
|
|
8524
|
-
|
|
8531
|
+
he(e.$slots, "actionBtnRow", {
|
|
8525
8532
|
row: V,
|
|
8526
8533
|
index: T
|
|
8527
8534
|
}, void 0, !0),
|
|
@@ -8568,7 +8575,7 @@ function Tp(e, t, a, l, o, i) {
|
|
|
8568
8575
|
])) : g("", !0)
|
|
8569
8576
|
], 64);
|
|
8570
8577
|
}
|
|
8571
|
-
const Mp = /* @__PURE__ */ B(Bu, [["render", Tp], ["__scopeId", "data-v-ff1dc326"]]),
|
|
8578
|
+
const Mp = /* @__PURE__ */ B(Bu, [["render", Tp], ["__scopeId", "data-v-ff1dc326"]]), hg = /* @__PURE__ */ L({
|
|
8572
8579
|
__name: "SdAppList",
|
|
8573
8580
|
props: {
|
|
8574
8581
|
userState: {
|
|
@@ -9517,7 +9524,7 @@ const Mp = /* @__PURE__ */ B(Bu, [["render", Tp], ["__scopeId", "data-v-ff1dc326
|
|
|
9517
9524
|
function Ta(e) {
|
|
9518
9525
|
return e.includes("admin") || e.includes("super");
|
|
9519
9526
|
}
|
|
9520
|
-
const Pp = Xo(() => import("./sd-render-
|
|
9527
|
+
const Pp = Xo(() => import("./sd-render-CWzAnbYE.js").then((e) => e.S)), Vp = L({
|
|
9521
9528
|
name: "SdCrudForm",
|
|
9522
9529
|
components: {
|
|
9523
9530
|
SdFormRenderAsync: Pp
|
|
@@ -9736,8 +9743,8 @@ const Pp = Xo(() => import("./sd-render-jM1JOKg_.js").then((e) => e.S)), Vp = L(
|
|
|
9736
9743
|
}
|
|
9737
9744
|
this.nextOpenForm = {
|
|
9738
9745
|
formId: a.form,
|
|
9739
|
-
parentId:
|
|
9740
|
-
dataId:
|
|
9746
|
+
parentId: se(a.parentId, o),
|
|
9747
|
+
dataId: se(a.dataId, o),
|
|
9741
9748
|
initData: i
|
|
9742
9749
|
}, this.nextOpenForm.dataId ? this.nextOpenForm.isInsert = !1 : this.nextOpenForm.isInsert = !0, this.subFormOpen({
|
|
9743
9750
|
modelValue: !0,
|
|
@@ -9836,7 +9843,7 @@ function Ap(e, t, a, l, o, i) {
|
|
|
9836
9843
|
onFormChange: e.onFormChange
|
|
9837
9844
|
}, {
|
|
9838
9845
|
default: s(() => [
|
|
9839
|
-
|
|
9846
|
+
he(e.$slots, "inputForm")
|
|
9840
9847
|
]),
|
|
9841
9848
|
_: 3
|
|
9842
9849
|
}, 8, ["sdform", "parent-id", "form-data", "option-model", "disabled", "api-url", "params", "annotated", "is-sub-form", "auth-token", "submit-func", "user-state", "onFormChange"])) : g("", !0)
|
|
@@ -9891,7 +9898,7 @@ function Ap(e, t, a, l, o, i) {
|
|
|
9891
9898
|
_: 1
|
|
9892
9899
|
})
|
|
9893
9900
|
], 64)) : g("", !0),
|
|
9894
|
-
|
|
9901
|
+
he(e.$slots, "closeForm")
|
|
9895
9902
|
]),
|
|
9896
9903
|
_: 3
|
|
9897
9904
|
})
|
|
@@ -10035,7 +10042,7 @@ function Kp(e, t, a, l, o, i) {
|
|
|
10035
10042
|
icon: "InfoFilled",
|
|
10036
10043
|
onClick: e.handleAppInfo
|
|
10037
10044
|
}, null, 8, ["onClick"])) : g("", !0),
|
|
10038
|
-
|
|
10045
|
+
he(e.$slots, "actions", {}, void 0, !0)
|
|
10039
10046
|
])
|
|
10040
10047
|
]),
|
|
10041
10048
|
P("div", Rp, [
|
|
@@ -10188,7 +10195,7 @@ function Kp(e, t, a, l, o, i) {
|
|
|
10188
10195
|
])) : g("", !0)
|
|
10189
10196
|
], 64);
|
|
10190
10197
|
}
|
|
10191
|
-
const
|
|
10198
|
+
const cg = /* @__PURE__ */ B(Op, [["render", Kp], ["__scopeId", "data-v-bc1eaadb"]]);
|
|
10192
10199
|
tn.register(
|
|
10193
10200
|
an,
|
|
10194
10201
|
ln,
|
|
@@ -10317,7 +10324,7 @@ const Gp = L({
|
|
|
10317
10324
|
preLoading: !1,
|
|
10318
10325
|
showChart: !1,
|
|
10319
10326
|
apiUrl: "",
|
|
10320
|
-
isDark:
|
|
10327
|
+
isDark: re(),
|
|
10321
10328
|
useUserState: this.$props.userState
|
|
10322
10329
|
};
|
|
10323
10330
|
},
|
|
@@ -10331,7 +10338,7 @@ const Gp = L({
|
|
|
10331
10338
|
},
|
|
10332
10339
|
computed: {
|
|
10333
10340
|
color() {
|
|
10334
|
-
return
|
|
10341
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10335
10342
|
},
|
|
10336
10343
|
dataChart() {
|
|
10337
10344
|
const e = {}, t = this.rawData.map((l) => {
|
|
@@ -10376,7 +10383,7 @@ const Gp = L({
|
|
|
10376
10383
|
async initdata() {
|
|
10377
10384
|
const e = {
|
|
10378
10385
|
providerId: this.sqlId,
|
|
10379
|
-
providerType:
|
|
10386
|
+
providerType: ue.SQL,
|
|
10380
10387
|
params: this.params
|
|
10381
10388
|
};
|
|
10382
10389
|
if (this.rawData = [], this.loadEnable) {
|
|
@@ -10413,7 +10420,7 @@ const Gp = L({
|
|
|
10413
10420
|
grid: {
|
|
10414
10421
|
display: this.gridDisplay,
|
|
10415
10422
|
color: function(e) {
|
|
10416
|
-
return
|
|
10423
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10417
10424
|
}
|
|
10418
10425
|
},
|
|
10419
10426
|
...this.scalesXCustom
|
|
@@ -10427,7 +10434,7 @@ const Gp = L({
|
|
|
10427
10434
|
grid: {
|
|
10428
10435
|
display: this.gridDisplay,
|
|
10429
10436
|
color: function(e) {
|
|
10430
|
-
return
|
|
10437
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10431
10438
|
}
|
|
10432
10439
|
},
|
|
10433
10440
|
...this.scalesYCustom
|
|
@@ -10450,7 +10457,7 @@ const Gp = L({
|
|
|
10450
10457
|
grid: {
|
|
10451
10458
|
display: this.gridDisplay,
|
|
10452
10459
|
color: function(e) {
|
|
10453
|
-
return
|
|
10460
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10454
10461
|
}
|
|
10455
10462
|
}
|
|
10456
10463
|
},
|
|
@@ -10463,7 +10470,7 @@ const Gp = L({
|
|
|
10463
10470
|
grid: {
|
|
10464
10471
|
display: this.gridDisplay,
|
|
10465
10472
|
color: function(e) {
|
|
10466
|
-
return
|
|
10473
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10467
10474
|
}
|
|
10468
10475
|
}
|
|
10469
10476
|
}
|
|
@@ -10493,7 +10500,7 @@ function Yp(e, t, a, l, o, i) {
|
|
|
10493
10500
|
], 64))
|
|
10494
10501
|
], 4);
|
|
10495
10502
|
}
|
|
10496
|
-
const
|
|
10503
|
+
const bg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
10497
10504
|
name: "SdApexChart",
|
|
10498
10505
|
components: { ApexChart: yn },
|
|
10499
10506
|
props: {
|
|
@@ -10625,7 +10632,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10625
10632
|
preLoading: !1,
|
|
10626
10633
|
showChart: !1,
|
|
10627
10634
|
apiUrl: "",
|
|
10628
|
-
isDark:
|
|
10635
|
+
isDark: re(),
|
|
10629
10636
|
useUserState: this.$props.userState
|
|
10630
10637
|
};
|
|
10631
10638
|
},
|
|
@@ -10639,7 +10646,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10639
10646
|
},
|
|
10640
10647
|
computed: {
|
|
10641
10648
|
color() {
|
|
10642
|
-
return
|
|
10649
|
+
return re().value ? "#414243" : "#e4e7ed";
|
|
10643
10650
|
},
|
|
10644
10651
|
dataChart() {
|
|
10645
10652
|
let e = [];
|
|
@@ -10683,7 +10690,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10683
10690
|
async initdata() {
|
|
10684
10691
|
const e = {
|
|
10685
10692
|
providerId: this.sqlId,
|
|
10686
|
-
providerType:
|
|
10693
|
+
providerType: ue.SQL,
|
|
10687
10694
|
params: this.params
|
|
10688
10695
|
};
|
|
10689
10696
|
if (this.rawData = [], this.loadEnable) {
|
|
@@ -10716,7 +10723,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10716
10723
|
},
|
|
10717
10724
|
grid: {
|
|
10718
10725
|
show: this.gridDisplay,
|
|
10719
|
-
borderColor:
|
|
10726
|
+
borderColor: re().value ? "#414243" : "#e4e7ed",
|
|
10720
10727
|
...this.gridCustom
|
|
10721
10728
|
},
|
|
10722
10729
|
dataLabels: {
|
|
@@ -10730,10 +10737,10 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10730
10737
|
text: this.scalesXLabel
|
|
10731
10738
|
},
|
|
10732
10739
|
axisBorder: {
|
|
10733
|
-
color:
|
|
10740
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10734
10741
|
},
|
|
10735
10742
|
axisTicks: {
|
|
10736
|
-
color:
|
|
10743
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10737
10744
|
},
|
|
10738
10745
|
...this.scalesXCustom
|
|
10739
10746
|
},
|
|
@@ -10743,10 +10750,10 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10743
10750
|
text: this.scalesYLabel
|
|
10744
10751
|
},
|
|
10745
10752
|
axisBorder: {
|
|
10746
|
-
color:
|
|
10753
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10747
10754
|
},
|
|
10748
10755
|
axisTicks: {
|
|
10749
|
-
color:
|
|
10756
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10750
10757
|
},
|
|
10751
10758
|
...this.scalesYCustom
|
|
10752
10759
|
},
|
|
@@ -10755,7 +10762,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10755
10762
|
theme: "dark"
|
|
10756
10763
|
},
|
|
10757
10764
|
theme: {
|
|
10758
|
-
mode:
|
|
10765
|
+
mode: re().value ? "dark" : "light"
|
|
10759
10766
|
},
|
|
10760
10767
|
...this.customOptions
|
|
10761
10768
|
};
|
|
@@ -10783,7 +10790,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10783
10790
|
},
|
|
10784
10791
|
grid: {
|
|
10785
10792
|
show: this.gridDisplay,
|
|
10786
|
-
borderColor:
|
|
10793
|
+
borderColor: re().value ? "#414243" : "#e4e7ed",
|
|
10787
10794
|
...this.gridCustom
|
|
10788
10795
|
},
|
|
10789
10796
|
xaxis: {
|
|
@@ -10793,10 +10800,10 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10793
10800
|
text: this.scalesXLabel
|
|
10794
10801
|
},
|
|
10795
10802
|
axisBorder: {
|
|
10796
|
-
color:
|
|
10803
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10797
10804
|
},
|
|
10798
10805
|
axisTicks: {
|
|
10799
|
-
color:
|
|
10806
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10800
10807
|
},
|
|
10801
10808
|
...this.scalesXCustom
|
|
10802
10809
|
},
|
|
@@ -10806,10 +10813,10 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10806
10813
|
text: this.scalesYLabel
|
|
10807
10814
|
},
|
|
10808
10815
|
axisBorder: {
|
|
10809
|
-
color:
|
|
10816
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10810
10817
|
},
|
|
10811
10818
|
axisTicks: {
|
|
10812
|
-
color:
|
|
10819
|
+
color: re().value ? "#414243" : "#e4e7ed"
|
|
10813
10820
|
},
|
|
10814
10821
|
...this.scalesYCustom
|
|
10815
10822
|
},
|
|
@@ -10818,7 +10825,7 @@ const cg = /* @__PURE__ */ B(Gp, [["render", Yp]]), Jp = L({
|
|
|
10818
10825
|
theme: "dark"
|
|
10819
10826
|
},
|
|
10820
10827
|
theme: {
|
|
10821
|
-
mode:
|
|
10828
|
+
mode: re().value ? "dark" : "light"
|
|
10822
10829
|
},
|
|
10823
10830
|
...this.customOptions
|
|
10824
10831
|
};
|
|
@@ -10846,7 +10853,7 @@ function Xp(e, t, a, l, o, i) {
|
|
|
10846
10853
|
], 64))
|
|
10847
10854
|
], 4);
|
|
10848
10855
|
}
|
|
10849
|
-
const
|
|
10856
|
+
const gg = /* @__PURE__ */ B(Jp, [["render", Xp]]), Qp = L({
|
|
10850
10857
|
name: "SdExportData",
|
|
10851
10858
|
emits: ["update:modelValue", "change"],
|
|
10852
10859
|
props: {
|
|
@@ -10938,7 +10945,7 @@ const bg = /* @__PURE__ */ B(Jp, [["render", Xp]]), Qp = L({
|
|
|
10938
10945
|
this.showFile = !1;
|
|
10939
10946
|
const e = `export/${this.userState.user?.username}`;
|
|
10940
10947
|
let t = { filePath: this.filePath, fileName: this.fName, fileType: "json", fileGroup: e, fileId: "" };
|
|
10941
|
-
await
|
|
10948
|
+
await ce.delete(`${this.userState.host}/v1/files/remove-one`, {
|
|
10942
10949
|
data: t,
|
|
10943
10950
|
headers: {
|
|
10944
10951
|
Authorization: `Bearer ${this.userState.user?.token}`
|
|
@@ -10987,7 +10994,7 @@ function tm(e, t, a, l, o, i) {
|
|
|
10987
10994
|
])
|
|
10988
10995
|
]),
|
|
10989
10996
|
default: s(() => [
|
|
10990
|
-
|
|
10997
|
+
he(e.$slots, "popup", {}, () => [
|
|
10991
10998
|
t[2] || (t[2] = S(" Download click here => ", -1)),
|
|
10992
10999
|
e.showFile ? (n(), p(m, {
|
|
10993
11000
|
key: 0,
|
|
@@ -11209,14 +11216,14 @@ const yo = /* @__PURE__ */ B(im, [["render", nm]]), sm = L({
|
|
|
11209
11216
|
l[`{{${o}}}`] = Ae(t[o], o, this.formModel);
|
|
11210
11217
|
if (a.expressions)
|
|
11211
11218
|
try {
|
|
11212
|
-
const i = `return ${
|
|
11219
|
+
const i = `return ${se(a.expressions, l)}`, d = new Function("row", ...De, i);
|
|
11213
11220
|
l["{{expressions}}"] = d.call(this.formModel, t);
|
|
11214
11221
|
} catch (o) {
|
|
11215
11222
|
l["{{expressions}}"] = o;
|
|
11216
11223
|
}
|
|
11217
11224
|
else
|
|
11218
11225
|
l["{{expressions}}"] = "";
|
|
11219
|
-
return Tt(
|
|
11226
|
+
return Tt(se(e, l));
|
|
11220
11227
|
};
|
|
11221
11228
|
},
|
|
11222
11229
|
columnFields() {
|
|
@@ -11256,11 +11263,11 @@ const yo = /* @__PURE__ */ B(im, [["render", nm]]), sm = L({
|
|
|
11256
11263
|
return l;
|
|
11257
11264
|
},
|
|
11258
11265
|
getValue(e, t, a) {
|
|
11259
|
-
let l =
|
|
11266
|
+
let l = de(e, t);
|
|
11260
11267
|
return this.rawValue ? l ?? null : Ae(l, t, a);
|
|
11261
11268
|
},
|
|
11262
11269
|
getValueType(e, t, a) {
|
|
11263
|
-
let l =
|
|
11270
|
+
let l = de(e, t);
|
|
11264
11271
|
if (this.rawValue)
|
|
11265
11272
|
return l ?? null;
|
|
11266
11273
|
if (typeof l == "boolean")
|
|
@@ -11499,7 +11506,7 @@ function um(e, t, a, l, o, i) {
|
|
|
11499
11506
|
_: 2
|
|
11500
11507
|
}, 1032, ["prop", "column-key", "label", "width", "align", "sortable", "filters", "fixed"]))), 256)) : g("", !0)
|
|
11501
11508
|
], 64)),
|
|
11502
|
-
|
|
11509
|
+
he(e.$slots, "default"),
|
|
11503
11510
|
e.systemColumn ? (n(), w(E, { key: 2 }, [
|
|
11504
11511
|
e.formModel && e.formModel.form_options && e.formModel.form_options.query_tool != "disable" ? (n(), p(u, {
|
|
11505
11512
|
key: 0,
|
|
@@ -11751,7 +11758,7 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
11751
11758
|
useUserState: this.$props.userState,
|
|
11752
11759
|
showExport: !1,
|
|
11753
11760
|
showRawValue: !1,
|
|
11754
|
-
dpFormData: { providerId: this.formId, providerType:
|
|
11761
|
+
dpFormData: { providerId: this.formId, providerType: ue.FORM },
|
|
11755
11762
|
dpExpandData: null,
|
|
11756
11763
|
isExpand: !1,
|
|
11757
11764
|
expandedRows: [],
|
|
@@ -11762,7 +11769,7 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
11762
11769
|
widgetId: "SdCrudGrid-" + Rt(),
|
|
11763
11770
|
dpExportRow: {
|
|
11764
11771
|
providerId: "",
|
|
11765
|
-
providerType:
|
|
11772
|
+
providerType: ue.FORM,
|
|
11766
11773
|
options: { where: "_id = CONVERT(:id, 'objectId')" },
|
|
11767
11774
|
params: { id: "" }
|
|
11768
11775
|
},
|
|
@@ -11874,13 +11881,13 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
11874
11881
|
this.defaultParams = { ...t, ...e }, this.defaultSort = D(this.optionProvider.orderBy), this.dpFormData.params = D(this.defaultParams), this.getDataList(this.dpFormData);
|
|
11875
11882
|
},
|
|
11876
11883
|
initForm(e) {
|
|
11877
|
-
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType =
|
|
11884
|
+
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType = ue.FORM), this.dpFormData.params || (this.dpFormData.params = {}), this.dpFormData.options ? (this.dpFormData.options.page || (this.dpFormData.options.page = 1), this.dpFormData.options.limit ? this.limit = this.dpFormData.options.limit : this.dpFormData.options.limit = this.limit, this.optionProvider = this.dpFormData.options) : this.dpFormData.options = this.optionProvider, this.parentId != "" && (this.params.xparentx = this.parentId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND xparentx = CONVERT(:xparentx, 'objectId')" : this.dpFormData.options.where = "xparentx = CONVERT(:xparentx, 'objectId')"), this.searchFields ? this.dpFormData.options.search = this.searchFields : this.dpFormData.options.search = this.sdformModel.form_options.search_fields ? this.sdformModel.form_options.search_fields : [];
|
|
11878
11885
|
const t = D(this.dpFormData.params), a = D(this.params);
|
|
11879
11886
|
if (this.defaultParams = { ...a, ...t }, this.defaultSort = D(this.optionProvider.orderBy), this.dpFormData.params = D(this.defaultParams), this.sumColumn && Object.values(this.sumColumn).length > 0 && (this.dpFormData.options.sum = this.sumColumn), this.groupKey)
|
|
11880
11887
|
if (this.expandProvider)
|
|
11881
11888
|
this.dpExpandData = D(this.expandProvider);
|
|
11882
11889
|
else {
|
|
11883
|
-
if (this.dpExpandData = { providerId: this.formId, providerType:
|
|
11890
|
+
if (this.dpExpandData = { providerId: this.formId, providerType: ue.FORM }, this.dpFormData.options.select && this.dpFormData.options.select.length > 0) {
|
|
11884
11891
|
const l = [`\`${this.groupKey}\``, `\`${this.groupKey}\` AS \`${this.rowKey}\``, `COUNT(*) AS \`${this.expandCountChildrenName}\``];
|
|
11885
11892
|
this.dpFormData.options.select.push(...l);
|
|
11886
11893
|
} else
|
|
@@ -11888,9 +11895,9 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
11888
11895
|
if (this.aggrColumn && Object.values(this.aggrColumn).length > 0 && this.dpFormData.options.select.push(...this.aggrColumn), this.sumColumn && Object.values(this.sumColumn).length > 0)
|
|
11889
11896
|
for (const l of this.sumColumn)
|
|
11890
11897
|
this.dpFormData.options.select.push(`SUM(\`${l}\`) AS \`${l}\``);
|
|
11891
|
-
this.dpExpandData.options || (this.dpExpandData.options = {}), this.dpExpandData.options.select = ["*", `\`${this.keyId}\` AS \`${this.rowKey}\``], this.dpExpandData.options.where = `\`${this.groupKey}\` = :xgidx`, this.dpFormData.options.groupBy = [`\`${this.groupKey}\``], this.dpFormData.options.orderBy = [{ column: `\`${this.groupKey}\``, sort:
|
|
11898
|
+
this.dpExpandData.options || (this.dpExpandData.options = {}), this.dpExpandData.options.select = ["*", `\`${this.keyId}\` AS \`${this.rowKey}\``], this.dpExpandData.options.where = `\`${this.groupKey}\` = :xgidx`, this.dpFormData.options.groupBy = [`\`${this.groupKey}\``], this.dpFormData.options.orderBy = [{ column: `\`${this.groupKey}\``, sort: fe.ASC }];
|
|
11892
11899
|
}
|
|
11893
|
-
this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort:
|
|
11900
|
+
this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort: fe.DESC }], this.defaultSort = [{ column: "created_at", sort: fe.DESC }]), this.dpExportRow.providerId = this.formId, this.getDataList(this.dpFormData), this.enableWs && this.sdformModel.form_options && this.sdformModel.form_options.enable_websocket && (this.wsConn = this.userState.connectWebSocket("gridform", this.sdformModel.dataid, this.widgetId, (l) => {
|
|
11894
11901
|
if (l.from != "server" && (l.from != this.userState.user?.username || l.params && l.params.widget && l.params.widget !== this.widgetId)) {
|
|
11895
11902
|
let o = -1;
|
|
11896
11903
|
const i = D(l.data), d = l.params ? D(l.params) : null;
|
|
@@ -11945,7 +11952,7 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
11945
11952
|
if (this.dpExpandData) {
|
|
11946
11953
|
this.dpExpandData.params || (this.dpExpandData.params ? this.dpExpandData.params = { ...this.dpExpandData.params, ...e } : this.dpExpandData.params = D(e));
|
|
11947
11954
|
const l = this.groupKey;
|
|
11948
|
-
l && e[l] != null && e[l] != null && (this.dpExpandData.params.xgidx = e[l],
|
|
11955
|
+
l && e[l] != null && e[l] != null && (this.dpExpandData.params.xgidx = e[l], ce.post(
|
|
11949
11956
|
`${this.userState.host}/widget/crud/getdata-all`,
|
|
11950
11957
|
{
|
|
11951
11958
|
sdProvider: this.dpExpandData,
|
|
@@ -12116,7 +12123,7 @@ const pm = /* @__PURE__ */ B(sm, [["render", um]]), mm = L({
|
|
|
12116
12123
|
}
|
|
12117
12124
|
},
|
|
12118
12125
|
handleSort(e) {
|
|
12119
|
-
this.optionProvider.orderBy = this.defaultSort, e.order !== null && (this.defaultSort ? this.optionProvider.orderBy.push({ column: `\`${e.prop}\``, sort: e.order == "descending" ?
|
|
12126
|
+
this.optionProvider.orderBy = this.defaultSort, e.order !== null && (this.defaultSort ? this.optionProvider.orderBy.push({ column: `\`${e.prop}\``, sort: e.order == "descending" ? fe.DESC : fe.ASC }) : this.optionProvider.orderBy = [{ column: `\`${e.prop}\``, sort: e.order == "descending" ? fe.DESC : fe.ASC }]), this.dpExpandData && this.resetExpand(), this.getDataList(this.dpFormData);
|
|
12120
12127
|
},
|
|
12121
12128
|
handleSearch() {
|
|
12122
12129
|
this.searchText != "" ? this.dpFormData.params.q = `%${this.searchText}%` : delete this.dpFormData.params.q, this.dpExpandData && this.resetExpand(), this.total = 0, this.getDataList(this.dpFormData);
|
|
@@ -12266,7 +12273,7 @@ function wm(e, t, a, l, o, i) {
|
|
|
12266
12273
|
_: 1
|
|
12267
12274
|
}),
|
|
12268
12275
|
P("span", bm, [
|
|
12269
|
-
|
|
12276
|
+
he(e.$slots, "actionsBar", {}, void 0, !0)
|
|
12270
12277
|
])
|
|
12271
12278
|
])) : g("", !0),
|
|
12272
12279
|
r(f, { gutter: 20 }, {
|
|
@@ -12294,7 +12301,7 @@ function wm(e, t, a, l, o, i) {
|
|
|
12294
12301
|
_: 1
|
|
12295
12302
|
}, 8, ["onClick"])) : g("", !0),
|
|
12296
12303
|
t[6] || (t[6] = S()),
|
|
12297
|
-
|
|
12304
|
+
he(e.$slots, "actions", {}, void 0, !0),
|
|
12298
12305
|
e.rawdataBtnEnable ? (n(), p(b, {
|
|
12299
12306
|
key: 1,
|
|
12300
12307
|
direction: "vertical",
|
|
@@ -12372,7 +12379,7 @@ function wm(e, t, a, l, o, i) {
|
|
|
12372
12379
|
style: { display: "inline-flex" }
|
|
12373
12380
|
}, {
|
|
12374
12381
|
default: s(() => [
|
|
12375
|
-
|
|
12382
|
+
he(e.$slots, "actionsPager", {}, () => [
|
|
12376
12383
|
e.total > e.limit ? (n(), p(M, {
|
|
12377
12384
|
key: 0,
|
|
12378
12385
|
class: "mb-2",
|
|
@@ -12508,14 +12515,14 @@ function wm(e, t, a, l, o, i) {
|
|
|
12508
12515
|
]),
|
|
12509
12516
|
_: 2
|
|
12510
12517
|
}, 1024)) : g("", !0),
|
|
12511
|
-
|
|
12518
|
+
he(e.$slots, "actionBtnRow", {
|
|
12512
12519
|
row: T.row,
|
|
12513
12520
|
index: T.$index
|
|
12514
12521
|
}, void 0, !0)
|
|
12515
12522
|
]),
|
|
12516
12523
|
_: 3
|
|
12517
12524
|
}, 8, ["label", "width"])) : g("", !0),
|
|
12518
|
-
|
|
12525
|
+
he(e.$slots, "actionColumn", {}, void 0, !0),
|
|
12519
12526
|
e.indexColumn ? (n(), p(k, {
|
|
12520
12527
|
key: 1,
|
|
12521
12528
|
type: "index",
|
|
@@ -12538,7 +12545,7 @@ function wm(e, t, a, l, o, i) {
|
|
|
12538
12545
|
"raw-value": e.showRawValue
|
|
12539
12546
|
}, {
|
|
12540
12547
|
default: s(() => [
|
|
12541
|
-
|
|
12548
|
+
he(e.$slots, "default", {}, void 0, !0)
|
|
12542
12549
|
]),
|
|
12543
12550
|
_: 3
|
|
12544
12551
|
}, 8, ["form-model", "display-fields", "subform-width", "system-column", "edit-column", "key-id", "row-key", "user-state", "after-save", "raw-value"])) : g("", !0)
|
|
@@ -13336,7 +13343,7 @@ const Tm = /* @__PURE__ */ B(Dm, [["render", $m]]), Mm = L({
|
|
|
13336
13343
|
t = Nu(o, e, this.valueField, this.labelField, this.labelTemplate);
|
|
13337
13344
|
} else {
|
|
13338
13345
|
let o = this.itemsList.find((i) => !!i.value && i.value == e);
|
|
13339
|
-
o
|
|
13346
|
+
o.label && (t = o.label);
|
|
13340
13347
|
}
|
|
13341
13348
|
let a = {};
|
|
13342
13349
|
if (this.refField) {
|
|
@@ -13352,14 +13359,14 @@ const Tm = /* @__PURE__ */ B(Dm, [["render", $m]]), Mm = L({
|
|
|
13352
13359
|
return i[this.valueField];
|
|
13353
13360
|
}
|
|
13354
13361
|
}), this.refField.forEach((i) => {
|
|
13355
|
-
const d =
|
|
13362
|
+
const d = de(o, i);
|
|
13356
13363
|
$a(a, i, d);
|
|
13357
13364
|
});
|
|
13358
13365
|
}
|
|
13359
13366
|
let l = {};
|
|
13360
13367
|
if (this.joinerObject && this.itemSelected) {
|
|
13361
13368
|
let o;
|
|
13362
|
-
if (this.fieldName ? o =
|
|
13369
|
+
if (this.fieldName ? o = de(this.itemSelected, this.fieldName) : this.formModel.joiner_field.joiner_enable && (o = de(this.itemSelected, this.formModel.joiner_field.field_name)), o) {
|
|
13363
13370
|
const i = D(o);
|
|
13364
13371
|
let d = 1;
|
|
13365
13372
|
for (const u in i) {
|
|
@@ -13398,17 +13405,18 @@ const Tm = /* @__PURE__ */ B(Dm, [["render", $m]]), Mm = L({
|
|
|
13398
13405
|
getItemsList(e) {
|
|
13399
13406
|
let t = "", a = [], l = ga(e);
|
|
13400
13407
|
this.labelField.forEach((d) => {
|
|
13401
|
-
|
|
13402
|
-
|
|
13408
|
+
const u = de(e, d);
|
|
13409
|
+
u ? (a.push(u), l[`{{${d}}}`] = u) : l[`{{${d}}}`] = "";
|
|
13410
|
+
}), this.labelTemplate && this.labelTemplate != "" ? t = se(this.labelTemplate, l) : t = a.join(" "), this.optionsTemplate && this.optionsTemplate != "" && (this.optionsUi[e[this.valueField]] = se(this.optionsTemplate, l));
|
|
13403
13411
|
let o = {};
|
|
13404
13412
|
this.refField && this.refField.forEach((d) => {
|
|
13405
|
-
const u =
|
|
13413
|
+
const u = de(e, d);
|
|
13406
13414
|
$a(o, d, u);
|
|
13407
13415
|
});
|
|
13408
13416
|
let i = {};
|
|
13409
13417
|
if (this.joinerObject) {
|
|
13410
13418
|
let d;
|
|
13411
|
-
if (this.fieldName ? d =
|
|
13419
|
+
if (this.fieldName ? d = de(e, this.fieldName) : this.formModel.joiner_field.joiner_enable && (d = de(e, this.formModel.joiner_field.field_name)), d) {
|
|
13412
13420
|
const u = D(d);
|
|
13413
13421
|
let m = 1;
|
|
13414
13422
|
for (const h in u) {
|
|
@@ -13421,7 +13429,7 @@ const Tm = /* @__PURE__ */ B(Dm, [["render", $m]]), Mm = L({
|
|
|
13421
13429
|
return { value: e[this.valueField], label: t, ...i, ...o };
|
|
13422
13430
|
},
|
|
13423
13431
|
async getDataAll(e, t) {
|
|
13424
|
-
this.loading = !0, await
|
|
13432
|
+
this.loading = !0, await ce.post(
|
|
13425
13433
|
`${this.apiUrl}/widget/crud/getdata-all`,
|
|
13426
13434
|
{
|
|
13427
13435
|
sdProvider: e,
|
|
@@ -13439,7 +13447,7 @@ const Tm = /* @__PURE__ */ B(Dm, [["render", $m]]), Mm = L({
|
|
|
13439
13447
|
});
|
|
13440
13448
|
},
|
|
13441
13449
|
async getDataOne(e, t) {
|
|
13442
|
-
this.loading = !0, await
|
|
13450
|
+
this.loading = !0, await ce.post(
|
|
13443
13451
|
`${this.apiUrl}/widget/crud/getdata-one`,
|
|
13444
13452
|
{ sdProvider: e },
|
|
13445
13453
|
{
|
|
@@ -13483,7 +13491,7 @@ function Nm(e, t, a, l, o, i) {
|
|
|
13483
13491
|
onVisibleChange: e.handleVisibleChange
|
|
13484
13492
|
}, tt({
|
|
13485
13493
|
prefix: s(() => [
|
|
13486
|
-
|
|
13494
|
+
he(e.$slots, "prefix")
|
|
13487
13495
|
]),
|
|
13488
13496
|
label: s(({ label: h, value: b }) => [
|
|
13489
13497
|
P("div", {
|
|
@@ -13861,7 +13869,7 @@ function Bm(e, t, a, l, o, i) {
|
|
|
13861
13869
|
} : void 0
|
|
13862
13870
|
]), 1032, ["modelValue", "multiple", "allow-create", "placeholder", "enable-object-type", "disabled", "data-provider", "value-field", "search-field", "label-field", "ref-field", "limit", "label-template", "options-template", "user-state", "onRemoteMethod", "onVisibleChange", "onChange"]);
|
|
13863
13871
|
}
|
|
13864
|
-
const
|
|
13872
|
+
const yg = /* @__PURE__ */ B(Em, [["render", Bm]]), jm = L({
|
|
13865
13873
|
name: "SdCrudSelectSubForm",
|
|
13866
13874
|
components: {
|
|
13867
13875
|
// SdSelectRemoteList,
|
|
@@ -14391,13 +14399,13 @@ const Rm = /* @__PURE__ */ B(jm, [["render", Um]]), vo = /* @__PURE__ */ L({
|
|
|
14391
14399
|
}
|
|
14392
14400
|
} else if (l.dataObjectMode = !0, l.disableAction = Object.keys(a.dataObject).length === 0 && !!a.path, !l.disableAction)
|
|
14393
14401
|
for (const c in a.dataObject) {
|
|
14394
|
-
const M = a.dataObject[c], f =
|
|
14402
|
+
const M = a.dataObject[c], f = de(M, a.path);
|
|
14395
14403
|
if (a.prefixProp) {
|
|
14396
|
-
const k =
|
|
14404
|
+
const k = de(M, a.prefixProp);
|
|
14397
14405
|
_ = k || a.prefixProp, a.sqlTag && (_ = `\`${_}\``);
|
|
14398
14406
|
}
|
|
14399
14407
|
if (a.groupField) {
|
|
14400
|
-
const k =
|
|
14408
|
+
const k = de(M, a.groupField);
|
|
14401
14409
|
C = k ? "----- " + k + " -----" : "----- " + c + " -----";
|
|
14402
14410
|
}
|
|
14403
14411
|
let y = [];
|
|
@@ -14413,7 +14421,7 @@ const Rm = /* @__PURE__ */ B(jm, [["render", Um]]), vo = /* @__PURE__ */ L({
|
|
|
14413
14421
|
let I = F.join(" ");
|
|
14414
14422
|
if (a.labelTemplate !== "") {
|
|
14415
14423
|
const V = ga(A);
|
|
14416
|
-
I =
|
|
14424
|
+
I = se(a.labelTemplate, V);
|
|
14417
14425
|
}
|
|
14418
14426
|
y.push({
|
|
14419
14427
|
value: q,
|
|
@@ -15270,7 +15278,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15270
15278
|
formDataDic: {},
|
|
15271
15279
|
popupWidthParent: "70%",
|
|
15272
15280
|
popupWidthDic: "80%",
|
|
15273
|
-
isDark:
|
|
15281
|
+
isDark: re(),
|
|
15274
15282
|
popSubSchema: {},
|
|
15275
15283
|
versionDescription: t.versionDescription,
|
|
15276
15284
|
activeCommt: "0",
|
|
@@ -15324,7 +15332,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15324
15332
|
const M = () => {
|
|
15325
15333
|
t.joinerField.order_by.push({
|
|
15326
15334
|
column: "",
|
|
15327
|
-
sort:
|
|
15335
|
+
sort: fe.ASC
|
|
15328
15336
|
});
|
|
15329
15337
|
}, f = (U, v) => {
|
|
15330
15338
|
t.joinerField.order_by.splice(v, 1);
|
|
@@ -15332,7 +15340,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15332
15340
|
if (U !== "") {
|
|
15333
15341
|
const v = {
|
|
15334
15342
|
providerId: "getsdform-all",
|
|
15335
|
-
providerType:
|
|
15343
|
+
providerType: ue.SYS,
|
|
15336
15344
|
params: { form_license: t.formLicense },
|
|
15337
15345
|
options: {
|
|
15338
15346
|
fileterObjectId: ["_id"],
|
|
@@ -15364,17 +15372,17 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15364
15372
|
a.subSchema = [];
|
|
15365
15373
|
if (a.formSelect.joiner_field && a.formSelect.joiner_field.form_id && a.formSelect.joiner_field.joiner_enable) {
|
|
15366
15374
|
const W = D(a.formSelect.joiner_field.form_id), J = D(a.formSelect.joiner_field.ref_form);
|
|
15367
|
-
let
|
|
15375
|
+
let pe = 1, je = {};
|
|
15368
15376
|
if (J) {
|
|
15369
15377
|
for (const nt in J)
|
|
15370
|
-
|
|
15378
|
+
pe++;
|
|
15371
15379
|
je = {
|
|
15372
|
-
[`xtbxlv${
|
|
15380
|
+
[`xtbxlv${pe}_xfx_id`]: W.value,
|
|
15373
15381
|
...J
|
|
15374
15382
|
};
|
|
15375
15383
|
} else
|
|
15376
15384
|
je = {
|
|
15377
|
-
[`xtbxlv${
|
|
15385
|
+
[`xtbxlv${pe}_xfx_id`]: W.value
|
|
15378
15386
|
};
|
|
15379
15387
|
t.joinerField.ref_form = D(je);
|
|
15380
15388
|
}
|
|
@@ -15393,7 +15401,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15393
15401
|
if (v && U !== "") {
|
|
15394
15402
|
let W = {
|
|
15395
15403
|
providerId: "getsdform-one",
|
|
15396
|
-
providerType:
|
|
15404
|
+
providerType: ue.SYS,
|
|
15397
15405
|
params: {
|
|
15398
15406
|
id: U
|
|
15399
15407
|
}
|
|
@@ -15483,9 +15491,9 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15483
15491
|
textType: void 0
|
|
15484
15492
|
};
|
|
15485
15493
|
else if (U.search(/xtbxlv/g) !== -1) {
|
|
15486
|
-
let J = U.split("xfx"),
|
|
15487
|
-
if (
|
|
15488
|
-
const nt =
|
|
15494
|
+
let J = U.split("xfx"), pe = U.split("lv"), je = "0";
|
|
15495
|
+
if (pe.length > 1 && pe[1]) {
|
|
15496
|
+
const nt = pe[1].split("_");
|
|
15489
15497
|
nt[0] && (je = nt[0]);
|
|
15490
15498
|
}
|
|
15491
15499
|
t.formDb.schema[W] = {
|
|
@@ -15684,9 +15692,9 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
15684
15692
|
});
|
|
15685
15693
|
}
|
|
15686
15694
|
return (U, v) => {
|
|
15687
|
-
const W = oe, J = Ll,
|
|
15695
|
+
const W = oe, J = Ll, pe = El, je = da, nt = ge, _e = ze, ie = lt, st = St, rt = Et, Ee = $e, _a = Nt, za = Ye, qa = jo, Ha = Bo, ne = qe, wo = Y("Link"), Wt = Ge, Fo = Y("Aim"), xa = Lt, Se = Dt, Mt = Ct, ct = kt, _o = va, So = Ra, ye = pt, Sa = vo, Wa = Y("InfoFilled"), ko = ra, Co = Nl, Do = Y("draggable"), Io = ut, Kt = Fe, $o = Y("sd-form-schema", !0), To = qm, Mo = zm, Po = ua;
|
|
15688
15696
|
return n(), w(E, null, [
|
|
15689
|
-
r(
|
|
15697
|
+
r(pe, {
|
|
15690
15698
|
title: "Parent Form",
|
|
15691
15699
|
column: 3,
|
|
15692
15700
|
size: "default",
|
|
@@ -16037,11 +16045,11 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
16037
16045
|
})
|
|
16038
16046
|
]),
|
|
16039
16047
|
default: s(() => [
|
|
16040
|
-
r(
|
|
16048
|
+
r(me(xl), {
|
|
16041
16049
|
modelValue: $.countSite,
|
|
16042
16050
|
"onUpdate:modelValue": (Q) => $.countSite = Q,
|
|
16043
16051
|
"main-menu-bar": !1,
|
|
16044
|
-
mode:
|
|
16052
|
+
mode: me(Wl).tree,
|
|
16045
16053
|
style: { width: "100%" },
|
|
16046
16054
|
class: X(a.isDark ? "jse-theme-dark" : "")
|
|
16047
16055
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "mode", "class"])
|
|
@@ -16647,7 +16655,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
16647
16655
|
"onUpdate:modelValue": v[2] || (v[2] = ($) => a.versionDescription = $),
|
|
16648
16656
|
mode: "mini",
|
|
16649
16657
|
readonly: !0,
|
|
16650
|
-
"user-state":
|
|
16658
|
+
"user-state": me(m)
|
|
16651
16659
|
}, null, 8, ["modelValue", "user-state"])
|
|
16652
16660
|
]),
|
|
16653
16661
|
_: 1
|
|
@@ -16717,7 +16725,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
16717
16725
|
}, {
|
|
16718
16726
|
default: s(() => [
|
|
16719
16727
|
r(So, {
|
|
16720
|
-
"user-state":
|
|
16728
|
+
"user-state": me(m),
|
|
16721
16729
|
modelValue: e.joinerField.form_id,
|
|
16722
16730
|
"onUpdate:modelValue": v[4] || (v[4] = ($) => e.joinerField.form_id = $),
|
|
16723
16731
|
filterable: "",
|
|
@@ -16727,7 +16735,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
16727
16735
|
"enable-object-type": !0,
|
|
16728
16736
|
"joiner-object": !0,
|
|
16729
16737
|
"field-name": "joiner_field.form_id",
|
|
16730
|
-
"data-provider": { providerId: "getsdform-all", providerType:
|
|
16738
|
+
"data-provider": { providerId: "getsdform-all", providerType: me(ue).SYS, params: { form_license: e.formLicense } },
|
|
16731
16739
|
"value-field": "_id",
|
|
16732
16740
|
"search-field": ["form_name"],
|
|
16733
16741
|
"label-field": ["form_name"],
|
|
@@ -17026,7 +17034,7 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
17026
17034
|
dark: a.isDark,
|
|
17027
17035
|
class: "mb-1",
|
|
17028
17036
|
plain: "",
|
|
17029
|
-
onClick: (Q) =>
|
|
17037
|
+
onClick: (Q) => me(xm)("{{" + $.value + "}}")
|
|
17030
17038
|
}, {
|
|
17031
17039
|
default: s(() => [
|
|
17032
17040
|
S(O($.value), 1)
|
|
@@ -17163,14 +17171,14 @@ const Wm = { key: 3 }, Km = { class: "items-box" }, Gm = { class: "opt-item" },
|
|
|
17163
17171
|
}, {
|
|
17164
17172
|
default: s(() => [
|
|
17165
17173
|
(n(), p(Se, {
|
|
17166
|
-
key:
|
|
17167
|
-
label:
|
|
17168
|
-
value:
|
|
17174
|
+
key: me(fe).ASC,
|
|
17175
|
+
label: me(fe).ASC,
|
|
17176
|
+
value: me(fe).ASC
|
|
17169
17177
|
}, null, 8, ["label", "value"])),
|
|
17170
17178
|
(n(), p(Se, {
|
|
17171
|
-
key:
|
|
17172
|
-
label:
|
|
17173
|
-
value:
|
|
17179
|
+
key: me(fe).DESC,
|
|
17180
|
+
label: me(fe).DESC,
|
|
17181
|
+
value: me(fe).DESC
|
|
17174
17182
|
}, null, 8, ["label", "value"]))
|
|
17175
17183
|
]),
|
|
17176
17184
|
_: 1
|
|
@@ -17474,7 +17482,7 @@ function sf(e, t, a, l, o, i) {
|
|
|
17474
17482
|
_: 1
|
|
17475
17483
|
}, 8, ["title", "modelValue", "width", "before-close", "close-on-click-modal"]);
|
|
17476
17484
|
}
|
|
17477
|
-
const
|
|
17485
|
+
const vg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
17478
17486
|
__name: "SdDynamicInput",
|
|
17479
17487
|
props: {
|
|
17480
17488
|
modelValue: {},
|
|
@@ -17490,7 +17498,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
17490
17498
|
const a = e, l = ke({
|
|
17491
17499
|
inputType: a.inputType,
|
|
17492
17500
|
inputOptions: {},
|
|
17493
|
-
isDark:
|
|
17501
|
+
isDark: re(),
|
|
17494
17502
|
arrayList: ["multiselect-editor"],
|
|
17495
17503
|
stringList: [
|
|
17496
17504
|
"text-editor",
|
|
@@ -17708,13 +17716,13 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
17708
17716
|
onBlur: _,
|
|
17709
17717
|
onChange: h
|
|
17710
17718
|
}), null, 16, ["modelValue", "size", "predefine", "disabled"])) : g("", !0),
|
|
17711
|
-
l.inputType === "json-editor" ? (n(), p(
|
|
17719
|
+
l.inputType === "json-editor" ? (n(), p(me(xl), {
|
|
17712
17720
|
key: 11,
|
|
17713
17721
|
modelValue: u.value,
|
|
17714
17722
|
"onUpdate:modelValue": c[11] || (c[11] = (x) => u.value = x),
|
|
17715
17723
|
"main-menu-bar": !1,
|
|
17716
17724
|
"navigation-bar": !1,
|
|
17717
|
-
mode:
|
|
17725
|
+
mode: me(Wl).tree,
|
|
17718
17726
|
style: { width: "100%" },
|
|
17719
17727
|
size: e.size || void 0,
|
|
17720
17728
|
class: X(l.isDark ? "jse-theme-dark" : ""),
|
|
@@ -17796,13 +17804,13 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
17796
17804
|
], 64);
|
|
17797
17805
|
};
|
|
17798
17806
|
}
|
|
17799
|
-
}),
|
|
17807
|
+
}), wg = /* @__PURE__ */ B(rf, [["__scopeId", "data-v-3bca21e7"]]), df = {
|
|
17800
17808
|
role: "heading",
|
|
17801
17809
|
class: "el-dialog__title"
|
|
17802
17810
|
}, uf = { style: { width: "100%", "min-height": "500px", height: "500px" } }, pf = {
|
|
17803
17811
|
key: 0,
|
|
17804
17812
|
style: { color: "var(--el-color-warning)", "font-size": "9px" }
|
|
17805
|
-
},
|
|
17813
|
+
}, Fg = /* @__PURE__ */ L({
|
|
17806
17814
|
__name: "SdFormErd",
|
|
17807
17815
|
props: {
|
|
17808
17816
|
modelValue: null,
|
|
@@ -17970,7 +17978,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
17970
17978
|
]),
|
|
17971
17979
|
default: s(() => [
|
|
17972
17980
|
P("div", uf, [
|
|
17973
|
-
o.showContent ? (n(), p(
|
|
17981
|
+
o.showContent ? (n(), p(me(ni), {
|
|
17974
17982
|
key: 0,
|
|
17975
17983
|
nodes: o.nodes,
|
|
17976
17984
|
edges: o.edges,
|
|
@@ -18171,7 +18179,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
18171
18179
|
},
|
|
18172
18180
|
methods: {
|
|
18173
18181
|
async getDataList(e, t) {
|
|
18174
|
-
this.preLoading = !0, await
|
|
18182
|
+
this.preLoading = !0, await ce.post(
|
|
18175
18183
|
`${this.apiUrl}/widget/crud/getdata-all`,
|
|
18176
18184
|
{
|
|
18177
18185
|
sdProvider: e,
|
|
@@ -18192,7 +18200,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
18192
18200
|
if (e.dataid = e._id || null, this.expandProvider) {
|
|
18193
18201
|
this.expandProvider.params ? this.expandProvider.params = { ...this.expandProvider.params, ...e } : this.expandProvider.params = D(e);
|
|
18194
18202
|
const l = this.rowKey;
|
|
18195
|
-
l && e[l] != null && e[l] != null && (this.expandProvider.params.rowKey = e[l],
|
|
18203
|
+
l && e[l] != null && e[l] != null && (this.expandProvider.params.rowKey = e[l], ce.post(
|
|
18196
18204
|
`${this.apiUrl}/widget/crud/getdata-all`,
|
|
18197
18205
|
{
|
|
18198
18206
|
sdProvider: this.expandProvider,
|
|
@@ -18285,7 +18293,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
18285
18293
|
}
|
|
18286
18294
|
},
|
|
18287
18295
|
handleSort(e) {
|
|
18288
|
-
this.optionProvider.orderBy = D(this.defaultSort), e.order !== null && (this.defaultSort && this.optionProvider.orderBy ? this.optionProvider.orderBy.push({ column: `\`${e.prop}\``, sort: e.order == "descending" ?
|
|
18296
|
+
this.optionProvider.orderBy = D(this.defaultSort), e.order !== null && (this.defaultSort && this.optionProvider.orderBy ? this.optionProvider.orderBy.push({ column: `\`${e.prop}\``, sort: e.order == "descending" ? fe.DESC : fe.ASC }) : this.optionProvider.orderBy = [{ column: `\`${e.prop}\``, sort: e.order == "descending" ? fe.DESC : fe.ASC }]), this.expandProvider && this.resetExpand(), this.dataProvider.options = this.optionProvider, this.getDataList(this.dataProvider);
|
|
18289
18297
|
},
|
|
18290
18298
|
handleSearch() {
|
|
18291
18299
|
this.searchText != "" ? this.dataProvider.params.q = `%${this.searchText}%` : delete this.dataProvider.params.q, this.expandProvider && this.resetExpand(), this.getDataList(this.dataProvider);
|
|
@@ -18314,7 +18322,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
18314
18322
|
cancelButtonText: "Cancel",
|
|
18315
18323
|
type: "warning"
|
|
18316
18324
|
}).then(() => {
|
|
18317
|
-
|
|
18325
|
+
ce.delete(`${this.apiUrl}/widget/crud/delete-data`, {
|
|
18318
18326
|
headers: {
|
|
18319
18327
|
Authorization: `Bearer ${this.userState.user?.token}`
|
|
18320
18328
|
},
|
|
@@ -18337,7 +18345,7 @@ const yg = /* @__PURE__ */ B(lf, [["render", sf]]), rf = /* @__PURE__ */ L({
|
|
|
18337
18345
|
cancelButtonText: "Cancel",
|
|
18338
18346
|
type: "warning"
|
|
18339
18347
|
}).then(() => {
|
|
18340
|
-
|
|
18348
|
+
ce.put(
|
|
18341
18349
|
`${this.apiUrl}/widget/crud/update-data`,
|
|
18342
18350
|
{
|
|
18343
18351
|
id: o,
|
|
@@ -18408,7 +18416,7 @@ function Ff(e, t, a, l, o, i) {
|
|
|
18408
18416
|
_: 1
|
|
18409
18417
|
}),
|
|
18410
18418
|
P("span", bf, [
|
|
18411
|
-
|
|
18419
|
+
he(e.$slots, "actionsBar", {}, void 0, !0)
|
|
18412
18420
|
])
|
|
18413
18421
|
])) : g("", !0),
|
|
18414
18422
|
r(C, { gutter: 20 }, {
|
|
@@ -18434,7 +18442,7 @@ function Ff(e, t, a, l, o, i) {
|
|
|
18434
18442
|
_: 1
|
|
18435
18443
|
}, 8, ["onClick"])) : g("", !0),
|
|
18436
18444
|
t[4] || (t[4] = S()),
|
|
18437
|
-
|
|
18445
|
+
he(e.$slots, "actions", {}, void 0, !0),
|
|
18438
18446
|
e.totalInline ? (n(), w(E, { key: 1 }, [
|
|
18439
18447
|
r(m, {
|
|
18440
18448
|
type: "info",
|
|
@@ -18490,7 +18498,7 @@ function Ff(e, t, a, l, o, i) {
|
|
|
18490
18498
|
style: { display: "inline-flex" }
|
|
18491
18499
|
}, {
|
|
18492
18500
|
default: s(() => [
|
|
18493
|
-
|
|
18501
|
+
he(e.$slots, "actionsPager", {}, () => [
|
|
18494
18502
|
e.total > e.limit ? (n(), p(_, {
|
|
18495
18503
|
key: 0,
|
|
18496
18504
|
class: "mb-2",
|
|
@@ -18597,7 +18605,7 @@ function Ff(e, t, a, l, o, i) {
|
|
|
18597
18605
|
]),
|
|
18598
18606
|
_: 1
|
|
18599
18607
|
}, 8, ["label", "width"])) : g("", !0),
|
|
18600
|
-
|
|
18608
|
+
he(e.$slots, "default", {}, void 0, !0)
|
|
18601
18609
|
]),
|
|
18602
18610
|
_: 3
|
|
18603
18611
|
}, 8, ["data", "border", "show-summary", "summary-method", "onSortChange", "height", "max-height", "row-key", "onExpandChange", "lazy", "load", "tree-props", "onFilterChange"])), [
|
|
@@ -18633,14 +18641,14 @@ function Ff(e, t, a, l, o, i) {
|
|
|
18633
18641
|
"destroy-on-close": !0
|
|
18634
18642
|
}, {
|
|
18635
18643
|
default: s(() => [
|
|
18636
|
-
|
|
18644
|
+
he(e.$slots, "popup", {}, void 0, !0)
|
|
18637
18645
|
]),
|
|
18638
18646
|
_: 3
|
|
18639
18647
|
}, 8, ["title", "modelValue", "width", "close-on-click-modal"])
|
|
18640
18648
|
])) : g("", !0)
|
|
18641
18649
|
], 64);
|
|
18642
18650
|
}
|
|
18643
|
-
const
|
|
18651
|
+
const _g = /* @__PURE__ */ B(mf, [["render", Ff], ["__scopeId", "data-v-a6ab139e"]]), _f = L({
|
|
18644
18652
|
name: "SdGridColumnIndex",
|
|
18645
18653
|
props: {
|
|
18646
18654
|
columnLabel: {
|
|
@@ -18676,7 +18684,7 @@ function Sf(e, t, a, l, o, i) {
|
|
|
18676
18684
|
align: "center"
|
|
18677
18685
|
}, null, 8, ["index", "label", "width"]);
|
|
18678
18686
|
}
|
|
18679
|
-
const
|
|
18687
|
+
const Sg = /* @__PURE__ */ B(_f, [["render", Sf]]), kf = L({
|
|
18680
18688
|
name: "SdGridColumnDate",
|
|
18681
18689
|
props: {
|
|
18682
18690
|
columnProp: {
|
|
@@ -18729,7 +18737,7 @@ function Cf(e, t, a, l, o, i) {
|
|
|
18729
18737
|
_: 1
|
|
18730
18738
|
}, 8, ["prop", "label", "width", "sortable"]);
|
|
18731
18739
|
}
|
|
18732
|
-
const
|
|
18740
|
+
const kg = /* @__PURE__ */ B(kf, [["render", Cf]]), Df = [
|
|
18733
18741
|
{
|
|
18734
18742
|
value: "addon-api",
|
|
18735
18743
|
label: "Api"
|
|
@@ -22247,7 +22255,7 @@ function Pf(e, t, a, l, o, i) {
|
|
|
22247
22255
|
_: 1
|
|
22248
22256
|
}, 8, ["modelValue", "multiple", "allow-create", "disabled", "remote-method", "placeholder", "loading", "onChange"]);
|
|
22249
22257
|
}
|
|
22250
|
-
const
|
|
22258
|
+
const Cg = /* @__PURE__ */ B($f, [["render", Pf]]), Vf = L({
|
|
22251
22259
|
name: "OptionsItemSetting",
|
|
22252
22260
|
props: {
|
|
22253
22261
|
typeSelect: String,
|
|
@@ -22461,7 +22469,7 @@ function Bf(e, t, a, l, o, i) {
|
|
|
22461
22469
|
])) : g("", !0)
|
|
22462
22470
|
]);
|
|
22463
22471
|
}
|
|
22464
|
-
const
|
|
22472
|
+
const Dg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad"]]), jf = L({
|
|
22465
22473
|
name: "SdReport",
|
|
22466
22474
|
components: {},
|
|
22467
22475
|
props: {
|
|
@@ -22629,16 +22637,16 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22629
22637
|
const F = d[q];
|
|
22630
22638
|
let I = "";
|
|
22631
22639
|
if (F.col_field && y[F.col_field] !== null && F.col_value === null)
|
|
22632
|
-
I =
|
|
22640
|
+
I = se(`{{${F.col_field}}}`, A);
|
|
22633
22641
|
else {
|
|
22634
22642
|
if (F.col_expressions)
|
|
22635
22643
|
try {
|
|
22636
|
-
const T = `return ${
|
|
22644
|
+
const T = `return ${se(F.col_expressions, A)}`, H = new Function("row", ...De, T);
|
|
22637
22645
|
A["{{expressions}}"] = H.call(a, y);
|
|
22638
22646
|
} catch (V) {
|
|
22639
22647
|
A["{{expressions}}"] = V;
|
|
22640
22648
|
}
|
|
22641
|
-
I =
|
|
22649
|
+
I = se(F.col_value, A);
|
|
22642
22650
|
}
|
|
22643
22651
|
if (!F.col_group)
|
|
22644
22652
|
if (F.col_sum) {
|
|
@@ -22752,16 +22760,16 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22752
22760
|
const b = l[h];
|
|
22753
22761
|
let _ = "";
|
|
22754
22762
|
if (b.col_field && d[b.col_field] !== null && b.col_value === null)
|
|
22755
|
-
_ =
|
|
22763
|
+
_ = se(`{{${b.col_field}}}`, m);
|
|
22756
22764
|
else {
|
|
22757
22765
|
if (b.col_expressions)
|
|
22758
22766
|
try {
|
|
22759
|
-
const M = `return ${
|
|
22767
|
+
const M = `return ${se(b.col_expressions, m)}`, f = new Function("row", ...De, M);
|
|
22760
22768
|
m["{{expressions}}"] = f.call(a, d);
|
|
22761
22769
|
} catch (c) {
|
|
22762
22770
|
m["{{expressions}}"] = c;
|
|
22763
22771
|
}
|
|
22764
|
-
_ =
|
|
22772
|
+
_ = se(b.col_value, m);
|
|
22765
22773
|
}
|
|
22766
22774
|
if (b.col_format)
|
|
22767
22775
|
try {
|
|
@@ -22789,7 +22797,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22789
22797
|
if (e.pdf_sql && e.pdf_sql.value) {
|
|
22790
22798
|
const o = {
|
|
22791
22799
|
providerId: e.pdf_sql.value,
|
|
22792
|
-
providerType:
|
|
22800
|
+
providerType: ue.SQL,
|
|
22793
22801
|
params: t
|
|
22794
22802
|
};
|
|
22795
22803
|
e.pdf_fontsize && e.pdf_fontsize;
|
|
@@ -22806,7 +22814,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22806
22814
|
for (const [C, c] of _.entries())
|
|
22807
22815
|
if (c.content_widget) {
|
|
22808
22816
|
let M = "";
|
|
22809
|
-
if (c.content_value && (typeof c.content_value == "object" ? M = c.content_value : M =
|
|
22817
|
+
if (c.content_value && (typeof c.content_value == "object" ? M = c.content_value : M = se(c.content_value, b)), c.content_widget === "table")
|
|
22810
22818
|
if (Object.keys(e.pdf_column).length > 0) {
|
|
22811
22819
|
const f = await this.dataConvert(h, e, i);
|
|
22812
22820
|
l.push({
|
|
@@ -22832,7 +22840,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22832
22840
|
F[H];
|
|
22833
22841
|
let Z = !1;
|
|
22834
22842
|
if (k.length > 0 ? k.includes(H) && (Z = !0) : Z = !0, Z) {
|
|
22835
|
-
let x =
|
|
22843
|
+
let x = se(`{{${H}}}`, V);
|
|
22836
22844
|
y.length > 0 && typeof y[0] != "object" && y[T] && (typeof y[T] == "string" ? y[T] : String(y[T])), I[H] = x, T++;
|
|
22837
22845
|
}
|
|
22838
22846
|
}
|
|
@@ -22846,7 +22854,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22846
22854
|
} else if (c.content_widget === "sub_report" && M !== "") {
|
|
22847
22855
|
const f = {
|
|
22848
22856
|
providerId: "getreport-one",
|
|
22849
|
-
providerType:
|
|
22857
|
+
providerType: ue.SYS,
|
|
22850
22858
|
params: { reportId: M }
|
|
22851
22859
|
}, y = await Ot(f, this.useUserState);
|
|
22852
22860
|
if (y && y.response && y.data && y.data.data) {
|
|
@@ -22881,7 +22889,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22881
22889
|
if (e.pdf_sql && e.pdf_sql.value) {
|
|
22882
22890
|
const d = {
|
|
22883
22891
|
providerId: e.pdf_sql.value,
|
|
22884
|
-
providerType:
|
|
22892
|
+
providerType: ue.SQL,
|
|
22885
22893
|
params: t
|
|
22886
22894
|
}, u = e.pdf_fontsize ? e.pdf_fontsize : 14;
|
|
22887
22895
|
let m = {}, h = "";
|
|
@@ -22897,7 +22905,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22897
22905
|
for (const [f, y] of M.entries())
|
|
22898
22906
|
if (y.content_widget) {
|
|
22899
22907
|
let k = "";
|
|
22900
|
-
if (y.content_value && (typeof y.content_value == "object" ? k = y.content_value : k =
|
|
22908
|
+
if (y.content_value && (typeof y.content_value == "object" ? k = y.content_value : k = se(y.content_value, c)), y.content_widget === "text")
|
|
22901
22909
|
l.push({
|
|
22902
22910
|
text: k,
|
|
22903
22911
|
alignment: y.content_align || "left",
|
|
@@ -22986,8 +22994,8 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22986
22994
|
Be[v];
|
|
22987
22995
|
let W = !1;
|
|
22988
22996
|
if (V.length > 0 ? V.includes(v) && (W = !0) : W = !0, W) {
|
|
22989
|
-
let J =
|
|
22990
|
-
if (
|
|
22997
|
+
let J = se(`{{${v}}}`, Me), pe = I[U] || "left";
|
|
22998
|
+
if (pe === "l" || pe === "L" ? pe = "left" : pe === "c" || pe === "C" ? pe = "center" : (pe === "r" || pe === "R") && (pe = "rigth"), Z)
|
|
22991
22999
|
if (q[U] || (q[U] = "*"), F.length > 0) {
|
|
22992
23000
|
if (typeof F[0] != "object")
|
|
22993
23001
|
if (x = !0, F[U]) {
|
|
@@ -22996,7 +23004,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
22996
23004
|
text: je,
|
|
22997
23005
|
bold: !0,
|
|
22998
23006
|
fillColor: "#ddd",
|
|
22999
|
-
alignment:
|
|
23007
|
+
alignment: pe,
|
|
23000
23008
|
fontSize: u
|
|
23001
23009
|
});
|
|
23002
23010
|
} else
|
|
@@ -23004,7 +23012,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23004
23012
|
text: v,
|
|
23005
23013
|
bold: !0,
|
|
23006
23014
|
fillColor: "#ddd",
|
|
23007
|
-
alignment:
|
|
23015
|
+
alignment: pe,
|
|
23008
23016
|
fontSize: u
|
|
23009
23017
|
});
|
|
23010
23018
|
} else
|
|
@@ -23012,12 +23020,12 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23012
23020
|
text: v,
|
|
23013
23021
|
bold: !0,
|
|
23014
23022
|
fillColor: "#ddd",
|
|
23015
|
-
alignment:
|
|
23023
|
+
alignment: pe,
|
|
23016
23024
|
fontSize: u
|
|
23017
23025
|
});
|
|
23018
23026
|
et.push({
|
|
23019
23027
|
text: J,
|
|
23020
|
-
alignment:
|
|
23028
|
+
alignment: pe,
|
|
23021
23029
|
fontSize: u
|
|
23022
23030
|
}), U++;
|
|
23023
23031
|
}
|
|
@@ -23046,7 +23054,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23046
23054
|
} else if (y.content_widget === "sub_report" && k !== "") {
|
|
23047
23055
|
const A = {
|
|
23048
23056
|
providerId: "getreport-one",
|
|
23049
|
-
providerType:
|
|
23057
|
+
providerType: ue.SYS,
|
|
23050
23058
|
params: { reportId: k }
|
|
23051
23059
|
}, q = await Ot(A, this.useUserState);
|
|
23052
23060
|
if (q && q.response && q.data && q.data.data) {
|
|
@@ -23105,7 +23113,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23105
23113
|
this.reportType = t;
|
|
23106
23114
|
const a = {
|
|
23107
23115
|
providerId: "getreport-one",
|
|
23108
|
-
providerType:
|
|
23116
|
+
providerType: ue.SYS,
|
|
23109
23117
|
params: { reportId: e }
|
|
23110
23118
|
};
|
|
23111
23119
|
let l = !0;
|
|
@@ -23131,7 +23139,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23131
23139
|
let i = "output";
|
|
23132
23140
|
t.pdf_name && (i = t.pdf_name), this.createExcel(o, i);
|
|
23133
23141
|
} else if (e === "word")
|
|
23134
|
-
this.popupDownloadName = "Report", t.pdf_name && (t.pdf_name, this.popupDownloadName = "Report " + t.pdf_name), t.pdf_temp && Object.keys(t.pdf_temp).length > 0 ? (t.pdf_temp[0].url ? t.pdf_temp[0].url : "") ? await
|
|
23142
|
+
this.popupDownloadName = "Report", t.pdf_name && (t.pdf_name, this.popupDownloadName = "Report " + t.pdf_name), t.pdf_temp && Object.keys(t.pdf_temp).length > 0 ? (t.pdf_temp[0].url ? t.pdf_temp[0].url : "") ? await ce.post(
|
|
23135
23143
|
`${this.userState.host}/v1/files/create-word`,
|
|
23136
23144
|
{ reportId: t._id, params: a },
|
|
23137
23145
|
{
|
|
@@ -23295,7 +23303,7 @@ const Cg = /* @__PURE__ */ B(Vf, [["render", Bf], ["__scopeId", "data-v-cc3dcbad
|
|
|
23295
23303
|
this.showFile = !1;
|
|
23296
23304
|
const e = `export/${this.userState.user?.username}`;
|
|
23297
23305
|
let t = { filePath: this.filePath, fileName: this.fullName, fileType: "docx", fileGroup: e, fileId: "" };
|
|
23298
|
-
await
|
|
23306
|
+
await ce.delete(`${this.userState.host}/v1/files/remove-one`, {
|
|
23299
23307
|
data: t,
|
|
23300
23308
|
headers: {
|
|
23301
23309
|
Authorization: `Bearer ${this.userState.user?.token}`
|
|
@@ -23570,7 +23578,7 @@ function Wf(e, t, a, l, o, i) {
|
|
|
23570
23578
|
])) : g("", !0)
|
|
23571
23579
|
], 64);
|
|
23572
23580
|
}
|
|
23573
|
-
const
|
|
23581
|
+
const Ig = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f"]]), Kf = L({
|
|
23574
23582
|
name: "SdUiCarousel",
|
|
23575
23583
|
components: {},
|
|
23576
23584
|
props: {
|
|
@@ -23720,7 +23728,7 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23720
23728
|
limit: this.limitRow,
|
|
23721
23729
|
optionProvider: { limit: this.limitRow, page: 1 },
|
|
23722
23730
|
useUserState: this.$props.userState,
|
|
23723
|
-
dpFormData: { providerId: this.formId, providerType:
|
|
23731
|
+
dpFormData: { providerId: this.formId, providerType: ue.FORM },
|
|
23724
23732
|
wsConn: void 0,
|
|
23725
23733
|
widgetId: "SdUiCarousel-" + Rt(),
|
|
23726
23734
|
isFormEnable: this.providerType === "FORM",
|
|
@@ -23732,7 +23740,7 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23732
23740
|
return (e, t) => {
|
|
23733
23741
|
let a = {}, l = this.sdformModel.form_db.schema;
|
|
23734
23742
|
for (const o in l) {
|
|
23735
|
-
let i =
|
|
23743
|
+
let i = de(t, o);
|
|
23736
23744
|
a[`{{${o}}}`] = Ae(i, o, this.sdformModel);
|
|
23737
23745
|
}
|
|
23738
23746
|
if (this.customValue) {
|
|
@@ -23741,7 +23749,7 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23741
23749
|
let i = this.customValue[o];
|
|
23742
23750
|
if (i.expressions)
|
|
23743
23751
|
try {
|
|
23744
|
-
const u = `return ${
|
|
23752
|
+
const u = `return ${se(i.expressions, a)}`, m = new Function("row", ...De, u);
|
|
23745
23753
|
a[`{{${i.fieldName}}}`] = m.call(this.sdformModel, t);
|
|
23746
23754
|
} catch (d) {
|
|
23747
23755
|
a[`{{${i.fieldName}}}`] = d;
|
|
@@ -23750,7 +23758,7 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23750
23758
|
a[`{{${i.fieldName}}}`] = "";
|
|
23751
23759
|
}
|
|
23752
23760
|
}
|
|
23753
|
-
return Tt(
|
|
23761
|
+
return Tt(se(e, a));
|
|
23754
23762
|
};
|
|
23755
23763
|
}
|
|
23756
23764
|
},
|
|
@@ -23784,9 +23792,9 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23784
23792
|
this.defaultParams = { ...t, ...e }, this.dpFormData.params = D(this.defaultParams), this.getDataList();
|
|
23785
23793
|
},
|
|
23786
23794
|
initForm(e) {
|
|
23787
|
-
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType =
|
|
23795
|
+
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType = ue.FORM), this.dpFormData.params || (this.dpFormData.params = {}), this.dpFormData.options ? (this.dpFormData.options.page || (this.dpFormData.options.page = 1), this.dpFormData.options.limit ? this.limit = this.dpFormData.options.limit : this.dpFormData.options.limit = this.limit, this.optionProvider = this.dpFormData.options) : this.dpFormData.options = this.optionProvider, this.parentId != "" && (this.params.xparentx = this.parentId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND xparentx = CONVERT(:xparentx, 'objectId')" : this.dpFormData.options.where = "xparentx = CONVERT(:xparentx, 'objectId')");
|
|
23788
23796
|
const t = D(this.dpFormData.params), a = D(this.params);
|
|
23789
|
-
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort:
|
|
23797
|
+
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort: fe.DESC }]), this.getDataList(), this.enableWs && this.sdformModel.form_options && this.sdformModel.form_options.enable_websocket && (this.wsConn = this.userState.connectWebSocket("gridform", this.sdformModel.dataid, this.widgetId, (l) => {
|
|
23790
23798
|
if (l.from != "server" && (l.from != this.userState.user?.username || l.params && l.params.widget && l.params.widget !== this.widgetId)) {
|
|
23791
23799
|
let o = -1;
|
|
23792
23800
|
const i = D(l.data);
|
|
@@ -23824,7 +23832,7 @@ const Dg = /* @__PURE__ */ B(jf, [["render", Wf], ["__scopeId", "data-v-1702f01f
|
|
|
23824
23832
|
this.isInsert = !1, this.selectIndex = t, this.clickEvent && this.clickEvent(e, t);
|
|
23825
23833
|
},
|
|
23826
23834
|
getValue(e, t) {
|
|
23827
|
-
let a =
|
|
23835
|
+
let a = de(e, t);
|
|
23828
23836
|
return a ? Ae(a, t, this.sdformModel) : "";
|
|
23829
23837
|
},
|
|
23830
23838
|
getSchema(e) {
|
|
@@ -24025,7 +24033,7 @@ function nh(e, t, a, l, o, i) {
|
|
|
24025
24033
|
}, 8, ["indicator-position", "motionBlur", "interval", "autoplay", "direction", "type", "trigger", "height"])) : g("", !0)
|
|
24026
24034
|
], 64);
|
|
24027
24035
|
}
|
|
24028
|
-
const
|
|
24036
|
+
const $g = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de"]]), sh = L({
|
|
24029
24037
|
name: "SdUiMenu",
|
|
24030
24038
|
components: {},
|
|
24031
24039
|
props: {
|
|
@@ -24191,7 +24199,7 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24191
24199
|
limit: this.limitRow,
|
|
24192
24200
|
optionProvider: { limit: this.limitRow, page: 1 },
|
|
24193
24201
|
useUserState: this.$props.userState,
|
|
24194
|
-
dpFormData: { providerId: this.formId, providerType:
|
|
24202
|
+
dpFormData: { providerId: this.formId, providerType: ue.FORM },
|
|
24195
24203
|
wsConn: void 0,
|
|
24196
24204
|
isFormEnable: this.providerType === "FORM",
|
|
24197
24205
|
scrollerHeight: 0,
|
|
@@ -24205,7 +24213,7 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24205
24213
|
return (e, t) => {
|
|
24206
24214
|
let a = {}, l = this.sdformModel.form_db.schema;
|
|
24207
24215
|
for (const o in l) {
|
|
24208
|
-
let i =
|
|
24216
|
+
let i = de(t, o);
|
|
24209
24217
|
a[`{{${o}}}`] = Ae(i, o, this.sdformModel);
|
|
24210
24218
|
}
|
|
24211
24219
|
if (this.customValue) {
|
|
@@ -24214,7 +24222,7 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24214
24222
|
let i = this.customValue[o];
|
|
24215
24223
|
if (i.expressions)
|
|
24216
24224
|
try {
|
|
24217
|
-
const u = `return ${
|
|
24225
|
+
const u = `return ${se(i.expressions, a)}`, m = new Function("row", ...De, u);
|
|
24218
24226
|
a[`{{${i.fieldName}}}`] = m.call(this.sdformModel, t);
|
|
24219
24227
|
} catch (d) {
|
|
24220
24228
|
a[`{{${i.fieldName}}}`] = d;
|
|
@@ -24223,7 +24231,7 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24223
24231
|
a[`{{${i.fieldName}}}`] = "";
|
|
24224
24232
|
}
|
|
24225
24233
|
}
|
|
24226
|
-
return Tt(
|
|
24234
|
+
return Tt(se(e, a));
|
|
24227
24235
|
};
|
|
24228
24236
|
}
|
|
24229
24237
|
},
|
|
@@ -24274,9 +24282,9 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24274
24282
|
this.defaultParams = { ...t, ...e }, this.dpFormData.params = D(this.defaultParams), this.getDataList();
|
|
24275
24283
|
},
|
|
24276
24284
|
initForm(e) {
|
|
24277
|
-
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType =
|
|
24285
|
+
this.searchText = "", this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType = ue.FORM), this.dpFormData.params || (this.dpFormData.params = {}), this.dpFormData.options ? (this.dpFormData.options.page || (this.dpFormData.options.page = 1), this.dpFormData.options.limit ? this.limit = this.dpFormData.options.limit : this.dpFormData.options.limit = this.limit, this.optionProvider = this.dpFormData.options) : this.dpFormData.options = this.optionProvider, this.parentId != "" && (this.params.xparentx = this.parentId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND xparentx = CONVERT(:xparentx, 'objectId')" : this.dpFormData.options.where = "xparentx = CONVERT(:xparentx, 'objectId')");
|
|
24278
24286
|
const t = D(this.dpFormData.params), a = D(this.params);
|
|
24279
|
-
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort:
|
|
24287
|
+
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), this.dpFormData.options.orderBy || (this.dpFormData.options.orderBy = [{ column: "created_at", sort: fe.DESC }]), this.getDataList();
|
|
24280
24288
|
},
|
|
24281
24289
|
keyIdIndex(e) {
|
|
24282
24290
|
let t = this.keyId;
|
|
@@ -24315,7 +24323,7 @@ const Ig = /* @__PURE__ */ B(Kf, [["render", nh], ["__scopeId", "data-v-ea5295de
|
|
|
24315
24323
|
window.localStorage.setItem("side_menu_" + this.formId, String(this.isCollapse));
|
|
24316
24324
|
},
|
|
24317
24325
|
getValue(e, t) {
|
|
24318
|
-
let a =
|
|
24326
|
+
let a = de(e, t);
|
|
24319
24327
|
return a ? Ae(a, t, this.sdformModel) : "";
|
|
24320
24328
|
},
|
|
24321
24329
|
getSchema(e) {
|
|
@@ -24488,7 +24496,7 @@ function mh(e, t, a, l, o, i) {
|
|
|
24488
24496
|
}, null, 4)
|
|
24489
24497
|
], 64);
|
|
24490
24498
|
}
|
|
24491
|
-
const
|
|
24499
|
+
const Tg = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
24492
24500
|
name: "SdUiRecordView",
|
|
24493
24501
|
components: {
|
|
24494
24502
|
// SdCrudPopupGrid,
|
|
@@ -24636,7 +24644,7 @@ const $g = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
|
24636
24644
|
},
|
|
24637
24645
|
data() {
|
|
24638
24646
|
return {
|
|
24639
|
-
isDark:
|
|
24647
|
+
isDark: re(),
|
|
24640
24648
|
rawData: null,
|
|
24641
24649
|
defaultParams: {},
|
|
24642
24650
|
preLoading: !1,
|
|
@@ -24656,7 +24664,7 @@ const $g = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
|
24656
24664
|
optionProvider: { limit: 1, page: 1 },
|
|
24657
24665
|
allowInsert: !1,
|
|
24658
24666
|
useUserState: this.$props.userState,
|
|
24659
|
-
dpFormData: { providerId: this.formId, providerType:
|
|
24667
|
+
dpFormData: { providerId: this.formId, providerType: ue.FORM },
|
|
24660
24668
|
wsConn: void 0,
|
|
24661
24669
|
widgetId: "SdUiRecordView-" + Rt(),
|
|
24662
24670
|
sdFunc: {},
|
|
@@ -24669,19 +24677,19 @@ const $g = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
|
24669
24677
|
return (e, t, a) => {
|
|
24670
24678
|
let l = {}, o = this.sdformModel.form_db.schema;
|
|
24671
24679
|
for (const i in o) {
|
|
24672
|
-
let d =
|
|
24680
|
+
let d = de(t, i);
|
|
24673
24681
|
l[`{{${i}}}`] = Ae(d, i, this.sdformModel);
|
|
24674
24682
|
}
|
|
24675
24683
|
if (a.expressions)
|
|
24676
24684
|
try {
|
|
24677
|
-
const d = `return ${
|
|
24685
|
+
const d = `return ${se(a.expressions, l)}`, u = new Function("row", ...De, d);
|
|
24678
24686
|
l["{{expressions}}"] = u.call(this.sdformModel, t);
|
|
24679
24687
|
} catch (i) {
|
|
24680
24688
|
l["{{expressions}}"] = i;
|
|
24681
24689
|
}
|
|
24682
24690
|
else
|
|
24683
24691
|
l["{{expressions}}"] = "";
|
|
24684
|
-
return Tt(
|
|
24692
|
+
return Tt(se(e, l));
|
|
24685
24693
|
};
|
|
24686
24694
|
}
|
|
24687
24695
|
},
|
|
@@ -24776,7 +24784,7 @@ const $g = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
|
24776
24784
|
this.showPopupGridFlag = !1;
|
|
24777
24785
|
},
|
|
24778
24786
|
initForm(e) {
|
|
24779
|
-
this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType =
|
|
24787
|
+
this.sdformModel = e, this.userState.formStore[this.formId] = this.sdformModel, this.fixApiUrl && this.fixApiUrl != "" ? this.apiUrl = this.fixApiUrl : this.sdformModel.form_db.api_url && this.sdformModel.form_db.api_url != "" ? this.apiUrl = this.sdformModel.form_db.api_url : this.apiUrl = window.APP_CONFIG.API_URL, this.userState.user && (this.allowInsert = Oe(this.sdformModel, this.userState.user)), this.sdformModel.form_event.after_delete && this.sdformModel.form_event.enable && (this.afterDeleteForm = new Function("formData", ...De, this.sdformModel.form_event.after_delete)), this.iconName || (this.iconForm = "", this.sdformModel.form_icon ? this.iconForm = this.sdformModel.form_icon : this.iconForm = ""), this.titleName ? this.titleNameForm = this.titleName : this.titleNameForm = this.sdformModel.form_name ? `${this.sdformModel.form_name}` : "", this.dataProvider ? this.dpFormData = D(this.dataProvider) : (this.dpFormData.providerId = this.formId, this.dpFormData.providerType = ue.FORM), this.dpFormData.params || (this.dpFormData.params = {}), this.dpFormData.options ? (this.dpFormData.options.page || (this.dpFormData.options.page = 1), this.dpFormData.options.limit ? this.limit = this.dpFormData.options.limit : this.dpFormData.options.limit = this.limit, this.optionProvider = this.dpFormData.options) : this.dpFormData.options = this.optionProvider, this.parentId != "" && (this.params.xparentx = this.parentId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND xparentx = CONVERT(:xparentx, 'objectId')" : this.dpFormData.options.where = "xparentx = CONVERT(:xparentx, 'objectId')"), (!this.lastRecord || this.dataId) && (this.params.xdataidx = this.recordId, this.dpFormData.options && this.dpFormData.options.where ? this.dpFormData.options.where += " AND _id = CONVERT(:xdataidx, 'objectId')" : this.dpFormData.options.where = "_id = CONVERT(:xdataidx, 'objectId')"), this.dpFormData.options.orderBy = [{ column: "created_at", sort: fe.DESC }];
|
|
24780
24788
|
const t = D(this.dpFormData.params), a = D(this.params);
|
|
24781
24789
|
this.defaultParams = { ...a, ...t }, this.dpFormData.params = D(this.defaultParams), (this.lastRecord || this.dataId) && this.getDataOne(this.dpFormData), this.enableWs && this.sdformModel.form_options && this.sdformModel.form_options.enable_websocket && (this.wsConn = this.userState.connectWebSocket("gridform", this.sdformModel.dataid, this.widgetId, (l) => {
|
|
24782
24790
|
if (l.from != "server" && (l.from != this.userState.user?.username || l.params && l.params.widget && l.params.widget !== this.widgetId) && l.keyid) {
|
|
@@ -24793,7 +24801,7 @@ const $g = /* @__PURE__ */ B(sh, [["render", mh]]), fh = L({
|
|
|
24793
24801
|
}
|
|
24794
24802
|
},
|
|
24795
24803
|
getValue(e, t) {
|
|
24796
|
-
let a =
|
|
24804
|
+
let a = de(e, t);
|
|
24797
24805
|
return a ? Ae(a, t, this.sdformModel) : "";
|
|
24798
24806
|
},
|
|
24799
24807
|
allowView(e, t, a) {
|
|
@@ -24892,7 +24900,7 @@ function bh(e, t, a, l, o, i) {
|
|
|
24892
24900
|
e.actionEnable ? {
|
|
24893
24901
|
name: "extra",
|
|
24894
24902
|
fn: s(() => [
|
|
24895
|
-
|
|
24903
|
+
he(e.$slots, "actions", { row: e.rawData }, void 0, !0),
|
|
24896
24904
|
!e.dataId && !e.rawData && e.addBtnEnable && e.allowInsert ? (n(), p(m, {
|
|
24897
24905
|
key: 0,
|
|
24898
24906
|
plain: "",
|
|
@@ -24960,14 +24968,14 @@ function bh(e, t, a, l, o, i) {
|
|
|
24960
24968
|
}, null, 8, ["modelValue", "parent-id", "readonly", "form-id", "user-state", "cancel-callback"])) : g("", !0)
|
|
24961
24969
|
], 64);
|
|
24962
24970
|
}
|
|
24963
|
-
const
|
|
24971
|
+
const Mg = /* @__PURE__ */ B(fh, [["render", bh], ["__scopeId", "data-v-88128e90"]]);
|
|
24964
24972
|
export {
|
|
24965
24973
|
Ua as $,
|
|
24966
24974
|
vo as A,
|
|
24967
|
-
|
|
24975
|
+
$g as B,
|
|
24968
24976
|
Mp as C,
|
|
24969
|
-
|
|
24970
|
-
|
|
24977
|
+
Tg as D,
|
|
24978
|
+
Mg as E,
|
|
24971
24979
|
Od as F,
|
|
24972
24980
|
xt as G,
|
|
24973
24981
|
af as H,
|
|
@@ -24981,7 +24989,7 @@ export {
|
|
|
24981
24989
|
ja as P,
|
|
24982
24990
|
ug as Q,
|
|
24983
24991
|
Au as R,
|
|
24984
|
-
|
|
24992
|
+
cg as S,
|
|
24985
24993
|
pg as T,
|
|
24986
24994
|
co as U,
|
|
24987
24995
|
Pl as V,
|
|
@@ -24995,61 +25003,62 @@ export {
|
|
|
24995
25003
|
Ou as a1,
|
|
24996
25004
|
Ae as a2,
|
|
24997
25005
|
Nu as a3,
|
|
24998
|
-
|
|
24999
|
-
|
|
25000
|
-
|
|
25001
|
-
|
|
25002
|
-
|
|
25003
|
-
|
|
25004
|
-
|
|
25005
|
-
|
|
25006
|
-
|
|
25007
|
-
|
|
25008
|
-
|
|
25009
|
-
|
|
25010
|
-
|
|
25011
|
-
|
|
25012
|
-
|
|
25013
|
-
|
|
25014
|
-
|
|
25015
|
-
|
|
25016
|
-
|
|
25017
|
-
|
|
25018
|
-
|
|
25019
|
-
|
|
25020
|
-
|
|
25021
|
-
|
|
25022
|
-
|
|
25023
|
-
|
|
25024
|
-
|
|
25025
|
-
|
|
25026
|
-
|
|
25027
|
-
|
|
25028
|
-
|
|
25029
|
-
|
|
25006
|
+
fg as a4,
|
|
25007
|
+
B as a5,
|
|
25008
|
+
En as a6,
|
|
25009
|
+
Ce as a7,
|
|
25010
|
+
D as a8,
|
|
25011
|
+
De as a9,
|
|
25012
|
+
Ra as aA,
|
|
25013
|
+
Rt as aa,
|
|
25014
|
+
Jb as ab,
|
|
25015
|
+
Yb as ac,
|
|
25016
|
+
de as ad,
|
|
25017
|
+
$a as ae,
|
|
25018
|
+
ng as af,
|
|
25019
|
+
ig as ag,
|
|
25020
|
+
Ln as ah,
|
|
25021
|
+
sg as ai,
|
|
25022
|
+
og as aj,
|
|
25023
|
+
lg as ak,
|
|
25024
|
+
Ba as al,
|
|
25025
|
+
Xb as am,
|
|
25026
|
+
La as an,
|
|
25027
|
+
Gb as ao,
|
|
25028
|
+
ga as ap,
|
|
25029
|
+
eg as aq,
|
|
25030
|
+
ee as ar,
|
|
25031
|
+
Kb as as,
|
|
25032
|
+
ag as at,
|
|
25033
|
+
tg as au,
|
|
25034
|
+
bt as av,
|
|
25035
|
+
Zb as aw,
|
|
25036
|
+
Qb as ax,
|
|
25037
|
+
ue as ay,
|
|
25038
|
+
xm as az,
|
|
25030
25039
|
Nn as b,
|
|
25031
25040
|
rg as c,
|
|
25032
25041
|
va as d,
|
|
25033
25042
|
dg as e,
|
|
25034
|
-
|
|
25035
|
-
|
|
25036
|
-
|
|
25043
|
+
hg as f,
|
|
25044
|
+
bg as g,
|
|
25045
|
+
gg as h,
|
|
25037
25046
|
bo as i,
|
|
25038
25047
|
Fm as j,
|
|
25039
25048
|
Cm as k,
|
|
25040
25049
|
Tm as l,
|
|
25041
|
-
|
|
25050
|
+
yg as m,
|
|
25042
25051
|
Rm as n,
|
|
25043
|
-
|
|
25044
|
-
|
|
25045
|
-
|
|
25046
|
-
|
|
25052
|
+
vg as o,
|
|
25053
|
+
wg as p,
|
|
25054
|
+
Fg as q,
|
|
25055
|
+
_g as r,
|
|
25047
25056
|
go as s,
|
|
25048
25057
|
yo as t,
|
|
25049
25058
|
pm as u,
|
|
25050
|
-
|
|
25051
|
-
|
|
25052
|
-
|
|
25053
|
-
|
|
25054
|
-
|
|
25059
|
+
Sg as v,
|
|
25060
|
+
kg as w,
|
|
25061
|
+
Cg as x,
|
|
25062
|
+
Dg as y,
|
|
25063
|
+
Ig as z
|
|
25055
25064
|
};
|