@kengic/vue 0.9.6-beta.1 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
package/dist/kengic-vue.js
CHANGED
@@ -2185,12 +2185,12 @@ setTwoToneColor("#1890ff");
|
|
2185
2185
|
var Icon$1 = function(t, r) {
|
2186
2186
|
var a, n = _objectSpread$k({}, t, r.attrs), s = n.class, l = n.icon, o = n.spin, i = n.rotate, c = n.tabindex, u = n.twoToneColor, d = n.onClick, g = _objectWithoutProperties(n, _excluded), v = (a = {
|
2187
2187
|
anticon: !0
|
2188
|
-
}, _defineProperty$k(a, "anticon-".concat(l.name), Boolean(l.name)), _defineProperty$k(a, s, s), a), y = o === "" || !!o || l.name === "loading" ? "anticon-spin" : "",
|
2189
|
-
|
2190
|
-
var
|
2188
|
+
}, _defineProperty$k(a, "anticon-".concat(l.name), Boolean(l.name)), _defineProperty$k(a, s, s), a), y = o === "" || !!o || l.name === "loading" ? "anticon-spin" : "", p = c;
|
2189
|
+
p === void 0 && d && (p = -1, g.tabindex = p);
|
2190
|
+
var m = i ? {
|
2191
2191
|
msTransform: "rotate(".concat(i, "deg)"),
|
2192
2192
|
transform: "rotate(".concat(i, "deg)")
|
2193
|
-
} : void 0, b = normalizeTwoToneColors(u), C = _slicedToArray(b, 2),
|
2193
|
+
} : void 0, b = normalizeTwoToneColors(u), C = _slicedToArray(b, 2), T = C[0], E = C[1];
|
2194
2194
|
return createVNode("span", _objectSpread$k({
|
2195
2195
|
role: "img",
|
2196
2196
|
"aria-label": l.name
|
@@ -2200,9 +2200,9 @@ var Icon$1 = function(t, r) {
|
|
2200
2200
|
}), [createVNode(VueIcon, {
|
2201
2201
|
class: y,
|
2202
2202
|
icon: l,
|
2203
|
-
primaryColor:
|
2204
|
-
secondaryColor:
|
2205
|
-
style:
|
2203
|
+
primaryColor: T,
|
2204
|
+
secondaryColor: E,
|
2205
|
+
style: m
|
2206
2206
|
}, null)]);
|
2207
2207
|
};
|
2208
2208
|
Icon$1.props = {
|
@@ -3011,38 +3011,38 @@ function iconToSVG(e, t) {
|
|
3011
3011
|
};
|
3012
3012
|
let s = r.body;
|
3013
3013
|
[r, a].forEach((y) => {
|
3014
|
-
const
|
3014
|
+
const p = [], m = y.hFlip, b = y.vFlip;
|
3015
3015
|
let C = y.rotate;
|
3016
|
-
|
3016
|
+
m ? b ? C += 2 : (p.push(
|
3017
3017
|
"translate(" + (n.width + n.left).toString() + " " + (0 - n.top).toString() + ")"
|
3018
|
-
),
|
3018
|
+
), p.push("scale(-1 1)"), n.top = n.left = 0) : b && (p.push(
|
3019
3019
|
"translate(" + (0 - n.left).toString() + " " + (n.height + n.top).toString() + ")"
|
3020
|
-
),
|
3021
|
-
let
|
3020
|
+
), p.push("scale(1 -1)"), n.top = n.left = 0);
|
3021
|
+
let T;
|
3022
3022
|
switch (C < 0 && (C -= Math.floor(C / 4) * 4), C = C % 4, C) {
|
3023
3023
|
case 1:
|
3024
|
-
|
3025
|
-
"rotate(90 " +
|
3024
|
+
T = n.height / 2 + n.top, p.unshift(
|
3025
|
+
"rotate(90 " + T.toString() + " " + T.toString() + ")"
|
3026
3026
|
);
|
3027
3027
|
break;
|
3028
3028
|
case 2:
|
3029
|
-
|
3029
|
+
p.unshift(
|
3030
3030
|
"rotate(180 " + (n.width / 2 + n.left).toString() + " " + (n.height / 2 + n.top).toString() + ")"
|
3031
3031
|
);
|
3032
3032
|
break;
|
3033
3033
|
case 3:
|
3034
|
-
|
3035
|
-
"rotate(-90 " +
|
3034
|
+
T = n.width / 2 + n.left, p.unshift(
|
3035
|
+
"rotate(-90 " + T.toString() + " " + T.toString() + ")"
|
3036
3036
|
);
|
3037
3037
|
break;
|
3038
3038
|
}
|
3039
|
-
C % 2 === 1 && (n.left !== n.top && (
|
3039
|
+
C % 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)), p.length && (s = '<g transform="' + p.join(" ") + '">' + s + "</g>");
|
3040
3040
|
});
|
3041
3041
|
const l = a.width, o = a.height, i = n.width, c = n.height;
|
3042
3042
|
let u, d;
|
3043
3043
|
l === null ? (d = o === null ? "1em" : o === "auto" ? c : o, u = calculateSize(d, i / c)) : (u = l === "auto" ? i : l, d = o === null ? calculateSize(u, c / i) : o === "auto" ? c : o);
|
3044
|
-
const g = {}, v = (y,
|
3045
|
-
isUnsetKeyword(
|
3044
|
+
const g = {}, v = (y, p) => {
|
3045
|
+
isUnsetKeyword(p) || (g[y] = p.toString());
|
3046
3046
|
};
|
3047
3047
|
return v("width", u), v("height", d), g.viewBox = n.left.toString() + " " + n.top.toString() + " " + i.toString() + " " + c.toString(), {
|
3048
3048
|
attributes: g,
|
@@ -3330,12 +3330,12 @@ function sendQuery(e, t, r, a) {
|
|
3330
3330
|
function y() {
|
3331
3331
|
d && (clearTimeout(d), d = null);
|
3332
3332
|
}
|
3333
|
-
function
|
3333
|
+
function p() {
|
3334
3334
|
i === "pending" && (i = "aborted"), y(), g.forEach((k) => {
|
3335
3335
|
k.status === "pending" && (k.status = "aborted");
|
3336
3336
|
}), g = [];
|
3337
3337
|
}
|
3338
|
-
function
|
3338
|
+
function m(k, R) {
|
3339
3339
|
R && (v = []), typeof k == "function" && v.push(k);
|
3340
3340
|
}
|
3341
3341
|
function b() {
|
@@ -3345,8 +3345,8 @@ function sendQuery(e, t, r, a) {
|
|
3345
3345
|
status: i,
|
3346
3346
|
queriesSent: c,
|
3347
3347
|
queriesPending: g.length,
|
3348
|
-
subscribe:
|
3349
|
-
abort:
|
3348
|
+
subscribe: m,
|
3349
|
+
abort: p
|
3350
3350
|
};
|
3351
3351
|
}
|
3352
3352
|
function C() {
|
@@ -3354,12 +3354,12 @@ function sendQuery(e, t, r, a) {
|
|
3354
3354
|
k(void 0, u);
|
3355
3355
|
});
|
3356
3356
|
}
|
3357
|
-
function
|
3357
|
+
function T() {
|
3358
3358
|
g.forEach((k) => {
|
3359
3359
|
k.status === "pending" && (k.status = "aborted");
|
3360
3360
|
}), g = [];
|
3361
3361
|
}
|
3362
|
-
function
|
3362
|
+
function E(k, R, D) {
|
3363
3363
|
const I = R !== "success";
|
3364
3364
|
switch (g = g.filter((M) => M !== k), i) {
|
3365
3365
|
case "pending":
|
@@ -3379,7 +3379,7 @@ function sendQuery(e, t, r, a) {
|
|
3379
3379
|
u = D, g.length || (l.length ? A() : C());
|
3380
3380
|
return;
|
3381
3381
|
}
|
3382
|
-
if (y(),
|
3382
|
+
if (y(), T(), !e.random) {
|
3383
3383
|
const M = e.resources.indexOf(k.resource);
|
3384
3384
|
M !== -1 && M !== e.index && (e.index = M);
|
3385
3385
|
}
|
@@ -3395,7 +3395,7 @@ function sendQuery(e, t, r, a) {
|
|
3395
3395
|
if (k === void 0) {
|
3396
3396
|
if (g.length) {
|
3397
3397
|
d = setTimeout(() => {
|
3398
|
-
y(), i === "pending" && (
|
3398
|
+
y(), i === "pending" && (T(), C());
|
3399
3399
|
}, e.timeout);
|
3400
3400
|
return;
|
3401
3401
|
}
|
@@ -3406,7 +3406,7 @@ function sendQuery(e, t, r, a) {
|
|
3406
3406
|
status: "pending",
|
3407
3407
|
resource: k,
|
3408
3408
|
callback: (D, I) => {
|
3409
|
-
|
3409
|
+
E(R, D, I);
|
3410
3410
|
}
|
3411
3411
|
};
|
3412
3412
|
g.push(R), c++, d = setTimeout(A, e.rotate), r(k, t, R.callback);
|
@@ -3785,10 +3785,10 @@ function fixSize(e) {
|
|
3785
3785
|
}
|
3786
3786
|
const render = (e, t) => {
|
3787
3787
|
const r = mergeCustomisations(defaultExtendedIconCustomisations, t), a = { ...svgDefaults }, n = t.mode || "svg", s = {}, l = t.style, o = typeof l == "object" && !(l instanceof Array) ? l : {};
|
3788
|
-
for (let
|
3789
|
-
const
|
3790
|
-
if (
|
3791
|
-
switch (
|
3788
|
+
for (let p in t) {
|
3789
|
+
const m = t[p];
|
3790
|
+
if (m !== void 0)
|
3791
|
+
switch (p) {
|
3792
3792
|
case "icon":
|
3793
3793
|
case "style":
|
3794
3794
|
case "onLoad":
|
@@ -3797,24 +3797,24 @@ const render = (e, t) => {
|
|
3797
3797
|
case "inline":
|
3798
3798
|
case "hFlip":
|
3799
3799
|
case "vFlip":
|
3800
|
-
r[
|
3800
|
+
r[p] = m === !0 || m === "true" || m === 1;
|
3801
3801
|
break;
|
3802
3802
|
case "flip":
|
3803
|
-
typeof
|
3803
|
+
typeof m == "string" && flipFromString(r, m);
|
3804
3804
|
break;
|
3805
3805
|
case "color":
|
3806
|
-
s.color =
|
3806
|
+
s.color = m;
|
3807
3807
|
break;
|
3808
3808
|
case "rotate":
|
3809
|
-
typeof
|
3809
|
+
typeof m == "string" ? r[p] = rotateFromString(m) : typeof m == "number" && (r[p] = m);
|
3810
3810
|
break;
|
3811
3811
|
case "ariaHidden":
|
3812
3812
|
case "aria-hidden":
|
3813
|
-
|
3813
|
+
m !== !0 && m !== "true" && delete a["aria-hidden"];
|
3814
3814
|
break;
|
3815
3815
|
default: {
|
3816
|
-
const b = customisationAliases[
|
3817
|
-
b ? (
|
3816
|
+
const b = customisationAliases[p];
|
3817
|
+
b ? (m === !0 || m === "true" || m === 1) && (r[b] = !0) : defaultExtendedIconCustomisations[p] === void 0 && (a[p] = m);
|
3818
3818
|
}
|
3819
3819
|
}
|
3820
3820
|
}
|
@@ -3824,8 +3824,8 @@ const render = (e, t) => {
|
|
3824
3824
|
...s,
|
3825
3825
|
...o
|
3826
3826
|
}, Object.assign(a, c);
|
3827
|
-
let
|
3828
|
-
return typeof
|
3827
|
+
let p = 0, m = t.id;
|
3828
|
+
return typeof m == "string" && (m = m.replace(/-/g, "_")), a.innerHTML = replaceIDs(i.body, m ? () => m + "ID" + p++ : "iconifyVue"), h("svg", a);
|
3829
3829
|
}
|
3830
3830
|
const { body: u, width: d, height: g } = e, v = n === "mask" || (n === "bg" ? !1 : u.indexOf("currentColor") !== -1), y = iconToHTML(u, {
|
3831
3831
|
...c,
|
@@ -3940,15 +3940,15 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3940
3940
|
(function(r, a) {
|
3941
3941
|
e.exports = a();
|
3942
3942
|
})(commonjsGlobal, function() {
|
3943
|
-
var r = 1e3, a = 6e4, n = 36e5, s = "millisecond", l = "second", o = "minute", i = "hour", c = "day", u = "week", d = "month", g = "quarter", v = "year", y = "date",
|
3943
|
+
var r = 1e3, a = 6e4, n = 36e5, s = "millisecond", l = "second", o = "minute", i = "hour", c = "day", u = "week", d = "month", g = "quarter", v = "year", y = "date", p = "Invalid Date", m = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, b = /\[([^\]]+)]|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, C = { 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(w) {
|
3944
3944
|
var O = ["th", "st", "nd", "rd"], V = w % 100;
|
3945
3945
|
return "[" + w + (O[(V - 20) % 10] || O[V] || O[0]) + "]";
|
3946
|
-
} },
|
3946
|
+
} }, T = function(w, O, V) {
|
3947
3947
|
var G = String(w);
|
3948
3948
|
return !G || G.length >= O ? w : "" + Array(O + 1 - G.length).join(V) + w;
|
3949
|
-
},
|
3949
|
+
}, E = { s: T, z: function(w) {
|
3950
3950
|
var O = -w.utcOffset(), V = Math.abs(O), G = Math.floor(V / 60), F = V % 60;
|
3951
|
-
return (O <= 0 ? "+" : "-") +
|
3951
|
+
return (O <= 0 ? "+" : "-") + T(G, 2, "0") + ":" + T(F, 2, "0");
|
3952
3952
|
}, m: function w(O, V) {
|
3953
3953
|
if (O.date() < V.date())
|
3954
3954
|
return -w(V, O);
|
@@ -3984,7 +3984,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3984
3984
|
return w.clone();
|
3985
3985
|
var V = typeof O == "object" ? O : {};
|
3986
3986
|
return V.date = w, V.args = arguments, new N(V);
|
3987
|
-
}, P =
|
3987
|
+
}, P = E;
|
3988
3988
|
P.l = I, P.i = D, P.w = function(w, O) {
|
3989
3989
|
return M(w, { locale: O.$L, utc: O.$u, x: O.$x, $offset: O.$offset });
|
3990
3990
|
};
|
@@ -4003,7 +4003,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4003
4003
|
if (F instanceof Date)
|
4004
4004
|
return new Date(F);
|
4005
4005
|
if (typeof F == "string" && !/Z$/i.test(F)) {
|
4006
|
-
var B = F.match(
|
4006
|
+
var B = F.match(m);
|
4007
4007
|
if (B) {
|
4008
4008
|
var Y = B[2] - 1 || 0, Q = (B[7] || "0").substring(0, 3);
|
4009
4009
|
return L ? new Date(Date.UTC(B[1], Y, B[3] || 1, B[4] || 0, B[5] || 0, B[6] || 0, Q)) : new Date(B[1], Y, B[3] || 1, B[4] || 0, B[5] || 0, B[6] || 0, Q);
|
@@ -4017,7 +4017,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4017
4017
|
}, O.$utils = function() {
|
4018
4018
|
return P;
|
4019
4019
|
}, O.isValid = function() {
|
4020
|
-
return this.$d.toString() !==
|
4020
|
+
return this.$d.toString() !== p;
|
4021
4021
|
}, O.isSame = function(V, G) {
|
4022
4022
|
var F = M(V);
|
4023
4023
|
return this.startOf(G) <= F && F <= this.endOf(G);
|
@@ -4094,7 +4094,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4094
4094
|
}, O.format = function(V) {
|
4095
4095
|
var G = this, F = this.$locale();
|
4096
4096
|
if (!this.isValid())
|
4097
|
-
return F.invalidDate ||
|
4097
|
+
return F.invalidDate || p;
|
4098
4098
|
var L = V || "YYYY-MM-DDTHH:mm:ssZ", B = P.z(this), Y = this.$H, Q = this.$m, z = this.$M, Z = F.weekdays, ee = F.months, se = F.meridiem, oe = function(ne, le, de, fe) {
|
4099
4099
|
return ne && (ne[le] || ne(G, L)) || de[le].slice(0, fe);
|
4100
4100
|
}, ge = function(ne) {
|
@@ -4264,35 +4264,35 @@ function filesize(e, {
|
|
4264
4264
|
fullform: g = !1,
|
4265
4265
|
fullforms: v = [],
|
4266
4266
|
exponent: y = -1,
|
4267
|
-
roundingMethod:
|
4268
|
-
precision:
|
4267
|
+
roundingMethod: p = ROUND,
|
4268
|
+
precision: m = 0
|
4269
4269
|
} = {}) {
|
4270
|
-
let b = y, C = Number(e),
|
4270
|
+
let b = y, C = Number(e), T = [], E = 0, A = EMPTY;
|
4271
4271
|
u === SI ? (a = 10, u = JEDEC) : u === IEC || u === JEDEC ? a = 2 : a === 2 ? u = IEC : (a = 10, u = JEDEC);
|
4272
|
-
const k = a === 10 ? 1e3 : 1024, R = g === !0, D = C < 0, I = Math[
|
4272
|
+
const k = a === 10 ? 1e3 : 1024, R = g === !0, D = C < 0, I = Math[p];
|
4273
4273
|
if (typeof e != "bigint" && isNaN(e))
|
4274
4274
|
throw new TypeError(INVALID_NUMBER);
|
4275
4275
|
if (typeof I !== FUNCTION)
|
4276
4276
|
throw new TypeError(INVALID_ROUND);
|
4277
|
-
if (D && (C = -C), (b === -1 || isNaN(b)) && (b = Math.floor(Math.log(C) / Math.log(k)), b < 0 && (b = 0)), b > 8 && (
|
4277
|
+
if (D && (C = -C), (b === -1 || isNaN(b)) && (b = Math.floor(Math.log(C) / Math.log(k)), b < 0 && (b = 0)), b > 8 && (m > 0 && (m += 8 - b), b = 8), d === EXPONENT)
|
4278
4278
|
return b;
|
4279
4279
|
if (C === 0)
|
4280
|
-
|
4280
|
+
T[0] = 0, A = T[1] = STRINGS.symbol[u][t ? BITS : BYTES][b];
|
4281
4281
|
else {
|
4282
|
-
|
4282
|
+
E = C / (a === 2 ? Math.pow(2, b * 10) : Math.pow(1e3, b)), t && (E = E * 8, E >= k && b < 8 && (E = E / k, b++));
|
4283
4283
|
const M = Math.pow(10, b > 0 ? n : 0);
|
4284
|
-
|
4284
|
+
T[0] = I(E * M) / M, T[0] === k && b < 8 && y === -1 && (T[0] = 1, b++), A = T[1] = a === 10 && b === 1 ? t ? SI_KBIT : SI_KBYTE : STRINGS.symbol[u][t ? BITS : BYTES][b];
|
4285
4285
|
}
|
4286
|
-
if (D && (
|
4287
|
-
const M = o || PERIOD, P =
|
4288
|
-
|
4286
|
+
if (D && (T[0] = -T[0]), m > 0 && (T[0] = T[0].toPrecision(m)), T[1] = c[T[1]] || T[1], s === !0 ? T[0] = T[0].toLocaleString() : s.length > 0 ? T[0] = T[0].toLocaleString(s, l) : o.length > 0 && (T[0] = T[0].toString().replace(PERIOD, o)), r && Number.isInteger(T[0]) === !1 && n > 0) {
|
4287
|
+
const M = o || PERIOD, P = T[0].toString().split(M), N = P[1] || EMPTY, U = N.length, w = n - U;
|
4288
|
+
T[0] = `${P[0]}${M}${N.padEnd(U + w, ZERO)}`;
|
4289
4289
|
}
|
4290
|
-
return R && (
|
4291
|
-
value:
|
4292
|
-
symbol:
|
4290
|
+
return R && (T[1] = v[b] ? v[b] : STRINGS.fullform[u][b] + (t ? BIT : BYTE) + (T[0] === 1 ? EMPTY : S)), d === ARRAY ? T : d === OBJECT ? {
|
4291
|
+
value: T[0],
|
4292
|
+
symbol: T[1],
|
4293
4293
|
exponent: b,
|
4294
4294
|
unit: A
|
4295
|
-
} :
|
4295
|
+
} : T.join(i);
|
4296
4296
|
}
|
4297
4297
|
var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
|
4298
4298
|
const freeGlobal$1 = freeGlobal;
|
@@ -5336,14 +5336,14 @@ function baseClone(e, t, r, a, n, s) {
|
|
5336
5336
|
var v = s.get(e);
|
5337
5337
|
if (v)
|
5338
5338
|
return v;
|
5339
|
-
s.set(e, l), isSet$1(e) ? e.forEach(function(
|
5340
|
-
l.add(baseClone(
|
5341
|
-
}) : isMap$1(e) && e.forEach(function(
|
5342
|
-
l.set(b, baseClone(
|
5339
|
+
s.set(e, l), isSet$1(e) ? e.forEach(function(m) {
|
5340
|
+
l.add(baseClone(m, t, r, m, e, s));
|
5341
|
+
}) : isMap$1(e) && e.forEach(function(m, b) {
|
5342
|
+
l.set(b, baseClone(m, t, r, b, e, s));
|
5343
5343
|
});
|
5344
|
-
var y = c ? i ? getAllKeysIn : getAllKeys : i ? keysIn : keys,
|
5345
|
-
return arrayEach(
|
5346
|
-
|
5344
|
+
var y = c ? i ? getAllKeysIn : getAllKeys : i ? keysIn : keys, p = u ? void 0 : y(e);
|
5345
|
+
return arrayEach(p || e, function(m, b) {
|
5346
|
+
p && (b = m, m = e[b]), assignValue(l, b, baseClone(m, t, r, b, e, s));
|
5347
5347
|
}), l;
|
5348
5348
|
}
|
5349
5349
|
var CLONE_DEEP_FLAG = 1, CLONE_SYMBOLS_FLAG = 4;
|
@@ -5383,11 +5383,11 @@ function equalArrays(e, t, r, a, n, s) {
|
|
5383
5383
|
return c == t && u == e;
|
5384
5384
|
var d = -1, g = !0, v = r & COMPARE_UNORDERED_FLAG$3 ? new SetCache() : void 0;
|
5385
5385
|
for (s.set(e, t), s.set(t, e); ++d < o; ) {
|
5386
|
-
var y = e[d],
|
5386
|
+
var y = e[d], p = t[d];
|
5387
5387
|
if (a)
|
5388
|
-
var
|
5389
|
-
if (
|
5390
|
-
if (
|
5388
|
+
var m = l ? a(p, y, d, t, e, s) : a(y, p, d, e, t, s);
|
5389
|
+
if (m !== void 0) {
|
5390
|
+
if (m)
|
5391
5391
|
continue;
|
5392
5392
|
g = !1;
|
5393
5393
|
break;
|
@@ -5400,7 +5400,7 @@ function equalArrays(e, t, r, a, n, s) {
|
|
5400
5400
|
g = !1;
|
5401
5401
|
break;
|
5402
5402
|
}
|
5403
|
-
} else if (!(y ===
|
5403
|
+
} else if (!(y === p || n(y, p, r, a, s))) {
|
5404
5404
|
g = !1;
|
5405
5405
|
break;
|
5406
5406
|
}
|
@@ -5468,24 +5468,24 @@ function equalObjects(e, t, r, a, n, s) {
|
|
5468
5468
|
var v = s.get(e), y = s.get(t);
|
5469
5469
|
if (v && y)
|
5470
5470
|
return v == t && y == e;
|
5471
|
-
var
|
5471
|
+
var p = !0;
|
5472
5472
|
s.set(e, t), s.set(t, e);
|
5473
|
-
for (var
|
5473
|
+
for (var m = l; ++d < i; ) {
|
5474
5474
|
g = o[d];
|
5475
5475
|
var b = e[g], C = t[g];
|
5476
5476
|
if (a)
|
5477
|
-
var
|
5478
|
-
if (!(
|
5479
|
-
|
5477
|
+
var T = l ? a(C, b, g, t, e, s) : a(b, C, g, e, t, s);
|
5478
|
+
if (!(T === void 0 ? b === C || n(b, C, r, a, s) : T)) {
|
5479
|
+
p = !1;
|
5480
5480
|
break;
|
5481
5481
|
}
|
5482
|
-
|
5482
|
+
m || (m = g == "constructor");
|
5483
5483
|
}
|
5484
|
-
if (
|
5485
|
-
var
|
5486
|
-
|
5484
|
+
if (p && !m) {
|
5485
|
+
var E = e.constructor, A = t.constructor;
|
5486
|
+
E != A && "constructor" in e && "constructor" in t && !(typeof E == "function" && E instanceof E && typeof A == "function" && A instanceof A) && (p = !1);
|
5487
5487
|
}
|
5488
|
-
return s.delete(e), s.delete(t),
|
5488
|
+
return s.delete(e), s.delete(t), p;
|
5489
5489
|
}
|
5490
5490
|
var COMPARE_PARTIAL_FLAG$2 = 1, argsTag = "[object Arguments]", arrayTag = "[object Array]", objectTag = "[object Object]", objectProto = Object.prototype, hasOwnProperty = objectProto.hasOwnProperty;
|
5491
5491
|
function baseIsEqualDeep(e, t, r, a, n, s) {
|
@@ -5502,8 +5502,8 @@ function baseIsEqualDeep(e, t, r, a, n, s) {
|
|
5502
5502
|
if (!(r & COMPARE_PARTIAL_FLAG$2)) {
|
5503
5503
|
var v = u && hasOwnProperty.call(e, "__wrapped__"), y = d && hasOwnProperty.call(t, "__wrapped__");
|
5504
5504
|
if (v || y) {
|
5505
|
-
var
|
5506
|
-
return s || (s = new Stack()), n(
|
5505
|
+
var p = v ? e.value() : e, m = y ? t.value() : t;
|
5506
|
+
return s || (s = new Stack()), n(p, m, r, a, s);
|
5507
5507
|
}
|
5508
5508
|
}
|
5509
5509
|
return g ? (s || (s = new Stack()), equalObjects(e, t, r, a, n, s)) : !1;
|
@@ -5642,31 +5642,31 @@ function debounce(e, t, r) {
|
|
5642
5642
|
function y(k) {
|
5643
5643
|
return c = k, o = setTimeout(b, t), u ? v(k) : l;
|
5644
5644
|
}
|
5645
|
-
function
|
5645
|
+
function p(k) {
|
5646
5646
|
var R = k - i, D = k - c, I = t - R;
|
5647
5647
|
return d ? nativeMin$1(I, s - D) : I;
|
5648
5648
|
}
|
5649
|
-
function
|
5649
|
+
function m(k) {
|
5650
5650
|
var R = k - i, D = k - c;
|
5651
5651
|
return i === void 0 || R >= t || R < 0 || d && D >= s;
|
5652
5652
|
}
|
5653
5653
|
function b() {
|
5654
5654
|
var k = now$1();
|
5655
|
-
if (
|
5655
|
+
if (m(k))
|
5656
5656
|
return C(k);
|
5657
|
-
o = setTimeout(b,
|
5657
|
+
o = setTimeout(b, p(k));
|
5658
5658
|
}
|
5659
5659
|
function C(k) {
|
5660
5660
|
return o = void 0, g && a ? v(k) : (a = n = void 0, l);
|
5661
5661
|
}
|
5662
|
-
function
|
5662
|
+
function T() {
|
5663
5663
|
o !== void 0 && clearTimeout(o), c = 0, a = i = n = o = void 0;
|
5664
5664
|
}
|
5665
|
-
function
|
5665
|
+
function E() {
|
5666
5666
|
return o === void 0 ? l : C(now$1());
|
5667
5667
|
}
|
5668
5668
|
function A() {
|
5669
|
-
var k = now$1(), R =
|
5669
|
+
var k = now$1(), R = m(k);
|
5670
5670
|
if (a = arguments, n = this, i = k, R) {
|
5671
5671
|
if (o === void 0)
|
5672
5672
|
return y(i);
|
@@ -5675,7 +5675,7 @@ function debounce(e, t, r) {
|
|
5675
5675
|
}
|
5676
5676
|
return o === void 0 && (o = setTimeout(b, t)), l;
|
5677
5677
|
}
|
5678
|
-
return A.cancel =
|
5678
|
+
return A.cancel = T, A.flush = E, A;
|
5679
5679
|
}
|
5680
5680
|
function isArrayLikeObject(e) {
|
5681
5681
|
return isObjectLike(e) && isArrayLike(e);
|
@@ -5765,8 +5765,8 @@ function baseIntersection(e, t, r) {
|
|
5765
5765
|
var v = u[d], y = t ? t(v) : v;
|
5766
5766
|
if (v = r || v !== 0 ? v : 0, !(g ? cacheHas(g, y) : a(c, y, r))) {
|
5767
5767
|
for (l = s; --l; ) {
|
5768
|
-
var
|
5769
|
-
if (!(
|
5768
|
+
var p = o[l];
|
5769
|
+
if (!(p ? cacheHas(p, y) : a(e[l], y, r)))
|
5770
5770
|
continue e;
|
5771
5771
|
}
|
5772
5772
|
g && g.push(y), c.push(v);
|
@@ -6345,16 +6345,16 @@ class KgUtil {
|
|
6345
6345
|
s[d] = n[d];
|
6346
6346
|
return;
|
6347
6347
|
}
|
6348
|
-
const g = i.store.getVarProfileDetail(r, d), v = g != null && g.table_alias ? `${g == null ? void 0 : g.table_alias}.` : "", y = n[d],
|
6348
|
+
const g = i.store.getVarProfileDetail(r, d), v = g != null && g.table_alias ? `${g == null ? void 0 : g.table_alias}.` : "", y = n[d], p = u == null ? void 0 : u[d];
|
6349
6349
|
switch (!0) {
|
6350
6350
|
case d.endsWith("_obj"): {
|
6351
6351
|
s[d] = void 0;
|
6352
6352
|
break;
|
6353
6353
|
}
|
6354
6354
|
case (!!a && a.isDayjs(y)): {
|
6355
|
-
const
|
6356
|
-
let b = this.parseParamFromDayJS(d,
|
6357
|
-
switch (
|
6355
|
+
const m = y;
|
6356
|
+
let b = this.parseParamFromDayJS(d, m, r);
|
6357
|
+
switch (p) {
|
6358
6358
|
case KG_DYNAMIC_QUERY_OPERATOR.NE:
|
6359
6359
|
break;
|
6360
6360
|
case KG_DYNAMIC_QUERY_OPERATOR.LT:
|
@@ -6367,45 +6367,45 @@ class KgUtil {
|
|
6367
6367
|
break;
|
6368
6368
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6369
6369
|
default: {
|
6370
|
-
let C = b,
|
6370
|
+
let C = b, T = "";
|
6371
6371
|
switch (!0) {
|
6372
6372
|
case /\d\d-\d\d-\d\d \d\d:\d\d:\d\d/.test(C): {
|
6373
|
-
|
6373
|
+
T = m.add(1, "second").format("YYYY-MM-DD HH:mm:ss");
|
6374
6374
|
break;
|
6375
6375
|
}
|
6376
6376
|
case /\d\d-\d\d-\d\d/.test(C): {
|
6377
|
-
|
6377
|
+
T = m.add(1, "day").format("YYYY-MM-DD");
|
6378
6378
|
break;
|
6379
6379
|
}
|
6380
6380
|
case /\d\d:\d\d:\d\d/.test(C): {
|
6381
|
-
C =
|
6381
|
+
C = m.format("1970-01-01 HH:mm:ss"), T = m.add(1, "second").format("1970-01-01 HH:mm:ss");
|
6382
6382
|
break;
|
6383
6383
|
}
|
6384
6384
|
}
|
6385
|
-
|
6385
|
+
T ? b = ` AND (${v}${d} >= '${C}' AND ${v}${d} < '${T}')` : b = ` AND (${v}${d} >= '${C}')`;
|
6386
6386
|
}
|
6387
6387
|
}
|
6388
6388
|
s[d] = b;
|
6389
6389
|
break;
|
6390
6390
|
}
|
6391
6391
|
case (!!a && isArray$1(y) && y.length === 2 && a.isDayjs(y[0]) && a.isDayjs(y[1])): {
|
6392
|
-
const
|
6393
|
-
let C = this.parseParamFromDayJS(d,
|
6392
|
+
const m = y[0], b = y[1];
|
6393
|
+
let C = this.parseParamFromDayJS(d, m, r), T = "", E = "";
|
6394
6394
|
switch (!0) {
|
6395
6395
|
case /\d\d-\d\d-\d\d \d\d:\d\d:\d\d/.test(C): {
|
6396
|
-
|
6396
|
+
T = b.add(1, "second").format("YYYY-MM-DD HH:mm:ss");
|
6397
6397
|
break;
|
6398
6398
|
}
|
6399
6399
|
case /\d\d-\d\d-\d\d/.test(C): {
|
6400
|
-
|
6400
|
+
T = b.add(1, "day").format("YYYY-MM-DD");
|
6401
6401
|
break;
|
6402
6402
|
}
|
6403
6403
|
case /\d\d:\d\d:\d\d/.test(C): {
|
6404
|
-
C =
|
6404
|
+
C = m.format("1970-01-01 HH:mm:ss"), T = b.add(1, "second").format("1970-01-01 HH:mm:ss");
|
6405
6405
|
break;
|
6406
6406
|
}
|
6407
6407
|
}
|
6408
|
-
|
6408
|
+
T ? E = ` AND (${v}${d} >= '${C}' AND ${v}${d} < '${T}')` : E = ` AND (${v}${d} >= '${C}')`, s[d] = E;
|
6409
6409
|
break;
|
6410
6410
|
}
|
6411
6411
|
case Array.isArray(y): {
|
@@ -6413,8 +6413,8 @@ class KgUtil {
|
|
6413
6413
|
s[d] = void 0;
|
6414
6414
|
break;
|
6415
6415
|
}
|
6416
|
-
const
|
6417
|
-
s[d] = ` AND (${v}${d} IN (${
|
6416
|
+
const m = y.map((b) => `'${String(b)}'`).join(", ");
|
6417
|
+
s[d] = ` AND (${v}${d} IN (${m}))`;
|
6418
6418
|
break;
|
6419
6419
|
}
|
6420
6420
|
case isObjectLike(y):
|
@@ -6424,79 +6424,79 @@ class KgUtil {
|
|
6424
6424
|
s[d] = void 0;
|
6425
6425
|
break;
|
6426
6426
|
}
|
6427
|
-
let
|
6428
|
-
switch (
|
6427
|
+
let m = this.parseParams(y, r, a);
|
6428
|
+
switch (p) {
|
6429
6429
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6430
|
-
|
6430
|
+
m = ` AND (${v}${d} <> '${m}')`;
|
6431
6431
|
break;
|
6432
6432
|
}
|
6433
6433
|
case KG_DYNAMIC_QUERY_OPERATOR.START_WITH: {
|
6434
|
-
|
6434
|
+
m = ` AND (${v}${d} LIKE '${m}%')`;
|
6435
6435
|
break;
|
6436
6436
|
}
|
6437
6437
|
case KG_DYNAMIC_QUERY_OPERATOR.END_WITH: {
|
6438
|
-
|
6438
|
+
m = ` AND (${v}${d} LIKE '%${m}')`;
|
6439
6439
|
break;
|
6440
6440
|
}
|
6441
6441
|
case KG_DYNAMIC_QUERY_OPERATOR.CONTAIN: {
|
6442
|
-
|
6442
|
+
m = ` AND (${v}${d} LIKE '%${m}%')`;
|
6443
6443
|
break;
|
6444
6444
|
}
|
6445
6445
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6446
6446
|
default: {
|
6447
|
-
|
6447
|
+
m = ` AND (${v}${d} = '${m}')`;
|
6448
6448
|
break;
|
6449
6449
|
}
|
6450
6450
|
}
|
6451
|
-
s[d] =
|
6451
|
+
s[d] = m;
|
6452
6452
|
break;
|
6453
6453
|
}
|
6454
6454
|
case typeof y == "number": {
|
6455
|
-
let
|
6456
|
-
switch (
|
6455
|
+
let m = "";
|
6456
|
+
switch (p) {
|
6457
6457
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6458
|
-
|
6458
|
+
m = ` AND (${v}${d} <> ${y})`;
|
6459
6459
|
break;
|
6460
6460
|
}
|
6461
6461
|
case KG_DYNAMIC_QUERY_OPERATOR.LT: {
|
6462
|
-
|
6462
|
+
m = ` AND (${v}${d} < ${y})`;
|
6463
6463
|
break;
|
6464
6464
|
}
|
6465
6465
|
case KG_DYNAMIC_QUERY_OPERATOR.LTE: {
|
6466
|
-
|
6466
|
+
m = ` AND (${v}${d} <= ${y})`;
|
6467
6467
|
break;
|
6468
6468
|
}
|
6469
6469
|
case KG_DYNAMIC_QUERY_OPERATOR.GT: {
|
6470
|
-
|
6470
|
+
m = ` AND (${v}${d} > ${y})`;
|
6471
6471
|
break;
|
6472
6472
|
}
|
6473
6473
|
case KG_DYNAMIC_QUERY_OPERATOR.GTE: {
|
6474
|
-
|
6474
|
+
m = ` AND (${v}${d} >= ${y})`;
|
6475
6475
|
break;
|
6476
6476
|
}
|
6477
6477
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6478
6478
|
default: {
|
6479
|
-
|
6479
|
+
m = ` AND (${v}${d} = ${y})`;
|
6480
6480
|
break;
|
6481
6481
|
}
|
6482
6482
|
}
|
6483
|
-
s[d] =
|
6483
|
+
s[d] = m;
|
6484
6484
|
break;
|
6485
6485
|
}
|
6486
6486
|
case typeof y == "boolean": {
|
6487
|
-
let
|
6488
|
-
switch (
|
6487
|
+
let m = "";
|
6488
|
+
switch (p) {
|
6489
6489
|
case KG_DYNAMIC_QUERY_OPERATOR.NE: {
|
6490
|
-
|
6490
|
+
m = ` AND (${v}${d} <> ${y ? 1 : 0})`;
|
6491
6491
|
break;
|
6492
6492
|
}
|
6493
6493
|
case KG_DYNAMIC_QUERY_OPERATOR.EQ:
|
6494
6494
|
default: {
|
6495
|
-
|
6495
|
+
m = ` AND (${v}${d} = ${y ? 1 : 0})`;
|
6496
6496
|
break;
|
6497
6497
|
}
|
6498
6498
|
}
|
6499
|
-
s[d] =
|
6499
|
+
s[d] = m;
|
6500
6500
|
break;
|
6501
6501
|
}
|
6502
6502
|
default: {
|
@@ -6777,8 +6777,8 @@ class KgVarUtil {
|
|
6777
6777
|
let i = n;
|
6778
6778
|
const c = /(.*)?({(.*)?})(.*)?/.exec(i);
|
6779
6779
|
if (c) {
|
6780
|
-
const
|
6781
|
-
switch (c[2].slice(1, -1),
|
6780
|
+
const p = c[2];
|
6781
|
+
switch (c[2].slice(1, -1), p) {
|
6782
6782
|
case "{NOW}":
|
6783
6783
|
i = i.replace("{NOW}", a().format("YYYY-MM-DD HH:mm:ss"));
|
6784
6784
|
break;
|
@@ -6791,20 +6791,20 @@ class KgVarUtil {
|
|
6791
6791
|
if (!u)
|
6792
6792
|
return i;
|
6793
6793
|
const d = (() => {
|
6794
|
-
const
|
6794
|
+
const p = u.ctrl_typ, m = u.prf_ctrl_typ, b = u.crt_ctrl_typ, C = u.upt_ctrl_typ, T = u.cpy_ctrl_typ, E = u.del_ctrl_typ;
|
6795
6795
|
switch (s) {
|
6796
6796
|
case "R":
|
6797
|
-
return
|
6797
|
+
return m || p;
|
6798
6798
|
case "C":
|
6799
|
-
return b ||
|
6799
|
+
return b || p;
|
6800
6800
|
case "U":
|
6801
|
-
return C ||
|
6801
|
+
return C || p;
|
6802
6802
|
case "CP":
|
6803
|
-
return
|
6803
|
+
return T || p;
|
6804
6804
|
case "D":
|
6805
|
-
return
|
6805
|
+
return E || p;
|
6806
6806
|
}
|
6807
|
-
return
|
6807
|
+
return p;
|
6808
6808
|
})();
|
6809
6809
|
switch (d) {
|
6810
6810
|
case KG_FORM_ITEM_TYPE.INPUT:
|
@@ -6814,8 +6814,8 @@ class KgVarUtil {
|
|
6814
6814
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER: {
|
6815
6815
|
if (isNil(i))
|
6816
6816
|
return;
|
6817
|
-
const
|
6818
|
-
if (Number.isNaN(
|
6817
|
+
const p = Number(i);
|
6818
|
+
if (Number.isNaN(p)) {
|
6819
6819
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.`, {
|
6820
6820
|
frm_id: t,
|
6821
6821
|
var_nam: r,
|
@@ -6823,14 +6823,14 @@ class KgVarUtil {
|
|
6823
6823
|
});
|
6824
6824
|
return;
|
6825
6825
|
}
|
6826
|
-
return
|
6826
|
+
return p;
|
6827
6827
|
}
|
6828
6828
|
case KG_FORM_ITEM_TYPE.CHECKBOX:
|
6829
6829
|
case KG_FORM_ITEM_TYPE.SWITCH: {
|
6830
6830
|
if (isNil(i))
|
6831
6831
|
return 0;
|
6832
|
-
const
|
6833
|
-
if (Number.isNaN(
|
6832
|
+
const p = Number(i);
|
6833
|
+
if (Number.isNaN(p)) {
|
6834
6834
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.`, {
|
6835
6835
|
frm_id: t,
|
6836
6836
|
var_nam: r,
|
@@ -6838,7 +6838,7 @@ class KgVarUtil {
|
|
6838
6838
|
});
|
6839
6839
|
return;
|
6840
6840
|
}
|
6841
|
-
if (![0, 1].includes(
|
6841
|
+
if (![0, 1].includes(p)) {
|
6842
6842
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A 0 \u6216 1.`, {
|
6843
6843
|
frm_id: t,
|
6844
6844
|
var_nam: r,
|
@@ -6846,14 +6846,14 @@ class KgVarUtil {
|
|
6846
6846
|
});
|
6847
6847
|
return;
|
6848
6848
|
}
|
6849
|
-
return
|
6849
|
+
return p;
|
6850
6850
|
}
|
6851
6851
|
case KG_FORM_ITEM_TYPE.DATE_TIME: {
|
6852
6852
|
if (isNil(i) || i.trim() === "")
|
6853
6853
|
return;
|
6854
|
-
const
|
6855
|
-
if (
|
6856
|
-
return
|
6854
|
+
const p = a(`1970-01-01 ${i}`);
|
6855
|
+
if (p != null && p.isValid())
|
6856
|
+
return p;
|
6857
6857
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u65F6\u95F4\u7C7B\u578B.`, {
|
6858
6858
|
frm_id: t,
|
6859
6859
|
var_nam: r,
|
@@ -6868,9 +6868,9 @@ class KgVarUtil {
|
|
6868
6868
|
case KG_FORM_ITEM_TYPE.DATE_YEAR: {
|
6869
6869
|
if (isNil(i))
|
6870
6870
|
return;
|
6871
|
-
const
|
6872
|
-
if (
|
6873
|
-
return
|
6871
|
+
const p = a(i);
|
6872
|
+
if (p != null && p.isValid())
|
6873
|
+
return p;
|
6874
6874
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u65E5\u671F\u7C7B\u578B.`, {
|
6875
6875
|
frm_id: t,
|
6876
6876
|
var_nam: r,
|
@@ -6883,8 +6883,8 @@ class KgVarUtil {
|
|
6883
6883
|
if (isNil(i))
|
6884
6884
|
return [];
|
6885
6885
|
try {
|
6886
|
-
const
|
6887
|
-
if (!isArray$1(
|
6886
|
+
const p = JSON.parse(i);
|
6887
|
+
if (!isArray$1(p)) {
|
6888
6888
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u7EC4\u7C7B\u578B.`, {
|
6889
6889
|
frm_id: t,
|
6890
6890
|
var_nam: r,
|
@@ -6892,26 +6892,26 @@ class KgVarUtil {
|
|
6892
6892
|
});
|
6893
6893
|
return;
|
6894
6894
|
}
|
6895
|
-
const
|
6896
|
-
switch (
|
6895
|
+
const m = o.store.getVarPossibility(t, r);
|
6896
|
+
switch (m == null ? void 0 : m.val_data_type) {
|
6897
6897
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER: {
|
6898
|
-
const b =
|
6898
|
+
const b = p.map((C) => Number(C));
|
6899
6899
|
if (b.some((C) => Number.isNaN(b))) {
|
6900
6900
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A number \u6570\u7EC4\u7C7B\u578B.`, {
|
6901
6901
|
frm_id: t,
|
6902
6902
|
var_nam: r,
|
6903
6903
|
value: i,
|
6904
|
-
VarPossibility:
|
6904
|
+
VarPossibility: m
|
6905
6905
|
});
|
6906
6906
|
return;
|
6907
6907
|
}
|
6908
6908
|
return b;
|
6909
6909
|
}
|
6910
6910
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
6911
|
-
return
|
6911
|
+
return p.map((b) => Boolean(b));
|
6912
6912
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
6913
6913
|
default:
|
6914
|
-
return
|
6914
|
+
return p.map((b) => String(b));
|
6915
6915
|
}
|
6916
6916
|
} catch {
|
6917
6917
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u7EC4\u7C7B\u578B.`, {
|
@@ -6925,20 +6925,20 @@ class KgVarUtil {
|
|
6925
6925
|
case KG_FORM_ITEM_TYPE.SELECT: {
|
6926
6926
|
if (isNil(i))
|
6927
6927
|
return;
|
6928
|
-
const
|
6929
|
-
switch (
|
6928
|
+
const p = o.store.getVarPossibility(t, r);
|
6929
|
+
switch (p == null ? void 0 : p.val_data_type) {
|
6930
6930
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER: {
|
6931
|
-
const
|
6932
|
-
if (Number.isNaN(
|
6931
|
+
const m = Number(i);
|
6932
|
+
if (Number.isNaN(m)) {
|
6933
6933
|
KgLogger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${d} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.`, {
|
6934
6934
|
frm_id: t,
|
6935
6935
|
var_nam: r,
|
6936
6936
|
value: i,
|
6937
|
-
VarPossibility:
|
6937
|
+
VarPossibility: p
|
6938
6938
|
});
|
6939
6939
|
return;
|
6940
6940
|
}
|
6941
|
-
return
|
6941
|
+
return m;
|
6942
6942
|
}
|
6943
6943
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
6944
6944
|
return Boolean(i);
|
@@ -7177,8 +7177,8 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7177
7177
|
let c, u, d = markRaw([]), g = markRaw([]), v;
|
7178
7178
|
const y = a.state.value[e];
|
7179
7179
|
!l && !y && (process.env.NODE_ENV === "production" || !n) && (a.state.value[e] = {});
|
7180
|
-
const
|
7181
|
-
function
|
7180
|
+
const p = ref({});
|
7181
|
+
function m(D) {
|
7182
7182
|
let I;
|
7183
7183
|
c = u = !1, process.env.NODE_ENV !== "production" && (v = []), typeof D == "function" ? (D(a.state.value[e]), I = {
|
7184
7184
|
type: MutationType.patchFunction,
|
@@ -7199,7 +7199,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7199
7199
|
function C() {
|
7200
7200
|
s.stop(), d = [], g = [], a._s.delete(e);
|
7201
7201
|
}
|
7202
|
-
function
|
7202
|
+
function T(D, I) {
|
7203
7203
|
return function() {
|
7204
7204
|
setActivePinia(a);
|
7205
7205
|
const M = Array.from(arguments), P = [], N = [];
|
@@ -7225,16 +7225,16 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7225
7225
|
return O instanceof Promise ? O.then((V) => (triggerSubscriptions(P, V), V)).catch((V) => (triggerSubscriptions(N, V), Promise.reject(V))) : (triggerSubscriptions(P, O), O);
|
7226
7226
|
};
|
7227
7227
|
}
|
7228
|
-
const
|
7228
|
+
const E = /* @__PURE__ */ markRaw({
|
7229
7229
|
actions: {},
|
7230
7230
|
getters: {},
|
7231
7231
|
state: [],
|
7232
|
-
hotState:
|
7232
|
+
hotState: p
|
7233
7233
|
}), A = {
|
7234
7234
|
_p: a,
|
7235
7235
|
$id: e,
|
7236
7236
|
$onAction: addSubscription.bind(null, g),
|
7237
|
-
$patch:
|
7237
|
+
$patch: m,
|
7238
7238
|
$reset: b,
|
7239
7239
|
$subscribe(D, I = {}) {
|
7240
7240
|
const M = addSubscription(d, D, I.detached, () => P()), P = s.run(() => watch(() => a.state.value[e], (N) => {
|
@@ -7250,7 +7250,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7250
7250
|
}, k = reactive(assign$1(
|
7251
7251
|
process.env.NODE_ENV !== "production" && IS_CLIENT ? {
|
7252
7252
|
_customProperties: markRaw(/* @__PURE__ */ new Set()),
|
7253
|
-
_hmrPayload:
|
7253
|
+
_hmrPayload: E
|
7254
7254
|
} : {},
|
7255
7255
|
A
|
7256
7256
|
));
|
@@ -7259,19 +7259,19 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7259
7259
|
for (const D in R) {
|
7260
7260
|
const I = R[D];
|
7261
7261
|
if (isRef(I) && !isComputed(I) || isReactive(I))
|
7262
|
-
process.env.NODE_ENV !== "production" && n ? set(
|
7262
|
+
process.env.NODE_ENV !== "production" && n ? set(p.value, D, toRef(R, D)) : l || (y && shouldHydrate(I) && (isRef(I) ? I.value = y[D] : mergeReactiveObjects(I, y[D])), a.state.value[e][D] = I), process.env.NODE_ENV !== "production" && E.state.push(D);
|
7263
7263
|
else if (typeof I == "function") {
|
7264
|
-
const M = process.env.NODE_ENV !== "production" && n ? I :
|
7265
|
-
R[D] = M, process.env.NODE_ENV !== "production" && (
|
7264
|
+
const M = process.env.NODE_ENV !== "production" && n ? I : T(D, I);
|
7265
|
+
R[D] = M, process.env.NODE_ENV !== "production" && (E.actions[D] = I), o.actions[D] = I;
|
7266
7266
|
} else
|
7267
|
-
process.env.NODE_ENV !== "production" && isComputed(I) && (
|
7267
|
+
process.env.NODE_ENV !== "production" && isComputed(I) && (E.getters[D] = l ? r.getters[D] : I, IS_CLIENT && (R._getters || (R._getters = markRaw([]))).push(D));
|
7268
7268
|
}
|
7269
7269
|
if (assign$1(k, R), assign$1(toRaw(k), R), Object.defineProperty(k, "$state", {
|
7270
|
-
get: () => process.env.NODE_ENV !== "production" && n ?
|
7270
|
+
get: () => process.env.NODE_ENV !== "production" && n ? p.value : a.state.value[e],
|
7271
7271
|
set: (D) => {
|
7272
7272
|
if (process.env.NODE_ENV !== "production" && n)
|
7273
7273
|
throw new Error("cannot set hotState");
|
7274
|
-
|
7274
|
+
m((I) => {
|
7275
7275
|
assign$1(I, D);
|
7276
7276
|
});
|
7277
7277
|
}
|
@@ -7290,7 +7290,7 @@ function createSetupStore(e, t, r = {}, a, n) {
|
|
7290
7290
|
});
|
7291
7291
|
for (const M in I._hmrPayload.actions) {
|
7292
7292
|
const P = I[M];
|
7293
|
-
set(k, M,
|
7293
|
+
set(k, M, T(M, P));
|
7294
7294
|
}
|
7295
7295
|
for (const M in I._hmrPayload.getters) {
|
7296
7296
|
const P = I._hmrPayload.getters[M], N = l ? computed(() => (setActivePinia(a), P.call(k, k))) : P;
|
@@ -7946,12 +7946,12 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
7946
7946
|
function y(C) {
|
7947
7947
|
g(C), d();
|
7948
7948
|
}
|
7949
|
-
function
|
7950
|
-
C.stopPropagation(), C.preventDefault(), d(), !(C instanceof MouseEvent && C.which !== 1) && (s = C.pageX, l = C.pageY, a = e.kgWidth, n = e.kgHeight, o =
|
7949
|
+
function p(C) {
|
7950
|
+
C.stopPropagation(), C.preventDefault(), d(), !(C instanceof MouseEvent && C.which !== 1) && (s = C.pageX, l = C.pageY, a = e.kgWidth, n = e.kgHeight, o = m(document.documentElement, "mousemove", v), i = m(document.documentElement, "mouseup", y));
|
7951
7951
|
}
|
7952
|
-
function
|
7953
|
-
return C.addEventListener(
|
7954
|
-
remove: () => C.removeEventListener(
|
7952
|
+
function m(C, T, E) {
|
7953
|
+
return C.addEventListener(T, E), {
|
7954
|
+
remove: () => C.removeEventListener(T, E)
|
7955
7955
|
};
|
7956
7956
|
}
|
7957
7957
|
function b(C) {
|
@@ -7965,7 +7965,7 @@ const KgModal_Close = "", getProps$A = () => ({
|
|
7965
7965
|
}, [createVNode("div", {
|
7966
7966
|
class: "kg-resizable-handle",
|
7967
7967
|
onClick: b,
|
7968
|
-
onMousedown:
|
7968
|
+
onMousedown: p
|
7969
7969
|
}, [createVNode("div", {
|
7970
7970
|
class: "kg-resizable-handle-line"
|
7971
7971
|
}, null)]), (C = r.default) == null ? void 0 : C.call(r)]);
|
@@ -8123,12 +8123,12 @@ function createStore(e, t, r) {
|
|
8123
8123
|
var g = slice(arguments, 0), v = this;
|
8124
8124
|
function y() {
|
8125
8125
|
if (!!u)
|
8126
|
-
return each$6(arguments, function(
|
8127
|
-
g[b] =
|
8126
|
+
return each$6(arguments, function(m, b) {
|
8127
|
+
g[b] = m;
|
8128
8128
|
}), u.apply(v, g);
|
8129
8129
|
}
|
8130
|
-
var
|
8131
|
-
return i.apply(v,
|
8130
|
+
var p = [y].concat(g);
|
8131
|
+
return i.apply(v, p);
|
8132
8132
|
};
|
8133
8133
|
},
|
8134
8134
|
_serialize: function(i) {
|
@@ -9138,19 +9138,19 @@ const useKgVarStore = () => (store$7 || (store$7 = defineStore("KgVar", {
|
|
9138
9138
|
varLookups: g,
|
9139
9139
|
varConfigs: v,
|
9140
9140
|
varVariableInputs: y,
|
9141
|
-
varPossibilities:
|
9142
|
-
varButtons:
|
9141
|
+
varPossibilities: p,
|
9142
|
+
varButtons: m,
|
9143
9143
|
varButtonConfig: b,
|
9144
9144
|
varSubmitConfig: C,
|
9145
|
-
varSubmitFields:
|
9146
|
-
varProfile:
|
9145
|
+
varSubmitFields: T,
|
9146
|
+
varProfile: E,
|
9147
9147
|
varProfileConfig: A,
|
9148
9148
|
varGrid: k,
|
9149
9149
|
varGridConfig: R
|
9150
9150
|
} = await GetAll({ params: { frm_id: e } });
|
9151
|
-
this.varCatalogMap.set(e, d != null ? d : []), this.varLookupMap.set(e, g != null ? g : []), this.varPossibilityMap.set(e,
|
9152
|
-
varProfile:
|
9153
|
-
currentVarProfileMasterID: (s = (n = ((t =
|
9151
|
+
this.varCatalogMap.set(e, d != null ? d : []), this.varLookupMap.set(e, g != null ? g : []), this.varPossibilityMap.set(e, p != null ? p : []), this.varVariableConfigMap.set(e, v != null ? v : []), this.varVariableInputMap.set(e, y != null ? y : []), this.varButtonMap.set(e, transformVarButtons(m)), this.varButtonConfigMap.set(e, transformVarButtonConfig(b != null ? b : null)), this.varSubmitConfigMap.set(e, transformVarSubmitConfig(C)), this.varSubmitFieldMap.set(e, transformVarSubmitFields(T)), this.varProfileConfigMap.set(e, transformVarProfileConfig(A != null ? A : null)), this.varProfileMap.set(e, {
|
9152
|
+
varProfile: E != null ? E : null,
|
9153
|
+
currentVarProfileMasterID: (s = (n = ((t = E == null ? void 0 : E.varProfileMasters) == null ? void 0 : t.find((D) => D.def_flg === 1)) || ((r = E == null ? void 0 : E.varProfileMasters) == null ? void 0 : r.find((D) => D.cust_lvl === KG_CUSTOM_LEVEL.L0)) || ((a = E == null ? void 0 : E.varProfileMasters) == null ? void 0 : a.find(() => !0))) == null ? void 0 : n.id) != null ? s : null
|
9154
9154
|
}), this.varGridConfigMap.set(e, transformVarGridConfig(R != null ? R : null)), this.varGridMap.set(e, {
|
9155
9155
|
varGrid: transformVarGridDTO(k),
|
9156
9156
|
currentVarGridMasterID: (u = (c = ((l = k == null ? void 0 : k.varGridMasters) == null ? void 0 : l.find((D) => D.def_flg === 1)) || ((o = k == null ? void 0 : k.varGridMasters) == null ? void 0 : o.find((D) => D.cust_lvl === KG_CUSTOM_LEVEL.L0)) || ((i = k == null ? void 0 : k.varGridMasters) == null ? void 0 : i.find(() => !0))) == null ? void 0 : c.id) != null ? u : null
|
@@ -9363,7 +9363,7 @@ function useKgVar(e, t, r = 0) {
|
|
9363
9363
|
const d = (z) => computed(() => {
|
9364
9364
|
var Z, ee, se;
|
9365
9365
|
return (se = (ee = (Z = u.getVarCatalog(c, z)) == null ? void 0 : Z.var_text) != null ? ee : z) != null ? se : "";
|
9366
|
-
}), g = computed(() => u.isRetrieving(c)), v = computed(() => u.isRetrievingVarProfileMaster(c)), y = computed(() => u.isRetrievingVarGridMaster(c)),
|
9366
|
+
}), g = computed(() => u.isRetrieving(c)), v = computed(() => u.isRetrievingVarProfileMaster(c)), y = computed(() => u.isRetrievingVarGridMaster(c)), p = computed(() => u.isCreating(c)), m = computed(() => u.isCreatingRequesting(c)), b = computed(() => u.isUpdating(c)), C = computed(() => u.isUpdatingRequesting(c)), T = computed(() => u.isCopying(c)), E = computed(() => u.isCopyingRequesting(c)), A = computed(() => u.isDeleting(c)), k = computed(() => u.isDeletingRequesting(c)), R = computed(() => u.isOtherRequesting(c)), D = computed(() => u.getVarButtons(c)), I = computed(() => u.getVarButtonSearch(c)), M = computed(() => u.getVarButtonCreate(c)), P = computed(() => u.getVarButtonUpdate(c)), N = computed(() => u.getVarButtonCopy(c)), U = computed(() => u.getVarButtonDelete(c)), w = computed(() => u.getVarProfileMasters(c)), O = computed(() => u.getCurrentVarProfileMaster(c)), V = computed(() => u.getCurrentVarProfileMasterID(c)), G = computed(() => {
|
9367
9367
|
var z, Z;
|
9368
9368
|
return (Z = (z = O.value) == null ? void 0 : z.varProfileDetails) != null ? Z : null;
|
9369
9369
|
}), F = computed(() => u.getVarGridConfig(c)), L = computed(() => u.getVarGridMasters(c)), B = computed(() => u.getCurrentVarGridMaster(c)), Y = computed(() => u.getSystemVarGridDetails(c)), Q = computed(() => u.getCurrentVarGridDetails(c));
|
@@ -9373,12 +9373,12 @@ function useKgVar(e, t, r = 0) {
|
|
9373
9373
|
isRetrieving: g,
|
9374
9374
|
isRetrievingVarProfileMaster: v,
|
9375
9375
|
isRetrievingVarGridMaster: y,
|
9376
|
-
isCreating:
|
9377
|
-
isCreatingRequesting:
|
9376
|
+
isCreating: p,
|
9377
|
+
isCreatingRequesting: m,
|
9378
9378
|
isUpdating: b,
|
9379
9379
|
isUpdatingRequesting: C,
|
9380
|
-
isCopying:
|
9381
|
-
isCopyingRequesting:
|
9380
|
+
isCopying: T,
|
9381
|
+
isCopyingRequesting: E,
|
9382
9382
|
isDeleting: A,
|
9383
9383
|
isDeletingRequesting: k,
|
9384
9384
|
isOtherRequesting: R,
|
@@ -9420,7 +9420,7 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9420
9420
|
}) {
|
9421
9421
|
provide(DI_KG_VAR__KG_PROPS, computed(() => e.kgProps)), provide(DI_KG_VAR__KG_SLOTS, e.kgSlots);
|
9422
9422
|
const r = useKgVar(), a = computed(() => r.store.getVarSubmitConfig(r.formID)), n = computed(() => r.store.getVarProfileConfig(r.formID)), s = computed(() => r.store.getVarButtonConfig(r.formID)), l = computed(() => {
|
9423
|
-
var g, v, y,
|
9423
|
+
var g, v, y, p;
|
9424
9424
|
switch (!0) {
|
9425
9425
|
case r.isCreating.value:
|
9426
9426
|
return ((g = a.value) == null ? void 0 : g.crt_flg) !== 0;
|
@@ -9429,7 +9429,7 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9429
9429
|
case r.isCopying.value:
|
9430
9430
|
return ((y = a.value) == null ? void 0 : y.cpy_flg) !== 0;
|
9431
9431
|
case r.isDeleting.value:
|
9432
|
-
return ((
|
9432
|
+
return ((p = a.value) == null ? void 0 : p.del_flg) !== 0;
|
9433
9433
|
}
|
9434
9434
|
return !1;
|
9435
9435
|
}), o = computed(() => {
|
@@ -9470,20 +9470,20 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9470
9470
|
const a = inject(KG_DI_HOST_FORM_ID, ""), n = useKgVar(a), s = useKgForm(n.formID), l = inject(KG_DI_VAR_NAME, ""), o = inject(KG_DI_LOOKUP_ID, ""), i = inject(DI_FORM_MODEL, computed(() => ({})));
|
9471
9471
|
useKgVar(o, !0, n.store.getFormLevel(n.formID) + 1);
|
9472
9472
|
const c = useKgTable(o), u = computed(() => n.store.getVarLookup(n.formID, l)), d = computed(() => {
|
9473
|
-
var
|
9474
|
-
return ((
|
9473
|
+
var p;
|
9474
|
+
return ((p = u == null ? void 0 : u.value) == null ? void 0 : p.mult_flg) === 1;
|
9475
9475
|
}), g = computed(() => {
|
9476
|
-
var
|
9477
|
-
return (
|
9476
|
+
var p, m;
|
9477
|
+
return (m = (p = u == null ? void 0 : u.value) == null ? void 0 : p.ret_fld) != null ? m : "";
|
9478
9478
|
});
|
9479
9479
|
c.onRowDoubleClick(async () => (await y(), !1));
|
9480
9480
|
function v() {
|
9481
9481
|
r("update:visible", !1);
|
9482
9482
|
}
|
9483
9483
|
async function y() {
|
9484
|
-
var
|
9484
|
+
var p, m, b, C, T, E, A;
|
9485
9485
|
if (d.value) {
|
9486
|
-
const k = (
|
9486
|
+
const k = (m = (p = c.selectedRows) == null ? void 0 : p.value) != null ? m : [], R = (b = k.map((I) => I[g.value])) != null ? b : [];
|
9487
9487
|
await s.store.emit(s.formID, "lookupBeforeOk", {
|
9488
9488
|
var_nam: l,
|
9489
9489
|
isMultiple: !0,
|
@@ -9497,7 +9497,7 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9497
9497
|
rows: k
|
9498
9498
|
}), r("update:visible", !1));
|
9499
9499
|
} else {
|
9500
|
-
const k = (
|
9500
|
+
const k = (E = (T = (C = c.selectedRows) == null ? void 0 : C.value) == null ? void 0 : T[0]) != null ? E : null, R = (A = k == null ? void 0 : k[g.value]) != null ? A : "";
|
9501
9501
|
await s.store.emit(s.formID, "lookupBeforeOk", {
|
9502
9502
|
var_nam: l,
|
9503
9503
|
isMultiple: !1,
|
@@ -9513,13 +9513,13 @@ const DI_KG_VAR__KG_SLOTS = Symbol("DI_KG_VAR__KG_SLOTS"), DI_KG_VAR__KG_PROPS =
|
|
9513
9513
|
}
|
9514
9514
|
}
|
9515
9515
|
return () => {
|
9516
|
-
var
|
9516
|
+
var p, m;
|
9517
9517
|
return createVNode(KgModal, {
|
9518
9518
|
visible: e.visible,
|
9519
9519
|
title: n.t(l).value,
|
9520
9520
|
destroyOnClose: !0,
|
9521
9521
|
okButtonProps: {
|
9522
|
-
disabled: ((
|
9522
|
+
disabled: ((m = (p = c.selectedRows.value) == null ? void 0 : p.length) != null ? m : 0) === 0
|
9523
9523
|
},
|
9524
9524
|
wrapClassName: "kg-form-item-addon-lookup-modal",
|
9525
9525
|
onCancel: v,
|
@@ -9614,7 +9614,7 @@ function _useRules(e) {
|
|
9614
9614
|
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));
|
9615
9615
|
return {
|
9616
9616
|
rules: computed(() => {
|
9617
|
-
var i, c, u, d, g, v, y,
|
9617
|
+
var i, c, u, d, g, v, y, p, m, b;
|
9618
9618
|
let o = [];
|
9619
9619
|
switch (e.kgContext) {
|
9620
9620
|
case KG_FORM_CONTEXT.SEARCH:
|
@@ -9656,16 +9656,16 @@ function _useRules(e) {
|
|
9656
9656
|
case KG_VAR_INPUT__DATA_TYPE.NUMBER:
|
9657
9657
|
{
|
9658
9658
|
const C = (y = n.value) == null ? void 0 : y.min;
|
9659
|
-
isNil(C) || (((
|
9660
|
-
validator: (
|
9659
|
+
isNil(C) || (((p = n.value) == null ? void 0 : p.min_include_flg) === 1 ? o.push({
|
9660
|
+
validator: (E, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) < C ? Promise.reject(t.t("kg.KgFormItem.mustGTE", [C])) : Promise.resolve()
|
9661
9661
|
}) : o.push({
|
9662
|
-
validator: (
|
9662
|
+
validator: (E, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) <= C ? Promise.reject(t.t("kg.KgFormItem.mustGT", [C])) : Promise.resolve()
|
9663
9663
|
}));
|
9664
|
-
const
|
9665
|
-
isNil(
|
9666
|
-
validator: (
|
9664
|
+
const T = (m = n.value) == null ? void 0 : m.max;
|
9665
|
+
isNil(T) || (((b = n.value) == null ? void 0 : b.max_include_flg) === 1 ? o.push({
|
9666
|
+
validator: (E, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) > T ? Promise.reject(t.t("kg.KgFormItem.mustLTE", [T])) : Promise.resolve()
|
9667
9667
|
}) : o.push({
|
9668
|
-
validator: (
|
9668
|
+
validator: (E, A) => A == null || A === "" || typeof A == "string" && A.trim() === "" ? Promise.resolve() : Number(A) >= T ? Promise.reject(t.t("kg.KgFormItem.mustLT", [T])) : Promise.resolve()
|
9669
9669
|
}));
|
9670
9670
|
}
|
9671
9671
|
break;
|
@@ -9676,8 +9676,8 @@ function _useRules(e) {
|
|
9676
9676
|
}
|
9677
9677
|
function useKgFormItem(e) {
|
9678
9678
|
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(() => {
|
9679
|
-
var v, y,
|
9680
|
-
const o = ((v = n.value) == null ? void 0 : v.ctrl_typ) || KG_FORM_ITEM_TYPE.INPUT, i = (y = n.value) == null ? void 0 : y.prf_ctrl_typ, c = (
|
9679
|
+
var v, y, p, m, b, C;
|
9680
|
+
const o = ((v = n.value) == null ? void 0 : v.ctrl_typ) || KG_FORM_ITEM_TYPE.INPUT, i = (y = n.value) == null ? void 0 : y.prf_ctrl_typ, c = (p = n.value) == null ? void 0 : p.crt_ctrl_typ, u = (m = n.value) == null ? void 0 : m.upt_ctrl_typ, d = (b = n.value) == null ? void 0 : b.cpy_ctrl_typ, g = (C = n.value) == null ? void 0 : C.del_ctrl_typ;
|
9681
9681
|
switch (r) {
|
9682
9682
|
case KG_FORM_CONTEXT.SEARCH:
|
9683
9683
|
return i || o;
|
@@ -9695,9 +9695,9 @@ function useKgFormItem(e) {
|
|
9695
9695
|
}
|
9696
9696
|
return o;
|
9697
9697
|
}), l = computed(() => {
|
9698
|
-
var y,
|
9698
|
+
var y, p, m, b, C, T;
|
9699
9699
|
let o;
|
9700
|
-
const i = (y = n.value) == null ? void 0 : y.ctrl_prop, c = (
|
9700
|
+
const i = (y = n.value) == null ? void 0 : y.ctrl_prop, c = (p = n.value) == null ? void 0 : p.prf_ctrl_prop, u = (m = n.value) == null ? void 0 : m.crt_ctrl_prop, d = (b = n.value) == null ? void 0 : b.upt_ctrl_prop, g = (C = n.value) == null ? void 0 : C.cpy_ctrl_prop, v = (T = n.value) == null ? void 0 : T.del_ctrl_prop;
|
9701
9701
|
switch (r) {
|
9702
9702
|
case KG_FORM_CONTEXT.SEARCH:
|
9703
9703
|
o = c || i;
|
@@ -9730,101 +9730,104 @@ function useKgFormItemSelect() {
|
|
9730
9730
|
controlType: n,
|
9731
9731
|
controlProperties: s
|
9732
9732
|
} = useKgFormItem(), l = ref([]), o = computed(() => {
|
9733
|
-
var
|
9734
|
-
return (
|
9733
|
+
var g, v;
|
9734
|
+
return (v = (g = a.value) == null ? void 0 : g.val_clm) != null ? v : "";
|
9735
9735
|
}), i = computed(() => {
|
9736
|
-
var g;
|
9737
|
-
|
9738
|
-
|
9739
|
-
|
9740
|
-
|
9741
|
-
|
9742
|
-
|
9743
|
-
|
9744
|
-
|
9745
|
-
|
9736
|
+
var g, v;
|
9737
|
+
return (v = (g = a.value) == null ? void 0 : g.lbl_clm) != null ? v : "";
|
9738
|
+
}), c = computed(() => {
|
9739
|
+
var v;
|
9740
|
+
let g = KgVarUtil.parseCommandParameter((v = a.value) == null ? void 0 : v.cmd_prm);
|
9741
|
+
return g = mapValues(g, (y) => {
|
9742
|
+
var m, b;
|
9743
|
+
let p = y;
|
9744
|
+
if (typeof y == "string" && y.startsWith("{") && y.endsWith("}")) {
|
9745
|
+
let C = y.slice(1, -1), T = "";
|
9746
|
+
if (C.includes(".")) {
|
9747
|
+
const E = C.split(".");
|
9748
|
+
C = E[0], T = E[1];
|
9746
9749
|
}
|
9747
|
-
t.value &&
|
9750
|
+
t.value && C in t.value && (T ? p = (b = (m = t.value[`${C}_obj`]) == null ? void 0 : m[T]) != null ? b : void 0 : p = t.value[C], p || (p = "__KG__FORM_ITEM_SELECT__PID"));
|
9748
9751
|
}
|
9749
|
-
return
|
9750
|
-
}),
|
9752
|
+
return p;
|
9753
|
+
}), g;
|
9751
9754
|
});
|
9752
|
-
async function
|
9753
|
-
var
|
9754
|
-
let
|
9755
|
-
const
|
9756
|
-
if (!
|
9755
|
+
async function u() {
|
9756
|
+
var C, T, E, A, k, R, D, I;
|
9757
|
+
let g = [];
|
9758
|
+
const v = (C = a.value) == null ? void 0 : C.cmd, y = (E = (T = a.value) == null ? void 0 : T.cmd_method) != null ? E : "GET", p = (k = (A = a.value) == null ? void 0 : A.val_clm) != null ? k : "", m = (D = (R = a.value) == null ? void 0 : R.lbl_clm) != null ? D : "";
|
9759
|
+
if (!v || !p || !m) {
|
9757
9760
|
KgLogger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF.", {
|
9758
9761
|
frm_id: r.formID,
|
9759
9762
|
var_nam: e,
|
9760
|
-
cmd:
|
9761
|
-
val_clm:
|
9763
|
+
cmd: v,
|
9764
|
+
val_clm: p,
|
9762
9765
|
lbl_clm: m
|
9763
9766
|
});
|
9764
9767
|
return;
|
9765
9768
|
}
|
9766
|
-
let
|
9769
|
+
let b = null;
|
9767
9770
|
try {
|
9768
|
-
|
9769
|
-
url:
|
9770
|
-
method:
|
9771
|
-
params:
|
9771
|
+
b = await ((I = httpClient()) == null ? void 0 : I.request({
|
9772
|
+
url: v,
|
9773
|
+
method: y,
|
9774
|
+
params: c.value
|
9772
9775
|
}));
|
9773
9776
|
} catch {
|
9774
9777
|
}
|
9775
|
-
if (!isObjectLike(
|
9776
|
-
|
9778
|
+
if (!isObjectLike(b))
|
9779
|
+
g = [];
|
9777
9780
|
else
|
9778
9781
|
switch (!0) {
|
9779
|
-
case isArrayLike(
|
9780
|
-
|
9782
|
+
case isArrayLike(b):
|
9783
|
+
g = d(b);
|
9781
9784
|
break;
|
9782
|
-
case (
|
9783
|
-
|
9785
|
+
case (b && "total" in b && "records" in b):
|
9786
|
+
g = d(b.records);
|
9784
9787
|
break;
|
9785
9788
|
}
|
9786
|
-
if (
|
9787
|
-
const
|
9788
|
-
(!(
|
9789
|
+
if (g.length > 0) {
|
9790
|
+
const M = g[0];
|
9791
|
+
(!(p in M) || !(m in M)) && KgLogger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF, \u6570\u636E\u5217(val_clm)\u6216\u663E\u793A\u5217(lbl_clm)\u6709\u8BEF.", {
|
9789
9792
|
frm_id: r.formID,
|
9790
9793
|
var_nam: e,
|
9791
|
-
cmd:
|
9792
|
-
val_clm:
|
9794
|
+
cmd: v,
|
9795
|
+
val_clm: p,
|
9793
9796
|
lbl_clm: m,
|
9794
|
-
\u6240\u6709\u5217: Object.keys(
|
9797
|
+
\u6240\u6709\u5217: Object.keys(M)
|
9795
9798
|
});
|
9796
9799
|
}
|
9797
|
-
l.value =
|
9800
|
+
l.value = g;
|
9798
9801
|
}
|
9799
|
-
function
|
9800
|
-
var
|
9801
|
-
if (!
|
9802
|
+
function d(g) {
|
9803
|
+
var p, m, b, C, T;
|
9804
|
+
if (!g)
|
9802
9805
|
return [];
|
9803
|
-
const
|
9804
|
-
switch (
|
9806
|
+
const v = (m = (p = a.value) == null ? void 0 : p.val_clm) != null ? m : "", y = (C = (b = a.value) == null ? void 0 : b.val_data_type) != null ? C : "string";
|
9807
|
+
switch (y) {
|
9805
9808
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
9806
|
-
|
9807
|
-
E[
|
9809
|
+
g.forEach((E) => {
|
9810
|
+
E[v] = String(E[v]);
|
9808
9811
|
});
|
9809
9812
|
break;
|
9810
9813
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER:
|
9811
|
-
|
9812
|
-
let
|
9813
|
-
Number.isNaN(
|
9814
|
+
g.forEach((E) => {
|
9815
|
+
let A = Number(E[v]);
|
9816
|
+
Number.isNaN(A) && (A = E[v], KgLogger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${E[v]} \u8F6C\u6362\u4E3A ${y} \u7C7B\u578B`, {
|
9814
9817
|
frm_id: r.formID,
|
9815
9818
|
var_nam: e,
|
9816
9819
|
VarPossibility: a.value
|
9817
|
-
})), E[
|
9820
|
+
})), E[v] = A;
|
9818
9821
|
});
|
9819
9822
|
break;
|
9820
9823
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
9821
|
-
|
9822
|
-
let
|
9823
|
-
String(E[
|
9824
|
+
g.forEach((E) => {
|
9825
|
+
let A;
|
9826
|
+
String(E[v]).toLowerCase() === "true" ? A = !0 : String(E[v]).toLowerCase() === "false" ? A = !1 : (A = E[v], KgLogger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${E[v]} \u8F6C\u6362\u4E3A ${y} \u7C7B\u578B`, {
|
9824
9827
|
frm_id: r.formID,
|
9825
9828
|
var_nam: e,
|
9826
9829
|
VarPossibility: a.value
|
9827
|
-
})), E[
|
9830
|
+
})), E[v] = A;
|
9828
9831
|
});
|
9829
9832
|
break;
|
9830
9833
|
}
|
@@ -9832,23 +9835,24 @@ function useKgFormItemSelect() {
|
|
9832
9835
|
case KG_FORM_ITEM_TYPE.CHECKBOX_GROUP:
|
9833
9836
|
{
|
9834
9837
|
const E = s;
|
9835
|
-
if ((
|
9836
|
-
return
|
9837
|
-
var
|
9838
|
-
return !((
|
9838
|
+
if ((T = E.value) != null && T.excludeValues)
|
9839
|
+
return g.filter((A) => {
|
9840
|
+
var k;
|
9841
|
+
return !((k = E.value.excludeValues) != null && k.includes(A[v]));
|
9839
9842
|
});
|
9840
9843
|
}
|
9841
9844
|
break;
|
9842
9845
|
}
|
9843
|
-
return
|
9846
|
+
return g;
|
9844
9847
|
}
|
9845
9848
|
return {
|
9846
9849
|
varPossibility: a,
|
9847
|
-
commandParameter:
|
9850
|
+
commandParameter: c,
|
9848
9851
|
val_clm: o,
|
9852
|
+
lbl_clm: i,
|
9849
9853
|
datas: l,
|
9850
|
-
retrieveDatas:
|
9851
|
-
transformDatas:
|
9854
|
+
retrieveDatas: u,
|
9855
|
+
transformDatas: d
|
9852
9856
|
};
|
9853
9857
|
}
|
9854
9858
|
function _isSlot$a(e) {
|
@@ -9873,12 +9877,12 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9873
9877
|
} = useKgFormItemSelect(), d = ref(!1), g = ref(!1);
|
9874
9878
|
watch(o, () => v(), {
|
9875
9879
|
immediate: !0
|
9876
|
-
}), watch([() => e.value, c], ([
|
9877
|
-
const C = get(
|
9880
|
+
}), watch([() => e.value, c], ([m, b]) => {
|
9881
|
+
const C = get(m, "length", 0);
|
9878
9882
|
if (C > 0 && b.length > 0) {
|
9879
|
-
const
|
9880
|
-
if (
|
9881
|
-
r("update:value",
|
9883
|
+
const T = intersection$1(m, b == null ? void 0 : b.map((E) => E[i.value]));
|
9884
|
+
if (T.length < C) {
|
9885
|
+
r("update:value", T);
|
9882
9886
|
return;
|
9883
9887
|
}
|
9884
9888
|
}
|
@@ -9897,18 +9901,18 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9897
9901
|
immediate: !0
|
9898
9902
|
});
|
9899
9903
|
async function v() {
|
9900
|
-
var
|
9901
|
-
!((
|
9904
|
+
var m, b;
|
9905
|
+
!((m = l.value) != null && m.id) || (await u(), r("kgCheckboxGroupDatasChange", c.value), r("update:value", intersection$1((b = c.value) == null ? void 0 : b.map((C) => C[i.value]), e.value)));
|
9902
9906
|
}
|
9903
|
-
function y(
|
9904
|
-
var b, C,
|
9905
|
-
|
9907
|
+
function y(m) {
|
9908
|
+
var b, C, T;
|
9909
|
+
m.target.checked ? p((C = (b = c.value) == null ? void 0 : b.map((E) => E[i.value])) != null ? C : []) : p([]), g.value = !1, (T = n.value) == null || T.validate(e.kgVarName);
|
9906
9910
|
}
|
9907
|
-
function m
|
9908
|
-
r("update:value",
|
9911
|
+
function p(m) {
|
9912
|
+
r("update:value", m), r("kgChange", m);
|
9909
9913
|
}
|
9910
9914
|
return () => {
|
9911
|
-
let
|
9915
|
+
let m, b;
|
9912
9916
|
return createVNode("div", {
|
9913
9917
|
class: "kg-form-item-checkbox-group"
|
9914
9918
|
}, [createVNode(Form.ItemRest, null, {
|
@@ -9917,19 +9921,19 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9917
9921
|
"onUpdate:checked": (C) => d.value = C,
|
9918
9922
|
indeterminate: g.value,
|
9919
9923
|
onChange: y
|
9920
|
-
}, _isSlot$a(
|
9921
|
-
default: () => [
|
9924
|
+
}, _isSlot$a(m = a.t("kg.selectAll")) ? m : {
|
9925
|
+
default: () => [m]
|
9922
9926
|
})]
|
9923
9927
|
}), createVNode(Divider, null, null), createVNode(Checkbox.Group, {
|
9924
9928
|
value: e.value,
|
9925
|
-
"onUpdate:value":
|
9929
|
+
"onUpdate:value": p
|
9926
9930
|
}, {
|
9927
9931
|
default: () => [createVNode(Row, {
|
9928
9932
|
gutter: 12
|
9929
9933
|
}, _isSlot$a(b = c.value.map((C) => {
|
9930
|
-
var
|
9934
|
+
var T, E;
|
9931
9935
|
return createVNode(Col, {
|
9932
|
-
span: (
|
9936
|
+
span: (E = (T = s.value) == null ? void 0 : T.span) != null ? E : 24
|
9933
9937
|
}, {
|
9934
9938
|
default: () => [createVNode(Checkbox, {
|
9935
9939
|
value: C[i.value],
|
@@ -10104,8 +10108,8 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10104
10108
|
"kg-value": g[l.value]
|
10105
10109
|
}, {
|
10106
10110
|
default: () => {
|
10107
|
-
var
|
10108
|
-
return [g[(
|
10111
|
+
var p, m;
|
10112
|
+
return [g[(m = (p = n.value) == null ? void 0 : p.lbl_clm) != null ? m : ""]];
|
10109
10113
|
}
|
10110
10114
|
})]
|
10111
10115
|
});
|
@@ -10127,74 +10131,75 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10127
10131
|
varPossibility: n,
|
10128
10132
|
commandParameter: s,
|
10129
10133
|
val_clm: l,
|
10130
|
-
|
10131
|
-
|
10134
|
+
lbl_clm: o,
|
10135
|
+
datas: i,
|
10136
|
+
retrieveDatas: c
|
10132
10137
|
} = useKgFormItemSelect();
|
10133
|
-
watch(s, () =>
|
10138
|
+
watch(s, () => u(), {
|
10134
10139
|
immediate: !0
|
10135
10140
|
});
|
10136
|
-
async function
|
10137
|
-
var
|
10138
|
-
if (!!((
|
10139
|
-
switch (await
|
10141
|
+
async function u() {
|
10142
|
+
var v;
|
10143
|
+
if (!!((v = n.value) != null && v.id))
|
10144
|
+
switch (await c(), r("kgSelectDatasChange", i.value), e.kgMode) {
|
10140
10145
|
case "multiple": {
|
10141
10146
|
if (Array.isArray(e.value)) {
|
10142
|
-
const
|
10143
|
-
|
10147
|
+
const y = e.value.filter((p) => i.value.find((m) => m[l.value] === p));
|
10148
|
+
y.length > 0 ? r("update:value", y) : r("update:value", []);
|
10144
10149
|
}
|
10145
10150
|
break;
|
10146
10151
|
}
|
10147
10152
|
default:
|
10148
|
-
|
10153
|
+
i.value.find((y) => y[l.value] === e.value) || r("update:value", void 0);
|
10149
10154
|
break;
|
10150
10155
|
}
|
10151
10156
|
}
|
10152
|
-
function
|
10153
|
-
var
|
10157
|
+
function d(v) {
|
10158
|
+
var y, p;
|
10154
10159
|
switch (e.kgMode) {
|
10155
10160
|
case "multiple": {
|
10156
|
-
if (Array.isArray(
|
10157
|
-
const m = (
|
10161
|
+
if (Array.isArray(v)) {
|
10162
|
+
const m = (y = toRaw(i.value.filter((b) => v.includes(b[l.value])))) != null ? y : null;
|
10158
10163
|
r("kgSelectChange", m), a.value[`${e.kgVarName}_obj`] = m;
|
10159
10164
|
}
|
10160
10165
|
break;
|
10161
10166
|
}
|
10162
10167
|
default: {
|
10163
|
-
const m = (
|
10168
|
+
const m = (p = toRaw(i.value.find((b) => b[l.value] === v))) != null ? p : null;
|
10164
10169
|
r("kgSelectChange", m), a.value[`${e.kgVarName}_obj`] = m;
|
10165
10170
|
break;
|
10166
10171
|
}
|
10167
10172
|
}
|
10168
10173
|
}
|
10169
|
-
function
|
10170
|
-
r("update:value",
|
10174
|
+
function g(v) {
|
10175
|
+
r("update:value", v), r("kgChange", v);
|
10171
10176
|
}
|
10172
10177
|
return () => {
|
10173
|
-
var
|
10178
|
+
var v;
|
10174
10179
|
return createVNode(Select, {
|
10175
10180
|
value: e.value,
|
10176
|
-
"onUpdate:value":
|
10181
|
+
"onUpdate:value": g,
|
10177
10182
|
id: t.id,
|
10178
10183
|
disabled: e.kgDisabled,
|
10179
10184
|
allowClear: e.kgAllowClear,
|
10180
10185
|
mode: e.kgMode,
|
10181
10186
|
maxTagCount: "responsive",
|
10182
|
-
onChange: u,
|
10183
10187
|
placeholder: e.kgPlaceholder,
|
10184
|
-
|
10188
|
+
showSearch: !0,
|
10189
|
+
filterOption: (y, p) => (p == null ? void 0 : p.value) !== null && (p == null ? void 0 : p.value) !== void 0 && String(p.value).toLowerCase().includes(y.toLowerCase()) || (p == null ? void 0 : p.label) !== null && (p == null ? void 0 : p.label) !== void 0 && String(p.label).toLowerCase().includes(y.toLowerCase()),
|
10185
10190
|
dropdownClassName: e.kgMode === "multiple" ? "kg-form-item-select-dropdown kg-form-item-multi-select-dropdown" : "kg-form-item-select-dropdown",
|
10186
|
-
"kg-
|
10191
|
+
class: "kg-form-item-select",
|
10192
|
+
onChange: d,
|
10193
|
+
"kg-cmd": (v = n.value) == null ? void 0 : v.cmd,
|
10187
10194
|
"kg-val_clm": l.value,
|
10188
|
-
"kg-lbl_clm":
|
10195
|
+
"kg-lbl_clm": o.value
|
10189
10196
|
}, {
|
10190
|
-
default: () =>
|
10197
|
+
default: () => i.value.map((y) => createVNode(Select.Option, {
|
10191
10198
|
"kg-value": y[l.value],
|
10192
|
-
value: y[l.value]
|
10199
|
+
value: y[l.value],
|
10200
|
+
label: y[o.value]
|
10193
10201
|
}, {
|
10194
|
-
default: () =>
|
10195
|
-
var m, p;
|
10196
|
-
return [y[(p = (m = n.value) == null ? void 0 : m.lbl_clm) != null ? p : ""]];
|
10197
|
-
}
|
10202
|
+
default: () => [y[o.value]]
|
10198
10203
|
})),
|
10199
10204
|
suffixIcon: () => createVNode(CaretDownOutlined$1, {
|
10200
10205
|
class: "ant-select-suffix"
|
@@ -10308,7 +10313,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10308
10313
|
break;
|
10309
10314
|
}
|
10310
10315
|
return M;
|
10311
|
-
}),
|
10316
|
+
}), p = computed(() => {
|
10312
10317
|
var P, N, U, w;
|
10313
10318
|
let M = " ";
|
10314
10319
|
if (e.kgPlaceholder)
|
@@ -10323,7 +10328,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10323
10328
|
break;
|
10324
10329
|
}
|
10325
10330
|
return M;
|
10326
|
-
}),
|
10331
|
+
}), m = computed(() => {
|
10327
10332
|
var P, N, U, w, O, V, G, F, L, B;
|
10328
10333
|
let M = 6;
|
10329
10334
|
if (e.kgSpan !== void 0)
|
@@ -10383,7 +10388,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10383
10388
|
break;
|
10384
10389
|
}
|
10385
10390
|
return M;
|
10386
|
-
}),
|
10391
|
+
}), T = computed(() => {
|
10387
10392
|
var P;
|
10388
10393
|
const M = {
|
10389
10394
|
...e,
|
@@ -10391,9 +10396,9 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10391
10396
|
"onUpdate:value": (N) => {
|
10392
10397
|
a.value && (a.value[e.kgVarName] = N);
|
10393
10398
|
},
|
10394
|
-
kgPlaceholder:
|
10399
|
+
kgPlaceholder: p.value,
|
10395
10400
|
kgDisabled: y.value,
|
10396
|
-
id:
|
10401
|
+
id: E.value
|
10397
10402
|
};
|
10398
10403
|
switch (v.value) {
|
10399
10404
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER:
|
@@ -10425,13 +10430,13 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10425
10430
|
break;
|
10426
10431
|
}
|
10427
10432
|
return M;
|
10428
|
-
}),
|
10433
|
+
}), E = computed(() => encodeURIComponent(`${e.kgContext}~${s.formID}~${e.kgVarName}`)), A = ref(null);
|
10429
10434
|
function k() {
|
10430
10435
|
if (t.control) {
|
10431
10436
|
const M = {
|
10432
10437
|
frm_id: s.formID,
|
10433
10438
|
varName: e.kgVarName,
|
10434
|
-
props:
|
10439
|
+
props: T,
|
10435
10440
|
model: a,
|
10436
10441
|
varVariableConfig: c,
|
10437
10442
|
varProfileDetail: u,
|
@@ -10441,35 +10446,35 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10441
10446
|
}
|
10442
10447
|
switch (v.value) {
|
10443
10448
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER:
|
10444
|
-
return createVNode(KgFormItemInputNumber,
|
10449
|
+
return createVNode(KgFormItemInputNumber, T.value, null);
|
10445
10450
|
case KG_FORM_ITEM_TYPE.TEXT_AREA:
|
10446
|
-
return createVNode(KgFormItemTextArea,
|
10451
|
+
return createVNode(KgFormItemTextArea, T.value, null);
|
10447
10452
|
case KG_FORM_ITEM_TYPE.SELECT:
|
10448
|
-
return createVNode(KgFormItemSelect,
|
10453
|
+
return createVNode(KgFormItemSelect, T.value, null);
|
10449
10454
|
case KG_FORM_ITEM_TYPE.SELECT_MULTIPLE:
|
10450
|
-
return createVNode(KgFormItemSelect,
|
10455
|
+
return createVNode(KgFormItemSelect, T.value, null);
|
10451
10456
|
case KG_FORM_ITEM_TYPE.SWITCH:
|
10452
|
-
return createVNode(KgFormItemSwitch,
|
10457
|
+
return createVNode(KgFormItemSwitch, T.value, null);
|
10453
10458
|
case KG_FORM_ITEM_TYPE.CHECKBOX:
|
10454
|
-
return createVNode(KgFormItemCheckbox,
|
10459
|
+
return createVNode(KgFormItemCheckbox, T.value, null);
|
10455
10460
|
case KG_FORM_ITEM_TYPE.CHECKBOX_GROUP:
|
10456
|
-
return createVNode(KgFormItemCheckboxGroup,
|
10461
|
+
return createVNode(KgFormItemCheckboxGroup, T.value, null);
|
10457
10462
|
case KG_FORM_ITEM_TYPE.RADIO_GROUP:
|
10458
|
-
return createVNode(KgFormItemRadioGroup,
|
10463
|
+
return createVNode(KgFormItemRadioGroup, T.value, null);
|
10459
10464
|
case KG_FORM_ITEM_TYPE.DATE_DATE:
|
10460
|
-
return createVNode(KgFormItemDate,
|
10465
|
+
return createVNode(KgFormItemDate, T.value, null);
|
10461
10466
|
case KG_FORM_ITEM_TYPE.DATE_DATE_RANGE:
|
10462
|
-
return createVNode(KgFormItemDateRange,
|
10467
|
+
return createVNode(KgFormItemDateRange, T.value, null);
|
10463
10468
|
case KG_FORM_ITEM_TYPE.DATE_TIME:
|
10464
|
-
return createVNode(KgFormItemDate,
|
10469
|
+
return createVNode(KgFormItemDate, T.value, null);
|
10465
10470
|
case KG_FORM_ITEM_TYPE.DATE_TIME_RANGE:
|
10466
|
-
return createVNode(KgFormItemDateRange,
|
10471
|
+
return createVNode(KgFormItemDateRange, T.value, null);
|
10467
10472
|
case KG_FORM_ITEM_TYPE.DATE_DATETIME:
|
10468
|
-
return createVNode(KgFormItemDate,
|
10473
|
+
return createVNode(KgFormItemDate, T.value, null);
|
10469
10474
|
case KG_FORM_ITEM_TYPE.DATE_DATETIME_RANGE:
|
10470
|
-
return createVNode(KgFormItemDateRange,
|
10475
|
+
return createVNode(KgFormItemDateRange, T.value, null);
|
10471
10476
|
default:
|
10472
|
-
return createVNode(KgFormItemInput,
|
10477
|
+
return createVNode(KgFormItemInput, T.value, null);
|
10473
10478
|
}
|
10474
10479
|
}
|
10475
10480
|
function R() {
|
@@ -10517,7 +10522,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10517
10522
|
var M, P;
|
10518
10523
|
return s.isRetrieving.value ? null : createVNode(Col, {
|
10519
10524
|
ref: A,
|
10520
|
-
span:
|
10525
|
+
span: m.value,
|
10521
10526
|
class: C.value,
|
10522
10527
|
style: b.value,
|
10523
10528
|
"kg-frm_id": s.formID,
|
@@ -10529,7 +10534,7 @@ const KgFormItemRadioGroup = defineComponent({
|
|
10529
10534
|
name: e.kgVarName,
|
10530
10535
|
rules: g.value,
|
10531
10536
|
validateFirst: !0,
|
10532
|
-
htmlFor:
|
10537
|
+
htmlFor: E.value
|
10533
10538
|
}, {
|
10534
10539
|
default: () => createVNode(Fragment, null, [R(), k(), I()]),
|
10535
10540
|
label: () => D()
|
@@ -10854,9 +10859,9 @@ const useKgSubmitStore = () => (store$5 || (store$5 = defineStore("KgSubmit", {
|
|
10854
10859
|
}).bind(null, pinia())), store$5);
|
10855
10860
|
function useKgSubmit(e) {
|
10856
10861
|
const t = useKgVar(e), r = useKgSubmitStore()(), a = computed(() => t.store.getVarSubmitConfig(t.formID)), n = computed(() => {
|
10857
|
-
var
|
10862
|
+
var m, b, C, T, E;
|
10858
10863
|
let i = KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER;
|
10859
|
-
const c = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL, u = KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE, d = (
|
10864
|
+
const c = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL, u = KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE, d = (m = a.value) == null ? void 0 : m.display_type, g = (b = a.value) == null ? void 0 : b.crt_display_type, v = (C = a.value) == null ? void 0 : C.upt_display_type, y = (T = a.value) == null ? void 0 : T.cpy_display_type, p = (E = a.value) == null ? void 0 : E.del_display_type;
|
10860
10865
|
switch (!0) {
|
10861
10866
|
case (t.isCreating.value && (g === c || !g && d === c)):
|
10862
10867
|
i = c;
|
@@ -10867,7 +10872,7 @@ function useKgSubmit(e) {
|
|
10867
10872
|
case (t.isCopying.value && (y === c || !y && d === c)):
|
10868
10873
|
i = c;
|
10869
10874
|
break;
|
10870
|
-
case (t.isDeleting.value && (
|
10875
|
+
case (t.isDeleting.value && (p === c || !p)):
|
10871
10876
|
i = c;
|
10872
10877
|
break;
|
10873
10878
|
}
|
@@ -10928,8 +10933,8 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10928
10933
|
}) => {
|
10929
10934
|
const u = s.store.getVarSubmitConfig(s.formID);
|
10930
10935
|
return o = watch(c, (d) => {
|
10931
|
-
var g, v, y,
|
10932
|
-
d && (d.id = (g = u == null ? void 0 : u.id) != null ? g : null, d.frm_id = s.formID, d.resizable_flg = (v = u == null ? void 0 : u.resizable_flg) != null ? v : 1, d.fullscreen_flg = (y = u == null ? void 0 : u.fullscreen_flg) != null ? y : 1, d.dft_fullscreen_flg = (
|
10936
|
+
var g, v, y, p, m, b, C, T, E, A, k, R;
|
10937
|
+
d && (d.id = (g = u == null ? void 0 : u.id) != null ? g : null, d.frm_id = s.formID, d.resizable_flg = (v = u == null ? void 0 : u.resizable_flg) != null ? v : 1, d.fullscreen_flg = (y = u == null ? void 0 : u.fullscreen_flg) != null ? y : 1, d.dft_fullscreen_flg = (p = u == null ? void 0 : u.dft_fullscreen_flg) != null ? p : 0, d.responsive_flg = (m = u == null ? void 0 : u.responsive_flg) != null ? m : 1, d.max_width = (b = u == null ? void 0 : u.max_width) != null ? b : DEFAULT_MAX_WIDTH, d.min_width = (C = u == null ? void 0 : u.min_width) != null ? C : DEFAULT_MIN_WIDTH, d.dft_width = (T = u == null ? void 0 : u.dft_width) != null ? T : DEFAULT_WIDTH, d.layout = (E = u == null ? void 0 : u.layout) != null ? E : 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 = (k = u == null ? void 0 : u.label_col_unit) != null ? k : KG_WIDTH_UNIT.SPAN, d.display_type = (R = u == null ? void 0 : u.display_type) != null ? R : KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER);
|
10933
10938
|
}, {
|
10934
10939
|
immediate: !0
|
10935
10940
|
}), KgUtil.hideLoading(), !1;
|
@@ -10987,7 +10992,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10987
10992
|
default: () => [e.isFullscreen ? createVNode(FullscreenExitOutlined$1, null, null) : createVNode(FullscreenOutlined$1, null, null)]
|
10988
10993
|
});
|
10989
10994
|
}
|
10990
|
-
function
|
10995
|
+
function p() {
|
10991
10996
|
return e.kgShowConfigButton ? createVNode(Fragment, null, [createVNode(Button, {
|
10992
10997
|
disabled: c.value || i.value,
|
10993
10998
|
onClick: g,
|
@@ -10998,7 +11003,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10998
11003
|
hostFormID: n.formID
|
10999
11004
|
}, null)]) : null;
|
11000
11005
|
}
|
11001
|
-
function
|
11006
|
+
function m() {
|
11002
11007
|
return createVNode(Button, {
|
11003
11008
|
disabled: c.value || i.value,
|
11004
11009
|
class: "kg-submit--btn-close",
|
@@ -11007,7 +11012,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
11007
11012
|
default: () => [createVNode(CloseOutlined$1, null, null)]
|
11008
11013
|
});
|
11009
11014
|
}
|
11010
|
-
return () => createVNode(Fragment, null, [
|
11015
|
+
return () => createVNode(Fragment, null, [p(), y(), m()]);
|
11011
11016
|
}
|
11012
11017
|
}), 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;
|
11013
11018
|
function _useFormModel$1() {
|
@@ -11032,20 +11037,20 @@ function _useFormModel$1() {
|
|
11032
11037
|
}
|
11033
11038
|
const d = r.selectedRow.value;
|
11034
11039
|
u.forEach((g) => {
|
11035
|
-
var y,
|
11040
|
+
var y, p, m, b, C, T, E, A;
|
11036
11041
|
const v = (y = g.var_nam) != null ? y : "";
|
11037
11042
|
switch (c.value[v] = void 0, !0) {
|
11038
11043
|
case t.isCreating.value:
|
11039
|
-
c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (
|
11044
|
+
c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (p = g.crt_dft_val) != null ? p : void 0, "C");
|
11040
11045
|
break;
|
11041
11046
|
case t.isUpdating.value:
|
11042
|
-
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (b = (
|
11047
|
+
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (b = (m = g.upt_dft_val) != null ? m : d == null ? void 0 : d[v]) != null ? b : void 0, "U");
|
11043
11048
|
break;
|
11044
11049
|
case t.isCopying.value:
|
11045
|
-
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (
|
11050
|
+
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (T = (C = g.cpy_dft_val) != null ? C : d == null ? void 0 : d[v]) != null ? T : void 0, "CP");
|
11046
11051
|
break;
|
11047
11052
|
case t.isDeleting.value:
|
11048
|
-
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (A = (
|
11053
|
+
c.value.id = d == null ? void 0 : d.id, c.value[v] = KgVarUtil.transformFormItemValue(t.formID, v, e, (A = (E = g.del_dft_val) != null ? E : d == null ? void 0 : d[v]) != null ? A : void 0, "D");
|
11049
11054
|
break;
|
11050
11055
|
}
|
11051
11056
|
}), a.store.setModel(t.formID, c.value);
|
@@ -11116,9 +11121,9 @@ function _useClass(e, t) {
|
|
11116
11121
|
const r = inject(DI_KG_VAR__KG_PROPS, null), a = useKgVar(), n = useKgSubmit(), s = computed(() => a.store.getVarSubmitConfig(a.formID)), l = computed(() => a.store.getVarSubmitFieldsForDeleteKey(a.formID));
|
11117
11122
|
return {
|
11118
11123
|
getClass: computed(() => {
|
11119
|
-
var c, u, d, g, v, y,
|
11124
|
+
var c, u, d, g, v, y, p;
|
11120
11125
|
let i = "kg-submit";
|
11121
|
-
return t.isFullscreen && (i += " kg-submit--fullscreen"), ((c = s.value) == null ? void 0 : c.responsive_flg) !== 0 && (i += " kg-submit--responsive"), n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? i += " kg-submit--modal" : n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (i += " kg-submit--table"), a.isDeleting.value && ((d = (u = l.value) == null ? void 0 : u.length) != null ? d : 0) === 0 && (i += " kg-submit--delete-message"), (v = (g = r == null ? void 0 : r.value) == null ? void 0 : g.KgSubmit) != null && v.kgClass ? i += ` ${(
|
11126
|
+
return t.isFullscreen && (i += " kg-submit--fullscreen"), ((c = s.value) == null ? void 0 : c.responsive_flg) !== 0 && (i += " kg-submit--responsive"), n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? i += " kg-submit--modal" : n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (i += " kg-submit--table"), a.isDeleting.value && ((d = (u = l.value) == null ? void 0 : u.length) != null ? d : 0) === 0 && (i += " kg-submit--delete-message"), (v = (g = r == null ? void 0 : r.value) == null ? void 0 : g.KgSubmit) != null && v.kgClass ? i += ` ${(p = (y = r == null ? void 0 : r.value) == null ? void 0 : y.KgSubmit) == null ? void 0 : p.kgClass}` : e.kgClass && (i += ` ${e.kgClass}`), i;
|
11122
11127
|
})
|
11123
11128
|
};
|
11124
11129
|
}
|
@@ -11194,13 +11199,13 @@ const getProps$p = () => ({
|
|
11194
11199
|
inject(DI_KG_VAR__KG_PROPS, null);
|
11195
11200
|
const n = useKg(), s = useKgVar(), l = useKgButton(), o = useKgTable(), i = useKgSubmit(), c = useKgSearch();
|
11196
11201
|
l.onSubmitSave(async () => (await oe(), !1)), l.onSubmitCancel(async () => (await se(), !1)), _useFormModel$1();
|
11197
|
-
const u = computed(() => s.isDeleting.value &&
|
11202
|
+
const u = computed(() => s.isDeleting.value && E.value.length === 0 && A.value.length === 0), d = computed(() => i.store.isLoading(s.formID)), g = computed(() => s.store.getVarSubmitConfig(s.formID)), v = computed(() => s.store.getVarSubmitFieldsForCreateKey(s.formID)), y = computed(() => s.store.getVarSubmitFieldsForCreateNotKey(s.formID)), p = computed(() => s.store.getVarSubmitFieldsForUpdateKey(s.formID)), m = computed(() => s.store.getVarSubmitFieldsForUpdateNotKey(s.formID)), b = computed(() => s.store.getVarSubmitFieldsForCopyKey(s.formID)), C = computed(() => s.store.getVarSubmitFieldsForCopyNotKey(s.formID)), T = computed(() => s.store.getVarSubmitFieldsForDelete(s.formID)), E = computed(() => {
|
11198
11203
|
var $, x, W;
|
11199
11204
|
switch (!0) {
|
11200
11205
|
case s.isCreating.value:
|
11201
11206
|
return ($ = v.value) != null ? $ : [];
|
11202
11207
|
case s.isUpdating.value:
|
11203
|
-
return (x =
|
11208
|
+
return (x = p.value) != null ? x : [];
|
11204
11209
|
case s.isCopying.value:
|
11205
11210
|
return (W = b.value) != null ? W : [];
|
11206
11211
|
case s.isDeleting.value:
|
@@ -11213,11 +11218,11 @@ const getProps$p = () => ({
|
|
11213
11218
|
case s.isCreating.value:
|
11214
11219
|
return ($ = y.value) != null ? $ : [];
|
11215
11220
|
case s.isUpdating.value:
|
11216
|
-
return (x =
|
11221
|
+
return (x = m.value) != null ? x : [];
|
11217
11222
|
case s.isCopying.value:
|
11218
11223
|
return (W = C.value) != null ? W : [];
|
11219
11224
|
case s.isDeleting.value:
|
11220
|
-
return (J =
|
11225
|
+
return (J = T.value) != null ? J : [];
|
11221
11226
|
}
|
11222
11227
|
return [];
|
11223
11228
|
}), k = computed(() => !!s.store.isCreatingRequesting(s.formID) || !!s.store.isUpdatingRequesting(s.formID) || !!s.store.isCopyingRequesting(s.formID) || !!s.store.isDeletingRequesting(s.formID)), R = computed(() => k.value || d.value), D = computed(() => d.value), I = ref({
|
@@ -11606,11 +11611,11 @@ const getProps$p = () => ({
|
|
11606
11611
|
}, {
|
11607
11612
|
default: () => [createVNode("div", {
|
11608
11613
|
ref: w
|
11609
|
-
}, [
|
11614
|
+
}, [E.value.length > 0 && createVNode(Row, {
|
11610
11615
|
gutter: 12
|
11611
|
-
}, _isSlot$8($ =
|
11616
|
+
}, _isSlot$8($ = E.value.map(de)) ? $ : {
|
11612
11617
|
default: () => [$]
|
11613
|
-
}),
|
11618
|
+
}), E.value.length > 0 && A.value.length > 0 && createVNode(Divider, null, null), A.value.length > 0 && createVNode(Row, {
|
11614
11619
|
gutter: 12
|
11615
11620
|
}, _isSlot$8(x = A.value.map(de)) ? x : {
|
11616
11621
|
default: () => [x]
|
@@ -11913,29 +11918,29 @@ const useKgTableStore = () => (store$4 || (store$4 = defineStore("KgTable", {
|
|
11913
11918
|
}).bind(null, pinia())), store$4);
|
11914
11919
|
function useKgTable(e) {
|
11915
11920
|
const t = useKgVar(e), r = useKgTableStore()(), a = computed(() => r.getIsRetrieving(t.formID)), n = computed(() => r.getSelectedRows(t.formID)), s = computed(() => r.getSelectedFirstRow(t.formID)), l = computed(() => r.getSelectedRow(t.formID)), o = computed(() => {
|
11916
|
-
var
|
11917
|
-
return ((
|
11921
|
+
var p;
|
11922
|
+
return ((p = t.varGridConfig.value) == null ? void 0 : p.mult_flg) === 1;
|
11918
11923
|
}), i = computed(() => {
|
11919
|
-
var
|
11920
|
-
return ((
|
11924
|
+
var p;
|
11925
|
+
return ((p = t.varGridConfig.value) == null ? void 0 : p.aut_load_flg) === 1;
|
11921
11926
|
}), c = computed(() => {
|
11922
|
-
var
|
11923
|
-
return !!((
|
11927
|
+
var p, m;
|
11928
|
+
return !!((p = t.varGridConfig.value) != null && p.id) && ((m = t.varGridConfig.value) == null ? void 0 : m.show_bottom_left_flg) !== 0;
|
11924
11929
|
}), u = computed(() => {
|
11925
|
-
var
|
11926
|
-
return !!((
|
11930
|
+
var p, m;
|
11931
|
+
return !!((p = t.varGridConfig.value) != null && p.id) && ((m = t.varGridConfig.value) == null ? void 0 : m.show_bottom_right_flg) !== 0;
|
11927
11932
|
}), d = computed(() => {
|
11928
|
-
var
|
11929
|
-
return (
|
11933
|
+
var p, m;
|
11934
|
+
return (m = (p = t.varGridConfig.value) == null ? void 0 : p.id_clm) != null ? m : "id";
|
11930
11935
|
}), g = computed(() => {
|
11931
|
-
var
|
11932
|
-
return JSON.parse((
|
11936
|
+
var p, m;
|
11937
|
+
return JSON.parse((m = (p = t.varGridConfig.value) == null ? void 0 : p.pg_size_opts) != null ? m : "[]");
|
11933
11938
|
}), v = computed(() => {
|
11934
|
-
var
|
11935
|
-
return (
|
11939
|
+
var p;
|
11940
|
+
return (p = t.varGridConfig.value) == null ? void 0 : p.pg_size_opt;
|
11936
11941
|
}), y = computed(() => {
|
11937
|
-
var
|
11938
|
-
return ((
|
11942
|
+
var p;
|
11943
|
+
return ((p = t.varGridConfig.value) == null ? void 0 : p.prf_frm_id) || t.formID;
|
11939
11944
|
});
|
11940
11945
|
return {
|
11941
11946
|
formID: t.formID,
|
@@ -11977,50 +11982,50 @@ const getProps$n = () => ({
|
|
11977
11982
|
}) {
|
11978
11983
|
const a = useKg(), n = useKgVar(), s = useKgButton(), l = useKgSubmit(), o = useKgTable();
|
11979
11984
|
s.onSubmitSave(async () => {
|
11980
|
-
var
|
11985
|
+
var E;
|
11981
11986
|
try {
|
11982
|
-
await ((
|
11987
|
+
await ((E = y.value) == null ? void 0 : E.validate());
|
11983
11988
|
} catch (A) {
|
11984
11989
|
KgUtil.throwIfNotFormError(A);
|
11985
11990
|
}
|
11986
11991
|
return !1;
|
11987
11992
|
});
|
11988
11993
|
const i = computed(() => e.kgVarName ? n.store.getVarGridDetail(n.formID, e.kgVarName) : null), c = computed(() => n.store.getVarSubmitField(n.formID, e.kgVarName)), u = computed(() => {
|
11989
|
-
var
|
11990
|
-
return l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((
|
11994
|
+
var E, A, k, R, D, I;
|
11995
|
+
return l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((E = e.kgRow) == null ? void 0 : E[o.id.value]) === ((A = o.selectedRow.value) == null ? void 0 : A[o.id.value]) && (!!n.isCreating.value && ((k = c.value) == null ? void 0 : k.crt_flg) === 1 || !!n.isUpdating.value && ((R = c.value) == null ? void 0 : R.upt_flg) === 1 || !!n.isCopying.value && ((D = c.value) == null ? void 0 : D.cpy_flg) === 1 || !!n.isDeleting.value && ((I = c.value) == null ? void 0 : I.del_flg) === 1);
|
11991
11996
|
}), d = computed(() => {
|
11992
|
-
var
|
11993
|
-
return l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((
|
11997
|
+
var E, A;
|
11998
|
+
return l.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((E = e.kgRow) == null ? void 0 : E[o.id.value]) === ((A = o.selectedRow.value) == null ? void 0 : A[o.id.value]) && (!!n.isCreating.value && !!n.isCreatingRequesting.value || !!n.isUpdating.value && !!n.isUpdatingRequesting.value || !!n.isCopying.value && !!n.isCopyingRequesting.value || !!n.isDeleting.value && !!n.isDeletingRequesting.value);
|
11994
11999
|
}), g = computed(() => {
|
11995
12000
|
var A, k;
|
11996
|
-
let
|
11997
|
-
return ((A = i.value) == null ? void 0 : A.align) === "center" ?
|
12001
|
+
let E = "kg-table-td";
|
12002
|
+
return ((A = i.value) == null ? void 0 : A.align) === "center" ? E += " kg-table-td--center" : ((k = i.value) == null ? void 0 : k.align) === "right" && (E += " kg-table-td--right"), u.value && (E += " kg-table-td--submitting"), E;
|
11998
12003
|
}), v = computed(() => {
|
11999
12004
|
var A, k, R, D, I;
|
12000
12005
|
if (e.kgValue === KG_TABLE_TEMP_ID)
|
12001
12006
|
return "";
|
12002
|
-
let
|
12007
|
+
let E = e.kgValue;
|
12003
12008
|
switch ((A = i.value) == null ? void 0 : A.display_type) {
|
12004
12009
|
case KG_TABLE_CELL_DISPLAY_TYPE.DESC:
|
12005
12010
|
{
|
12006
12011
|
const M = KgUtil.tryParseJSON((k = i.value) == null ? void 0 : k.display_type_properties);
|
12007
|
-
M.dscFieldName ?
|
12012
|
+
M.dscFieldName ? E = ((R = e.kgRow) == null ? void 0 : R[M.dscFieldName]) || e.kgValue : E = ((D = e.kgRow) == null ? void 0 : D[`${e.kgVarName}_dsc`]) || ((I = e.kgRow) == null ? void 0 : I[`${e.kgVarName}Dsc`]) || e.kgValue;
|
12008
12013
|
}
|
12009
12014
|
break;
|
12010
12015
|
}
|
12011
|
-
return isString$1(
|
12012
|
-
`)),
|
12016
|
+
return isString$1(E) && (E = E.replaceAll("\\n", `
|
12017
|
+
`)), E;
|
12013
12018
|
}), y = ref(null);
|
12014
|
-
function
|
12019
|
+
function p(E) {
|
12015
12020
|
var A, k, R;
|
12016
|
-
if (
|
12021
|
+
if (E.detail === 1 && !(n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value))
|
12017
12022
|
switch ((A = i.value) == null ? void 0 : A.display_type) {
|
12018
12023
|
case KG_TABLE_CELL_DISPLAY_TYPE.UPDATE_LINK:
|
12019
|
-
|
12024
|
+
E.stopPropagation(), E.preventDefault(), r("kgUpdateLinkClick");
|
12020
12025
|
break;
|
12021
12026
|
case KG_TABLE_CELL_DISPLAY_TYPE.ROUTE_LINK:
|
12022
12027
|
{
|
12023
|
-
|
12028
|
+
E.stopPropagation(), E.preventDefault();
|
12024
12029
|
const D = KgUtil.tryParseJSON((k = i.value) == null ? void 0 : k.display_type_properties);
|
12025
12030
|
(R = a.router.value) == null || R.push({
|
12026
12031
|
path: D.path,
|
@@ -12030,7 +12035,7 @@ const getProps$n = () => ({
|
|
12030
12035
|
break;
|
12031
12036
|
}
|
12032
12037
|
}
|
12033
|
-
function
|
12038
|
+
function m() {
|
12034
12039
|
}
|
12035
12040
|
function b() {
|
12036
12041
|
return createVNode(KgForm, {
|
@@ -12048,16 +12053,16 @@ const getProps$n = () => ({
|
|
12048
12053
|
kgRules: l.rules.value[e.kgVarName],
|
12049
12054
|
kgSpan: 24,
|
12050
12055
|
kgDisabled: d.value ? !0 : void 0,
|
12051
|
-
onKgSubmit:
|
12056
|
+
onKgSubmit: m
|
12052
12057
|
}, null)]
|
12053
12058
|
})]
|
12054
12059
|
});
|
12055
12060
|
}
|
12056
12061
|
function C() {
|
12057
|
-
var
|
12062
|
+
var E, A, k, R, D, I, M, P, N, U;
|
12058
12063
|
if (u.value)
|
12059
12064
|
return b();
|
12060
|
-
switch ((
|
12065
|
+
switch ((E = i.value) == null ? void 0 : E.display_type) {
|
12061
12066
|
case KG_TABLE_CELL_DISPLAY_TYPE.YN: {
|
12062
12067
|
const w = KgUtil.tryParseJSON((A = i.value) == null ? void 0 : A.display_type_properties);
|
12063
12068
|
return createVNode(KgYesOrNo, {
|
@@ -12073,9 +12078,9 @@ const getProps$n = () => ({
|
|
12073
12078
|
color: (D = O.color) != null ? D : "default"
|
12074
12079
|
}, _isSlot$7(V) ? V : {
|
12075
12080
|
default: () => [V]
|
12076
|
-
}) :
|
12081
|
+
}) : T();
|
12077
12082
|
} else
|
12078
|
-
return
|
12083
|
+
return T();
|
12079
12084
|
}
|
12080
12085
|
case KG_TABLE_CELL_DISPLAY_TYPE.DESC: {
|
12081
12086
|
const w = KgUtil.tryParseJSON((I = i.value) == null ? void 0 : I.display_type_properties);
|
@@ -12085,9 +12090,9 @@ const getProps$n = () => ({
|
|
12085
12090
|
color: (M = O == null ? void 0 : O.color) != null ? M : "default"
|
12086
12091
|
}, {
|
12087
12092
|
default: () => [v.value]
|
12088
|
-
}) :
|
12093
|
+
}) : T();
|
12089
12094
|
} else
|
12090
|
-
return
|
12095
|
+
return T();
|
12091
12096
|
}
|
12092
12097
|
case KG_TABLE_CELL_DISPLAY_TYPE.PROGRESS: {
|
12093
12098
|
const w = KgUtil.tryParseJSON((P = i.value) == null ? void 0 : P.display_type_properties);
|
@@ -12100,19 +12105,19 @@ const getProps$n = () => ({
|
|
12100
12105
|
case KG_TABLE_CELL_DISPLAY_TYPE.FILE_SIZE:
|
12101
12106
|
return KgUtil.getFileSize(e.kgValue);
|
12102
12107
|
case KG_TABLE_CELL_DISPLAY_TYPE.UPDATE_LINK:
|
12103
|
-
return
|
12108
|
+
return T(!0);
|
12104
12109
|
case KG_TABLE_CELL_DISPLAY_TYPE.ROUTE_LINK:
|
12105
|
-
return
|
12110
|
+
return T(!0);
|
12106
12111
|
default:
|
12107
|
-
return
|
12112
|
+
return T();
|
12108
12113
|
}
|
12109
12114
|
}
|
12110
|
-
function E
|
12115
|
+
function T(E = !1) {
|
12111
12116
|
let A = "";
|
12112
|
-
return
|
12117
|
+
return E && !(n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value) && (A += "kg-table-td-update-link"), createVNode("pre", {
|
12113
12118
|
innerHTML: v.value,
|
12114
12119
|
class: A,
|
12115
|
-
onClick:
|
12120
|
+
onClick: p
|
12116
12121
|
}, null);
|
12117
12122
|
}
|
12118
12123
|
return () => createVNode("div", {
|
@@ -12208,8 +12213,8 @@ const getProps$m = () => ({
|
|
12208
12213
|
}) => {
|
12209
12214
|
const c = a == null ? void 0 : a.store.getVarGridConfig(a.formID);
|
12210
12215
|
return l = watch(i, (u) => {
|
12211
|
-
var d, g, v, y,
|
12212
|
-
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 = (v = c == null ? void 0 : c.mult_flg) != null ? v : 0, u.show_check_column_flg = (y = c == null ? void 0 : c.show_check_column_flg) != null ? y : 0, u.show_bottom_left_flg = (
|
12216
|
+
var d, g, v, y, p, m, b, C, T, E, A;
|
12217
|
+
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 = (v = c == null ? void 0 : c.mult_flg) != null ? v : 0, u.show_check_column_flg = (y = c == null ? void 0 : c.show_check_column_flg) != null ? y : 0, u.show_bottom_left_flg = (p = c == null ? void 0 : c.show_bottom_left_flg) != null ? p : 1, u.show_bottom_right_flg = (m = c == null ? void 0 : c.show_bottom_right_flg) != null ? m : 1, u.convert_sort_field_to_under_score_flg = (b = c == null ? void 0 : c.convert_sort_field_to_under_score_flg) != null ? b : 0, u.pg_size_opts = (C = c == null ? void 0 : c.pg_size_opts) != null ? C : "[10, 20, 50, 100]", u.pg_size_opt = (T = c == null ? void 0 : c.pg_size_opt) != null ? T : 10, u.cmd_prm = (E = c == null ? void 0 : c.cmd_prm) != null ? E : void 0, u.button_display_type = (A = c == null ? void 0 : c.button_display_type) != null ? A : KG_BUTTON_DISPLAY_TYPE.DEFAULT);
|
12213
12218
|
}, {
|
12214
12219
|
immediate: !0
|
12215
12220
|
}), KgUtil.hideLoading(), !1;
|
@@ -12424,8 +12429,8 @@ const FORM_ID__VAR_GRID_MASTER__SAVE = "kg-table.VarGridMaster.Save", KgTableSet
|
|
12424
12429
|
return l.onOpen(async ({
|
12425
12430
|
model: o
|
12426
12431
|
}) => {
|
12427
|
-
var i, c, u, d, g, v, y,
|
12428
|
-
return o.value.grd_var_nam = `${(c = (i = n.currentVarGridMaster.value) == null ? void 0 : i.grd_var_nam) != null ? c : ""}_COPY`, o.value.frm_id = (d = (u = n.currentVarGridMaster.value) == null ? void 0 : u.frm_id) != null ? d : "", o.value.usr_id = (v = (g = n.currentVarGridMaster.value) == null ? void 0 : g.usr_id) != null ? v : "", o.value.grp_nam = (
|
12432
|
+
var i, c, u, d, g, v, y, p, m, b;
|
12433
|
+
return o.value.grd_var_nam = `${(c = (i = n.currentVarGridMaster.value) == null ? void 0 : i.grd_var_nam) != null ? c : ""}_COPY`, o.value.frm_id = (d = (u = n.currentVarGridMaster.value) == null ? void 0 : u.frm_id) != null ? d : "", o.value.usr_id = (v = (g = n.currentVarGridMaster.value) == null ? void 0 : g.usr_id) != null ? v : "", o.value.grp_nam = (p = (y = n.currentVarGridMaster.value) == null ? void 0 : y.grp_nam) != null ? p : "", o.value.varGridDetails = (b = (m = n.currentVarGridMaster.value) == null ? void 0 : m.varGridDetails) != null ? b : [], KgUtil.hideLoading(), !1;
|
12429
12434
|
}), l.onBeforeOk(async ({
|
12430
12435
|
model: o
|
12431
12436
|
}) => (o.value, !1)), l.onOk(async () => (n.store.retrieve(n.formID), !1)), () => createVNode(KgSubmit, null, null);
|
@@ -12453,19 +12458,19 @@ const getProps$h = () => ({
|
|
12453
12458
|
} = _useServices(), o = ref(""), i = ref([]), c = computed(() => i.value.includes("1")), u = reactive({
|
12454
12459
|
visible: !1
|
12455
12460
|
}), d = computed(() => isNil(e.kgDisabled) ? !!n.isCreating.value || !!n.isCreating.value || !!n.isCreating.value || !!n.isCreating.value : e.kgDisabled), g = ref(!1);
|
12456
|
-
_useObserveMenuItemColumns(c), watch(c, (
|
12457
|
-
|
12461
|
+
_useObserveMenuItemColumns(c), watch(c, (T) => {
|
12462
|
+
T || (o.value = "");
|
12458
12463
|
}, {
|
12459
12464
|
immediate: !0
|
12460
12465
|
});
|
12461
|
-
function v(
|
12462
|
-
n.store.patchVarGridDetail(n.formID,
|
12463
|
-
vis_flg:
|
12466
|
+
function v(T) {
|
12467
|
+
n.store.patchVarGridDetail(n.formID, T.var_nam, {
|
12468
|
+
vis_flg: T.vis_flg === 1 ? 0 : 1
|
12464
12469
|
});
|
12465
12470
|
}
|
12466
12471
|
async function y() {
|
12467
|
-
var
|
12468
|
-
if (((
|
12472
|
+
var T;
|
12473
|
+
if (((T = n.currentVarGridMaster.value) == null ? void 0 : T.cust_lvl) === KG_CUSTOM_LEVEL.L0) {
|
12469
12474
|
KgUtil.confirm({
|
12470
12475
|
content: a.t("kg.KgTable.canNotUpdateSystemVarGridMaster"),
|
12471
12476
|
okButtonProps: {
|
@@ -12483,39 +12488,39 @@ const getProps$h = () => ({
|
|
12483
12488
|
})
|
12484
12489
|
}), KgUtil.hideLoading(), message.success(a.t("kg.KgTable.saveVarGridMasterSuccessMessage"));
|
12485
12490
|
}
|
12486
|
-
async function
|
12491
|
+
async function p() {
|
12487
12492
|
g.value = !0, await nextTick(), n.store.setIsCopying(FORM_ID__VAR_GRID_MASTER__SAVE, !0);
|
12488
12493
|
}
|
12489
|
-
function
|
12494
|
+
function m() {
|
12490
12495
|
return createVNode(Menu.SubMenu, {
|
12491
12496
|
key: "1",
|
12492
12497
|
title: a.t("kg.KgTable.column"),
|
12493
12498
|
popupClassName: "kg-table-setting-submenu-popup-columns"
|
12494
12499
|
}, {
|
12495
12500
|
default: () => {
|
12496
|
-
var
|
12501
|
+
var T;
|
12497
12502
|
return createVNode("div", {
|
12498
12503
|
class: "columns"
|
12499
12504
|
}, [createVNode(Input, {
|
12500
12505
|
value: o.value,
|
12501
|
-
"onUpdate:value": (
|
12506
|
+
"onUpdate:value": (E) => o.value = E,
|
12502
12507
|
allowClear: !0
|
12503
12508
|
}, null), createVNode("ul", {
|
12504
12509
|
class: "ant-dropdown-menu ant-dropdown-menu-vertical"
|
12505
|
-
}, [(
|
12510
|
+
}, [(T = n.currentVarGridDetails.value) == null ? void 0 : T.map((E) => createVNode("li", {
|
12506
12511
|
class: "ant-dropdown-menu-item ant-dropdown-menu-item-only-child",
|
12507
12512
|
onClick: (A) => {
|
12508
|
-
A.preventDefault(), A.stopPropagation(), v(
|
12513
|
+
A.preventDefault(), A.stopPropagation(), v(E);
|
12509
12514
|
},
|
12510
12515
|
style: {
|
12511
|
-
display: l(
|
12516
|
+
display: l(E, o.value) ? "flex" : "none"
|
12512
12517
|
},
|
12513
|
-
"kg-var_nam":
|
12518
|
+
"kg-var_nam": E.var_nam
|
12514
12519
|
}, [createVNode(Checkbox, {
|
12515
|
-
checked:
|
12520
|
+
checked: E.vis_flg === 1,
|
12516
12521
|
disabled: !0
|
12517
12522
|
}, {
|
12518
|
-
default: () => [createVNode("pre", null, [n.t(
|
12523
|
+
default: () => [createVNode("pre", null, [n.t(E.var_nam).value])]
|
12519
12524
|
}), createVNode(HolderOutlined$1, {
|
12520
12525
|
onClick: (A) => {
|
12521
12526
|
A.preventDefault(), A.stopPropagation();
|
@@ -12533,7 +12538,7 @@ const getProps$h = () => ({
|
|
12533
12538
|
}, {
|
12534
12539
|
default: () => {
|
12535
12540
|
var A;
|
12536
|
-
let
|
12541
|
+
let T, E;
|
12537
12542
|
return createVNode(Fragment, null, [(A = n.varGridMasters.value) == null ? void 0 : A.map((k) => {
|
12538
12543
|
var R;
|
12539
12544
|
return createVNode(Menu.Item, {
|
@@ -12547,27 +12552,27 @@ const getProps$h = () => ({
|
|
12547
12552
|
}), createVNode(Menu.Divider, null, null), createVNode(Menu.Item, {
|
12548
12553
|
key: "save-grid-view",
|
12549
12554
|
onClick: y
|
12550
|
-
}, _isSlot$5(
|
12551
|
-
default: () => [
|
12555
|
+
}, _isSlot$5(T = a.t("kg.KgTable.saveVarGridMaster")) ? T : {
|
12556
|
+
default: () => [T]
|
12552
12557
|
}), createVNode(Menu.Item, {
|
12553
12558
|
key: "save-grid-view-as",
|
12554
|
-
onClick:
|
12555
|
-
}, _isSlot$5(
|
12556
|
-
default: () => [
|
12559
|
+
onClick: p
|
12560
|
+
}, _isSlot$5(E = a.t("kg.KgTable.saveVarGridMasterAs")) ? E : {
|
12561
|
+
default: () => [E]
|
12557
12562
|
})]);
|
12558
12563
|
},
|
12559
12564
|
expandIcon: () => createVNode(CaretRightOutlined$1, null, null)
|
12560
12565
|
});
|
12561
12566
|
}
|
12562
12567
|
function C() {
|
12563
|
-
let
|
12568
|
+
let T;
|
12564
12569
|
return createVNode(Menu.Item, {
|
12565
12570
|
key: "config-var-grid-master",
|
12566
12571
|
onClick: () => {
|
12567
12572
|
u.visible = !0;
|
12568
12573
|
}
|
12569
|
-
}, _isSlot$5(
|
12570
|
-
default: () => [
|
12574
|
+
}, _isSlot$5(T = a.t("kg.KgTable.config")) ? T : {
|
12575
|
+
default: () => [T]
|
12571
12576
|
});
|
12572
12577
|
}
|
12573
12578
|
return () => createVNode(Fragment, null, [createVNode(Dropdown, {
|
@@ -12580,14 +12585,14 @@ const getProps$h = () => ({
|
|
12580
12585
|
overlay: () => createVNode(Menu, {
|
12581
12586
|
triggerSubMenuAction: "click",
|
12582
12587
|
openKeys: i.value,
|
12583
|
-
"onUpdate:openKeys": (
|
12588
|
+
"onUpdate:openKeys": (T) => i.value = T,
|
12584
12589
|
selectable: !1
|
12585
12590
|
}, {
|
12586
|
-
default: () => [
|
12591
|
+
default: () => [m(), b(), C()]
|
12587
12592
|
})
|
12588
12593
|
}), u.visible && createVNode(KgTableSettingConfigModal, {
|
12589
12594
|
visible: u.visible,
|
12590
|
-
"onUpdate:visible": (
|
12595
|
+
"onUpdate:visible": (T) => u.visible = T,
|
12591
12596
|
hostFormID: n.formID
|
12592
12597
|
}, null), g.value && createVNode(KgTableSettingVarGridMasterSaveAs, null, null)]);
|
12593
12598
|
}
|
@@ -13051,61 +13056,61 @@ function _useColumns(e) {
|
|
13051
13056
|
align: "center",
|
13052
13057
|
className: "kg-table-td-index",
|
13053
13058
|
customRender: ({
|
13054
|
-
index:
|
13055
|
-
}) =>
|
13056
|
-
}, ...(y = u == null ? void 0 : u.map((
|
13057
|
-
const
|
13059
|
+
index: p
|
13060
|
+
}) => p + 1
|
13061
|
+
}, ...(y = u == null ? void 0 : u.map((p) => {
|
13062
|
+
const m = p.var_nam;
|
13058
13063
|
function b() {
|
13059
|
-
return
|
13064
|
+
return p.width === "auto" ? "auto" : Number(p.width) || KG_TABLE_TD_DEFAULT_WIDTH;
|
13060
13065
|
}
|
13061
13066
|
function C() {
|
13062
|
-
return r.t(
|
13063
|
-
}
|
13064
|
-
function E() {
|
13065
|
-
return m.ord === -1 ? null : m.ord === 0 ? "ascend" : m.ord === 1 ? "descend" : null;
|
13067
|
+
return r.t(m).value;
|
13066
13068
|
}
|
13067
13069
|
function T() {
|
13068
|
-
|
13070
|
+
return p.ord === -1 ? null : p.ord === 0 ? "ascend" : p.ord === 1 ? "descend" : null;
|
13071
|
+
}
|
13072
|
+
function E() {
|
13073
|
+
if (p.fix_left_flg === 1)
|
13069
13074
|
return "left";
|
13070
|
-
if (
|
13075
|
+
if (p.fix_right_flg === 1)
|
13071
13076
|
return "right";
|
13072
13077
|
}
|
13073
13078
|
function A() {
|
13074
13079
|
var D, I, M, P;
|
13075
|
-
return !((I = (D = t == null ? void 0 : t.value) == null ? void 0 : D.KgTable) != null && I.kgDisabled || isNil((P = (M = t == null ? void 0 : t.value) == null ? void 0 : M.KgTable) == null ? void 0 : P.kgDisabled) && e.kgDisabled ||
|
13080
|
+
return !((I = (D = t == null ? void 0 : t.value) == null ? void 0 : D.KgTable) != null && I.kgDisabled || isNil((P = (M = t == null ? void 0 : t.value) == null ? void 0 : M.KgTable) == null ? void 0 : P.kgDisabled) && e.kgDisabled || p.ord_flg !== 1 || r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value);
|
13076
13081
|
}
|
13077
13082
|
function k() {
|
13078
|
-
return ["left", "center", "right"].includes(
|
13083
|
+
return ["left", "center", "right"].includes(p.align || "") ? p.align : "left";
|
13079
13084
|
}
|
13080
13085
|
const R = b();
|
13081
13086
|
return {
|
13082
|
-
dataIndex:
|
13087
|
+
dataIndex: m,
|
13083
13088
|
title: C(),
|
13084
13089
|
width: R,
|
13085
13090
|
resizable: typeof R == "number",
|
13086
13091
|
minWidth: KG_TABLE_TD_MIN_WIDTH,
|
13087
13092
|
maxWidth: KG_TABLE_TD_MAX_WIDTH,
|
13088
|
-
fixed:
|
13093
|
+
fixed: E(),
|
13089
13094
|
sorter: A(),
|
13090
13095
|
align: k(),
|
13091
|
-
defaultSortOrder:
|
13096
|
+
defaultSortOrder: T(),
|
13092
13097
|
customHeaderCell: () => ({
|
13093
13098
|
"kg-frm_id": r.formID,
|
13094
|
-
"kg-var_nam":
|
13099
|
+
"kg-var_nam": m,
|
13095
13100
|
draggable: !0
|
13096
13101
|
}),
|
13097
13102
|
customCell: (D) => {
|
13098
13103
|
var M;
|
13099
|
-
const I = r.store.getVarSubmitField(r.formID,
|
13104
|
+
const I = r.store.getVarSubmitField(r.formID, m);
|
13100
13105
|
return {
|
13101
13106
|
"kg-frm_id": r.formID,
|
13102
|
-
"kg-var_nam":
|
13107
|
+
"kg-var_nam": m,
|
13103
13108
|
class: a.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && D[n.id.value] === ((M = n.selectedRow.value) == null ? void 0 : M[n.id.value]) && (!!r.isCreating.value && (I == null ? void 0 : I.crt_flg) === 1 || !!r.isUpdating.value && (I == null ? void 0 : I.upt_flg) === 1 || !!r.isCopying.value && (I == null ? void 0 : I.cpy_flg) === 1 || !!r.isDeleting.value && (I == null ? void 0 : I.del_flg) === 1) ? "submitting" : ""
|
13104
13109
|
};
|
13105
13110
|
}
|
13106
13111
|
};
|
13107
13112
|
})) != null ? y : []];
|
13108
|
-
return (c === 0 || i > c && !(u != null && u.find((
|
13113
|
+
return (c === 0 || i > c && !(u != null && u.find((p) => p.width === "auto"))) && d.push({
|
13109
13114
|
width: "auto",
|
13110
13115
|
customRender: () => null
|
13111
13116
|
}), d;
|
@@ -13158,8 +13163,8 @@ function _useDragColumn(e, t) {
|
|
13158
13163
|
height: g
|
13159
13164
|
} = i.getBoundingClientRect();
|
13160
13165
|
d && g && (u.style.width = `${d + 2}px`, u.style.height = `${g + 2}px`), (v = c.dataTransfer) == null || v.setDragImage(u, -10, (g + 2) / 2), toCanvas(i).then((y) => {
|
13161
|
-
var
|
13162
|
-
u.appendChild(y), document.body.appendChild(u), (
|
13166
|
+
var p;
|
13167
|
+
u.appendChild(y), document.body.appendChild(u), (p = c.dataTransfer) == null || p.setDragImage(u, -10, (g + 2) / 2);
|
13163
13168
|
});
|
13164
13169
|
}, i.addEventListener("dragstart", i.__kg__dragstart__), i.__kg__dragend__ = (c) => {
|
13165
13170
|
i.classList.remove("dragging"), i.parentElement.classList.remove("dragging");
|
@@ -13243,15 +13248,15 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13243
13248
|
});
|
13244
13249
|
const g = ref(!1), v = ref([]), {
|
13245
13250
|
columns: y,
|
13246
|
-
scrollX:
|
13251
|
+
scrollX: p
|
13247
13252
|
} = _useColumns(e), {
|
13248
|
-
isLoading:
|
13253
|
+
isLoading: m
|
13249
13254
|
} = _useLoading(), b = ref(null);
|
13250
13255
|
_useResizeObserver(b), _useDragColumn(b, y);
|
13251
13256
|
const C = computed(() => {
|
13252
13257
|
var K, H;
|
13253
13258
|
return (H = (K = o.varButtonSearch.value) == null ? void 0 : K.cmd) != null ? H : null;
|
13254
|
-
}),
|
13259
|
+
}), T = computed(() => {
|
13255
13260
|
var H, q, $, x, W, J, X;
|
13256
13261
|
let K = {
|
13257
13262
|
pageNo: O.pageIndex,
|
@@ -13266,7 +13271,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13266
13271
|
...K,
|
13267
13272
|
...KgVarUtil.parseCommandParameter((J = o.varGridConfig.value.cmd_prm) != null ? J : "")
|
13268
13273
|
}), ((X = o.varGridConfig.value) == null ? void 0 : X.convert_sort_field_to_under_score_flg) === 1 && K.column && (K.column = snakeCase$1(K.column)), K;
|
13269
|
-
}),
|
13274
|
+
}), E = computed(() => {
|
13270
13275
|
var K, H, q, $;
|
13271
13276
|
if (!isNil((H = (K = s == null ? void 0 : s.value) == null ? void 0 : K.KgTable) == null ? void 0 : H.kgDisabled))
|
13272
13277
|
return ($ = (q = s == null ? void 0 : s.value) == null ? void 0 : q.KgTable) == null ? void 0 : $.kgDisabled;
|
@@ -13278,7 +13283,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13278
13283
|
return ($ = (q = s == null ? void 0 : s.value) == null ? void 0 : q.KgTable) == null ? void 0 : $.kgCheckboxDisabled;
|
13279
13284
|
if (!isNil(e.kgCheckboxDisabled))
|
13280
13285
|
return e.kgCheckboxDisabled;
|
13281
|
-
}), k = computed(() => !!
|
13286
|
+
}), k = computed(() => !!E.value || m.value || !!o.isCreating.value || !!o.isUpdating.value || !!o.isCopying.value || !!o.isDeleting.value), R = computed(() => !!E.value || m.value || !!o.isCreating.value || !!o.isUpdating.value || !!o.isCopying.value || !!o.isDeleting.value || O.total === 0), D = computed(() => {
|
13282
13287
|
var K;
|
13283
13288
|
return !!((K = n == null ? void 0 : n.KgTable) != null && K.expandedRowRender);
|
13284
13289
|
}), I = computed(() => {
|
@@ -13295,7 +13300,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13295
13300
|
getCheckboxProps: (K) => {
|
13296
13301
|
var H;
|
13297
13302
|
return {
|
13298
|
-
disabled: !!
|
13303
|
+
disabled: !!E.value || !!o.isCreating.value || !!o.isUpdating.value || !!o.isCopying.value || !!o.isDeleting.value || !!((H = A.value) != null && H.call(A, K))
|
13299
13304
|
};
|
13300
13305
|
},
|
13301
13306
|
onSelect: (K) => z(K),
|
@@ -13346,7 +13351,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13346
13351
|
}
|
13347
13352
|
function B(K, H) {
|
13348
13353
|
var q;
|
13349
|
-
if (!(!!
|
13354
|
+
if (!(!!E.value || !!o.isCreating.value || !!o.isUpdating.value || !!o.isCopying.value || !!o.isDeleting.value) && !!M.value) {
|
13350
13355
|
if (!H) {
|
13351
13356
|
u.store.setSelectedRows(o.formID, []);
|
13352
13357
|
return;
|
@@ -13386,7 +13391,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13386
13391
|
}
|
13387
13392
|
K && (O.pageIndex = 1), u.store.setIsRetrieving(o.formID, !0);
|
13388
13393
|
try {
|
13389
|
-
const J = KgUtil.parseParams(
|
13394
|
+
const J = KgUtil.parseParams(T.value, u.profileFormID.value, a), X = ref({});
|
13390
13395
|
await u.store.emit(o.formID, "beforeRetrieve", {
|
13391
13396
|
params: J,
|
13392
13397
|
response: X
|
@@ -13499,7 +13504,7 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13499
13504
|
switch (H.dataIndex) {
|
13500
13505
|
case "index":
|
13501
13506
|
return createVNode(KgTableSetting, {
|
13502
|
-
kgDisabled:
|
13507
|
+
kgDisabled: E.value
|
13503
13508
|
}, null);
|
13504
13509
|
default:
|
13505
13510
|
return createVNode("pre", {
|
@@ -13587,14 +13592,14 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13587
13592
|
class: "kg-flex-table",
|
13588
13593
|
size: "small",
|
13589
13594
|
scroll: {
|
13590
|
-
x:
|
13595
|
+
x: p.value,
|
13591
13596
|
y: "auto"
|
13592
13597
|
},
|
13593
13598
|
pagination: !1,
|
13594
13599
|
showSorterTooltip: !1,
|
13595
13600
|
columns: y.value,
|
13596
13601
|
dataSource: U.value,
|
13597
|
-
loading:
|
13602
|
+
loading: m.value,
|
13598
13603
|
rowKey: u.id.value,
|
13599
13604
|
rowClassName: (H = (K = s == null ? void 0 : s.value) == null ? void 0 : K.KgTable) == null ? void 0 : H.kgRowClassName,
|
13600
13605
|
expandColumnWidth: 28,
|
@@ -13668,8 +13673,8 @@ const KgTable$1 = "", getProps$g = () => ({
|
|
13668
13673
|
attrs: t
|
13669
13674
|
}) {
|
13670
13675
|
const r = useKg(), a = useKgVar(), n = useKgTable(), s = computed(() => a.store.getVarButton(a.formID, e.kgVarName)), l = computed(() => {
|
13671
|
-
var u, d, g, v, y,
|
13672
|
-
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 || ((v = s.value) == null ? void 0 : v.dis_mult_select_flg) === 1 && ((
|
13676
|
+
var u, d, g, v, y, p, m, b;
|
13677
|
+
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 || ((v = s.value) == null ? void 0 : v.dis_mult_select_flg) === 1 && ((p = (y = n.selectedRows.value) == null ? void 0 : y.length) != null ? p : 0) > 1 || ((m = s.value) == null ? void 0 : m.permission_type) === 2 && !r.p((b = s.value) == null ? void 0 : b.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
13673
13678
|
});
|
13674
13679
|
async function o() {
|
13675
13680
|
e.onKgClick && await e.onKgClick() || a.store.setIsCopying(a.formID, !0);
|
@@ -13867,8 +13872,8 @@ const KgButtonCreate = defineComponent({
|
|
13867
13872
|
attrs: a
|
13868
13873
|
}) {
|
13869
13874
|
const n = useKg(), s = useKgVar(), l = useKgButton(), o = useKgTable(), i = useKgSubmit(), c = computed(() => s.store.getVarButton(s.formID, e.kgVarName)), u = computed(() => {
|
13870
|
-
var
|
13871
|
-
return s.isUpdating.value || s.isCopying.value || s.isDeleting.value || o.isRetrieving.value || ((
|
13875
|
+
var T, E, A, k, R, D, I, M;
|
13876
|
+
return s.isUpdating.value || s.isCopying.value || s.isDeleting.value || o.isRetrieving.value || ((T = c.value) == null ? void 0 : T.dis_no_select_flg) === 1 && ((A = (E = o.selectedRows.value) == null ? void 0 : E.length) != null ? A : 0) === 0 || ((k = c.value) == null ? void 0 : k.dis_mult_select_flg) === 1 && ((D = (R = o.selectedRows.value) == null ? void 0 : R.length) != null ? D : 0) > 1 || ((I = c.value) == null ? void 0 : I.permission_type) === 2 && !n.p((M = c.value) == null ? void 0 : M.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
13872
13877
|
}), d = computed(() => !!s.isCreatingRequesting.value);
|
13873
13878
|
async function g() {
|
13874
13879
|
e.onKgClick && await e.onKgClick() || s.store.setIsCreating(s.formID, !0);
|
@@ -13879,29 +13884,29 @@ const KgButtonCreate = defineComponent({
|
|
13879
13884
|
function y() {
|
13880
13885
|
l.store.emit(s.formID, "submitCancel", {});
|
13881
13886
|
}
|
13882
|
-
function
|
13887
|
+
function p() {
|
13883
13888
|
return e.kgIcon ? createVNode("span", {
|
13884
13889
|
class: "anticon"
|
13885
13890
|
}, [createVNode(Icon, {
|
13886
13891
|
icon: e.kgIcon
|
13887
13892
|
}, null)]) : createVNode(PlusOutlined$1, null, null);
|
13888
13893
|
}
|
13889
|
-
function
|
13894
|
+
function m() {
|
13890
13895
|
return e.kgText ? e.kgText : n.t("kg.create");
|
13891
13896
|
}
|
13892
13897
|
function b() {
|
13893
|
-
var
|
13898
|
+
var T, E, A, k;
|
13894
13899
|
return i.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && s.isCreating.value ? null : createVNode(Button, {
|
13895
13900
|
type: "primary",
|
13896
13901
|
disabled: u.value,
|
13897
13902
|
onClick: g,
|
13898
13903
|
class: a.class,
|
13899
|
-
"kg-id": (
|
13900
|
-
"kg-frm_id": (
|
13904
|
+
"kg-id": (T = c.value) == null ? void 0 : T.id,
|
13905
|
+
"kg-frm_id": (E = c.value) == null ? void 0 : E.frm_id,
|
13901
13906
|
"kg-var_nam": (A = c.value) == null ? void 0 : A.var_nam,
|
13902
13907
|
"kg-cmd": (k = c.value) == null ? void 0 : k.cmd
|
13903
13908
|
}, {
|
13904
|
-
default: () => [
|
13909
|
+
default: () => [p(), m()]
|
13905
13910
|
});
|
13906
13911
|
}
|
13907
13912
|
function C() {
|
@@ -13927,8 +13932,8 @@ const KgButtonCreate = defineComponent({
|
|
13927
13932
|
props: getProps$f(),
|
13928
13933
|
setup(e) {
|
13929
13934
|
const t = useKg(), r = useKgVar(), a = useKgTable(), n = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), s = computed(() => {
|
13930
|
-
var c, u, d, g, v, y,
|
13931
|
-
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 && ((y = (v = a.selectedRows.value) == null ? void 0 : v.length) != null ? y : 0) > 1 || ((
|
13935
|
+
var c, u, d, g, v, y, p, m;
|
13936
|
+
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 && ((y = (v = a.selectedRows.value) == null ? void 0 : v.length) != null ? y : 0) > 1 || ((p = n.value) == null ? void 0 : p.permission_type) === 2 && !t.p((m = n.value) == null ? void 0 : m.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
13932
13937
|
});
|
13933
13938
|
async function l() {
|
13934
13939
|
e.onKgClick && await e.onKgClick() || r.store.setIsDeleting(r.formID, !0);
|
@@ -13965,31 +13970,31 @@ const KgButtonCreate = defineComponent({
|
|
13965
13970
|
props: getProps$f(),
|
13966
13971
|
setup(e) {
|
13967
13972
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgTable(), s = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), l = computed(() => {
|
13968
|
-
var y,
|
13969
|
-
return s.value ? (
|
13973
|
+
var y, p;
|
13974
|
+
return s.value ? (p = (y = s.value) == null ? void 0 : y.cmd) != null ? p : "" : null;
|
13970
13975
|
}), o = computed(() => {
|
13971
|
-
var y,
|
13972
|
-
return (
|
13976
|
+
var y, p;
|
13977
|
+
return (p = (y = s.value) == null ? void 0 : y.cmd_method) != null ? p : "GET";
|
13973
13978
|
}), i = computed(() => {
|
13974
|
-
var
|
13979
|
+
var p, m, b, C, T, E;
|
13975
13980
|
let y = {
|
13976
13981
|
pageNo: 1,
|
13977
13982
|
pageSize: 9999999,
|
13978
|
-
...(
|
13983
|
+
...(p = a.model.value) != null ? p : {}
|
13979
13984
|
};
|
13980
13985
|
return s.value && (y = {
|
13981
13986
|
...y,
|
13982
|
-
...KgVarUtil.parseCommandParameter((b = (
|
13987
|
+
...KgVarUtil.parseCommandParameter((b = (m = s.value) == null ? void 0 : m.cmd_prm) != null ? b : "")
|
13983
13988
|
}), (C = r.varGridConfig.value) != null && C.cmd_prm && (y = {
|
13984
13989
|
...y,
|
13985
|
-
...KgVarUtil.parseCommandParameter((
|
13986
|
-
}), ((
|
13990
|
+
...KgVarUtil.parseCommandParameter((T = r.varGridConfig.value.cmd_prm) != null ? T : "")
|
13991
|
+
}), ((E = r.varGridConfig.value) == null ? void 0 : E.convert_sort_field_to_under_score_flg) === 1 && y.column && (y.column = snakeCase$1(y.column)), y;
|
13987
13992
|
}), c = computed(() => {
|
13988
|
-
var y,
|
13989
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((y = s.value) == null ? void 0 : y.dis_no_select_flg) === 1 && ((
|
13993
|
+
var y, p, m, b, C, T, E, A;
|
13994
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((y = s.value) == null ? void 0 : y.dis_no_select_flg) === 1 && ((m = (p = n.selectedRows.value) == null ? void 0 : p.length) != null ? m : 0) === 0 || ((b = s.value) == null ? void 0 : b.dis_mult_select_flg) === 1 && ((T = (C = n.selectedRows.value) == null ? void 0 : C.length) != null ? T : 0) > 1 || ((E = s.value) == null ? void 0 : E.permission_type) === 2 && !t.p((A = s.value) == null ? void 0 : A.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
13990
13995
|
}), u = ref(!1);
|
13991
13996
|
async function d() {
|
13992
|
-
var y,
|
13997
|
+
var y, p;
|
13993
13998
|
if (!(e.onKgClick && await e.onKgClick())) {
|
13994
13999
|
if (!l.value) {
|
13995
14000
|
KgLogger.error("[KgButton] '\u5BFC\u51FA\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -13999,7 +14004,7 @@ const KgButtonCreate = defineComponent({
|
|
13999
14004
|
}
|
14000
14005
|
u.value = !0;
|
14001
14006
|
try {
|
14002
|
-
const
|
14007
|
+
const m = await httpClient().request({
|
14003
14008
|
method: o.value,
|
14004
14009
|
url: l.value,
|
14005
14010
|
params: i.value,
|
@@ -14008,9 +14013,9 @@ const KgButtonCreate = defineComponent({
|
|
14008
14013
|
joinParamsToUrl: !0,
|
14009
14014
|
isTransformResponse: !1
|
14010
14015
|
}), b = (y = s.value) == null ? void 0 : y.export_excel_filename;
|
14011
|
-
KgUtil.downloadFile(
|
14012
|
-
} catch (
|
14013
|
-
throw
|
14016
|
+
KgUtil.downloadFile(m, `${b ? r.t(b).value : t.t("kg.export")}.${(p = s.value) == null ? void 0 : p.export_excel_suffix}`);
|
14017
|
+
} catch (m) {
|
14018
|
+
throw m;
|
14014
14019
|
} finally {
|
14015
14020
|
u.value = !1;
|
14016
14021
|
}
|
@@ -14027,7 +14032,7 @@ const KgButtonCreate = defineComponent({
|
|
14027
14032
|
return e.kgText ? e.kgText : t.t("kg.export");
|
14028
14033
|
}
|
14029
14034
|
return () => {
|
14030
|
-
var y,
|
14035
|
+
var y, p, m, b;
|
14031
14036
|
return createVNode(Button, {
|
14032
14037
|
type: "primary",
|
14033
14038
|
disabled: c.value,
|
@@ -14035,8 +14040,8 @@ const KgButtonCreate = defineComponent({
|
|
14035
14040
|
loading: u.value,
|
14036
14041
|
onClick: d,
|
14037
14042
|
"kg-id": (y = s.value) == null ? void 0 : y.id,
|
14038
|
-
"kg-frm_id": (
|
14039
|
-
"kg-var_nam": (
|
14043
|
+
"kg-frm_id": (p = s.value) == null ? void 0 : p.frm_id,
|
14044
|
+
"kg-var_nam": (m = s.value) == null ? void 0 : m.var_nam,
|
14040
14045
|
"kg-cmd": (b = s.value) == null ? void 0 : b.cmd
|
14041
14046
|
}, {
|
14042
14047
|
default: () => [g(), v()]
|
@@ -14052,25 +14057,25 @@ const KgButtonCreate = defineComponent({
|
|
14052
14057
|
attrs: r
|
14053
14058
|
}) {
|
14054
14059
|
const a = useKg(), n = useKgVar(), s = useKgSearch(), l = useKgTable(), o = computed(() => n.store.getVarButton(n.formID, e.kgVarName)), i = computed(() => {
|
14055
|
-
var
|
14056
|
-
return o.value ? (b = (
|
14060
|
+
var m, b;
|
14061
|
+
return o.value ? (b = (m = o.value) == null ? void 0 : m.cmd) != null ? b : "" : null;
|
14057
14062
|
}), c = computed(() => {
|
14058
|
-
var
|
14059
|
-
return (b = (
|
14063
|
+
var m, b;
|
14064
|
+
return (b = (m = o.value) == null ? void 0 : m.cmd_method) != null ? b : "POST";
|
14060
14065
|
}), u = computed(() => {
|
14061
|
-
var b, C,
|
14062
|
-
let
|
14066
|
+
var b, C, T;
|
14067
|
+
let m = {
|
14063
14068
|
...(b = s.model.value) != null ? b : {}
|
14064
14069
|
};
|
14065
|
-
return o.value && (
|
14066
|
-
...
|
14067
|
-
...KgVarUtil.parseCommandParameter((
|
14068
|
-
}),
|
14070
|
+
return o.value && (m = {
|
14071
|
+
...m,
|
14072
|
+
...KgVarUtil.parseCommandParameter((T = (C = o.value) == null ? void 0 : C.cmd_prm) != null ? T : "")
|
14073
|
+
}), m;
|
14069
14074
|
}), d = computed(() => {
|
14070
|
-
var
|
14071
|
-
return n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value || l.isRetrieving.value || ((
|
14075
|
+
var m, b, C, T, E, A, k, R;
|
14076
|
+
return n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value || l.isRetrieving.value || ((m = o.value) == null ? void 0 : m.dis_no_select_flg) === 1 && ((C = (b = l.selectedRows.value) == null ? void 0 : b.length) != null ? C : 0) === 0 || ((T = o.value) == null ? void 0 : T.dis_mult_select_flg) === 1 && ((A = (E = l.selectedRows.value) == null ? void 0 : E.length) != null ? A : 0) > 1 || ((k = o.value) == null ? void 0 : k.permission_type) === 2 && !a.p((R = o.value) == null ? void 0 : R.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
14072
14077
|
}), g = ref(!1);
|
14073
|
-
async function v(
|
14078
|
+
async function v(m) {
|
14074
14079
|
if (!i.value)
|
14075
14080
|
return KgLogger.error("[KgButton] '\u5BFC\u5165\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
14076
14081
|
VarButton: o.value
|
@@ -14078,7 +14083,7 @@ const KgButtonCreate = defineComponent({
|
|
14078
14083
|
g.value = !0;
|
14079
14084
|
try {
|
14080
14085
|
const b = new FormData();
|
14081
|
-
b.append("file",
|
14086
|
+
b.append("file", m);
|
14082
14087
|
const C = await httpClient().axiosInstance.request({
|
14083
14088
|
method: c.value,
|
14084
14089
|
baseURL: window._CONFIG.domianURL,
|
@@ -14105,7 +14110,7 @@ const KgButtonCreate = defineComponent({
|
|
14105
14110
|
icon: e.kgIcon
|
14106
14111
|
}, null)]) : createVNode(DownloadOutlined$1, null, null);
|
14107
14112
|
}
|
14108
|
-
function
|
14113
|
+
function p() {
|
14109
14114
|
return e.kgText ? e.kgText : a.t("kg.import");
|
14110
14115
|
}
|
14111
14116
|
return () => createVNode(Upload, {
|
@@ -14115,19 +14120,19 @@ const KgButtonCreate = defineComponent({
|
|
14115
14120
|
disabled: g.value
|
14116
14121
|
}, {
|
14117
14122
|
default: () => {
|
14118
|
-
var
|
14123
|
+
var m, b, C, T;
|
14119
14124
|
return [createVNode(Button, {
|
14120
14125
|
class: r.class,
|
14121
14126
|
type: "primary",
|
14122
14127
|
disabled: d.value,
|
14123
14128
|
ghost: !e.kgPrimary && !d.value,
|
14124
14129
|
loading: g.value,
|
14125
|
-
"kg-id": (
|
14130
|
+
"kg-id": (m = o.value) == null ? void 0 : m.id,
|
14126
14131
|
"kg-frm_id": (b = o.value) == null ? void 0 : b.frm_id,
|
14127
14132
|
"kg-var_nam": (C = o.value) == null ? void 0 : C.var_nam,
|
14128
|
-
"kg-cmd": (
|
14133
|
+
"kg-cmd": (T = o.value) == null ? void 0 : T.cmd
|
14129
14134
|
}, {
|
14130
|
-
default: () => [y(),
|
14135
|
+
default: () => [y(), p()]
|
14131
14136
|
})];
|
14132
14137
|
}
|
14133
14138
|
});
|
@@ -14137,29 +14142,29 @@ const KgButtonCreate = defineComponent({
|
|
14137
14142
|
props: getProps$f(),
|
14138
14143
|
setup(e) {
|
14139
14144
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgTable(), s = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), l = computed(() => {
|
14140
|
-
var y,
|
14141
|
-
return s.value ? (
|
14145
|
+
var y, p;
|
14146
|
+
return s.value ? (p = (y = s.value) == null ? void 0 : y.cmd) != null ? p : "" : null;
|
14142
14147
|
}), o = computed(() => {
|
14143
|
-
var y,
|
14144
|
-
return (
|
14148
|
+
var y, p;
|
14149
|
+
return (p = (y = s.value) == null ? void 0 : y.cmd_method) != null ? p : "GET";
|
14145
14150
|
}), i = computed(() => {
|
14146
|
-
var
|
14151
|
+
var p, m, b, C, T;
|
14147
14152
|
let y = {
|
14148
|
-
...(
|
14153
|
+
...(p = a.model.value) != null ? p : {}
|
14149
14154
|
};
|
14150
14155
|
return s.value && (y = {
|
14151
14156
|
...y,
|
14152
|
-
...KgVarUtil.parseCommandParameter((b = (
|
14157
|
+
...KgVarUtil.parseCommandParameter((b = (m = s.value) == null ? void 0 : m.cmd_prm) != null ? b : "")
|
14153
14158
|
}), (C = r.varGridConfig.value) != null && C.cmd_prm && (y = {
|
14154
14159
|
...y,
|
14155
|
-
...KgVarUtil.parseCommandParameter((
|
14160
|
+
...KgVarUtil.parseCommandParameter((T = r.varGridConfig.value.cmd_prm) != null ? T : "")
|
14156
14161
|
}), y;
|
14157
14162
|
}), c = computed(() => {
|
14158
|
-
var y,
|
14159
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((y = s.value) == null ? void 0 : y.dis_no_select_flg) === 1 && ((
|
14163
|
+
var y, p, m, b, C, T, E, A;
|
14164
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((y = s.value) == null ? void 0 : y.dis_no_select_flg) === 1 && ((m = (p = n.selectedRows.value) == null ? void 0 : p.length) != null ? m : 0) === 0 || ((b = s.value) == null ? void 0 : b.dis_mult_select_flg) === 1 && ((T = (C = n.selectedRows.value) == null ? void 0 : C.length) != null ? T : 0) > 1 || ((E = s.value) == null ? void 0 : E.permission_type) === 2 && !t.p((A = s.value) == null ? void 0 : A.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
14160
14165
|
}), u = ref(!1);
|
14161
14166
|
async function d() {
|
14162
|
-
var y,
|
14167
|
+
var y, p;
|
14163
14168
|
if (!l.value) {
|
14164
14169
|
KgLogger.error("[KgButton] '\u4E0B\u8F7D\u5BFC\u5165\u6A21\u677F\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
14165
14170
|
VarButton: s.value
|
@@ -14168,7 +14173,7 @@ const KgButtonCreate = defineComponent({
|
|
14168
14173
|
}
|
14169
14174
|
u.value = !0;
|
14170
14175
|
try {
|
14171
|
-
const
|
14176
|
+
const m = await httpClient().request({
|
14172
14177
|
method: o.value,
|
14173
14178
|
url: l.value,
|
14174
14179
|
params: i.value,
|
@@ -14177,9 +14182,9 @@ const KgButtonCreate = defineComponent({
|
|
14177
14182
|
joinParamsToUrl: !0,
|
14178
14183
|
isTransformResponse: !1
|
14179
14184
|
}), b = (y = s.value) == null ? void 0 : y.export_excel_filename;
|
14180
|
-
KgUtil.downloadFile(
|
14181
|
-
} catch (
|
14182
|
-
throw
|
14185
|
+
KgUtil.downloadFile(m, `${b ? r.t(b).value : t.t("kg.importTemplate")}.${(p = s.value) == null ? void 0 : p.export_excel_suffix}`);
|
14186
|
+
} catch (m) {
|
14187
|
+
throw m;
|
14183
14188
|
} finally {
|
14184
14189
|
u.value = !1;
|
14185
14190
|
}
|
@@ -14195,7 +14200,7 @@ const KgButtonCreate = defineComponent({
|
|
14195
14200
|
return e.kgText ? e.kgText : t.t("kg.downloadImportTemplate");
|
14196
14201
|
}
|
14197
14202
|
return () => {
|
14198
|
-
var y,
|
14203
|
+
var y, p, m, b;
|
14199
14204
|
return createVNode(Button, {
|
14200
14205
|
type: "primary",
|
14201
14206
|
disabled: c.value,
|
@@ -14203,8 +14208,8 @@ const KgButtonCreate = defineComponent({
|
|
14203
14208
|
loading: u.value,
|
14204
14209
|
onClick: d,
|
14205
14210
|
"kg-id": (y = s.value) == null ? void 0 : y.id,
|
14206
|
-
"kg-frm_id": (
|
14207
|
-
"kg-var_nam": (
|
14211
|
+
"kg-frm_id": (p = s.value) == null ? void 0 : p.frm_id,
|
14212
|
+
"kg-var_nam": (m = s.value) == null ? void 0 : m.var_nam,
|
14208
14213
|
"kg-cmd": (b = s.value) == null ? void 0 : b.cmd
|
14209
14214
|
}, {
|
14210
14215
|
default: () => [g(), v()]
|
@@ -14216,11 +14221,11 @@ const KgButtonCreate = defineComponent({
|
|
14216
14221
|
props: getProps$f(),
|
14217
14222
|
setup(e) {
|
14218
14223
|
const t = useKg(), r = useKgVar(), a = useKgSearch(), n = useKgButton(), s = useKgTable(), l = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), o = computed(() => {
|
14219
|
-
var d, g, v, y,
|
14220
|
-
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || s.isRetrieving.value || ((d = l.value) == null ? void 0 : d.dis_no_select_flg) === 1 && ((v = (g = s.selectedRows.value) == null ? void 0 : g.length) != null ? v : 0) === 0 || ((y = l.value) == null ? void 0 : y.dis_mult_select_flg) === 1 && ((
|
14224
|
+
var d, g, v, y, p, m, b, C;
|
14225
|
+
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || s.isRetrieving.value || ((d = l.value) == null ? void 0 : d.dis_no_select_flg) === 1 && ((v = (g = s.selectedRows.value) == null ? void 0 : g.length) != null ? v : 0) === 0 || ((y = l.value) == null ? void 0 : y.dis_mult_select_flg) === 1 && ((m = (p = s.selectedRows.value) == null ? void 0 : p.length) != null ? m : 0) > 1 || ((b = l.value) == null ? void 0 : b.permission_type) === 2 && !t.p((C = l.value) == null ? void 0 : C.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
14221
14226
|
});
|
14222
14227
|
async function i() {
|
14223
|
-
var y,
|
14228
|
+
var y, p, m;
|
14224
14229
|
if (e.onKgClick && await e.onKgClick())
|
14225
14230
|
return;
|
14226
14231
|
const d = (y = e.kgButton) == null ? void 0 : y.cmd;
|
@@ -14232,14 +14237,14 @@ const KgButtonCreate = defineComponent({
|
|
14232
14237
|
}
|
14233
14238
|
let g = null;
|
14234
14239
|
const v = async () => {
|
14235
|
-
var C,
|
14240
|
+
var C, T, E, A, k, R;
|
14236
14241
|
g == null || g.showLoading(), r.store.setIsOtherRequesting(r.formID, !0);
|
14237
14242
|
const b = s.selectedRows.value;
|
14238
14243
|
try {
|
14239
14244
|
const D = await httpClient().request({
|
14240
|
-
method: (
|
14245
|
+
method: (T = (C = e.kgButton) == null ? void 0 : C.cmd_method) != null ? T : "POST",
|
14241
14246
|
url: d,
|
14242
|
-
params: KgVarUtil.parseCommandParameter((A = (
|
14247
|
+
params: KgVarUtil.parseCommandParameter((A = (E = e.kgButton) == null ? void 0 : E.cmd_prm) != null ? A : ""),
|
14243
14248
|
data: b != null ? b : []
|
14244
14249
|
});
|
14245
14250
|
if (((k = e.kgButton) == null ? void 0 : k.reload_all_after_done_flg) === 1) {
|
@@ -14265,8 +14270,8 @@ const KgButtonCreate = defineComponent({
|
|
14265
14270
|
r.store.setIsOtherRequesting(r.formID, !1), g == null || g.hideLoading();
|
14266
14271
|
}
|
14267
14272
|
};
|
14268
|
-
if (((
|
14269
|
-
const b = KgUtil.tryParseJSON((
|
14273
|
+
if (((p = e.kgButton) == null ? void 0 : p.show_modal_flg) === 1) {
|
14274
|
+
const b = KgUtil.tryParseJSON((m = e.kgButton) == null ? void 0 : m.modal_props);
|
14270
14275
|
typeof b.content == "string" && (b.content = r.t(b.content).value), g = KgUtil.confirm({
|
14271
14276
|
onOk: () => v(),
|
14272
14277
|
...b
|
@@ -14350,18 +14355,18 @@ const KgButtonCreate = defineComponent({
|
|
14350
14355
|
}) {
|
14351
14356
|
const n = useKg(), s = useKgVar(), l = useKgTable(), o = useKgButton(), i = useKgSubmit();
|
14352
14357
|
o.store.$onAction(async ({
|
14353
|
-
name:
|
14354
|
-
args:
|
14358
|
+
name: T,
|
14359
|
+
args: E
|
14355
14360
|
}) => {
|
14356
|
-
switch (
|
14361
|
+
switch (T) {
|
14357
14362
|
case "click":
|
14358
|
-
|
14363
|
+
E[0] === s.formID && await g();
|
14359
14364
|
break;
|
14360
14365
|
}
|
14361
14366
|
});
|
14362
14367
|
const c = computed(() => s.store.getVarButton(s.formID, e.kgVarName)), u = computed(() => {
|
14363
|
-
var
|
14364
|
-
return s.isCreating.value || s.isCopying.value || s.isDeleting.value || l.isRetrieving.value || ((
|
14368
|
+
var T, E, A, k, R, D, I, M;
|
14369
|
+
return s.isCreating.value || s.isCopying.value || s.isDeleting.value || l.isRetrieving.value || ((T = c.value) == null ? void 0 : T.dis_no_select_flg) === 1 && ((A = (E = l.selectedRows.value) == null ? void 0 : E.length) != null ? A : 0) === 0 || ((k = c.value) == null ? void 0 : k.dis_mult_select_flg) === 1 && ((D = (R = l.selectedRows.value) == null ? void 0 : R.length) != null ? D : 0) > 1 || ((I = c.value) == null ? void 0 : I.permission_type) === 2 && !n.p((M = c.value) == null ? void 0 : M.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
14365
14370
|
}), d = computed(() => !!s.isUpdatingRequesting.value);
|
14366
14371
|
async function g() {
|
14367
14372
|
e.onKgClick && await e.onKgClick() || await o.store.emit(s.formID, "updateBeforeClick", {
|
@@ -14375,30 +14380,30 @@ const KgButtonCreate = defineComponent({
|
|
14375
14380
|
function y() {
|
14376
14381
|
o.store.emit(s.formID, "submitCancel", {});
|
14377
14382
|
}
|
14378
|
-
function
|
14383
|
+
function p() {
|
14379
14384
|
return e.kgIcon ? createVNode("span", {
|
14380
14385
|
class: "anticon"
|
14381
14386
|
}, [createVNode(Icon, {
|
14382
14387
|
icon: e.kgIcon
|
14383
14388
|
}, null)]) : createVNode(EditOutlined$1, null, null);
|
14384
14389
|
}
|
14385
|
-
function
|
14390
|
+
function m() {
|
14386
14391
|
return e.kgText ? e.kgText : n.t("kg.update");
|
14387
14392
|
}
|
14388
14393
|
function b() {
|
14389
|
-
var
|
14394
|
+
var T, E, A, k;
|
14390
14395
|
return i.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && s.isUpdating.value ? null : createVNode(Button, {
|
14391
14396
|
type: "primary",
|
14392
14397
|
disabled: u.value,
|
14393
14398
|
ghost: !e.kgPrimary && !u.value,
|
14394
14399
|
onClick: g,
|
14395
14400
|
class: a.class,
|
14396
|
-
"kg-id": (
|
14397
|
-
"kg-frm_id": (
|
14401
|
+
"kg-id": (T = c.value) == null ? void 0 : T.id,
|
14402
|
+
"kg-frm_id": (E = c.value) == null ? void 0 : E.frm_id,
|
14398
14403
|
"kg-var_nam": (A = c.value) == null ? void 0 : A.var_nam,
|
14399
14404
|
"kg-cmd": (k = c.value) == null ? void 0 : k.cmd
|
14400
14405
|
}, {
|
14401
|
-
default: () => [
|
14406
|
+
default: () => [p(), m()]
|
14402
14407
|
});
|
14403
14408
|
}
|
14404
14409
|
function C() {
|
@@ -14486,22 +14491,22 @@ const getProps$e = () => ({
|
|
14486
14491
|
props: getProps$e(),
|
14487
14492
|
setup(e) {
|
14488
14493
|
const t = inject(DI_KG_VAR__KG_SLOTS, null), r = inject(DI_KG_VAR__KG_PROPS, null), a = useKg(), n = useKgVar(), s = useKgButton(), l = computed(() => !1);
|
14489
|
-
function o(
|
14490
|
-
return s.store.emit(n.formID, "click",
|
14494
|
+
function o(p) {
|
14495
|
+
return s.store.emit(n.formID, "click", p);
|
14491
14496
|
}
|
14492
|
-
function i(
|
14497
|
+
function i(p) {
|
14493
14498
|
return computed(() => {
|
14494
14499
|
var b, C;
|
14495
|
-
const
|
14496
|
-
if (
|
14497
|
-
const
|
14498
|
-
if (!isNil(
|
14499
|
-
return
|
14500
|
+
const m = ((C = (b = r == null ? void 0 : r.value) == null ? void 0 : b.KgButton) == null ? void 0 : C.kgDisabled) || e.kgDisabled;
|
14501
|
+
if (m) {
|
14502
|
+
const T = m(p);
|
14503
|
+
if (!isNil(T))
|
14504
|
+
return T;
|
14500
14505
|
}
|
14501
14506
|
});
|
14502
14507
|
}
|
14503
|
-
function c(
|
14504
|
-
switch (
|
14508
|
+
function c(p) {
|
14509
|
+
switch (p.primary_flg) {
|
14505
14510
|
case 1:
|
14506
14511
|
return !0;
|
14507
14512
|
case 0:
|
@@ -14510,37 +14515,37 @@ const getProps$e = () => ({
|
|
14510
14515
|
return;
|
14511
14516
|
}
|
14512
14517
|
}
|
14513
|
-
function u(
|
14514
|
-
if (n.t(
|
14515
|
-
return n.t(
|
14518
|
+
function u(p) {
|
14519
|
+
if (n.t(p.var_nam).value !== p.var_nam)
|
14520
|
+
return n.t(p.var_nam).value;
|
14516
14521
|
}
|
14517
14522
|
function d() {
|
14518
|
-
var
|
14519
|
-
if (!n.varButtons.value || ((
|
14523
|
+
var p, m;
|
14524
|
+
if (!n.varButtons.value || ((p = n.varButtons.value) == null ? void 0 : p.length) === 0)
|
14520
14525
|
return null;
|
14521
|
-
switch ((
|
14526
|
+
switch ((m = n.varGridConfig.value) == null ? void 0 : m.button_display_type) {
|
14522
14527
|
case KG_BUTTON_DISPLAY_TYPE.SELECT:
|
14523
14528
|
return y();
|
14524
14529
|
default:
|
14525
14530
|
return v();
|
14526
14531
|
}
|
14527
14532
|
}
|
14528
|
-
function g(
|
14533
|
+
function g(p) {
|
14529
14534
|
return createVNode(KgButtonItem, {
|
14530
|
-
kgButton:
|
14531
|
-
kgVarName:
|
14532
|
-
kgType:
|
14533
|
-
kgIcon:
|
14534
|
-
kgText: u(
|
14535
|
-
kgColor:
|
14536
|
-
kgPrimary: c(
|
14537
|
-
kgDisabled: i(
|
14538
|
-
onKgClick: () => o(
|
14535
|
+
kgButton: p,
|
14536
|
+
kgVarName: p.var_nam,
|
14537
|
+
kgType: p.typ,
|
14538
|
+
kgIcon: p.icon,
|
14539
|
+
kgText: u(p),
|
14540
|
+
kgColor: p.color,
|
14541
|
+
kgPrimary: c(p),
|
14542
|
+
kgDisabled: i(p).value,
|
14543
|
+
onKgClick: () => o(p)
|
14539
14544
|
}, null);
|
14540
14545
|
}
|
14541
14546
|
function v() {
|
14542
|
-
var
|
14543
|
-
return (
|
14547
|
+
var p;
|
14548
|
+
return (p = n.varButtons.value) == null ? void 0 : p.filter((m) => m.typ !== KG_BUTTON_TYPE.SEARCH).map((m) => g(m));
|
14544
14549
|
}
|
14545
14550
|
function y() {
|
14546
14551
|
return createVNode(Dropdown, {
|
@@ -14554,8 +14559,8 @@ const getProps$e = () => ({
|
|
14554
14559
|
}),
|
14555
14560
|
overlay: () => createVNode(Menu, null, {
|
14556
14561
|
default: () => {
|
14557
|
-
var
|
14558
|
-
return [(
|
14562
|
+
var p, m;
|
14563
|
+
return [(m = (p = n.varButtons.value) == null ? void 0 : p.filter((b) => b.typ !== KG_BUTTON_TYPE.SEARCH)) == null ? void 0 : m.filter((b) => !(b.permission_type !== 2 && !a.p(b.permission_code))).map((b) => {
|
14559
14564
|
let C;
|
14560
14565
|
return createVNode(Menu.Item, null, _isSlot$3(C = g(b)) ? C : {
|
14561
14566
|
default: () => [C]
|
@@ -14574,8 +14579,8 @@ const getProps$e = () => ({
|
|
14574
14579
|
spinning: l.value
|
14575
14580
|
}, {
|
14576
14581
|
default: () => {
|
14577
|
-
var
|
14578
|
-
return [d(), (
|
14582
|
+
var p, m;
|
14583
|
+
return [d(), (m = (p = t == null ? void 0 : t.KgButton) == null ? void 0 : p.right) == null ? void 0 : m.call(p)];
|
14579
14584
|
}
|
14580
14585
|
})]);
|
14581
14586
|
}
|
@@ -15035,7 +15040,7 @@ function _useDragRow(e, t, r) {
|
|
15035
15040
|
if (n = filter(document.querySelectorAll(`tr[kg-host-frm_id="${e}"] > td.handler`), () => !0), n)
|
15036
15041
|
for (let u of n)
|
15037
15042
|
u.__kg__dragstart__ = async (d) => {
|
15038
|
-
var
|
15043
|
+
var m, b;
|
15039
15044
|
s = u.parentElement, u.classList.add("dragging"), u.parentElement.classList.add("dragging");
|
15040
15045
|
const g = document.createElement("span");
|
15041
15046
|
g.setAttribute("id", "__kg_search_config_fields_drag_image__");
|
@@ -15043,9 +15048,9 @@ function _useDragRow(e, t, r) {
|
|
15043
15048
|
width: v,
|
15044
15049
|
height: y
|
15045
15050
|
} = u.parentElement.getBoundingClientRect();
|
15046
|
-
v && y && (g.style.width = `${v + 2}px`, g.style.height = `${y + 2}px`), (
|
15047
|
-
const
|
15048
|
-
g.appendChild(
|
15051
|
+
v && y && (g.style.width = `${v + 2}px`, g.style.height = `${y + 2}px`), (m = d.dataTransfer) == null || m.setDragImage(g, -10, (y + 2) / 2);
|
15052
|
+
const p = await toCanvas(u.parentElement);
|
15053
|
+
g.appendChild(p), document.body.appendChild(g), (b = d.dataTransfer) == null || b.setDragImage(g, -10, (y + 2) / 2);
|
15049
15054
|
}, u.addEventListener("dragstart", u.__kg__dragstart__), u.__kg__dragend__ = (d) => {
|
15050
15055
|
u.classList.remove("dragging"), u.parentElement.classList.remove("dragging");
|
15051
15056
|
const g = document.querySelector("#__kg_search_config_fields_drag_image__");
|
@@ -15089,15 +15094,15 @@ function _useDragRow(e, t, r) {
|
|
15089
15094
|
}
|
15090
15095
|
function i(u, d) {
|
15091
15096
|
setTimeout(() => {
|
15092
|
-
const g = t.value.findIndex((
|
15097
|
+
const g = t.value.findIndex((m) => m.var_nam === u), v = t.value.findIndex((m) => m.var_nam === d);
|
15093
15098
|
if (g === -1 || v === -1)
|
15094
15099
|
return;
|
15095
|
-
const y = t.value.find((
|
15096
|
-
t.value.forEach((
|
15097
|
-
g > v ? b < v ?
|
15098
|
-
}),
|
15099
|
-
|
15100
|
-
}), t.value =
|
15100
|
+
const y = t.value.find((m) => m.var_nam === u), p = [];
|
15101
|
+
t.value.forEach((m, b) => {
|
15102
|
+
g > v ? b < v ? p.push(m) : b === v ? (p.push(y), p.push(m)) : b > v && b !== g && p.push(m) : g < v && (b < g ? p.push(m) : b === g || (b === v ? (p.push(m), p.push(y)) : p.push(m)));
|
15103
|
+
}), p.forEach((m, b) => {
|
15104
|
+
m.srtseq = b + 1;
|
15105
|
+
}), t.value = p, nextTick().finally(() => {
|
15101
15106
|
KgUtil.hideLoading();
|
15102
15107
|
});
|
15103
15108
|
});
|
@@ -15123,27 +15128,27 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15123
15128
|
setup(e) {
|
15124
15129
|
const t = useKg(), r = useKgVar(FORM_ID__VAR_PROFILE_MASTER, !0, 1), a = useKgSearch(r.formID), n = useKgTable(r.formID), s = useKgButton(r.formID), l = useKgSubmit(r.formID), o = useKgVar(e.hostFormID);
|
15125
15130
|
l.onOpen(async ({
|
15126
|
-
isCreating:
|
15131
|
+
isCreating: m,
|
15127
15132
|
isUpdating: b,
|
15128
15133
|
isCopying: C,
|
15129
|
-
row:
|
15130
|
-
model:
|
15134
|
+
row: T,
|
15135
|
+
model: E
|
15131
15136
|
}) => {
|
15132
15137
|
var k, R, D;
|
15133
15138
|
const A = o.store.getSystemVarProfileDetails(o.formID);
|
15134
15139
|
switch (i.value = A ? cloneDeep(unref(toRaw(A))) : [], !0) {
|
15135
|
-
case
|
15140
|
+
case m: {
|
15136
15141
|
c.value = [];
|
15137
15142
|
break;
|
15138
15143
|
}
|
15139
15144
|
case b:
|
15140
15145
|
case C: {
|
15141
|
-
if (
|
15146
|
+
if (T != null && T.id)
|
15142
15147
|
try {
|
15143
15148
|
l.store.setIsLoading(r.formID, !0);
|
15144
15149
|
const I = await QueryByID({
|
15145
15150
|
params: {
|
15146
|
-
id:
|
15151
|
+
id: T.id
|
15147
15152
|
}
|
15148
15153
|
});
|
15149
15154
|
i.value = i.value.map((P) => {
|
@@ -15169,20 +15174,20 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15169
15174
|
}
|
15170
15175
|
switch (!0) {
|
15171
15176
|
case C: {
|
15172
|
-
|
15177
|
+
E.value.prf_var_nam = ((D = E.value.prf_var_nam) != null ? D : "") + "_COPY";
|
15173
15178
|
break;
|
15174
15179
|
}
|
15175
15180
|
}
|
15176
15181
|
return !1;
|
15177
15182
|
}), l.onBeforeOk(async ({
|
15178
|
-
model:
|
15183
|
+
model: m
|
15179
15184
|
}) => {
|
15180
|
-
var C,
|
15181
|
-
const b =
|
15182
|
-
return b.frm_id = o.formID, b.varProfileDetails = (
|
15185
|
+
var C, T;
|
15186
|
+
const b = m.value;
|
15187
|
+
return b.frm_id = o.formID, b.varProfileDetails = (T = (C = i.value) == null ? void 0 : C.filter((E) => c.value.includes(E.id))) != null ? T : [], !1;
|
15183
15188
|
}), l.onOk(async () => (o.store.retrieve(o.formID), !1)), s.onUpdateBeforeClick(({
|
15184
|
-
row:
|
15185
|
-
}) => (
|
15189
|
+
row: m
|
15190
|
+
}) => (m == null ? void 0 : m.cust_lvl) === KG_CUSTOM_LEVEL.L0 ? new Promise((b) => {
|
15186
15191
|
KgUtil.confirm({
|
15187
15192
|
content: t.t("kg.KgSearchConfigModal.canNotUpdateSystemVarProfileMaster"),
|
15188
15193
|
okButtonProps: {
|
@@ -15199,7 +15204,7 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15199
15204
|
const i = ref([]), c = ref([]), u = ref([]);
|
15200
15205
|
_useDragRow(e.hostFormID, i, u);
|
15201
15206
|
const d = computed(() => {
|
15202
|
-
const
|
15207
|
+
const m = n.selectedRow.value;
|
15203
15208
|
return {
|
15204
15209
|
KgSubmit: {
|
15205
15210
|
kgClass: "kg-submit--search-config-modal--profile"
|
@@ -15208,7 +15213,7 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15208
15213
|
kgDisabled: (b) => {
|
15209
15214
|
switch (b.var_nam) {
|
15210
15215
|
case "set-default":
|
15211
|
-
if ((
|
15216
|
+
if ((m == null ? void 0 : m.def_flg) === 1)
|
15212
15217
|
return !0;
|
15213
15218
|
break;
|
15214
15219
|
}
|
@@ -15221,22 +15226,22 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15221
15226
|
varProfileDetails: () => createVNode(Transfer, {
|
15222
15227
|
dataSource: i.value,
|
15223
15228
|
targetKeys: c.value,
|
15224
|
-
"onUpdate:targetKeys": (
|
15225
|
-
rowKey: (
|
15229
|
+
"onUpdate:targetKeys": (m) => c.value = m,
|
15230
|
+
rowKey: (m) => m.id,
|
15226
15231
|
showSearch: !0,
|
15227
15232
|
showSelectAll: !1,
|
15228
15233
|
searchPlaceholder: " ",
|
15229
|
-
filterOption: (
|
15234
|
+
filterOption: (m, b) => {
|
15230
15235
|
var C;
|
15231
|
-
return !!((C = b.var_nam) != null && C.includes(
|
15236
|
+
return !!((C = b.var_nam) != null && C.includes(m));
|
15232
15237
|
}
|
15233
15238
|
}, {
|
15234
15239
|
children: ({
|
15235
|
-
direction:
|
15240
|
+
direction: m,
|
15236
15241
|
filteredItems: b,
|
15237
15242
|
selectedKeys: C,
|
15238
|
-
disabled:
|
15239
|
-
onItemSelectAll:
|
15243
|
+
disabled: T,
|
15244
|
+
onItemSelectAll: E,
|
15240
15245
|
onItemSelect: A
|
15241
15246
|
}) => {
|
15242
15247
|
const k = b.sort((R, D) => {
|
@@ -15248,22 +15253,22 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15248
15253
|
class: "kg-flex-table",
|
15249
15254
|
size: "small",
|
15250
15255
|
scroll: {
|
15251
|
-
x:
|
15256
|
+
x: m === "left" ? "370px" : "1174px",
|
15252
15257
|
y: "auto"
|
15253
15258
|
},
|
15254
|
-
columns:
|
15259
|
+
columns: m === "left" ? leftVarProfileDetailColumns(e.hostFormID) : rightVarProfileDetailColumns(e.hostFormID),
|
15255
15260
|
rowKey: "id",
|
15256
15261
|
dataSource: k,
|
15257
15262
|
customRow: (R) => {
|
15258
15263
|
let D = {
|
15259
|
-
onClick: (I) =>
|
15264
|
+
onClick: (I) => p(I, R, m, C)
|
15260
15265
|
};
|
15261
|
-
return
|
15266
|
+
return m === "right" && (D["kg-host-frm_id"] = o.formID, D["kg-var_nam"] = R.var_nam), D;
|
15262
15267
|
},
|
15263
15268
|
rowSelection: v({
|
15264
|
-
disabled:
|
15269
|
+
disabled: T,
|
15265
15270
|
selectedKeys: C,
|
15266
|
-
onItemSelectAll:
|
15271
|
+
onItemSelectAll: E,
|
15267
15272
|
onItemSelect: A
|
15268
15273
|
})
|
15269
15274
|
}, null);
|
@@ -15276,42 +15281,42 @@ const KgSearch_ConfigModal_VarProfileMaster = "", getProps$c = () => ({
|
|
15276
15281
|
y();
|
15277
15282
|
});
|
15278
15283
|
const v = ({
|
15279
|
-
disabled:
|
15284
|
+
disabled: m,
|
15280
15285
|
selectedKeys: b,
|
15281
15286
|
onItemSelectAll: C,
|
15282
|
-
onItemSelect:
|
15287
|
+
onItemSelect: T
|
15283
15288
|
}) => ({
|
15284
|
-
getCheckboxProps: (
|
15285
|
-
disabled:
|
15289
|
+
getCheckboxProps: (E) => ({
|
15290
|
+
disabled: m || E.disabled
|
15286
15291
|
}),
|
15287
|
-
onSelectAll(
|
15292
|
+
onSelectAll(E, A) {
|
15288
15293
|
const k = A.filter((R) => !R.disabled).map(({
|
15289
15294
|
key: R
|
15290
15295
|
}) => R);
|
15291
|
-
C(k,
|
15296
|
+
C(k, E);
|
15292
15297
|
},
|
15293
15298
|
onSelect({
|
15294
|
-
key:
|
15299
|
+
key: E
|
15295
15300
|
}, A) {
|
15296
|
-
E
|
15301
|
+
T(E, A);
|
15297
15302
|
},
|
15298
15303
|
selectedRowKeys: b,
|
15299
15304
|
columnWidth: 32
|
15300
15305
|
});
|
15301
15306
|
async function y() {
|
15302
|
-
const
|
15303
|
-
b && a.model.value && (setTimeout(() =>
|
15307
|
+
const m = watch(a.isReady, async (b) => {
|
15308
|
+
b && a.model.value && (setTimeout(() => m(), 0), await a.store.patchModel(r.formID, {
|
15304
15309
|
frm_id: e.hostFormID
|
15305
15310
|
}), a.search());
|
15306
15311
|
}, {
|
15307
15312
|
immediate: !0
|
15308
15313
|
});
|
15309
15314
|
}
|
15310
|
-
function m
|
15311
|
-
if (!KgDomUtil.isNotClickable(
|
15312
|
-
switch (
|
15315
|
+
function p(m, b, C, T) {
|
15316
|
+
if (!KgDomUtil.isNotClickable(m.target, ["ant-input"]))
|
15317
|
+
switch (T.length = 0, m.detail) {
|
15313
15318
|
case 1:
|
15314
|
-
|
15319
|
+
T[0] = b.id;
|
15315
15320
|
break;
|
15316
15321
|
case 2:
|
15317
15322
|
switch (C) {
|
@@ -15456,9 +15461,9 @@ function _useFormModel(e, t) {
|
|
15456
15461
|
async function u() {
|
15457
15462
|
var d;
|
15458
15463
|
((d = a.currentVarProfileDetails.value) != null ? d : []).forEach((g) => {
|
15459
|
-
var y,
|
15464
|
+
var y, p, m;
|
15460
15465
|
const v = (y = g.var_nam) != null ? y : "";
|
15461
|
-
i.value[v] = KgVarUtil.transformFormItemValue(a.formID, v, r, (
|
15466
|
+
i.value[v] = KgVarUtil.transformFormItemValue(a.formID, v, r, (p = g.dft_val) != null ? p : void 0, "R"), c.value[v] = KgVarUtil.transformFormItemDynamicQueryOperator(a.formID, v, (m = g.dft_dyn_op) != null ? m : void 0);
|
15462
15467
|
}), t.value.kgHeight = l.value, n.store.setModel(a.formID, i.value), n.store.setOperatorModel(a.formID, c.value), s.value ? (o == null || o(), o = watch(e, async (g) => {
|
15463
15468
|
g && (await n.store.emit(a.formID, "ready", {}), n.store.setIsReady(a.formID, !0));
|
15464
15469
|
}, {
|
@@ -15501,7 +15506,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
15501
15506
|
kgHeight: g.value
|
15502
15507
|
});
|
15503
15508
|
_useLayoutHeaderResizeObserver();
|
15504
|
-
const
|
15509
|
+
const p = _useFormModel(v, y), m = computed(() => {
|
15505
15510
|
var L, B, Y, Q;
|
15506
15511
|
if (!isNil((B = (L = r == null ? void 0 : r.value) == null ? void 0 : L.KgSearch) == null ? void 0 : B.kgDisabled))
|
15507
15512
|
return (Q = (Y = r == null ? void 0 : r.value) == null ? void 0 : Y.KgSearch) == null ? void 0 : Q.kgDisabled;
|
@@ -15509,8 +15514,8 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
15509
15514
|
return e.kgDisabled;
|
15510
15515
|
}), b = computed(() => {
|
15511
15516
|
var L, B;
|
15512
|
-
return !!(
|
15513
|
-
}), C = computed(() => !!(
|
15517
|
+
return !!(m.value || l.isRetrieving.value || ((L = n.varButtonSearch.value) == null ? void 0 : L.permission_type) === 2 && !a.p((B = n.varButtonSearch.value) == null ? void 0 : B.permission_code) || n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value);
|
15518
|
+
}), C = computed(() => !!(m.value || l.isRetrieving.value || n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value)), T = computed(() => !!(m.value || l.isRetrieving.value)), E = ref({
|
15514
15519
|
visible: !1
|
15515
15520
|
}), A = computed(() => y.value.kgHeight === g.value), k = computed(() => {
|
15516
15521
|
var L, B, Y;
|
@@ -15552,7 +15557,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
15552
15557
|
}
|
15553
15558
|
s.store.setSearchFn(n.formID, P);
|
15554
15559
|
async function N() {
|
15555
|
-
|
15560
|
+
p.initFormModel(), o.value ? v.value && v.value.validate().then(async () => {
|
15556
15561
|
await s.store.emit(n.formID, "reset", {});
|
15557
15562
|
}).catch((L) => {
|
15558
15563
|
KgLogger.debug("[KgSearch] \u8868\u5355\u9A8C\u8BC1\u5931\u8D25", {
|
@@ -15598,14 +15603,14 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
15598
15603
|
}), createVNode(Button, {
|
15599
15604
|
disabled: C.value,
|
15600
15605
|
onClick: () => {
|
15601
|
-
|
15606
|
+
E.value.visible = !0;
|
15602
15607
|
},
|
15603
15608
|
class: "kg-search-profile-master-btn"
|
15604
15609
|
}, {
|
15605
15610
|
default: () => [createVNode(SettingOutlined$1, null, null)]
|
15606
15611
|
}), createVNode(KgSearchConfigModal, {
|
15607
|
-
visible:
|
15608
|
-
"onUpdate:visible": (z) =>
|
15612
|
+
visible: E.value.visible,
|
15613
|
+
"onUpdate:visible": (z) => E.value.visible = z,
|
15609
15614
|
hostFormID: n.formID
|
15610
15615
|
}, null)]);
|
15611
15616
|
}
|
@@ -15626,7 +15631,7 @@ const KgSearch$1 = "", getProps$9 = () => ({
|
|
15626
15631
|
kgText: k.value,
|
15627
15632
|
kgColor: (z = n.varButtonSearch.value) == null ? void 0 : z.color,
|
15628
15633
|
kgPrimary: R.value,
|
15629
|
-
kgLoading:
|
15634
|
+
kgLoading: T.value,
|
15630
15635
|
onKgClick: U
|
15631
15636
|
}, null)]);
|
15632
15637
|
}
|
@@ -15747,35 +15752,35 @@ function useMagicKeys(e = {}) {
|
|
15747
15752
|
} = e, l = reactive(/* @__PURE__ */ new Set()), o = { toJSON() {
|
15748
15753
|
return {};
|
15749
15754
|
}, current: l }, i = t ? reactive(o) : o, c = /* @__PURE__ */ new Set(), u = /* @__PURE__ */ new Set();
|
15750
|
-
function d(
|
15751
|
-
|
15755
|
+
function d(p, m) {
|
15756
|
+
p in i && (t ? i[p] = m : i[p].value = m);
|
15752
15757
|
}
|
15753
15758
|
function g() {
|
15754
|
-
for (const
|
15755
|
-
d(
|
15759
|
+
for (const p of u)
|
15760
|
+
d(p, !1);
|
15756
15761
|
}
|
15757
|
-
function v(
|
15762
|
+
function v(p, m) {
|
15758
15763
|
var b, C;
|
15759
|
-
const
|
15760
|
-
|
15764
|
+
const T = (b = p.key) == null ? void 0 : b.toLowerCase(), E = (C = p.code) == null ? void 0 : C.toLowerCase(), A = [E, T].filter(Boolean);
|
15765
|
+
E && (m ? l.add(p.code) : l.delete(p.code));
|
15761
15766
|
for (const k of A)
|
15762
|
-
u.add(k), d(k,
|
15763
|
-
|
15767
|
+
u.add(k), d(k, m);
|
15768
|
+
T === "meta" && !m ? (c.forEach((k) => {
|
15764
15769
|
l.delete(k), d(k, !1);
|
15765
|
-
}), c.clear()) : typeof
|
15770
|
+
}), c.clear()) : typeof p.getModifierState == "function" && p.getModifierState("Meta") && m && [...l, ...A].forEach((k) => c.add(k));
|
15766
15771
|
}
|
15767
|
-
r && (useEventListener(r, "keydown", (
|
15772
|
+
r && (useEventListener(r, "keydown", (p) => (v(p, !0), s(p)), { passive: n }), useEventListener(r, "keyup", (p) => (v(p, !1), s(p)), { passive: n }), useEventListener("blur", g, { passive: !0 }), useEventListener("focus", g, { passive: !0 }));
|
15768
15773
|
const y = new Proxy(i, {
|
15769
|
-
get(
|
15770
|
-
if (typeof
|
15771
|
-
return Reflect.get(
|
15772
|
-
if (
|
15773
|
-
if (/[+_-]/.test(
|
15774
|
-
const
|
15775
|
-
i[
|
15774
|
+
get(p, m, b) {
|
15775
|
+
if (typeof m != "string")
|
15776
|
+
return Reflect.get(p, m, b);
|
15777
|
+
if (m = m.toLowerCase(), m in a && (m = a[m]), !(m in i))
|
15778
|
+
if (/[+_-]/.test(m)) {
|
15779
|
+
const T = m.split(/[+_-]/g).map((E) => E.trim());
|
15780
|
+
i[m] = computed(() => T.every((E) => unref(y[E])));
|
15776
15781
|
} else
|
15777
|
-
i[
|
15778
|
-
const C = Reflect.get(
|
15782
|
+
i[m] = ref(!1);
|
15783
|
+
const C = Reflect.get(p, m, b);
|
15779
15784
|
return t ? unref(C) : C;
|
15780
15785
|
}
|
15781
15786
|
});
|
@@ -16164,10 +16169,10 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16164
16169
|
onSelect: (N) => R(N)
|
16165
16170
|
}), v = ref({
|
16166
16171
|
visible: !1
|
16167
|
-
}), y = computed(() => !!(unref(u) || unref(n) || unref(s) || unref(l))),
|
16172
|
+
}), y = computed(() => !!(unref(u) || unref(n) || unref(s) || unref(l))), p = computed(() => {
|
16168
16173
|
var N;
|
16169
16174
|
return !!u.value || ((N = a.getSelectedVarCatalog) == null ? void 0 : N.cust_lvl) === KG_CUSTOM_LEVEL.L0;
|
16170
|
-
}),
|
16175
|
+
}), m = computed(() => !!(!unref(u) || unref(n) || unref(s))), b = computed(() => !!(!unref(a.getSelectedVarCatalog) || unref(n)));
|
16171
16176
|
watch(() => a.getSelectedVar, (N) => {
|
16172
16177
|
N ? C() : (u.value = null, c.value = [], a.setSelectedVarCatalog(null));
|
16173
16178
|
}, {
|
@@ -16206,7 +16211,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16206
16211
|
n.value = !1;
|
16207
16212
|
}
|
16208
16213
|
}
|
16209
|
-
async function
|
16214
|
+
async function T() {
|
16210
16215
|
var N, U, w;
|
16211
16216
|
try {
|
16212
16217
|
s.value = !0, await ((N = o.value) == null ? void 0 : N.validate());
|
@@ -16239,7 +16244,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16239
16244
|
s.value = !1;
|
16240
16245
|
}
|
16241
16246
|
}
|
16242
|
-
function
|
16247
|
+
function E({
|
16243
16248
|
isAllForm: N,
|
16244
16249
|
isAllLanguage: U
|
16245
16250
|
}) {
|
@@ -16300,8 +16305,8 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16300
16305
|
default: () => [createVNode(PlusOutlined$1, null, null), t.t("common.create")]
|
16301
16306
|
}), createVNode(Button, {
|
16302
16307
|
onClick: k,
|
16303
|
-
disabled:
|
16304
|
-
ghost: !
|
16308
|
+
disabled: p.value,
|
16309
|
+
ghost: !p.value,
|
16305
16310
|
type: "primary",
|
16306
16311
|
danger: !0
|
16307
16312
|
}, {
|
@@ -16315,7 +16320,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16315
16320
|
}, [createVNode(Form, {
|
16316
16321
|
ref: o,
|
16317
16322
|
model: i.value,
|
16318
|
-
onSubmit:
|
16323
|
+
onSubmit: T
|
16319
16324
|
}, {
|
16320
16325
|
default: () => [createVNode(Form.Item, {
|
16321
16326
|
name: "var_text",
|
@@ -16335,14 +16340,14 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16335
16340
|
}), createVNode("div", {
|
16336
16341
|
class: "buttons"
|
16337
16342
|
}, [createVNode(Button, {
|
16338
|
-
disabled:
|
16343
|
+
disabled: m.value,
|
16339
16344
|
onClick: A
|
16340
16345
|
}, _isSlot(N = t.t("common.cancelText")) ? N : {
|
16341
16346
|
default: () => [N]
|
16342
16347
|
}), createVNode(Button, {
|
16343
16348
|
loading: s.value,
|
16344
16349
|
disabled: b.value,
|
16345
|
-
onClick:
|
16350
|
+
onClick: T,
|
16346
16351
|
type: "primary"
|
16347
16352
|
}, _isSlot(U = t.t("common.save")) ? U : {
|
16348
16353
|
default: () => [U]
|
@@ -16375,7 +16380,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
16375
16380
|
}, null), M(), createVNode(KgVarConfigModalVarCreateModal, {
|
16376
16381
|
visible: v.value.visible,
|
16377
16382
|
"onUpdate:visible": (N) => v.value.visible = N,
|
16378
|
-
onKgOk:
|
16383
|
+
onKgOk: E
|
16379
16384
|
}, null)]);
|
16380
16385
|
}
|
16381
16386
|
}), columns = () => [{
|
@@ -16679,16 +16684,16 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16679
16684
|
emit: t
|
16680
16685
|
}) {
|
16681
16686
|
const r = useKg(), a = useKgWarehouse(), n = computed(() => {
|
16682
|
-
let
|
16683
|
-
return (!g.value || e.kgInvisible) && (
|
16687
|
+
let E = "jeecg-layout-header-action__item kg-warehouse";
|
16688
|
+
return (!g.value || e.kgInvisible) && (E += " kg-warehouse--invisible"), E;
|
16684
16689
|
}), s = ref(""), l = a.warehouse, o = ref(null), i = ref(!1), c = reactive([{
|
16685
16690
|
width: 80,
|
16686
16691
|
align: "center",
|
16687
16692
|
customRender: ({
|
16688
|
-
record:
|
16693
|
+
record: E
|
16689
16694
|
}) => {
|
16690
16695
|
var k;
|
16691
|
-
return
|
16696
|
+
return E.id === ((k = o.value) == null ? void 0 : k.id) ? createVNode("img", {
|
16692
16697
|
src: WAREHOUSE_1890ff
|
16693
16698
|
}, null) : createVNode("img", {
|
16694
16699
|
src: WAREHOUSE_000000
|
@@ -16696,27 +16701,27 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16696
16701
|
}
|
16697
16702
|
}, {
|
16698
16703
|
customRender: ({
|
16699
|
-
record:
|
16704
|
+
record: E
|
16700
16705
|
}) => {
|
16701
16706
|
var k, R, D;
|
16702
|
-
const A =
|
16707
|
+
const A = E;
|
16703
16708
|
return createVNode("div", null, [createVNode("div", null, [(k = A.whDsc) != null ? k : " ", createTextVNode(" - "), (R = A.whId) != null ? R : " "]), createVNode("div", {
|
16704
16709
|
class: "address"
|
16705
16710
|
}, [(D = A.adrId) != null ? D : " "])]);
|
16706
16711
|
}
|
16707
16712
|
}]), u = ref([]), d = computed(() => {
|
16708
16713
|
var A;
|
16709
|
-
const
|
16714
|
+
const E = (A = s.value) == null ? void 0 : A.toUpperCase();
|
16710
16715
|
return u.value.filter((k) => {
|
16711
16716
|
var R, D, I, M, P, N;
|
16712
|
-
return ((D = (R = k.whDsc) == null ? void 0 : R.toUpperCase()) == null ? void 0 : D.includes(
|
16717
|
+
return ((D = (R = k.whDsc) == null ? void 0 : R.toUpperCase()) == null ? void 0 : D.includes(E)) || ((M = (I = k.whId) == null ? void 0 : I.toUpperCase()) == null ? void 0 : M.includes(E)) || ((N = (P = k.adrId) == null ? void 0 : P.toUpperCase()) == null ? void 0 : N.includes(E));
|
16713
16718
|
});
|
16714
16719
|
}), g = computed(() => {
|
16715
|
-
var
|
16716
|
-
return ((A = (
|
16720
|
+
var E, A;
|
16721
|
+
return ((A = (E = r.option.value) == null ? void 0 : E.KgWarehouse) == null ? void 0 : A.enable) !== !1;
|
16717
16722
|
});
|
16718
|
-
watch(a.visible, (
|
16719
|
-
!g.value || (
|
16723
|
+
watch(a.visible, (E) => {
|
16724
|
+
!g.value || (E ? y() : p());
|
16720
16725
|
}, {
|
16721
16726
|
immediate: !0
|
16722
16727
|
}), onMounted(() => {
|
@@ -16728,12 +16733,12 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16728
16733
|
function y() {
|
16729
16734
|
o.value = a.warehouse.value, b();
|
16730
16735
|
}
|
16731
|
-
function
|
16736
|
+
function p() {
|
16732
16737
|
s.value = "", u.value = [], o.value = null;
|
16733
16738
|
}
|
16734
|
-
function
|
16735
|
-
var
|
16736
|
-
!o.value || (e.kgInvisible ? (a.store.setWarehouse(o.value), t("kgOk")) : o.value.id !== ((
|
16739
|
+
function m() {
|
16740
|
+
var E;
|
16741
|
+
!o.value || (e.kgInvisible ? (a.store.setWarehouse(o.value), t("kgOk")) : o.value.id !== ((E = a.warehouse.value) == null ? void 0 : E.id) && (a.store.setWarehouse(o.value), KgUtil.confirm({
|
16737
16742
|
content: r.t("kg.KgWarehouse.reloadMessage"),
|
16738
16743
|
kgHideCancelButton: !0,
|
16739
16744
|
okButtonProps: {
|
@@ -16749,43 +16754,43 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16749
16754
|
i.value = !0;
|
16750
16755
|
try {
|
16751
16756
|
const {
|
16752
|
-
records:
|
16757
|
+
records: E
|
16753
16758
|
} = await ListVO({
|
16754
16759
|
params: {
|
16755
16760
|
pageNo: 1,
|
16756
16761
|
pageSize: 999
|
16757
16762
|
}
|
16758
16763
|
});
|
16759
|
-
u.value =
|
16760
|
-
} catch (
|
16761
|
-
console.error(
|
16764
|
+
u.value = E != null ? E : [];
|
16765
|
+
} catch (E) {
|
16766
|
+
console.error(E);
|
16762
16767
|
} finally {
|
16763
16768
|
i.value = !1;
|
16764
16769
|
}
|
16765
16770
|
}
|
16766
|
-
function C(
|
16771
|
+
function C(E, A) {
|
16767
16772
|
var k;
|
16768
|
-
switch (
|
16773
|
+
switch (E.detail) {
|
16769
16774
|
case 1:
|
16770
16775
|
((k = o.value) == null ? void 0 : k.id) === A.id ? o.value = null : o.value = A;
|
16771
16776
|
break;
|
16772
16777
|
case 2:
|
16773
|
-
o.value = A,
|
16778
|
+
o.value = A, m();
|
16774
16779
|
break;
|
16775
16780
|
}
|
16776
16781
|
}
|
16777
|
-
function
|
16782
|
+
function T() {
|
16778
16783
|
return g.value ? createVNode(Fragment, null, [createVNode(Tooltip, {
|
16779
16784
|
title: r.t("kg.KgWarehouse.warehouse"),
|
16780
16785
|
placement: "bottomRight"
|
16781
16786
|
}, {
|
16782
16787
|
default: () => {
|
16783
|
-
var
|
16784
|
-
return [((
|
16788
|
+
var E, A;
|
16789
|
+
return [((E = l.value) == null ? void 0 : E.whDsc) || ((A = l.value) == null ? void 0 : A.whId) || r.t("kg.KgWarehouse.selectWarehouse")];
|
16785
16790
|
}
|
16786
16791
|
}), createVNode(KgModal, {
|
16787
16792
|
visible: a.visible.value,
|
16788
|
-
"onUpdate:visible": (
|
16793
|
+
"onUpdate:visible": (E) => a.store.setVisible(E),
|
16789
16794
|
title: r.t("kg.KgWarehouse.title"),
|
16790
16795
|
width: "500px",
|
16791
16796
|
kgFullHeight: !1,
|
@@ -16798,11 +16803,11 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16798
16803
|
okButtonProps: {
|
16799
16804
|
disabled: i.value || !o.value
|
16800
16805
|
},
|
16801
|
-
onOk:
|
16806
|
+
onOk: m
|
16802
16807
|
}, {
|
16803
16808
|
default: () => [createVNode(Input, {
|
16804
16809
|
value: s.value,
|
16805
|
-
"onUpdate:value": (
|
16810
|
+
"onUpdate:value": (E) => s.value = E,
|
16806
16811
|
allowClear: !0,
|
16807
16812
|
disabled: i.value,
|
16808
16813
|
placeholder: r.t("kg.search")
|
@@ -16822,11 +16827,11 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16822
16827
|
dataSource: d.value,
|
16823
16828
|
columns: c,
|
16824
16829
|
class: "kg-flex-table",
|
16825
|
-
customRow: (
|
16830
|
+
customRow: (E) => {
|
16826
16831
|
var A;
|
16827
16832
|
return {
|
16828
|
-
class:
|
16829
|
-
onClick: (k) => C(k,
|
16833
|
+
class: E.id === ((A = o.value) == null ? void 0 : A.id) ? "selected" : "",
|
16834
|
+
onClick: (k) => C(k, E)
|
16830
16835
|
};
|
16831
16836
|
}
|
16832
16837
|
}, null)]
|
@@ -16835,7 +16840,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
16835
16840
|
return () => createVNode("div", {
|
16836
16841
|
class: n.value,
|
16837
16842
|
onClick: v
|
16838
|
-
}, [
|
16843
|
+
}, [T()]);
|
16839
16844
|
}
|
16840
16845
|
});
|
16841
16846
|
function createKgWarehouseGuard(e, t) {
|