@kengic/vue 0.13.1 → 0.13.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/kengic-vue.js
CHANGED
@@ -1816,8 +1816,8 @@ function generate$1(e) {
|
|
1816
1816
|
r.push(c);
|
1817
1817
|
}
|
1818
1818
|
return t.theme === "dark" ? darkColorMap.map(function(u) {
|
1819
|
-
var d = u.index, g = u.opacity,
|
1820
|
-
return
|
1819
|
+
var d = u.index, g = u.opacity, y = toHex(mix(inputToRGB(t.backgroundColor || "#141414"), inputToRGB(r[d]), g * 100));
|
1820
|
+
return y;
|
1821
1821
|
}) : r;
|
1822
1822
|
}
|
1823
1823
|
var presetPrimaryColors = {
|
@@ -2173,22 +2173,22 @@ function _objectWithoutPropertiesLoose(e, t) {
|
|
2173
2173
|
}
|
2174
2174
|
setTwoToneColor("#1890ff");
|
2175
2175
|
var Icon$1 = function(t, r) {
|
2176
|
-
var a, n = _objectSpread$k({}, t, r.attrs), s = n.class, i = n.icon, o = n.spin, l = n.rotate, c = n.tabindex, u = n.twoToneColor, d = n.onClick, g = _objectWithoutProperties(n, _excluded),
|
2176
|
+
var a, n = _objectSpread$k({}, t, r.attrs), s = n.class, i = n.icon, o = n.spin, l = n.rotate, c = n.tabindex, u = n.twoToneColor, d = n.onClick, g = _objectWithoutProperties(n, _excluded), y = (a = {
|
2177
2177
|
anticon: !0
|
2178
|
-
}, _defineProperty$k(a, "anticon-".concat(i.name), Boolean(i.name)), _defineProperty$k(a, s, s), a),
|
2178
|
+
}, _defineProperty$k(a, "anticon-".concat(i.name), Boolean(i.name)), _defineProperty$k(a, s, s), a), b = o === "" || !!o || i.name === "loading" ? "anticon-spin" : "", _ = c;
|
2179
2179
|
_ === void 0 && d && (_ = -1, g.tabindex = _);
|
2180
2180
|
var p = l ? {
|
2181
2181
|
msTransform: "rotate(".concat(l, "deg)"),
|
2182
2182
|
transform: "rotate(".concat(l, "deg)")
|
2183
|
-
} : void 0, m = normalizeTwoToneColors(u),
|
2183
|
+
} : void 0, m = normalizeTwoToneColors(u), E = _slicedToArray(m, 2), T = E[0], k = E[1];
|
2184
2184
|
return createVNode("span", _objectSpread$k({
|
2185
2185
|
role: "img",
|
2186
2186
|
"aria-label": i.name
|
2187
2187
|
}, g, {
|
2188
2188
|
onClick: d,
|
2189
|
-
class:
|
2189
|
+
class: y
|
2190
2190
|
}), [createVNode(VueIcon, {
|
2191
|
-
class:
|
2191
|
+
class: b,
|
2192
2192
|
icon: i,
|
2193
2193
|
primaryColor: T,
|
2194
2194
|
secondaryColor: k,
|
@@ -3000,16 +3000,16 @@ function iconToSVG(e, t) {
|
|
3000
3000
|
height: r.height
|
3001
3001
|
};
|
3002
3002
|
let s = r.body;
|
3003
|
-
[r, a].forEach((
|
3004
|
-
const _ = [], p =
|
3005
|
-
let
|
3006
|
-
p ? m ?
|
3003
|
+
[r, a].forEach((b) => {
|
3004
|
+
const _ = [], p = b.hFlip, m = b.vFlip;
|
3005
|
+
let E = b.rotate;
|
3006
|
+
p ? m ? E += 2 : (_.push(
|
3007
3007
|
"translate(" + (n.width + n.left).toString() + " " + (0 - n.top).toString() + ")"
|
3008
3008
|
), _.push("scale(-1 1)"), n.top = n.left = 0) : m && (_.push(
|
3009
3009
|
"translate(" + (0 - n.left).toString() + " " + (n.height + n.top).toString() + ")"
|
3010
3010
|
), _.push("scale(1 -1)"), n.top = n.left = 0);
|
3011
3011
|
let T;
|
3012
|
-
switch (
|
3012
|
+
switch (E < 0 && (E -= Math.floor(E / 4) * 4), E = E % 4, E) {
|
3013
3013
|
case 1:
|
3014
3014
|
T = n.height / 2 + n.top, _.unshift(
|
3015
3015
|
"rotate(90 " + T.toString() + " " + T.toString() + ")"
|
@@ -3026,15 +3026,15 @@ function iconToSVG(e, t) {
|
|
3026
3026
|
);
|
3027
3027
|
break;
|
3028
3028
|
}
|
3029
|
-
|
3029
|
+
E % 2 === 1 && (n.left !== n.top && (T = n.left, n.left = n.top, n.top = T), n.width !== n.height && (T = n.width, n.width = n.height, n.height = T)), _.length && (s = '<g transform="' + _.join(" ") + '">' + s + "</g>");
|
3030
3030
|
});
|
3031
3031
|
const i = a.width, o = a.height, l = n.width, c = n.height;
|
3032
3032
|
let u, d;
|
3033
3033
|
i === null ? (d = o === null ? "1em" : o === "auto" ? c : o, u = calculateSize(d, l / c)) : (u = i === "auto" ? l : i, d = o === null ? calculateSize(u, c / l) : o === "auto" ? c : o);
|
3034
|
-
const g = {},
|
3035
|
-
isUnsetKeyword(_) || (g[
|
3034
|
+
const g = {}, y = (b, _) => {
|
3035
|
+
isUnsetKeyword(_) || (g[b] = _.toString());
|
3036
3036
|
};
|
3037
|
-
return
|
3037
|
+
return y("width", u), y("height", d), g.viewBox = n.left.toString() + " " + n.top.toString() + " " + l.toString() + " " + c.toString(), {
|
3038
3038
|
attributes: g,
|
3039
3039
|
body: s
|
3040
3040
|
};
|
@@ -3315,18 +3315,18 @@ function sendQuery(e, t, r, a) {
|
|
3315
3315
|
} else
|
3316
3316
|
i = e.resources.slice(s).concat(e.resources.slice(0, s));
|
3317
3317
|
const o = Date.now();
|
3318
|
-
let l = "pending", c = 0, u, d = null, g = [],
|
3319
|
-
typeof a == "function" &&
|
3320
|
-
function
|
3318
|
+
let l = "pending", c = 0, u, d = null, g = [], y = [];
|
3319
|
+
typeof a == "function" && y.push(a);
|
3320
|
+
function b() {
|
3321
3321
|
d && (clearTimeout(d), d = null);
|
3322
3322
|
}
|
3323
3323
|
function _() {
|
3324
|
-
l === "pending" && (l = "aborted"),
|
3324
|
+
l === "pending" && (l = "aborted"), b(), g.forEach((C) => {
|
3325
3325
|
C.status === "pending" && (C.status = "aborted");
|
3326
3326
|
}), g = [];
|
3327
3327
|
}
|
3328
3328
|
function p(C, M) {
|
3329
|
-
M && (
|
3329
|
+
M && (y = []), typeof C == "function" && y.push(C);
|
3330
3330
|
}
|
3331
3331
|
function m() {
|
3332
3332
|
return {
|
@@ -3339,8 +3339,8 @@ function sendQuery(e, t, r, a) {
|
|
3339
3339
|
abort: _
|
3340
3340
|
};
|
3341
3341
|
}
|
3342
|
-
function
|
3343
|
-
l = "failed",
|
3342
|
+
function E() {
|
3343
|
+
l = "failed", y.forEach((C) => {
|
3344
3344
|
C(void 0, u);
|
3345
3345
|
});
|
3346
3346
|
}
|
@@ -3362,34 +3362,34 @@ function sendQuery(e, t, r, a) {
|
|
3362
3362
|
return;
|
3363
3363
|
}
|
3364
3364
|
if (M === "abort") {
|
3365
|
-
u = w,
|
3365
|
+
u = w, E();
|
3366
3366
|
return;
|
3367
3367
|
}
|
3368
3368
|
if (I) {
|
3369
|
-
u = w, g.length || (i.length ? A() :
|
3369
|
+
u = w, g.length || (i.length ? A() : E());
|
3370
3370
|
return;
|
3371
3371
|
}
|
3372
|
-
if (
|
3372
|
+
if (b(), T(), !e.random) {
|
3373
3373
|
const R = e.resources.indexOf(C.resource);
|
3374
3374
|
R !== -1 && R !== e.index && (e.index = R);
|
3375
3375
|
}
|
3376
|
-
l = "completed",
|
3376
|
+
l = "completed", y.forEach((R) => {
|
3377
3377
|
R(w);
|
3378
3378
|
});
|
3379
3379
|
}
|
3380
3380
|
function A() {
|
3381
3381
|
if (l !== "pending")
|
3382
3382
|
return;
|
3383
|
-
|
3383
|
+
b();
|
3384
3384
|
const C = i.shift();
|
3385
3385
|
if (C === void 0) {
|
3386
3386
|
if (g.length) {
|
3387
3387
|
d = setTimeout(() => {
|
3388
|
-
|
3388
|
+
b(), l === "pending" && (T(), E());
|
3389
3389
|
}, e.timeout);
|
3390
3390
|
return;
|
3391
3391
|
}
|
3392
|
-
|
3392
|
+
E();
|
3393
3393
|
return;
|
3394
3394
|
}
|
3395
3395
|
const M = {
|
@@ -3666,8 +3666,8 @@ const loadIcons = (e, t) => {
|
|
3666
3666
|
const d = n[c] || (n[c] = /* @__PURE__ */ Object.create(null));
|
3667
3667
|
d[u] || (d[u] = []);
|
3668
3668
|
}), a.pending.forEach((l) => {
|
3669
|
-
const { provider: c, prefix: u, name: d } = l, g = getStorage(c, u),
|
3670
|
-
|
3669
|
+
const { provider: c, prefix: u, name: d } = l, g = getStorage(c, u), y = g.pendingIcons || (g.pendingIcons = /* @__PURE__ */ new Set());
|
3670
|
+
y.has(d) || (y.add(d), n[c][u].push(d));
|
3671
3671
|
}), s.forEach((l) => {
|
3672
3672
|
const { provider: c, prefix: u } = l;
|
3673
3673
|
n[c][u].length && loadNewIcons(l, n[c][u]);
|
@@ -3817,18 +3817,18 @@ const render = (e, t) => {
|
|
3817
3817
|
let _ = 0, p = t.id;
|
3818
3818
|
return typeof p == "string" && (p = p.replace(/-/g, "_")), a.innerHTML = replaceIDs(l.body, p ? () => p + "ID" + _++ : "iconifyVue"), h("svg", a);
|
3819
3819
|
}
|
3820
|
-
const { body: u, width: d, height: g } = e,
|
3820
|
+
const { body: u, width: d, height: g } = e, y = n === "mask" || (n === "bg" ? !1 : u.indexOf("currentColor") !== -1), b = iconToHTML(u, {
|
3821
3821
|
...c,
|
3822
3822
|
width: d + "",
|
3823
3823
|
height: g + ""
|
3824
3824
|
});
|
3825
3825
|
return a.style = {
|
3826
3826
|
...s,
|
3827
|
-
"--svg": svgToURL(
|
3827
|
+
"--svg": svgToURL(b),
|
3828
3828
|
width: fixSize(c.width),
|
3829
3829
|
height: fixSize(c.height),
|
3830
3830
|
...commonProps,
|
3831
|
-
...
|
3831
|
+
...y ? monotoneProps : coloredProps,
|
3832
3832
|
...o
|
3833
3833
|
}, h("span", a);
|
3834
3834
|
};
|
@@ -3919,7 +3919,7 @@ const emptyIcon = {
|
|
3919
3919
|
...t.data
|
3920
3920
|
}, r);
|
3921
3921
|
}
|
3922
|
-
}), name = "@kengic/vue", version = "0.13.
|
3922
|
+
}), name = "@kengic/vue", version = "0.13.2", data$1 = {
|
3923
3923
|
width: 24,
|
3924
3924
|
height: 24,
|
3925
3925
|
body: '<path fill="currentColor" d="M5 21q-.825 0-1.413-.588T3 19V5q0-.825.588-1.413T5 3h11.175q.4 0 .763.15t.637.425l2.85 2.85q.275.275.425.638t.15.762V12.3q-.475-.2-.988-.263T19 12.05V7.825L16.175 5H5v14h6v2H5ZM5 5v14V5Zm8 17v-1.65q0-.2.075-.388t.225-.337l5.225-5.2q.225-.225.5-.325t.55-.1q.3 0 .575.113t.5.337l.925.925q.2.225.313.5t.112.55q0 .275-.1.563t-.325.512l-5.2 5.2q-.15.15-.338.225T15.65 23H14q-.425 0-.712-.287T13 22Zm7.5-5.575l-.925-.925l.925.925Zm-6 5.075h.95l3.025-3.05l-.45-.475l-.475-.45l-3.05 3.025v.95Zm3.525-3.525l-.475-.45l.925.925l-.45-.475ZM7 10h7q.425 0 .713-.288T15 9V7q0-.425-.288-.713T14 6H7q-.425 0-.713.288T6 7v2q0 .425.288.713T7 10Zm5 8h.1l2.9-2.875V15q0-1.25-.875-2.125T12 12q-1.25 0-2.125.875T9 15q0 1.25.875 2.125T12 18Z"/>'
|
@@ -3938,7 +3938,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3938
3938
|
(function(r, a) {
|
3939
3939
|
e.exports = a();
|
3940
3940
|
})(commonjsGlobal, function() {
|
3941
|
-
var r = 1e3, a = 6e4, n = 36e5, s = "millisecond", i = "second", o = "minute", l = "hour", c = "day", u = "week", d = "month", g = "quarter",
|
3941
|
+
var r = 1e3, a = 6e4, n = 36e5, s = "millisecond", i = "second", o = "minute", l = "hour", c = "day", u = "week", d = "month", g = "quarter", y = "year", b = "date", _ = "Invalid Date", p = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, m = /\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, E = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function($) {
|
3942
3942
|
var D = ["th", "st", "nd", "rd"], V = $ % 100;
|
3943
3943
|
return "[" + $ + (D[(V - 20) % 10] || D[V] || D[0]) + "]";
|
3944
3944
|
} }, T = function($, D, V) {
|
@@ -3955,11 +3955,11 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3955
3955
|
}, a: function($) {
|
3956
3956
|
return $ < 0 ? Math.ceil($) || 0 : Math.floor($);
|
3957
3957
|
}, p: function($) {
|
3958
|
-
return { M: d, y
|
3958
|
+
return { M: d, y, w: u, d: c, D: b, h: l, m: o, s: i, ms: s, Q: g }[$] || String($ || "").toLowerCase().replace(/s$/, "");
|
3959
3959
|
}, u: function($) {
|
3960
3960
|
return $ === void 0;
|
3961
3961
|
} }, A = "en", C = {};
|
3962
|
-
C[A] =
|
3962
|
+
C[A] = E;
|
3963
3963
|
var M = "$isDayjsObject", w = function($) {
|
3964
3964
|
return $ instanceof O || !(!$ || !$[M]);
|
3965
3965
|
}, I = function $(D, V, N) {
|
@@ -4030,22 +4030,22 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4030
4030
|
}, D.valueOf = function() {
|
4031
4031
|
return this.$d.getTime();
|
4032
4032
|
}, D.startOf = function(V, N) {
|
4033
|
-
var B = this, H = !!P.u(N) || N, L = P.p(V), x = function(
|
4034
|
-
var K = P.w(B.$u ? Date.UTC(B.$y, ae,
|
4033
|
+
var B = this, H = !!P.u(N) || N, L = P.p(V), x = function(de, ae) {
|
4034
|
+
var K = P.w(B.$u ? Date.UTC(B.$y, ae, de) : new Date(B.$y, ae, de), B);
|
4035
4035
|
return H ? K : K.endOf(c);
|
4036
|
-
}, Y = function(
|
4037
|
-
return P.w(B.toDate()[
|
4036
|
+
}, Y = function(de, ae) {
|
4037
|
+
return P.w(B.toDate()[de].apply(B.toDate("s"), (H ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(ae)), B);
|
4038
4038
|
}, q = this.$W, X = this.$M, J = this.$D, te = "set" + (this.$u ? "UTC" : "");
|
4039
4039
|
switch (L) {
|
4040
|
-
case
|
4040
|
+
case y:
|
4041
4041
|
return H ? x(1, 0) : x(31, 11);
|
4042
4042
|
case d:
|
4043
4043
|
return H ? x(1, X) : x(0, X + 1);
|
4044
4044
|
case u:
|
4045
|
-
var
|
4046
|
-
return x(H ? J -
|
4045
|
+
var ie = this.$locale().weekStart || 0, me = (q < ie ? q + 7 : q) - ie;
|
4046
|
+
return x(H ? J - me : J + (6 - me), X);
|
4047
4047
|
case c:
|
4048
|
-
case
|
4048
|
+
case b:
|
4049
4049
|
return Y(te + "Hours", 0);
|
4050
4050
|
case l:
|
4051
4051
|
return Y(te + "Minutes", 1);
|
@@ -4059,10 +4059,10 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4059
4059
|
}, D.endOf = function(V) {
|
4060
4060
|
return this.startOf(V, !1);
|
4061
4061
|
}, D.$set = function(V, N) {
|
4062
|
-
var B, H = P.p(V), L = "set" + (this.$u ? "UTC" : ""), x = (B = {}, B[c] = L + "Date", B[
|
4063
|
-
if (H === d || H ===
|
4064
|
-
var q = this.clone().set(
|
4065
|
-
q.$d[x](Y), q.init(), this.$d = q.set(
|
4062
|
+
var B, H = P.p(V), L = "set" + (this.$u ? "UTC" : ""), x = (B = {}, B[c] = L + "Date", B[b] = L + "Date", B[d] = L + "Month", B[y] = L + "FullYear", B[l] = L + "Hours", B[o] = L + "Minutes", B[i] = L + "Seconds", B[s] = L + "Milliseconds", B)[H], Y = H === c ? this.$D + (N - this.$W) : N;
|
4063
|
+
if (H === d || H === y) {
|
4064
|
+
var q = this.clone().set(b, 1);
|
4065
|
+
q.$d[x](Y), q.init(), this.$d = q.set(b, Math.min(this.$D, q.daysInMonth())).$d;
|
4066
4066
|
} else
|
4067
4067
|
x && this.$d[x](Y);
|
4068
4068
|
return this.init(), this;
|
@@ -4079,8 +4079,8 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4079
4079
|
};
|
4080
4080
|
if (L === d)
|
4081
4081
|
return this.set(d, this.$M + V);
|
4082
|
-
if (L ===
|
4083
|
-
return this.set(
|
4082
|
+
if (L === y)
|
4083
|
+
return this.set(y, this.$y + V);
|
4084
4084
|
if (L === c)
|
4085
4085
|
return x(1);
|
4086
4086
|
if (L === u)
|
@@ -4093,17 +4093,17 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4093
4093
|
var N = this, B = this.$locale();
|
4094
4094
|
if (!this.isValid())
|
4095
4095
|
return B.invalidDate || _;
|
4096
|
-
var H = V || "YYYY-MM-DDTHH:mm:ssZ", L = P.z(this), x = this.$H, Y = this.$m, q = this.$M, X = B.weekdays, J = B.months, te = B.meridiem,
|
4097
|
-
return ae && (ae[K] || ae(N, H)) ||
|
4098
|
-
},
|
4096
|
+
var H = V || "YYYY-MM-DDTHH:mm:ssZ", L = P.z(this), x = this.$H, Y = this.$m, q = this.$M, X = B.weekdays, J = B.months, te = B.meridiem, ie = function(ae, K, G, Q) {
|
4097
|
+
return ae && (ae[K] || ae(N, H)) || G[K].slice(0, Q);
|
4098
|
+
}, me = function(ae) {
|
4099
4099
|
return P.s(x % 12 || 12, ae, "0");
|
4100
|
-
},
|
4100
|
+
}, de = te || function(ae, K, G) {
|
4101
4101
|
var Q = ae < 12 ? "AM" : "PM";
|
4102
|
-
return
|
4102
|
+
return G ? Q.toLowerCase() : Q;
|
4103
4103
|
};
|
4104
4104
|
return H.replace(m, function(ae, K) {
|
4105
|
-
return K || function(
|
4106
|
-
switch (
|
4105
|
+
return K || function(G) {
|
4106
|
+
switch (G) {
|
4107
4107
|
case "YY":
|
4108
4108
|
return String(N.$y).slice(-2);
|
4109
4109
|
case "YYYY":
|
@@ -4113,9 +4113,9 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4113
4113
|
case "MM":
|
4114
4114
|
return P.s(q + 1, 2, "0");
|
4115
4115
|
case "MMM":
|
4116
|
-
return
|
4116
|
+
return ie(B.monthsShort, q, J, 3);
|
4117
4117
|
case "MMMM":
|
4118
|
-
return
|
4118
|
+
return ie(J, q);
|
4119
4119
|
case "D":
|
4120
4120
|
return N.$D;
|
4121
4121
|
case "DD":
|
@@ -4123,9 +4123,9 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4123
4123
|
case "d":
|
4124
4124
|
return String(N.$W);
|
4125
4125
|
case "dd":
|
4126
|
-
return
|
4126
|
+
return ie(B.weekdaysMin, N.$W, X, 2);
|
4127
4127
|
case "ddd":
|
4128
|
-
return
|
4128
|
+
return ie(B.weekdaysShort, N.$W, X, 3);
|
4129
4129
|
case "dddd":
|
4130
4130
|
return X[N.$W];
|
4131
4131
|
case "H":
|
@@ -4133,13 +4133,13 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4133
4133
|
case "HH":
|
4134
4134
|
return P.s(x, 2, "0");
|
4135
4135
|
case "h":
|
4136
|
-
return
|
4136
|
+
return me(1);
|
4137
4137
|
case "hh":
|
4138
|
-
return
|
4138
|
+
return me(2);
|
4139
4139
|
case "a":
|
4140
|
-
return
|
4140
|
+
return de(x, Y, !0);
|
4141
4141
|
case "A":
|
4142
|
-
return
|
4142
|
+
return de(x, Y, !1);
|
4143
4143
|
case "m":
|
4144
4144
|
return String(Y);
|
4145
4145
|
case "mm":
|
@@ -4163,7 +4163,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4163
4163
|
return P.m(L, Y);
|
4164
4164
|
};
|
4165
4165
|
switch (x) {
|
4166
|
-
case
|
4166
|
+
case y:
|
4167
4167
|
H = J() / 12;
|
4168
4168
|
break;
|
4169
4169
|
case d:
|
@@ -4212,7 +4212,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4212
4212
|
return this.$d.toUTCString();
|
4213
4213
|
}, $;
|
4214
4214
|
}(), F = O.prototype;
|
4215
|
-
return R.prototype = F, [["$ms", s], ["$s", i], ["$m", o], ["$H", l], ["$W", c], ["$M", d], ["$y",
|
4215
|
+
return R.prototype = F, [["$ms", s], ["$s", i], ["$m", o], ["$H", l], ["$W", c], ["$M", d], ["$y", y], ["$D", b]].forEach(function($) {
|
4216
4216
|
F[$[1]] = function(D) {
|
4217
4217
|
return this.$g(D, $[0], $[1]);
|
4218
4218
|
};
|
@@ -4260,32 +4260,32 @@ function filesize(e, {
|
|
4260
4260
|
standard: u = EMPTY,
|
4261
4261
|
output: d = STRING,
|
4262
4262
|
fullform: g = !1,
|
4263
|
-
fullforms:
|
4264
|
-
exponent:
|
4263
|
+
fullforms: y = [],
|
4264
|
+
exponent: b = -1,
|
4265
4265
|
roundingMethod: _ = ROUND,
|
4266
4266
|
precision: p = 0
|
4267
4267
|
} = {}) {
|
4268
|
-
let m =
|
4268
|
+
let m = b, E = Number(e), T = [], k = 0, A = EMPTY;
|
4269
4269
|
u === SI ? (a = 10, u = JEDEC) : u === IEC || u === JEDEC ? a = 2 : a === 2 ? u = IEC : (a = 10, u = JEDEC);
|
4270
|
-
const C = a === 10 ? 1e3 : 1024, M = g === !0, w =
|
4270
|
+
const C = a === 10 ? 1e3 : 1024, M = g === !0, w = E < 0, I = Math[_];
|
4271
4271
|
if (typeof e != "bigint" && isNaN(e))
|
4272
4272
|
throw new TypeError(INVALID_NUMBER);
|
4273
4273
|
if (typeof I !== FUNCTION)
|
4274
4274
|
throw new TypeError(INVALID_ROUND);
|
4275
|
-
if (w && (
|
4275
|
+
if (w && (E = -E), (m === -1 || isNaN(m)) && (m = Math.floor(Math.log(E) / Math.log(C)), m < 0 && (m = 0)), m > 8 && (p > 0 && (p += 8 - m), m = 8), d === EXPONENT)
|
4276
4276
|
return m;
|
4277
|
-
if (
|
4277
|
+
if (E === 0)
|
4278
4278
|
T[0] = 0, A = T[1] = STRINGS.symbol[u][t ? BITS : BYTES][m];
|
4279
4279
|
else {
|
4280
|
-
k =
|
4280
|
+
k = E / (a === 2 ? Math.pow(2, m * 10) : Math.pow(1e3, m)), t && (k = k * 8, k >= C && m < 8 && (k = k / C, m++));
|
4281
4281
|
const R = Math.pow(10, m > 0 ? n : 0);
|
4282
|
-
T[0] = I(k * R) / R, T[0] === C && m < 8 &&
|
4282
|
+
T[0] = I(k * R) / R, T[0] === C && m < 8 && b === -1 && (T[0] = 1, m++), A = T[1] = a === 10 && m === 1 ? t ? SI_KBIT : SI_KBYTE : STRINGS.symbol[u][t ? BITS : BYTES][m];
|
4283
4283
|
}
|
4284
4284
|
if (w && (T[0] = -T[0]), p > 0 && (T[0] = T[0].toPrecision(p)), T[1] = c[T[1]] || T[1], s === !0 ? T[0] = T[0].toLocaleString() : s.length > 0 ? T[0] = T[0].toLocaleString(s, i) : o.length > 0 && (T[0] = T[0].toString().replace(PERIOD, o)), r && Number.isInteger(T[0]) === !1 && n > 0) {
|
4285
4285
|
const R = o || PERIOD, P = T[0].toString().split(R), O = P[1] || EMPTY, F = O.length, $ = n - F;
|
4286
4286
|
T[0] = `${P[0]}${R}${O.padEnd(F + $, ZERO)}`;
|
4287
4287
|
}
|
4288
|
-
return M && (T[1] =
|
4288
|
+
return M && (T[1] = y[m] ? y[m] : STRINGS.fullform[u][m] + (t ? BIT : BYTE) + (T[0] === 1 ? EMPTY : S)), d === ARRAY ? T : d === OBJECT ? {
|
4289
4289
|
value: T[0],
|
4290
4290
|
symbol: T[1],
|
4291
4291
|
exponent: m,
|
@@ -5331,15 +5331,15 @@ function baseClone(e, t, r, a, n, s) {
|
|
5331
5331
|
}
|
5332
5332
|
}
|
5333
5333
|
s || (s = new Stack());
|
5334
|
-
var
|
5335
|
-
if (
|
5336
|
-
return
|
5334
|
+
var y = s.get(e);
|
5335
|
+
if (y)
|
5336
|
+
return y;
|
5337
5337
|
s.set(e, i), isSet$1(e) ? e.forEach(function(p) {
|
5338
5338
|
i.add(baseClone(p, t, r, p, e, s));
|
5339
5339
|
}) : isMap$1(e) && e.forEach(function(p, m) {
|
5340
5340
|
i.set(m, baseClone(p, t, r, m, e, s));
|
5341
5341
|
});
|
5342
|
-
var
|
5342
|
+
var b = c ? l ? getAllKeysIn : getAllKeys : l ? keysIn : keys, _ = u ? void 0 : b(e);
|
5343
5343
|
return arrayEach(_ || e, function(p, m) {
|
5344
5344
|
_ && (m = p, p = e[m]), assignValue(i, m, baseClone(p, t, r, m, e, s));
|
5345
5345
|
}), i;
|
@@ -5386,26 +5386,26 @@ function equalArrays(e, t, r, a, n, s) {
|
|
5386
5386
|
var c = s.get(e), u = s.get(t);
|
5387
5387
|
if (c && u)
|
5388
5388
|
return c == t && u == e;
|
5389
|
-
var d = -1, g = !0,
|
5389
|
+
var d = -1, g = !0, y = r & COMPARE_UNORDERED_FLAG$3 ? new SetCache() : void 0;
|
5390
5390
|
for (s.set(e, t), s.set(t, e); ++d < o; ) {
|
5391
|
-
var
|
5391
|
+
var b = e[d], _ = t[d];
|
5392
5392
|
if (a)
|
5393
|
-
var p = i ? a(_,
|
5393
|
+
var p = i ? a(_, b, d, t, e, s) : a(b, _, d, e, t, s);
|
5394
5394
|
if (p !== void 0) {
|
5395
5395
|
if (p)
|
5396
5396
|
continue;
|
5397
5397
|
g = !1;
|
5398
5398
|
break;
|
5399
5399
|
}
|
5400
|
-
if (
|
5401
|
-
if (!arraySome(t, function(m,
|
5402
|
-
if (!cacheHas(
|
5403
|
-
return
|
5400
|
+
if (y) {
|
5401
|
+
if (!arraySome(t, function(m, E) {
|
5402
|
+
if (!cacheHas(y, E) && (b === m || n(b, m, r, a, s)))
|
5403
|
+
return y.push(E);
|
5404
5404
|
})) {
|
5405
5405
|
g = !1;
|
5406
5406
|
break;
|
5407
5407
|
}
|
5408
|
-
} else if (!(
|
5408
|
+
} else if (!(b === _ || n(b, _, r, a, s))) {
|
5409
5409
|
g = !1;
|
5410
5410
|
break;
|
5411
5411
|
}
|
@@ -5470,17 +5470,17 @@ function equalObjects(e, t, r, a, n, s) {
|
|
5470
5470
|
if (!(i ? g in t : hasOwnProperty$1.call(t, g)))
|
5471
5471
|
return !1;
|
5472
5472
|
}
|
5473
|
-
var
|
5474
|
-
if (
|
5475
|
-
return
|
5473
|
+
var y = s.get(e), b = s.get(t);
|
5474
|
+
if (y && b)
|
5475
|
+
return y == t && b == e;
|
5476
5476
|
var _ = !0;
|
5477
5477
|
s.set(e, t), s.set(t, e);
|
5478
5478
|
for (var p = i; ++d < l; ) {
|
5479
5479
|
g = o[d];
|
5480
|
-
var m = e[g],
|
5480
|
+
var m = e[g], E = t[g];
|
5481
5481
|
if (a)
|
5482
|
-
var T = i ? a(
|
5483
|
-
if (!(T === void 0 ? m ===
|
5482
|
+
var T = i ? a(E, m, g, t, e, s) : a(m, E, g, e, t, s);
|
5483
|
+
if (!(T === void 0 ? m === E || n(m, E, r, a, s) : T)) {
|
5484
5484
|
_ = !1;
|
5485
5485
|
break;
|
5486
5486
|
}
|
@@ -5505,9 +5505,9 @@ function baseIsEqualDeep(e, t, r, a, n, s) {
|
|
5505
5505
|
if (g && !u)
|
5506
5506
|
return s || (s = new Stack()), i || isTypedArray$1(e) ? equalArrays(e, t, r, a, n, s) : equalByTag(e, t, l, r, a, n, s);
|
5507
5507
|
if (!(r & COMPARE_PARTIAL_FLAG$2)) {
|
5508
|
-
var
|
5509
|
-
if (
|
5510
|
-
var _ =
|
5508
|
+
var y = u && hasOwnProperty.call(e, "__wrapped__"), b = d && hasOwnProperty.call(t, "__wrapped__");
|
5509
|
+
if (y || b) {
|
5510
|
+
var _ = y ? e.value() : e, p = b ? t.value() : t;
|
5511
5511
|
return s || (s = new Stack()), n(_, p, r, a, s);
|
5512
5512
|
}
|
5513
5513
|
}
|
@@ -5640,12 +5640,12 @@ function debounce(e, t, r) {
|
|
5640
5640
|
if (typeof e != "function")
|
5641
5641
|
throw new TypeError(FUNC_ERROR_TEXT);
|
5642
5642
|
t = toNumber(t) || 0, isObject$2(r) && (u = !!r.leading, d = "maxWait" in r, s = d ? nativeMax$1(toNumber(r.maxWait) || 0, t) : s, g = "trailing" in r ? !!r.trailing : g);
|
5643
|
-
function
|
5643
|
+
function y(C) {
|
5644
5644
|
var M = a, w = n;
|
5645
5645
|
return a = n = void 0, c = C, i = e.apply(w, M), i;
|
5646
5646
|
}
|
5647
|
-
function
|
5648
|
-
return c = C, o = setTimeout(m, t), u ?
|
5647
|
+
function b(C) {
|
5648
|
+
return c = C, o = setTimeout(m, t), u ? y(C) : i;
|
5649
5649
|
}
|
5650
5650
|
function _(C) {
|
5651
5651
|
var M = C - l, w = C - c, I = t - M;
|
@@ -5658,25 +5658,25 @@ function debounce(e, t, r) {
|
|
5658
5658
|
function m() {
|
5659
5659
|
var C = now$1();
|
5660
5660
|
if (p(C))
|
5661
|
-
return
|
5661
|
+
return E(C);
|
5662
5662
|
o = setTimeout(m, _(C));
|
5663
5663
|
}
|
5664
|
-
function
|
5665
|
-
return o = void 0, g && a ?
|
5664
|
+
function E(C) {
|
5665
|
+
return o = void 0, g && a ? y(C) : (a = n = void 0, i);
|
5666
5666
|
}
|
5667
5667
|
function T() {
|
5668
5668
|
o !== void 0 && clearTimeout(o), c = 0, a = l = n = o = void 0;
|
5669
5669
|
}
|
5670
5670
|
function k() {
|
5671
|
-
return o === void 0 ? i :
|
5671
|
+
return o === void 0 ? i : E(now$1());
|
5672
5672
|
}
|
5673
5673
|
function A() {
|
5674
5674
|
var C = now$1(), M = p(C);
|
5675
5675
|
if (a = arguments, n = this, l = C, M) {
|
5676
5676
|
if (o === void 0)
|
5677
|
-
return
|
5677
|
+
return b(l);
|
5678
5678
|
if (d)
|
5679
|
-
return clearTimeout(o), o = setTimeout(m, t),
|
5679
|
+
return clearTimeout(o), o = setTimeout(m, t), y(l);
|
5680
5680
|
}
|
5681
5681
|
return o === void 0 && (o = setTimeout(m, t)), i;
|
5682
5682
|
}
|
@@ -5767,14 +5767,14 @@ function baseIntersection(e, t, r) {
|
|
5767
5767
|
var d = -1, g = o[0];
|
5768
5768
|
e:
|
5769
5769
|
for (; ++d < n && c.length < l; ) {
|
5770
|
-
var
|
5771
|
-
if (
|
5770
|
+
var y = u[d], b = t ? t(y) : y;
|
5771
|
+
if (y = r || y !== 0 ? y : 0, !(g ? cacheHas(g, b) : a(c, b, r))) {
|
5772
5772
|
for (i = s; --i; ) {
|
5773
5773
|
var _ = o[i];
|
5774
|
-
if (!(_ ? cacheHas(_,
|
5774
|
+
if (!(_ ? cacheHas(_, b) : a(e[i], b, r)))
|
5775
5775
|
continue e;
|
5776
5776
|
}
|
5777
|
-
g && g.push(
|
5777
|
+
g && g.push(b), c.push(y);
|
5778
5778
|
}
|
5779
5779
|
}
|
5780
5780
|
return c;
|
@@ -5983,7 +5983,10 @@ const without$1 = without, en = {
|
|
5983
5983
|
canNotUpdateSystemVarGridMaster: "System grid view cannot be changed, create a new one based on it ?",
|
5984
5984
|
column: "Column",
|
5985
5985
|
config: "Config",
|
5986
|
+
"dynamic-query-is-off-in-server": "API NOT SUPPORT DYNAMIC QUERY.",
|
5986
5987
|
emptyText: "Too many data, please click the Query button to load.",
|
5988
|
+
"request-fail-error": "REQUEST FAIL.",
|
5989
|
+
"request-fail-no-data": "REQUEST FAIL, NO DATA.",
|
5987
5990
|
rowHeight: "Row Height",
|
5988
5991
|
rowHeightH: "High",
|
5989
5992
|
rowHeightL: "Low",
|
@@ -6172,7 +6175,10 @@ const without$1 = without, en = {
|
|
6172
6175
|
canNotUpdateSystemVarGridMaster: "\u7CFB\u7EDF\u89C6\u56FE\u4E0D\u5141\u8BB8\u88AB\u4FEE\u6539, \u5C06\u57FA\u4E8E\u5B83\u53E6\u5B58\u4E00\u4E2A\u65B0\u7684\u89C6\u56FE ?",
|
6173
6176
|
column: "\u5B57\u6BB5",
|
6174
6177
|
config: "\u914D\u7F6E",
|
6178
|
+
"dynamic-query-is-off-in-server": "\u67E5\u8BE2\u63A5\u53E3\u5C1A\u4E0D\u652F\u6301\u9AD8\u7EA7\u67E5\u8BE2.",
|
6175
6179
|
emptyText: "\u5F53\u524D\u6570\u636E\u91CF\u5927, \u8BF7\u70B9\u51FB\u67E5\u8BE2\u52A0\u8F7D\u6570\u636E.",
|
6180
|
+
"request-fail-error": "\u8BF7\u6C42\u5931\u8D25.",
|
6181
|
+
"request-fail-no-data": "\u8BF7\u6C42\u5931\u8D25, \u54CD\u5E94\u5185\u5BB9\u4E3A\u7A7A.",
|
6176
6182
|
rowHeight: "\u884C\u9AD8",
|
6177
6183
|
rowHeightH: "\u9AD8",
|
6178
6184
|
rowHeightL: "\u4F4E",
|
@@ -6311,7 +6317,8 @@ var KG_APP = /* @__PURE__ */ ((e) => (e.WMS_DATA_MANAGER = "data-manager", e.WMS
|
|
6311
6317
|
const KG_APPS = ["data-manager", "business-manager", "wcs", "sys"];
|
6312
6318
|
var KG_APP_PREFIX = /* @__PURE__ */ ((e) => (e.WMS_DATA_MANAGER = "/wms/data-manager", e.WMS_BUSINESS_MANAGER = "/wms/business-manager", e.WCS = "/wcs", e.SYS = "/sys", e))(KG_APP_PREFIX || {});
|
6313
6319
|
const KG_APP_PREFIXS = ["/wms/data-manager", "/wms/business-manager", "/wcs", "/sys"];
|
6314
|
-
var KG_FORM_ITEM_TYPE = /* @__PURE__ */ ((e) => (e.INPUT = "INPUT", e.INPUT_PASSWORD = "INPUT_PASSWORD", e.INPUT_NUMBER = "INPUT_NUMBER", e.TEXT_AREA = "TEXT_AREA", e.CHECKBOX = "CHECKBOX", e.CHECKBOX_GROUP = "CHECKBOX_GROUP", e.RADIO_GROUP = "RADIO_GROUP", e.SWITCH = "SWITCH", e.SELECT = "SELECT", e.SELECT_MULTIPLE = "SELECT_MULTIPLE", e.DATE_DATE = "DATE_DATE", e.DATE_DATE_RANGE = "DATE_DATE_RANGE", e.DATE_TIME = "DATE_TIME", e.DATE_TIME_RANGE = "DATE_TIME_RANGE", e.DATE_DATETIME = "DATE_DATETIME", e.DATE_DATETIME_RANGE = "DATE_DATETIME_RANGE", e.DATE_WEEK = "DATE_WEEK", e.DATE_MONTH = "DATE_MONTH", e.DATE_YEAR = "DATE_YEAR", e.BUTTON_UPLOAD = "BUTTON_UPLOAD", e))(KG_FORM_ITEM_TYPE || {}), KG_FORM_CONTEXT = /* @__PURE__ */ ((e) => (e.SEARCH = "SEARCH", e.SUBMIT = "SUBMIT", e.TABLE = "TABLE", e))(KG_FORM_CONTEXT || {}), KG_TABLE_CELL_DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.YN = "YN", e.ENUM = "ENUM", e.PROGRESS = "PROGRESS", e.FILE_SIZE = "FILE_SIZE", e.UPDATE_LINK = "UPDATE_LINK", e.ROUTE_LINK = "ROUTE_LINK", e.DESC = "DESC", e))(KG_TABLE_CELL_DISPLAY_TYPE || {}), KG_BUTTON_TYPE = /* @__PURE__ */ ((e) => (e.CREATE = "CREATE", e.UPDATE = "UPDATE", e.COPY = "COPY", e.DELETE = "DELETE", e.IMPORT = "IMPORT", e.IMPORT_TEMPLATE = "IMPORT_TEMPLATE", e.EXPORT = "EXPORT", e.SEARCH = "SEARCH", e.REFRESH = "REFRESH", e.OTHER = "OTHER", e))(KG_BUTTON_TYPE || {}), KG_BUTTON_COLOR = /* @__PURE__ */ ((e) => (e.DANGER = "DANGER", e.WARN = "WARN", e))(KG_BUTTON_COLOR || {}), KG_BUTTON_DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.DEFAULT = "DEFAULT", e.SELECT = "SELECT", e))(KG_BUTTON_DISPLAY_TYPE || {}), KG_VAR_SUBMIT__DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.MODAL = "MODAL", e.DRAWER = "DRAWER", e.TABLE = "TABLE", e))(KG_VAR_SUBMIT__DISPLAY_TYPE || {}), KG_VAR_SUBMIT__LAYOUT = /* @__PURE__ */ ((e) => (e.VERTICAL = "vertical", e.HORIZONTAL = "horizontal", e))(KG_VAR_SUBMIT__LAYOUT || {}), KG_VAR_INPUT__DATA_TYPE = /* @__PURE__ */ ((e) => (e.NUMBER = "NUMBER", e))(KG_VAR_INPUT__DATA_TYPE || {}), KG_CUSTOM_LEVEL = /* @__PURE__ */ ((e) => (e[e.L0 = 0] = "L0", e[e.L10 = 10] = "L10", e))(KG_CUSTOM_LEVEL || {}), KG_POSSIBILITY_DATA_TYPE = /* @__PURE__ */ ((e) => (e.STRING = "string", e.NUMBER = "number", e.BOOLEAN = "boolean", e))(KG_POSSIBILITY_DATA_TYPE || {}), KG_WIDTH_UNIT = /* @__PURE__ */ ((e) => (e.SPAN = "SPAN", e.PX = "PX", e))(KG_WIDTH_UNIT || {}), KG_EXCEL_SUFFIX = /* @__PURE__ */ ((e) => (e.XLS = "xls", e.XLSX = "xlsx", e))(KG_EXCEL_SUFFIX || {}), KG_DESCRIPTION_CODE_NAME = /* @__PURE__ */ ((e) => (e.YN = "yn", e.VAR_SUBMIT_LAYOUT = "var_submit_layout", e.VAR_SPAN = "var_span", e.VAR_BUTTON_DISPLAY_TYPE = "var_button_display_type", e.VAR_WIDTH_UNIT = "var_width_unit", e))(KG_DESCRIPTION_CODE_NAME || {}), KG_DYNAMIC_QUERY_OPERATOR = /* @__PURE__ */ ((e) => (e.EQ = "eq", e.NE = "ne", e.GT = "gt", e.LT = "lt", e.GTE = "gte", e.LTE = "lte", e.START_WITH = "start", e.END_WITH = "end", e.CONTAIN = "contain", e.IN = "in", e.BETWEEN = "between", e))(KG_DYNAMIC_QUERY_OPERATOR || {}), KG_HTTP_HEADERS = /* @__PURE__ */ ((e) => (e.
|
6320
|
+
var KG_FORM_ITEM_TYPE = /* @__PURE__ */ ((e) => (e.INPUT = "INPUT", e.INPUT_PASSWORD = "INPUT_PASSWORD", e.INPUT_NUMBER = "INPUT_NUMBER", e.TEXT_AREA = "TEXT_AREA", e.CHECKBOX = "CHECKBOX", e.CHECKBOX_GROUP = "CHECKBOX_GROUP", e.RADIO_GROUP = "RADIO_GROUP", e.SWITCH = "SWITCH", e.SELECT = "SELECT", e.SELECT_MULTIPLE = "SELECT_MULTIPLE", e.DATE_DATE = "DATE_DATE", e.DATE_DATE_RANGE = "DATE_DATE_RANGE", e.DATE_TIME = "DATE_TIME", e.DATE_TIME_RANGE = "DATE_TIME_RANGE", e.DATE_DATETIME = "DATE_DATETIME", e.DATE_DATETIME_RANGE = "DATE_DATETIME_RANGE", e.DATE_WEEK = "DATE_WEEK", e.DATE_MONTH = "DATE_MONTH", e.DATE_YEAR = "DATE_YEAR", e.BUTTON_UPLOAD = "BUTTON_UPLOAD", e))(KG_FORM_ITEM_TYPE || {}), KG_FORM_CONTEXT = /* @__PURE__ */ ((e) => (e.SEARCH = "SEARCH", e.SUBMIT = "SUBMIT", e.TABLE = "TABLE", e))(KG_FORM_CONTEXT || {}), KG_TABLE_CELL_DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.YN = "YN", e.ENUM = "ENUM", e.PROGRESS = "PROGRESS", e.FILE_SIZE = "FILE_SIZE", e.UPDATE_LINK = "UPDATE_LINK", e.ROUTE_LINK = "ROUTE_LINK", e.DESC = "DESC", e))(KG_TABLE_CELL_DISPLAY_TYPE || {}), KG_BUTTON_TYPE = /* @__PURE__ */ ((e) => (e.CREATE = "CREATE", e.UPDATE = "UPDATE", e.COPY = "COPY", e.DELETE = "DELETE", e.IMPORT = "IMPORT", e.IMPORT_TEMPLATE = "IMPORT_TEMPLATE", e.EXPORT = "EXPORT", e.SEARCH = "SEARCH", e.REFRESH = "REFRESH", e.OTHER = "OTHER", e))(KG_BUTTON_TYPE || {}), KG_BUTTON_COLOR = /* @__PURE__ */ ((e) => (e.DANGER = "DANGER", e.WARN = "WARN", e))(KG_BUTTON_COLOR || {}), KG_BUTTON_DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.DEFAULT = "DEFAULT", e.SELECT = "SELECT", e))(KG_BUTTON_DISPLAY_TYPE || {}), KG_VAR_SUBMIT__DISPLAY_TYPE = /* @__PURE__ */ ((e) => (e.MODAL = "MODAL", e.DRAWER = "DRAWER", e.TABLE = "TABLE", e))(KG_VAR_SUBMIT__DISPLAY_TYPE || {}), KG_VAR_SUBMIT__LAYOUT = /* @__PURE__ */ ((e) => (e.VERTICAL = "vertical", e.HORIZONTAL = "horizontal", e))(KG_VAR_SUBMIT__LAYOUT || {}), KG_VAR_INPUT__DATA_TYPE = /* @__PURE__ */ ((e) => (e.NUMBER = "NUMBER", e))(KG_VAR_INPUT__DATA_TYPE || {}), KG_CUSTOM_LEVEL = /* @__PURE__ */ ((e) => (e[e.L0 = 0] = "L0", e[e.L10 = 10] = "L10", e))(KG_CUSTOM_LEVEL || {}), KG_POSSIBILITY_DATA_TYPE = /* @__PURE__ */ ((e) => (e.STRING = "string", e.NUMBER = "number", e.BOOLEAN = "boolean", e))(KG_POSSIBILITY_DATA_TYPE || {}), KG_WIDTH_UNIT = /* @__PURE__ */ ((e) => (e.SPAN = "SPAN", e.PX = "PX", e))(KG_WIDTH_UNIT || {}), KG_EXCEL_SUFFIX = /* @__PURE__ */ ((e) => (e.XLS = "xls", e.XLSX = "xlsx", e))(KG_EXCEL_SUFFIX || {}), KG_DESCRIPTION_CODE_NAME = /* @__PURE__ */ ((e) => (e.YN = "yn", e.VAR_SUBMIT_LAYOUT = "var_submit_layout", e.VAR_SPAN = "var_span", e.VAR_BUTTON_DISPLAY_TYPE = "var_button_display_type", e.VAR_WIDTH_UNIT = "var_width_unit", e))(KG_DESCRIPTION_CODE_NAME || {}), KG_DYNAMIC_QUERY_OPERATOR = /* @__PURE__ */ ((e) => (e.EQ = "eq", e.NE = "ne", e.GT = "gt", e.LT = "lt", e.GTE = "gte", e.LTE = "lte", e.START_WITH = "start", e.END_WITH = "end", e.CONTAIN = "contain", e.IN = "in", e.BETWEEN = "between", e))(KG_DYNAMIC_QUERY_OPERATOR || {}), KG_HTTP_HEADERS = /* @__PURE__ */ ((e) => (e.KG_DYNAMIC_QUERY = "Kg-Dynamic-Query", e.KG_QUERY_SQL = "Kg-Query-Sql", e))(KG_HTTP_HEADERS || {});
|
6321
|
+
const __KG__RESPONSE__ = "__KG__RESPONSE__";
|
6315
6322
|
class KgLogger {
|
6316
6323
|
static deprecated(t, r = {}, a = !0) {
|
6317
6324
|
KgLogger.log("deprecated", t, r, a);
|
@@ -6453,31 +6460,30 @@ class KgUtil {
|
|
6453
6460
|
}
|
6454
6461
|
}), s);
|
6455
6462
|
}
|
6456
|
-
static
|
6457
|
-
var E, _, p;
|
6463
|
+
static getQuerySql(t, r, a) {
|
6458
6464
|
let n = toRaw(unref(t));
|
6459
6465
|
if (!n || !isObjectLike(n) || !r)
|
6460
6466
|
return "";
|
6461
|
-
const s = useKg(), i = useKgVar(r);
|
6462
|
-
|
6463
|
-
|
6464
|
-
|
6465
|
-
|
6466
|
-
if (l.includes(m)) {
|
6467
|
-
o[m] = n[m];
|
6467
|
+
const s = useKg(), i = useKgVar(r), o = {}, l = ["pageNo", "pageSize", "column", "order"], u = useKgSearch(r).operatorModel.value;
|
6468
|
+
Object.keys(n).sort().forEach((b) => {
|
6469
|
+
var k, A, C;
|
6470
|
+
if (l.includes(b)) {
|
6471
|
+
o[b] = n[b];
|
6468
6472
|
return;
|
6469
6473
|
}
|
6470
|
-
const
|
6471
|
-
let
|
6472
|
-
|
6473
|
-
|
6474
|
-
|
6474
|
+
const _ = i.store.getVarProfileDetail(r, b), p = _ != null && _.table_alias ? `${_ == null ? void 0 : _.table_alias}.` : "", m = n[b];
|
6475
|
+
let E = u == null ? void 0 : u[b];
|
6476
|
+
(((A = (k = s.option.value.KgSearch) == null ? void 0 : k.dynamicQuery) == null ? void 0 : A.on) !== !0 || ((C = i.currentVarProfileMaster.value) == null ? void 0 : C.dyn_flg) !== 1) && (E = KG_DYNAMIC_QUERY_OPERATOR.EQ);
|
6477
|
+
let T = b;
|
6478
|
+
switch ((_ == null ? void 0 : _.use_underscore_when_dynamic_query_flag) !== 0 && (T = snakeCase$1(b)), !0) {
|
6479
|
+
case b.endsWith("_obj"): {
|
6480
|
+
o[b] = void 0;
|
6475
6481
|
break;
|
6476
6482
|
}
|
6477
|
-
case (!!a && a.isDayjs(
|
6478
|
-
const M =
|
6479
|
-
let w = this.parseParamFromDayJS(
|
6480
|
-
switch (
|
6483
|
+
case (!!a && a.isDayjs(m)): {
|
6484
|
+
const M = m;
|
6485
|
+
let w = this.parseParamFromDayJS(b, M, r);
|
6486
|
+
switch (E) {
|
6481
6487
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6482
6488
|
let I = w, R = "";
|
6483
6489
|
switch (!0) {
|
@@ -6496,7 +6502,7 @@ class KgUtil {
|
|
6496
6502
|
default:
|
6497
6503
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6498
6504
|
}
|
6499
|
-
w = ` AND (${
|
6505
|
+
w = ` AND (${p}${T} < '${I}' OR ${p}${T} >= '${R}')`;
|
6500
6506
|
break;
|
6501
6507
|
}
|
6502
6508
|
case KG_DYNAMIC_QUERY_OPERATOR.LT: {
|
@@ -6513,7 +6519,7 @@ class KgUtil {
|
|
6513
6519
|
default:
|
6514
6520
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6515
6521
|
}
|
6516
|
-
w = ` AND (${
|
6522
|
+
w = ` AND (${p}${T} < '${I}')`;
|
6517
6523
|
break;
|
6518
6524
|
}
|
6519
6525
|
case KG_DYNAMIC_QUERY_OPERATOR.LTE: {
|
@@ -6534,7 +6540,7 @@ class KgUtil {
|
|
6534
6540
|
default:
|
6535
6541
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6536
6542
|
}
|
6537
|
-
w = ` AND (${
|
6543
|
+
w = ` AND (${p}${T} < '${R}')`;
|
6538
6544
|
break;
|
6539
6545
|
}
|
6540
6546
|
case KG_DYNAMIC_QUERY_OPERATOR.GT: {
|
@@ -6555,7 +6561,7 @@ class KgUtil {
|
|
6555
6561
|
default:
|
6556
6562
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6557
6563
|
}
|
6558
|
-
w = ` AND (${
|
6564
|
+
w = ` AND (${p}${T} >= '${R}')`;
|
6559
6565
|
break;
|
6560
6566
|
}
|
6561
6567
|
case KG_DYNAMIC_QUERY_OPERATOR.GTE: {
|
@@ -6572,7 +6578,7 @@ class KgUtil {
|
|
6572
6578
|
default:
|
6573
6579
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6574
6580
|
}
|
6575
|
-
w = ` AND (${
|
6581
|
+
w = ` AND (${p}${T} >= '${I}')`;
|
6576
6582
|
break;
|
6577
6583
|
}
|
6578
6584
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
@@ -6594,16 +6600,16 @@ class KgUtil {
|
|
6594
6600
|
default:
|
6595
6601
|
throw new Error("KgUtil.parseParamsForDynamicQuery() | \u65E5\u671F\u683C\u5F0F\u6709\u8BEF.");
|
6596
6602
|
}
|
6597
|
-
w = ` AND (${
|
6603
|
+
w = ` AND (${p}${T} >= '${I}' AND ${p}${T} < '${R}')`;
|
6598
6604
|
break;
|
6599
6605
|
}
|
6600
6606
|
}
|
6601
|
-
o[
|
6607
|
+
o[b] = w;
|
6602
6608
|
break;
|
6603
6609
|
}
|
6604
|
-
case (!!a && isArray$1(
|
6605
|
-
const M =
|
6606
|
-
let I = this.parseParamFromDayJS(
|
6610
|
+
case (!!a && isArray$1(m) && m.length === 2 && a.isDayjs(m[0]) && a.isDayjs(m[1])): {
|
6611
|
+
const M = m[0], w = m[1];
|
6612
|
+
let I = this.parseParamFromDayJS(b, M, r), R = "", P = "";
|
6607
6613
|
switch (!0) {
|
6608
6614
|
case /\d\d-\d\d-\d\d \d\d:\d\d:\d\d/.test(I): {
|
6609
6615
|
R = w.add(1, "second").format("YYYY-MM-DD HH:mm:ss");
|
@@ -6618,120 +6624,120 @@ class KgUtil {
|
|
6618
6624
|
break;
|
6619
6625
|
}
|
6620
6626
|
}
|
6621
|
-
R ? P = ` AND (${
|
6627
|
+
R ? P = ` AND (${p}${T} >= '${I}' AND ${p}${T} < '${R}')` : P = ` AND (${p}${T} >= '${I}')`, o[b] = P;
|
6622
6628
|
break;
|
6623
6629
|
}
|
6624
|
-
case Array.isArray(
|
6625
|
-
if (
|
6626
|
-
o[
|
6630
|
+
case Array.isArray(m): {
|
6631
|
+
if (m.length === 0) {
|
6632
|
+
o[b] = void 0;
|
6627
6633
|
break;
|
6628
6634
|
}
|
6629
|
-
const M =
|
6630
|
-
o[
|
6635
|
+
const M = m.map((w) => `N'${String(w)}'`).join(", ");
|
6636
|
+
o[b] = ` AND (${p}${T} IN (${M}))`;
|
6631
6637
|
break;
|
6632
6638
|
}
|
6633
|
-
case isObjectLike(
|
6634
|
-
throw KgLogger.error("\u4E0D\u652F\u6301\u7684\u53C2\u6570\u7C7B\u578B.", { value:
|
6635
|
-
case typeof
|
6636
|
-
if (
|
6637
|
-
o[
|
6639
|
+
case isObjectLike(m):
|
6640
|
+
throw KgLogger.error("\u4E0D\u652F\u6301\u7684\u53C2\u6570\u7C7B\u578B.", { value: m }), new Error("\u4E0D\u652F\u6301\u7684\u53C2\u6570\u7C7B\u578B.");
|
6641
|
+
case typeof m == "string": {
|
6642
|
+
if (m.trim() === "") {
|
6643
|
+
o[b] = void 0;
|
6638
6644
|
break;
|
6639
6645
|
}
|
6640
|
-
let M = this.parseParamFromString(
|
6641
|
-
switch (
|
6646
|
+
let M = this.parseParamFromString(m);
|
6647
|
+
switch (E) {
|
6642
6648
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6643
|
-
M = ` AND (${
|
6649
|
+
M = ` AND (${p}${T} <> N'${M}')`;
|
6644
6650
|
break;
|
6645
6651
|
}
|
6646
6652
|
case KG_DYNAMIC_QUERY_OPERATOR.START_WITH: {
|
6647
|
-
M = ` AND (${
|
6653
|
+
M = ` AND (${p}${T} LIKE N'${M}%')`;
|
6648
6654
|
break;
|
6649
6655
|
}
|
6650
6656
|
case KG_DYNAMIC_QUERY_OPERATOR.END_WITH: {
|
6651
|
-
M = ` AND (${
|
6657
|
+
M = ` AND (${p}${T} LIKE N'%${M}')`;
|
6652
6658
|
break;
|
6653
6659
|
}
|
6654
6660
|
case KG_DYNAMIC_QUERY_OPERATOR.CONTAIN: {
|
6655
|
-
M = ` AND (${
|
6661
|
+
M = ` AND (${p}${T} LIKE N'%${M}%')`;
|
6656
6662
|
break;
|
6657
6663
|
}
|
6658
6664
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6659
6665
|
default: {
|
6660
|
-
M = ` AND (${
|
6666
|
+
M = ` AND (${p}${T} = N'${M}')`;
|
6661
6667
|
break;
|
6662
6668
|
}
|
6663
6669
|
}
|
6664
|
-
o[
|
6670
|
+
o[b] = M;
|
6665
6671
|
break;
|
6666
6672
|
}
|
6667
|
-
case typeof
|
6673
|
+
case typeof m == "number": {
|
6668
6674
|
let M = "";
|
6669
|
-
switch (
|
6675
|
+
switch (E) {
|
6670
6676
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6671
|
-
M = ` AND (${
|
6677
|
+
M = ` AND (${p}${T} <> ${m})`;
|
6672
6678
|
break;
|
6673
6679
|
}
|
6674
6680
|
case KG_DYNAMIC_QUERY_OPERATOR.LT: {
|
6675
|
-
M = ` AND (${
|
6681
|
+
M = ` AND (${p}${T} < ${m})`;
|
6676
6682
|
break;
|
6677
6683
|
}
|
6678
6684
|
case KG_DYNAMIC_QUERY_OPERATOR.LTE: {
|
6679
|
-
M = ` AND (${
|
6685
|
+
M = ` AND (${p}${T} <= ${m})`;
|
6680
6686
|
break;
|
6681
6687
|
}
|
6682
6688
|
case KG_DYNAMIC_QUERY_OPERATOR.GT: {
|
6683
|
-
M = ` AND (${
|
6689
|
+
M = ` AND (${p}${T} > ${m})`;
|
6684
6690
|
break;
|
6685
6691
|
}
|
6686
6692
|
case KG_DYNAMIC_QUERY_OPERATOR.GTE: {
|
6687
|
-
M = ` AND (${
|
6693
|
+
M = ` AND (${p}${T} >= ${m})`;
|
6688
6694
|
break;
|
6689
6695
|
}
|
6690
6696
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6691
6697
|
default: {
|
6692
|
-
M = ` AND (${
|
6698
|
+
M = ` AND (${p}${T} = ${m})`;
|
6693
6699
|
break;
|
6694
6700
|
}
|
6695
6701
|
}
|
6696
|
-
o[
|
6702
|
+
o[b] = M;
|
6697
6703
|
break;
|
6698
6704
|
}
|
6699
|
-
case typeof
|
6705
|
+
case typeof m == "boolean": {
|
6700
6706
|
let M = "";
|
6701
|
-
switch (
|
6707
|
+
switch (E) {
|
6702
6708
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6703
|
-
M = ` AND (${
|
6709
|
+
M = ` AND (${p}${T} <> ${m ? 1 : 0})`;
|
6704
6710
|
break;
|
6705
6711
|
}
|
6706
6712
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6707
6713
|
default: {
|
6708
|
-
M = ` AND (${
|
6714
|
+
M = ` AND (${p}${T} = ${m ? 1 : 0})`;
|
6709
6715
|
break;
|
6710
6716
|
}
|
6711
6717
|
}
|
6712
|
-
o[
|
6718
|
+
o[b] = M;
|
6713
6719
|
break;
|
6714
6720
|
}
|
6715
6721
|
default: {
|
6716
|
-
o[
|
6722
|
+
o[b] = m;
|
6717
6723
|
break;
|
6718
6724
|
}
|
6719
6725
|
}
|
6720
6726
|
});
|
6721
6727
|
const d = reduce(
|
6722
6728
|
o,
|
6723
|
-
(
|
6729
|
+
(b, _, p) => l.includes(p) || !_ ? b : b + _,
|
6724
6730
|
""
|
6725
6731
|
);
|
6726
6732
|
let g = "";
|
6727
6733
|
d.trim() && (g = `WHERE${d}`), g = g.replace("WHERE AND", "WHERE");
|
6728
|
-
let
|
6734
|
+
let y = "";
|
6729
6735
|
if (n.column) {
|
6730
|
-
const
|
6731
|
-
let
|
6732
|
-
(
|
6736
|
+
const b = i.store.getVarProfileDetail(r, n.column), _ = b != null && b.table_alias ? `${b == null ? void 0 : b.table_alias}.` : "";
|
6737
|
+
let p = n.column;
|
6738
|
+
(b == null ? void 0 : b.use_underscore_when_dynamic_query_flag) !== 0 && (p = snakeCase$1(n.column)), y = ` ORDER BY ${_}${p}`, n.order === "asc" ? y += " ASC" : n.order === "desc" && (y += " DESC");
|
6733
6739
|
}
|
6734
|
-
return g +
|
6740
|
+
return g + y;
|
6735
6741
|
}
|
6736
6742
|
static parseParamFromString(t) {
|
6737
6743
|
var n, s, i, o, l;
|
@@ -6758,7 +6764,7 @@ class KgUtil {
|
|
6758
6764
|
if (!i)
|
6759
6765
|
return r;
|
6760
6766
|
switch ((() => {
|
6761
|
-
const l = i.ctrl_typ, c = i.prf_ctrl_typ, u = i.crt_ctrl_typ, d = i.upt_ctrl_typ, g = i.cpy_ctrl_typ,
|
6767
|
+
const l = i.ctrl_typ, c = i.prf_ctrl_typ, u = i.crt_ctrl_typ, d = i.upt_ctrl_typ, g = i.cpy_ctrl_typ, y = i.del_ctrl_typ;
|
6762
6768
|
switch (!0) {
|
6763
6769
|
case s.isRetrieving.value:
|
6764
6770
|
return c || l;
|
@@ -6769,7 +6775,7 @@ class KgUtil {
|
|
6769
6775
|
case n.isCopying.value:
|
6770
6776
|
return g || l;
|
6771
6777
|
case n.isDeleting.value:
|
6772
|
-
return
|
6778
|
+
return y || l;
|
6773
6779
|
}
|
6774
6780
|
return l;
|
6775
6781
|
})()) {
|
@@ -6958,7 +6964,7 @@ class KgVarUtil {
|
|
6958
6964
|
return r;
|
6959
6965
|
}
|
6960
6966
|
static transformFormItemValue(t, r, a, n, s) {
|
6961
|
-
var g,
|
6967
|
+
var g, y, b;
|
6962
6968
|
const i = useKg(), o = useKgVar(t);
|
6963
6969
|
let l = n;
|
6964
6970
|
const c = /(.*)?({(.*)?})(.*)?/.exec(l);
|
@@ -6969,7 +6975,7 @@ class KgVarUtil {
|
|
6969
6975
|
l = l.replace("{NOW}", a().format("YYYY-MM-DD HH:mm:ss"));
|
6970
6976
|
break;
|
6971
6977
|
case "{USER.username}":
|
6972
|
-
l = l.replace("{USER.username}", (
|
6978
|
+
l = l.replace("{USER.username}", (b = (y = (g = i.store).getUseUserStore) == null ? void 0 : y.call(g).userInfo) == null ? void 0 : b.username);
|
6973
6979
|
break;
|
6974
6980
|
}
|
6975
6981
|
}
|
@@ -6977,14 +6983,14 @@ class KgVarUtil {
|
|
6977
6983
|
if (!u)
|
6978
6984
|
return l;
|
6979
6985
|
const d = (() => {
|
6980
|
-
const _ = u.ctrl_typ, p = u.prf_ctrl_typ, m = u.crt_ctrl_typ,
|
6986
|
+
const _ = u.ctrl_typ, p = u.prf_ctrl_typ, m = u.crt_ctrl_typ, E = u.upt_ctrl_typ, T = u.cpy_ctrl_typ, k = u.del_ctrl_typ;
|
6981
6987
|
switch (s) {
|
6982
6988
|
case "R":
|
6983
6989
|
return p || _;
|
6984
6990
|
case "C":
|
6985
6991
|
return m || _;
|
6986
6992
|
case "U":
|
6987
|
-
return
|
6993
|
+
return E || _;
|
6988
6994
|
case "CP":
|
6989
6995
|
return T || _;
|
6990
6996
|
case "D":
|
@@ -7081,8 +7087,8 @@ class KgVarUtil {
|
|
7081
7087
|
const p = o.store.getVarPossibility(t, r);
|
7082
7088
|
switch (p == null ? void 0 : p.val_data_type) {
|
7083
7089
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER: {
|
7084
|
-
const m = _.map((
|
7085
|
-
if (m.some((
|
7090
|
+
const m = _.map((E) => Number(E));
|
7091
|
+
if (m.some((E) => Number.isNaN(m))) {
|
7086
7092
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A number \u6570\u7EC4\u7C7B\u578B.`, {
|
7087
7093
|
frm_id: t,
|
7088
7094
|
var_nam: r,
|
@@ -7205,61 +7211,61 @@ class KgVarUtil {
|
|
7205
7211
|
}
|
7206
7212
|
static getDynamicQueryOperatorSelectOptions(t) {
|
7207
7213
|
let r, a, n, s, i, o, l, c, u, d, g;
|
7208
|
-
const
|
7214
|
+
const y = useKg();
|
7209
7215
|
return createVNode(Fragment, null, [[KG_FORM_ITEM_TYPE.INPUT, KG_FORM_ITEM_TYPE.TEXT_AREA, KG_FORM_ITEM_TYPE.INPUT_NUMBER, KG_FORM_ITEM_TYPE.DATE_DATE, KG_FORM_ITEM_TYPE.DATE_TIME, KG_FORM_ITEM_TYPE.DATE_DATETIME, KG_FORM_ITEM_TYPE.DATE_WEEK, KG_FORM_ITEM_TYPE.DATE_MONTH, KG_FORM_ITEM_TYPE.DATE_YEAR, KG_FORM_ITEM_TYPE.CHECKBOX, KG_FORM_ITEM_TYPE.SWITCH, KG_FORM_ITEM_TYPE.SELECT, KG_FORM_ITEM_TYPE.RADIO_GROUP].includes(t) && createVNode(Fragment, null, [createVNode(Select.Option, {
|
7210
|
-
title:
|
7216
|
+
title: y.t("kg.KgSearchConfigModal.EQ-desc"),
|
7211
7217
|
value: KG_DYNAMIC_QUERY_OPERATOR.EQ
|
7212
|
-
}, _isSlot$d(r =
|
7218
|
+
}, _isSlot$d(r = y.t("kg.KgSearchConfigModal.EQ")) ? r : {
|
7213
7219
|
default: () => [r]
|
7214
7220
|
}), createVNode(Select.Option, {
|
7215
|
-
title:
|
7221
|
+
title: y.t("kg.KgSearchConfigModal.NE-desc"),
|
7216
7222
|
value: KG_DYNAMIC_QUERY_OPERATOR.NE
|
7217
|
-
}, _isSlot$d(a =
|
7223
|
+
}, _isSlot$d(a = y.t("kg.KgSearchConfigModal.NE")) ? a : {
|
7218
7224
|
default: () => [a]
|
7219
7225
|
})]), [KG_FORM_ITEM_TYPE.INPUT_NUMBER, KG_FORM_ITEM_TYPE.DATE_DATE, KG_FORM_ITEM_TYPE.DATE_TIME, KG_FORM_ITEM_TYPE.DATE_DATETIME, KG_FORM_ITEM_TYPE.DATE_WEEK, KG_FORM_ITEM_TYPE.DATE_MONTH, KG_FORM_ITEM_TYPE.DATE_YEAR].includes(t) && createVNode(Fragment, null, [createVNode(Select.Option, {
|
7220
|
-
title:
|
7226
|
+
title: y.t("kg.KgSearchConfigModal.GT-desc"),
|
7221
7227
|
value: KG_DYNAMIC_QUERY_OPERATOR.GT
|
7222
|
-
}, _isSlot$d(n =
|
7228
|
+
}, _isSlot$d(n = y.t("kg.KgSearchConfigModal.GT")) ? n : {
|
7223
7229
|
default: () => [n]
|
7224
7230
|
}), createVNode(Select.Option, {
|
7225
|
-
title:
|
7231
|
+
title: y.t("kg.KgSearchConfigModal.GTE-desc"),
|
7226
7232
|
value: KG_DYNAMIC_QUERY_OPERATOR.GTE
|
7227
|
-
}, _isSlot$d(s =
|
7233
|
+
}, _isSlot$d(s = y.t("kg.KgSearchConfigModal.GTE")) ? s : {
|
7228
7234
|
default: () => [s]
|
7229
7235
|
}), createVNode(Select.Option, {
|
7230
|
-
title:
|
7236
|
+
title: y.t("kg.KgSearchConfigModal.LT-desc"),
|
7231
7237
|
value: KG_DYNAMIC_QUERY_OPERATOR.LT
|
7232
|
-
}, _isSlot$d(i =
|
7238
|
+
}, _isSlot$d(i = y.t("kg.KgSearchConfigModal.LT")) ? i : {
|
7233
7239
|
default: () => [i]
|
7234
7240
|
}), createVNode(Select.Option, {
|
7235
|
-
title:
|
7241
|
+
title: y.t("kg.KgSearchConfigModal.LTE-desc"),
|
7236
7242
|
value: KG_DYNAMIC_QUERY_OPERATOR.LTE
|
7237
|
-
}, _isSlot$d(o =
|
7243
|
+
}, _isSlot$d(o = y.t("kg.KgSearchConfigModal.LTE")) ? o : {
|
7238
7244
|
default: () => [o]
|
7239
7245
|
})]), [KG_FORM_ITEM_TYPE.INPUT, KG_FORM_ITEM_TYPE.TEXT_AREA].includes(t) && createVNode(Fragment, null, [createVNode(Select.Option, {
|
7240
|
-
title:
|
7246
|
+
title: y.t("kg.KgSearchConfigModal.START_WITH-desc"),
|
7241
7247
|
value: KG_DYNAMIC_QUERY_OPERATOR.START_WITH
|
7242
|
-
}, _isSlot$d(l =
|
7248
|
+
}, _isSlot$d(l = y.t("kg.KgSearchConfigModal.START_WITH")) ? l : {
|
7243
7249
|
default: () => [l]
|
7244
7250
|
}), createVNode(Select.Option, {
|
7245
|
-
title:
|
7251
|
+
title: y.t("kg.KgSearchConfigModal.END_WITH-desc"),
|
7246
7252
|
value: KG_DYNAMIC_QUERY_OPERATOR.END_WITH
|
7247
|
-
}, _isSlot$d(c =
|
7253
|
+
}, _isSlot$d(c = y.t("kg.KgSearchConfigModal.END_WITH")) ? c : {
|
7248
7254
|
default: () => [c]
|
7249
7255
|
}), createVNode(Select.Option, {
|
7250
|
-
title:
|
7256
|
+
title: y.t("kg.KgSearchConfigModal.CONTAIN-desc"),
|
7251
7257
|
value: KG_DYNAMIC_QUERY_OPERATOR.CONTAIN
|
7252
|
-
}, _isSlot$d(u =
|
7258
|
+
}, _isSlot$d(u = y.t("kg.KgSearchConfigModal.CONTAIN")) ? u : {
|
7253
7259
|
default: () => [u]
|
7254
7260
|
})]), [KG_FORM_ITEM_TYPE.CHECKBOX_GROUP, KG_FORM_ITEM_TYPE.SELECT_MULTIPLE].includes(t) && createVNode(Select.Option, {
|
7255
|
-
title:
|
7261
|
+
title: y.t("kg.KgSearchConfigModal.IN-desc"),
|
7256
7262
|
value: KG_DYNAMIC_QUERY_OPERATOR.IN
|
7257
|
-
}, _isSlot$d(d =
|
7263
|
+
}, _isSlot$d(d = y.t("kg.KgSearchConfigModal.IN")) ? d : {
|
7258
7264
|
default: () => [d]
|
7259
7265
|
}), [KG_FORM_ITEM_TYPE.DATE_DATE_RANGE, KG_FORM_ITEM_TYPE.DATE_TIME_RANGE, KG_FORM_ITEM_TYPE.DATE_DATETIME_RANGE].includes(t) && createVNode(Select.Option, {
|
7260
|
-
title:
|
7266
|
+
title: y.t("kg.KgSearchConfigModal.BETWEEN-desc"),
|
7261
7267
|
value: KG_DYNAMIC_QUERY_OPERATOR.BETWEEN
|
7262
|
-
}, _isSlot$d(g =
|
7268
|
+
}, _isSlot$d(g = y.t("kg.KgSearchConfigModal.BETWEEN")) ? g : {
|
7263
7269
|
default: () => [g]
|
7264
7270
|
})]);
|
7265
7271
|
}
|
@@ -7338,8 +7344,8 @@ function createOptionsStore(e, t, r, a) {
|
|
7338
7344
|
const u = process.env.NODE_ENV !== "production" && a ? toRefs(ref(n ? n() : {}).value) : toRefs(r.state.value[e]);
|
7339
7345
|
return assign$1(u, s, Object.keys(i || {}).reduce((d, g) => (d[g] = markRaw(computed(() => {
|
7340
7346
|
setActivePinia(r);
|
7341
|
-
const
|
7342
|
-
return i[g].call(
|
7347
|
+
const y = r._s.get(e);
|
7348
|
+
return i[g].call(y, y);
|
7343
7349
|
})), d), {}));
|
7344
7350
|
}
|
7345
7351
|
return l = createSetupStore(e, c, t, r, a), l.$reset = function() {
|
@@ -7358,23 +7364,23 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7358
7364
|
deep: !0
|
7359
7365
|
};
|
7360
7366
|
process.env.NODE_ENV !== "production" && !isVue2 && (l.onTrigger = (w) => {
|
7361
|
-
c ?
|
7367
|
+
c ? y = w : c == !1 && !C._hotUpdating && (Array.isArray(y) ? y.push(w) : console.error("\u{1F34D} debuggerEvents should be an array. This is most likely an internal Pinia bug."));
|
7362
7368
|
});
|
7363
|
-
let c, u, d = markRaw([]), g = markRaw([]),
|
7364
|
-
const
|
7365
|
-
!i && !
|
7369
|
+
let c, u, d = markRaw([]), g = markRaw([]), y;
|
7370
|
+
const b = a.state.value[e];
|
7371
|
+
!i && !b && (process.env.NODE_ENV === "production" || !n) && (a.state.value[e] = {});
|
7366
7372
|
const _ = ref({});
|
7367
7373
|
function p(w) {
|
7368
7374
|
let I;
|
7369
|
-
c = u = !1, process.env.NODE_ENV !== "production" && (
|
7375
|
+
c = u = !1, process.env.NODE_ENV !== "production" && (y = []), typeof w == "function" ? (w(a.state.value[e]), I = {
|
7370
7376
|
type: MutationType.patchFunction,
|
7371
7377
|
storeId: e,
|
7372
|
-
events:
|
7378
|
+
events: y
|
7373
7379
|
}) : (mergeReactiveObjects(a.state.value[e], w), I = {
|
7374
7380
|
type: MutationType.patchObject,
|
7375
7381
|
payload: w,
|
7376
7382
|
storeId: e,
|
7377
|
-
events:
|
7383
|
+
events: y
|
7378
7384
|
}), nextTick().then(() => {
|
7379
7385
|
c = !0;
|
7380
7386
|
}), u = !0, triggerSubscriptions(d, I, a.state.value[e]);
|
@@ -7382,7 +7388,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7382
7388
|
const m = process.env.NODE_ENV !== "production" ? () => {
|
7383
7389
|
throw new Error(`\u{1F34D}: Store "${e}" is build using the setup syntax and does not implement $reset().`);
|
7384
7390
|
} : noop$1;
|
7385
|
-
function
|
7391
|
+
function E() {
|
7386
7392
|
s.stop(), d = [], g = [], a._s.delete(e);
|
7387
7393
|
}
|
7388
7394
|
function T(w, I) {
|
@@ -7427,12 +7433,12 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7427
7433
|
(I.flush === "sync" ? u : c) && w({
|
7428
7434
|
storeId: e,
|
7429
7435
|
type: MutationType.direct,
|
7430
|
-
events:
|
7436
|
+
events: y
|
7431
7437
|
}, O);
|
7432
7438
|
}, assign$1({}, l, I)));
|
7433
7439
|
return R;
|
7434
7440
|
},
|
7435
|
-
$dispose:
|
7441
|
+
$dispose: E
|
7436
7442
|
}, C = reactive(assign$1(
|
7437
7443
|
process.env.NODE_ENV !== "production" && IS_CLIENT ? {
|
7438
7444
|
_customProperties: markRaw(/* @__PURE__ */ new Set()),
|
@@ -7445,7 +7451,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7445
7451
|
for (const w in M) {
|
7446
7452
|
const I = M[w];
|
7447
7453
|
if (isRef(I) && !isComputed(I) || isReactive(I))
|
7448
|
-
process.env.NODE_ENV !== "production" && n ? set(_.value, w, toRef(M, w)) : i || (
|
7454
|
+
process.env.NODE_ENV !== "production" && n ? set(_.value, w, toRef(M, w)) : i || (b && shouldHydrate(I) && (isRef(I) ? I.value = b[w] : mergeReactiveObjects(I, b[w])), a.state.value[e][w] = I), process.env.NODE_ENV !== "production" && k.state.push(w);
|
7449
7455
|
else if (typeof I == "function") {
|
7450
7456
|
const R = process.env.NODE_ENV !== "production" && n ? I : T(w, I);
|
7451
7457
|
M[w] = R, process.env.NODE_ENV !== "production" && (k.actions[w] = I), o.actions[w] = I;
|
@@ -7518,7 +7524,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7518
7524
|
})));
|
7519
7525
|
}), process.env.NODE_ENV !== "production" && C.$state && typeof C.$state == "object" && typeof C.$state.constructor == "function" && !C.$state.constructor.toString().includes("[native code]") && console.warn(`[\u{1F34D}]: The "state" must be a plain object. It cannot be
|
7520
7526
|
state: () => new MyClass()
|
7521
|
-
Found in store "${C.$id}".`),
|
7527
|
+
Found in store "${C.$id}".`), b && i && r.hydrate && r.hydrate(C.$state, b), c = !0, u = !0, C;
|
7522
7528
|
}
|
7523
7529
|
function defineStore(e, t, r) {
|
7524
7530
|
let a, n;
|
@@ -8060,18 +8066,18 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
8060
8066
|
slots: r
|
8061
8067
|
}) {
|
8062
8068
|
if (e.kgMaxHeight < e.kgMinHeight) {
|
8063
|
-
const
|
8064
|
-
throw KgLogger.error(
|
8069
|
+
const E = "[KgResizable] kgMaxHeight \u4E0D\u80FD\u5C0F\u4E8E kgMinHeight.";
|
8070
|
+
throw KgLogger.error(E, {
|
8065
8071
|
kgMaxHeight: e.kgMaxHeight,
|
8066
8072
|
kgMinHeight: e.kgMinHeight
|
8067
|
-
}), new Error(
|
8073
|
+
}), new Error(E);
|
8068
8074
|
}
|
8069
8075
|
if (e.kgMaxWidth < e.kgMinWidth) {
|
8070
|
-
const
|
8071
|
-
throw KgLogger.error(
|
8076
|
+
const E = "[KgResizable] kgMaxWidth \u4E0D\u80FD\u5C0F\u4E8E kgMinWidth.";
|
8077
|
+
throw KgLogger.error(E, {
|
8072
8078
|
kgMaxWidth: e.kgMaxWidth,
|
8073
8079
|
kgMinWidth: e.kgMinWidth
|
8074
|
-
}), new Error(
|
8080
|
+
}), new Error(E);
|
8075
8081
|
}
|
8076
8082
|
let a = 0, n = 0, s = 0, i = 0, o = {
|
8077
8083
|
remove: () => {
|
@@ -8094,22 +8100,22 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
8094
8100
|
};
|
8095
8101
|
}
|
8096
8102
|
}), u = computed(() => {
|
8097
|
-
let
|
8098
|
-
switch (e.kgClass && (
|
8103
|
+
let E = "";
|
8104
|
+
switch (e.kgClass && (E += `${e.kgClass} `), E += "kg-resizable", e.kgDisabled && (E += " kg-resizable--disabled"), e.kgType) {
|
8099
8105
|
case "left":
|
8100
|
-
|
8106
|
+
E += " kg-resizable--left";
|
8101
8107
|
break;
|
8102
8108
|
case "right":
|
8103
|
-
|
8109
|
+
E += " kg-resizable--right";
|
8104
8110
|
break;
|
8105
8111
|
case "top":
|
8106
|
-
|
8112
|
+
E += " kg-resizable--top";
|
8107
8113
|
break;
|
8108
8114
|
case "bottom":
|
8109
|
-
|
8115
|
+
E += " kg-resizable--bottom";
|
8110
8116
|
break;
|
8111
8117
|
}
|
8112
|
-
return
|
8118
|
+
return E;
|
8113
8119
|
});
|
8114
8120
|
function d() {
|
8115
8121
|
o.remove(), l.remove();
|
@@ -8117,41 +8123,41 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
8117
8123
|
onUnmounted(() => {
|
8118
8124
|
d();
|
8119
8125
|
});
|
8120
|
-
const g = (
|
8126
|
+
const g = (E) => {
|
8121
8127
|
switch (e.kgType) {
|
8122
8128
|
case "top":
|
8123
|
-
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, n - (
|
8129
|
+
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, n - (E.pageY - i))));
|
8124
8130
|
break;
|
8125
8131
|
case "bottom":
|
8126
|
-
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, n + (
|
8132
|
+
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, n + (E.pageY - i))));
|
8127
8133
|
break;
|
8128
8134
|
case "left":
|
8129
|
-
t("update:kgWidth", Math.min(e.kgMaxWidth, Math.max(e.kgMinWidth, a - (
|
8135
|
+
t("update:kgWidth", Math.min(e.kgMaxWidth, Math.max(e.kgMinWidth, a - (E.pageX - s))));
|
8130
8136
|
break;
|
8131
8137
|
case "right":
|
8132
|
-
t("update:kgWidth", Math.min(e.kgMaxWidth, Math.max(e.kgMinWidth, a + (
|
8138
|
+
t("update:kgWidth", Math.min(e.kgMaxWidth, Math.max(e.kgMinWidth, a + (E.pageX - s))));
|
8133
8139
|
break;
|
8134
8140
|
}
|
8135
8141
|
};
|
8136
|
-
function
|
8137
|
-
g(
|
8142
|
+
function y(E) {
|
8143
|
+
g(E);
|
8138
8144
|
}
|
8139
|
-
function E
|
8140
|
-
g(
|
8145
|
+
function b(E) {
|
8146
|
+
g(E), d();
|
8141
8147
|
}
|
8142
|
-
function _(
|
8143
|
-
|
8148
|
+
function _(E) {
|
8149
|
+
E.stopPropagation(), E.preventDefault(), d(), !(E instanceof MouseEvent && E.which !== 1) && (s = E.pageX, i = E.pageY, a = e.kgWidth, n = e.kgHeight, o = p(document.documentElement, "mousemove", y), l = p(document.documentElement, "mouseup", b));
|
8144
8150
|
}
|
8145
|
-
function p(
|
8146
|
-
return
|
8147
|
-
remove: () =>
|
8151
|
+
function p(E, T, k) {
|
8152
|
+
return E.addEventListener(T, k), {
|
8153
|
+
remove: () => E.removeEventListener(T, k)
|
8148
8154
|
};
|
8149
8155
|
}
|
8150
|
-
function m(
|
8151
|
-
|
8156
|
+
function m(E) {
|
8157
|
+
E.stopPropagation(), E.preventDefault();
|
8152
8158
|
}
|
8153
8159
|
return () => {
|
8154
|
-
var
|
8160
|
+
var E;
|
8155
8161
|
return createVNode("div", {
|
8156
8162
|
class: u.value,
|
8157
8163
|
style: c.value
|
@@ -8161,7 +8167,7 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
8161
8167
|
onMousedown: _
|
8162
8168
|
}, [createVNode("div", {
|
8163
8169
|
class: "kg-resizable-handle-line"
|
8164
|
-
}, null)]), (
|
8170
|
+
}, null)]), (E = r.default) == null ? void 0 : E.call(r)]);
|
8165
8171
|
};
|
8166
8172
|
}
|
8167
8173
|
}), getProps$w = () => ({ ...formProps() }), DI_FORM_MODEL = Symbol("DI_FORM_MODEL"), DI_FORM_REF = Symbol("DI_FORM_REF");
|
@@ -8313,15 +8319,15 @@ function createStore(e, t, r) {
|
|
8313
8319
|
_assignPluginFnProp: function(l, c) {
|
8314
8320
|
var u = this[c];
|
8315
8321
|
this[c] = function() {
|
8316
|
-
var g = slice(arguments, 0),
|
8317
|
-
function
|
8322
|
+
var g = slice(arguments, 0), y = this;
|
8323
|
+
function b() {
|
8318
8324
|
if (!!u)
|
8319
8325
|
return each$6(arguments, function(p, m) {
|
8320
8326
|
g[m] = p;
|
8321
|
-
}), u.apply(
|
8327
|
+
}), u.apply(y, g);
|
8322
8328
|
}
|
8323
|
-
var _ = [
|
8324
|
-
return l.apply(
|
8329
|
+
var _ = [b].concat(g);
|
8330
|
+
return l.apply(y, _);
|
8325
8331
|
};
|
8326
8332
|
},
|
8327
8333
|
_serialize: function(l) {
|
@@ -8358,10 +8364,10 @@ function createStore(e, t, r) {
|
|
8358
8364
|
var d = l.call(this);
|
8359
8365
|
if (!isObject(d))
|
8360
8366
|
throw new Error("Plugins must return an object of function properties");
|
8361
|
-
each$6(d, function(g,
|
8367
|
+
each$6(d, function(g, y) {
|
8362
8368
|
if (!isFunction(g))
|
8363
|
-
throw new Error("Bad plugin property: " +
|
8364
|
-
c._assignPluginFnProp(g,
|
8369
|
+
throw new Error("Bad plugin property: " + y + " from plugin " + l.name + ". Plugins should only return functions.");
|
8370
|
+
c._assignPluginFnProp(g, y);
|
8365
8371
|
});
|
8366
8372
|
}
|
8367
8373
|
},
|
@@ -9413,18 +9419,18 @@ const useKgVarStore = () => (store$7 || (store$7 = defineStore("KgVar", {
|
|
9413
9419
|
varButtonConfig: u,
|
9414
9420
|
varButtons: d,
|
9415
9421
|
varSubmitConfig: g,
|
9416
|
-
varSubmitFields:
|
9417
|
-
varProfileMasters:
|
9422
|
+
varSubmitFields: y,
|
9423
|
+
varProfileMasters: b,
|
9418
9424
|
varProfileConfig: _,
|
9419
9425
|
varGridMasters: p,
|
9420
9426
|
varGridConfig: m
|
9421
9427
|
} = await GetAll({ params: { frm_id: e } });
|
9422
|
-
this.varCatalogMap.set(e, s != null ? s : []), this.varLookupMap.set(e, i != null ? i : []), this.varPossibilityMap.set(e, c != null ? c : []), this.varVariableConfigMap.set(e, o != null ? o : []), this.varVariableInputMap.set(e, l != null ? l : []), this.varButtonMap.set(e, transformVarButtons(d)), this.varButtonConfigMap.set(e, transformVarButtonConfig(u != null ? u : null)), this.varSubmitConfigMap.set(e, transformVarSubmitConfig(g)), this.varSubmitFieldMap.set(e, transformVarSubmitFields(
|
9423
|
-
varProfileMasters: transformVarProfileMasterDTOs(
|
9424
|
-
currentVarProfileMasterID: (r = (t = (
|
9428
|
+
this.varCatalogMap.set(e, s != null ? s : []), this.varLookupMap.set(e, i != null ? i : []), this.varPossibilityMap.set(e, c != null ? c : []), this.varVariableConfigMap.set(e, o != null ? o : []), this.varVariableInputMap.set(e, l != null ? l : []), this.varButtonMap.set(e, transformVarButtons(d)), this.varButtonConfigMap.set(e, transformVarButtonConfig(u != null ? u : null)), this.varSubmitConfigMap.set(e, transformVarSubmitConfig(g)), this.varSubmitFieldMap.set(e, transformVarSubmitFields(y)), this.varProfileConfigMap.set(e, transformVarProfileConfig(_ != null ? _ : null)), this.varProfileMasterMap.set(e, {
|
9429
|
+
varProfileMasters: transformVarProfileMasterDTOs(b),
|
9430
|
+
currentVarProfileMasterID: (r = (t = (b == null ? void 0 : b.find((E) => E.id === this.getCurrentVarProfileMasterID(e))) || (b == null ? void 0 : b.find((E) => E.def_flg === 1)) || (b == null ? void 0 : b.find((E) => E.cust_lvl === KG_CUSTOM_LEVEL.L0)) || (b == null ? void 0 : b.find(() => !0))) == null ? void 0 : t.id) != null ? r : null
|
9425
9431
|
}), this.varGridConfigMap.set(e, transformVarGridConfig(m != null ? m : null)), this.varGridMasterMap.set(e, {
|
9426
9432
|
varGridMasters: transformVarGridMasterDTOs(p),
|
9427
|
-
currentVarGridMasterID: (n = (a = (p == null ? void 0 : p.find((
|
9433
|
+
currentVarGridMasterID: (n = (a = (p == null ? void 0 : p.find((E) => E.id === this.getCurrentVarGridMasterID(e))) || (p == null ? void 0 : p.find((E) => E.def_flg === 1)) || (p == null ? void 0 : p.find((E) => E.cust_lvl === KG_CUSTOM_LEVEL.L0)) || (p == null ? void 0 : p.find(() => !0))) == null ? void 0 : a.id) != null ? n : null
|
9428
9434
|
}), await Promise.all([
|
9429
9435
|
this.setCurrentVarGridMasterID(e, this.getCurrentVarGridMasterID(e)),
|
9430
9436
|
this.setCurrentVarProfileMasterID(e, this.getCurrentVarProfileMasterID(e))
|
@@ -9634,7 +9640,7 @@ function useKgVar(e, t, r = 0) {
|
|
9634
9640
|
}), onUnmounted(() => {
|
9635
9641
|
u.dispose(c);
|
9636
9642
|
}));
|
9637
|
-
const d = (J) => computed(() => u.t(c, J)), g = computed(() => u.isRetrieving(c)),
|
9643
|
+
const d = (J) => computed(() => u.t(c, J)), g = computed(() => u.isRetrieving(c)), y = computed(() => u.isRetrievingVarProfileMaster(c)), b = computed(() => u.isRetrievingVarGridMaster(c)), _ = computed(() => u.isRetrieved(c)), p = computed(() => u.isCreating(c)), m = computed(() => u.isCreatingRequesting(c)), E = computed(() => u.isUpdating(c)), T = computed(() => u.isUpdatingRequesting(c)), k = computed(() => u.isCopying(c)), A = computed(() => u.isCopyingRequesting(c)), C = computed(() => u.isDeleting(c)), M = computed(() => u.isDeletingRequesting(c)), w = computed(() => u.isOtherRequesting(c)), I = computed(() => u.getVarButtons(c)), R = computed(() => u.getVarButtonSearch(c)), P = computed(() => u.getVarButtonCreate(c)), O = computed(() => u.getVarButtonUpdate(c)), F = computed(() => u.getVarButtonCopy(c)), $ = computed(() => u.getVarButtonDelete(c)), D = computed(() => u.getVarProfileMasters(c)), V = computed(() => u.getCurrentVarProfileMasterID(c)), N = computed(() => u.getCurrentVarProfileMaster(c)), B = computed(() => {
|
9638
9644
|
var J, te;
|
9639
9645
|
return (te = (J = N.value) == null ? void 0 : J.varProfileDetails) != null ? te : null;
|
9640
9646
|
}), H = computed(() => u.getVarGridConfig(c)), L = computed(() => u.getVarGridMasters(c)), x = computed(() => u.getCurrentVarGridMasterID(c)), Y = computed(() => u.getCurrentVarGridMaster(c)), q = computed(() => u.getSystemVarGridDetails(c)), X = computed(() => u.getCurrentVarGridDetails(c));
|
@@ -9642,12 +9648,12 @@ function useKgVar(e, t, r = 0) {
|
|
9642
9648
|
formID: c,
|
9643
9649
|
store: u,
|
9644
9650
|
isRetrieving: g,
|
9645
|
-
isRetrievingVarProfileMaster:
|
9646
|
-
isRetrievingVarGridMaster:
|
9651
|
+
isRetrievingVarProfileMaster: y,
|
9652
|
+
isRetrievingVarGridMaster: b,
|
9647
9653
|
isRetrieved: _,
|
9648
9654
|
isCreating: p,
|
9649
9655
|
isCreatingRequesting: m,
|
9650
|
-
isUpdating:
|
9656
|
+
isUpdating: E,
|
9651
9657
|
isUpdatingRequesting: T,
|
9652
9658
|
isCopying: k,
|
9653
9659
|
isCopyingRequesting: A,
|
@@ -9693,10 +9699,10 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9693
9699
|
}) {
|
9694
9700
|
provide(DI_KG_VAR__KG_PROPS, computed(() => e.kgProps)), provide(DI_KG_VAR__KG_SLOTS, e.kgSlots);
|
9695
9701
|
const r = useKgVar(), a = useKgSearch(r.formID), n = useKgButton(r.formID), s = useKgSubmit(r.formID), i = useKgTable(r.formID), o = computed(() => r.store.getVarProfileConfig(r.formID)), l = computed(() => r.store.getVarButtonConfig(r.formID)), c = computed(() => r.store.getVarGridConfig(r.formID)), u = computed(() => r.store.getVarSubmitConfig(r.formID)), d = computed(() => {
|
9696
|
-
var
|
9702
|
+
var E, T, k, A;
|
9697
9703
|
switch (!0) {
|
9698
9704
|
case r.isCreating.value:
|
9699
|
-
return ((
|
9705
|
+
return ((E = u.value) == null ? void 0 : E.crt_flg) !== 0;
|
9700
9706
|
case r.isUpdating.value:
|
9701
9707
|
return ((T = u.value) == null ? void 0 : T.upt_flg) !== 0;
|
9702
9708
|
case r.isCopying.value:
|
@@ -9706,25 +9712,25 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9706
9712
|
}
|
9707
9713
|
return !1;
|
9708
9714
|
}), g = computed(() => {
|
9709
|
-
var
|
9710
|
-
return r.isRetrieved.value && ((
|
9715
|
+
var E;
|
9716
|
+
return r.isRetrieved.value && ((E = o.value) == null ? void 0 : E.available_flg) !== 0;
|
9717
|
+
}), y = computed(() => {
|
9718
|
+
var E;
|
9719
|
+
return r.isRetrieved.value && ((E = l.value) == null ? void 0 : E.available_flg) !== 0;
|
9711
9720
|
}), b = computed(() => {
|
9712
|
-
var
|
9713
|
-
return r.isRetrieved.value && ((
|
9714
|
-
}), E = computed(() => {
|
9715
|
-
var y;
|
9716
|
-
return r.isRetrieved.value && ((y = c.value) == null ? void 0 : y.available_flg) !== 0;
|
9721
|
+
var E;
|
9722
|
+
return r.isRetrieved.value && ((E = c.value) == null ? void 0 : E.available_flg) !== 0;
|
9717
9723
|
}), _ = computed(() => !!r.isOtherRequesting.value), p = computed(() => {
|
9718
|
-
let
|
9719
|
-
return e.KgBackgroundGray && (
|
9724
|
+
let E = "kg-var";
|
9725
|
+
return e.KgBackgroundGray && (E += " kg-var--bg-gray"), !g.value && !y.value && !b.value && (E += " kg-var--empty"), E;
|
9720
9726
|
});
|
9721
9727
|
function m() {
|
9722
9728
|
return createVNode(Spin, {
|
9723
9729
|
spinning: _.value
|
9724
9730
|
}, {
|
9725
9731
|
default: () => {
|
9726
|
-
var
|
9727
|
-
return [t.default ? t.default() : createVNode(Fragment, null, [g.value && createVNode(KgSearch, null, null),
|
9732
|
+
var E, T;
|
9733
|
+
return [t.default ? t.default() : createVNode(Fragment, null, [g.value && createVNode(KgSearch, null, null), y.value && createVNode(KgButton, null, null), b.value && createVNode(Fragment, null, [createVNode(KgTable, null, null), (T = (E = e.kgSlots) == null ? void 0 : E.afterKgTable) == null ? void 0 : T.call(E)]), d.value && createVNode(KgSubmit, null, null)])];
|
9728
9734
|
}
|
9729
9735
|
});
|
9730
9736
|
}
|
@@ -9748,18 +9754,18 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9748
9754
|
const a = inject(KG_DI_HOST_FORM_ID, ""), n = useKgVar(a), s = useKgForm(n.formID), i = inject(KG_DI_VAR_NAME, ""), o = inject(KG_DI_LOOKUP_ID, ""), l = inject(DI_FORM_MODEL, computed(() => ({}))), c = useKgVar(o, !0, n.store.getFormLevel(n.formID) + 1), u = useKgTable(c.formID), d = computed(() => n.store.getVarLookup(n.formID, i)), g = computed(() => {
|
9749
9755
|
var p;
|
9750
9756
|
return ((p = d == null ? void 0 : d.value) == null ? void 0 : p.mult_flg) === 1;
|
9751
|
-
}),
|
9757
|
+
}), y = computed(() => {
|
9752
9758
|
var p, m;
|
9753
9759
|
return (m = (p = d == null ? void 0 : d.value) == null ? void 0 : p.ret_fld) != null ? m : "";
|
9754
9760
|
});
|
9755
9761
|
u.onRowDoubleClick(async () => (await _(), !1));
|
9756
|
-
function
|
9762
|
+
function b() {
|
9757
9763
|
r("update:visible", !1);
|
9758
9764
|
}
|
9759
9765
|
async function _() {
|
9760
|
-
var p, m,
|
9766
|
+
var p, m, E, T, k, A, C;
|
9761
9767
|
if (g.value) {
|
9762
|
-
const M = (m = (p = u.selectedRows) == null ? void 0 : p.value) != null ? m : [], w = (
|
9768
|
+
const M = (m = (p = u.selectedRows) == null ? void 0 : p.value) != null ? m : [], w = (E = M.map((R) => R[y.value])) != null ? E : [];
|
9763
9769
|
await s.store.emit(s.formID, "lookupBeforeOk", {
|
9764
9770
|
var_nam: i,
|
9765
9771
|
isMultiple: !0,
|
@@ -9773,7 +9779,7 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9773
9779
|
rows: M
|
9774
9780
|
}), r("update:visible", !1));
|
9775
9781
|
} else {
|
9776
|
-
const M = (A = (k = (T = u.selectedRows) == null ? void 0 : T.value) == null ? void 0 : k[0]) != null ? A : null, w = (C = M == null ? void 0 : M[
|
9782
|
+
const M = (A = (k = (T = u.selectedRows) == null ? void 0 : T.value) == null ? void 0 : k[0]) != null ? A : null, w = (C = M == null ? void 0 : M[y.value]) != null ? C : "";
|
9777
9783
|
await s.store.emit(s.formID, "lookupBeforeOk", {
|
9778
9784
|
var_nam: i,
|
9779
9785
|
isMultiple: !1,
|
@@ -9798,7 +9804,7 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9798
9804
|
disabled: ((m = (p = u.selectedRows.value) == null ? void 0 : p.length) != null ? m : 0) === 0
|
9799
9805
|
},
|
9800
9806
|
wrapClassName: "kg-form-item-addon-lookup-modal",
|
9801
|
-
onCancel:
|
9807
|
+
onCancel: b,
|
9802
9808
|
onOk: _
|
9803
9809
|
}, {
|
9804
9810
|
default: () => [createVNode(KgVar, null, null)]
|
@@ -9893,7 +9899,7 @@ function _useRules(e) {
|
|
9893
9899
|
const t = useKg(), r = useKgVar(), a = computed(() => r.store.getVarProfileDetail(r.formID, e.kgVarName)), n = computed(() => r.store.getVarVariableInput(r.formID, e.kgVarName)), s = computed(() => r.store.getVarSubmitField(r.formID, e.kgVarName));
|
9894
9900
|
return {
|
9895
9901
|
rules: computed(() => {
|
9896
|
-
var l, c, u, d, g,
|
9902
|
+
var l, c, u, d, g, y, b, _, p, m;
|
9897
9903
|
let o = [];
|
9898
9904
|
switch (e.kgContext) {
|
9899
9905
|
case KG_FORM_CONTEXT.SEARCH:
|
@@ -9931,14 +9937,14 @@ function _useRules(e) {
|
|
9931
9937
|
}
|
9932
9938
|
break;
|
9933
9939
|
}
|
9934
|
-
switch ((
|
9940
|
+
switch ((y = n.value) == null ? void 0 : y.data_type) {
|
9935
9941
|
case KG_VAR_INPUT__DATA_TYPE.NUMBER:
|
9936
9942
|
{
|
9937
|
-
const
|
9938
|
-
isNil(
|
9939
|
-
validator: (k, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) <
|
9943
|
+
const E = (b = n.value) == null ? void 0 : b.min;
|
9944
|
+
isNil(E) || (((_ = n.value) == null ? void 0 : _.min_include_flg) === 1 ? o.push({
|
9945
|
+
validator: (k, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) < E ? Promise.reject(t.t("kg.KgFormItem.mustGTE", [E])) : Promise.resolve()
|
9940
9946
|
}) : o.push({
|
9941
|
-
validator: (k, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) <=
|
9947
|
+
validator: (k, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) <= E ? Promise.reject(t.t("kg.KgFormItem.mustGT", [E])) : Promise.resolve()
|
9942
9948
|
}));
|
9943
9949
|
const T = (p = n.value) == null ? void 0 : p.max;
|
9944
9950
|
isNil(T) || (((m = n.value) == null ? void 0 : m.max_include_flg) === 1 ? o.push({
|
@@ -9955,8 +9961,8 @@ function _useRules(e) {
|
|
9955
9961
|
}
|
9956
9962
|
function useKgFormItem(e) {
|
9957
9963
|
const t = (e == null ? void 0 : e.kgVarName) || inject(KG_DI_VAR_NAME, e == null ? void 0 : e.kgVarName), r = (e == null ? void 0 : e.kgContext) || inject(DI_KG_CONTEXT, e == null ? void 0 : e.kgContext), a = useKgVar(), n = computed(() => a.store.getVarVariableConfig(a.formID, t)), s = computed(() => {
|
9958
|
-
var
|
9959
|
-
const o = ((
|
9964
|
+
var y, b, _, p, m, E;
|
9965
|
+
const o = ((y = n.value) == null ? void 0 : y.ctrl_typ) || KG_FORM_ITEM_TYPE.INPUT, l = (b = n.value) == null ? void 0 : b.prf_ctrl_typ, c = (_ = n.value) == null ? void 0 : _.crt_ctrl_typ, u = (p = n.value) == null ? void 0 : p.upt_ctrl_typ, d = (m = n.value) == null ? void 0 : m.cpy_ctrl_typ, g = (E = n.value) == null ? void 0 : E.del_ctrl_typ;
|
9960
9966
|
switch (r) {
|
9961
9967
|
case KG_FORM_CONTEXT.SEARCH:
|
9962
9968
|
return l || o;
|
@@ -9974,9 +9980,9 @@ function useKgFormItem(e) {
|
|
9974
9980
|
}
|
9975
9981
|
return o;
|
9976
9982
|
}), i = computed(() => {
|
9977
|
-
var
|
9983
|
+
var b, _, p, m, E, T;
|
9978
9984
|
let o;
|
9979
|
-
const l = (
|
9985
|
+
const l = (b = n.value) == null ? void 0 : b.ctrl_prop, c = (_ = n.value) == null ? void 0 : _.prf_ctrl_prop, u = (p = n.value) == null ? void 0 : p.crt_ctrl_prop, d = (m = n.value) == null ? void 0 : m.upt_ctrl_prop, g = (E = n.value) == null ? void 0 : E.cpy_ctrl_prop, y = (T = n.value) == null ? void 0 : T.del_ctrl_prop;
|
9980
9986
|
switch (r) {
|
9981
9987
|
case KG_FORM_CONTEXT.SEARCH:
|
9982
9988
|
o = c || l;
|
@@ -9993,7 +9999,7 @@ function useKgFormItem(e) {
|
|
9993
9999
|
o = g || l;
|
9994
10000
|
break;
|
9995
10001
|
case a.isDeleting.value:
|
9996
|
-
o =
|
10002
|
+
o = y || l;
|
9997
10003
|
break;
|
9998
10004
|
}
|
9999
10005
|
}
|
@@ -10009,16 +10015,16 @@ function useKgFormItemSelect() {
|
|
10009
10015
|
controlType: n,
|
10010
10016
|
controlProperties: s
|
10011
10017
|
} = useKgFormItem(), i = ref(!1), o = ref([]), l = computed(() => {
|
10012
|
-
var
|
10013
|
-
return (
|
10018
|
+
var y, b;
|
10019
|
+
return (b = (y = a.value) == null ? void 0 : y.val_clm) != null ? b : "";
|
10014
10020
|
}), c = computed(() => {
|
10015
|
-
var
|
10016
|
-
return (
|
10021
|
+
var y, b;
|
10022
|
+
return (b = (y = a.value) == null ? void 0 : y.lbl_clm) != null ? b : "";
|
10017
10023
|
}), u = computed(() => {
|
10018
|
-
var
|
10019
|
-
let
|
10020
|
-
return
|
10021
|
-
var m,
|
10024
|
+
var b;
|
10025
|
+
let y = KgVarUtil.parseCommandParameter((b = a.value) == null ? void 0 : b.cmd_prm);
|
10026
|
+
return y = mapValues(y, (_) => {
|
10027
|
+
var m, E;
|
10022
10028
|
let p = _;
|
10023
10029
|
if (typeof _ == "string" && _.startsWith("{") && _.endsWith("}")) {
|
10024
10030
|
let T = _.slice(1, -1), k = "";
|
@@ -10026,29 +10032,29 @@ function useKgFormItemSelect() {
|
|
10026
10032
|
const A = T.split(".");
|
10027
10033
|
T = A[0], k = A[1];
|
10028
10034
|
}
|
10029
|
-
t.value && T in t.value && (k ? p = (
|
10035
|
+
t.value && T in t.value && (k ? p = (E = (m = t.value[`${T}_obj`]) == null ? void 0 : m[k]) != null ? E : void 0 : p = t.value[T], p || (p = "__kg__form_item_select__pid"));
|
10030
10036
|
}
|
10031
10037
|
return p;
|
10032
|
-
}),
|
10038
|
+
}), y;
|
10033
10039
|
});
|
10034
10040
|
async function d() {
|
10035
10041
|
var T, k, A, C, M, w, I, R;
|
10036
|
-
let
|
10037
|
-
const
|
10038
|
-
if (!
|
10042
|
+
let y = [];
|
10043
|
+
const b = (T = a.value) == null ? void 0 : T.cmd, _ = (A = (k = a.value) == null ? void 0 : k.cmd_method) != null ? A : "GET", p = (M = (C = a.value) == null ? void 0 : C.val_clm) != null ? M : "", m = (I = (w = a.value) == null ? void 0 : w.lbl_clm) != null ? I : "";
|
10044
|
+
if (!b || !p || !m) {
|
10039
10045
|
KgLogger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF.", {
|
10040
10046
|
frm_id: r.formID,
|
10041
10047
|
var_nam: e,
|
10042
|
-
cmd:
|
10048
|
+
cmd: b,
|
10043
10049
|
val_clm: p,
|
10044
10050
|
lbl_clm: m
|
10045
10051
|
});
|
10046
10052
|
return;
|
10047
10053
|
}
|
10048
|
-
let
|
10054
|
+
let E = null;
|
10049
10055
|
try {
|
10050
|
-
i.value = !0,
|
10051
|
-
url:
|
10056
|
+
i.value = !0, E = await ((R = httpClient()) == null ? void 0 : R.request({
|
10057
|
+
url: b,
|
10052
10058
|
method: _,
|
10053
10059
|
params: u.value
|
10054
10060
|
}));
|
@@ -10056,59 +10062,59 @@ function useKgFormItemSelect() {
|
|
10056
10062
|
} finally {
|
10057
10063
|
i.value = !1;
|
10058
10064
|
}
|
10059
|
-
if (!isObjectLike(
|
10060
|
-
|
10065
|
+
if (!isObjectLike(E))
|
10066
|
+
y = [];
|
10061
10067
|
else
|
10062
10068
|
switch (!0) {
|
10063
|
-
case isArrayLike(
|
10064
|
-
|
10069
|
+
case isArrayLike(E):
|
10070
|
+
y = g(E);
|
10065
10071
|
break;
|
10066
|
-
case (
|
10067
|
-
|
10072
|
+
case (E && "total" in E && "records" in E):
|
10073
|
+
y = g(E.records);
|
10068
10074
|
break;
|
10069
10075
|
}
|
10070
|
-
if (
|
10071
|
-
const P =
|
10076
|
+
if (y.length > 0) {
|
10077
|
+
const P = y[0];
|
10072
10078
|
(!(p in P) || !(m in P)) && KgLogger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF, \u6570\u636E\u5217(val_clm)\u6216\u663E\u793A\u5217(lbl_clm)\u6709\u8BEF.", {
|
10073
10079
|
frm_id: r.formID,
|
10074
10080
|
var_nam: e,
|
10075
|
-
cmd:
|
10081
|
+
cmd: b,
|
10076
10082
|
val_clm: p,
|
10077
10083
|
lbl_clm: m,
|
10078
10084
|
\u6240\u6709\u5217: Object.keys(P)
|
10079
10085
|
});
|
10080
10086
|
}
|
10081
|
-
o.value =
|
10087
|
+
o.value = y;
|
10082
10088
|
}
|
10083
|
-
function g(
|
10084
|
-
var p, m,
|
10085
|
-
if (!
|
10089
|
+
function g(y) {
|
10090
|
+
var p, m, E, T, k;
|
10091
|
+
if (!y)
|
10086
10092
|
return [];
|
10087
|
-
const
|
10093
|
+
const b = (m = (p = a.value) == null ? void 0 : p.val_clm) != null ? m : "", _ = (T = (E = a.value) == null ? void 0 : E.val_data_type) != null ? T : "string";
|
10088
10094
|
switch (_) {
|
10089
10095
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
10090
|
-
|
10091
|
-
A[
|
10096
|
+
y.forEach((A) => {
|
10097
|
+
A[b] = String(A[b]);
|
10092
10098
|
});
|
10093
10099
|
break;
|
10094
10100
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER:
|
10095
|
-
|
10096
|
-
let C = Number(A[
|
10097
|
-
Number.isNaN(C) && (C = A[
|
10101
|
+
y.forEach((A) => {
|
10102
|
+
let C = Number(A[b]);
|
10103
|
+
Number.isNaN(C) && (C = A[b], KgLogger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${A[b]} \u8F6C\u6362\u4E3A ${_} \u7C7B\u578B`, {
|
10098
10104
|
frm_id: r.formID,
|
10099
10105
|
var_nam: e,
|
10100
10106
|
VarPossibility: a.value
|
10101
|
-
})), A[
|
10107
|
+
})), A[b] = C;
|
10102
10108
|
});
|
10103
10109
|
break;
|
10104
10110
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
10105
|
-
|
10111
|
+
y.forEach((A) => {
|
10106
10112
|
let C;
|
10107
|
-
String(A[
|
10113
|
+
String(A[b]).toLowerCase() === "true" ? C = !0 : String(A[b]).toLowerCase() === "false" ? C = !1 : (C = A[b], KgLogger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${A[b]} \u8F6C\u6362\u4E3A ${_} \u7C7B\u578B`, {
|
10108
10114
|
frm_id: r.formID,
|
10109
10115
|
var_nam: e,
|
10110
10116
|
VarPossibility: a.value
|
10111
|
-
})), A[
|
10117
|
+
})), A[b] = C;
|
10112
10118
|
});
|
10113
10119
|
break;
|
10114
10120
|
}
|
@@ -10117,14 +10123,14 @@ function useKgFormItemSelect() {
|
|
10117
10123
|
{
|
10118
10124
|
const A = s;
|
10119
10125
|
if ((k = A.value) != null && k.excludeValues)
|
10120
|
-
return
|
10126
|
+
return y.filter((C) => {
|
10121
10127
|
var M;
|
10122
|
-
return !((M = A.value.excludeValues) != null && M.includes(C[
|
10128
|
+
return !((M = A.value.excludeValues) != null && M.includes(C[b]));
|
10123
10129
|
});
|
10124
10130
|
}
|
10125
10131
|
break;
|
10126
10132
|
}
|
10127
|
-
return
|
10133
|
+
return y;
|
10128
10134
|
}
|
10129
10135
|
return {
|
10130
10136
|
varPossibility: a,
|
@@ -10157,22 +10163,22 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
10157
10163
|
datas: c,
|
10158
10164
|
retrieveDatas: u
|
10159
10165
|
} = useKgFormItemSelect(), d = ref(!1), g = ref(!1);
|
10160
|
-
watch(o, () =>
|
10166
|
+
watch(o, () => y(), {
|
10161
10167
|
immediate: !0
|
10162
10168
|
}), watch([() => e.value, c], ([p, m]) => {
|
10163
|
-
const
|
10164
|
-
if (
|
10169
|
+
const E = get(p, "length", 0);
|
10170
|
+
if (E > 0 && m.length > 0) {
|
10165
10171
|
const T = intersection$1(p, m == null ? void 0 : m.map((k) => k[l.value]));
|
10166
|
-
if (T.length <
|
10172
|
+
if (T.length < E) {
|
10167
10173
|
r("update:value", T);
|
10168
10174
|
return;
|
10169
10175
|
}
|
10170
10176
|
}
|
10171
10177
|
switch (!0) {
|
10172
|
-
case (
|
10178
|
+
case (E > 0 && E === m.length):
|
10173
10179
|
d.value = !0, g.value = !1;
|
10174
10180
|
break;
|
10175
|
-
case (
|
10181
|
+
case (E > 0 && E !== m.length):
|
10176
10182
|
d.value = !1, g.value = !0;
|
10177
10183
|
break;
|
10178
10184
|
default:
|
@@ -10182,13 +10188,13 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
10182
10188
|
}, {
|
10183
10189
|
immediate: !0
|
10184
10190
|
});
|
10185
|
-
async function
|
10191
|
+
async function y() {
|
10186
10192
|
var p, m;
|
10187
|
-
!((p = i.value) != null && p.id) || (await u(), r("kgCheckboxGroupDatasChange", c.value), r("update:value", intersection$1((m = c.value) == null ? void 0 : m.map((
|
10193
|
+
!((p = i.value) != null && p.id) || (await u(), r("kgCheckboxGroupDatasChange", c.value), r("update:value", intersection$1((m = c.value) == null ? void 0 : m.map((E) => E[l.value]), e.value)));
|
10188
10194
|
}
|
10189
|
-
function
|
10190
|
-
var m,
|
10191
|
-
p.target.checked ? _((
|
10195
|
+
function b(p) {
|
10196
|
+
var m, E, T;
|
10197
|
+
p.target.checked ? _((E = (m = c.value) == null ? void 0 : m.map((k) => k[l.value])) != null ? E : []) : _([]), g.value = !1, (T = n.value) == null || T.validate(e.kgVarName);
|
10192
10198
|
}
|
10193
10199
|
function _(p) {
|
10194
10200
|
r("update:value", p), r("kgChange", p);
|
@@ -10200,9 +10206,9 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
10200
10206
|
}, [createVNode(Form.ItemRest, null, {
|
10201
10207
|
default: () => [createVNode(Checkbox, {
|
10202
10208
|
checked: d.value,
|
10203
|
-
"onUpdate:checked": (
|
10209
|
+
"onUpdate:checked": (E) => d.value = E,
|
10204
10210
|
indeterminate: g.value,
|
10205
|
-
onChange:
|
10211
|
+
onChange: b
|
10206
10212
|
}, _isSlot$b(p = a.t("kg.selectAll")) ? p : {
|
10207
10213
|
default: () => [p]
|
10208
10214
|
})]
|
@@ -10212,18 +10218,18 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
10212
10218
|
}, {
|
10213
10219
|
default: () => [createVNode(Row, {
|
10214
10220
|
gutter: 12
|
10215
|
-
}, _isSlot$b(m = c.value.map((
|
10221
|
+
}, _isSlot$b(m = c.value.map((E) => {
|
10216
10222
|
var T, k;
|
10217
10223
|
return createVNode(Col, {
|
10218
10224
|
span: (k = (T = s.value) == null ? void 0 : T.span) != null ? k : 24
|
10219
10225
|
}, {
|
10220
10226
|
default: () => [createVNode(Checkbox, {
|
10221
|
-
value:
|
10222
|
-
"kg-value":
|
10227
|
+
value: E[l.value],
|
10228
|
+
"kg-value": E[l.value]
|
10223
10229
|
}, {
|
10224
10230
|
default: () => {
|
10225
10231
|
var A, C;
|
10226
|
-
return [
|
10232
|
+
return [E[(C = (A = i.value) == null ? void 0 : A.lbl_clm) != null ? C : ""]];
|
10227
10233
|
}
|
10228
10234
|
})]
|
10229
10235
|
});
|
@@ -10381,9 +10387,9 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10381
10387
|
default: () => [createVNode(Row, {
|
10382
10388
|
gutter: 12
|
10383
10389
|
}, _isSlot$a(d = o.value.map((g) => {
|
10384
|
-
var
|
10390
|
+
var y, b;
|
10385
10391
|
return createVNode(Col, {
|
10386
|
-
span: (
|
10392
|
+
span: (b = (y = a.value) == null ? void 0 : y.span) != null ? b : 24
|
10387
10393
|
}, {
|
10388
10394
|
default: () => [createVNode(Radio, {
|
10389
10395
|
value: g[i.value],
|
@@ -10419,17 +10425,17 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10419
10425
|
retrieveDatas: g
|
10420
10426
|
} = useKgFormItemSelect();
|
10421
10427
|
watch(o, () => {
|
10422
|
-
|
10428
|
+
y();
|
10423
10429
|
}, {
|
10424
10430
|
immediate: !0
|
10425
10431
|
});
|
10426
|
-
async function
|
10432
|
+
async function y() {
|
10427
10433
|
var p;
|
10428
10434
|
if (!!((p = i.value) != null && p.id))
|
10429
10435
|
switch (await g(), r("kgSelectDatasChange", d.value), e.kgMode) {
|
10430
10436
|
case "multiple": {
|
10431
10437
|
if (Array.isArray(e.value)) {
|
10432
|
-
const m = e.value.filter((
|
10438
|
+
const m = e.value.filter((E) => d.value.find((T) => T[l.value] === E));
|
10433
10439
|
m.length > 0 ? r("update:value", m) : r("update:value", []);
|
10434
10440
|
}
|
10435
10441
|
break;
|
@@ -10439,8 +10445,8 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10439
10445
|
break;
|
10440
10446
|
}
|
10441
10447
|
}
|
10442
|
-
function
|
10443
|
-
var m,
|
10448
|
+
function b(p) {
|
10449
|
+
var m, E;
|
10444
10450
|
switch (e.kgMode) {
|
10445
10451
|
case "multiple": {
|
10446
10452
|
if (Array.isArray(p)) {
|
@@ -10453,7 +10459,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10453
10459
|
break;
|
10454
10460
|
}
|
10455
10461
|
default: {
|
10456
|
-
const T = (
|
10462
|
+
const T = (E = toRaw(d.value.find((k) => k[l.value] === p))) != null ? E : null;
|
10457
10463
|
r("kgSelectChange", T), s.store.emit(s.formID, "selectChange", {
|
10458
10464
|
var_nam: e.kgVarName,
|
10459
10465
|
rows: T
|
@@ -10478,10 +10484,10 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10478
10484
|
placeholder: e.kgPlaceholder,
|
10479
10485
|
showArrow: !0,
|
10480
10486
|
showSearch: !0,
|
10481
|
-
filterOption: (m,
|
10487
|
+
filterOption: (m, E) => (E == null ? void 0 : E.value) !== null && (E == null ? void 0 : E.value) !== void 0 && String(E.value).toLowerCase().includes(m.toLowerCase()) || (E == null ? void 0 : E.label) !== null && (E == null ? void 0 : E.label) !== void 0 && String(E.label).toLowerCase().includes(m.toLowerCase()),
|
10482
10488
|
dropdownClassName: e.kgMode === "multiple" ? "kg-form-item-select-dropdown kg-form-item-multi-select-dropdown" : "kg-form-item-select-dropdown",
|
10483
10489
|
class: "kg-form-item-select",
|
10484
|
-
onChange:
|
10490
|
+
onChange: b,
|
10485
10491
|
"kg-value": e.value,
|
10486
10492
|
"kg-cmd": (p = i.value) == null ? void 0 : p.cmd,
|
10487
10493
|
"kg-val_clm": l.value,
|
@@ -10573,9 +10579,9 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10573
10579
|
return !1;
|
10574
10580
|
});
|
10575
10581
|
const c = computed(() => i.store.getVarLookup(i.formID, e.kgVarName)), u = computed(() => i.store.getVarVariableConfig(i.formID, e.kgVarName)), d = computed(() => i.store.getVarProfileDetail(i.formID, e.kgVarName)), g = computed(() => i.store.getVarSubmitField(i.formID, e.kgVarName)), {
|
10576
|
-
rules:
|
10582
|
+
rules: y
|
10577
10583
|
} = _useRules(e), {
|
10578
|
-
controlType:
|
10584
|
+
controlType: b
|
10579
10585
|
} = useKgFormItem(e), _ = computed(() => {
|
10580
10586
|
var F, $, D, V, N;
|
10581
10587
|
if (i.isRetrieving.value)
|
@@ -10651,7 +10657,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10651
10657
|
VarProfileDetail: d.value,
|
10652
10658
|
VarSubmitField: g.value
|
10653
10659
|
}), 6);
|
10654
|
-
}),
|
10660
|
+
}), E = computed(() => {
|
10655
10661
|
var F, $, D, V, N;
|
10656
10662
|
let O = null;
|
10657
10663
|
if (e.kgSpan !== void 0)
|
@@ -10692,7 +10698,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10692
10698
|
}), k = computed(() => {
|
10693
10699
|
var F, $, D, V;
|
10694
10700
|
let O = "kg-form-item";
|
10695
|
-
switch (c.value && (O += " kg-form-item-lookup"),
|
10701
|
+
switch (c.value && (O += " kg-form-item-lookup"), E.value !== null && (O += " kg-form-item--col-fixed"), e.kgContext) {
|
10696
10702
|
case KG_FORM_CONTEXT.SEARCH:
|
10697
10703
|
switch (!0) {
|
10698
10704
|
case ((F = d.value) == null ? void 0 : F.vis_flg) === 0:
|
@@ -10723,7 +10729,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10723
10729
|
kgDisabled: _.value,
|
10724
10730
|
id: C.value
|
10725
10731
|
};
|
10726
|
-
switch (
|
10732
|
+
switch (b.value) {
|
10727
10733
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER:
|
10728
10734
|
break;
|
10729
10735
|
case KG_FORM_ITEM_TYPE.SELECT:
|
@@ -10767,7 +10773,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10767
10773
|
};
|
10768
10774
|
return t.control(O);
|
10769
10775
|
}
|
10770
|
-
switch (
|
10776
|
+
switch (b.value) {
|
10771
10777
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER:
|
10772
10778
|
return createVNode(KgFormItemInputNumber, A.value, null);
|
10773
10779
|
case KG_FORM_ITEM_TYPE.TEXT_AREA:
|
@@ -10818,7 +10824,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10818
10824
|
}, {
|
10819
10825
|
default: () => {
|
10820
10826
|
var V;
|
10821
|
-
return KgVarUtil.getDynamicQueryOperatorSelectOptions((V =
|
10827
|
+
return KgVarUtil.getDynamicQueryOperatorSelectOptions((V = b.value) != null ? V : "");
|
10822
10828
|
},
|
10823
10829
|
suffixIcon: () => createVNode(CaretDownOutlined$1, {
|
10824
10830
|
class: "ant-select-suffix"
|
@@ -10855,7 +10861,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10855
10861
|
}, {
|
10856
10862
|
default: () => [createVNode(Form.Item, {
|
10857
10863
|
name: e.kgVarName,
|
10858
|
-
rules:
|
10864
|
+
rules: y.value,
|
10859
10865
|
validateFirst: !0,
|
10860
10866
|
htmlFor: C.value
|
10861
10867
|
}, {
|
@@ -11223,17 +11229,17 @@ const useKgSubmitStore = () => (store$5 || (store$5 = defineStore("KgSubmit", {
|
|
11223
11229
|
}).bind(null, pinia())), store$5);
|
11224
11230
|
function useKgSubmit(e) {
|
11225
11231
|
const t = useKgVar(e), r = useKgSubmitStore()(), a = computed(() => t.store.getVarSubmitConfig(t.formID)), n = computed(() => {
|
11226
|
-
var p, m,
|
11232
|
+
var p, m, E, T, k;
|
11227
11233
|
let l = KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER;
|
11228
|
-
const c = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL, u = KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE, d = (p = a.value) == null ? void 0 : p.display_type, g = (m = a.value) == null ? void 0 : m.crt_display_type,
|
11234
|
+
const c = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL, u = KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE, d = (p = a.value) == null ? void 0 : p.display_type, g = (m = a.value) == null ? void 0 : m.crt_display_type, y = (E = a.value) == null ? void 0 : E.upt_display_type, b = (T = a.value) == null ? void 0 : T.cpy_display_type, _ = (k = a.value) == null ? void 0 : k.del_display_type;
|
11229
11235
|
switch (!0) {
|
11230
11236
|
case (t.isCreating.value && (g === c || !g && d === c)):
|
11231
11237
|
l = c;
|
11232
11238
|
break;
|
11233
|
-
case (t.isUpdating.value && (
|
11239
|
+
case (t.isUpdating.value && (y === c || !y && d === c)):
|
11234
11240
|
l = c;
|
11235
11241
|
break;
|
11236
|
-
case (t.isCopying.value && (
|
11242
|
+
case (t.isCopying.value && (b === c || !b && d === c)):
|
11237
11243
|
l = c;
|
11238
11244
|
break;
|
11239
11245
|
case (t.isDeleting.value && (_ === c || !_)):
|
@@ -11244,10 +11250,10 @@ function useKgSubmit(e) {
|
|
11244
11250
|
case (t.isCreating.value && (g === u || !g && d === u)):
|
11245
11251
|
l = u;
|
11246
11252
|
break;
|
11247
|
-
case (t.isUpdating.value && (
|
11253
|
+
case (t.isUpdating.value && (y === u || !y && d === u)):
|
11248
11254
|
l = u;
|
11249
11255
|
break;
|
11250
|
-
case (t.isCopying.value && (
|
11256
|
+
case (t.isCopying.value && (b === u || !b && d === u)):
|
11251
11257
|
l = u;
|
11252
11258
|
break;
|
11253
11259
|
}
|
@@ -11297,8 +11303,8 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
11297
11303
|
}) => {
|
11298
11304
|
const u = s.store.getVarSubmitConfig(s.formID);
|
11299
11305
|
return o = watch(c, (d) => {
|
11300
|
-
var g,
|
11301
|
-
d && (d.id = (g = u == null ? void 0 : u.id) != null ? g : null, d.frm_id = s.formID, d.resizable_flg = (
|
11306
|
+
var g, y, b, _, p, m, E, T, k, A, C, M;
|
11307
|
+
d && (d.id = (g = u == null ? void 0 : u.id) != null ? g : null, d.frm_id = s.formID, d.resizable_flg = (y = u == null ? void 0 : u.resizable_flg) != null ? y : 1, d.fullscreen_flg = (b = u == null ? void 0 : u.fullscreen_flg) != null ? b : 1, d.dft_fullscreen_flg = (_ = u == null ? void 0 : u.dft_fullscreen_flg) != null ? _ : 0, d.responsive_flg = (p = u == null ? void 0 : u.responsive_flg) != null ? p : 1, d.max_width = (m = u == null ? void 0 : u.max_width) != null ? m : DEFAULT_MAX_WIDTH, d.min_width = (E = u == null ? void 0 : u.min_width) != null ? E : DEFAULT_MIN_WIDTH, d.dft_width = (T = u == null ? void 0 : u.dft_width) != null ? T : DEFAULT_WIDTH, d.layout = (k = u == null ? void 0 : u.layout) != null ? k : KG_VAR_SUBMIT__LAYOUT.VERTICAL, d.label_col = (A = u == null ? void 0 : u.label_col) != null ? A : DEFAULT_LABEL_COL_FOR_SPAN, d.label_col_unit = (C = u == null ? void 0 : u.label_col_unit) != null ? C : KG_WIDTH_UNIT.SPAN, d.display_type = (M = u == null ? void 0 : u.display_type) != null ? M : KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER);
|
11302
11308
|
}, {
|
11303
11309
|
immediate: !0
|
11304
11310
|
}), KgUtil.hideLoading(), !1;
|
@@ -11344,10 +11350,10 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
11344
11350
|
function g() {
|
11345
11351
|
u.value = !0;
|
11346
11352
|
}
|
11347
|
-
function
|
11353
|
+
function y() {
|
11348
11354
|
r("kgCancel");
|
11349
11355
|
}
|
11350
|
-
function
|
11356
|
+
function b() {
|
11351
11357
|
var m;
|
11352
11358
|
return e.kgShowFullscreenButton === !1 || ((m = o.value) == null ? void 0 : m.fullscreen_flg) === 0 ? null : createVNode(Button, {
|
11353
11359
|
onClick: d,
|
@@ -11371,17 +11377,17 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
11371
11377
|
return createVNode(Button, {
|
11372
11378
|
disabled: c.value || l.value,
|
11373
11379
|
class: "kg-submit--btn-close",
|
11374
|
-
onClick:
|
11380
|
+
onClick: y
|
11375
11381
|
}, {
|
11376
11382
|
default: () => [createVNode(CloseOutlined$1, null, null)]
|
11377
11383
|
});
|
11378
11384
|
}
|
11379
|
-
return () => createVNode(Fragment, null, [_(),
|
11385
|
+
return () => createVNode(Fragment, null, [_(), b(), p()]);
|
11380
11386
|
}
|
11381
11387
|
}), DEFAULT_MIN_WIDTH = 300, DEFAULT_MAX_WIDTH = 1182, DEFAULT_WIDTH = 594, DEFAULT_LAYOUT = "vertical", DEFAULT_LABEL_COL_FOR_SPAN = 4, DEFAULT_LABEL_COL_FOR_PX = 100;
|
11382
11388
|
function _useFormModel$1() {
|
11383
11389
|
const e = inject("$dayjs", dayjs), t = useKgVar(), r = useKgTable(), a = useKgSubmit(), n = computed(() => t.store.getVarSubmitFieldsForCreate(t.formID)), s = computed(() => t.store.getVarSubmitFieldsForUpdate(t.formID)), i = computed(() => t.store.getVarSubmitFieldsForCopy(t.formID)), o = computed(() => t.store.getVarSubmitFieldsForDelete(t.formID)), l = computed(() => {
|
11384
|
-
var u, d, g,
|
11390
|
+
var u, d, g, y;
|
11385
11391
|
switch (!0) {
|
11386
11392
|
case t.isCreating.value:
|
11387
11393
|
return (u = n.value) != null ? u : [];
|
@@ -11390,7 +11396,7 @@ function _useFormModel$1() {
|
|
11390
11396
|
case t.isCopying.value:
|
11391
11397
|
return (g = i.value) != null ? g : [];
|
11392
11398
|
case t.isDeleting.value:
|
11393
|
-
return (
|
11399
|
+
return (y = o.value) != null ? y : [];
|
11394
11400
|
}
|
11395
11401
|
return [];
|
11396
11402
|
}), c = ref({});
|
@@ -11401,20 +11407,20 @@ function _useFormModel$1() {
|
|
11401
11407
|
}
|
11402
11408
|
const d = r.selectedRow.value;
|
11403
11409
|
u.forEach((g) => {
|
11404
|
-
var
|
11405
|
-
const
|
11406
|
-
switch (c.value[
|
11410
|
+
var b, _, p, m, E, T, k, A;
|
11411
|
+
const y = (b = g.var_nam) != null ? b : "";
|
11412
|
+
switch (c.value[y] = void 0, !0) {
|
11407
11413
|
case t.isCreating.value:
|
11408
|
-
c.value[
|
11414
|
+
c.value[y] = KgVarUtil.transformFormItemValue(t.formID, y, e, (_ = g.crt_dft_val) != null ? _ : void 0, "C");
|
11409
11415
|
break;
|
11410
11416
|
case t.isUpdating.value:
|
11411
|
-
c.value.id = d == null ? void 0 : d.id, c.value[
|
11417
|
+
c.value.id = d == null ? void 0 : d.id, c.value[y] = KgVarUtil.transformFormItemValue(t.formID, y, e, (m = (p = g.upt_dft_val) != null ? p : d == null ? void 0 : d[y]) != null ? m : void 0, "U");
|
11412
11418
|
break;
|
11413
11419
|
case t.isCopying.value:
|
11414
|
-
c.value.id = d == null ? void 0 : d.id, c.value[
|
11420
|
+
c.value.id = d == null ? void 0 : d.id, c.value[y] = KgVarUtil.transformFormItemValue(t.formID, y, e, (T = (E = g.cpy_dft_val) != null ? E : d == null ? void 0 : d[y]) != null ? T : void 0, "CP");
|
11415
11421
|
break;
|
11416
11422
|
case t.isDeleting.value:
|
11417
|
-
c.value.id = d == null ? void 0 : d.id, c.value[
|
11423
|
+
c.value.id = d == null ? void 0 : d.id, c.value[y] = KgVarUtil.transformFormItemValue(t.formID, y, e, (A = (k = g.del_dft_val) != null ? k : d == null ? void 0 : d[y]) != null ? A : void 0, "D");
|
11418
11424
|
break;
|
11419
11425
|
}
|
11420
11426
|
}), a.store.setModel(t.formID, c.value);
|
@@ -11485,9 +11491,9 @@ function _useClass(e, t) {
|
|
11485
11491
|
const r = inject(DI_KG_VAR__KG_PROPS, null), a = useKgVar(), n = useKgSubmit(), s = computed(() => a.store.getVarSubmitConfig(a.formID)), i = computed(() => a.store.getVarSubmitFieldsForDeleteKey(a.formID));
|
11486
11492
|
return {
|
11487
11493
|
getClass: computed(() => {
|
11488
|
-
var c, u, d, g,
|
11494
|
+
var c, u, d, g, y, b, _;
|
11489
11495
|
let l = "kg-submit";
|
11490
|
-
return t.isFullscreen && (l += " kg-submit--fullscreen"), ((c = s.value) == null ? void 0 : c.responsive_flg) !== 0 && (l += " kg-submit--responsive"), n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? l += " kg-submit--modal" : n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (l += " kg-submit--table"), a.isDeleting.value && ((d = (u = i.value) == null ? void 0 : u.length) != null ? d : 0) === 0 && (l += " kg-submit--delete-message"), (
|
11496
|
+
return t.isFullscreen && (l += " kg-submit--fullscreen"), ((c = s.value) == null ? void 0 : c.responsive_flg) !== 0 && (l += " kg-submit--responsive"), n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? l += " kg-submit--modal" : n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (l += " kg-submit--table"), a.isDeleting.value && ((d = (u = i.value) == null ? void 0 : u.length) != null ? d : 0) === 0 && (l += " kg-submit--delete-message"), (y = (g = r == null ? void 0 : r.value) == null ? void 0 : g.KgSubmit) != null && y.kgClass ? l += ` ${(_ = (b = r == null ? void 0 : r.value) == null ? void 0 : b.KgSubmit) == null ? void 0 : _.kgClass}` : e.kgClass && (l += ` ${e.kgClass}`), l;
|
11491
11497
|
})
|
11492
11498
|
};
|
11493
11499
|
}
|
@@ -11495,9 +11501,9 @@ function _useLayout() {
|
|
11495
11501
|
const e = useKgVar(), t = computed(() => e.store.getVarSubmitConfig(e.formID));
|
11496
11502
|
return {
|
11497
11503
|
getLayout: computed(() => {
|
11498
|
-
var c, u, d, g,
|
11504
|
+
var c, u, d, g, y;
|
11499
11505
|
let a = "vertical";
|
11500
|
-
const n = (c = t.value) == null ? void 0 : c.layout, s = (u = t.value) == null ? void 0 : u.crt_layout, i = (d = t.value) == null ? void 0 : d.upt_layout, o = (g = t.value) == null ? void 0 : g.cpy_layout, l = (
|
11506
|
+
const n = (c = t.value) == null ? void 0 : c.layout, s = (u = t.value) == null ? void 0 : u.crt_layout, i = (d = t.value) == null ? void 0 : d.upt_layout, o = (g = t.value) == null ? void 0 : g.cpy_layout, l = (y = t.value) == null ? void 0 : y.del_layout;
|
11501
11507
|
switch (!0) {
|
11502
11508
|
case (e.isCreating.value && (s === "horizontal" || !s && n === "horizontal")):
|
11503
11509
|
a = "horizontal";
|
@@ -11520,10 +11526,10 @@ function _useDefaultWidth() {
|
|
11520
11526
|
const e = useKgVar(), t = computed(() => e.store.getVarSubmitConfig(e.formID));
|
11521
11527
|
return {
|
11522
11528
|
getDefaultWidth: computed(() => {
|
11523
|
-
var c, u, d, g,
|
11529
|
+
var c, u, d, g, y;
|
11524
11530
|
if (!t.value)
|
11525
11531
|
return 0;
|
11526
|
-
const a = (c = t.value) == null ? void 0 : c.dft_width, n = (u = t.value) == null ? void 0 : u.crt_dft_width, s = (d = t.value) == null ? void 0 : d.upt_dft_width, i = (g = t.value) == null ? void 0 : g.cpy_dft_width, o = (
|
11532
|
+
const a = (c = t.value) == null ? void 0 : c.dft_width, n = (u = t.value) == null ? void 0 : u.crt_dft_width, s = (d = t.value) == null ? void 0 : d.upt_dft_width, i = (g = t.value) == null ? void 0 : g.cpy_dft_width, o = (y = t.value) == null ? void 0 : y.del_dft_width;
|
11527
11533
|
let l = a || DEFAULT_WIDTH;
|
11528
11534
|
switch (!0) {
|
11529
11535
|
case (e.isCreating.value && !!n):
|
@@ -11563,11 +11569,11 @@ const getProps$p = () => ({
|
|
11563
11569
|
inject(DI_KG_VAR__KG_PROPS, null);
|
11564
11570
|
const n = useKg(), s = useKgVar(), i = useKgButton(), o = useKgTable(), l = useKgSubmit(), c = useKgSearch();
|
11565
11571
|
i.onSubmitSave(async () => (await ee(), !1)), i.onSubmitCancel(async () => (await z(), !1)), _useFormModel$1();
|
11566
|
-
const u = computed(() => s.isDeleting.value && R.value.length === 0 && O.value.length === 0), d = computed(() => l.store.isLoading(s.formID)), g = computed(() => s.store.getVarSubmitConfig(s.formID)),
|
11567
|
-
var
|
11572
|
+
const u = computed(() => s.isDeleting.value && R.value.length === 0 && O.value.length === 0), d = computed(() => l.store.isLoading(s.formID)), g = computed(() => s.store.getVarSubmitConfig(s.formID)), y = computed(() => s.store.getVarSubmitFieldsForCreateKey(s.formID)), b = computed(() => s.store.getVarSubmitFieldsForCreateNotKey(s.formID)), _ = computed(() => s.store.getVarSubmitFieldsForUpdateKey(s.formID)), p = computed(() => s.store.getVarSubmitFieldsForUpdateNotKey(s.formID)), m = computed(() => s.store.getVarSubmitFieldsForCopyKey(s.formID)), E = computed(() => s.store.getVarSubmitFieldsForCopyNotKey(s.formID)), T = computed(() => s.store.getVarSubmitFieldsForCreateKeyVisible(s.formID)), k = computed(() => s.store.getVarSubmitFieldsForCreateNotKeyVisible(s.formID)), A = computed(() => s.store.getVarSubmitFieldsForUpdateKeyVisible(s.formID)), C = computed(() => s.store.getVarSubmitFieldsForUpdateNotKeyVisible(s.formID)), M = computed(() => s.store.getVarSubmitFieldsForCopyKeyVisible(s.formID)), w = computed(() => s.store.getVarSubmitFieldsForCopyNotKeyVisible(s.formID)), I = computed(() => s.store.getVarSubmitFieldsForDelete(s.formID)), R = computed(() => {
|
11573
|
+
var U, W, Z;
|
11568
11574
|
switch (!0) {
|
11569
11575
|
case s.isCreating.value:
|
11570
|
-
return (
|
11576
|
+
return (U = y.value) != null ? U : [];
|
11571
11577
|
case s.isUpdating.value:
|
11572
11578
|
return (W = _.value) != null ? W : [];
|
11573
11579
|
case s.isCopying.value:
|
@@ -11577,10 +11583,10 @@ const getProps$p = () => ({
|
|
11577
11583
|
}
|
11578
11584
|
return [];
|
11579
11585
|
}), P = computed(() => {
|
11580
|
-
var
|
11586
|
+
var U, W, Z;
|
11581
11587
|
switch (!0) {
|
11582
11588
|
case s.isCreating.value:
|
11583
|
-
return (
|
11589
|
+
return (U = T.value) != null ? U : [];
|
11584
11590
|
case s.isUpdating.value:
|
11585
11591
|
return (W = A.value) != null ? W : [];
|
11586
11592
|
case s.isCopying.value:
|
@@ -11590,23 +11596,23 @@ const getProps$p = () => ({
|
|
11590
11596
|
}
|
11591
11597
|
return [];
|
11592
11598
|
}), O = computed(() => {
|
11593
|
-
var
|
11599
|
+
var U, W, Z, re;
|
11594
11600
|
switch (!0) {
|
11595
11601
|
case s.isCreating.value:
|
11596
|
-
return (
|
11602
|
+
return (U = b.value) != null ? U : [];
|
11597
11603
|
case s.isUpdating.value:
|
11598
11604
|
return (W = p.value) != null ? W : [];
|
11599
11605
|
case s.isCopying.value:
|
11600
|
-
return (Z =
|
11606
|
+
return (Z = E.value) != null ? Z : [];
|
11601
11607
|
case s.isDeleting.value:
|
11602
11608
|
return (re = I.value) != null ? re : [];
|
11603
11609
|
}
|
11604
11610
|
return [];
|
11605
11611
|
}), F = computed(() => {
|
11606
|
-
var
|
11612
|
+
var U, W, Z, re;
|
11607
11613
|
switch (!0) {
|
11608
11614
|
case s.isCreating.value:
|
11609
|
-
return (
|
11615
|
+
return (U = k.value) != null ? U : [];
|
11610
11616
|
case s.isUpdating.value:
|
11611
11617
|
return (W = C.value) != null ? W : [];
|
11612
11618
|
case s.isCopying.value:
|
@@ -11618,29 +11624,29 @@ const getProps$p = () => ({
|
|
11618
11624
|
}), $ = computed(() => !!s.store.isCreatingRequesting(s.formID) || !!s.store.isUpdatingRequesting(s.formID) || !!s.store.isCopyingRequesting(s.formID) || !!s.store.isDeletingRequesting(s.formID)), D = computed(() => $.value || d.value), V = computed(() => d.value), N = ref({
|
11619
11625
|
kgWidth: 0
|
11620
11626
|
}), B = computed(() => {
|
11621
|
-
var
|
11622
|
-
return !!(u.value || te.isFullscreen || ((
|
11627
|
+
var U;
|
11628
|
+
return !!(u.value || te.isFullscreen || ((U = g.value) == null ? void 0 : U.resizable_flg) === 0);
|
11623
11629
|
}), H = computed(() => {
|
11624
|
-
var
|
11625
|
-
return u.value ? 398 : (W = (
|
11630
|
+
var U, W;
|
11631
|
+
return u.value ? 398 : (W = (U = g.value) == null ? void 0 : U.min_width) != null ? W : DEFAULT_MIN_WIDTH;
|
11626
11632
|
}), L = computed(() => {
|
11627
|
-
var
|
11628
|
-
return u.value ? 398 : (W = (
|
11633
|
+
var U, W;
|
11634
|
+
return u.value ? 398 : (W = (U = g.value) == null ? void 0 : U.max_width) != null ? W : DEFAULT_MAX_WIDTH;
|
11629
11635
|
}), x = computed(() => u.value ? 398 : N.value.kgWidth), Y = ref(null);
|
11630
11636
|
_useResizeObserver$1(Y);
|
11631
11637
|
const q = _useTitle(), X = computed(() => u.value ? 400 : N.value.kgWidth && N.value.kgWidth > 0 ? "auto" : 0), J = computed(() => X.value === 0 ? !1 : !!(s.isCreating.value || s.isUpdating.value || s.isCopying.value || s.isDeleting.value)), te = reactive({
|
11632
11638
|
isFullscreen: !1
|
11633
11639
|
}), {
|
11634
|
-
getClass:
|
11640
|
+
getClass: ie
|
11635
11641
|
} = _useClass(e, te), {
|
11636
|
-
getLayout:
|
11642
|
+
getLayout: me
|
11637
11643
|
} = _useLayout(), {
|
11638
|
-
getDefaultWidth:
|
11644
|
+
getDefaultWidth: de
|
11639
11645
|
} = _useDefaultWidth(), ae = computed(() => {
|
11640
|
-
var
|
11641
|
-
switch (
|
11646
|
+
var U, W, Z;
|
11647
|
+
switch (me.value) {
|
11642
11648
|
case "horizontal":
|
11643
|
-
switch ((
|
11649
|
+
switch ((U = g.value) == null ? void 0 : U.label_col_unit) {
|
11644
11650
|
case KG_WIDTH_UNIT.SPAN:
|
11645
11651
|
return {
|
11646
11652
|
span: (W = g.value) == null ? void 0 : W.label_col
|
@@ -11656,10 +11662,10 @@ const getProps$p = () => ({
|
|
11656
11662
|
return;
|
11657
11663
|
}
|
11658
11664
|
}), K = computed(() => {
|
11659
|
-
var
|
11660
|
-
switch (
|
11665
|
+
var U, W;
|
11666
|
+
switch (me.value) {
|
11661
11667
|
case "horizontal":
|
11662
|
-
switch ((
|
11668
|
+
switch ((U = g.value) == null ? void 0 : U.label_col_unit) {
|
11663
11669
|
case KG_WIDTH_UNIT.SPAN:
|
11664
11670
|
return {
|
11665
11671
|
span: 24 - ((W = g.value) == null ? void 0 : W.label_col)
|
@@ -11671,16 +11677,16 @@ const getProps$p = () => ({
|
|
11671
11677
|
return;
|
11672
11678
|
}
|
11673
11679
|
});
|
11674
|
-
watch(J, (
|
11675
|
-
|
11680
|
+
watch(J, (U, W) => {
|
11681
|
+
U === !0 && G(), W === !0 && U === !1 && Q();
|
11676
11682
|
}, {
|
11677
11683
|
immediate: !0
|
11678
|
-
}), watch(
|
11679
|
-
|
11684
|
+
}), watch(de, (U) => {
|
11685
|
+
U && (N.value.kgWidth = U);
|
11680
11686
|
}, {
|
11681
11687
|
immediate: !0
|
11682
11688
|
});
|
11683
|
-
async function
|
11689
|
+
async function G() {
|
11684
11690
|
if (!await l.store.emit(s.formID, "beforeOpen", {
|
11685
11691
|
isCreating: s.isCreating.value,
|
11686
11692
|
isUpdating: s.isUpdating.value,
|
@@ -11706,7 +11712,7 @@ const getProps$p = () => ({
|
|
11706
11712
|
});
|
11707
11713
|
}
|
11708
11714
|
async function Q() {
|
11709
|
-
N.value.kgWidth =
|
11715
|
+
N.value.kgWidth = de.value, te.isFullscreen = !1, await l.store.emit(s.formID, "close", null);
|
11710
11716
|
}
|
11711
11717
|
function z() {
|
11712
11718
|
switch (!0) {
|
@@ -11725,7 +11731,7 @@ const getProps$p = () => ({
|
|
11725
11731
|
}
|
11726
11732
|
}
|
11727
11733
|
async function ee() {
|
11728
|
-
var
|
11734
|
+
var U, W;
|
11729
11735
|
try {
|
11730
11736
|
if (await l.store.emit(s.formID, "beforeOk", {
|
11731
11737
|
isCreating: s.isCreating.value,
|
@@ -11738,7 +11744,7 @@ const getProps$p = () => ({
|
|
11738
11744
|
}))
|
11739
11745
|
return;
|
11740
11746
|
try {
|
11741
|
-
await ((
|
11747
|
+
await ((U = l.formRef.value) == null ? void 0 : U.validate());
|
11742
11748
|
} catch (se) {
|
11743
11749
|
KgUtil.throwIfNotFormError(se);
|
11744
11750
|
}
|
@@ -11754,26 +11760,26 @@ const getProps$p = () => ({
|
|
11754
11760
|
return;
|
11755
11761
|
switch (!0) {
|
11756
11762
|
case s.isCreating.value:
|
11757
|
-
await
|
11763
|
+
await he();
|
11758
11764
|
break;
|
11759
11765
|
case s.isUpdating.value:
|
11760
|
-
await
|
11766
|
+
await ge();
|
11761
11767
|
break;
|
11762
11768
|
case s.isCopying.value:
|
11763
|
-
await
|
11769
|
+
await fe();
|
11764
11770
|
break;
|
11765
11771
|
case s.isDeleting.value:
|
11766
|
-
await
|
11772
|
+
await le();
|
11767
11773
|
break;
|
11768
11774
|
}
|
11769
11775
|
} catch (Z) {
|
11770
11776
|
KgUtil.throwIfNotFormError(Z);
|
11771
11777
|
}
|
11772
11778
|
}
|
11773
|
-
async function
|
11774
|
-
var W, Z, re, se, oe,
|
11775
|
-
const
|
11776
|
-
if (!
|
11779
|
+
async function he() {
|
11780
|
+
var W, Z, re, se, oe, ue;
|
11781
|
+
const U = (W = s.varButtonCreate.value) == null ? void 0 : W.cmd;
|
11782
|
+
if (!U) {
|
11777
11783
|
KgLogger.error("[KgSubmit] '\u521B\u5EFA\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
11778
11784
|
VarButton: s.varButtonCreate.value
|
11779
11785
|
});
|
@@ -11781,7 +11787,7 @@ const getProps$p = () => ({
|
|
11781
11787
|
}
|
11782
11788
|
s.store.setIsCreatingRequesting(s.formID, !0);
|
11783
11789
|
try {
|
11784
|
-
let ne = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonCreate.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)),
|
11790
|
+
let ne = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonCreate.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)), ce = ref(KgUtil.parseParams(toRaw(l.model.value), s.formID, r));
|
11785
11791
|
if (await l.store.emit(s.formID, "beforeRequest", {
|
11786
11792
|
isCreating: s.isCreating.value,
|
11787
11793
|
isUpdating: s.isUpdating.value,
|
@@ -11791,15 +11797,15 @@ const getProps$p = () => ({
|
|
11791
11797
|
rows: o.selectedRows.value,
|
11792
11798
|
model: l.model,
|
11793
11799
|
params: ne,
|
11794
|
-
data:
|
11800
|
+
data: ce
|
11795
11801
|
}))
|
11796
11802
|
return;
|
11797
11803
|
await httpClient().request({
|
11798
11804
|
method: (oe = (se = s.varButtonCreate.value) == null ? void 0 : se.cmd_method) != null ? oe : "POST",
|
11799
|
-
url:
|
11805
|
+
url: U,
|
11800
11806
|
params: ne.value,
|
11801
|
-
data:
|
11802
|
-
}), ((
|
11807
|
+
data: ce.value
|
11808
|
+
}), ((ue = s.varButtonCreate.value) == null ? void 0 : ue.show_success_message_flg) !== 0 && message.success(q.title.value + n.t("kg.succeed")), await l.store.emit(s.formID, "ok", {
|
11803
11809
|
isCreating: s.isCreating.value,
|
11804
11810
|
isUpdating: s.isUpdating.value,
|
11805
11811
|
isCopying: s.isCopying.value,
|
@@ -11815,10 +11821,10 @@ const getProps$p = () => ({
|
|
11815
11821
|
s.store.setIsCreatingRequesting(s.formID, !1);
|
11816
11822
|
}
|
11817
11823
|
}
|
11818
|
-
async function
|
11819
|
-
var W, Z, re, se, oe,
|
11820
|
-
const
|
11821
|
-
if (!
|
11824
|
+
async function ge() {
|
11825
|
+
var W, Z, re, se, oe, ue;
|
11826
|
+
const U = (W = s.varButtonUpdate.value) == null ? void 0 : W.cmd;
|
11827
|
+
if (!U) {
|
11822
11828
|
KgLogger.error("[KgSubmit] '\u66F4\u65B0\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
11823
11829
|
VarButton: s.varButtonUpdate.value
|
11824
11830
|
});
|
@@ -11826,7 +11832,7 @@ const getProps$p = () => ({
|
|
11826
11832
|
}
|
11827
11833
|
try {
|
11828
11834
|
s.store.setIsUpdatingRequesting(s.formID, !0);
|
11829
|
-
let ne = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonUpdate.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)),
|
11835
|
+
let ne = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonUpdate.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)), ce = ref(KgUtil.parseParams(toRaw(l.model.value), s.formID, r));
|
11830
11836
|
if (await l.store.emit(s.formID, "beforeRequest", {
|
11831
11837
|
isCreating: s.isCreating.value,
|
11832
11838
|
isUpdating: s.isUpdating.value,
|
@@ -11836,15 +11842,15 @@ const getProps$p = () => ({
|
|
11836
11842
|
rows: o.selectedRows.value,
|
11837
11843
|
model: l.model,
|
11838
11844
|
params: ne,
|
11839
|
-
data:
|
11845
|
+
data: ce
|
11840
11846
|
}))
|
11841
11847
|
return;
|
11842
11848
|
await httpClient().request({
|
11843
11849
|
method: (oe = (se = s.varButtonUpdate.value) == null ? void 0 : se.cmd_method) != null ? oe : "POST",
|
11844
|
-
url:
|
11850
|
+
url: U,
|
11845
11851
|
params: ne.value,
|
11846
|
-
data:
|
11847
|
-
}), ((
|
11852
|
+
data: ce.value
|
11853
|
+
}), ((ue = s.varButtonUpdate.value) == null ? void 0 : ue.show_success_message_flg) !== 0 && message.success(n.t("kg.updateSuccess")), await l.store.emit(s.formID, "ok", {
|
11848
11854
|
isCreating: s.isCreating.value,
|
11849
11855
|
isUpdating: s.isUpdating.value,
|
11850
11856
|
isCopying: s.isCopying.value,
|
@@ -11860,10 +11866,10 @@ const getProps$p = () => ({
|
|
11860
11866
|
s.store.setIsUpdatingRequesting(s.formID, !1);
|
11861
11867
|
}
|
11862
11868
|
}
|
11863
|
-
async function
|
11864
|
-
var W, Z, re, se, oe,
|
11865
|
-
const
|
11866
|
-
if (!
|
11869
|
+
async function fe() {
|
11870
|
+
var W, Z, re, se, oe, ue, ne, ce;
|
11871
|
+
const U = (W = s.varButtonCopy.value) == null ? void 0 : W.cmd;
|
11872
|
+
if (!U) {
|
11867
11873
|
KgLogger.error("[KgSubmit] '\u590D\u5236\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
11868
11874
|
VarButton: s.varButtonCopy.value
|
11869
11875
|
});
|
@@ -11871,11 +11877,11 @@ const getProps$p = () => ({
|
|
11871
11877
|
}
|
11872
11878
|
try {
|
11873
11879
|
s.store.setIsCopyingRequesting(s.formID, !0);
|
11874
|
-
let
|
11880
|
+
let _e = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonCopy.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)), ye = ref(KgUtil.parseParams({
|
11875
11881
|
...(se = o.selectedFirstRow.value) != null ? se : {},
|
11876
11882
|
...toRaw(l.model.value)
|
11877
11883
|
}, s.formID, r));
|
11878
|
-
if (((oe = g.value) == null ? void 0 : oe.cpy_clear_id_flg) !== 0 && delete
|
11884
|
+
if (((oe = g.value) == null ? void 0 : oe.cpy_clear_id_flg) !== 0 && delete ye.value.id, await l.store.emit(s.formID, "beforeRequest", {
|
11879
11885
|
isCreating: s.isCreating.value,
|
11880
11886
|
isUpdating: s.isUpdating.value,
|
11881
11887
|
isCopying: s.isCopying.value,
|
@@ -11883,16 +11889,16 @@ const getProps$p = () => ({
|
|
11883
11889
|
row: o.selectedRow.value,
|
11884
11890
|
rows: o.selectedRows.value,
|
11885
11891
|
model: l.model,
|
11886
|
-
params:
|
11887
|
-
data:
|
11892
|
+
params: _e,
|
11893
|
+
data: ye
|
11888
11894
|
}))
|
11889
11895
|
return;
|
11890
11896
|
await httpClient().request({
|
11891
|
-
method: (ne = (
|
11892
|
-
url:
|
11893
|
-
params:
|
11894
|
-
data:
|
11895
|
-
}), ((
|
11897
|
+
method: (ne = (ue = s.varButtonCopy.value) == null ? void 0 : ue.cmd_method) != null ? ne : "POST",
|
11898
|
+
url: U,
|
11899
|
+
params: _e.value,
|
11900
|
+
data: ye.value
|
11901
|
+
}), ((ce = s.varButtonCopy.value) == null ? void 0 : ce.show_success_message_flg) !== 0 && message.success(n.t("kg.copySuccess")), await l.store.emit(s.formID, "ok", {
|
11896
11902
|
isCreating: s.isCreating.value,
|
11897
11903
|
isUpdating: s.isUpdating.value,
|
11898
11904
|
isCopying: s.isCopying.value,
|
@@ -11902,16 +11908,16 @@ const getProps$p = () => ({
|
|
11902
11908
|
}), s.store.setIsCopying(s.formID, !1), c.search({
|
11903
11909
|
isSearchFirstPage: !0
|
11904
11910
|
});
|
11905
|
-
} catch (
|
11906
|
-
console.error(
|
11911
|
+
} catch (_e) {
|
11912
|
+
console.error(_e), l.store.emit(s.formID, "error", _e);
|
11907
11913
|
} finally {
|
11908
11914
|
s.store.setIsCopyingRequesting(s.formID, !1);
|
11909
11915
|
}
|
11910
11916
|
}
|
11911
|
-
async function
|
11912
|
-
var W, Z, re, se, oe,
|
11913
|
-
const
|
11914
|
-
if (!
|
11917
|
+
async function le() {
|
11918
|
+
var W, Z, re, se, oe, ue, ne, ce, _e, ye;
|
11919
|
+
const U = (W = s.varButtonDelete.value) == null ? void 0 : W.cmd;
|
11920
|
+
if (!U) {
|
11915
11921
|
KgLogger.error("[KgSubmit] '\u5220\u9664\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
11916
11922
|
VarButton: s.varButtonDelete.value
|
11917
11923
|
});
|
@@ -11919,9 +11925,9 @@ const getProps$p = () => ({
|
|
11919
11925
|
}
|
11920
11926
|
try {
|
11921
11927
|
s.store.setIsDeletingRequesting(s.formID, !0);
|
11922
|
-
let
|
11923
|
-
if (((oe = s.varButtonDelete.value) == null ? void 0 : oe.del_param_clm) !== "__kg__new_delete_param" && (
|
11924
|
-
ids: (ne = (
|
11928
|
+
let Ee = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (Z = s.varButtonDelete.value) == null ? void 0 : Z.cmd_prm) != null ? re : ""), s.formID, r)), Te = ref((se = o.selectedRows.value) != null ? se : []);
|
11929
|
+
if (((oe = s.varButtonDelete.value) == null ? void 0 : oe.del_param_clm) !== "__kg__new_delete_param" && (Ee = ref({
|
11930
|
+
ids: (ne = (ue = o.selectedRows.value) == null ? void 0 : ue.map((Ie) => {
|
11925
11931
|
var ke, Ae, Me;
|
11926
11932
|
return (Me = Ie[(Ae = (ke = s.varButtonDelete.value) == null ? void 0 : ke.del_param_clm) != null ? Ae : "id"]) != null ? Me : "";
|
11927
11933
|
})) != null ? ne : []
|
@@ -11933,18 +11939,18 @@ const getProps$p = () => ({
|
|
11933
11939
|
row: o.selectedFirstRow.value,
|
11934
11940
|
rows: o.selectedRows.value,
|
11935
11941
|
model: l.model,
|
11936
|
-
params:
|
11942
|
+
params: Ee,
|
11937
11943
|
data: Te
|
11938
11944
|
}))
|
11939
11945
|
return;
|
11940
11946
|
await httpClient().request({
|
11941
|
-
method: (
|
11942
|
-
url:
|
11943
|
-
params:
|
11947
|
+
method: (_e = (ce = s.varButtonDelete.value) == null ? void 0 : ce.cmd_method) != null ? _e : "DELETE",
|
11948
|
+
url: U,
|
11949
|
+
params: Ee.value,
|
11944
11950
|
data: Te.value
|
11945
11951
|
}, {
|
11946
11952
|
joinParamsToUrl: !0
|
11947
|
-
}), ((
|
11953
|
+
}), ((ye = s.varButtonDelete.value) == null ? void 0 : ye.show_success_message_flg) !== 0 && message.success(n.t("kg.deleteSuccess")), await i.store.emit(s.formID, "deleteOk", {
|
11948
11954
|
button: s.varButtonDelete.value,
|
11949
11955
|
rows: o.selectedRows.value
|
11950
11956
|
}), await l.store.emit(s.formID, "ok", {
|
@@ -11957,47 +11963,47 @@ const getProps$p = () => ({
|
|
11957
11963
|
}), s.store.setIsDeleting(s.formID, !1), c.search({
|
11958
11964
|
isSearchFirstPage: !0
|
11959
11965
|
});
|
11960
|
-
} catch (
|
11961
|
-
console.error(
|
11966
|
+
} catch (Ee) {
|
11967
|
+
console.error(Ee), l.store.emit(s.formID, "error", Ee);
|
11962
11968
|
} finally {
|
11963
11969
|
s.store.setIsDeletingRequesting(s.formID, !1);
|
11964
11970
|
}
|
11965
11971
|
}
|
11966
|
-
function
|
11972
|
+
function ve(U) {
|
11967
11973
|
var Z, re;
|
11968
|
-
const W = (re = (Z = a == null ? void 0 : a.KgSubmit) == null ? void 0 : Z["KgForm.Item"]) == null ? void 0 : re[
|
11974
|
+
const W = (re = (Z = a == null ? void 0 : a.KgSubmit) == null ? void 0 : Z["KgForm.Item"]) == null ? void 0 : re[U.var_nam];
|
11969
11975
|
return isFunction$2(W) ? createVNode(KgForm.Item, {
|
11970
|
-
kgVarName:
|
11976
|
+
kgVarName: U.var_nam,
|
11971
11977
|
kgContext: KG_FORM_CONTEXT.SUBMIT,
|
11972
|
-
kgRules: l.rules.value[
|
11978
|
+
kgRules: l.rules.value[U.var_nam],
|
11973
11979
|
onKgSubmit: ee
|
11974
11980
|
}, {
|
11975
11981
|
control: ({
|
11976
11982
|
frm_id: se,
|
11977
11983
|
varName: oe,
|
11978
|
-
props:
|
11984
|
+
props: ue,
|
11979
11985
|
model: ne,
|
11980
|
-
varVariableConfig:
|
11981
|
-
varProfileDetail:
|
11982
|
-
varSubmitField:
|
11986
|
+
varVariableConfig: ce,
|
11987
|
+
varProfileDetail: _e,
|
11988
|
+
varSubmitField: ye
|
11983
11989
|
}) => W({
|
11984
11990
|
frm_id: se,
|
11985
11991
|
varName: oe,
|
11986
|
-
props:
|
11992
|
+
props: ue,
|
11987
11993
|
model: ne,
|
11988
|
-
varVariableConfig:
|
11989
|
-
varProfileDetail:
|
11990
|
-
varSubmitField:
|
11994
|
+
varVariableConfig: ce,
|
11995
|
+
varProfileDetail: _e,
|
11996
|
+
varSubmitField: ye
|
11991
11997
|
})
|
11992
11998
|
}) : createVNode(KgForm.Item, {
|
11993
|
-
kgVarName:
|
11999
|
+
kgVarName: U.var_nam,
|
11994
12000
|
kgContext: KG_FORM_CONTEXT.SUBMIT,
|
11995
|
-
kgRules: l.rules.value[
|
12001
|
+
kgRules: l.rules.value[U.var_nam],
|
11996
12002
|
onKgSubmit: ee
|
11997
12003
|
}, null);
|
11998
12004
|
}
|
11999
|
-
function
|
12000
|
-
let
|
12005
|
+
function be() {
|
12006
|
+
let U, W;
|
12001
12007
|
return createVNode(KgResizable, {
|
12002
12008
|
kgType: l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? "right" : "left",
|
12003
12009
|
kgMinWidth: H.value,
|
@@ -12012,7 +12018,7 @@ const getProps$p = () => ({
|
|
12012
12018
|
default: () => [createVNode(KgForm, {
|
12013
12019
|
ref: l.formRef,
|
12014
12020
|
model: l.model.value,
|
12015
|
-
layout:
|
12021
|
+
layout: me.value,
|
12016
12022
|
labelCol: ae.value,
|
12017
12023
|
wrapperCol: K.value
|
12018
12024
|
}, {
|
@@ -12020,11 +12026,11 @@ const getProps$p = () => ({
|
|
12020
12026
|
ref: Y
|
12021
12027
|
}, [R.value.length > 0 && createVNode(Row, {
|
12022
12028
|
gutter: 12
|
12023
|
-
}, _isSlot$9(
|
12024
|
-
default: () => [
|
12029
|
+
}, _isSlot$9(U = R.value.map(ve)) ? U : {
|
12030
|
+
default: () => [U]
|
12025
12031
|
}), P.value.length > 0 && F.value.length > 0 && createVNode(Divider, null, null), O.value.length > 0 && createVNode(Row, {
|
12026
12032
|
gutter: 12
|
12027
|
-
}, _isSlot$9(W = O.value.map(
|
12033
|
+
}, _isSlot$9(W = O.value.map(ve)) ? W : {
|
12028
12034
|
default: () => [W]
|
12029
12035
|
}), u.value && createVNode("div", {
|
12030
12036
|
style: "text-align: center; padding: 6px 0 12px;"
|
@@ -12033,15 +12039,15 @@ const getProps$p = () => ({
|
|
12033
12039
|
})]
|
12034
12040
|
});
|
12035
12041
|
}
|
12036
|
-
function
|
12037
|
-
let
|
12042
|
+
function Se() {
|
12043
|
+
let U, W;
|
12038
12044
|
return createVNode("div", null, [createVNode(Button, {
|
12039
12045
|
type: "primary",
|
12040
12046
|
ghost: !D.value,
|
12041
12047
|
disabled: D.value,
|
12042
12048
|
onClick: z
|
12043
|
-
}, _isSlot$9(
|
12044
|
-
default: () => [
|
12049
|
+
}, _isSlot$9(U = n.t("kg.cancel")) ? U : {
|
12050
|
+
default: () => [U]
|
12045
12051
|
}), createVNode(Button, {
|
12046
12052
|
type: "primary",
|
12047
12053
|
disabled: V.value,
|
@@ -12052,15 +12058,15 @@ const getProps$p = () => ({
|
|
12052
12058
|
default: () => [W]
|
12053
12059
|
})]);
|
12054
12060
|
}
|
12055
|
-
function
|
12061
|
+
function Ce() {
|
12056
12062
|
return createVNode("div", {
|
12057
12063
|
title: q.title.value
|
12058
12064
|
}, [q.title.value]);
|
12059
12065
|
}
|
12060
|
-
function
|
12066
|
+
function pe() {
|
12061
12067
|
return createVNode(KgSubmitHeader, {
|
12062
12068
|
isFullscreen: te.isFullscreen,
|
12063
|
-
"onUpdate:isFullscreen": (
|
12069
|
+
"onUpdate:isFullscreen": (U) => te.isFullscreen = U,
|
12064
12070
|
kgShowFullscreenButton: !u.value,
|
12065
12071
|
kgShowConfigButton: !u.value && e.kgShowConfigButton,
|
12066
12072
|
onKgCancel: z
|
@@ -12076,13 +12082,13 @@ const getProps$p = () => ({
|
|
12076
12082
|
keyboard: !1,
|
12077
12083
|
destroyOnClose: !0,
|
12078
12084
|
width: X.value,
|
12079
|
-
class:
|
12085
|
+
class: ie.value,
|
12080
12086
|
"kg-frm_id": s.formID
|
12081
12087
|
}, {
|
12082
|
-
title:
|
12083
|
-
extra:
|
12084
|
-
default:
|
12085
|
-
footer:
|
12088
|
+
title: Ce,
|
12089
|
+
extra: pe,
|
12090
|
+
default: be,
|
12091
|
+
footer: Se
|
12086
12092
|
});
|
12087
12093
|
}
|
12088
12094
|
});
|
@@ -12367,10 +12373,10 @@ function useKgTable(e) {
|
|
12367
12373
|
}), g = computed(() => {
|
12368
12374
|
var p, m;
|
12369
12375
|
return (m = (p = t.varGridConfig.value) == null ? void 0 : p.id_clm) != null ? m : "id";
|
12370
|
-
}),
|
12376
|
+
}), y = computed(() => {
|
12371
12377
|
var p, m;
|
12372
12378
|
return JSON.parse((m = (p = t.varGridConfig.value) == null ? void 0 : p.pg_size_opts) != null ? m : "[]");
|
12373
|
-
}),
|
12379
|
+
}), b = computed(() => {
|
12374
12380
|
var p;
|
12375
12381
|
return (p = t.varGridConfig.value) == null ? void 0 : p.pg_size_opt;
|
12376
12382
|
}), _ = computed(() => {
|
@@ -12390,8 +12396,8 @@ function useKgTable(e) {
|
|
12390
12396
|
isShowBottomLeft: u,
|
12391
12397
|
isShowBottomRight: d,
|
12392
12398
|
id: g,
|
12393
|
-
pageSizeOptions:
|
12394
|
-
pageSizeOption:
|
12399
|
+
pageSizeOptions: y,
|
12400
|
+
pageSizeOption: b,
|
12395
12401
|
profileFormID: _,
|
12396
12402
|
onReady: onEventFactory(t.formID, r, "ready"),
|
12397
12403
|
onRowDoubleClick: onEventFactory(t.formID, r, "rowDoubleClick"),
|
@@ -12487,8 +12493,8 @@ const getProps$o = () => ({
|
|
12487
12493
|
}) => {
|
12488
12494
|
const c = a == null ? void 0 : a.store.getVarGridConfig(a.formID);
|
12489
12495
|
return i = watch(l, (u) => {
|
12490
|
-
var d, g,
|
12491
|
-
u && (u.id = (d = c == null ? void 0 : c.id) != null ? d : null, u.frm_id = a == null ? void 0 : a.formID, u.aut_load_flg = (g = c == null ? void 0 : c.aut_load_flg) != null ? g : 0, u.mult_flg = (
|
12496
|
+
var d, g, y, b, _, p, m, E, T, k, A;
|
12497
|
+
u && (u.id = (d = c == null ? void 0 : c.id) != null ? d : null, u.frm_id = a == null ? void 0 : a.formID, u.aut_load_flg = (g = c == null ? void 0 : c.aut_load_flg) != null ? g : 0, u.mult_flg = (y = c == null ? void 0 : c.mult_flg) != null ? y : 0, u.show_check_column_flg = (b = c == null ? void 0 : c.show_check_column_flg) != null ? b : 0, u.show_bottom_left_flg = (_ = c == null ? void 0 : c.show_bottom_left_flg) != null ? _ : 1, u.show_bottom_right_flg = (p = c == null ? void 0 : c.show_bottom_right_flg) != null ? p : 1, u.convert_sort_field_to_under_score_flg = (m = c == null ? void 0 : c.convert_sort_field_to_under_score_flg) != null ? m : 0, u.pg_size_opts = (E = c == null ? void 0 : c.pg_size_opts) != null ? E : "[10, 20, 50, 100]", u.pg_size_opt = (T = c == null ? void 0 : c.pg_size_opt) != null ? T : 10, u.cmd_prm = (k = c == null ? void 0 : c.cmd_prm) != null ? k : void 0, u.button_display_type = (A = c == null ? void 0 : c.button_display_type) != null ? A : KG_BUTTON_DISPLAY_TYPE.DEFAULT);
|
12492
12498
|
}, {
|
12493
12499
|
immediate: !0
|
12494
12500
|
}), KgUtil.hideLoading(), !1;
|
@@ -13198,7 +13204,7 @@ function _useTransferColumns(e, t) {
|
|
13198
13204
|
class: "kg-not-clickable"
|
13199
13205
|
}, {
|
13200
13206
|
default: () => {
|
13201
|
-
let c, u, d, g,
|
13207
|
+
let c, u, d, g, y, b, _;
|
13202
13208
|
return createVNode(Fragment, null, [createVNode(Select.Option, {
|
13203
13209
|
value: "DESC"
|
13204
13210
|
}, _isSlot$7(c = r.t("kg.KgTableSettingConfigModalVarGridMaster.DESC")) ? c : {
|
@@ -13217,12 +13223,12 @@ function _useTransferColumns(e, t) {
|
|
13217
13223
|
default: () => [g]
|
13218
13224
|
}), createVNode(Select.Option, {
|
13219
13225
|
value: "FILE_SIZE"
|
13220
|
-
}, _isSlot$7(
|
13221
|
-
default: () => [
|
13226
|
+
}, _isSlot$7(y = r.t("kg.KgTableSettingConfigModalVarGridMaster.FILE_SIZE")) ? y : {
|
13227
|
+
default: () => [y]
|
13222
13228
|
}), createVNode(Select.Option, {
|
13223
13229
|
value: "UPDATE_LINK"
|
13224
|
-
}, _isSlot$7(
|
13225
|
-
default: () => [
|
13230
|
+
}, _isSlot$7(b = r.t("kg.KgTableSettingConfigModalVarGridMaster.UPDATE_LINK")) ? b : {
|
13231
|
+
default: () => [b]
|
13226
13232
|
}), createVNode(Select.Option, {
|
13227
13233
|
value: "ROUTE_LINK"
|
13228
13234
|
}, _isSlot$7(_ = r.t("kg.KgTableSettingConfigModalVarGridMaster.ROUTE_LINK")) ? _ : {
|
@@ -13300,12 +13306,12 @@ function _useDragRow$1(e, t, r) {
|
|
13300
13306
|
const g = document.createElement("span");
|
13301
13307
|
g.setAttribute("id", "__kg_table_config_fields_drag_image__");
|
13302
13308
|
const {
|
13303
|
-
width:
|
13304
|
-
height:
|
13309
|
+
width: y,
|
13310
|
+
height: b
|
13305
13311
|
} = u.parentElement.getBoundingClientRect();
|
13306
|
-
|
13312
|
+
y && b && (g.style.width = `${y + 2}px`, g.style.height = `${b + 2}px`), (p = d.dataTransfer) == null || p.setDragImage(g, -10, (b + 2) / 2);
|
13307
13313
|
const _ = await toCanvas(u.parentElement);
|
13308
|
-
g.appendChild(_), document.body.appendChild(g), (m = d.dataTransfer) == null || m.setDragImage(g, -10, (
|
13314
|
+
g.appendChild(_), document.body.appendChild(g), (m = d.dataTransfer) == null || m.setDragImage(g, -10, (b + 2) / 2);
|
13309
13315
|
}, u.addEventListener("dragstart", u.__kg__dragstart__), u.__kg__dragend__ = (d) => {
|
13310
13316
|
u.classList.remove("dragging"), u.parentElement.classList.remove("dragging");
|
13311
13317
|
const g = document.querySelector("#__kg_table_config_fields_drag_image__");
|
@@ -13318,19 +13324,19 @@ function _useDragRow$1(e, t, r) {
|
|
13318
13324
|
if (a = filter(document.querySelectorAll(`tr[kg-host-frm_id="${e}"]`), () => !0), a)
|
13319
13325
|
for (let u of a)
|
13320
13326
|
u.__kg__dragover__ = (d) => {
|
13321
|
-
var g,
|
13322
|
-
d.preventDefault(), u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((
|
13327
|
+
var g, y;
|
13328
|
+
d.preventDefault(), u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((y = s == null ? void 0 : s.rowIndex) != null ? y : -1) && u.classList.add("dragover", "dragover-left");
|
13323
13329
|
}, u.addEventListener("dragover", u.__kg__dragover__, !1), u.__kg__dragenter__ = (d) => {
|
13324
|
-
var g,
|
13325
|
-
u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((
|
13330
|
+
var g, y;
|
13331
|
+
u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((y = s == null ? void 0 : s.rowIndex) != null ? y : -1) && u.classList.add("dragover", "dragover-left");
|
13326
13332
|
}, u.addEventListener("dragenter", u.__kg__dragenter__), u.__kg__dragleave__ = (d) => {
|
13327
13333
|
u.classList.remove("dragover", "dragover-right", "dragover-left");
|
13328
13334
|
}, u.addEventListener("dragleave", u.__kg__dragleave__), u.__kg__drop__ = (d) => {
|
13329
13335
|
d.preventDefault(), KgUtil.showLoading();
|
13330
13336
|
const g = document.querySelector("#__kg_table_config_fields_drag_image__");
|
13331
13337
|
g && document.body.removeChild(g), u.classList.remove("dragover", "dragover-right", "dragover-left");
|
13332
|
-
const
|
13333
|
-
|
13338
|
+
const y = s == null ? void 0 : s.getAttribute("kg-var_nam"), b = u.getAttribute("kg-var_nam");
|
13339
|
+
y !== b && l(y, b);
|
13334
13340
|
}, u.addEventListener("drop", u.__kg__drop__);
|
13335
13341
|
}
|
13336
13342
|
function o() {
|
@@ -13349,12 +13355,12 @@ function _useDragRow$1(e, t, r) {
|
|
13349
13355
|
}
|
13350
13356
|
function l(u, d) {
|
13351
13357
|
setTimeout(() => {
|
13352
|
-
const g = t.value.findIndex((p) => p.var_nam === u),
|
13353
|
-
if (g === -1 ||
|
13358
|
+
const g = t.value.findIndex((p) => p.var_nam === u), y = t.value.findIndex((p) => p.var_nam === d);
|
13359
|
+
if (g === -1 || y === -1)
|
13354
13360
|
return;
|
13355
|
-
const
|
13361
|
+
const b = t.value.find((p) => p.var_nam === u), _ = [];
|
13356
13362
|
t.value.forEach((p, m) => {
|
13357
|
-
g >
|
13363
|
+
g > y ? m < y ? _.push(p) : m === y ? (_.push(b), _.push(p)) : m > y && m !== g && _.push(p) : g < y && (m < g ? _.push(p) : m === g || (m === y ? (_.push(p), _.push(b)) : _.push(p)));
|
13358
13364
|
}), _.forEach((p, m) => {
|
13359
13365
|
p.srtseq = m + 1;
|
13360
13366
|
}), t.value = _, nextTick().finally(() => {
|
@@ -13387,7 +13393,7 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13387
13393
|
s.onReady(async () => (await n.store.patchVarProfileDetail(n.formID, "frm_id", {
|
13388
13394
|
dft_val: a.formID
|
13389
13395
|
}), !1)), o.onOpen(async ({
|
13390
|
-
isCreating:
|
13396
|
+
isCreating: E,
|
13391
13397
|
isUpdating: T,
|
13392
13398
|
isCopying: k,
|
13393
13399
|
row: A,
|
@@ -13396,7 +13402,7 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13396
13402
|
var w, I, R, P, O;
|
13397
13403
|
const M = a.store.getSystemVarGridDetails(a.formID);
|
13398
13404
|
switch (c.value = M ? cloneDeep(unref(toRaw(M))) : [], !0) {
|
13399
|
-
case
|
13405
|
+
case E: {
|
13400
13406
|
u.value = [];
|
13401
13407
|
break;
|
13402
13408
|
}
|
@@ -13439,14 +13445,14 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13439
13445
|
}
|
13440
13446
|
return !1;
|
13441
13447
|
}), o.onBeforeOk(async ({
|
13442
|
-
model:
|
13448
|
+
model: E
|
13443
13449
|
}) => {
|
13444
13450
|
var k, A;
|
13445
|
-
const T =
|
13451
|
+
const T = E.value;
|
13446
13452
|
return T.frm_id = a.formID, T.varGridDetails = (A = (k = c.value) == null ? void 0 : k.filter((C) => u.value.includes(C.id))) != null ? A : [], !1;
|
13447
13453
|
}), o.onOk(async () => (a.store.retrieve(a.formID), !1)), i.onUpdateBeforeClick(({
|
13448
|
-
row:
|
13449
|
-
}) => (
|
13454
|
+
row: E
|
13455
|
+
}) => (E == null ? void 0 : E.cust_lvl) === KG_CUSTOM_LEVEL.L0 ? new Promise((T) => {
|
13450
13456
|
KgUtil.confirm({
|
13451
13457
|
content: r.t("kg.KgTable.canNotUpdateSystemVarGridMaster"),
|
13452
13458
|
okButtonProps: {
|
@@ -13462,11 +13468,11 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13462
13468
|
}) : Promise.resolve(!1));
|
13463
13469
|
const c = ref([]), u = ref([]), d = ref([]), {
|
13464
13470
|
leftColumns: g,
|
13465
|
-
rightColumns:
|
13471
|
+
rightColumns: y
|
13466
13472
|
} = _useTransferColumns(e.hostFormID, c);
|
13467
13473
|
_useDragRow$1(e.hostFormID, c, d);
|
13468
|
-
const
|
13469
|
-
const
|
13474
|
+
const b = computed(() => {
|
13475
|
+
const E = l.selectedRow.value;
|
13470
13476
|
return {
|
13471
13477
|
KgSubmit: {
|
13472
13478
|
kgClass: "kg-submit--kg-table-setting-config-modal--var-grid-master"
|
@@ -13475,7 +13481,7 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13475
13481
|
kgDisabled: (T) => {
|
13476
13482
|
switch (T.var_nam) {
|
13477
13483
|
case "set-default":
|
13478
|
-
if ((
|
13484
|
+
if ((E == null ? void 0 : E.def_flg) === 1)
|
13479
13485
|
return !0;
|
13480
13486
|
break;
|
13481
13487
|
}
|
@@ -13488,18 +13494,18 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13488
13494
|
varGridDetails: () => createVNode(Transfer, {
|
13489
13495
|
dataSource: c.value,
|
13490
13496
|
targetKeys: u.value,
|
13491
|
-
"onUpdate:targetKeys": (
|
13492
|
-
rowKey: (
|
13497
|
+
"onUpdate:targetKeys": (E) => u.value = E,
|
13498
|
+
rowKey: (E) => E.id,
|
13493
13499
|
showSearch: !0,
|
13494
13500
|
showSelectAll: !1,
|
13495
13501
|
searchPlaceholder: " ",
|
13496
|
-
filterOption: (
|
13502
|
+
filterOption: (E, T) => {
|
13497
13503
|
var k;
|
13498
|
-
return !!((k = T.var_nam) != null && k.includes(
|
13504
|
+
return !!((k = T.var_nam) != null && k.includes(E));
|
13499
13505
|
}
|
13500
13506
|
}, {
|
13501
13507
|
children: ({
|
13502
|
-
direction:
|
13508
|
+
direction: E,
|
13503
13509
|
filteredItems: T,
|
13504
13510
|
selectedKeys: k,
|
13505
13511
|
disabled: A,
|
@@ -13515,17 +13521,17 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13515
13521
|
class: "kg-flex-table",
|
13516
13522
|
size: "small",
|
13517
13523
|
scroll: {
|
13518
|
-
x:
|
13524
|
+
x: E === "left" ? "370px" : `${1552 + 32}px`,
|
13519
13525
|
y: "auto"
|
13520
13526
|
},
|
13521
|
-
columns:
|
13527
|
+
columns: E === "left" ? g() : y(),
|
13522
13528
|
rowKey: "id",
|
13523
13529
|
dataSource: w,
|
13524
13530
|
customRow: (I) => {
|
13525
13531
|
let R = {
|
13526
|
-
onClick: (P) => m(P, I,
|
13532
|
+
onClick: (P) => m(P, I, E, k)
|
13527
13533
|
};
|
13528
|
-
return
|
13534
|
+
return E === "right" && (R["kg-host-frm_id"] = a.formID, R["kg-var_nam"] = I.var_nam), R;
|
13529
13535
|
},
|
13530
13536
|
rowSelection: p({
|
13531
13537
|
disabled: A,
|
@@ -13539,13 +13545,13 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13539
13545
|
}
|
13540
13546
|
}
|
13541
13547
|
}), p = ({
|
13542
|
-
disabled:
|
13548
|
+
disabled: E,
|
13543
13549
|
selectedKeys: T,
|
13544
13550
|
onItemSelectAll: k,
|
13545
13551
|
onItemSelect: A
|
13546
13552
|
}) => ({
|
13547
13553
|
getCheckboxProps: (C) => ({
|
13548
|
-
disabled:
|
13554
|
+
disabled: E || C.disabled
|
13549
13555
|
}),
|
13550
13556
|
onSelectAll(C, M) {
|
13551
13557
|
const w = M.filter((I) => !I.disabled).map(({
|
@@ -13561,9 +13567,9 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13561
13567
|
selectedRowKeys: T,
|
13562
13568
|
columnWidth: 32
|
13563
13569
|
});
|
13564
|
-
function m(
|
13565
|
-
if (!KgDomUtil.isNotClickable(
|
13566
|
-
switch (A.length = 0,
|
13570
|
+
function m(E, T, k, A) {
|
13571
|
+
if (!KgDomUtil.isNotClickable(E.target, ["ant-input"]))
|
13572
|
+
switch (A.length = 0, E.detail) {
|
13567
13573
|
case 1:
|
13568
13574
|
A[0] = T.id;
|
13569
13575
|
break;
|
@@ -13581,7 +13587,7 @@ const KgTable_Setting_ConfigModal_VarGridMaster = "", getProps$m = () => ({
|
|
13581
13587
|
}
|
13582
13588
|
return () => createVNode(KgVar, {
|
13583
13589
|
class: "kg-table--config-modal--var-grid-master",
|
13584
|
-
kgProps:
|
13590
|
+
kgProps: b.value,
|
13585
13591
|
kgSlots: _.value
|
13586
13592
|
}, null);
|
13587
13593
|
}
|
@@ -13693,9 +13699,9 @@ const FORM_ID__VAR_GRID_MASTER__SAVE = "kg-table.VarGridMaster.Save", KgTableSet
|
|
13693
13699
|
return o.onOpen(async ({
|
13694
13700
|
model: l
|
13695
13701
|
}) => {
|
13696
|
-
var u, d, g,
|
13702
|
+
var u, d, g, y, b, _, p;
|
13697
13703
|
const c = s.currentVarGridMaster.value;
|
13698
|
-
return l.value.grd_var_nam = `${(u = c == null ? void 0 : c.grd_var_nam) != null ? u : ""}_COPY`, l.value.grd_var_nam_dsc = `${(g = (d = c == null ? void 0 : c.grd_var_nam_dsc) != null ? d : c == null ? void 0 : c.grd_var_nam) != null ? g : ""}_COPY`, l.value.frm_id = (
|
13704
|
+
return l.value.grd_var_nam = `${(u = c == null ? void 0 : c.grd_var_nam) != null ? u : ""}_COPY`, l.value.grd_var_nam_dsc = `${(g = (d = c == null ? void 0 : c.grd_var_nam_dsc) != null ? d : c == null ? void 0 : c.grd_var_nam) != null ? g : ""}_COPY`, l.value.frm_id = (y = c == null ? void 0 : c.frm_id) != null ? y : "", l.value.usr_id = (b = c == null ? void 0 : c.usr_id) != null ? b : "", l.value.grp_nam = (_ = c == null ? void 0 : c.grp_nam) != null ? _ : "", l.value.varGridDetails = (p = c == null ? void 0 : c.varGridDetails) != null ? p : [], KgUtil.hideLoading(), !1;
|
13699
13705
|
}), o.onBeforeOk(async ({
|
13700
13706
|
model: l
|
13701
13707
|
}) => (l.value, !1)), o.onOk(async () => (message.success(a.t("kg.KgTable.save-var-grid-master-as-success-message")), s.store.retrieve(s.formID), !1)), o.onClose(async () => (r("kgClose"), !1)), i.store.setIsCopying(i.formID, !0), () => createVNode(KgVar, null, null);
|
@@ -13722,13 +13728,13 @@ const getProps$j = () => ({
|
|
13722
13728
|
visible: !1
|
13723
13729
|
}), g = ref({
|
13724
13730
|
visible: !1
|
13725
|
-
}),
|
13731
|
+
}), y = computed(() => isNil(e.kgDisabled) ? !!n.isCreating.value || !!n.isCreating.value || !!n.isCreating.value || !!n.isCreating.value : e.kgDisabled);
|
13726
13732
|
_useObserveMenuColumns(l), watch(l, (C) => {
|
13727
13733
|
C || (c.value = "");
|
13728
13734
|
}, {
|
13729
13735
|
immediate: !0
|
13730
13736
|
});
|
13731
|
-
function
|
13737
|
+
function b(C) {
|
13732
13738
|
n.store.patchVarGridDetail(n.formID, C.var_nam, {
|
13733
13739
|
vis_flg: C.vis_flg === 1 ? 0 : 1
|
13734
13740
|
});
|
@@ -13759,7 +13765,7 @@ const getProps$j = () => ({
|
|
13759
13765
|
async function m() {
|
13760
13766
|
g.value.visible = !0;
|
13761
13767
|
}
|
13762
|
-
function
|
13768
|
+
function E() {
|
13763
13769
|
return createVNode(Menu.SubMenu, {
|
13764
13770
|
key: "columns",
|
13765
13771
|
title: a.t("kg.KgTable.column"),
|
@@ -13778,7 +13784,7 @@ const getProps$j = () => ({
|
|
13778
13784
|
}, [(C = n.currentVarGridDetails.value) == null ? void 0 : C.map((M) => createVNode("li", {
|
13779
13785
|
class: "ant-dropdown-menu-item ant-dropdown-menu-item-only-child",
|
13780
13786
|
onClick: (w) => {
|
13781
|
-
w.preventDefault(), w.stopPropagation(),
|
13787
|
+
w.preventDefault(), w.stopPropagation(), b(M);
|
13782
13788
|
},
|
13783
13789
|
style: {
|
13784
13790
|
display: i(M, c.value) ? "flex" : "none"
|
@@ -13885,7 +13891,7 @@ const getProps$j = () => ({
|
|
13885
13891
|
});
|
13886
13892
|
}
|
13887
13893
|
return () => createVNode(Fragment, null, [createVNode(Dropdown, {
|
13888
|
-
disabled:
|
13894
|
+
disabled: y.value,
|
13889
13895
|
class: "kg-table-setting",
|
13890
13896
|
overlayClassName: "kg-table-setting-dropdown",
|
13891
13897
|
trigger: "click"
|
@@ -13897,7 +13903,7 @@ const getProps$j = () => ({
|
|
13897
13903
|
"onUpdate:openKeys": (C) => o.value = C,
|
13898
13904
|
selectable: !1
|
13899
13905
|
}, {
|
13900
|
-
default: () => [
|
13906
|
+
default: () => [E(), k(), T(), A()]
|
13901
13907
|
})
|
13902
13908
|
}), d.value.visible && createVNode(KgTableSettingConfigModal, {
|
13903
13909
|
visible: d.value.visible,
|
@@ -13955,7 +13961,7 @@ const getProps$h = () => ({
|
|
13955
13961
|
s.onSubmitSave(async () => {
|
13956
13962
|
var k;
|
13957
13963
|
try {
|
13958
|
-
await ((k =
|
13964
|
+
await ((k = b.value) == null ? void 0 : k.validate());
|
13959
13965
|
} catch (A) {
|
13960
13966
|
KgUtil.throwIfNotFormError(A);
|
13961
13967
|
}
|
@@ -13971,7 +13977,7 @@ const getProps$h = () => ({
|
|
13971
13977
|
var A, C;
|
13972
13978
|
let k = "kg-table-td";
|
13973
13979
|
return ((A = l.value) == null ? void 0 : A.align) === "center" ? k += " kg-table-td--center" : ((C = l.value) == null ? void 0 : C.align) === "right" && (k += " kg-table-td--right"), u.value && (k += " kg-table-td--submitting"), k;
|
13974
|
-
}),
|
13980
|
+
}), y = computed(() => {
|
13975
13981
|
var A, C, M, w, I;
|
13976
13982
|
if (e.kgValue === KG_TABLE_TEMP_ID)
|
13977
13983
|
return "";
|
@@ -13986,7 +13992,7 @@ const getProps$h = () => ({
|
|
13986
13992
|
}
|
13987
13993
|
return isString$1(k) && (k = k.replaceAll("\\n", `
|
13988
13994
|
`)), isNil(k) && (k = ""), k;
|
13989
|
-
}),
|
13995
|
+
}), b = ref(null);
|
13990
13996
|
function _(k) {
|
13991
13997
|
var A, C, M;
|
13992
13998
|
if (k.detail === 1 && !(n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value))
|
@@ -14017,7 +14023,7 @@ const getProps$h = () => ({
|
|
14017
14023
|
}
|
14018
14024
|
function m() {
|
14019
14025
|
return createVNode(KgForm, {
|
14020
|
-
ref:
|
14026
|
+
ref: b,
|
14021
14027
|
model: i.model.value,
|
14022
14028
|
layout: "vertical",
|
14023
14029
|
wrapperCol: {
|
@@ -14036,7 +14042,7 @@ const getProps$h = () => ({
|
|
14036
14042
|
})]
|
14037
14043
|
});
|
14038
14044
|
}
|
14039
|
-
function
|
14045
|
+
function E() {
|
14040
14046
|
var k, A, C, M, w, I, R, P, O, F, $;
|
14041
14047
|
if (u.value)
|
14042
14048
|
return m();
|
@@ -14064,10 +14070,10 @@ const getProps$h = () => ({
|
|
14064
14070
|
const D = KgUtil.tryParseJSON((I = l.value) == null ? void 0 : I.display_type_properties);
|
14065
14071
|
if (D.isTag && isArrayLike(D.tagColors)) {
|
14066
14072
|
const V = D.tagColors.find((N) => N.value === e.kgValue);
|
14067
|
-
return
|
14073
|
+
return y.value ? createVNode(Tag, {
|
14068
14074
|
color: (R = V == null ? void 0 : V.color) != null ? R : "default"
|
14069
14075
|
}, {
|
14070
|
-
default: () => [
|
14076
|
+
default: () => [y.value]
|
14071
14077
|
}) : T();
|
14072
14078
|
} else
|
14073
14079
|
return T();
|
@@ -14113,16 +14119,16 @@ const getProps$h = () => ({
|
|
14113
14119
|
function T(k = !1) {
|
14114
14120
|
let A = "";
|
14115
14121
|
return k && !(n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value) && (A += "kg-table-td-update-link"), createVNode("pre", {
|
14116
|
-
innerHTML:
|
14122
|
+
innerHTML: y.value,
|
14117
14123
|
class: A,
|
14118
14124
|
onClick: _
|
14119
14125
|
}, null);
|
14120
14126
|
}
|
14121
14127
|
return () => createVNode("div", {
|
14122
14128
|
class: g.value,
|
14123
|
-
title:
|
14129
|
+
title: y.value,
|
14124
14130
|
"kg-value": e.kgValue
|
14125
|
-
}, [
|
14131
|
+
}, [E()]);
|
14126
14132
|
}
|
14127
14133
|
});
|
14128
14134
|
function _useRenderBodyCell() {
|
@@ -14138,26 +14144,26 @@ function _useRenderBodyCell() {
|
|
14138
14144
|
record: u,
|
14139
14145
|
text: d,
|
14140
14146
|
value: g
|
14141
|
-
} = i,
|
14142
|
-
let
|
14143
|
-
l.customRender ?
|
14147
|
+
} = i, y = l.dataIndex;
|
14148
|
+
let b = "";
|
14149
|
+
l.customRender ? b = l.customRender({
|
14144
14150
|
index: c,
|
14145
14151
|
record: u,
|
14146
14152
|
column: l,
|
14147
14153
|
text: d,
|
14148
14154
|
value: g,
|
14149
14155
|
renderIndex: c
|
14150
|
-
}) :
|
14156
|
+
}) : b = g;
|
14151
14157
|
const _ = createVNode(KgTableCell, {
|
14152
14158
|
kgContext: o,
|
14153
14159
|
kgRow: u,
|
14154
|
-
kgValue:
|
14155
|
-
kgVarName:
|
14160
|
+
kgValue: b,
|
14161
|
+
kgVarName: y,
|
14156
14162
|
onKgUpdateLinkClick: () => n(u)
|
14157
14163
|
}, null);
|
14158
14164
|
if (!((m = e == null ? void 0 : e.KgTable) != null && m.bodyCell))
|
14159
14165
|
return _;
|
14160
|
-
const p = t.store.getVarGridDetail(t.formID,
|
14166
|
+
const p = t.store.getVarGridDetail(t.formID, y);
|
14161
14167
|
return e.KgTable.bodyCell({
|
14162
14168
|
column: l,
|
14163
14169
|
index: c,
|
@@ -14177,11 +14183,11 @@ function _useColumns(e) {
|
|
14177
14183
|
const t = inject(DI_KG_VAR__KG_PROPS, null), r = useKgVar(), a = useKgSearch(), n = useKgSubmit(), s = useKgTable(), {
|
14178
14184
|
renderBodyCell: i
|
14179
14185
|
} = _useRenderBodyCell(), o = ref({}), l = ref({}), c = computed(() => {
|
14180
|
-
var
|
14181
|
-
return ((
|
14186
|
+
var y;
|
14187
|
+
return ((y = r.store.getVarGridConfig(r.formID)) == null ? void 0 : y.show_check_column_flg) === 1;
|
14182
14188
|
}), u = computed(() => {
|
14183
14189
|
var T, k, A;
|
14184
|
-
const
|
14190
|
+
const y = useKg(), b = s.store.getDatas(r.formID), _ = (T = s.store.getTableWidth(r.formID)) != null ? T : 0, p = (k = r.store.getCurrentVisibleVarGridDetailsTotalWidth(r.formID)) != null ? k : 0, m = r.store.getCurrentVisibleVarGridDetails(r.formID), E = [{
|
14185
14191
|
dataIndex: "index",
|
14186
14192
|
width: KG_TABLE_TD_INDEX_WIDTH,
|
14187
14193
|
fixed: "left",
|
@@ -14207,15 +14213,15 @@ function _useColumns(e) {
|
|
14207
14213
|
}
|
14208
14214
|
function O() {
|
14209
14215
|
var L, x, Y, q;
|
14210
|
-
return !(C.ord_flg !== 1 || (x = (L = t == null ? void 0 : t.value) == null ? void 0 : L.KgTable) != null && x.kgDisabled || isNil((q = (Y = t == null ? void 0 : t.value) == null ? void 0 : Y.KgTable) == null ? void 0 : q.kgDisabled) && e.kgDisabled || r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value ||
|
14216
|
+
return !(C.ord_flg !== 1 || (x = (L = t == null ? void 0 : t.value) == null ? void 0 : L.KgTable) != null && x.kgDisabled || isNil((q = (Y = t == null ? void 0 : t.value) == null ? void 0 : Y.KgTable) == null ? void 0 : q.kgDisabled) && e.kgDisabled || r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || b.length <= 0);
|
14211
14217
|
}
|
14212
14218
|
function F() {
|
14213
14219
|
var L, x, Y, q, X, J;
|
14214
|
-
if (((x = (L =
|
14215
|
-
return uniqBy(
|
14216
|
-
var
|
14220
|
+
if (((x = (L = y.option.value.KgTable) == null ? void 0 : L.filter) == null ? void 0 : x.on) === !0 && C.filter_flag === 1 && !((q = (Y = t == null ? void 0 : t.value) == null ? void 0 : Y.KgTable) != null && q.kgDisabled) && !(isNil((J = (X = t == null ? void 0 : t.value) == null ? void 0 : X.KgTable) == null ? void 0 : J.kgDisabled) && e.kgDisabled) && !(r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value) && !(b.length <= 0))
|
14221
|
+
return uniqBy(b.map((te) => {
|
14222
|
+
var ie;
|
14217
14223
|
return {
|
14218
|
-
value: (
|
14224
|
+
value: (ie = te == null ? void 0 : te[w]) != null ? ie : "",
|
14219
14225
|
text: i({
|
14220
14226
|
column: {
|
14221
14227
|
dataIndex: w
|
@@ -14229,7 +14235,7 @@ function _useColumns(e) {
|
|
14229
14235
|
}
|
14230
14236
|
function $() {
|
14231
14237
|
var L, x, Y;
|
14232
|
-
return ((x = (L =
|
14238
|
+
return ((x = (L = y.option.value.KgTable) == null ? void 0 : L.filter) == null ? void 0 : x.on) !== !0 ? null : ((Y = o.value) == null ? void 0 : Y[w]) || null;
|
14233
14239
|
}
|
14234
14240
|
function D() {
|
14235
14241
|
return ["left", "center", "right"].includes(C.align || "") ? C.align : "left";
|
@@ -14280,17 +14286,17 @@ function _useColumns(e) {
|
|
14280
14286
|
}
|
14281
14287
|
};
|
14282
14288
|
})) != null ? A : []];
|
14283
|
-
return (p === 0 || _ > p && !(m != null && m.find((C) => C.width === "auto"))) &&
|
14289
|
+
return (p === 0 || _ > p && !(m != null && m.find((C) => C.width === "auto"))) && E.push({
|
14284
14290
|
width: "auto",
|
14285
14291
|
customRender: () => null
|
14286
|
-
}),
|
14292
|
+
}), E;
|
14287
14293
|
}), d = computed(() => {
|
14288
|
-
var
|
14289
|
-
let
|
14290
|
-
return c.value && (
|
14294
|
+
var b;
|
14295
|
+
let y = 0;
|
14296
|
+
return c.value && (y += KG_TABLE_TD_CHECK_WIDTH), y += KG_TABLE_TD_INDEX_WIDTH, y += (b = r.store.getCurrentVisibleVarGridDetailsTotalWidth(r.formID)) != null ? b : 0, `${y}px`;
|
14291
14297
|
});
|
14292
14298
|
let g = null;
|
14293
|
-
return watch(r.currentVarGridMasteID, (
|
14299
|
+
return watch(r.currentVarGridMasteID, (y, b) => {
|
14294
14300
|
l.value = {}, g == null || g(), g = watch(l, () => {
|
14295
14301
|
g(), g = null, a.search({
|
14296
14302
|
isSearchFirstPage: !0
|
@@ -14335,7 +14341,7 @@ function _useDragColumn(e, t) {
|
|
14335
14341
|
if (a = filter((o = e.value) == null ? void 0 : o.querySelectorAll("div.ant-table-header > table > thead > tr >th"), (l) => l.hasAttribute("kg-var_nam")), a)
|
14336
14342
|
for (let l of a)
|
14337
14343
|
l.__kg__dragstart__ = (c) => {
|
14338
|
-
var
|
14344
|
+
var y;
|
14339
14345
|
n = l, l.classList.add("dragging"), l.parentElement.classList.add("dragging");
|
14340
14346
|
const u = document.createElement("span");
|
14341
14347
|
u.setAttribute("id", "__kg_table_header_drag_image__");
|
@@ -14343,9 +14349,9 @@ function _useDragColumn(e, t) {
|
|
14343
14349
|
width: d,
|
14344
14350
|
height: g
|
14345
14351
|
} = l.getBoundingClientRect();
|
14346
|
-
d && g && (u.style.width = `${d + 2}px`, u.style.height = `${g + 2}px`), (
|
14352
|
+
d && g && (u.style.width = `${d + 2}px`, u.style.height = `${g + 2}px`), (y = c.dataTransfer) == null || y.setDragImage(u, -10, (g + 2) / 2), toCanvas(l).then((b) => {
|
14347
14353
|
var _;
|
14348
|
-
u.appendChild(
|
14354
|
+
u.appendChild(b), document.body.appendChild(u), (_ = c.dataTransfer) == null || _.setDragImage(u, -10, (g + 2) / 2);
|
14349
14355
|
});
|
14350
14356
|
}, l.addEventListener("dragstart", l.__kg__dragstart__), l.__kg__dragend__ = (c) => {
|
14351
14357
|
l.classList.remove("dragging"), l.parentElement.classList.remove("dragging");
|
@@ -14367,8 +14373,8 @@ function _useDragColumn(e, t) {
|
|
14367
14373
|
c.preventDefault(), l.classList.remove("dragover", "dragover-right", "dragover-left");
|
14368
14374
|
const u = n == null ? void 0 : n.getAttribute("kg-frm_id"), d = l.getAttribute("kg-frm_id");
|
14369
14375
|
if (u === d) {
|
14370
|
-
const g = n == null ? void 0 : n.getAttribute("kg-var_nam"),
|
14371
|
-
g !==
|
14376
|
+
const g = n == null ? void 0 : n.getAttribute("kg-var_nam"), y = l.getAttribute("kg-var_nam");
|
14377
|
+
g !== y && r.store.dragSortCurrentVarGridDetails(r.formID, g, y);
|
14372
14378
|
}
|
14373
14379
|
}, l.addEventListener("drop", l.__kg__drop__);
|
14374
14380
|
}
|
@@ -14444,12 +14450,12 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14444
14450
|
isSearchFirstPage: !0
|
14445
14451
|
}), !1)), o.store.$onAction(async ({
|
14446
14452
|
name: K,
|
14447
|
-
args:
|
14453
|
+
args: G
|
14448
14454
|
}) => {
|
14449
14455
|
switch (K) {
|
14450
14456
|
case "setRowSelect":
|
14451
|
-
if (
|
14452
|
-
const Q =
|
14457
|
+
if (G[0] === s.formID) {
|
14458
|
+
const Q = G[1], z = G[2], ee = Q[o.id.value];
|
14453
14459
|
switch (!0) {
|
14454
14460
|
case (z && !$.value.includes(ee)):
|
14455
14461
|
x([...$.value, ee]);
|
@@ -14461,7 +14467,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14461
14467
|
}
|
14462
14468
|
break;
|
14463
14469
|
case "clearDatas":
|
14464
|
-
|
14470
|
+
G[0] === s.formID && (o.store.setDatas(s.formID, []), D.total = 0, H(), c.value = []);
|
14465
14471
|
break;
|
14466
14472
|
}
|
14467
14473
|
});
|
@@ -14469,48 +14475,48 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14469
14475
|
columns: u,
|
14470
14476
|
filterInfo: d,
|
14471
14477
|
sorterInfo: g,
|
14472
|
-
scrollX:
|
14478
|
+
scrollX: y
|
14473
14479
|
} = _useColumns(e), {
|
14474
|
-
isLoading:
|
14480
|
+
isLoading: b
|
14475
14481
|
} = _useLoading(), _ = ref(null), {
|
14476
14482
|
renderBodyCell: p
|
14477
14483
|
} = _useRenderBodyCell();
|
14478
14484
|
_useResizeObserver(_), _useDragColumn(_, u);
|
14479
14485
|
const {
|
14480
14486
|
datas: m,
|
14481
|
-
transformDatas:
|
14487
|
+
transformDatas: E
|
14482
14488
|
} = _useDatas(), T = computed(() => {
|
14483
|
-
var K,
|
14484
|
-
return (
|
14489
|
+
var K, G;
|
14490
|
+
return (G = (K = s.varButtonSearch.value) == null ? void 0 : K.cmd) != null ? G : null;
|
14485
14491
|
}), k = computed(() => {
|
14486
|
-
var
|
14492
|
+
var G, Q, z, ee, he, ge, fe, le, ve;
|
14487
14493
|
let K = {
|
14488
14494
|
pageNo: D.pageIndex,
|
14489
14495
|
pageSize: D.pageSize,
|
14490
|
-
column: (Q = (
|
14496
|
+
column: (Q = (G = g.value) == null ? void 0 : G.field) != null ? Q : void 0,
|
14491
14497
|
order: g.value.order === "ascend" ? "asc" : g.value.order === "descend" ? "desc" : void 0,
|
14492
14498
|
...(ee = (z = i.model) == null ? void 0 : z.value) != null ? ee : {}
|
14493
14499
|
};
|
14494
14500
|
return s.varButtonSearch.value && (K = {
|
14495
14501
|
...K,
|
14496
|
-
...KgVarUtil.parseCommandParameter((
|
14497
|
-
}), (
|
14502
|
+
...KgVarUtil.parseCommandParameter((ge = (he = s.varButtonSearch.value) == null ? void 0 : he.cmd_prm) != null ? ge : "")
|
14503
|
+
}), (fe = s.varGridConfig.value) != null && fe.cmd_prm && (K = {
|
14498
14504
|
...K,
|
14499
|
-
...KgVarUtil.parseCommandParameter((
|
14500
|
-
}), ((
|
14505
|
+
...KgVarUtil.parseCommandParameter((le = s.varGridConfig.value.cmd_prm) != null ? le : "")
|
14506
|
+
}), ((ve = s.varGridConfig.value) == null ? void 0 : ve.convert_sort_field_to_under_score_flg) === 1 && K.column && (K.column = snakeCase$1(K.column)), K;
|
14501
14507
|
}), A = computed(() => {
|
14502
|
-
var K,
|
14503
|
-
if (!isNil((
|
14508
|
+
var K, G, Q, z;
|
14509
|
+
if (!isNil((G = (K = a == null ? void 0 : a.value) == null ? void 0 : K.KgTable) == null ? void 0 : G.kgDisabled))
|
14504
14510
|
return (z = (Q = a == null ? void 0 : a.value) == null ? void 0 : Q.KgTable) == null ? void 0 : z.kgDisabled;
|
14505
14511
|
if (!isNil(e.kgDisabled))
|
14506
14512
|
return e.kgDisabled;
|
14507
14513
|
}), C = computed(() => {
|
14508
|
-
var K,
|
14509
|
-
if (!isNil((
|
14514
|
+
var K, G, Q, z;
|
14515
|
+
if (!isNil((G = (K = a == null ? void 0 : a.value) == null ? void 0 : K.KgTable) == null ? void 0 : G.kgCheckboxDisabled))
|
14510
14516
|
return (z = (Q = a == null ? void 0 : a.value) == null ? void 0 : Q.KgTable) == null ? void 0 : z.kgCheckboxDisabled;
|
14511
14517
|
if (!isNil(e.kgCheckboxDisabled))
|
14512
14518
|
return e.kgCheckboxDisabled;
|
14513
|
-
}), M = computed(() => !!A.value ||
|
14519
|
+
}), M = computed(() => !!A.value || b.value || !!s.isCreating.value || !!s.isUpdating.value || !!s.isCopying.value || !!s.isDeleting.value), w = computed(() => !!A.value || b.value || !!s.isCreating.value || !!s.isUpdating.value || !!s.isCopying.value || !!s.isDeleting.value || D.total === 0), I = computed(() => {
|
14514
14520
|
var K;
|
14515
14521
|
return !!((K = r == null ? void 0 : r.KgTable) != null && K.expandedRowRender);
|
14516
14522
|
}), R = computed(() => {
|
@@ -14525,18 +14531,18 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14525
14531
|
selectedRowKeys: $,
|
14526
14532
|
preserveSelectedRowKeys: !1,
|
14527
14533
|
getCheckboxProps: (K) => {
|
14528
|
-
var
|
14534
|
+
var G;
|
14529
14535
|
return {
|
14530
|
-
disabled: !!A.value || !!s.isCreating.value || !!s.isUpdating.value || !!s.isCopying.value || !!s.isDeleting.value || !!((
|
14536
|
+
disabled: !!A.value || !!s.isCreating.value || !!s.isUpdating.value || !!s.isCopying.value || !!s.isDeleting.value || !!((G = C.value) != null && G.call(C, K))
|
14531
14537
|
};
|
14532
14538
|
},
|
14533
14539
|
onSelect: (K) => Y(K),
|
14534
14540
|
onChange: (K) => o.isMultiSelect.value && x(K)
|
14535
14541
|
};
|
14536
14542
|
}), O = computed(() => {
|
14537
|
-
var
|
14543
|
+
var G;
|
14538
14544
|
let K = "kg-table";
|
14539
|
-
switch (((
|
14545
|
+
switch (((G = s.varGridConfig.value) == null ? void 0 : G.show_bottom_border_flg) === 1 && (K += " kg-table--bottom-border"), !o.isShowBottomLeft.value && !o.isShowBottomRight.value && (K += " kg-table--no-bottom"), l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (s.isCreating.value || s.isUpdating.value || s.isCopying.value || s.isDeleting.value) && (K += " kg-table--submitting"), o.store.getRowHeight(s.formID)) {
|
14540
14546
|
case "L":
|
14541
14547
|
K += " kg-table--row-l";
|
14542
14548
|
break;
|
@@ -14549,9 +14555,9 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14549
14555
|
}
|
14550
14556
|
return K;
|
14551
14557
|
}), F = computed(() => {
|
14552
|
-
var
|
14558
|
+
var G;
|
14553
14559
|
let K = "kg-table-bottom";
|
14554
|
-
return ((
|
14560
|
+
return ((G = s.varGridConfig.value) == null ? void 0 : G.show_bottom_border_flg) === 1 && (K += " kg-table-bottom--border"), K;
|
14555
14561
|
}), $ = (ae = o.store.getSelectedRowKeys(s.formID)) != null ? ae : ref([]), D = reactive({
|
14556
14562
|
pageIndex: 1,
|
14557
14563
|
pageSize: 10,
|
@@ -14563,14 +14569,14 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14563
14569
|
});
|
14564
14570
|
watch(o.pageSizeOptions, (K) => {
|
14565
14571
|
K.length > 0 && !K.includes(D.pageSize) && (D.pageSize = o.pageSizeOption.value);
|
14566
|
-
}), watch([T, o.isReadAutomatically, i.isReady], ([K,
|
14567
|
-
K &&
|
14572
|
+
}), watch([T, o.isReadAutomatically, i.isReady], ([K, G, Q]) => {
|
14573
|
+
K && G && Q && !o.store.getIsRetrieved(s.formID) && L({
|
14568
14574
|
isSearchFirstPage: !0
|
14569
14575
|
});
|
14570
14576
|
}, {
|
14571
14577
|
immediate: !0
|
14572
|
-
}), watch(s.isCreating, (K,
|
14573
|
-
K === !0 ? N() : K === !1 &&
|
14578
|
+
}), watch(s.isCreating, (K, G) => {
|
14579
|
+
K === !0 ? N() : K === !1 && G === !0 && B();
|
14574
14580
|
}), onUnmounted(() => {
|
14575
14581
|
o.store.dispose(s.formID);
|
14576
14582
|
});
|
@@ -14583,13 +14589,13 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14583
14589
|
}
|
14584
14590
|
}
|
14585
14591
|
function B() {
|
14586
|
-
const K = m.value.find((
|
14592
|
+
const K = m.value.find((G) => G[o.id.value] === KG_TABLE_TEMP_ID);
|
14587
14593
|
K && (o.store.setDatas(s.formID, without$1(m.value, K)), o.store.setSelectedRows(s.formID, []));
|
14588
14594
|
}
|
14589
|
-
function H(K,
|
14595
|
+
function H(K, G) {
|
14590
14596
|
var Q;
|
14591
14597
|
if (!(!!A.value || !!s.isCreating.value || !!s.isUpdating.value || !!s.isCopying.value || !!s.isDeleting.value) && !!P.value) {
|
14592
|
-
if (!
|
14598
|
+
if (!G) {
|
14593
14599
|
o.store.setSelectedRows(s.formID, []);
|
14594
14600
|
return;
|
14595
14601
|
}
|
@@ -14599,13 +14605,13 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14599
14605
|
case 0:
|
14600
14606
|
break;
|
14601
14607
|
case 1:
|
14602
|
-
o.store.setSelectedRows(s.formID, [
|
14608
|
+
o.store.setSelectedRows(s.formID, [G]);
|
14603
14609
|
break;
|
14604
14610
|
}
|
14605
14611
|
break;
|
14606
14612
|
case 2:
|
14607
14613
|
o.store.emit(s.formID, "rowDoubleClick", {
|
14608
|
-
row:
|
14614
|
+
row: G
|
14609
14615
|
});
|
14610
14616
|
break;
|
14611
14617
|
}
|
@@ -14615,84 +14621,89 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14615
14621
|
KgLogger.debug(`${s.formID} | KgTable | retrieve() | \u6267\u884C\u5F00\u59CB.`, {
|
14616
14622
|
param: K
|
14617
14623
|
});
|
14618
|
-
const
|
14619
|
-
z && (setTimeout(() =>
|
14624
|
+
const G = watch(o.isReady, (z) => {
|
14625
|
+
z && (setTimeout(() => G()), Q());
|
14620
14626
|
}, {
|
14621
14627
|
immediate: !0
|
14622
14628
|
});
|
14623
14629
|
async function Q() {
|
14624
|
-
var z, ee,
|
14630
|
+
var z, ee, he, ge, fe;
|
14625
14631
|
if (KgLogger.debug(`${s.formID} | KgTable | retrieve() | retrieveDatas() | \u6267\u884C\u5F00\u59CB.`), !T.value) {
|
14626
|
-
KgLogger.error(`${s.formID} | KgTable | retrieve() | retrieveDatas() | \u67E5\u8BE2\u6309\u94AE\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3
|
14632
|
+
KgLogger.error(`${s.formID} | KgTable | retrieve() | retrieveDatas() | \u67E5\u8BE2\u6309\u94AE\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3.`, {
|
14627
14633
|
VarButton: s.varButtonSearch.value
|
14628
14634
|
});
|
14629
14635
|
return;
|
14630
14636
|
}
|
14631
14637
|
K.isSearchFirstPage && (D.pageIndex = 1), o.store.setIsRetrieving(s.formID, !0);
|
14632
14638
|
try {
|
14633
|
-
const
|
14639
|
+
const le = KgUtil.parseParams(k.value, o.profileFormID.value, t), ve = ref({});
|
14634
14640
|
if (!await o.store.emit(s.formID, "beforeRetrieve", {
|
14635
|
-
params:
|
14636
|
-
response:
|
14641
|
+
params: le,
|
14642
|
+
response: ve
|
14637
14643
|
})) {
|
14638
|
-
const
|
14639
|
-
ue.value = await httpClient().request({
|
14644
|
+
const pe = ((ee = (z = n.option.value.KgSearch) == null ? void 0 : z.dynamicQuery) == null ? void 0 : ee.on) === !0 && ((he = s.currentVarProfileMaster.value) == null ? void 0 : he.dyn_flg) === 1, U = await httpClient().request({
|
14640
14645
|
method: "GET",
|
14641
14646
|
url: T.value,
|
14642
|
-
params:
|
14647
|
+
params: le,
|
14643
14648
|
headers: {
|
14644
|
-
[KG_HTTP_HEADERS.
|
14645
|
-
[KG_HTTP_HEADERS.
|
14649
|
+
[KG_HTTP_HEADERS.KG_DYNAMIC_QUERY]: pe,
|
14650
|
+
[KG_HTTP_HEADERS.KG_QUERY_SQL]: KgUtil.getQuerySql(k.value, o.profileFormID.value, t)
|
14646
14651
|
}
|
14647
14652
|
}, {
|
14653
|
+
isReturnNativeResponse: !0,
|
14648
14654
|
successMessageMode: "none"
|
14649
|
-
})
|
14650
|
-
|
14651
|
-
|
14655
|
+
});
|
14656
|
+
if (!U.data)
|
14657
|
+
throw message.error(n.t("kg.KgTable.request-fail-no-data")), new Error(n.t("kg.KgTable.request-fail-no-data"));
|
14658
|
+
if (![0, 200].includes((ge = U.data.code) != null ? ge : -1) || !U.data.success)
|
14659
|
+
throw message.error(U.data.message || n.t("kg.KgTable.request-fail-error")), new Error(U.data.message || n.t("kg.KgTable.request-fail-error"));
|
14660
|
+
pe && U.headers[KG_HTTP_HEADERS.KG_DYNAMIC_QUERY] !== "true" && message.warning(n.t("kg.KgTable.dynamic-query-is-off-in-server")), ve.value = U.data.result, KgLogger.debug(`${s.formID} | KgTable | retrieve() | retrieveDatas() | \u67E5\u8BE2\u6210\u529F.`, {
|
14661
|
+
params: le,
|
14662
|
+
response: ve.value
|
14652
14663
|
});
|
14653
14664
|
}
|
14654
14665
|
const {
|
14655
|
-
datas:
|
14666
|
+
datas: be,
|
14656
14667
|
total: Se
|
14657
|
-
} =
|
14668
|
+
} = E(ve);
|
14658
14669
|
await o.store.emit(s.formID, "beforeSetDatas", {
|
14659
|
-
datas:
|
14670
|
+
datas: be,
|
14660
14671
|
total: Se,
|
14661
|
-
setDatas(
|
14662
|
-
o.store.setDatas(s.formID,
|
14672
|
+
setDatas(pe) {
|
14673
|
+
o.store.setDatas(s.formID, pe);
|
14663
14674
|
}
|
14664
|
-
}), d.value = {}, o.store.setDatas(s.formID,
|
14675
|
+
}), d.value = {}, o.store.setDatas(s.formID, be.value), D.total = Se.value;
|
14665
14676
|
const Ce = cloneDeep($.value);
|
14666
|
-
H(), c.value = [], await nextTick(), K.isPreserveSelectedRows ? o.store.setSelectedRows(s.formID, Ce.map((
|
14667
|
-
var
|
14668
|
-
return (
|
14669
|
-
}).filter((
|
14670
|
-
page:
|
14671
|
-
datas:
|
14672
|
-
setDatas(
|
14673
|
-
o.store.setDatas(s.formID,
|
14677
|
+
H(), c.value = [], await nextTick(), K.isPreserveSelectedRows ? o.store.setSelectedRows(s.formID, Ce.map((pe) => {
|
14678
|
+
var U;
|
14679
|
+
return (U = be.value) == null ? void 0 : U.find((W) => W[o.id.value] === pe);
|
14680
|
+
}).filter((pe) => !!pe)) : ((fe = s.varGridConfig.value) == null ? void 0 : fe.check_first_row_after_retrieve) === 1 && be.value.length > 0 && o.store.setSelectedRows(s.formID, [be.value[0]]), await o.store.emit(s.formID, "retrieve", {
|
14681
|
+
page: ve.value,
|
14682
|
+
datas: be,
|
14683
|
+
setDatas(pe) {
|
14684
|
+
o.store.setDatas(s.formID, pe);
|
14674
14685
|
}
|
14675
14686
|
}), o.store.setIsRetrieved(s.formID, !0);
|
14676
|
-
} catch (
|
14677
|
-
throw
|
14687
|
+
} catch (le) {
|
14688
|
+
throw le;
|
14678
14689
|
} finally {
|
14679
14690
|
o.store.setIsRetrieving(s.formID, !1);
|
14680
14691
|
}
|
14681
14692
|
}
|
14682
14693
|
}
|
14683
14694
|
function x(K) {
|
14684
|
-
o.store.setSelectedRows(s.formID, K.map((
|
14695
|
+
o.store.setSelectedRows(s.formID, K.map((G) => {
|
14685
14696
|
var Q;
|
14686
|
-
return (Q = m.value) == null ? void 0 : Q.find((z) => z[o.id.value] ===
|
14687
|
-
}).filter((
|
14697
|
+
return (Q = m.value) == null ? void 0 : Q.find((z) => z[o.id.value] === G);
|
14698
|
+
}).filter((G) => !!G));
|
14688
14699
|
}
|
14689
14700
|
function Y(K) {
|
14690
|
-
var
|
14701
|
+
var G, Q;
|
14691
14702
|
switch (o.isMultiSelect.value) {
|
14692
14703
|
case !0:
|
14693
14704
|
{
|
14694
14705
|
const z = K[o.id.value];
|
14695
|
-
$.value.includes(z) ? $.value = without$1($.value, z) : $.value = [...(
|
14706
|
+
$.value.includes(z) ? $.value = without$1($.value, z) : $.value = [...(G = $.value) != null ? G : [], z];
|
14696
14707
|
}
|
14697
14708
|
break;
|
14698
14709
|
case !1:
|
@@ -14704,13 +14715,13 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14704
14715
|
}
|
14705
14716
|
o.store.setSelectedRows(s.formID, $.value.map((z) => {
|
14706
14717
|
var ee;
|
14707
|
-
return (ee = m.value) == null ? void 0 : ee.find((
|
14718
|
+
return (ee = m.value) == null ? void 0 : ee.find((he) => he[o.id.value] === z);
|
14708
14719
|
}).filter((z) => !!z));
|
14709
14720
|
}
|
14710
|
-
function q(K,
|
14711
|
-
|
14721
|
+
function q(K, G) {
|
14722
|
+
G.width = K, s.store.setVarGridDetailWidth(s.formID, G.dataIndex, K);
|
14712
14723
|
}
|
14713
|
-
async function X(K,
|
14724
|
+
async function X(K, G, Q, z) {
|
14714
14725
|
switch (z.action) {
|
14715
14726
|
case "sort": {
|
14716
14727
|
g.value = Q, g.value.order || (g.value.field = void 0), await nextTick(), L({
|
@@ -14719,12 +14730,12 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14719
14730
|
break;
|
14720
14731
|
}
|
14721
14732
|
case "filter":
|
14722
|
-
d.value =
|
14733
|
+
d.value = G;
|
14723
14734
|
}
|
14724
14735
|
}
|
14725
|
-
function J(K,
|
14736
|
+
function J(K, G) {
|
14726
14737
|
var z;
|
14727
|
-
const Q =
|
14738
|
+
const Q = G[o.id.value];
|
14728
14739
|
switch ((z = s.varGridConfig.value) == null ? void 0 : z.expand_accordion_flg) {
|
14729
14740
|
case 0:
|
14730
14741
|
K ? c.value = uniq([...c.value, Q]) : c.value = without$1(c.value, Q);
|
@@ -14734,14 +14745,14 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14734
14745
|
break;
|
14735
14746
|
}
|
14736
14747
|
}
|
14737
|
-
function te(K,
|
14738
|
-
|
14748
|
+
function te(K, G) {
|
14749
|
+
G !== D.pageSize ? (D.pageIndex = 1, D.pageSize = G) : D.pageIndex = K, L();
|
14739
14750
|
}
|
14740
|
-
function
|
14751
|
+
function ie({
|
14741
14752
|
title: K,
|
14742
|
-
column:
|
14753
|
+
column: G
|
14743
14754
|
}) {
|
14744
|
-
switch (
|
14755
|
+
switch (G.dataIndex) {
|
14745
14756
|
case "index":
|
14746
14757
|
return createVNode(KgTableSetting, {
|
14747
14758
|
kgDisabled: A.value
|
@@ -14752,7 +14763,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14752
14763
|
}, [K]);
|
14753
14764
|
}
|
14754
14765
|
}
|
14755
|
-
function
|
14766
|
+
function me() {
|
14756
14767
|
var K;
|
14757
14768
|
return (K = r == null ? void 0 : r.KgTable) != null && K["summary.bodyCell"] ? createVNode(TableSummary, {
|
14758
14769
|
fixed: "bottom"
|
@@ -14762,18 +14773,18 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14762
14773
|
index: 0
|
14763
14774
|
}, null), R.value && createVNode(TableSummary.Cell, {
|
14764
14775
|
index: I.value ? 1 : 0
|
14765
|
-
}, null), u.value.map((
|
14766
|
-
const z = String(
|
14767
|
-
let
|
14768
|
-
return I.value && R.value ?
|
14769
|
-
index:
|
14770
|
-
align:
|
14776
|
+
}, null), u.value.map((G, Q) => {
|
14777
|
+
const z = String(G.dataIndex), ee = z ? s.store.getVarGridDetail(s.formID, z) : null, he = (() => ["left", "center", "right"].includes((ee == null ? void 0 : ee.align) || "") ? ee == null ? void 0 : ee.align : "left")();
|
14778
|
+
let ge = Q;
|
14779
|
+
return I.value && R.value ? ge += 2 : (I.value || R.value) && (ge += 1), createVNode(TableSummary.Cell, {
|
14780
|
+
index: ge,
|
14781
|
+
align: he
|
14771
14782
|
}, {
|
14772
14783
|
default: () => {
|
14773
|
-
var
|
14774
|
-
return [(
|
14775
|
-
column:
|
14776
|
-
index:
|
14784
|
+
var fe, le;
|
14785
|
+
return [(le = (fe = r == null ? void 0 : r.KgTable) == null ? void 0 : fe["summary.bodyCell"]) == null ? void 0 : le.call(fe, {
|
14786
|
+
column: G,
|
14787
|
+
index: ge,
|
14777
14788
|
varGridDetail: ee
|
14778
14789
|
})];
|
14779
14790
|
}
|
@@ -14782,11 +14793,11 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14782
14793
|
})]
|
14783
14794
|
}) : null;
|
14784
14795
|
}
|
14785
|
-
function
|
14796
|
+
function de() {
|
14786
14797
|
return !o.isReadAutomatically.value && !o.store.getIsRetrieved(s.formID) ? n.t("kg.KgTable.emptyText") : n.t("kg.emptyText");
|
14787
14798
|
}
|
14788
14799
|
return () => {
|
14789
|
-
var K,
|
14800
|
+
var K, G, Q;
|
14790
14801
|
return createVNode("div", {
|
14791
14802
|
class: O.value,
|
14792
14803
|
"kg-frm_id": s.formID,
|
@@ -14795,16 +14806,16 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14795
14806
|
class: "kg-flex-table",
|
14796
14807
|
size: "small",
|
14797
14808
|
scroll: {
|
14798
|
-
x:
|
14809
|
+
x: y.value,
|
14799
14810
|
y: "auto"
|
14800
14811
|
},
|
14801
14812
|
pagination: !1,
|
14802
14813
|
showSorterTooltip: !1,
|
14803
14814
|
columns: u.value,
|
14804
14815
|
dataSource: m.value,
|
14805
|
-
loading:
|
14816
|
+
loading: b.value,
|
14806
14817
|
rowKey: o.id.value,
|
14807
|
-
rowClassName: (
|
14818
|
+
rowClassName: (G = (K = a == null ? void 0 : a.value) == null ? void 0 : K.KgTable) == null ? void 0 : G.kgRowClassName,
|
14808
14819
|
expandColumnWidth: 28,
|
14809
14820
|
expandedRowKeys: c.value,
|
14810
14821
|
rowSelection: P.value,
|
@@ -14815,11 +14826,11 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14815
14826
|
onChange: X,
|
14816
14827
|
onExpand: J
|
14817
14828
|
}, {
|
14818
|
-
headerCell:
|
14829
|
+
headerCell: ie,
|
14819
14830
|
bodyCell: p,
|
14820
|
-
emptyText:
|
14831
|
+
emptyText: de,
|
14821
14832
|
expandedRowRender: (Q = r == null ? void 0 : r.KgTable) == null ? void 0 : Q.expandedRowRender,
|
14822
|
-
summary:
|
14833
|
+
summary: me
|
14823
14834
|
}), (o.isShowBottomLeft.value || o.isShowBottomRight.value) && createVNode("div", {
|
14824
14835
|
class: F.value
|
14825
14836
|
}, [createVNode("div", {
|
@@ -14876,8 +14887,8 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14876
14887
|
attrs: t
|
14877
14888
|
}) {
|
14878
14889
|
const r = useKg(), a = useKgVar(), n = useKgTable(), s = computed(() => a.store.getVarButton(a.formID, e.kgVarName)), i = computed(() => {
|
14879
|
-
var u, d, g,
|
14880
|
-
return a.isCreating.value || a.isUpdating.value || a.isDeleting.value || n.isRetrieving.value || ((u = s.value) == null ? void 0 : u.dis_no_select_flg) === 1 && ((g = (d = n.selectedRows.value) == null ? void 0 : d.length) != null ? g : 0) === 0 || ((
|
14890
|
+
var u, d, g, y, b, _, p, m;
|
14891
|
+
return a.isCreating.value || a.isUpdating.value || a.isDeleting.value || n.isRetrieving.value || ((u = s.value) == null ? void 0 : u.dis_no_select_flg) === 1 && ((g = (d = n.selectedRows.value) == null ? void 0 : d.length) != null ? g : 0) === 0 || ((y = s.value) == null ? void 0 : y.dis_mult_select_flg) === 1 && ((_ = (b = n.selectedRows.value) == null ? void 0 : b.length) != null ? _ : 0) > 1 || ((p = s.value) == null ? void 0 : p.permission_type) === 2 && !r.p((m = s.value) == null ? void 0 : m.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
14881
14892
|
});
|
14882
14893
|
async function o() {
|
14883
14894
|
e.onKgClick && await e.onKgClick() || a.store.setIsCopying(a.formID, !0);
|
@@ -14893,7 +14904,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14893
14904
|
return e.kgText ? e.kgText : r.t("kg.copy");
|
14894
14905
|
}
|
14895
14906
|
return () => {
|
14896
|
-
var u, d, g,
|
14907
|
+
var u, d, g, y;
|
14897
14908
|
return createVNode(Button, {
|
14898
14909
|
type: "primary",
|
14899
14910
|
disabled: i.value,
|
@@ -14903,7 +14914,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
14903
14914
|
"kg-id": (u = s.value) == null ? void 0 : u.id,
|
14904
14915
|
"kg-frm_id": (d = s.value) == null ? void 0 : d.frm_id,
|
14905
14916
|
"kg-var_nam": (g = s.value) == null ? void 0 : g.var_nam,
|
14906
|
-
"kg-cmd": (
|
14917
|
+
"kg-cmd": (y = s.value) == null ? void 0 : y.cmd
|
14907
14918
|
}, {
|
14908
14919
|
default: () => [l(), c()]
|
14909
14920
|
});
|
@@ -15081,10 +15092,10 @@ const KgButtonCreate = defineComponent({
|
|
15081
15092
|
async function g() {
|
15082
15093
|
e.onKgClick && await e.onKgClick() || s.store.setIsCreating(s.formID, !0);
|
15083
15094
|
}
|
15084
|
-
function
|
15095
|
+
function y() {
|
15085
15096
|
i.store.emit(s.formID, "submitSave", {});
|
15086
15097
|
}
|
15087
|
-
function
|
15098
|
+
function b() {
|
15088
15099
|
i.store.emit(s.formID, "submitCancel", {});
|
15089
15100
|
}
|
15090
15101
|
function _() {
|
@@ -15112,10 +15123,10 @@ const KgButtonCreate = defineComponent({
|
|
15112
15123
|
default: () => [_(), p()]
|
15113
15124
|
});
|
15114
15125
|
}
|
15115
|
-
function
|
15126
|
+
function E() {
|
15116
15127
|
return l.displayType.value !== KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE || !s.isCreating.value ? null : createVNode(Fragment, null, [createVNode(Button, {
|
15117
15128
|
type: "primary",
|
15118
|
-
onClick:
|
15129
|
+
onClick: y,
|
15119
15130
|
disabled: !!s.isCreatingRequesting.value
|
15120
15131
|
}, {
|
15121
15132
|
default: () => [s.isCreatingRequesting.value ? createVNode(LoadingOutlined$1, null, null) : createVNode(CheckOutlined$1, null, null), n.t("kg.save")]
|
@@ -15123,20 +15134,20 @@ const KgButtonCreate = defineComponent({
|
|
15123
15134
|
type: "primary",
|
15124
15135
|
ghost: !d.value,
|
15125
15136
|
disabled: d.value,
|
15126
|
-
onClick:
|
15137
|
+
onClick: b
|
15127
15138
|
}, {
|
15128
15139
|
default: () => [createVNode(StopOutlined$1, null, null), n.t("kg.cancel")]
|
15129
15140
|
})]);
|
15130
15141
|
}
|
15131
|
-
return () => createVNode(Fragment, null, [m(),
|
15142
|
+
return () => createVNode(Fragment, null, [m(), E()]);
|
15132
15143
|
}
|
15133
15144
|
}), KgButtonDelete = defineComponent({
|
15134
15145
|
name: "KgButtonDelete",
|
15135
15146
|
props: getProps$f(),
|
15136
15147
|
setup(e) {
|
15137
15148
|
const t = useKg(), r = useKgVar(), a = useKgTable(), n = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), s = computed(() => {
|
15138
|
-
var c, u, d, g,
|
15139
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || a.isRetrieving.value || ((c = n.value) == null ? void 0 : c.dis_no_select_flg) === 1 && ((d = (u = a.selectedRows.value) == null ? void 0 : u.length) != null ? d : 0) === 0 || ((g = n.value) == null ? void 0 : g.dis_mult_select_flg) === 1 && ((
|
15149
|
+
var c, u, d, g, y, b, _, p;
|
15150
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || a.isRetrieving.value || ((c = n.value) == null ? void 0 : c.dis_no_select_flg) === 1 && ((d = (u = a.selectedRows.value) == null ? void 0 : u.length) != null ? d : 0) === 0 || ((g = n.value) == null ? void 0 : g.dis_mult_select_flg) === 1 && ((b = (y = a.selectedRows.value) == null ? void 0 : y.length) != null ? b : 0) > 1 || ((_ = n.value) == null ? void 0 : _.permission_type) === 2 && !t.p((p = n.value) == null ? void 0 : p.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
15140
15151
|
});
|
15141
15152
|
async function i() {
|
15142
15153
|
e.onKgClick && await e.onKgClick() || r.store.setIsDeleting(r.formID, !0);
|
@@ -15173,31 +15184,31 @@ const KgButtonCreate = defineComponent({
|
|
15173
15184
|
props: getProps$f(),
|
15174
15185
|
setup(e) {
|
15175
15186
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgTable(), s = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), i = computed(() => {
|
15176
|
-
var
|
15177
|
-
return s.value ? (_ = (
|
15187
|
+
var b, _;
|
15188
|
+
return s.value ? (_ = (b = s.value) == null ? void 0 : b.cmd) != null ? _ : "" : null;
|
15178
15189
|
}), o = computed(() => {
|
15179
|
-
var
|
15180
|
-
return (_ = (
|
15190
|
+
var b, _;
|
15191
|
+
return (_ = (b = s.value) == null ? void 0 : b.cmd_method) != null ? _ : "GET";
|
15181
15192
|
}), l = computed(() => {
|
15182
|
-
var _, p, m,
|
15183
|
-
let
|
15193
|
+
var _, p, m, E, T, k;
|
15194
|
+
let b = {
|
15184
15195
|
pageNo: 1,
|
15185
15196
|
pageSize: 9999999,
|
15186
15197
|
...(_ = a.model.value) != null ? _ : {}
|
15187
15198
|
};
|
15188
|
-
return s.value && (
|
15189
|
-
...
|
15199
|
+
return s.value && (b = {
|
15200
|
+
...b,
|
15190
15201
|
...KgVarUtil.parseCommandParameter((m = (p = s.value) == null ? void 0 : p.cmd_prm) != null ? m : "")
|
15191
|
-
}), (
|
15192
|
-
...
|
15202
|
+
}), (E = r.varGridConfig.value) != null && E.cmd_prm && (b = {
|
15203
|
+
...b,
|
15193
15204
|
...KgVarUtil.parseCommandParameter((T = r.varGridConfig.value.cmd_prm) != null ? T : "")
|
15194
|
-
}), ((k = r.varGridConfig.value) == null ? void 0 : k.convert_sort_field_to_under_score_flg) === 1 &&
|
15205
|
+
}), ((k = r.varGridConfig.value) == null ? void 0 : k.convert_sort_field_to_under_score_flg) === 1 && b.column && (b.column = snakeCase$1(b.column)), b;
|
15195
15206
|
}), c = computed(() => {
|
15196
|
-
var
|
15197
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((
|
15207
|
+
var b, _, p, m, E, T, k, A;
|
15208
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((b = s.value) == null ? void 0 : b.dis_no_select_flg) === 1 && ((p = (_ = n.selectedRows.value) == null ? void 0 : _.length) != null ? p : 0) === 0 || ((m = s.value) == null ? void 0 : m.dis_mult_select_flg) === 1 && ((T = (E = n.selectedRows.value) == null ? void 0 : E.length) != null ? T : 0) > 1 || ((k = s.value) == null ? void 0 : k.permission_type) === 2 && !t.p((A = s.value) == null ? void 0 : A.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
15198
15209
|
}), u = ref(!1);
|
15199
15210
|
async function d() {
|
15200
|
-
var
|
15211
|
+
var b, _;
|
15201
15212
|
if (!(e.onKgClick && await e.onKgClick())) {
|
15202
15213
|
if (!i.value) {
|
15203
15214
|
KgLogger.error("[KgButton] '\u5BFC\u51FA\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -15215,7 +15226,7 @@ const KgButtonCreate = defineComponent({
|
|
15215
15226
|
}, {
|
15216
15227
|
joinParamsToUrl: !0,
|
15217
15228
|
isTransformResponse: !1
|
15218
|
-
}), m = (
|
15229
|
+
}), m = (b = s.value) == null ? void 0 : b.export_excel_filename;
|
15219
15230
|
KgUtil.downloadFile(p, `${m ? r.t(m).value : t.t("kg.export")}.${(_ = s.value) == null ? void 0 : _.export_excel_suffix}`);
|
15220
15231
|
} catch (p) {
|
15221
15232
|
throw p;
|
@@ -15231,23 +15242,23 @@ const KgButtonCreate = defineComponent({
|
|
15231
15242
|
icon: e.kgIcon
|
15232
15243
|
}, null)]) : createVNode(UploadOutlined$1, null, null);
|
15233
15244
|
}
|
15234
|
-
function
|
15245
|
+
function y() {
|
15235
15246
|
return e.kgText ? e.kgText : t.t("kg.export");
|
15236
15247
|
}
|
15237
15248
|
return () => {
|
15238
|
-
var
|
15249
|
+
var b, _, p, m;
|
15239
15250
|
return createVNode(Button, {
|
15240
15251
|
type: "primary",
|
15241
15252
|
disabled: c.value,
|
15242
15253
|
ghost: !e.kgPrimary && !c.value,
|
15243
15254
|
loading: u.value,
|
15244
15255
|
onClick: d,
|
15245
|
-
"kg-id": (
|
15256
|
+
"kg-id": (b = s.value) == null ? void 0 : b.id,
|
15246
15257
|
"kg-frm_id": (_ = s.value) == null ? void 0 : _.frm_id,
|
15247
15258
|
"kg-var_nam": (p = s.value) == null ? void 0 : p.var_nam,
|
15248
15259
|
"kg-cmd": (m = s.value) == null ? void 0 : m.cmd
|
15249
15260
|
}, {
|
15250
|
-
default: () => [g(),
|
15261
|
+
default: () => [g(), y()]
|
15251
15262
|
});
|
15252
15263
|
};
|
15253
15264
|
}
|
@@ -15266,19 +15277,19 @@ const KgButtonCreate = defineComponent({
|
|
15266
15277
|
var p, m;
|
15267
15278
|
return (m = (p = o.value) == null ? void 0 : p.cmd_method) != null ? m : "POST";
|
15268
15279
|
}), u = computed(() => {
|
15269
|
-
var m,
|
15280
|
+
var m, E, T;
|
15270
15281
|
let p = {
|
15271
15282
|
...(m = s.model.value) != null ? m : {}
|
15272
15283
|
};
|
15273
15284
|
return o.value && (p = {
|
15274
15285
|
...p,
|
15275
|
-
...KgVarUtil.parseCommandParameter((T = (
|
15286
|
+
...KgVarUtil.parseCommandParameter((T = (E = o.value) == null ? void 0 : E.cmd_prm) != null ? T : "")
|
15276
15287
|
}), p;
|
15277
15288
|
}), d = computed(() => {
|
15278
|
-
var p, m,
|
15279
|
-
return n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value || i.isRetrieving.value || ((p = o.value) == null ? void 0 : p.dis_no_select_flg) === 1 && ((
|
15289
|
+
var p, m, E, T, k, A, C, M;
|
15290
|
+
return n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value || i.isRetrieving.value || ((p = o.value) == null ? void 0 : p.dis_no_select_flg) === 1 && ((E = (m = i.selectedRows.value) == null ? void 0 : m.length) != null ? E : 0) === 0 || ((T = o.value) == null ? void 0 : T.dis_mult_select_flg) === 1 && ((A = (k = i.selectedRows.value) == null ? void 0 : k.length) != null ? A : 0) > 1 || ((C = o.value) == null ? void 0 : C.permission_type) === 2 && !a.p((M = o.value) == null ? void 0 : M.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
15280
15291
|
}), g = ref(!1);
|
15281
|
-
async function
|
15292
|
+
async function y(p) {
|
15282
15293
|
if (!l.value)
|
15283
15294
|
return KgLogger.error("[KgButton] '\u5BFC\u5165\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
15284
15295
|
VarButton: o.value
|
@@ -15287,7 +15298,7 @@ const KgButtonCreate = defineComponent({
|
|
15287
15298
|
try {
|
15288
15299
|
const m = new FormData();
|
15289
15300
|
m.append("file", p);
|
15290
|
-
const
|
15301
|
+
const E = await httpClient().axiosInstance.request({
|
15291
15302
|
method: c.value,
|
15292
15303
|
baseURL: window._CONFIG.domianURL,
|
15293
15304
|
url: l.value,
|
@@ -15308,7 +15319,7 @@ const KgButtonCreate = defineComponent({
|
|
15308
15319
|
}
|
15309
15320
|
return !1;
|
15310
15321
|
}
|
15311
|
-
function
|
15322
|
+
function b() {
|
15312
15323
|
return g.value ? createVNode(LoadingOutlined$1, null, null) : e.kgIcon ? createVNode("span", {
|
15313
15324
|
class: "anticon"
|
15314
15325
|
}, [createVNode(Icon, {
|
@@ -15321,11 +15332,11 @@ const KgButtonCreate = defineComponent({
|
|
15321
15332
|
return () => createVNode(Upload, {
|
15322
15333
|
name: "file",
|
15323
15334
|
showUploadList: !1,
|
15324
|
-
beforeUpload:
|
15335
|
+
beforeUpload: y,
|
15325
15336
|
disabled: g.value
|
15326
15337
|
}, {
|
15327
15338
|
default: () => {
|
15328
|
-
var p, m,
|
15339
|
+
var p, m, E, T;
|
15329
15340
|
return [createVNode(Button, {
|
15330
15341
|
class: r.class,
|
15331
15342
|
type: "primary",
|
@@ -15334,10 +15345,10 @@ const KgButtonCreate = defineComponent({
|
|
15334
15345
|
loading: g.value,
|
15335
15346
|
"kg-id": (p = o.value) == null ? void 0 : p.id,
|
15336
15347
|
"kg-frm_id": (m = o.value) == null ? void 0 : m.frm_id,
|
15337
|
-
"kg-var_nam": (
|
15348
|
+
"kg-var_nam": (E = o.value) == null ? void 0 : E.var_nam,
|
15338
15349
|
"kg-cmd": (T = o.value) == null ? void 0 : T.cmd
|
15339
15350
|
}, {
|
15340
|
-
default: () => [
|
15351
|
+
default: () => [b(), _()]
|
15341
15352
|
})];
|
15342
15353
|
}
|
15343
15354
|
});
|
@@ -15347,29 +15358,29 @@ const KgButtonCreate = defineComponent({
|
|
15347
15358
|
props: getProps$f(),
|
15348
15359
|
setup(e) {
|
15349
15360
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgTable(), s = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), i = computed(() => {
|
15350
|
-
var
|
15351
|
-
return s.value ? (_ = (
|
15361
|
+
var b, _;
|
15362
|
+
return s.value ? (_ = (b = s.value) == null ? void 0 : b.cmd) != null ? _ : "" : null;
|
15352
15363
|
}), o = computed(() => {
|
15353
|
-
var
|
15354
|
-
return (_ = (
|
15364
|
+
var b, _;
|
15365
|
+
return (_ = (b = s.value) == null ? void 0 : b.cmd_method) != null ? _ : "GET";
|
15355
15366
|
}), l = computed(() => {
|
15356
|
-
var _, p, m,
|
15357
|
-
let
|
15367
|
+
var _, p, m, E, T;
|
15368
|
+
let b = {
|
15358
15369
|
...(_ = a.model.value) != null ? _ : {}
|
15359
15370
|
};
|
15360
|
-
return s.value && (
|
15361
|
-
...
|
15371
|
+
return s.value && (b = {
|
15372
|
+
...b,
|
15362
15373
|
...KgVarUtil.parseCommandParameter((m = (p = s.value) == null ? void 0 : p.cmd_prm) != null ? m : "")
|
15363
|
-
}), (
|
15364
|
-
...
|
15374
|
+
}), (E = r.varGridConfig.value) != null && E.cmd_prm && (b = {
|
15375
|
+
...b,
|
15365
15376
|
...KgVarUtil.parseCommandParameter((T = r.varGridConfig.value.cmd_prm) != null ? T : "")
|
15366
|
-
}),
|
15377
|
+
}), b;
|
15367
15378
|
}), c = computed(() => {
|
15368
|
-
var
|
15369
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((
|
15379
|
+
var b, _, p, m, E, T, k, A;
|
15380
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((b = s.value) == null ? void 0 : b.dis_no_select_flg) === 1 && ((p = (_ = n.selectedRows.value) == null ? void 0 : _.length) != null ? p : 0) === 0 || ((m = s.value) == null ? void 0 : m.dis_mult_select_flg) === 1 && ((T = (E = n.selectedRows.value) == null ? void 0 : E.length) != null ? T : 0) > 1 || ((k = s.value) == null ? void 0 : k.permission_type) === 2 && !t.p((A = s.value) == null ? void 0 : A.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
15370
15381
|
}), u = ref(!1);
|
15371
15382
|
async function d() {
|
15372
|
-
var
|
15383
|
+
var b, _;
|
15373
15384
|
if (!i.value) {
|
15374
15385
|
KgLogger.error("[KgButton] '\u4E0B\u8F7D\u5BFC\u5165\u6A21\u677F\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
15375
15386
|
VarButton: s.value
|
@@ -15386,7 +15397,7 @@ const KgButtonCreate = defineComponent({
|
|
15386
15397
|
}, {
|
15387
15398
|
joinParamsToUrl: !0,
|
15388
15399
|
isTransformResponse: !1
|
15389
|
-
}), m = (
|
15400
|
+
}), m = (b = s.value) == null ? void 0 : b.export_excel_filename;
|
15390
15401
|
KgUtil.downloadFile(p, `${m ? r.t(m).value : t.t("kg.importTemplate")}.${(_ = s.value) == null ? void 0 : _.export_excel_suffix}`);
|
15391
15402
|
} catch (p) {
|
15392
15403
|
throw p;
|
@@ -15401,23 +15412,23 @@ const KgButtonCreate = defineComponent({
|
|
15401
15412
|
icon: e.kgIcon
|
15402
15413
|
}, null)]) : createVNode(UploadOutlined$1, null, null);
|
15403
15414
|
}
|
15404
|
-
function
|
15415
|
+
function y() {
|
15405
15416
|
return e.kgText ? e.kgText : t.t("kg.downloadImportTemplate");
|
15406
15417
|
}
|
15407
15418
|
return () => {
|
15408
|
-
var
|
15419
|
+
var b, _, p, m;
|
15409
15420
|
return createVNode(Button, {
|
15410
15421
|
type: "primary",
|
15411
15422
|
disabled: c.value,
|
15412
15423
|
ghost: !e.kgPrimary && !c.value,
|
15413
15424
|
loading: u.value,
|
15414
15425
|
onClick: d,
|
15415
|
-
"kg-id": (
|
15426
|
+
"kg-id": (b = s.value) == null ? void 0 : b.id,
|
15416
15427
|
"kg-frm_id": (_ = s.value) == null ? void 0 : _.frm_id,
|
15417
15428
|
"kg-var_nam": (p = s.value) == null ? void 0 : p.var_nam,
|
15418
15429
|
"kg-cmd": (m = s.value) == null ? void 0 : m.cmd
|
15419
15430
|
}, {
|
15420
|
-
default: () => [g(),
|
15431
|
+
default: () => [g(), y()]
|
15421
15432
|
});
|
15422
15433
|
};
|
15423
15434
|
}
|
@@ -15426,14 +15437,14 @@ const KgButtonCreate = defineComponent({
|
|
15426
15437
|
props: getProps$f(),
|
15427
15438
|
setup(e) {
|
15428
15439
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgButton(), s = useKgTable(), i = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), o = computed(() => {
|
15429
|
-
var d, g,
|
15430
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || s.isRetrieving.value || ((d = i.value) == null ? void 0 : d.dis_no_select_flg) === 1 && ((
|
15440
|
+
var d, g, y, b, _, p, m, E;
|
15441
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || s.isRetrieving.value || ((d = i.value) == null ? void 0 : d.dis_no_select_flg) === 1 && ((y = (g = s.selectedRows.value) == null ? void 0 : g.length) != null ? y : 0) === 0 || ((b = i.value) == null ? void 0 : b.dis_mult_select_flg) === 1 && ((p = (_ = s.selectedRows.value) == null ? void 0 : _.length) != null ? p : 0) > 1 || ((m = i.value) == null ? void 0 : m.permission_type) === 2 && !t.p((E = i.value) == null ? void 0 : E.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
15431
15442
|
});
|
15432
15443
|
async function l() {
|
15433
|
-
var
|
15444
|
+
var b, _, p;
|
15434
15445
|
if (e.onKgClick && await e.onKgClick())
|
15435
15446
|
return;
|
15436
|
-
const d = (
|
15447
|
+
const d = (b = e.kgButton) == null ? void 0 : b.cmd;
|
15437
15448
|
if (!d) {
|
15438
15449
|
KgLogger.error("[KgButton] \u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
15439
15450
|
VarButton: e.kgButton
|
@@ -15441,13 +15452,13 @@ const KgButtonCreate = defineComponent({
|
|
15441
15452
|
return;
|
15442
15453
|
}
|
15443
15454
|
let g = null;
|
15444
|
-
const
|
15445
|
-
var
|
15455
|
+
const y = async () => {
|
15456
|
+
var E, T, k, A, C, M;
|
15446
15457
|
g == null || g.showLoading(), r.store.setIsOtherRequesting(r.formID, !0);
|
15447
15458
|
const m = s.selectedRows.value;
|
15448
15459
|
try {
|
15449
15460
|
const w = await httpClient().request({
|
15450
|
-
method: (T = (
|
15461
|
+
method: (T = (E = e.kgButton) == null ? void 0 : E.cmd_method) != null ? T : "POST",
|
15451
15462
|
url: d,
|
15452
15463
|
params: KgVarUtil.parseCommandParameter((A = (k = e.kgButton) == null ? void 0 : k.cmd_prm) != null ? A : ""),
|
15453
15464
|
data: m != null ? m : []
|
@@ -15480,11 +15491,11 @@ const KgButtonCreate = defineComponent({
|
|
15480
15491
|
if (((_ = e.kgButton) == null ? void 0 : _.show_modal_flg) === 1) {
|
15481
15492
|
const m = KgUtil.tryParseJSON((p = e.kgButton) == null ? void 0 : p.modal_props);
|
15482
15493
|
typeof m.content == "string" && (m.content = r.t(m.content).value), g = KgUtil.confirm({
|
15483
|
-
onOk: () =>
|
15494
|
+
onOk: () => y(),
|
15484
15495
|
...m
|
15485
15496
|
});
|
15486
15497
|
} else
|
15487
|
-
|
15498
|
+
y();
|
15488
15499
|
}
|
15489
15500
|
function c() {
|
15490
15501
|
return e.kgIcon ? createVNode("span", {
|
@@ -15497,7 +15508,7 @@ const KgButtonCreate = defineComponent({
|
|
15497
15508
|
return e.kgText ? e.kgText : t.t("kg.button");
|
15498
15509
|
}
|
15499
15510
|
return () => {
|
15500
|
-
var d, g,
|
15511
|
+
var d, g, y, b;
|
15501
15512
|
return createVNode(Button, {
|
15502
15513
|
type: "primary",
|
15503
15514
|
disabled: o.value,
|
@@ -15506,8 +15517,8 @@ const KgButtonCreate = defineComponent({
|
|
15506
15517
|
onClick: l,
|
15507
15518
|
"kg-id": (d = i.value) == null ? void 0 : d.id,
|
15508
15519
|
"kg-frm_id": (g = i.value) == null ? void 0 : g.frm_id,
|
15509
|
-
"kg-var_nam": (
|
15510
|
-
"kg-cmd": (
|
15520
|
+
"kg-var_nam": (y = i.value) == null ? void 0 : y.var_nam,
|
15521
|
+
"kg-cmd": (b = i.value) == null ? void 0 : b.cmd
|
15511
15522
|
}, {
|
15512
15523
|
default: () => [c(), u()]
|
15513
15524
|
});
|
@@ -15581,10 +15592,10 @@ const KgButtonCreate = defineComponent({
|
|
15581
15592
|
row: i.selectedRow.value
|
15582
15593
|
}) || s.store.setIsUpdating(s.formID, !0);
|
15583
15594
|
}
|
15584
|
-
function
|
15595
|
+
function y() {
|
15585
15596
|
o.store.emit(s.formID, "submitSave", {});
|
15586
15597
|
}
|
15587
|
-
function
|
15598
|
+
function b() {
|
15588
15599
|
o.store.emit(s.formID, "submitCancel", {});
|
15589
15600
|
}
|
15590
15601
|
function _() {
|
@@ -15613,10 +15624,10 @@ const KgButtonCreate = defineComponent({
|
|
15613
15624
|
default: () => [_(), p()]
|
15614
15625
|
});
|
15615
15626
|
}
|
15616
|
-
function
|
15627
|
+
function E() {
|
15617
15628
|
return l.displayType.value !== KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE || !s.isUpdating.value ? null : createVNode(Fragment, null, [createVNode(Button, {
|
15618
15629
|
type: "primary",
|
15619
|
-
onClick:
|
15630
|
+
onClick: y,
|
15620
15631
|
disabled: !!s.isUpdatingRequesting.value
|
15621
15632
|
}, {
|
15622
15633
|
default: () => [s.isUpdatingRequesting.value ? createVNode(LoadingOutlined$1, null, null) : createVNode(CheckOutlined$1, null, null), n.t("kg.save")]
|
@@ -15624,12 +15635,12 @@ const KgButtonCreate = defineComponent({
|
|
15624
15635
|
type: "primary",
|
15625
15636
|
ghost: !d.value,
|
15626
15637
|
disabled: d.value,
|
15627
|
-
onClick:
|
15638
|
+
onClick: b
|
15628
15639
|
}, {
|
15629
15640
|
default: () => [createVNode(StopOutlined$1, null, null), n.t("kg.cancel")]
|
15630
15641
|
})]);
|
15631
15642
|
}
|
15632
|
-
return () => createVNode(Fragment, null, [m(),
|
15643
|
+
return () => createVNode(Fragment, null, [m(), E()]);
|
15633
15644
|
}
|
15634
15645
|
}), KgButton_Item = "";
|
15635
15646
|
function _isSlot$4(e) {
|
@@ -15703,8 +15714,8 @@ const getProps$e = () => ({
|
|
15703
15714
|
}
|
15704
15715
|
function l(_) {
|
15705
15716
|
return computed(() => {
|
15706
|
-
var m,
|
15707
|
-
const p = ((
|
15717
|
+
var m, E;
|
15718
|
+
const p = ((E = (m = r == null ? void 0 : r.value) == null ? void 0 : m.KgButton) == null ? void 0 : E.kgDisabled) || e.kgDisabled;
|
15708
15719
|
if (p) {
|
15709
15720
|
const T = p(_);
|
15710
15721
|
if (!isNil(T))
|
@@ -15732,9 +15743,9 @@ const getProps$e = () => ({
|
|
15732
15743
|
return null;
|
15733
15744
|
switch ((p = n.varGridConfig.value) == null ? void 0 : p.button_display_type) {
|
15734
15745
|
case KG_BUTTON_DISPLAY_TYPE.SELECT:
|
15735
|
-
return E();
|
15736
|
-
default:
|
15737
15746
|
return b();
|
15747
|
+
default:
|
15748
|
+
return y();
|
15738
15749
|
}
|
15739
15750
|
}
|
15740
15751
|
function g(_) {
|
@@ -15750,11 +15761,11 @@ const getProps$e = () => ({
|
|
15750
15761
|
onKgClick: () => o(_)
|
15751
15762
|
}, null);
|
15752
15763
|
}
|
15753
|
-
function
|
15764
|
+
function y() {
|
15754
15765
|
var _;
|
15755
15766
|
return (_ = n.varButtons.value) == null ? void 0 : _.filter((p) => p.typ !== KG_BUTTON_TYPE.SEARCH).map((p) => g(p));
|
15756
15767
|
}
|
15757
|
-
function
|
15768
|
+
function b() {
|
15758
15769
|
return createVNode(Dropdown, {
|
15759
15770
|
trigger: "click",
|
15760
15771
|
overlayClassName: "kg-button-dropdown"
|
@@ -15768,9 +15779,9 @@ const getProps$e = () => ({
|
|
15768
15779
|
default: () => {
|
15769
15780
|
var _, p;
|
15770
15781
|
return [(p = (_ = n.varButtons.value) == null ? void 0 : _.filter((m) => m.typ !== KG_BUTTON_TYPE.SEARCH)) == null ? void 0 : p.filter((m) => !(m.permission_type !== 2 && !a.p(m.permission_code))).map((m) => {
|
15771
|
-
let
|
15772
|
-
return createVNode(Menu.Item, null, _isSlot$3(
|
15773
|
-
default: () => [
|
15782
|
+
let E;
|
15783
|
+
return createVNode(Menu.Item, null, _isSlot$3(E = g(m)) ? E : {
|
15784
|
+
default: () => [E]
|
15774
15785
|
});
|
15775
15786
|
})];
|
15776
15787
|
}
|
@@ -16263,12 +16274,12 @@ function _useDragRow(e, t, r) {
|
|
16263
16274
|
const g = document.createElement("span");
|
16264
16275
|
g.setAttribute("id", "__kg_search_config_fields_drag_image__");
|
16265
16276
|
const {
|
16266
|
-
width:
|
16267
|
-
height:
|
16277
|
+
width: y,
|
16278
|
+
height: b
|
16268
16279
|
} = u.parentElement.getBoundingClientRect();
|
16269
|
-
|
16280
|
+
y && b && (g.style.width = `${y + 2}px`, g.style.height = `${b + 2}px`), (p = d.dataTransfer) == null || p.setDragImage(g, -10, (b + 2) / 2);
|
16270
16281
|
const _ = await toCanvas(u.parentElement);
|
16271
|
-
g.appendChild(_), document.body.appendChild(g), (m = d.dataTransfer) == null || m.setDragImage(g, -10, (
|
16282
|
+
g.appendChild(_), document.body.appendChild(g), (m = d.dataTransfer) == null || m.setDragImage(g, -10, (b + 2) / 2);
|
16272
16283
|
}, u.addEventListener("dragstart", u.__kg__dragstart__), u.__kg__dragend__ = (d) => {
|
16273
16284
|
u.classList.remove("dragging"), u.parentElement.classList.remove("dragging");
|
16274
16285
|
const g = document.querySelector("#__kg_search_config_fields_drag_image__");
|
@@ -16281,19 +16292,19 @@ function _useDragRow(e, t, r) {
|
|
16281
16292
|
if (a = filter(document.querySelectorAll(`tr[kg-host-frm_id="${e}"]`), () => !0), a)
|
16282
16293
|
for (let u of a)
|
16283
16294
|
u.__kg__dragover__ = (d) => {
|
16284
|
-
var g,
|
16285
|
-
d.preventDefault(), u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((
|
16295
|
+
var g, y;
|
16296
|
+
d.preventDefault(), u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((y = s == null ? void 0 : s.rowIndex) != null ? y : -1) && u.classList.add("dragover", "dragover-left");
|
16286
16297
|
}, u.addEventListener("dragover", u.__kg__dragover__, !1), u.__kg__dragenter__ = (d) => {
|
16287
|
-
var g,
|
16288
|
-
u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((
|
16298
|
+
var g, y;
|
16299
|
+
u.rowIndex > ((g = s == null ? void 0 : s.rowIndex) != null ? g : -1) ? u.classList.add("dragover", "dragover-right") : u.rowIndex < ((y = s == null ? void 0 : s.rowIndex) != null ? y : -1) && u.classList.add("dragover", "dragover-left");
|
16289
16300
|
}, u.addEventListener("dragenter", u.__kg__dragenter__), u.__kg__dragleave__ = (d) => {
|
16290
16301
|
u.classList.remove("dragover", "dragover-right", "dragover-left");
|
16291
16302
|
}, u.addEventListener("dragleave", u.__kg__dragleave__), u.__kg__drop__ = (d) => {
|
16292
16303
|
d.preventDefault(), KgUtil.showLoading();
|
16293
16304
|
const g = document.querySelector("#__kg_search_config_fields_drag_image__");
|
16294
16305
|
g && document.body.removeChild(g), u.classList.remove("dragover", "dragover-right", "dragover-left");
|
16295
|
-
const
|
16296
|
-
|
16306
|
+
const y = s == null ? void 0 : s.getAttribute("kg-var_nam"), b = u.getAttribute("kg-var_nam");
|
16307
|
+
y !== b && l(y, b);
|
16297
16308
|
}, u.addEventListener("drop", u.__kg__drop__);
|
16298
16309
|
}
|
16299
16310
|
function o() {
|
@@ -16312,12 +16323,12 @@ function _useDragRow(e, t, r) {
|
|
16312
16323
|
}
|
16313
16324
|
function l(u, d) {
|
16314
16325
|
setTimeout(() => {
|
16315
|
-
const g = t.value.findIndex((p) => p.var_nam === u),
|
16316
|
-
if (g === -1 ||
|
16326
|
+
const g = t.value.findIndex((p) => p.var_nam === u), y = t.value.findIndex((p) => p.var_nam === d);
|
16327
|
+
if (g === -1 || y === -1)
|
16317
16328
|
return;
|
16318
|
-
const
|
16329
|
+
const b = t.value.find((p) => p.var_nam === u), _ = [];
|
16319
16330
|
t.value.forEach((p, m) => {
|
16320
|
-
g >
|
16331
|
+
g > y ? m < y ? _.push(p) : m === y ? (_.push(b), _.push(p)) : m > y && m !== g && _.push(p) : g < y && (m < g ? _.push(p) : m === g || (m === y ? (_.push(p), _.push(b)) : _.push(p)));
|
16321
16332
|
}), _.forEach((p, m) => {
|
16322
16333
|
p.srtseq = m + 1;
|
16323
16334
|
}), t.value = _, nextTick().finally(() => {
|
@@ -16351,7 +16362,7 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16351
16362
|
isCreating: _,
|
16352
16363
|
isUpdating: p,
|
16353
16364
|
isCopying: m,
|
16354
|
-
row:
|
16365
|
+
row: E,
|
16355
16366
|
model: T
|
16356
16367
|
}) => {
|
16357
16368
|
var A, C, M, w, I;
|
@@ -16363,12 +16374,12 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16363
16374
|
}
|
16364
16375
|
case p:
|
16365
16376
|
case m: {
|
16366
|
-
if (
|
16377
|
+
if (E != null && E.id)
|
16367
16378
|
try {
|
16368
16379
|
o.store.setIsLoading(a.formID, !0);
|
16369
16380
|
const R = await QueryByID({
|
16370
16381
|
params: {
|
16371
|
-
id:
|
16382
|
+
id: E.id
|
16372
16383
|
}
|
16373
16384
|
});
|
16374
16385
|
l.value = l.value.map((O) => {
|
@@ -16402,9 +16413,9 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16402
16413
|
}), o.onBeforeOk(async ({
|
16403
16414
|
model: _
|
16404
16415
|
}) => {
|
16405
|
-
var m,
|
16416
|
+
var m, E;
|
16406
16417
|
const p = _.value;
|
16407
|
-
return p.frm_id = r.formID, p.varProfileDetails = (
|
16418
|
+
return p.frm_id = r.formID, p.varProfileDetails = (E = (m = l.value) == null ? void 0 : m.filter((T) => c.value.includes(T.id))) != null ? E : [], !1;
|
16408
16419
|
}), o.onOk(async () => (r.store.retrieve(r.formID), !1)), i.onUpdateBeforeClick(({
|
16409
16420
|
row: _
|
16410
16421
|
}) => (_ == null ? void 0 : _.cust_lvl) === KG_CUSTOM_LEVEL.L0 ? new Promise((p) => {
|
@@ -16460,7 +16471,7 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16460
16471
|
direction: _,
|
16461
16472
|
filteredItems: p,
|
16462
16473
|
selectedKeys: m,
|
16463
|
-
disabled:
|
16474
|
+
disabled: E,
|
16464
16475
|
onItemSelectAll: T,
|
16465
16476
|
onItemSelect: k
|
16466
16477
|
}) => {
|
@@ -16482,12 +16493,12 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16482
16493
|
dataSource: A,
|
16483
16494
|
customRow: (w) => {
|
16484
16495
|
let I = {
|
16485
|
-
onClick: (R) =>
|
16496
|
+
onClick: (R) => b(R, w, _, m)
|
16486
16497
|
};
|
16487
16498
|
return _ === "right" && (I["kg-host-frm_id"] = r.formID, I["kg-var_nam"] = w.var_nam), I;
|
16488
16499
|
},
|
16489
|
-
rowSelection:
|
16490
|
-
disabled:
|
16500
|
+
rowSelection: y({
|
16501
|
+
disabled: E,
|
16491
16502
|
selectedKeys: m,
|
16492
16503
|
onItemSelectAll: T,
|
16493
16504
|
onItemSelect: k
|
@@ -16497,11 +16508,11 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16497
16508
|
})
|
16498
16509
|
}
|
16499
16510
|
}
|
16500
|
-
}),
|
16511
|
+
}), y = ({
|
16501
16512
|
disabled: _,
|
16502
16513
|
selectedKeys: p,
|
16503
16514
|
onItemSelectAll: m,
|
16504
|
-
onItemSelect:
|
16515
|
+
onItemSelect: E
|
16505
16516
|
}) => ({
|
16506
16517
|
getCheckboxProps: (T) => ({
|
16507
16518
|
disabled: _ || T.disabled
|
@@ -16515,16 +16526,16 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
16515
16526
|
onSelect({
|
16516
16527
|
key: T
|
16517
16528
|
}, k) {
|
16518
|
-
|
16529
|
+
E(T, k);
|
16519
16530
|
},
|
16520
16531
|
selectedRowKeys: p,
|
16521
16532
|
columnWidth: 32
|
16522
16533
|
});
|
16523
|
-
function
|
16534
|
+
function b(_, p, m, E) {
|
16524
16535
|
if (!KgDomUtil.isNotClickable(_.target, ["ant-input"]))
|
16525
|
-
switch (
|
16536
|
+
switch (E.length = 0, _.detail) {
|
16526
16537
|
case 1:
|
16527
|
-
|
16538
|
+
E[0] = p.id;
|
16528
16539
|
break;
|
16529
16540
|
case 2:
|
16530
16541
|
switch (m) {
|
@@ -16633,11 +16644,11 @@ function _useLayoutHeaderResizeObserver() {
|
|
16633
16644
|
}
|
16634
16645
|
function _useCommon() {
|
16635
16646
|
const e = inject(DI_KG_VAR__KG_PROPS, null), t = useKgVar(), r = computed(() => t.store.getVarProfileConfig(t.formID)), a = computed(() => t.store.getFormLevel(t.formID)), n = ref(!0), s = computed(() => {
|
16636
|
-
var g,
|
16647
|
+
var g, y, b;
|
16637
16648
|
if (!n.value || a.value > 0)
|
16638
16649
|
return !1;
|
16639
|
-
const d = (
|
16640
|
-
return d !== void 0 ? d : ((
|
16650
|
+
const d = (y = (g = e == null ? void 0 : e.value) == null ? void 0 : g.KgSearch) == null ? void 0 : y.kgHeaderTeleport;
|
16651
|
+
return d !== void 0 ? d : ((b = r.value) == null ? void 0 : b.header_teleport_flg) !== 0;
|
16641
16652
|
}), i = computed(() => {
|
16642
16653
|
var d;
|
16643
16654
|
return ((d = r.value) == null ? void 0 : d.vis_flg) === 1;
|
@@ -16667,23 +16678,23 @@ function _useFormModel(e, t, r) {
|
|
16667
16678
|
let l, c;
|
16668
16679
|
const u = ref({}), d = ref({});
|
16669
16680
|
async function g() {
|
16670
|
-
var
|
16671
|
-
((
|
16672
|
-
var p, m,
|
16673
|
-
const _ = (p =
|
16674
|
-
u.value[_] = KgVarUtil.transformFormItemValue(n.formID, _, a, (m =
|
16675
|
-
}), r.value.kgHeight = o.value, s.store.setModel(n.formID, u.value), s.store.setOperatorModel(n.formID, d.value), i.value ? (c == null || c(), c = watch(t, async (
|
16676
|
-
|
16681
|
+
var y;
|
16682
|
+
((y = n.currentVarProfileDetails.value) != null ? y : []).forEach((b) => {
|
16683
|
+
var p, m, E;
|
16684
|
+
const _ = (p = b.var_nam) != null ? p : "";
|
16685
|
+
u.value[_] = KgVarUtil.transformFormItemValue(n.formID, _, a, (m = b.dft_val) != null ? m : void 0, "R"), d.value[_] = KgVarUtil.transformFormItemDynamicQueryOperator(n.formID, _, (E = b.dft_dyn_op) != null ? E : void 0);
|
16686
|
+
}), r.value.kgHeight = o.value, s.store.setModel(n.formID, u.value), s.store.setOperatorModel(n.formID, d.value), i.value ? (c == null || c(), c = watch(t, async (b) => {
|
16687
|
+
b && (await s.store.emit(n.formID, "ready", {}), s.store.setIsReady(n.formID, !0));
|
16677
16688
|
}, {
|
16678
16689
|
immediate: !0
|
16679
|
-
})) : (l == null || l(), l = watch(e, async (
|
16680
|
-
|
16690
|
+
})) : (l == null || l(), l = watch(e, async (b) => {
|
16691
|
+
b && (await s.store.emit(n.formID, "ready", {}), s.store.setIsReady(n.formID, !0));
|
16681
16692
|
}, {
|
16682
16693
|
immediate: !0
|
16683
16694
|
}));
|
16684
16695
|
}
|
16685
|
-
return watch(n.currentVarProfileDetails, async (
|
16686
|
-
if (u.value = {}, d.value = {}, isNil(
|
16696
|
+
return watch(n.currentVarProfileDetails, async (y) => {
|
16697
|
+
if (u.value = {}, d.value = {}, isNil(y)) {
|
16687
16698
|
s.store.setModel(n.formID, u.value), s.store.setOperatorModel(n.formID, d.value);
|
16688
16699
|
return;
|
16689
16700
|
}
|
@@ -16714,17 +16725,17 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16714
16725
|
defaultHeight: u,
|
16715
16726
|
maxHeight: d,
|
16716
16727
|
minHeight: g
|
16717
|
-
} = _useCommon(),
|
16728
|
+
} = _useCommon(), y = ref(null), b = ref(null), _ = ref({
|
16718
16729
|
kgHeight: g.value
|
16719
16730
|
});
|
16720
16731
|
_useLayoutHeaderResizeObserver();
|
16721
|
-
const p = _useFormModel(
|
16732
|
+
const p = _useFormModel(y, b, _), m = computed(() => {
|
16722
16733
|
var L, x, Y, q;
|
16723
16734
|
if (!isNil((x = (L = r == null ? void 0 : r.value) == null ? void 0 : L.KgSearch) == null ? void 0 : x.kgDisabled))
|
16724
16735
|
return (q = (Y = r == null ? void 0 : r.value) == null ? void 0 : Y.KgSearch) == null ? void 0 : q.kgDisabled;
|
16725
16736
|
if (!isNil(e.kgDisabled))
|
16726
16737
|
return e.kgDisabled;
|
16727
|
-
}),
|
16738
|
+
}), E = computed(() => {
|
16728
16739
|
var L, x;
|
16729
16740
|
return !!(m.value || i.isRetrieving.value || ((L = n.varButtonSearch.value) == null ? void 0 : L.permission_type) === 2 && !a.p((x = n.varButtonSearch.value) == null ? void 0 : x.permission_code) || n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value);
|
16730
16741
|
}), T = computed(() => !!(m.value || i.isRetrieving.value || n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value)), k = computed(() => !!(m.value || i.isRetrieving.value)), A = ref({
|
@@ -16761,7 +16772,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16761
16772
|
KgLogger.debug(`${n.formID} | KgSearch | onSearch() | \u6B63\u5728\u521B\u5EFA/\u66F4\u65B0/\u590D\u5236/\u5220\u9664.`);
|
16762
16773
|
return;
|
16763
16774
|
}
|
16764
|
-
o.value ? (KgLogger.debug(`${n.formID} | KgSearch | onSearch() | \u663E\u793A\u67E5\u8BE2\u6761\u4EF6\u7EC4\u4EF6.`),
|
16775
|
+
o.value ? (KgLogger.debug(`${n.formID} | KgSearch | onSearch() | \u663E\u793A\u67E5\u8BE2\u6761\u4EF6\u7EC4\u4EF6.`), b.value && b.value.validate().then(async () => {
|
16765
16776
|
await s.store.emit(n.formID, "search", L);
|
16766
16777
|
}).catch((q) => {
|
16767
16778
|
KgLogger.debug(`${n.formID} | KgSearch | onSearch() | \u8868\u5355\u9A8C\u8BC1\u5931\u8D25.`, {
|
@@ -16771,7 +16782,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16771
16782
|
}
|
16772
16783
|
s.store.setSearchFn(n.formID, O);
|
16773
16784
|
async function F() {
|
16774
|
-
p.initFormModel(), o.value ?
|
16785
|
+
p.initFormModel(), o.value ? b.value && b.value.validate().then(async () => {
|
16775
16786
|
await s.store.emit(n.formID, "reset", {});
|
16776
16787
|
}).catch((L) => {
|
16777
16788
|
KgLogger.debug(`${n.formID} | KgSearch | onReset() | \u8868\u5355\u9A8C\u8BC1\u5931\u8D25.`, {
|
@@ -16834,8 +16845,8 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16834
16845
|
var L, x, Y, q, X;
|
16835
16846
|
return createVNode(Fragment, null, [V(), !(((L = n.varButtonSearch.value) == null ? void 0 : L.permission_type) !== 2 && !a.p((x = n.varButtonSearch.value) == null ? void 0 : x.permission_code)) && createVNode(Button, {
|
16836
16847
|
type: "primary",
|
16837
|
-
ghost: !
|
16838
|
-
disabled:
|
16848
|
+
ghost: !E.value,
|
16849
|
+
disabled: E.value,
|
16839
16850
|
onClick: F,
|
16840
16851
|
class: "kg-search-btn-reset"
|
16841
16852
|
}, {
|
@@ -16858,7 +16869,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16858
16869
|
default: () => {
|
16859
16870
|
var L;
|
16860
16871
|
return [createVNode(KgForm, {
|
16861
|
-
ref:
|
16872
|
+
ref: b,
|
16862
16873
|
model: (L = s.model.value) != null ? L : {}
|
16863
16874
|
}, {
|
16864
16875
|
default: () => [createVNode(Row, {
|
@@ -16884,7 +16895,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
16884
16895
|
C.value ? _.value.kgHeight = u.value : _.value.kgHeight = g.value;
|
16885
16896
|
}
|
16886
16897
|
return () => createVNode(KgResizable, {
|
16887
|
-
ref:
|
16898
|
+
ref: y,
|
16888
16899
|
kgHeight: _.value.kgHeight,
|
16889
16900
|
"onUpdate:kgHeight": (L) => _.value.kgHeight = L,
|
16890
16901
|
kgMinHeight: g.value,
|
@@ -16978,9 +16989,9 @@ function useMagicKeys(e = {}) {
|
|
16978
16989
|
for (const _ of u)
|
16979
16990
|
d(_, !1);
|
16980
16991
|
}
|
16981
|
-
function
|
16982
|
-
var m,
|
16983
|
-
const T = (m = _.key) == null ? void 0 : m.toLowerCase(), k = (
|
16992
|
+
function y(_, p) {
|
16993
|
+
var m, E;
|
16994
|
+
const T = (m = _.key) == null ? void 0 : m.toLowerCase(), k = (E = _.code) == null ? void 0 : E.toLowerCase(), A = [k, T].filter(Boolean);
|
16984
16995
|
k && (p ? i.add(_.code) : i.delete(_.code));
|
16985
16996
|
for (const C of A)
|
16986
16997
|
u.add(C), d(C, p);
|
@@ -16988,22 +16999,22 @@ function useMagicKeys(e = {}) {
|
|
16988
16999
|
i.delete(C), d(C, !1);
|
16989
17000
|
}), c.clear()) : typeof _.getModifierState == "function" && _.getModifierState("Meta") && p && [...i, ...A].forEach((C) => c.add(C));
|
16990
17001
|
}
|
16991
|
-
r && (useEventListener(r, "keydown", (_) => (
|
16992
|
-
const
|
17002
|
+
r && (useEventListener(r, "keydown", (_) => (y(_, !0), s(_)), { passive: n }), useEventListener(r, "keyup", (_) => (y(_, !1), s(_)), { passive: n }), useEventListener("blur", g, { passive: !0 }), useEventListener("focus", g, { passive: !0 }));
|
17003
|
+
const b = new Proxy(l, {
|
16993
17004
|
get(_, p, m) {
|
16994
17005
|
if (typeof p != "string")
|
16995
17006
|
return Reflect.get(_, p, m);
|
16996
17007
|
if (p = p.toLowerCase(), p in a && (p = a[p]), !(p in l))
|
16997
17008
|
if (/[+_-]/.test(p)) {
|
16998
17009
|
const T = p.split(/[+_-]/g).map((k) => k.trim());
|
16999
|
-
l[p] = computed(() => T.every((k) => unref(
|
17010
|
+
l[p] = computed(() => T.every((k) => unref(b[k])));
|
17000
17011
|
} else
|
17001
17012
|
l[p] = ref(!1);
|
17002
|
-
const
|
17003
|
-
return t ? unref(
|
17013
|
+
const E = Reflect.get(_, p, m);
|
17014
|
+
return t ? unref(E) : E;
|
17004
17015
|
}
|
17005
17016
|
});
|
17006
|
-
return
|
17017
|
+
return b;
|
17007
17018
|
}
|
17008
17019
|
var SwipeDirection;
|
17009
17020
|
(function(e) {
|
@@ -17386,21 +17397,21 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
17386
17397
|
hideSelectAll: !0,
|
17387
17398
|
selectedRowKeys: d,
|
17388
17399
|
onSelect: (O) => M(O)
|
17389
|
-
}),
|
17400
|
+
}), y = ref({
|
17390
17401
|
visible: !1
|
17391
|
-
}),
|
17402
|
+
}), b = computed(() => !!(unref(u) || unref(n) || unref(s) || unref(i))), _ = computed(() => {
|
17392
17403
|
var O;
|
17393
17404
|
return !!u.value || ((O = a.getSelectedVarCatalog) == null ? void 0 : O.cust_lvl) === KG_CUSTOM_LEVEL.L0;
|
17394
17405
|
}), p = computed(() => !!(!unref(u) || unref(n) || unref(s))), m = computed(() => !!(!unref(a.getSelectedVarCatalog) || unref(n)));
|
17395
17406
|
watch(() => a.getSelectedVar, (O) => {
|
17396
|
-
O ?
|
17407
|
+
O ? E() : (u.value = null, c.value = [], a.setSelectedVarCatalog(null));
|
17397
17408
|
}, {
|
17398
17409
|
immediate: !0
|
17399
17410
|
}), watch(() => a.getSelectedVarCatalog, async (O) => {
|
17400
17411
|
var F, $;
|
17401
17412
|
l.value.var_text = (F = O == null ? void 0 : O.var_text) != null ? F : "", ($ = o.value) == null || $.clearValidate();
|
17402
17413
|
});
|
17403
|
-
async function
|
17414
|
+
async function E(O = !1) {
|
17404
17415
|
var F, $, D;
|
17405
17416
|
n.value = !0;
|
17406
17417
|
try {
|
@@ -17444,19 +17455,19 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
17444
17455
|
successMessageMode: "none"
|
17445
17456
|
}), message.success({
|
17446
17457
|
content: t.t("kg.KgVarConfig.createSuccess")
|
17447
|
-
}), await
|
17458
|
+
}), await E()) : (await Edit({
|
17448
17459
|
data: D
|
17449
17460
|
}, {
|
17450
17461
|
successMessageMode: "none"
|
17451
17462
|
}), message.success({
|
17452
17463
|
content: t.t("kg.KgVarConfig.saveSuccess")
|
17453
|
-
}), await
|
17464
|
+
}), await E(!0)) : (await Add({
|
17454
17465
|
data: D
|
17455
17466
|
}, {
|
17456
17467
|
successMessageMode: "none"
|
17457
17468
|
}), message.success({
|
17458
17469
|
content: t.t("kg.KgVarConfig.createSuccess")
|
17459
|
-
}), await
|
17470
|
+
}), await E()), r.retrieve(e == null ? void 0 : e.value);
|
17460
17471
|
} catch (D) {
|
17461
17472
|
KgUtil.throwIfNotFormError(D);
|
17462
17473
|
} finally {
|
@@ -17497,7 +17508,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
17497
17508
|
joinParamsToUrl: !0
|
17498
17509
|
}), message.success({
|
17499
17510
|
content: t.t("kg.KgVarConfig.deleteSuccess")
|
17500
|
-
}), r.retrieve(e == null ? void 0 : e.value), await
|
17511
|
+
}), r.retrieve(e == null ? void 0 : e.value), await E();
|
17501
17512
|
}
|
17502
17513
|
});
|
17503
17514
|
}
|
@@ -17511,14 +17522,14 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
17511
17522
|
}) : (a.setSelectedVarCatalog(unref(O)), d.value = [O.id]));
|
17512
17523
|
}
|
17513
17524
|
function w() {
|
17514
|
-
|
17525
|
+
y.value.visible = !0;
|
17515
17526
|
}
|
17516
17527
|
function I() {
|
17517
17528
|
return createVNode("div", {
|
17518
17529
|
class: "buttons"
|
17519
17530
|
}, [createVNode(Button, {
|
17520
17531
|
onClick: w,
|
17521
|
-
disabled:
|
17532
|
+
disabled: b.value,
|
17522
17533
|
type: "primary"
|
17523
17534
|
}, {
|
17524
17535
|
default: () => [createVNode(PlusOutlined$1, null, null), t.t("common.create")]
|
@@ -17597,8 +17608,8 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
17597
17608
|
onClick: () => M(O)
|
17598
17609
|
})
|
17599
17610
|
}, null), R(), createVNode(KgVarConfigModalVarCreateModal, {
|
17600
|
-
visible:
|
17601
|
-
"onUpdate:visible": (O) =>
|
17611
|
+
visible: y.value.visible,
|
17612
|
+
"onUpdate:visible": (O) => y.value.visible = O,
|
17602
17613
|
onKgOk: k
|
17603
17614
|
}, null)]);
|
17604
17615
|
}
|
@@ -17940,16 +17951,16 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
17940
17951
|
return ((k = r.option.value.KgWarehouse) == null ? void 0 : k.on) !== !1;
|
17941
17952
|
});
|
17942
17953
|
watch(a.visible, (k) => {
|
17943
|
-
!g.value || (k ?
|
17954
|
+
!g.value || (k ? b() : _());
|
17944
17955
|
}, {
|
17945
17956
|
immediate: !0
|
17946
17957
|
}), onMounted(() => {
|
17947
17958
|
a.store.emit("mounted");
|
17948
17959
|
});
|
17949
|
-
function
|
17960
|
+
function y() {
|
17950
17961
|
!g.value || a.store.setVisible(!0);
|
17951
17962
|
}
|
17952
|
-
function
|
17963
|
+
function b() {
|
17953
17964
|
o.value = a.warehouse.value, m();
|
17954
17965
|
}
|
17955
17966
|
function _() {
|
@@ -17987,7 +17998,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
17987
17998
|
l.value = !1;
|
17988
17999
|
}
|
17989
18000
|
}
|
17990
|
-
function
|
18001
|
+
function E(k, A) {
|
17991
18002
|
var C;
|
17992
18003
|
switch (k.detail) {
|
17993
18004
|
case 1:
|
@@ -18050,7 +18061,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
18050
18061
|
var A;
|
18051
18062
|
return {
|
18052
18063
|
class: k.id === ((A = o.value) == null ? void 0 : A.id) ? "selected" : "",
|
18053
|
-
onClick: (C) =>
|
18064
|
+
onClick: (C) => E(C, k)
|
18054
18065
|
};
|
18055
18066
|
}
|
18056
18067
|
}, null)]
|
@@ -18058,7 +18069,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
18058
18069
|
}
|
18059
18070
|
return () => createVNode("div", {
|
18060
18071
|
class: n.value,
|
18061
|
-
onClick:
|
18072
|
+
onClick: y
|
18062
18073
|
}, [T()]);
|
18063
18074
|
}
|
18064
18075
|
});
|
@@ -18170,6 +18181,7 @@ export {
|
|
18170
18181
|
VarVariableConfig,
|
18171
18182
|
VarVariableInput,
|
18172
18183
|
WhDTO,
|
18184
|
+
__KG__RESPONSE__,
|
18173
18185
|
createKgWarehouseGuard,
|
18174
18186
|
httpClient,
|
18175
18187
|
keys$1 as keys,
|