@kengic/vue 0.6.1-beta.6 → 0.6.1-beta.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/kengic-vue.js +858 -892
- package/package.json +1 -1
package/dist/kengic-vue.js
CHANGED
@@ -14,10 +14,6 @@ function httpClient() {
|
|
14
14
|
return _httpClient;
|
15
15
|
}
|
16
16
|
console.log("111:");
|
17
|
-
const DEF = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
18
|
-
__proto__: null,
|
19
|
-
WMS: models
|
20
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
21
17
|
class CreateVarGridMasterQuery {
|
22
18
|
constructor(t) {
|
23
19
|
d(this, "def_flg");
|
@@ -844,36 +840,6 @@ function keys$1(e) {
|
|
844
840
|
const t = typeof e;
|
845
841
|
return e != null && (t === "object" || t === "function") ? Reflect.ownKeys(e) : [];
|
846
842
|
}
|
847
|
-
const models = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
848
|
-
__proto__: null,
|
849
|
-
CreateVarGridMasterQuery,
|
850
|
-
CreateVarProfileMasterQuery,
|
851
|
-
IPage,
|
852
|
-
UpdateVarGridMasterQuery,
|
853
|
-
VarButton,
|
854
|
-
VarButtonConfig,
|
855
|
-
VarCatalog,
|
856
|
-
VarContext,
|
857
|
-
VarDTO,
|
858
|
-
VarGridConfig,
|
859
|
-
VarGridDTO,
|
860
|
-
VarGridDetail,
|
861
|
-
VarGridMaster,
|
862
|
-
VarGridMasterDTO,
|
863
|
-
VarLookup,
|
864
|
-
VarPossibility,
|
865
|
-
VarProfileConfig,
|
866
|
-
VarProfileDTO,
|
867
|
-
VarProfileDetail,
|
868
|
-
VarProfileMaster,
|
869
|
-
VarProfileMasterDTO,
|
870
|
-
VarSubmitConfig,
|
871
|
-
VarSubmitField,
|
872
|
-
VarVariableConfig,
|
873
|
-
VarVariableInput,
|
874
|
-
WhDTO,
|
875
|
-
keys: keys$1
|
876
|
-
}, Symbol.toStringTag, { value: "Module" }));
|
877
843
|
class GetAllQuery {
|
878
844
|
constructor(t) {
|
879
845
|
d(this, "frm_id");
|
@@ -887,7 +853,7 @@ class GetAllQuery {
|
|
887
853
|
}
|
888
854
|
}
|
889
855
|
function GetAll(e, t) {
|
890
|
-
return
|
856
|
+
return httpClient().request(
|
891
857
|
{
|
892
858
|
method: GetAll.method,
|
893
859
|
url: `${t != null && t.mock ? "/mock" : ""}${GetAll.url}`,
|
@@ -906,7 +872,7 @@ const index$6 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePrope
|
|
906
872
|
class AddQuery$1 {
|
907
873
|
}
|
908
874
|
function Add$1(e, t) {
|
909
|
-
return
|
875
|
+
return httpClient().request(
|
910
876
|
{
|
911
877
|
method: Add$1.method,
|
912
878
|
url: `${t != null && t.mock ? "/mock" : ""}${Add$1.url}`,
|
@@ -930,7 +896,7 @@ class DeleteQuery$1 {
|
|
930
896
|
}
|
931
897
|
}
|
932
898
|
function Delete$1(e, t) {
|
933
|
-
return
|
899
|
+
return httpClient().request(
|
934
900
|
{
|
935
901
|
method: Delete$1.method,
|
936
902
|
url: `${t != null && t.mock ? "/mock" : ""}${Delete$1.url}`,
|
@@ -954,7 +920,7 @@ class DeleteBatchQuery$1 {
|
|
954
920
|
}
|
955
921
|
}
|
956
922
|
function DeleteBatch$1(e, t) {
|
957
|
-
return
|
923
|
+
return httpClient().request(
|
958
924
|
{
|
959
925
|
method: DeleteBatch$1.method,
|
960
926
|
url: `${t != null && t.mock ? "/mock" : ""}${DeleteBatch$1.url}`,
|
@@ -968,7 +934,7 @@ DeleteBatch$1.url = "/var/VarContext/deleteBatch";
|
|
968
934
|
class EditQuery$1 {
|
969
935
|
}
|
970
936
|
function Edit$1(e, t) {
|
971
|
-
return
|
937
|
+
return httpClient().request(
|
972
938
|
{
|
973
939
|
method: Edit$1.method,
|
974
940
|
url: `${t != null && t.mock ? "/mock" : ""}${Edit$1.url}`,
|
@@ -998,7 +964,7 @@ class ExportXlsQuery$1 {
|
|
998
964
|
}
|
999
965
|
}
|
1000
966
|
function ExportXls$1(e, t) {
|
1001
|
-
return
|
967
|
+
return httpClient().request(
|
1002
968
|
{
|
1003
969
|
method: ExportXls$1.method,
|
1004
970
|
url: `${t != null && t.mock ? "/mock" : ""}${ExportXls$1.url}`,
|
@@ -1012,7 +978,7 @@ ExportXls$1.url = "/var/VarContext/exportXls";
|
|
1012
978
|
class ImportExcelQuery$1 {
|
1013
979
|
}
|
1014
980
|
function ImportExcel$1(e, t) {
|
1015
|
-
return
|
981
|
+
return httpClient().request(
|
1016
982
|
{
|
1017
983
|
method: ImportExcel$1.method,
|
1018
984
|
url: `${t != null && t.mock ? "/mock" : ""}${ImportExcel$1.url}`,
|
@@ -1048,7 +1014,7 @@ class ListQuery$1 {
|
|
1048
1014
|
}
|
1049
1015
|
}
|
1050
1016
|
function List$1(e, t) {
|
1051
|
-
return
|
1017
|
+
return httpClient().request(
|
1052
1018
|
{
|
1053
1019
|
method: List$1.method,
|
1054
1020
|
url: `${t != null && t.mock ? "/mock" : ""}${List$1.url}`,
|
@@ -1072,7 +1038,7 @@ class QueryByIdQuery$1 {
|
|
1072
1038
|
}
|
1073
1039
|
}
|
1074
1040
|
function QueryById$1(e, t) {
|
1075
|
-
return
|
1041
|
+
return httpClient().request(
|
1076
1042
|
{
|
1077
1043
|
method: QueryById$1.method,
|
1078
1044
|
url: `${t != null && t.mock ? "/mock" : ""}${QueryById$1.url}`,
|
@@ -1115,7 +1081,7 @@ class QueryByIDQuery$1 {
|
|
1115
1081
|
}
|
1116
1082
|
}
|
1117
1083
|
function QueryByID$1(e, t) {
|
1118
|
-
return
|
1084
|
+
return httpClient().request(
|
1119
1085
|
{
|
1120
1086
|
method: QueryByID$1.method,
|
1121
1087
|
url: `${t != null && t.mock ? "/mock" : ""}${QueryByID$1.url}`,
|
@@ -1129,7 +1095,7 @@ QueryByID$1.url = "/var/VarGridMaster/queryByID";
|
|
1129
1095
|
class UpdateQuery {
|
1130
1096
|
}
|
1131
1097
|
function Update(e, t) {
|
1132
|
-
return
|
1098
|
+
return httpClient().request(
|
1133
1099
|
{
|
1134
1100
|
method: Update.method,
|
1135
1101
|
url: `${t != null && t.mock ? "/mock" : ""}${Update.url}`,
|
@@ -1160,7 +1126,7 @@ class QueryByIDQuery {
|
|
1160
1126
|
}
|
1161
1127
|
}
|
1162
1128
|
function QueryByID(e, t) {
|
1163
|
-
return
|
1129
|
+
return httpClient().request(
|
1164
1130
|
{
|
1165
1131
|
method: QueryByID.method,
|
1166
1132
|
url: `${t != null && t.mock ? "/mock" : ""}${QueryByID.url}`,
|
@@ -1179,7 +1145,7 @@ const index$3 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePrope
|
|
1179
1145
|
class AddQuery {
|
1180
1146
|
}
|
1181
1147
|
function Add(e, t) {
|
1182
|
-
return
|
1148
|
+
return httpClient().request(
|
1183
1149
|
{
|
1184
1150
|
method: Add.method,
|
1185
1151
|
url: `${t != null && t.mock ? "/mock" : ""}${Add.url}`,
|
@@ -1203,7 +1169,7 @@ class DeleteQuery {
|
|
1203
1169
|
}
|
1204
1170
|
}
|
1205
1171
|
function Delete(e, t) {
|
1206
|
-
return
|
1172
|
+
return httpClient().request(
|
1207
1173
|
{
|
1208
1174
|
method: Delete.method,
|
1209
1175
|
url: `${t != null && t.mock ? "/mock" : ""}${Delete.url}`,
|
@@ -1227,7 +1193,7 @@ class DeleteBatchQuery {
|
|
1227
1193
|
}
|
1228
1194
|
}
|
1229
1195
|
function DeleteBatch(e, t) {
|
1230
|
-
return
|
1196
|
+
return httpClient().request(
|
1231
1197
|
{
|
1232
1198
|
method: DeleteBatch.method,
|
1233
1199
|
url: `${t != null && t.mock ? "/mock" : ""}${DeleteBatch.url}`,
|
@@ -1241,7 +1207,7 @@ DeleteBatch.url = "/var/VarVariableCatalog/deleteBatch";
|
|
1241
1207
|
class EditQuery {
|
1242
1208
|
}
|
1243
1209
|
function Edit(e, t) {
|
1244
|
-
return
|
1210
|
+
return httpClient().request(
|
1245
1211
|
{
|
1246
1212
|
method: Edit.method,
|
1247
1213
|
url: `${t != null && t.mock ? "/mock" : ""}${Edit.url}`,
|
@@ -1277,7 +1243,7 @@ class ExportXlsQuery {
|
|
1277
1243
|
}
|
1278
1244
|
}
|
1279
1245
|
function ExportXls(e, t) {
|
1280
|
-
return
|
1246
|
+
return httpClient().request(
|
1281
1247
|
{
|
1282
1248
|
method: ExportXls.method,
|
1283
1249
|
url: `${t != null && t.mock ? "/mock" : ""}${ExportXls.url}`,
|
@@ -1291,7 +1257,7 @@ ExportXls.url = "/var/VarVariableCatalog/exportXls";
|
|
1291
1257
|
class ImportExcelQuery {
|
1292
1258
|
}
|
1293
1259
|
function ImportExcel(e, t) {
|
1294
|
-
return
|
1260
|
+
return httpClient().request(
|
1295
1261
|
{
|
1296
1262
|
method: ImportExcel.method,
|
1297
1263
|
url: `${t != null && t.mock ? "/mock" : ""}${ImportExcel.url}`,
|
@@ -1333,7 +1299,7 @@ class ListQuery {
|
|
1333
1299
|
}
|
1334
1300
|
}
|
1335
1301
|
function List(e, t) {
|
1336
|
-
return
|
1302
|
+
return httpClient().request(
|
1337
1303
|
{
|
1338
1304
|
method: List.method,
|
1339
1305
|
url: `${t != null && t.mock ? "/mock" : ""}${List.url}`,
|
@@ -1357,7 +1323,7 @@ class QueryByIdQuery {
|
|
1357
1323
|
}
|
1358
1324
|
}
|
1359
1325
|
function QueryById(e, t) {
|
1360
|
-
return
|
1326
|
+
return httpClient().request(
|
1361
1327
|
{
|
1362
1328
|
method: QueryById.method,
|
1363
1329
|
url: `${t != null && t.mock ? "/mock" : ""}${QueryById.url}`,
|
@@ -1430,7 +1396,7 @@ class ListVOQuery {
|
|
1430
1396
|
}
|
1431
1397
|
}
|
1432
1398
|
function ListVO(e, t) {
|
1433
|
-
return
|
1399
|
+
return httpClient().request(
|
1434
1400
|
{
|
1435
1401
|
method: ListVO.method,
|
1436
1402
|
url: `${t != null && t.mock ? "/mock" : ""}${ListVO.url}`,
|
@@ -1492,35 +1458,35 @@ function hslToRgb(e, t, r) {
|
|
1492
1458
|
if (e = bound01(e, 360), t = bound01(t, 100), r = bound01(r, 100), t === 0)
|
1493
1459
|
a = r, o = r, n = r;
|
1494
1460
|
else {
|
1495
|
-
var
|
1496
|
-
n = hue2rgb(
|
1461
|
+
var i = r < 0.5 ? r * (1 + t) : r + t - r * t, s = 2 * r - i;
|
1462
|
+
n = hue2rgb(s, i, e + 1 / 3), a = hue2rgb(s, i, e), o = hue2rgb(s, i, e - 1 / 3);
|
1497
1463
|
}
|
1498
1464
|
return { r: n * 255, g: a * 255, b: o * 255 };
|
1499
1465
|
}
|
1500
1466
|
function rgbToHsv(e, t, r) {
|
1501
1467
|
e = bound01(e, 255), t = bound01(t, 255), r = bound01(r, 255);
|
1502
|
-
var n = Math.max(e, t, r), a = Math.min(e, t, r), o = 0,
|
1468
|
+
var n = Math.max(e, t, r), a = Math.min(e, t, r), o = 0, i = n, s = n - a, l = n === 0 ? 0 : s / n;
|
1503
1469
|
if (n === a)
|
1504
1470
|
o = 0;
|
1505
1471
|
else {
|
1506
1472
|
switch (n) {
|
1507
1473
|
case e:
|
1508
|
-
o = (t - r) /
|
1474
|
+
o = (t - r) / s + (t < r ? 6 : 0);
|
1509
1475
|
break;
|
1510
1476
|
case t:
|
1511
|
-
o = (r - e) /
|
1477
|
+
o = (r - e) / s + 2;
|
1512
1478
|
break;
|
1513
1479
|
case r:
|
1514
|
-
o = (e - t) /
|
1480
|
+
o = (e - t) / s + 4;
|
1515
1481
|
break;
|
1516
1482
|
}
|
1517
1483
|
o /= 6;
|
1518
1484
|
}
|
1519
|
-
return { h: o, s: l, v:
|
1485
|
+
return { h: o, s: l, v: i };
|
1520
1486
|
}
|
1521
1487
|
function hsvToRgb(e, t, r) {
|
1522
1488
|
e = bound01(e, 360) * 6, t = bound01(t, 100), r = bound01(r, 100);
|
1523
|
-
var n = Math.floor(e), a = e - n, o = r * (1 - t),
|
1489
|
+
var n = Math.floor(e), a = e - n, o = r * (1 - t), i = r * (1 - a * t), s = r * (1 - (1 - a) * t), l = n % 6, u = [r, i, o, o, s, r][l], c = [s, r, r, i, o, o][l], g = [o, o, s, r, r, i][l];
|
1524
1490
|
return { r: u * 255, g: c * 255, b: g * 255 };
|
1525
1491
|
}
|
1526
1492
|
function rgbToHex(e, t, r, n) {
|
@@ -1688,10 +1654,10 @@ var names = {
|
|
1688
1654
|
yellowgreen: "#9acd32"
|
1689
1655
|
};
|
1690
1656
|
function inputToRGB(e) {
|
1691
|
-
var t = { r: 0, g: 0, b: 0 }, r = 1, n = null, a = null, o = null,
|
1692
|
-
return typeof e == "string" && (e = stringInputToObject(e)), typeof e == "object" && (isValidCSSUnit(e.r) && isValidCSSUnit(e.g) && isValidCSSUnit(e.b) ? (t = rgbToRgb(e.r, e.g, e.b),
|
1693
|
-
ok:
|
1694
|
-
format: e.format ||
|
1657
|
+
var t = { r: 0, g: 0, b: 0 }, r = 1, n = null, a = null, o = null, i = !1, s = !1;
|
1658
|
+
return typeof e == "string" && (e = stringInputToObject(e)), typeof e == "object" && (isValidCSSUnit(e.r) && isValidCSSUnit(e.g) && isValidCSSUnit(e.b) ? (t = rgbToRgb(e.r, e.g, e.b), i = !0, s = String(e.r).substr(-1) === "%" ? "prgb" : "rgb") : isValidCSSUnit(e.h) && isValidCSSUnit(e.s) && isValidCSSUnit(e.v) ? (n = convertToPercentage(e.s), a = convertToPercentage(e.v), t = hsvToRgb(e.h, n, a), i = !0, s = "hsv") : isValidCSSUnit(e.h) && isValidCSSUnit(e.s) && isValidCSSUnit(e.l) && (n = convertToPercentage(e.s), o = convertToPercentage(e.l), t = hslToRgb(e.h, n, o), i = !0, s = "hsl"), Object.prototype.hasOwnProperty.call(e, "a") && (r = e.a)), r = boundAlpha(r), {
|
1659
|
+
ok: i,
|
1660
|
+
format: e.format || s,
|
1695
1661
|
r: Math.min(255, Math.max(t.r, 0)),
|
1696
1662
|
g: Math.min(255, Math.max(t.g, 0)),
|
1697
1663
|
b: Math.min(255, Math.max(t.b, 0)),
|
@@ -1814,19 +1780,19 @@ function getValue$1(e, t, r) {
|
|
1814
1780
|
}
|
1815
1781
|
function generate$1(e) {
|
1816
1782
|
for (var t = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, r = [], n = inputToRGB(e), a = lightColorCount; a > 0; a -= 1) {
|
1817
|
-
var o = toHsv(n),
|
1783
|
+
var o = toHsv(n), i = toHex(inputToRGB({
|
1818
1784
|
h: getHue(o, a, !0),
|
1819
1785
|
s: getSaturation(o, a, !0),
|
1820
1786
|
v: getValue$1(o, a, !0)
|
1821
1787
|
}));
|
1822
|
-
r.push(
|
1788
|
+
r.push(i);
|
1823
1789
|
}
|
1824
1790
|
r.push(toHex(n));
|
1825
|
-
for (var
|
1791
|
+
for (var s = 1; s <= darkColorCount; s += 1) {
|
1826
1792
|
var l = toHsv(n), u = toHex(inputToRGB({
|
1827
|
-
h: getHue(l,
|
1828
|
-
s: getSaturation(l,
|
1829
|
-
v: getValue$1(l,
|
1793
|
+
h: getHue(l, s),
|
1794
|
+
s: getSaturation(l, s),
|
1795
|
+
v: getValue$1(l, s)
|
1830
1796
|
}));
|
1831
1797
|
r.push(u);
|
1832
1798
|
}
|
@@ -2017,16 +1983,16 @@ function getTwoToneColors() {
|
|
2017
1983
|
return _objectSpread$l({}, twoToneColorPalette);
|
2018
1984
|
}
|
2019
1985
|
var IconBase = function(t, r) {
|
2020
|
-
var n = _objectSpread$l({}, t, r.attrs), a = n.icon, o = n.primaryColor,
|
1986
|
+
var n = _objectSpread$l({}, t, r.attrs), a = n.icon, o = n.primaryColor, i = n.secondaryColor, s = _objectWithoutProperties$1(n, _excluded$1), l = twoToneColorPalette;
|
2021
1987
|
if (o && (l = {
|
2022
1988
|
primaryColor: o,
|
2023
|
-
secondaryColor:
|
1989
|
+
secondaryColor: i || getSecondaryColor(o)
|
2024
1990
|
}), useInsertStyles(), warning(isIconDefinition(a), "icon should be icon definiton, but got ".concat(a)), !isIconDefinition(a))
|
2025
1991
|
return null;
|
2026
1992
|
var u = a;
|
2027
1993
|
return u && typeof u.icon == "function" && (u = _objectSpread$l({}, u, {
|
2028
1994
|
icon: u.icon(l.primaryColor, l.secondaryColor)
|
2029
|
-
})), generate(u.icon, "svg-".concat(u.name), _objectSpread$l({},
|
1995
|
+
})), generate(u.icon, "svg-".concat(u.name), _objectSpread$l({}, s, {
|
2030
1996
|
"data-icon": u.name,
|
2031
1997
|
width: "1em",
|
2032
1998
|
height: "1em",
|
@@ -2072,18 +2038,18 @@ function _arrayLikeToArray$1(e, t) {
|
|
2072
2038
|
function _iterableToArrayLimit$1(e, t) {
|
2073
2039
|
var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
2074
2040
|
if (r != null) {
|
2075
|
-
var n = [], a = !0, o = !1,
|
2041
|
+
var n = [], a = !0, o = !1, i, s;
|
2076
2042
|
try {
|
2077
|
-
for (r = r.call(e); !(a = (
|
2043
|
+
for (r = r.call(e); !(a = (i = r.next()).done) && (n.push(i.value), !(t && n.length === t)); a = !0)
|
2078
2044
|
;
|
2079
2045
|
} catch (l) {
|
2080
|
-
o = !0,
|
2046
|
+
o = !0, s = l;
|
2081
2047
|
} finally {
|
2082
2048
|
try {
|
2083
2049
|
!a && r.return != null && r.return();
|
2084
2050
|
} finally {
|
2085
2051
|
if (o)
|
2086
|
-
throw
|
2052
|
+
throw s;
|
2087
2053
|
}
|
2088
2054
|
}
|
2089
2055
|
return n;
|
@@ -2132,18 +2098,18 @@ function _arrayLikeToArray(e, t) {
|
|
2132
2098
|
function _iterableToArrayLimit(e, t) {
|
2133
2099
|
var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
|
2134
2100
|
if (r != null) {
|
2135
|
-
var n = [], a = !0, o = !1,
|
2101
|
+
var n = [], a = !0, o = !1, i, s;
|
2136
2102
|
try {
|
2137
|
-
for (r = r.call(e); !(a = (
|
2103
|
+
for (r = r.call(e); !(a = (i = r.next()).done) && (n.push(i.value), !(t && n.length === t)); a = !0)
|
2138
2104
|
;
|
2139
2105
|
} catch (l) {
|
2140
|
-
o = !0,
|
2106
|
+
o = !0, s = l;
|
2141
2107
|
} finally {
|
2142
2108
|
try {
|
2143
2109
|
!a && r.return != null && r.return();
|
2144
2110
|
} finally {
|
2145
2111
|
if (o)
|
2146
|
-
throw
|
2112
|
+
throw s;
|
2147
2113
|
}
|
2148
2114
|
}
|
2149
2115
|
return n;
|
@@ -2188,9 +2154,9 @@ function _objectWithoutPropertiesLoose(e, t) {
|
|
2188
2154
|
}
|
2189
2155
|
setTwoToneColor("#1890ff");
|
2190
2156
|
var Icon$1 = function(t, r) {
|
2191
|
-
var n, a = _objectSpread$k({}, t, r.attrs), o = a.class,
|
2157
|
+
var n, a = _objectSpread$k({}, t, r.attrs), o = a.class, i = a.icon, s = a.spin, l = a.rotate, u = a.tabindex, c = a.twoToneColor, g = a.onClick, p = _objectWithoutProperties(a, _excluded), b = (n = {
|
2192
2158
|
anticon: !0
|
2193
|
-
}, _defineProperty$k(n, "anticon-".concat(
|
2159
|
+
}, _defineProperty$k(n, "anticon-".concat(i.name), Boolean(i.name)), _defineProperty$k(n, o, o), n), m = s === "" || !!s || i.name === "loading" ? "anticon-spin" : "", v = u;
|
2194
2160
|
v === void 0 && g && (v = -1, p.tabindex = v);
|
2195
2161
|
var _ = l ? {
|
2196
2162
|
msTransform: "rotate(".concat(l, "deg)"),
|
@@ -2198,13 +2164,13 @@ var Icon$1 = function(t, r) {
|
|
2198
2164
|
} : void 0, y = normalizeTwoToneColors(c), C = _slicedToArray(y, 2), E = C[0], T = C[1];
|
2199
2165
|
return createVNode("span", _objectSpread$k({
|
2200
2166
|
role: "img",
|
2201
|
-
"aria-label":
|
2167
|
+
"aria-label": i.name
|
2202
2168
|
}, p, {
|
2203
2169
|
onClick: g,
|
2204
2170
|
class: b
|
2205
2171
|
}), [createVNode(VueIcon, {
|
2206
2172
|
class: m,
|
2207
|
-
icon:
|
2173
|
+
icon: i,
|
2208
2174
|
primaryColor: E,
|
2209
2175
|
secondaryColor: T,
|
2210
2176
|
style: _
|
@@ -2762,29 +2728,29 @@ const UploadOutlined$1 = UploadOutlined, data$7 = {
|
|
2762
2728
|
if (a.length > 3 || !a.length)
|
2763
2729
|
return null;
|
2764
2730
|
if (a.length > 1) {
|
2765
|
-
const
|
2731
|
+
const s = a.pop(), l = a.pop(), u = {
|
2766
2732
|
provider: a.length > 0 ? a[0] : n,
|
2767
2733
|
prefix: l,
|
2768
|
-
name:
|
2734
|
+
name: s
|
2769
2735
|
};
|
2770
2736
|
return t && !validateIconName(u) ? null : u;
|
2771
2737
|
}
|
2772
|
-
const o = a[0],
|
2773
|
-
if (
|
2774
|
-
const
|
2738
|
+
const o = a[0], i = o.split("-");
|
2739
|
+
if (i.length > 1) {
|
2740
|
+
const s = {
|
2775
2741
|
provider: n,
|
2776
|
-
prefix:
|
2777
|
-
name:
|
2742
|
+
prefix: i.shift(),
|
2743
|
+
name: i.join("-")
|
2778
2744
|
};
|
2779
|
-
return t && !validateIconName(
|
2745
|
+
return t && !validateIconName(s) ? null : s;
|
2780
2746
|
}
|
2781
2747
|
if (r && n === "") {
|
2782
|
-
const
|
2748
|
+
const s = {
|
2783
2749
|
provider: n,
|
2784
2750
|
prefix: "",
|
2785
2751
|
name: o
|
2786
2752
|
};
|
2787
|
-
return t && !validateIconName(
|
2753
|
+
return t && !validateIconName(s, r) ? null : s;
|
2788
2754
|
}
|
2789
2755
|
return null;
|
2790
2756
|
}, validateIconName = (e, t) => e ? !!((e.provider === "" || e.provider.match(matchIconName)) && (t && e.prefix === "" || e.prefix.match(matchIconName)) && e.name.match(matchIconName)) : !1, defaultIconDimensions = Object.freeze(
|
@@ -2820,28 +2786,28 @@ function mergeIconData(e, t) {
|
|
2820
2786
|
}
|
2821
2787
|
function getIconsTree(e, t) {
|
2822
2788
|
const r = e.icons, n = e.aliases || /* @__PURE__ */ Object.create(null), a = /* @__PURE__ */ Object.create(null);
|
2823
|
-
function o(
|
2824
|
-
if (r[
|
2825
|
-
return a[
|
2826
|
-
if (!(
|
2827
|
-
a[
|
2828
|
-
const
|
2829
|
-
l && (a[
|
2789
|
+
function o(i) {
|
2790
|
+
if (r[i])
|
2791
|
+
return a[i] = [];
|
2792
|
+
if (!(i in a)) {
|
2793
|
+
a[i] = null;
|
2794
|
+
const s = n[i] && n[i].parent, l = s && o(s);
|
2795
|
+
l && (a[i] = [s].concat(l));
|
2830
2796
|
}
|
2831
|
-
return a[
|
2797
|
+
return a[i];
|
2832
2798
|
}
|
2833
2799
|
return (t || Object.keys(r).concat(Object.keys(n))).forEach(o), a;
|
2834
2800
|
}
|
2835
2801
|
function internalGetIconData(e, t, r) {
|
2836
2802
|
const n = e.icons, a = e.aliases || /* @__PURE__ */ Object.create(null);
|
2837
2803
|
let o = {};
|
2838
|
-
function s
|
2804
|
+
function i(s) {
|
2839
2805
|
o = mergeIconData(
|
2840
|
-
n[
|
2806
|
+
n[s] || a[s],
|
2841
2807
|
o
|
2842
2808
|
);
|
2843
2809
|
}
|
2844
|
-
return
|
2810
|
+
return i(t), r.forEach(i), mergeIconData(e, o);
|
2845
2811
|
}
|
2846
2812
|
function parseIconSet(e, t) {
|
2847
2813
|
const r = [];
|
@@ -2886,8 +2852,8 @@ function quicklyValidateIconSet(e) {
|
|
2886
2852
|
}
|
2887
2853
|
const n = t.aliases || /* @__PURE__ */ Object.create(null);
|
2888
2854
|
for (const a in n) {
|
2889
|
-
const o = n[a],
|
2890
|
-
if (!a.match(matchIconName) || typeof
|
2855
|
+
const o = n[a], i = o.parent;
|
2856
|
+
if (!a.match(matchIconName) || typeof i != "string" || !r[i] && !n[i] || !checkOptionalProps(
|
2891
2857
|
o,
|
2892
2858
|
defaultExtendedIconProps
|
2893
2859
|
))
|
@@ -2944,8 +2910,8 @@ function addCollection(e, t) {
|
|
2944
2910
|
return !1;
|
2945
2911
|
if (typeof t != "string" && (t = e.provider || ""), simpleNames && !t && !e.prefix) {
|
2946
2912
|
let a = !1;
|
2947
|
-
return quicklyValidateIconSet(e) && (e.prefix = "", parseIconSet(e, (o,
|
2948
|
-
|
2913
|
+
return quicklyValidateIconSet(e) && (e.prefix = "", parseIconSet(e, (o, i) => {
|
2914
|
+
i && addIcon(o, i) && (a = !0);
|
2949
2915
|
})), a;
|
2950
2916
|
}
|
2951
2917
|
const r = e.prefix;
|
@@ -2976,16 +2942,16 @@ function calculateSize(e, t, r) {
|
|
2976
2942
|
if (n === null || !n.length)
|
2977
2943
|
return e;
|
2978
2944
|
const a = [];
|
2979
|
-
let o = n.shift(),
|
2945
|
+
let o = n.shift(), i = unitsTest.test(o);
|
2980
2946
|
for (; ; ) {
|
2981
|
-
if (
|
2982
|
-
const
|
2983
|
-
isNaN(
|
2947
|
+
if (i) {
|
2948
|
+
const s = parseFloat(o);
|
2949
|
+
isNaN(s) ? a.push(o) : a.push(Math.ceil(s * t * r) / r);
|
2984
2950
|
} else
|
2985
2951
|
a.push(o);
|
2986
2952
|
if (o = n.shift(), o === void 0)
|
2987
2953
|
return a.join("");
|
2988
|
-
|
2954
|
+
i = !i;
|
2989
2955
|
}
|
2990
2956
|
}
|
2991
2957
|
const isUnsetKeyword = (e) => e === "unset" || e === "undefined" || e === "none";
|
@@ -3031,9 +2997,9 @@ function iconToSVG(e, t) {
|
|
3031
2997
|
}
|
3032
2998
|
C % 2 === 1 && (a.left !== a.top && (E = a.left, a.left = a.top, a.top = E), a.width !== a.height && (E = a.width, a.width = a.height, a.height = E)), v.length && (o = '<g transform="' + v.join(" ") + '">' + o + "</g>");
|
3033
2999
|
});
|
3034
|
-
const
|
3000
|
+
const i = n.width, s = n.height, l = a.width, u = a.height;
|
3035
3001
|
let c, g;
|
3036
|
-
|
3002
|
+
i === null ? (g = s === null ? "1em" : s === "auto" ? u : s, c = calculateSize(g, l / u)) : (c = i === "auto" ? l : i, g = s === null ? calculateSize(c, u / l) : s === "auto" ? u : s);
|
3037
3003
|
const p = {}, b = (m, v) => {
|
3038
3004
|
isUnsetKeyword(v) || (p[m] = v.toString());
|
3039
3005
|
};
|
@@ -3053,10 +3019,10 @@ function replaceIDs(e, t = randomPrefix) {
|
|
3053
3019
|
return e;
|
3054
3020
|
const a = "suffix" + (Math.random() * 16777216 | Date.now()).toString(16);
|
3055
3021
|
return r.forEach((o) => {
|
3056
|
-
const
|
3022
|
+
const i = typeof t == "function" ? t(o) : t + (counter++).toString(), s = o.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
3057
3023
|
e = e.replace(
|
3058
|
-
new RegExp('([#;"])(' +
|
3059
|
-
"$1" +
|
3024
|
+
new RegExp('([#;"])(' + s + ')([")]|\\.[a-z])', "g"),
|
3025
|
+
"$1" + i + a + "$3"
|
3060
3026
|
);
|
3061
3027
|
}), e = e.replace(new RegExp(a, "g"), ""), e;
|
3062
3028
|
}
|
@@ -3118,8 +3084,8 @@ function calculateMaxLength(e, t) {
|
|
3118
3084
|
n = 0;
|
3119
3085
|
else {
|
3120
3086
|
let a = 0;
|
3121
|
-
r.resources.forEach((
|
3122
|
-
a = Math.max(a,
|
3087
|
+
r.resources.forEach((i) => {
|
3088
|
+
a = Math.max(a, i.length);
|
3123
3089
|
});
|
3124
3090
|
const o = t + ".json?icons=";
|
3125
3091
|
n = r.maxURL - a - r.path.length - o.length;
|
@@ -3131,20 +3097,20 @@ function shouldAbort(e) {
|
|
3131
3097
|
}
|
3132
3098
|
const prepare = (e, t, r) => {
|
3133
3099
|
const n = [], a = calculateMaxLength(e, t), o = "icons";
|
3134
|
-
let
|
3100
|
+
let i = {
|
3135
3101
|
type: o,
|
3136
3102
|
provider: e,
|
3137
3103
|
prefix: t,
|
3138
3104
|
icons: []
|
3139
|
-
},
|
3105
|
+
}, s = 0;
|
3140
3106
|
return r.forEach((l, u) => {
|
3141
|
-
|
3107
|
+
s += l.length + 1, s >= a && u > 0 && (n.push(i), i = {
|
3142
3108
|
type: o,
|
3143
3109
|
provider: e,
|
3144
3110
|
prefix: t,
|
3145
3111
|
icons: []
|
3146
|
-
},
|
3147
|
-
}), n.push(
|
3112
|
+
}, s = l.length), i.icons.push(l);
|
3113
|
+
}), n.push(i), n;
|
3148
3114
|
};
|
3149
3115
|
function getPath(e) {
|
3150
3116
|
if (typeof e == "string") {
|
@@ -3162,8 +3128,8 @@ const send = (e, t, r) => {
|
|
3162
3128
|
let n = getPath(t.provider);
|
3163
3129
|
switch (t.type) {
|
3164
3130
|
case "icons": {
|
3165
|
-
const o = t.prefix,
|
3166
|
-
icons:
|
3131
|
+
const o = t.prefix, s = t.icons.join(","), l = new URLSearchParams({
|
3132
|
+
icons: s
|
3167
3133
|
});
|
3168
3134
|
n += o + ".json?" + l.toString();
|
3169
3135
|
break;
|
@@ -3179,10 +3145,10 @@ const send = (e, t, r) => {
|
|
3179
3145
|
}
|
3180
3146
|
let a = 503;
|
3181
3147
|
fetchModule(e + n).then((o) => {
|
3182
|
-
const
|
3183
|
-
if (
|
3148
|
+
const i = o.status;
|
3149
|
+
if (i !== 200) {
|
3184
3150
|
setTimeout(() => {
|
3185
|
-
r(shouldAbort(
|
3151
|
+
r(shouldAbort(i) ? "abort" : "next", i);
|
3186
3152
|
});
|
3187
3153
|
return;
|
3188
3154
|
}
|
@@ -3220,13 +3186,13 @@ function sortIcons(e) {
|
|
3220
3186
|
if (n.name === a.name && n.prefix === a.prefix && n.provider === a.provider)
|
3221
3187
|
return;
|
3222
3188
|
n = a;
|
3223
|
-
const o = a.provider,
|
3189
|
+
const o = a.provider, i = a.prefix, s = a.name, l = r[o] || (r[o] = /* @__PURE__ */ Object.create(null)), u = l[i] || (l[i] = getStorage(o, i));
|
3224
3190
|
let c;
|
3225
|
-
|
3191
|
+
s in u.icons ? c = t.loaded : i === "" || u.missing.has(s) ? c = t.missing : c = t.pending;
|
3226
3192
|
const g = {
|
3227
3193
|
provider: o,
|
3228
|
-
prefix:
|
3229
|
-
name:
|
3194
|
+
prefix: i,
|
3195
|
+
name: s
|
3230
3196
|
};
|
3231
3197
|
c.push(g);
|
3232
3198
|
}), t;
|
@@ -3246,19 +3212,19 @@ function updateCallbacks(e) {
|
|
3246
3212
|
let r = !1;
|
3247
3213
|
const n = e.provider, a = e.prefix;
|
3248
3214
|
t.forEach((o) => {
|
3249
|
-
const
|
3250
|
-
|
3215
|
+
const i = o.icons, s = i.pending.length;
|
3216
|
+
i.pending = i.pending.filter((l) => {
|
3251
3217
|
if (l.prefix !== a)
|
3252
3218
|
return !0;
|
3253
3219
|
const u = l.name;
|
3254
3220
|
if (e.icons[u])
|
3255
|
-
|
3221
|
+
i.loaded.push({
|
3256
3222
|
provider: n,
|
3257
3223
|
prefix: a,
|
3258
3224
|
name: u
|
3259
3225
|
});
|
3260
3226
|
else if (e.missing.has(u))
|
3261
|
-
|
3227
|
+
i.missing.push({
|
3262
3228
|
provider: n,
|
3263
3229
|
prefix: a,
|
3264
3230
|
name: u
|
@@ -3266,10 +3232,10 @@ function updateCallbacks(e) {
|
|
3266
3232
|
else
|
3267
3233
|
return r = !0, !0;
|
3268
3234
|
return !1;
|
3269
|
-
}),
|
3270
|
-
|
3271
|
-
|
3272
|
-
|
3235
|
+
}), i.pending.length !== s && (r || removeCallback([e], o.id), o.callback(
|
3236
|
+
i.loaded.slice(0),
|
3237
|
+
i.missing.slice(0),
|
3238
|
+
i.pending.slice(0),
|
3273
3239
|
o.abort
|
3274
3240
|
));
|
3275
3241
|
});
|
@@ -3286,8 +3252,8 @@ function storeCallback(e, t, r) {
|
|
3286
3252
|
callback: e,
|
3287
3253
|
abort: a
|
3288
3254
|
};
|
3289
|
-
return r.forEach((
|
3290
|
-
(
|
3255
|
+
return r.forEach((i) => {
|
3256
|
+
(i.loaderCallbacks || (i.loaderCallbacks = [])).push(o);
|
3291
3257
|
}), a;
|
3292
3258
|
}
|
3293
3259
|
function listToIcons(e, t = !0, r = !1) {
|
@@ -3307,17 +3273,17 @@ var defaultConfig = {
|
|
3307
3273
|
};
|
3308
3274
|
function sendQuery(e, t, r, n) {
|
3309
3275
|
const a = e.resources.length, o = e.random ? Math.floor(Math.random() * a) : e.index;
|
3310
|
-
let
|
3276
|
+
let i;
|
3311
3277
|
if (e.random) {
|
3312
3278
|
let k = e.resources.slice(0);
|
3313
|
-
for (
|
3279
|
+
for (i = []; k.length > 1; ) {
|
3314
3280
|
const w = Math.floor(Math.random() * k.length);
|
3315
|
-
|
3281
|
+
i.push(k[w]), k = k.slice(0, w).concat(k.slice(w + 1));
|
3316
3282
|
}
|
3317
|
-
|
3283
|
+
i = i.concat(k);
|
3318
3284
|
} else
|
3319
|
-
|
3320
|
-
const
|
3285
|
+
i = e.resources.slice(o).concat(e.resources.slice(0, o));
|
3286
|
+
const s = Date.now();
|
3321
3287
|
let l = "pending", u = 0, c, g = null, p = [], b = [];
|
3322
3288
|
typeof n == "function" && b.push(n);
|
3323
3289
|
function m() {
|
@@ -3333,7 +3299,7 @@ function sendQuery(e, t, r, n) {
|
|
3333
3299
|
}
|
3334
3300
|
function y() {
|
3335
3301
|
return {
|
3336
|
-
startTime:
|
3302
|
+
startTime: s,
|
3337
3303
|
payload: t,
|
3338
3304
|
status: l,
|
3339
3305
|
queriesSent: u,
|
@@ -3369,7 +3335,7 @@ function sendQuery(e, t, r, n) {
|
|
3369
3335
|
return;
|
3370
3336
|
}
|
3371
3337
|
if (A) {
|
3372
|
-
c = M, p.length || (
|
3338
|
+
c = M, p.length || (i.length ? I() : C());
|
3373
3339
|
return;
|
3374
3340
|
}
|
3375
3341
|
if (m(), E(), !e.random) {
|
@@ -3384,7 +3350,7 @@ function sendQuery(e, t, r, n) {
|
|
3384
3350
|
if (l !== "pending")
|
3385
3351
|
return;
|
3386
3352
|
m();
|
3387
|
-
const k =
|
3353
|
+
const k = i.shift();
|
3388
3354
|
if (k === void 0) {
|
3389
3355
|
if (p.length) {
|
3390
3356
|
g = setTimeout(() => {
|
@@ -3413,12 +3379,12 @@ function initRedundancy(e) {
|
|
3413
3379
|
};
|
3414
3380
|
let r = [];
|
3415
3381
|
function n() {
|
3416
|
-
r = r.filter((
|
3382
|
+
r = r.filter((s) => s().status === "pending");
|
3417
3383
|
}
|
3418
|
-
function a(
|
3384
|
+
function a(s, l, u) {
|
3419
3385
|
const c = sendQuery(
|
3420
3386
|
t,
|
3421
|
-
|
3387
|
+
s,
|
3422
3388
|
l,
|
3423
3389
|
(g, p) => {
|
3424
3390
|
n(), u && u(g, p);
|
@@ -3426,14 +3392,14 @@ function initRedundancy(e) {
|
|
3426
3392
|
);
|
3427
3393
|
return r.push(c), c;
|
3428
3394
|
}
|
3429
|
-
function o(
|
3430
|
-
return r.find((l) =>
|
3395
|
+
function o(s) {
|
3396
|
+
return r.find((l) => s(l)) || null;
|
3431
3397
|
}
|
3432
3398
|
return {
|
3433
3399
|
query: a,
|
3434
3400
|
find: o,
|
3435
|
-
setIndex: (
|
3436
|
-
t.index =
|
3401
|
+
setIndex: (s) => {
|
3402
|
+
t.index = s;
|
3437
3403
|
},
|
3438
3404
|
getIndex: () => t.index,
|
3439
3405
|
cleanup: n
|
@@ -3462,14 +3428,14 @@ function sendAPIQuery(e, t, r) {
|
|
3462
3428
|
if (!o)
|
3463
3429
|
return r(void 0, 424), emptyCallback$1;
|
3464
3430
|
a = o.send;
|
3465
|
-
const
|
3466
|
-
|
3431
|
+
const i = getRedundancyCache(e);
|
3432
|
+
i && (n = i.redundancy);
|
3467
3433
|
} else {
|
3468
3434
|
const o = createAPIConfig(e);
|
3469
3435
|
if (o) {
|
3470
3436
|
n = initRedundancy(o);
|
3471
|
-
const
|
3472
|
-
|
3437
|
+
const i = e.resources ? e.resources[0] : "", s = getAPIModule(i);
|
3438
|
+
s && (a = s.send);
|
3473
3439
|
}
|
3474
3440
|
}
|
3475
3441
|
return !n || !a ? (r(void 0, 424), emptyCallback$1) : n.query(t, a, r)().abort;
|
@@ -3527,28 +3493,28 @@ function iterateBrowserStorage(e, t) {
|
|
3527
3493
|
const n = getStoredItem(r, browserCacheVersionKey);
|
3528
3494
|
if (n !== browserCacheVersion) {
|
3529
3495
|
if (n) {
|
3530
|
-
const
|
3531
|
-
for (let l = 0; l <
|
3496
|
+
const s = getBrowserStorageItemsCount(r);
|
3497
|
+
for (let l = 0; l < s; l++)
|
3532
3498
|
removeStoredItem(r, browserCachePrefix + l.toString());
|
3533
3499
|
}
|
3534
3500
|
setStoredItem(r, browserCacheVersionKey, browserCacheVersion), setBrowserStorageItemsCount(r, 0);
|
3535
3501
|
return;
|
3536
3502
|
}
|
3537
|
-
const a = Math.floor(Date.now() / browserStorageHour) - browserStorageCacheExpiration, o = (
|
3538
|
-
const l = browserCachePrefix +
|
3503
|
+
const a = Math.floor(Date.now() / browserStorageHour) - browserStorageCacheExpiration, o = (s) => {
|
3504
|
+
const l = browserCachePrefix + s.toString(), u = getStoredItem(r, l);
|
3539
3505
|
if (typeof u == "string") {
|
3540
3506
|
try {
|
3541
3507
|
const c = JSON.parse(u);
|
3542
|
-
if (typeof c == "object" && typeof c.cached == "number" && c.cached > a && typeof c.provider == "string" && typeof c.data == "object" && typeof c.data.prefix == "string" && t(c,
|
3508
|
+
if (typeof c == "object" && typeof c.cached == "number" && c.cached > a && typeof c.provider == "string" && typeof c.data == "object" && typeof c.data.prefix == "string" && t(c, s))
|
3543
3509
|
return !0;
|
3544
3510
|
} catch {
|
3545
3511
|
}
|
3546
3512
|
removeStoredItem(r, l);
|
3547
3513
|
}
|
3548
3514
|
};
|
3549
|
-
let
|
3550
|
-
for (let
|
3551
|
-
o(
|
3515
|
+
let i = getBrowserStorageItemsCount(r);
|
3516
|
+
for (let s = i - 1; s >= 0; s--)
|
3517
|
+
o(s) || (s === i - 1 ? (i--, setBrowserStorageItemsCount(r, i)) : browserStorageEmptyItems[e].add(s));
|
3552
3518
|
}
|
3553
3519
|
function initBrowserStorage() {
|
3554
3520
|
if (!browserStorageStatus) {
|
@@ -3561,8 +3527,8 @@ function initBrowserStorage() {
|
|
3561
3527
|
);
|
3562
3528
|
if (!addIconSet(o, r).length)
|
3563
3529
|
return !1;
|
3564
|
-
const
|
3565
|
-
return o.lastModifiedCached = o.lastModifiedCached ? Math.min(o.lastModifiedCached,
|
3530
|
+
const i = r.lastModified || -1;
|
3531
|
+
return o.lastModifiedCached = o.lastModifiedCached ? Math.min(o.lastModifiedCached, i) : i, !0;
|
3566
3532
|
});
|
3567
3533
|
}
|
3568
3534
|
}
|
@@ -3585,20 +3551,20 @@ function storeInBrowserStorage(e, t) {
|
|
3585
3551
|
if (!browserStorageConfig[n] || !(a = getBrowserStorage(n)))
|
3586
3552
|
return;
|
3587
3553
|
const o = browserStorageEmptyItems[n];
|
3588
|
-
let
|
3554
|
+
let i;
|
3589
3555
|
if (o.size)
|
3590
|
-
o.delete(
|
3591
|
-
else if (
|
3556
|
+
o.delete(i = Array.from(o).shift());
|
3557
|
+
else if (i = getBrowserStorageItemsCount(a), !setBrowserStorageItemsCount(a, i + 1))
|
3592
3558
|
return;
|
3593
|
-
const
|
3559
|
+
const s = {
|
3594
3560
|
cached: Math.floor(Date.now() / browserStorageHour),
|
3595
3561
|
provider: e.provider,
|
3596
3562
|
data: t
|
3597
3563
|
};
|
3598
3564
|
return setStoredItem(
|
3599
3565
|
a,
|
3600
|
-
browserCachePrefix +
|
3601
|
-
JSON.stringify(
|
3566
|
+
browserCachePrefix + i.toString(),
|
3567
|
+
JSON.stringify(s)
|
3602
3568
|
);
|
3603
3569
|
}
|
3604
3570
|
t.lastModified && !updateLastModified(e, t.lastModified) || !Object.keys(t.icons).length || (t.not_found && (t = Object.assign({}, t), delete t.not_found), r("local") || r("session"));
|
@@ -3618,10 +3584,10 @@ function loadNewIcons(e, t) {
|
|
3618
3584
|
let o;
|
3619
3585
|
if (!a || !(o = getAPIModule(r)))
|
3620
3586
|
return;
|
3621
|
-
o.prepare(r, n, a).forEach((
|
3622
|
-
sendAPIQuery(r,
|
3587
|
+
o.prepare(r, n, a).forEach((s) => {
|
3588
|
+
sendAPIQuery(r, s, (l) => {
|
3623
3589
|
if (typeof l != "object")
|
3624
|
-
|
3590
|
+
s.icons.forEach((u) => {
|
3625
3591
|
e.missing.add(u);
|
3626
3592
|
});
|
3627
3593
|
else
|
@@ -3660,12 +3626,12 @@ const loadIcons = (e, t) => {
|
|
3660
3626
|
};
|
3661
3627
|
}
|
3662
3628
|
const a = /* @__PURE__ */ Object.create(null), o = [];
|
3663
|
-
let
|
3629
|
+
let i, s;
|
3664
3630
|
return n.pending.forEach((l) => {
|
3665
3631
|
const { provider: u, prefix: c } = l;
|
3666
|
-
if (c ===
|
3632
|
+
if (c === s && u === i)
|
3667
3633
|
return;
|
3668
|
-
|
3634
|
+
i = u, s = c, o.push(getStorage(u, c));
|
3669
3635
|
const g = a[u] || (a[u] = /* @__PURE__ */ Object.create(null));
|
3670
3636
|
g[c] || (g[c] = []);
|
3671
3637
|
}), n.pending.forEach((l) => {
|
@@ -3777,7 +3743,7 @@ function fixSize(e) {
|
|
3777
3743
|
return e + (e.match(/^[-0-9.]+$/) ? "px" : "");
|
3778
3744
|
}
|
3779
3745
|
const render = (e, t) => {
|
3780
|
-
const r = mergeCustomisations(defaultExtendedIconCustomisations, t), n = { ...svgDefaults }, a = t.mode || "svg", o = {},
|
3746
|
+
const r = mergeCustomisations(defaultExtendedIconCustomisations, t), n = { ...svgDefaults }, a = t.mode || "svg", o = {}, i = t.style, s = typeof i == "object" && !(i instanceof Array) ? i : {};
|
3781
3747
|
for (let v in t) {
|
3782
3748
|
const _ = t[v];
|
3783
3749
|
if (_ !== void 0)
|
@@ -3815,7 +3781,7 @@ const render = (e, t) => {
|
|
3815
3781
|
if (r.inline && (o.verticalAlign = "-0.125em"), a === "svg") {
|
3816
3782
|
n.style = {
|
3817
3783
|
...o,
|
3818
|
-
...
|
3784
|
+
...s
|
3819
3785
|
}, Object.assign(n, u);
|
3820
3786
|
let v = 0, _ = t.id;
|
3821
3787
|
return typeof _ == "string" && (_ = _.replace(/-/g, "_")), n.innerHTML = replaceIDs(l.body, _ ? () => _ + "ID" + v++ : "iconifyVue"), h("svg", n);
|
@@ -3832,7 +3798,7 @@ const render = (e, t) => {
|
|
3832
3798
|
height: fixSize(u.height),
|
3833
3799
|
...commonProps,
|
3834
3800
|
...b ? monotoneProps : coloredProps,
|
3835
|
-
...
|
3801
|
+
...s
|
3836
3802
|
}, h("span", n);
|
3837
3803
|
};
|
3838
3804
|
allowSimpleNames(!0);
|
@@ -3933,7 +3899,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3933
3899
|
(function(r, n) {
|
3934
3900
|
e.exports = n();
|
3935
3901
|
})(commonjsGlobal, function() {
|
3936
|
-
var r = 1e3, n = 6e4, a = 36e5, o = "millisecond",
|
3902
|
+
var r = 1e3, n = 6e4, a = 36e5, o = "millisecond", i = "second", s = "minute", l = "hour", u = "day", c = "week", g = "month", p = "quarter", b = "year", m = "date", v = "Invalid Date", _ = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, y = /\[([^\]]+)]|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(P) {
|
3937
3903
|
var D = ["th", "st", "nd", "rd"], V = P % 100;
|
3938
3904
|
return "[" + P + (D[(V - 20) % 10] || D[V] || D[0]) + "]";
|
3939
3905
|
} }, E = function(P, D, V) {
|
@@ -3950,7 +3916,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
3950
3916
|
}, a: function(P) {
|
3951
3917
|
return P < 0 ? Math.ceil(P) || 0 : Math.floor(P);
|
3952
3918
|
}, p: function(P) {
|
3953
|
-
return { M: g, y: b, w: c, d: u, D: m, h: l, m:
|
3919
|
+
return { M: g, y: b, w: c, d: u, D: m, h: l, m: s, s: i, ms: o, Q: p }[P] || String(P || "").toLowerCase().replace(/s$/, "");
|
3954
3920
|
}, u: function(P) {
|
3955
3921
|
return P === void 0;
|
3956
3922
|
} }, I = "en", k = {};
|
@@ -4044,9 +4010,9 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4044
4010
|
return q(ee + "Hours", 0);
|
4045
4011
|
case l:
|
4046
4012
|
return q(ee + "Minutes", 1);
|
4047
|
-
case i:
|
4048
|
-
return q(ee + "Seconds", 2);
|
4049
4013
|
case s:
|
4014
|
+
return q(ee + "Seconds", 2);
|
4015
|
+
case i:
|
4050
4016
|
return q(ee + "Milliseconds", 3);
|
4051
4017
|
default:
|
4052
4018
|
return this.clone();
|
@@ -4054,7 +4020,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4054
4020
|
}, D.endOf = function(V) {
|
4055
4021
|
return this.startOf(V, !1);
|
4056
4022
|
}, D.$set = function(V, R) {
|
4057
|
-
var L, H = O.p(V), N = "set" + (this.$u ? "UTC" : ""), x = (L = {}, L[u] = N + "Date", L[m] = N + "Date", L[g] = N + "Month", L[b] = N + "FullYear", L[l] = N + "Hours", L[
|
4023
|
+
var L, H = O.p(V), N = "set" + (this.$u ? "UTC" : ""), x = (L = {}, L[u] = N + "Date", L[m] = N + "Date", L[g] = N + "Month", L[b] = N + "FullYear", L[l] = N + "Hours", L[s] = N + "Minutes", L[i] = N + "Seconds", L[o] = N + "Milliseconds", L)[H], q = H === u ? this.$D + (R - this.$W) : R;
|
4058
4024
|
if (H === g || H === b) {
|
4059
4025
|
var Y = this.clone().set(m, 1);
|
4060
4026
|
Y.$d[x](q), Y.init(), this.$d = Y.set(m, Math.min(this.$D, Y.daysInMonth())).$d;
|
@@ -4080,7 +4046,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4080
4046
|
return x(1);
|
4081
4047
|
if (N === c)
|
4082
4048
|
return x(7);
|
4083
|
-
var q = (L = {}, L[
|
4049
|
+
var q = (L = {}, L[s] = n, L[l] = a, L[i] = r, L)[N] || 1, Y = this.$d.getTime() + V * q;
|
4084
4050
|
return O.w(Y, this);
|
4085
4051
|
}, D.subtract = function(V, R) {
|
4086
4052
|
return this.add(-1 * V, R);
|
@@ -4103,7 +4069,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4103
4069
|
return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
|
4104
4070
|
}, D.diff = function(V, R, L) {
|
4105
4071
|
var H, N = O.p(R), x = A(V), q = (x.utcOffset() - this.utcOffset()) * n, Y = this - x, Q = O.m(this, x);
|
4106
|
-
return Q = (H = {}, H[b] = Q / 12, H[g] = Q, H[p] = Q / 3, H[c] = (Y - q) / 6048e5, H[u] = (Y - q) / 864e5, H[l] = Y / a, H[
|
4072
|
+
return Q = (H = {}, H[b] = Q / 12, H[g] = Q, H[p] = Q / 3, H[c] = (Y - q) / 6048e5, H[u] = (Y - q) / 864e5, H[l] = Y / a, H[s] = Y / n, H[i] = Y / r, H)[N] || Y, L ? Q : O.a(Q);
|
4107
4073
|
}, D.daysInMonth = function() {
|
4108
4074
|
return this.endOf(g).$D;
|
4109
4075
|
}, D.$locale = function() {
|
@@ -4125,7 +4091,7 @@ var commonjsGlobal = typeof globalThis < "u" ? globalThis : typeof window < "u"
|
|
4125
4091
|
return this.$d.toUTCString();
|
4126
4092
|
}, P;
|
4127
4093
|
}(), $ = B.prototype;
|
4128
|
-
return A.prototype = $, [["$ms", o], ["$s",
|
4094
|
+
return A.prototype = $, [["$ms", o], ["$s", i], ["$m", s], ["$H", l], ["$W", u], ["$M", g], ["$y", b], ["$D", m]].forEach(function(P) {
|
4129
4095
|
$[P[1]] = function(D) {
|
4130
4096
|
return this.$g(D, P[0], P[1]);
|
4131
4097
|
};
|
@@ -4166,8 +4132,8 @@ function filesize(e, {
|
|
4166
4132
|
base: n = -1,
|
4167
4133
|
round: a = 2,
|
4168
4134
|
locale: o = EMPTY,
|
4169
|
-
localeOptions:
|
4170
|
-
separator:
|
4135
|
+
localeOptions: i = {},
|
4136
|
+
separator: s = EMPTY,
|
4171
4137
|
spacer: l = SPACE,
|
4172
4138
|
symbols: u = {},
|
4173
4139
|
standard: c = EMPTY,
|
@@ -4194,8 +4160,8 @@ function filesize(e, {
|
|
4194
4160
|
const O = Math.pow(10, y > 0 ? a : 0);
|
4195
4161
|
E[0] = A(T * O) / O, E[0] === k && y < 8 && m === -1 && (E[0] = 1, y++), I = E[1] = n === 10 && y === 1 ? t ? SI_KBIT : SI_KBYTE : STRINGS.symbol[c][t ? BITS : BYTES][y];
|
4196
4162
|
}
|
4197
|
-
if (M && (E[0] = -E[0]), _ > 0 && (E[0] = E[0].toPrecision(_)), E[1] = u[E[1]] || E[1], o === !0 ? E[0] = E[0].toLocaleString() : o.length > 0 ? E[0] = E[0].toLocaleString(o,
|
4198
|
-
const O =
|
4163
|
+
if (M && (E[0] = -E[0]), _ > 0 && (E[0] = E[0].toPrecision(_)), E[1] = u[E[1]] || E[1], o === !0 ? E[0] = E[0].toLocaleString() : o.length > 0 ? E[0] = E[0].toLocaleString(o, i) : s.length > 0 && (E[0] = E[0].toString().replace(PERIOD, s)), r && Number.isInteger(E[0]) === !1 && a > 0) {
|
4164
|
+
const O = s || PERIOD, B = E[0].toString().split(O), $ = B[1] || EMPTY, P = $.length, D = a - P;
|
4199
4165
|
E[0] = `${B[0]}${O}${$.padEnd(P + D, ZERO)}`;
|
4200
4166
|
}
|
4201
4167
|
return w && (E[1] = b[y] ? b[y] : STRINGS.fullform[c][y] + (t ? BIT : BYTE) + (E[0] === 1 ? EMPTY : S)), g === ARRAY ? E : g === OBJECT ? {
|
@@ -4469,21 +4435,21 @@ function assignValue(e, t, r) {
|
|
4469
4435
|
function copyObject(e, t, r, n) {
|
4470
4436
|
var a = !r;
|
4471
4437
|
r || (r = {});
|
4472
|
-
for (var o = -1,
|
4473
|
-
var
|
4474
|
-
l === void 0 && (l = e[
|
4438
|
+
for (var o = -1, i = t.length; ++o < i; ) {
|
4439
|
+
var s = t[o], l = n ? n(r[s], e[s], s, r, e) : void 0;
|
4440
|
+
l === void 0 && (l = e[s]), a ? baseAssignValue(r, s, l) : assignValue(r, s, l);
|
4475
4441
|
}
|
4476
4442
|
return r;
|
4477
4443
|
}
|
4478
4444
|
var nativeMax$1 = Math.max;
|
4479
4445
|
function overRest(e, t, r) {
|
4480
4446
|
return t = nativeMax$1(t === void 0 ? e.length - 1 : t, 0), function() {
|
4481
|
-
for (var n = arguments, a = -1, o = nativeMax$1(n.length - t, 0),
|
4482
|
-
|
4447
|
+
for (var n = arguments, a = -1, o = nativeMax$1(n.length - t, 0), i = Array(o); ++a < o; )
|
4448
|
+
i[a] = n[t + a];
|
4483
4449
|
a = -1;
|
4484
|
-
for (var
|
4485
|
-
|
4486
|
-
return
|
4450
|
+
for (var s = Array(t + 1); ++a < t; )
|
4451
|
+
s[a] = n[a];
|
4452
|
+
return s[t] = r(i), apply(e, this, s);
|
4487
4453
|
};
|
4488
4454
|
}
|
4489
4455
|
function baseRest(e, t) {
|
@@ -4550,10 +4516,10 @@ var nodeIsTypedArray = nodeUtil$1 && nodeUtil$1.isTypedArray, isTypedArray = nod
|
|
4550
4516
|
const isTypedArray$1 = isTypedArray;
|
4551
4517
|
var objectProto$8 = Object.prototype, hasOwnProperty$7 = objectProto$8.hasOwnProperty;
|
4552
4518
|
function arrayLikeKeys(e, t) {
|
4553
|
-
var r = isArray$1(e), n = !r && isArguments$1(e), a = !r && !n && isBuffer$1(e), o = !r && !n && !a && isTypedArray$1(e),
|
4519
|
+
var r = isArray$1(e), n = !r && isArguments$1(e), a = !r && !n && isBuffer$1(e), o = !r && !n && !a && isTypedArray$1(e), i = r || n || a || o, s = i ? baseTimes(e.length, String) : [], l = s.length;
|
4554
4520
|
for (var u in e)
|
4555
|
-
(t || hasOwnProperty$7.call(e, u)) && !(
|
4556
|
-
return
|
4521
|
+
(t || hasOwnProperty$7.call(e, u)) && !(i && (u == "length" || a && (u == "offset" || u == "parent") || o && (u == "buffer" || u == "byteLength" || u == "byteOffset") || isIndex(u, l))) && s.push(u);
|
4522
|
+
return s;
|
4557
4523
|
}
|
4558
4524
|
function overArg(e, t) {
|
4559
4525
|
return function(r) {
|
@@ -4731,8 +4697,8 @@ function memoize(e, t) {
|
|
4731
4697
|
var n = arguments, a = t ? t.apply(this, n) : n[0], o = r.cache;
|
4732
4698
|
if (o.has(a))
|
4733
4699
|
return o.get(a);
|
4734
|
-
var
|
4735
|
-
return r.cache = o.set(a,
|
4700
|
+
var i = e.apply(this, n);
|
4701
|
+
return r.cache = o.set(a, i) || o, i;
|
4736
4702
|
};
|
4737
4703
|
return r.cache = new (memoize.Cache || MapCache)(), r;
|
4738
4704
|
}
|
@@ -4784,10 +4750,10 @@ function isFlattenable(e) {
|
|
4784
4750
|
return isArray$1(e) || isArguments$1(e) || !!(spreadableSymbol && e && e[spreadableSymbol]);
|
4785
4751
|
}
|
4786
4752
|
function baseFlatten(e, t, r, n, a) {
|
4787
|
-
var o = -1,
|
4788
|
-
for (r || (r = isFlattenable), a || (a = []); ++o <
|
4789
|
-
var
|
4790
|
-
t > 0 && r(
|
4753
|
+
var o = -1, i = e.length;
|
4754
|
+
for (r || (r = isFlattenable), a || (a = []); ++o < i; ) {
|
4755
|
+
var s = e[o];
|
4756
|
+
t > 0 && r(s) ? t > 1 ? baseFlatten(s, t - 1, r, n, a) : arrayPush(a, s) : n || (a[a.length] = s);
|
4791
4757
|
}
|
4792
4758
|
return a;
|
4793
4759
|
}
|
@@ -5079,8 +5045,8 @@ function cloneBuffer(e, t) {
|
|
5079
5045
|
}
|
5080
5046
|
function arrayFilter(e, t) {
|
5081
5047
|
for (var r = -1, n = e == null ? 0 : e.length, a = 0, o = []; ++r < n; ) {
|
5082
|
-
var
|
5083
|
-
t(
|
5048
|
+
var i = e[r];
|
5049
|
+
t(i, r, e) && (o[a++] = i);
|
5084
5050
|
}
|
5085
5051
|
return o;
|
5086
5052
|
}
|
@@ -5221,41 +5187,41 @@ var CLONE_DEEP_FLAG$1 = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG$1 = 4, argsTa
|
|
5221
5187
|
cloneableTags[argsTag$1] = cloneableTags[arrayTag$1] = cloneableTags[arrayBufferTag$1] = cloneableTags[dataViewTag$1] = cloneableTags[boolTag$1] = cloneableTags[dateTag$1] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag$2] = cloneableTags[numberTag$1] = cloneableTags[objectTag$1] = cloneableTags[regexpTag$1] = cloneableTags[setTag$2] = cloneableTags[stringTag$2] = cloneableTags[symbolTag$1] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = !0;
|
5222
5188
|
cloneableTags[errorTag$1] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = !1;
|
5223
5189
|
function baseClone(e, t, r, n, a, o) {
|
5224
|
-
var
|
5225
|
-
if (r && (
|
5226
|
-
return
|
5190
|
+
var i, s = t & CLONE_DEEP_FLAG$1, l = t & CLONE_FLAT_FLAG, u = t & CLONE_SYMBOLS_FLAG$1;
|
5191
|
+
if (r && (i = a ? r(e, n, a, o) : r(e)), i !== void 0)
|
5192
|
+
return i;
|
5227
5193
|
if (!isObject$2(e))
|
5228
5194
|
return e;
|
5229
5195
|
var c = isArray$1(e);
|
5230
5196
|
if (c) {
|
5231
|
-
if (
|
5232
|
-
return copyArray(e,
|
5197
|
+
if (i = initCloneArray(e), !s)
|
5198
|
+
return copyArray(e, i);
|
5233
5199
|
} else {
|
5234
5200
|
var g = getTag$1(e), p = g == funcTag || g == genTag;
|
5235
5201
|
if (isBuffer$1(e))
|
5236
|
-
return cloneBuffer(e,
|
5202
|
+
return cloneBuffer(e, s);
|
5237
5203
|
if (g == objectTag$1 || g == argsTag$1 || p && !a) {
|
5238
|
-
if (
|
5239
|
-
return l ? copySymbolsIn(e, baseAssignIn(
|
5204
|
+
if (i = l || p ? {} : initCloneObject(e), !s)
|
5205
|
+
return l ? copySymbolsIn(e, baseAssignIn(i, e)) : copySymbols(e, baseAssign(i, e));
|
5240
5206
|
} else {
|
5241
5207
|
if (!cloneableTags[g])
|
5242
5208
|
return a ? e : {};
|
5243
|
-
|
5209
|
+
i = initCloneByTag(e, g, s);
|
5244
5210
|
}
|
5245
5211
|
}
|
5246
5212
|
o || (o = new Stack());
|
5247
5213
|
var b = o.get(e);
|
5248
5214
|
if (b)
|
5249
5215
|
return b;
|
5250
|
-
o.set(e,
|
5251
|
-
|
5216
|
+
o.set(e, i), isSet$1(e) ? e.forEach(function(_) {
|
5217
|
+
i.add(baseClone(_, t, r, _, e, o));
|
5252
5218
|
}) : isMap$1(e) && e.forEach(function(_, y) {
|
5253
|
-
|
5219
|
+
i.set(y, baseClone(_, t, r, y, e, o));
|
5254
5220
|
});
|
5255
5221
|
var m = u ? l ? getAllKeysIn : getAllKeys : l ? keysIn : keys, v = c ? void 0 : m(e);
|
5256
5222
|
return arrayEach(v || e, function(_, y) {
|
5257
|
-
v && (y = _, _ = e[y]), assignValue(
|
5258
|
-
}),
|
5223
|
+
v && (y = _, _ = e[y]), assignValue(i, y, baseClone(_, t, r, y, e, o));
|
5224
|
+
}), i;
|
5259
5225
|
}
|
5260
5226
|
var CLONE_DEEP_FLAG = 1, CLONE_SYMBOLS_FLAG = 4;
|
5261
5227
|
function cloneDeep(e) {
|
@@ -5286,17 +5252,17 @@ function cacheHas(e, t) {
|
|
5286
5252
|
}
|
5287
5253
|
var COMPARE_PARTIAL_FLAG$5 = 1, COMPARE_UNORDERED_FLAG$3 = 2;
|
5288
5254
|
function equalArrays(e, t, r, n, a, o) {
|
5289
|
-
var
|
5290
|
-
if (
|
5255
|
+
var i = r & COMPARE_PARTIAL_FLAG$5, s = e.length, l = t.length;
|
5256
|
+
if (s != l && !(i && l > s))
|
5291
5257
|
return !1;
|
5292
5258
|
var u = o.get(e), c = o.get(t);
|
5293
5259
|
if (u && c)
|
5294
5260
|
return u == t && c == e;
|
5295
5261
|
var g = -1, p = !0, b = r & COMPARE_UNORDERED_FLAG$3 ? new SetCache() : void 0;
|
5296
|
-
for (o.set(e, t), o.set(t, e); ++g <
|
5262
|
+
for (o.set(e, t), o.set(t, e); ++g < s; ) {
|
5297
5263
|
var m = e[g], v = t[g];
|
5298
5264
|
if (n)
|
5299
|
-
var _ =
|
5265
|
+
var _ = i ? n(v, m, g, t, e, o) : n(m, v, g, e, t, o);
|
5300
5266
|
if (_ !== void 0) {
|
5301
5267
|
if (_)
|
5302
5268
|
continue;
|
@@ -5331,7 +5297,7 @@ function setToArray(e) {
|
|
5331
5297
|
}), r;
|
5332
5298
|
}
|
5333
5299
|
var COMPARE_PARTIAL_FLAG$4 = 1, COMPARE_UNORDERED_FLAG$2 = 2, boolTag = "[object Boolean]", dateTag = "[object Date]", errorTag = "[object Error]", mapTag$1 = "[object Map]", numberTag = "[object Number]", regexpTag = "[object RegExp]", setTag$1 = "[object Set]", stringTag$1 = "[object String]", symbolTag = "[object Symbol]", arrayBufferTag = "[object ArrayBuffer]", dataViewTag = "[object DataView]", symbolProto = Symbol$2 ? Symbol$2.prototype : void 0, symbolValueOf = symbolProto ? symbolProto.valueOf : void 0;
|
5334
|
-
function equalByTag(e, t, r, n, a, o,
|
5300
|
+
function equalByTag(e, t, r, n, a, o, i) {
|
5335
5301
|
switch (r) {
|
5336
5302
|
case dataViewTag:
|
5337
5303
|
if (e.byteLength != t.byteLength || e.byteOffset != t.byteOffset)
|
@@ -5349,17 +5315,17 @@ function equalByTag(e, t, r, n, a, o, s) {
|
|
5349
5315
|
case stringTag$1:
|
5350
5316
|
return e == t + "";
|
5351
5317
|
case mapTag$1:
|
5352
|
-
var
|
5318
|
+
var s = mapToArray;
|
5353
5319
|
case setTag$1:
|
5354
5320
|
var l = n & COMPARE_PARTIAL_FLAG$4;
|
5355
|
-
if (
|
5321
|
+
if (s || (s = setToArray), e.size != t.size && !l)
|
5356
5322
|
return !1;
|
5357
|
-
var u =
|
5323
|
+
var u = i.get(e);
|
5358
5324
|
if (u)
|
5359
5325
|
return u == t;
|
5360
|
-
n |= COMPARE_UNORDERED_FLAG$2,
|
5361
|
-
var c = equalArrays(
|
5362
|
-
return
|
5326
|
+
n |= COMPARE_UNORDERED_FLAG$2, i.set(e, t);
|
5327
|
+
var c = equalArrays(s(e), s(t), n, a, o, i);
|
5328
|
+
return i.delete(e), c;
|
5363
5329
|
case symbolTag:
|
5364
5330
|
if (symbolValueOf)
|
5365
5331
|
return symbolValueOf.call(e) == symbolValueOf.call(t);
|
@@ -5368,12 +5334,12 @@ function equalByTag(e, t, r, n, a, o, s) {
|
|
5368
5334
|
}
|
5369
5335
|
var COMPARE_PARTIAL_FLAG$3 = 1, objectProto$1 = Object.prototype, hasOwnProperty$1 = objectProto$1.hasOwnProperty;
|
5370
5336
|
function equalObjects(e, t, r, n, a, o) {
|
5371
|
-
var
|
5372
|
-
if (l != c && !
|
5337
|
+
var i = r & COMPARE_PARTIAL_FLAG$3, s = getAllKeys(e), l = s.length, u = getAllKeys(t), c = u.length;
|
5338
|
+
if (l != c && !i)
|
5373
5339
|
return !1;
|
5374
5340
|
for (var g = l; g--; ) {
|
5375
|
-
var p =
|
5376
|
-
if (!(
|
5341
|
+
var p = s[g];
|
5342
|
+
if (!(i ? p in t : hasOwnProperty$1.call(t, p)))
|
5377
5343
|
return !1;
|
5378
5344
|
}
|
5379
5345
|
var b = o.get(e), m = o.get(t);
|
@@ -5381,11 +5347,11 @@ function equalObjects(e, t, r, n, a, o) {
|
|
5381
5347
|
return b == t && m == e;
|
5382
5348
|
var v = !0;
|
5383
5349
|
o.set(e, t), o.set(t, e);
|
5384
|
-
for (var _ =
|
5385
|
-
p =
|
5350
|
+
for (var _ = i; ++g < l; ) {
|
5351
|
+
p = s[g];
|
5386
5352
|
var y = e[p], C = t[p];
|
5387
5353
|
if (n)
|
5388
|
-
var E =
|
5354
|
+
var E = i ? n(C, y, p, t, e, o) : n(y, C, p, e, t, o);
|
5389
5355
|
if (!(E === void 0 ? y === C || a(y, C, r, n, o) : E)) {
|
5390
5356
|
v = !1;
|
5391
5357
|
break;
|
@@ -5400,16 +5366,16 @@ function equalObjects(e, t, r, n, a, o) {
|
|
5400
5366
|
}
|
5401
5367
|
var COMPARE_PARTIAL_FLAG$2 = 1, argsTag = "[object Arguments]", arrayTag = "[object Array]", objectTag = "[object Object]", objectProto = Object.prototype, hasOwnProperty = objectProto.hasOwnProperty;
|
5402
5368
|
function baseIsEqualDeep(e, t, r, n, a, o) {
|
5403
|
-
var
|
5369
|
+
var i = isArray$1(e), s = isArray$1(t), l = i ? arrayTag : getTag$1(e), u = s ? arrayTag : getTag$1(t);
|
5404
5370
|
l = l == argsTag ? objectTag : l, u = u == argsTag ? objectTag : u;
|
5405
5371
|
var c = l == objectTag, g = u == objectTag, p = l == u;
|
5406
5372
|
if (p && isBuffer$1(e)) {
|
5407
5373
|
if (!isBuffer$1(t))
|
5408
5374
|
return !1;
|
5409
|
-
|
5375
|
+
i = !0, c = !1;
|
5410
5376
|
}
|
5411
5377
|
if (p && !c)
|
5412
|
-
return o || (o = new Stack()),
|
5378
|
+
return o || (o = new Stack()), i || isTypedArray$1(e) ? equalArrays(e, t, r, n, a, o) : equalByTag(e, t, l, r, n, a, o);
|
5413
5379
|
if (!(r & COMPARE_PARTIAL_FLAG$2)) {
|
5414
5380
|
var b = c && hasOwnProperty.call(e, "__wrapped__"), m = g && hasOwnProperty.call(t, "__wrapped__");
|
5415
5381
|
if (b || m) {
|
@@ -5424,18 +5390,18 @@ function baseIsEqual(e, t, r, n, a) {
|
|
5424
5390
|
}
|
5425
5391
|
var COMPARE_PARTIAL_FLAG$1 = 1, COMPARE_UNORDERED_FLAG$1 = 2;
|
5426
5392
|
function baseIsMatch(e, t, r, n) {
|
5427
|
-
var a = r.length, o = a,
|
5393
|
+
var a = r.length, o = a, i = !n;
|
5428
5394
|
if (e == null)
|
5429
5395
|
return !o;
|
5430
5396
|
for (e = Object(e); a--; ) {
|
5431
|
-
var
|
5432
|
-
if (
|
5397
|
+
var s = r[a];
|
5398
|
+
if (i && s[2] ? s[1] !== e[s[0]] : !(s[0] in e))
|
5433
5399
|
return !1;
|
5434
5400
|
}
|
5435
5401
|
for (; ++a < o; ) {
|
5436
|
-
|
5437
|
-
var l =
|
5438
|
-
if (
|
5402
|
+
s = r[a];
|
5403
|
+
var l = s[0], u = e[l], c = s[1];
|
5404
|
+
if (i && s[2]) {
|
5439
5405
|
if (u === void 0 && !(l in e))
|
5440
5406
|
return !1;
|
5441
5407
|
} else {
|
@@ -5475,12 +5441,12 @@ function baseHasIn(e, t) {
|
|
5475
5441
|
function hasPath(e, t, r) {
|
5476
5442
|
t = castPath(t, e);
|
5477
5443
|
for (var n = -1, a = t.length, o = !1; ++n < a; ) {
|
5478
|
-
var
|
5479
|
-
if (!(o = e != null && r(e,
|
5444
|
+
var i = toKey(t[n]);
|
5445
|
+
if (!(o = e != null && r(e, i)))
|
5480
5446
|
break;
|
5481
|
-
e = e[
|
5447
|
+
e = e[i];
|
5482
5448
|
}
|
5483
|
-
return o || ++n != a ? o : (a = e == null ? 0 : e.length, !!a && isLength(a) && isIndex(
|
5449
|
+
return o || ++n != a ? o : (a = e == null ? 0 : e.length, !!a && isLength(a) && isIndex(i, a) && (isArray$1(e) || isArguments$1(e)));
|
5484
5450
|
}
|
5485
5451
|
function hasIn(e, t) {
|
5486
5452
|
return e != null && hasPath(e, t, baseHasIn);
|
@@ -5510,8 +5476,8 @@ function baseIteratee(e) {
|
|
5510
5476
|
}
|
5511
5477
|
function createBaseFor(e) {
|
5512
5478
|
return function(t, r, n) {
|
5513
|
-
for (var a = -1, o = Object(t),
|
5514
|
-
var l =
|
5479
|
+
for (var a = -1, o = Object(t), i = n(t), s = i.length; s--; ) {
|
5480
|
+
var l = i[e ? s : ++a];
|
5515
5481
|
if (r(o[l], l, o) === !1)
|
5516
5482
|
break;
|
5517
5483
|
}
|
@@ -5529,7 +5495,7 @@ function createBaseEach(e, t) {
|
|
5529
5495
|
return r;
|
5530
5496
|
if (!isArrayLike(r))
|
5531
5497
|
return e(r, n);
|
5532
|
-
for (var a = r.length, o = t ? a : -1,
|
5498
|
+
for (var a = r.length, o = t ? a : -1, i = Object(r); (t ? o-- : ++o < a) && n(i[o], o, i) !== !1; )
|
5533
5499
|
;
|
5534
5500
|
return r;
|
5535
5501
|
};
|
@@ -5547,14 +5513,14 @@ function arrayIncludesWith(e, t, r) {
|
|
5547
5513
|
}
|
5548
5514
|
var LARGE_ARRAY_SIZE$1 = 200;
|
5549
5515
|
function baseDifference(e, t, r, n) {
|
5550
|
-
var a = -1, o = arrayIncludes,
|
5551
|
-
if (!
|
5516
|
+
var a = -1, o = arrayIncludes, i = !0, s = e.length, l = [], u = t.length;
|
5517
|
+
if (!s)
|
5552
5518
|
return l;
|
5553
|
-
r && (t = arrayMap(t, baseUnary(r))), n ? (o = arrayIncludesWith,
|
5519
|
+
r && (t = arrayMap(t, baseUnary(r))), n ? (o = arrayIncludesWith, i = !1) : t.length >= LARGE_ARRAY_SIZE$1 && (o = cacheHas, i = !1, t = new SetCache(t));
|
5554
5520
|
e:
|
5555
|
-
for (; ++a <
|
5521
|
+
for (; ++a < s; ) {
|
5556
5522
|
var c = e[a], g = r == null ? c : r(c);
|
5557
|
-
if (c = n || c !== 0 ? c : 0,
|
5523
|
+
if (c = n || c !== 0 ? c : 0, i && g === g) {
|
5558
5524
|
for (var p = u; p--; )
|
5559
5525
|
if (t[p] === g)
|
5560
5526
|
continue e;
|
@@ -5586,8 +5552,8 @@ var toPairs = createToPairs(keys);
|
|
5586
5552
|
const toPairs$1 = toPairs;
|
5587
5553
|
function baseMap(e, t) {
|
5588
5554
|
var r = -1, n = isArrayLike(e) ? Array(e.length) : [];
|
5589
|
-
return baseEach$1(e, function(a, o,
|
5590
|
-
n[++r] = t(a, o,
|
5555
|
+
return baseEach$1(e, function(a, o, i) {
|
5556
|
+
n[++r] = t(a, o, i);
|
5591
5557
|
}), n;
|
5592
5558
|
}
|
5593
5559
|
function baseGt(e, t) {
|
@@ -5599,19 +5565,19 @@ function isString$1(e) {
|
|
5599
5565
|
}
|
5600
5566
|
var nativeMin = Math.min;
|
5601
5567
|
function baseIntersection(e, t, r) {
|
5602
|
-
for (var n = r ? arrayIncludesWith : arrayIncludes, a = e[0].length, o = e.length,
|
5603
|
-
var c = e[
|
5604
|
-
|
5568
|
+
for (var n = r ? arrayIncludesWith : arrayIncludes, a = e[0].length, o = e.length, i = o, s = Array(o), l = 1 / 0, u = []; i--; ) {
|
5569
|
+
var c = e[i];
|
5570
|
+
i && t && (c = arrayMap(c, baseUnary(t))), l = nativeMin(c.length, l), s[i] = !r && (t || a >= 120 && c.length >= 120) ? new SetCache(i && c) : void 0;
|
5605
5571
|
}
|
5606
5572
|
c = e[0];
|
5607
|
-
var g = -1, p =
|
5573
|
+
var g = -1, p = s[0];
|
5608
5574
|
e:
|
5609
5575
|
for (; ++g < a && u.length < l; ) {
|
5610
5576
|
var b = c[g], m = t ? t(b) : b;
|
5611
5577
|
if (b = r || b !== 0 ? b : 0, !(p ? cacheHas(p, m) : n(u, m, r))) {
|
5612
|
-
for (
|
5613
|
-
var v = i
|
5614
|
-
if (!(v ? cacheHas(v, m) : n(e[
|
5578
|
+
for (i = o; --i; ) {
|
5579
|
+
var v = s[i];
|
5580
|
+
if (!(v ? cacheHas(v, m) : n(e[i], m, r)))
|
5615
5581
|
continue e;
|
5616
5582
|
}
|
5617
5583
|
p && p.push(m), u.push(b);
|
@@ -5638,9 +5604,9 @@ function mapValues(e, t) {
|
|
5638
5604
|
}
|
5639
5605
|
function baseExtremum(e, t, r) {
|
5640
5606
|
for (var n = -1, a = e.length; ++n < a; ) {
|
5641
|
-
var o = e[n],
|
5642
|
-
if (
|
5643
|
-
var
|
5607
|
+
var o = e[n], i = t(o);
|
5608
|
+
if (i != null && (s === void 0 ? i === i && !isSymbol(i) : r(i, s)))
|
5609
|
+
var s = i, l = o;
|
5644
5610
|
}
|
5645
5611
|
return l;
|
5646
5612
|
}
|
@@ -5655,19 +5621,19 @@ function baseSortBy(e, t) {
|
|
5655
5621
|
}
|
5656
5622
|
function compareAscending(e, t) {
|
5657
5623
|
if (e !== t) {
|
5658
|
-
var r = e !== void 0, n = e === null, a = e === e, o = isSymbol(e),
|
5659
|
-
if (!
|
5624
|
+
var r = e !== void 0, n = e === null, a = e === e, o = isSymbol(e), i = t !== void 0, s = t === null, l = t === t, u = isSymbol(t);
|
5625
|
+
if (!s && !u && !o && e > t || o && i && l && !s && !u || n && i && l || !r && l || !a)
|
5660
5626
|
return 1;
|
5661
|
-
if (!n && !o && !u && e < t || u && r && a && !n && !o ||
|
5627
|
+
if (!n && !o && !u && e < t || u && r && a && !n && !o || s && r && a || !i && a || !l)
|
5662
5628
|
return -1;
|
5663
5629
|
}
|
5664
5630
|
return 0;
|
5665
5631
|
}
|
5666
5632
|
function compareMultiple(e, t, r) {
|
5667
|
-
for (var n = -1, a = e.criteria, o = t.criteria,
|
5633
|
+
for (var n = -1, a = e.criteria, o = t.criteria, i = a.length, s = r.length; ++n < i; ) {
|
5668
5634
|
var l = compareAscending(a[n], o[n]);
|
5669
5635
|
if (l) {
|
5670
|
-
if (n >=
|
5636
|
+
if (n >= s)
|
5671
5637
|
return l;
|
5672
5638
|
var u = r[n];
|
5673
5639
|
return l * (u == "desc" ? -1 : 1);
|
@@ -5677,27 +5643,27 @@ function compareMultiple(e, t, r) {
|
|
5677
5643
|
}
|
5678
5644
|
function baseOrderBy(e, t, r) {
|
5679
5645
|
t.length ? t = arrayMap(t, function(o) {
|
5680
|
-
return isArray$1(o) ? function(
|
5681
|
-
return baseGet(
|
5646
|
+
return isArray$1(o) ? function(i) {
|
5647
|
+
return baseGet(i, o.length === 1 ? o[0] : o);
|
5682
5648
|
} : o;
|
5683
5649
|
}) : t = [identity];
|
5684
5650
|
var n = -1;
|
5685
5651
|
t = arrayMap(t, baseUnary(baseIteratee));
|
5686
|
-
var a = baseMap(e, function(o,
|
5652
|
+
var a = baseMap(e, function(o, i, s) {
|
5687
5653
|
var l = arrayMap(t, function(u) {
|
5688
5654
|
return u(o);
|
5689
5655
|
});
|
5690
5656
|
return { criteria: l, index: ++n, value: o };
|
5691
5657
|
});
|
5692
|
-
return baseSortBy(a, function(o,
|
5693
|
-
return compareMultiple(o,
|
5658
|
+
return baseSortBy(a, function(o, i) {
|
5659
|
+
return compareMultiple(o, i, r);
|
5694
5660
|
});
|
5695
5661
|
}
|
5696
5662
|
var nativeCeil = Math.ceil, nativeMax = Math.max;
|
5697
5663
|
function baseRange(e, t, r, n) {
|
5698
|
-
for (var a = -1, o = nativeMax(nativeCeil((t - e) / (r || 1)), 0),
|
5699
|
-
|
5700
|
-
return
|
5664
|
+
for (var a = -1, o = nativeMax(nativeCeil((t - e) / (r || 1)), 0), i = Array(o); o--; )
|
5665
|
+
i[n ? o : ++a] = e, e += r;
|
5666
|
+
return i;
|
5701
5667
|
}
|
5702
5668
|
function createRange(e) {
|
5703
5669
|
return function(t, r, n) {
|
@@ -5723,28 +5689,28 @@ var INFINITY = 1 / 0, createSet = Set$2 && 1 / setToArray(new Set$2([, -0]))[1]
|
|
5723
5689
|
const createSet$1 = createSet;
|
5724
5690
|
var LARGE_ARRAY_SIZE = 200;
|
5725
5691
|
function baseUniq(e, t, r) {
|
5726
|
-
var n = -1, a = arrayIncludes, o = e.length,
|
5692
|
+
var n = -1, a = arrayIncludes, o = e.length, i = !0, s = [], l = s;
|
5727
5693
|
if (r)
|
5728
|
-
|
5694
|
+
i = !1, a = arrayIncludesWith;
|
5729
5695
|
else if (o >= LARGE_ARRAY_SIZE) {
|
5730
5696
|
var u = t ? null : createSet$1(e);
|
5731
5697
|
if (u)
|
5732
5698
|
return setToArray(u);
|
5733
|
-
|
5699
|
+
i = !1, a = cacheHas, l = new SetCache();
|
5734
5700
|
} else
|
5735
|
-
l = t ? [] :
|
5701
|
+
l = t ? [] : s;
|
5736
5702
|
e:
|
5737
5703
|
for (; ++n < o; ) {
|
5738
5704
|
var c = e[n], g = t ? t(c) : c;
|
5739
|
-
if (c = r || c !== 0 ? c : 0,
|
5705
|
+
if (c = r || c !== 0 ? c : 0, i && g === g) {
|
5740
5706
|
for (var p = l.length; p--; )
|
5741
5707
|
if (l[p] === g)
|
5742
5708
|
continue e;
|
5743
|
-
t && l.push(g),
|
5709
|
+
t && l.push(g), s.push(c);
|
5744
5710
|
} else
|
5745
|
-
a(l, g, r) || (l !==
|
5711
|
+
a(l, g, r) || (l !== s && l.push(g), s.push(c));
|
5746
5712
|
}
|
5747
|
-
return
|
5713
|
+
return s;
|
5748
5714
|
}
|
5749
5715
|
function uniq(e) {
|
5750
5716
|
return e && e.length ? baseUniq(e) : [];
|
@@ -6051,22 +6017,22 @@ class Logger {
|
|
6051
6017
|
Logger.log("info", t, r, n);
|
6052
6018
|
}
|
6053
6019
|
static log(t = "info", r, n = {}, a = !0, o = "color:#000;") {
|
6054
|
-
let
|
6020
|
+
let i = r, s = o;
|
6055
6021
|
switch (t) {
|
6056
6022
|
case "debug":
|
6057
|
-
|
6023
|
+
i = `[DEBUG] ${r}`;
|
6058
6024
|
break;
|
6059
6025
|
case "info":
|
6060
|
-
|
6026
|
+
i = `[INFO] ${r}`;
|
6061
6027
|
break;
|
6062
6028
|
case "warn":
|
6063
|
-
|
6029
|
+
i = `[WARN] ${r}`, s = "color:#fa8c16;";
|
6064
6030
|
break;
|
6065
6031
|
case "error":
|
6066
|
-
|
6032
|
+
i = `[ERROR] ${r}`, s = "color:#f00;";
|
6067
6033
|
break;
|
6068
6034
|
}
|
6069
|
-
a ? console.groupCollapsed(`%c[@kengic/vue] ${
|
6035
|
+
a ? console.groupCollapsed(`%c[@kengic/vue] ${i}`, s) : console.group(`%c[@kengic/vue] ${i}`, s), toPairs$1(cloneDeep(n)).forEach((l) => {
|
6070
6036
|
console.log(`%c${l[0]}:`, "color: #000; font-weight: bold;", l[1]);
|
6071
6037
|
}), console.trace(""), console.groupEnd();
|
6072
6038
|
}
|
@@ -6085,15 +6051,15 @@ class KgUtil {
|
|
6085
6051
|
static base64toBlob(t, r, n = 512) {
|
6086
6052
|
let a = t;
|
6087
6053
|
a.startsWith("data:") && (a = t.split("base64,")[1]);
|
6088
|
-
const o = atob(a),
|
6089
|
-
for (let
|
6090
|
-
const l = o.slice(
|
6054
|
+
const o = atob(a), i = [];
|
6055
|
+
for (let s = 0; s < o.length; s += n) {
|
6056
|
+
const l = o.slice(s, s + n), u = new Array(l.length);
|
6091
6057
|
for (let g = 0; g < l.length; g++)
|
6092
6058
|
u[g] = l.charCodeAt(g);
|
6093
6059
|
const c = new Uint8Array(u);
|
6094
|
-
|
6060
|
+
i.push(c);
|
6095
6061
|
}
|
6096
|
-
return new Blob(
|
6062
|
+
return new Blob(i, { type: r });
|
6097
6063
|
}
|
6098
6064
|
static downloadFile(t, r, n) {
|
6099
6065
|
const a = r.split(".")[1];
|
@@ -6113,40 +6079,40 @@ class KgUtil {
|
|
6113
6079
|
Logger.error("\u53C2\u6570 _contentType \u4E3A\u7A7A.");
|
6114
6080
|
return;
|
6115
6081
|
}
|
6116
|
-
let
|
6117
|
-
typeof t == "string" ?
|
6118
|
-
const
|
6119
|
-
l.setAttribute("style", "display:none"), l.setAttribute("href",
|
6082
|
+
let i;
|
6083
|
+
typeof t == "string" ? i = new Blob([this.base64toBlob(t, n)], { type: n }) : i = new Blob([t], { type: n });
|
6084
|
+
const s = URL.createObjectURL(i), l = document.createElement("a");
|
6085
|
+
l.setAttribute("style", "display:none"), l.setAttribute("href", s), l.setAttribute("download", r), document.body.appendChild(l), l.click(), document.body.removeChild(l), URL.revokeObjectURL(s);
|
6120
6086
|
}
|
6121
6087
|
static parseParams(t, r, n) {
|
6122
6088
|
let a = cloneDeep(toRaw(unref(t)));
|
6123
6089
|
return !a || !isObjectLike(a) || Object.keys(a).forEach((o) => {
|
6124
|
-
const
|
6090
|
+
const i = a[o];
|
6125
6091
|
switch (!0) {
|
6126
6092
|
case o.endsWith("_obj"): {
|
6127
6093
|
a[o] = void 0;
|
6128
6094
|
break;
|
6129
6095
|
}
|
6130
|
-
case (!!r && !!n && n.isDayjs(
|
6131
|
-
a[o] = this.parseParamFromDayJS(o,
|
6096
|
+
case (!!r && !!n && n.isDayjs(i)):
|
6097
|
+
a[o] = this.parseParamFromDayJS(o, i, r);
|
6132
6098
|
break;
|
6133
|
-
case (isArray$1(
|
6134
|
-
a[o] = void 0, a[`${o}_begin`] = this.parseParamFromDayJS(o,
|
6099
|
+
case (isArray$1(i) && i.length === 2 && !!r && !!n && n.isDayjs(i[0]) && n.isDayjs(i[1])):
|
6100
|
+
a[o] = void 0, a[`${o}_begin`] = this.parseParamFromDayJS(o, i[0], r), a[`${o}_end`] = this.parseParamFromDayJS(o, i[1], r);
|
6135
6101
|
break;
|
6136
|
-
case isObjectLike(
|
6137
|
-
a[o] = this.parseParams(
|
6102
|
+
case isObjectLike(i):
|
6103
|
+
a[o] = this.parseParams(i);
|
6138
6104
|
break;
|
6139
|
-
case typeof
|
6140
|
-
a[o] = this.parseParamFromString(
|
6105
|
+
case typeof i == "string":
|
6106
|
+
a[o] = this.parseParamFromString(i);
|
6141
6107
|
break;
|
6142
6108
|
default:
|
6143
|
-
a[o] =
|
6109
|
+
a[o] = i;
|
6144
6110
|
break;
|
6145
6111
|
}
|
6146
6112
|
}), a;
|
6147
6113
|
}
|
6148
6114
|
static parseParamFromString(t) {
|
6149
|
-
var a, o,
|
6115
|
+
var a, o, i, s, l;
|
6150
6116
|
const r = useKg(), n = /(.*)?({(.*)?})(.*)?/.exec(t);
|
6151
6117
|
if (n) {
|
6152
6118
|
const u = n[2], c = n[2].slice(1, -1);
|
@@ -6155,7 +6121,7 @@ class KgUtil {
|
|
6155
6121
|
return t.replace("{WAREHOUSE}", (o = (a = useKgWarehouse().warehouse.value) == null ? void 0 : a.whId) != null ? o : "");
|
6156
6122
|
default:
|
6157
6123
|
if (c.endsWith(":query"))
|
6158
|
-
return (l = (
|
6124
|
+
return (l = (s = (i = r.router.value) == null ? void 0 : i.currentRoute) == null ? void 0 : s.query[c.slice(0, -6)]) != null ? l : "";
|
6159
6125
|
break;
|
6160
6126
|
}
|
6161
6127
|
return t;
|
@@ -6200,14 +6166,14 @@ class KgUtil {
|
|
6200
6166
|
...t
|
6201
6167
|
});
|
6202
6168
|
return n.showLoading = () => {
|
6203
|
-
n.update((
|
6204
|
-
const
|
6205
|
-
return
|
6169
|
+
n.update((i) => {
|
6170
|
+
const s = cloneDeep(i);
|
6171
|
+
return s.okButtonProps.loading = !0, s.cancelButtonProps.disabled = !0, s;
|
6206
6172
|
});
|
6207
6173
|
}, n.hideLoading = () => {
|
6208
|
-
n.update((
|
6209
|
-
const
|
6210
|
-
return
|
6174
|
+
n.update((i) => {
|
6175
|
+
const s = cloneDeep(i);
|
6176
|
+
return s.okButtonProps.loading = !1, s.cancelButtonProps.disabled = !1, s;
|
6211
6177
|
});
|
6212
6178
|
}, n;
|
6213
6179
|
}
|
@@ -6304,7 +6270,7 @@ class KgRouteUtil {
|
|
6304
6270
|
throw new Error(`\u5730\u5740\u65E0\u6CD5\u5339\u914D\u6A21\u5757. \u5730\u5740: ${t}`);
|
6305
6271
|
}
|
6306
6272
|
static getAppIndexPath(t) {
|
6307
|
-
var a, o,
|
6273
|
+
var a, o, i, s, l, u, c, g;
|
6308
6274
|
const r = useKg();
|
6309
6275
|
let n = "";
|
6310
6276
|
switch (t) {
|
@@ -6312,7 +6278,7 @@ class KgRouteUtil {
|
|
6312
6278
|
n = ((o = (a = r.option.value) == null ? void 0 : a.appIndex) == null ? void 0 : o[KG_APP.WMS_DATA_MANAGER]) || `${KG_APP_PREFIX.WMS_DATA_MANAGER}/index`;
|
6313
6279
|
break;
|
6314
6280
|
case KG_APP.WMS_BUSINESS_MANAGER:
|
6315
|
-
n = ((
|
6281
|
+
n = ((s = (i = r.option.value) == null ? void 0 : i.appIndex) == null ? void 0 : s[KG_APP.WMS_BUSINESS_MANAGER]) || `${KG_APP_PREFIX.WMS_BUSINESS_MANAGER}/index`;
|
6316
6282
|
break;
|
6317
6283
|
case KG_APP.WCS:
|
6318
6284
|
n = ((u = (l = r.option.value) == null ? void 0 : l.appIndex) == null ? void 0 : u[KG_APP.WCS]) || `${KG_APP_PREFIX.WCS}/index`;
|
@@ -6340,10 +6306,10 @@ class KgVarUtil {
|
|
6340
6306
|
return r;
|
6341
6307
|
}
|
6342
6308
|
static transformValueByControlType(t, r, n, a) {
|
6343
|
-
const o = useKgVar(t),
|
6344
|
-
if (!
|
6309
|
+
const o = useKgVar(t), i = o.store.getVariableConfig(t, r);
|
6310
|
+
if (!i)
|
6345
6311
|
return a;
|
6346
|
-
switch (
|
6312
|
+
switch (i.ctrl_typ) {
|
6347
6313
|
case KG_FORM_ITEM_TYPE.INPUT:
|
6348
6314
|
case KG_FORM_ITEM_TYPE.INPUT_PASSWORD:
|
6349
6315
|
case KG_FORM_ITEM_TYPE.INPUT_AREA:
|
@@ -6351,8 +6317,8 @@ class KgVarUtil {
|
|
6351
6317
|
case KG_FORM_ITEM_TYPE.INPUT_NUMBER: {
|
6352
6318
|
if (isNil(a))
|
6353
6319
|
return;
|
6354
|
-
const
|
6355
|
-
if (Number.isNaN(
|
6320
|
+
const s = Number(a);
|
6321
|
+
if (Number.isNaN(s)) {
|
6356
6322
|
Logger.error("| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | INPUT_NUMBER \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.", {
|
6357
6323
|
frm_id: t,
|
6358
6324
|
var_nam: r,
|
@@ -6360,30 +6326,30 @@ class KgVarUtil {
|
|
6360
6326
|
});
|
6361
6327
|
return;
|
6362
6328
|
}
|
6363
|
-
return
|
6329
|
+
return s;
|
6364
6330
|
}
|
6365
6331
|
case KG_FORM_ITEM_TYPE.CHECKBOX:
|
6366
6332
|
case KG_FORM_ITEM_TYPE.SWITCH: {
|
6367
6333
|
if (isNil(a))
|
6368
6334
|
return 0;
|
6369
|
-
const
|
6370
|
-
if (Number.isNaN(
|
6371
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6335
|
+
const s = Number(a);
|
6336
|
+
if (Number.isNaN(s)) {
|
6337
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.`, {
|
6372
6338
|
frm_id: t,
|
6373
6339
|
var_nam: r,
|
6374
6340
|
value: a
|
6375
6341
|
});
|
6376
6342
|
return;
|
6377
6343
|
}
|
6378
|
-
if (![0, 1].includes(
|
6379
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6344
|
+
if (![0, 1].includes(s)) {
|
6345
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A 0 \u6216 1.`, {
|
6380
6346
|
frm_id: t,
|
6381
6347
|
var_nam: r,
|
6382
6348
|
value: a
|
6383
6349
|
});
|
6384
6350
|
return;
|
6385
6351
|
}
|
6386
|
-
return
|
6352
|
+
return s;
|
6387
6353
|
}
|
6388
6354
|
case KG_FORM_ITEM_TYPE.DATE_DATE:
|
6389
6355
|
case KG_FORM_ITEM_TYPE.DATE_DATETIME:
|
@@ -6392,10 +6358,10 @@ class KgVarUtil {
|
|
6392
6358
|
case KG_FORM_ITEM_TYPE.DATE_YEAR: {
|
6393
6359
|
if (isNil(a))
|
6394
6360
|
return;
|
6395
|
-
const
|
6396
|
-
if (
|
6397
|
-
return
|
6398
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6361
|
+
const s = n(a);
|
6362
|
+
if (s != null && s.isValid())
|
6363
|
+
return s;
|
6364
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u65E5\u671F\u7C7B\u578B.`, {
|
6399
6365
|
frm_id: t,
|
6400
6366
|
var_nam: r,
|
6401
6367
|
value: a
|
@@ -6406,9 +6372,9 @@ class KgVarUtil {
|
|
6406
6372
|
if (isNil(a))
|
6407
6373
|
return [];
|
6408
6374
|
try {
|
6409
|
-
const
|
6410
|
-
if (!isArray$1(
|
6411
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6375
|
+
const s = JSON.parse(a);
|
6376
|
+
if (!isArray$1(s)) {
|
6377
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u7EC4\u7C7B\u578B.`, {
|
6412
6378
|
frm_id: t,
|
6413
6379
|
var_nam: r,
|
6414
6380
|
value: a
|
@@ -6418,9 +6384,9 @@ class KgVarUtil {
|
|
6418
6384
|
const l = o.store.getVarPossibility(t, r);
|
6419
6385
|
switch (l == null ? void 0 : l.val_data_type) {
|
6420
6386
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER: {
|
6421
|
-
const u =
|
6387
|
+
const u = s.map((c) => Number(c));
|
6422
6388
|
if (u.some((c) => Number.isNaN(u))) {
|
6423
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6389
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A number \u6570\u7EC4\u7C7B\u578B.`, {
|
6424
6390
|
frm_id: t,
|
6425
6391
|
var_nam: r,
|
6426
6392
|
value: a,
|
@@ -6431,13 +6397,13 @@ class KgVarUtil {
|
|
6431
6397
|
return u;
|
6432
6398
|
}
|
6433
6399
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
6434
|
-
return
|
6400
|
+
return s.map((u) => Boolean(u));
|
6435
6401
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
6436
6402
|
default:
|
6437
|
-
return
|
6403
|
+
return s.map((u) => String(u));
|
6438
6404
|
}
|
6439
6405
|
} catch {
|
6440
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6406
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u7EC4\u7C7B\u578B.`, {
|
6441
6407
|
frm_id: t,
|
6442
6408
|
var_nam: r,
|
6443
6409
|
value: a
|
@@ -6448,16 +6414,16 @@ class KgVarUtil {
|
|
6448
6414
|
case KG_FORM_ITEM_TYPE.SELECT: {
|
6449
6415
|
if (isNil(a))
|
6450
6416
|
return;
|
6451
|
-
const
|
6452
|
-
switch (
|
6417
|
+
const s = o.store.getVarPossibility(t, r);
|
6418
|
+
switch (s == null ? void 0 : s.val_data_type) {
|
6453
6419
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER: {
|
6454
6420
|
const l = Number(a);
|
6455
6421
|
if (Number.isNaN(l)) {
|
6456
|
-
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${
|
6422
|
+
Logger.error(`| \u63A7\u4EF6\u7684\u503C\u975E\u6CD5 | ${i.ctrl_typ} \u63A7\u4EF6\u7684\u503C\u5FC5\u987B\u4E3A\u6570\u5B57\u7C7B\u578B.`, {
|
6457
6423
|
frm_id: t,
|
6458
6424
|
var_nam: r,
|
6459
6425
|
value: a,
|
6460
|
-
VarPossibility:
|
6426
|
+
VarPossibility: s
|
6461
6427
|
});
|
6462
6428
|
return;
|
6463
6429
|
}
|
@@ -6544,15 +6510,15 @@ function isComputed(e) {
|
|
6544
6510
|
return !!(isRef(e) && e.effect);
|
6545
6511
|
}
|
6546
6512
|
function createOptionsStore(e, t, r, n) {
|
6547
|
-
const { state: a, actions: o, getters:
|
6513
|
+
const { state: a, actions: o, getters: i } = t, s = r.state.value[e];
|
6548
6514
|
let l;
|
6549
6515
|
function u() {
|
6550
|
-
!
|
6516
|
+
!s && (process.env.NODE_ENV === "production" || !n) && (r.state.value[e] = a ? a() : {});
|
6551
6517
|
const c = process.env.NODE_ENV !== "production" && n ? toRefs(ref(a ? a() : {}).value) : toRefs(r.state.value[e]);
|
6552
|
-
return assign$1(c, o, Object.keys(
|
6518
|
+
return assign$1(c, o, Object.keys(i || {}).reduce((g, p) => (g[p] = markRaw(computed(() => {
|
6553
6519
|
setActivePinia(r);
|
6554
6520
|
const b = r._s.get(e);
|
6555
|
-
return
|
6521
|
+
return i[p].call(b, b);
|
6556
6522
|
})), g), {}));
|
6557
6523
|
}
|
6558
6524
|
return l = createSetupStore(e, u, t, r, n), l.$reset = function() {
|
@@ -6564,7 +6530,7 @@ function createOptionsStore(e, t, r, n) {
|
|
6564
6530
|
}
|
6565
6531
|
function createSetupStore(e, t, r = {}, n, a) {
|
6566
6532
|
let o;
|
6567
|
-
const
|
6533
|
+
const i = r.state, s = assign$1({ actions: {} }, r);
|
6568
6534
|
if (process.env.NODE_ENV !== "production" && !n._e.active)
|
6569
6535
|
throw new Error("Pinia destroyed");
|
6570
6536
|
const l = {
|
@@ -6575,7 +6541,7 @@ function createSetupStore(e, t, r = {}, n, a) {
|
|
6575
6541
|
});
|
6576
6542
|
let u, c, g = markRaw([]), p = markRaw([]), b;
|
6577
6543
|
const m = n.state.value[e];
|
6578
|
-
!
|
6544
|
+
!i && !m && (process.env.NODE_ENV === "production" || !a) && (n.state.value[e] = {});
|
6579
6545
|
const v = ref({});
|
6580
6546
|
function _(M) {
|
6581
6547
|
let A;
|
@@ -6658,12 +6624,12 @@ function createSetupStore(e, t, r = {}, n, a) {
|
|
6658
6624
|
for (const M in w) {
|
6659
6625
|
const A = w[M];
|
6660
6626
|
if (isRef(A) && !isComputed(A) || isReactive(A))
|
6661
|
-
process.env.NODE_ENV !== "production" && a ? set(v.value, M, toRef(w, M)) :
|
6627
|
+
process.env.NODE_ENV !== "production" && a ? set(v.value, M, toRef(w, M)) : i || (m && shouldHydrate(A) && (isRef(A) ? A.value = m[M] : mergeReactiveObjects(A, m[M])), n.state.value[e][M] = A), process.env.NODE_ENV !== "production" && T.state.push(M);
|
6662
6628
|
else if (typeof A == "function") {
|
6663
6629
|
const O = process.env.NODE_ENV !== "production" && a ? A : E(M, A);
|
6664
|
-
w[M] = O, process.env.NODE_ENV !== "production" && (T.actions[M] = A),
|
6630
|
+
w[M] = O, process.env.NODE_ENV !== "production" && (T.actions[M] = A), s.actions[M] = A;
|
6665
6631
|
} else
|
6666
|
-
process.env.NODE_ENV !== "production" && isComputed(A) && (T.getters[M] =
|
6632
|
+
process.env.NODE_ENV !== "production" && isComputed(A) && (T.getters[M] = i ? r.getters[M] : A, IS_CLIENT && (w._getters || (w._getters = markRaw([]))).push(M));
|
6667
6633
|
}
|
6668
6634
|
if (assign$1(k, w), assign$1(toRaw(k), w), Object.defineProperty(k, "$state", {
|
6669
6635
|
get: () => process.env.NODE_ENV !== "production" && a ? v.value : n.state.value[e],
|
@@ -6692,7 +6658,7 @@ function createSetupStore(e, t, r = {}, n, a) {
|
|
6692
6658
|
set(k, O, E(O, B));
|
6693
6659
|
}
|
6694
6660
|
for (const O in A._hmrPayload.getters) {
|
6695
|
-
const B = A._hmrPayload.getters[O], $ =
|
6661
|
+
const B = A._hmrPayload.getters[O], $ = i ? computed(() => (setActivePinia(n), B.call(k, k))) : B;
|
6696
6662
|
set(k, O, $);
|
6697
6663
|
}
|
6698
6664
|
Object.keys(k._hmrPayload.getters).forEach((O) => {
|
@@ -6719,7 +6685,7 @@ function createSetupStore(e, t, r = {}, n, a) {
|
|
6719
6685
|
store: k,
|
6720
6686
|
app: n._a,
|
6721
6687
|
pinia: n,
|
6722
|
-
options:
|
6688
|
+
options: s
|
6723
6689
|
}));
|
6724
6690
|
Object.keys(A || {}).forEach((O) => k._customProperties.add(O)), assign$1(k, A);
|
6725
6691
|
} else
|
@@ -6727,28 +6693,28 @@ function createSetupStore(e, t, r = {}, n, a) {
|
|
6727
6693
|
store: k,
|
6728
6694
|
app: n._a,
|
6729
6695
|
pinia: n,
|
6730
|
-
options:
|
6696
|
+
options: s
|
6731
6697
|
})));
|
6732
6698
|
}), process.env.NODE_ENV !== "production" && k.$state && typeof k.$state == "object" && typeof k.$state.constructor == "function" && !k.$state.constructor.toString().includes("[native code]") && console.warn(`[\u{1F34D}]: The "state" must be a plain object. It cannot be
|
6733
6699
|
state: () => new MyClass()
|
6734
|
-
Found in store "${k.$id}".`), m &&
|
6700
|
+
Found in store "${k.$id}".`), m && i && r.hydrate && r.hydrate(k.$state, m), u = !0, c = !0, k;
|
6735
6701
|
}
|
6736
6702
|
function defineStore(e, t, r) {
|
6737
6703
|
let n, a;
|
6738
6704
|
const o = typeof t == "function";
|
6739
6705
|
typeof e == "string" ? (n = e, a = o ? r : t) : (a = e, n = e.id);
|
6740
|
-
function s
|
6706
|
+
function i(s, l) {
|
6741
6707
|
const u = getCurrentInstance();
|
6742
|
-
if (
|
6708
|
+
if (s = (process.env.NODE_ENV === "test" && activePinia && activePinia._testing ? null : s) || u && inject(piniaSymbol), s && setActivePinia(s), process.env.NODE_ENV !== "production" && !activePinia)
|
6743
6709
|
throw new Error(`[\u{1F34D}]: getActivePinia was called with no active Pinia. Did you forget to install pinia?
|
6744
6710
|
const pinia = createPinia()
|
6745
6711
|
app.use(pinia)
|
6746
6712
|
This will fail in production.`);
|
6747
|
-
|
6748
|
-
const c =
|
6713
|
+
s = activePinia, s._s.has(n) || (o ? createSetupStore(n, t, a, s) : createOptionsStore(n, a, s), process.env.NODE_ENV !== "production" && (i._pinia = s));
|
6714
|
+
const c = s._s.get(n);
|
6749
6715
|
if (process.env.NODE_ENV !== "production" && l) {
|
6750
|
-
const g = "__hot:" + n, p = o ? createSetupStore(g, t, a,
|
6751
|
-
l._hotUpdate(p), delete
|
6716
|
+
const g = "__hot:" + n, p = o ? createSetupStore(g, t, a, s, !0) : createOptionsStore(g, assign$1({}, a), s, !0);
|
6717
|
+
l._hotUpdate(p), delete s.state.value[g], s._s.delete(g);
|
6752
6718
|
}
|
6753
6719
|
if (process.env.NODE_ENV !== "production" && IS_CLIENT && u && u.proxy && !l) {
|
6754
6720
|
const g = u.proxy, p = "_pStores" in g ? g._pStores : g._pStores = {};
|
@@ -6756,7 +6722,7 @@ This will fail in production.`);
|
|
6756
6722
|
}
|
6757
6723
|
return c;
|
6758
6724
|
}
|
6759
|
-
return
|
6725
|
+
return i.$id = n, i;
|
6760
6726
|
}
|
6761
6727
|
let store$8 = null;
|
6762
6728
|
const useKgStore = (e) => (store$8 || (store$8 = defineStore("Kg", {
|
@@ -6813,14 +6779,14 @@ const useKgStore = (e) => (store$8 || (store$8 = defineStore("Kg", {
|
|
6813
6779
|
}
|
6814
6780
|
}).bind(null, e != null ? e : pinia())), store$8);
|
6815
6781
|
function useKg(e) {
|
6816
|
-
const t = useKgStore(e)(), r = computed(() => unref(t.getLocale || "zh_CN")), n = computed(() => t.getRouter), a = computed(() => t.getOption), o = t.t,
|
6782
|
+
const t = useKgStore(e)(), r = computed(() => unref(t.getLocale || "zh_CN")), n = computed(() => t.getRouter), a = computed(() => t.getOption), o = t.t, i = t.p;
|
6817
6783
|
return {
|
6818
6784
|
store: t,
|
6819
6785
|
locale: r,
|
6820
6786
|
router: n,
|
6821
6787
|
option: a,
|
6822
6788
|
t: o,
|
6823
|
-
p:
|
6789
|
+
p: i
|
6824
6790
|
};
|
6825
6791
|
}
|
6826
6792
|
Spin.setDefaultIndicator({
|
@@ -7054,15 +7020,15 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7054
7020
|
attrs: n
|
7055
7021
|
}) {
|
7056
7022
|
const a = ref(!1), o = ref(null);
|
7057
|
-
function
|
7023
|
+
function i(u) {
|
7058
7024
|
u.preventDefault(), u.stopPropagation(), a.value = !a.value;
|
7059
7025
|
const c = get(o.value, "$el.parentElement.parentElement.parentElement.parentElement.parentElement");
|
7060
7026
|
c && c.classList.toggle("kg-modal--fullscreen");
|
7061
7027
|
}
|
7062
|
-
function
|
7028
|
+
function s() {
|
7063
7029
|
return e.kgShowFullscreenButton ? createVNode(Button, {
|
7064
7030
|
ref: o,
|
7065
|
-
onClick:
|
7031
|
+
onClick: i,
|
7066
7032
|
class: "kg-modal-btn-fullscreen"
|
7067
7033
|
}, {
|
7068
7034
|
default: () => [a.value ? createVNode(FullscreenExitOutlined$1, null, null) : createVNode(FullscreenOutlined$1, null, null)]
|
@@ -7071,7 +7037,7 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7071
7037
|
function l() {
|
7072
7038
|
return e.kgShowCloseButton ? createVNode(CloseOutlined$1, null, null) : null;
|
7073
7039
|
}
|
7074
|
-
return () => createVNode(Fragment, null, [
|
7040
|
+
return () => createVNode(Fragment, null, [s(), l()]);
|
7075
7041
|
}
|
7076
7042
|
}), formProps = () => ({
|
7077
7043
|
layout: String,
|
@@ -7154,11 +7120,11 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7154
7120
|
attrs: n
|
7155
7121
|
}) {
|
7156
7122
|
const a = computed((o) => {
|
7157
|
-
const
|
7123
|
+
const i = {
|
7158
7124
|
...unref(n),
|
7159
7125
|
...e
|
7160
7126
|
};
|
7161
|
-
return
|
7127
|
+
return i.wrapClassName = i.wrapClassName ? `${i.wrapClassName} kg-modal` : "kg-modal", e.kgFullHeight && (i.wrapClassName += " kg-modal--full-height"), e.footer === null && (i.wrapClassName += " kg-modal--no-footer"), i.closable = !0, i.width = i.width !== void 0 ? i.width : "80%", i.centered = i.centered !== void 0 ? i.centered : !0, i.destroyOnClose = i.destroyOnClose !== void 0 ? i.destroyOnClose : !0, i.keyboard = i.keyboard !== void 0 ? i.keyboard : !1, i.maskClosable = i.maskClosable !== void 0 ? i.maskClosable : !1, i.cancelButtonProps = i.cancelButtonProps !== void 0 ? i.cancelButtonProps : {}, e.kgShowCancelButton || (i.cancelButtonProps.class = "kg-invisible"), i.okButtonProps = i.okButtonProps !== void 0 ? i.okButtonProps : {}, e.kgShowOkButton || (i.okButtonProps.class = "kg-invisible"), i;
|
7162
7128
|
});
|
7163
7129
|
return () => createVNode(Modal, a.value, {
|
7164
7130
|
...renderSlots(t, ["closeIcon"]),
|
@@ -7263,7 +7229,7 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7263
7229
|
kgMinWidth: e.kgMinWidth
|
7264
7230
|
}), new Error(C);
|
7265
7231
|
}
|
7266
|
-
let n = 0, a = 0, o = 0,
|
7232
|
+
let n = 0, a = 0, o = 0, i = 0, s = {
|
7267
7233
|
remove: () => {
|
7268
7234
|
}
|
7269
7235
|
}, l = {
|
@@ -7302,7 +7268,7 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7302
7268
|
return C;
|
7303
7269
|
});
|
7304
7270
|
function g() {
|
7305
|
-
|
7271
|
+
s.remove(), l.remove();
|
7306
7272
|
}
|
7307
7273
|
onUnmounted(() => {
|
7308
7274
|
g();
|
@@ -7310,10 +7276,10 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7310
7276
|
const p = (C) => {
|
7311
7277
|
switch (e.kgType) {
|
7312
7278
|
case "top":
|
7313
|
-
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, a - (C.pageY -
|
7279
|
+
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, a - (C.pageY - i))));
|
7314
7280
|
break;
|
7315
7281
|
case "bottom":
|
7316
|
-
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, a + (C.pageY -
|
7282
|
+
t("update:kgHeight", Math.min(e.kgMaxHeight, Math.max(e.kgMinHeight, a + (C.pageY - i))));
|
7317
7283
|
break;
|
7318
7284
|
case "left":
|
7319
7285
|
t("update:kgWidth", Math.min(e.kgMaxWidth, Math.max(e.kgMinWidth, n - (C.pageX - o))));
|
@@ -7330,7 +7296,7 @@ const KgModal_Close = "", getProps$y = () => ({
|
|
7330
7296
|
p(C), g();
|
7331
7297
|
}
|
7332
7298
|
function v(C) {
|
7333
|
-
C.stopPropagation(), C.preventDefault(), g(), !(C instanceof MouseEvent && C.which !== 1) && (o = C.pageX,
|
7299
|
+
C.stopPropagation(), C.preventDefault(), g(), !(C instanceof MouseEvent && C.which !== 1) && (o = C.pageX, i = C.pageY, n = e.kgWidth, a = e.kgHeight, s = _(document.documentElement, "mousemove", b), l = _(document.documentElement, "mouseup", m));
|
7334
7300
|
}
|
7335
7301
|
function _(C, E, T) {
|
7336
7302
|
return C.addEventListener(E, T), {
|
@@ -7372,8 +7338,8 @@ var assign = make_assign(), create$1 = make_create(), trim$1 = make_trim(), Glob
|
|
7372
7338
|
function make_assign() {
|
7373
7339
|
return Object.assign ? Object.assign : function(t, r, n, a) {
|
7374
7340
|
for (var o = 1; o < arguments.length; o++)
|
7375
|
-
each$7(Object(arguments[o]), function(
|
7376
|
-
t[
|
7341
|
+
each$7(Object(arguments[o]), function(i, s) {
|
7342
|
+
t[s] = i;
|
7377
7343
|
});
|
7378
7344
|
return t;
|
7379
7345
|
};
|
@@ -7388,8 +7354,8 @@ function make_create() {
|
|
7388
7354
|
let e = function() {
|
7389
7355
|
};
|
7390
7356
|
return function(r, n, a, o) {
|
7391
|
-
var
|
7392
|
-
return e.prototype = r, assign.apply(this, [new e()].concat(
|
7357
|
+
var i = slice$1(arguments, 1);
|
7358
|
+
return e.prototype = r, assign.apply(this, [new e()].concat(i));
|
7393
7359
|
};
|
7394
7360
|
}
|
7395
7361
|
}
|
@@ -7487,7 +7453,7 @@ function createStore(e, t, r) {
|
|
7487
7453
|
var n = r ? "__storejs_" + r + "_" : "", a = r ? new RegExp("^" + n) : null, o = /^[a-zA-Z0-9_\-]*$/;
|
7488
7454
|
if (!o.test(r))
|
7489
7455
|
throw new Error("store.js namespaces can only have alphanumerics + underscores and dashes");
|
7490
|
-
var
|
7456
|
+
var i = {
|
7491
7457
|
_namespacePrefix: n,
|
7492
7458
|
_namespaceRegexp: a,
|
7493
7459
|
_testStorage: function(l) {
|
@@ -7558,16 +7524,16 @@ function createStore(e, t, r) {
|
|
7558
7524
|
addStorage: function(l) {
|
7559
7525
|
_warn("store.addStorage(storage) is deprecated. Use createStore([storages])"), this._addStorage(l);
|
7560
7526
|
}
|
7561
|
-
},
|
7527
|
+
}, s = create(i, storeAPI, {
|
7562
7528
|
plugins: []
|
7563
7529
|
});
|
7564
|
-
return
|
7565
|
-
isFunction(l) && (
|
7530
|
+
return s.raw = {}, each$6(s, function(l, u) {
|
7531
|
+
isFunction(l) && (s.raw[u] = bind(s, l));
|
7566
7532
|
}), each$6(e, function(l) {
|
7567
|
-
|
7533
|
+
s._addStorage(l);
|
7568
7534
|
}), each$6(t, function(l) {
|
7569
|
-
|
7570
|
-
}),
|
7535
|
+
s._addPlugin(l);
|
7536
|
+
}), s;
|
7571
7537
|
}
|
7572
7538
|
var util$4 = util$6, Global$4 = util$4.Global, localStorage_1 = {
|
7573
7539
|
name: "localStorage",
|
@@ -7807,7 +7773,7 @@ function requireJson2() {
|
|
7807
7773
|
}) + '"' : '"' + e + '"';
|
7808
7774
|
}
|
7809
7775
|
function str(e, t) {
|
7810
|
-
var r, n, a, o,
|
7776
|
+
var r, n, a, o, i = gap, s, l = t[e];
|
7811
7777
|
switch (l && typeof l == "object" && typeof l.toJSON == "function" && (l = l.toJSON(e)), typeof rep == "function" && (l = rep.call(t, e, l)), typeof l) {
|
7812
7778
|
case "string":
|
7813
7779
|
return quote(l);
|
@@ -7819,24 +7785,24 @@ function requireJson2() {
|
|
7819
7785
|
case "object":
|
7820
7786
|
if (!l)
|
7821
7787
|
return "null";
|
7822
|
-
if (gap += indent,
|
7788
|
+
if (gap += indent, s = [], Object.prototype.toString.apply(l) === "[object Array]") {
|
7823
7789
|
for (o = l.length, r = 0; r < o; r += 1)
|
7824
|
-
|
7825
|
-
return a =
|
7826
|
-
` + gap +
|
7790
|
+
s[r] = str(r, l) || "null";
|
7791
|
+
return a = s.length === 0 ? "[]" : gap ? `[
|
7792
|
+
` + gap + s.join(`,
|
7827
7793
|
` + gap) + `
|
7828
|
-
` +
|
7794
|
+
` + i + "]" : "[" + s.join(",") + "]", gap = i, a;
|
7829
7795
|
}
|
7830
7796
|
if (rep && typeof rep == "object")
|
7831
7797
|
for (o = rep.length, r = 0; r < o; r += 1)
|
7832
|
-
typeof rep[r] == "string" && (n = rep[r], a = str(n, l), a &&
|
7798
|
+
typeof rep[r] == "string" && (n = rep[r], a = str(n, l), a && s.push(quote(n) + (gap ? ": " : ":") + a));
|
7833
7799
|
else
|
7834
7800
|
for (n in l)
|
7835
|
-
Object.prototype.hasOwnProperty.call(l, n) && (a = str(n, l), a &&
|
7836
|
-
return a =
|
7837
|
-
` + gap +
|
7801
|
+
Object.prototype.hasOwnProperty.call(l, n) && (a = str(n, l), a && s.push(quote(n) + (gap ? ": " : ":") + a));
|
7802
|
+
return a = s.length === 0 ? "{}" : gap ? `{
|
7803
|
+
` + gap + s.join(`,
|
7838
7804
|
` + gap) + `
|
7839
|
-
` +
|
7805
|
+
` + i + "}" : "{" + s.join(",") + "}", gap = i, a;
|
7840
7806
|
}
|
7841
7807
|
}
|
7842
7808
|
typeof JSON.stringify != "function" && (meta = {
|
@@ -7935,20 +7901,20 @@ function transformVarSubmitConfig(e) {
|
|
7935
7901
|
`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.dft_width \u8D85\u51FA\u8303\u56F4 [${e.min_width}, ${e.max_width}], \u6539\u4E3A\u4F7F\u7528\u6700\u5C0F\u5BBD\u5EA6 ${e.min_width}.`,
|
7936
7902
|
{ VarSubmitConfig: e }
|
7937
7903
|
)), isNil(e.layout) ? e.layout = DEFAULT_LAYOUT : ["vertical", "horizontal", "inline"].includes(e.layout) || (e.layout = DEFAULT_LAYOUT, Logger.error(`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.layout \u975E\u6CD5, \u6539\u4E3A\u4F7F\u7528\u9ED8\u8BA4\u503C ${DEFAULT_LAYOUT}.`, { VarSubmitConfig: e })), isNil(e.label_col_unit) ? e.label_col_unit = KG_WIDTH_UNIT.SPAN : [KG_WIDTH_UNIT.SPAN, KG_WIDTH_UNIT.PX].includes(e.label_col_unit) || (e.label_col_unit = KG_WIDTH_UNIT.SPAN, Logger.error(`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.label_col_unit \u975E\u6CD5, \u6539\u4E3A\u4F7F\u7528\u9ED8\u8BA4\u503C ${KG_WIDTH_UNIT.SPAN}.`, { VarSubmitConfig: e })), e.layout === "horizontal") {
|
7938
|
-
const
|
7904
|
+
const s = Number(e.label_col);
|
7939
7905
|
switch (e.label_col_unit) {
|
7940
7906
|
case KG_WIDTH_UNIT.SPAN:
|
7941
7907
|
switch (!0) {
|
7942
7908
|
case isNil(e.label_col):
|
7943
7909
|
e.label_col = DEFAULT_LABEL_COL_FOR_SPAN;
|
7944
7910
|
break;
|
7945
|
-
case (Number.isNaN(
|
7911
|
+
case (Number.isNaN(s) || s > 24 || s < 1):
|
7946
7912
|
e.label_col = DEFAULT_LABEL_COL_FOR_SPAN, Logger.error(`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.label_col \u975E\u6CD5, \u6539\u4E3A\u4F7F\u7528\u9ED8\u8BA4\u503C ${DEFAULT_LABEL_COL_FOR_SPAN}.`, {
|
7947
7913
|
VarSubmitConfig: e
|
7948
7914
|
});
|
7949
7915
|
break;
|
7950
7916
|
default:
|
7951
|
-
e.label_col = Math.floor(
|
7917
|
+
e.label_col = Math.floor(s);
|
7952
7918
|
}
|
7953
7919
|
break;
|
7954
7920
|
case KG_WIDTH_UNIT.PX:
|
@@ -7956,7 +7922,7 @@ function transformVarSubmitConfig(e) {
|
|
7956
7922
|
case isNil(e.label_col):
|
7957
7923
|
e.label_col = DEFAULT_LABEL_COL_FOR_PX;
|
7958
7924
|
break;
|
7959
|
-
case (Number.isNaN(
|
7925
|
+
case (Number.isNaN(s) || s <= 0):
|
7960
7926
|
e.label_col = DEFAULT_LABEL_COL_FOR_PX, Logger.error(`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.label_col \u975E\u6CD5, \u6539\u4E3A\u4F7F\u7528\u9ED8\u8BA4\u503C ${DEFAULT_LABEL_COL_FOR_PX}.`, {
|
7961
7927
|
VarSubmitConfig: e
|
7962
7928
|
});
|
@@ -7965,8 +7931,8 @@ function transformVarSubmitConfig(e) {
|
|
7965
7931
|
break;
|
7966
7932
|
}
|
7967
7933
|
}
|
7968
|
-
const a = KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER, o = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL,
|
7969
|
-
return isNil(e.display_type) ? e.display_type = a : [a, o,
|
7934
|
+
const a = KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER, o = KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL, i = KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE;
|
7935
|
+
return isNil(e.display_type) ? e.display_type = a : [a, o, i].includes(e.display_type) || (e.display_type = a, Logger.error(`| \u6570\u636E\u6709\u8BEF | VarSubmitConfig.display_type \u975E\u6CD5, \u5408\u6CD5\u7684\u503C\u4E3A ${[a, o, i]}, \u6539\u4E3A\u4F7F\u7528\u9ED8\u8BA4\u503C ${a}.`, {
|
7970
7936
|
VarSubmitConfig: e
|
7971
7937
|
})), e;
|
7972
7938
|
}
|
@@ -8273,13 +8239,13 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8273
8239
|
},
|
8274
8240
|
getVarButtonSearch(e) {
|
8275
8241
|
return (t) => {
|
8276
|
-
var a, o,
|
8242
|
+
var a, o, i;
|
8277
8243
|
if (!t)
|
8278
8244
|
return Logger.error("formID \u4E3A\u7A7A."), null;
|
8279
|
-
let r = e.varButtonMap.get(t), n = (a = r == null ? void 0 : r.find((
|
8245
|
+
let r = e.varButtonMap.get(t), n = (a = r == null ? void 0 : r.find((s) => s.typ === KG_BUTTON_TYPE.SEARCH)) != null ? a : null;
|
8280
8246
|
if (!n) {
|
8281
8247
|
const l = (o = useKgVar(t).store.getVarGridConfig(t)) == null ? void 0 : o.prf_frm_id;
|
8282
|
-
r = e.varButtonMap.get(l || t), n = (
|
8248
|
+
r = e.varButtonMap.get(l || t), n = (i = r == null ? void 0 : r.find((u) => u.typ === KG_BUTTON_TYPE.SEARCH)) != null ? i : null;
|
8283
8249
|
}
|
8284
8250
|
return n;
|
8285
8251
|
};
|
@@ -8341,7 +8307,7 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8341
8307
|
if (!t)
|
8342
8308
|
return Logger.error("formID \u4E3A\u7A7A."), null;
|
8343
8309
|
const r = e.varProfileMap.get(t);
|
8344
|
-
return (o = (a = (n = r == null ? void 0 : r.varProfile) == null ? void 0 : n.varProfileMasters) == null ? void 0 : a.find((
|
8310
|
+
return (o = (a = (n = r == null ? void 0 : r.varProfile) == null ? void 0 : n.varProfileMasters) == null ? void 0 : a.find((i) => i.id === (r == null ? void 0 : r.currentVarProfileMasterID))) != null ? o : null;
|
8345
8311
|
};
|
8346
8312
|
},
|
8347
8313
|
getCurrentVarProfileMasterID(e) {
|
@@ -8361,14 +8327,14 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8361
8327
|
},
|
8362
8328
|
getSystemVarProfileDetails(e) {
|
8363
8329
|
return (t) => {
|
8364
|
-
var r, n, a, o,
|
8365
|
-
return t ? (
|
8330
|
+
var r, n, a, o, i;
|
8331
|
+
return t ? (i = (o = (a = (n = (r = e.varProfileMap.get(t)) == null ? void 0 : r.varProfile) == null ? void 0 : n.varProfileMasters) == null ? void 0 : a.find((s) => s.cust_lvl === KG_CUSTOM_LEVEL.L0)) == null ? void 0 : o.varProfileDetails) != null ? i : null : (Logger.error("formID \u4E3A\u7A7A."), null);
|
8366
8332
|
};
|
8367
8333
|
},
|
8368
8334
|
getVarProfileDetail(e) {
|
8369
8335
|
return (t, r) => {
|
8370
8336
|
var n, a, o;
|
8371
|
-
return !t || !r ? null : (o = (a = (n = this.getCurrentVarProfileMaster(t)) == null ? void 0 : n.varProfileDetails) == null ? void 0 : a.find((
|
8337
|
+
return !t || !r ? null : (o = (a = (n = this.getCurrentVarProfileMaster(t)) == null ? void 0 : n.varProfileDetails) == null ? void 0 : a.find((i) => i.var_nam === r)) != null ? o : null;
|
8372
8338
|
};
|
8373
8339
|
},
|
8374
8340
|
getVarGridConfigMap(e) {
|
@@ -8395,7 +8361,7 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8395
8361
|
if (!t)
|
8396
8362
|
return Logger.error("formID \u4E3A\u7A7A."), null;
|
8397
8363
|
const r = e.varGridMap.get(t);
|
8398
|
-
return (o = (a = (n = r == null ? void 0 : r.varGrid) == null ? void 0 : n.varGridMasters) == null ? void 0 : a.find((
|
8364
|
+
return (o = (a = (n = r == null ? void 0 : r.varGrid) == null ? void 0 : n.varGridMasters) == null ? void 0 : a.find((i) => i.id === (r == null ? void 0 : r.currentVarGridMasterID))) != null ? o : null;
|
8399
8365
|
};
|
8400
8366
|
},
|
8401
8367
|
getCurrentVisibleVarGridDetails(e) {
|
@@ -8421,14 +8387,14 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8421
8387
|
},
|
8422
8388
|
getSystemVarGridDetails(e) {
|
8423
8389
|
return (t) => {
|
8424
|
-
var r, n, a, o,
|
8425
|
-
return t ? (
|
8390
|
+
var r, n, a, o, i;
|
8391
|
+
return t ? (i = (o = (a = (n = (r = e.varGridMap.get(t)) == null ? void 0 : r.varGrid) == null ? void 0 : n.varGridMasters) == null ? void 0 : a.find((s) => s.cust_lvl === KG_CUSTOM_LEVEL.L0)) == null ? void 0 : o.varGridDetails) != null ? i : null : (Logger.error("formID \u4E3A\u7A7A."), null);
|
8426
8392
|
};
|
8427
8393
|
},
|
8428
8394
|
getVarGridDetail(e) {
|
8429
8395
|
return (t, r) => {
|
8430
8396
|
var n, a, o;
|
8431
|
-
return !t || !r ? (Logger.error("formID \u6216 var_nam \u4E3A\u7A7A.", { frm_id: t, var_nam: r }), null) : (o = (a = (n = this.getCurrentVarGridMaster(t)) == null ? void 0 : n.varGridDetails) == null ? void 0 : a.find((
|
8397
|
+
return !t || !r ? (Logger.error("formID \u6216 var_nam \u4E3A\u7A7A.", { frm_id: t, var_nam: r }), null) : (o = (a = (n = this.getCurrentVarGridMaster(t)) == null ? void 0 : n.varGridDetails) == null ? void 0 : a.find((i) => i.var_nam === r)) != null ? o : null;
|
8432
8398
|
};
|
8433
8399
|
}
|
8434
8400
|
},
|
@@ -8514,12 +8480,12 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8514
8480
|
this.formIDs = this.formIDs.filter((t) => t.formID !== e), this.isRetrievingVarMap.delete(e), this.isRetrievingVarProfileMasterMap.delete(e), this.isCreatingMap.delete(e), this.isCreatingRequestingMap.delete(e), this.isUpdatingMap.delete(e), this.isUpdatingRequestingMap.delete(e), this.isCopyingMap.delete(e), this.isCopyingRequestingMap.delete(e), this.isDeletingMap.delete(e), this.isDeletingRequestingMap.delete(e), this.isOtherRequestingMap.delete(e), this.varCatalogMap.delete(e), this.varLookupMap.delete(e), this.varPossibilityMap.delete(e), this.varVariableConfigMap.delete(e), this.varButtonMap.delete(e), this.varSubmitConfigMap.delete(e), this.varSubmitFieldMap.delete(e), this.varProfileConfigMap.delete(e), this.varProfileMap.delete(e), this.varGridConfigMap.delete(e), this.varGridMap.delete(e), store_legacy.set("KgVar.formIDs", this.formIDs);
|
8515
8481
|
},
|
8516
8482
|
async retrieve(e) {
|
8517
|
-
var t, r, n, a, o,
|
8483
|
+
var t, r, n, a, o, i;
|
8518
8484
|
if (!!e) {
|
8519
8485
|
this.isRetrievingVarMap.set(e, !0);
|
8520
8486
|
try {
|
8521
8487
|
const {
|
8522
|
-
varCatalogs:
|
8488
|
+
varCatalogs: s,
|
8523
8489
|
varLookups: l,
|
8524
8490
|
varConfigs: u,
|
8525
8491
|
varVariableInputs: c,
|
@@ -8533,22 +8499,22 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8533
8499
|
varGrid: C,
|
8534
8500
|
varGridConfig: E
|
8535
8501
|
} = await GetAll({ params: { frm_id: e } });
|
8536
|
-
this.varCatalogMap.set(e,
|
8502
|
+
this.varCatalogMap.set(e, s != null ? s : []), this.varLookupMap.set(e, l != null ? l : []), this.varPossibilityMap.set(e, g != null ? g : []), this.varVariableConfigMap.set(e, u != null ? u : []), this.varVariableInputMap.set(e, c != null ? c : []), this.varButtonMap.set(e, transformVarButtons(p)), this.varButtonConfigMap.set(e, b != null ? b : null), this.varSubmitConfigMap.set(e, transformVarSubmitConfig(m)), this.varSubmitFieldMap.set(e, transformVarSubmitFields(v)), this.varProfileConfigMap.set(e, transformVarProfileConfig(y != null ? y : null)), this.varProfileMap.set(e, {
|
8537
8503
|
varProfile: _ != null ? _ : null,
|
8538
8504
|
currentVarProfileMasterID: (n = (r = (t = _ == null ? void 0 : _.varProfileMasters) == null ? void 0 : t.find((T) => T.def_flg === 1 || T.cust_lvl === KG_CUSTOM_LEVEL.L0)) == null ? void 0 : r.id) != null ? n : null
|
8539
8505
|
}), this.varGridConfigMap.set(e, transformVarGridConfig(E != null ? E : null)), this.varGridMap.set(e, {
|
8540
8506
|
varGrid: transformVarGridDTO(C),
|
8541
|
-
currentVarGridMasterID: (
|
8507
|
+
currentVarGridMasterID: (i = (o = (a = C == null ? void 0 : C.varGridMasters) == null ? void 0 : a.find((T) => T.def_flg === 1 || T.cust_lvl === KG_CUSTOM_LEVEL.L0)) == null ? void 0 : o.id) != null ? i : null
|
8542
8508
|
}), this.emit(e, "ready");
|
8543
|
-
} catch (
|
8544
|
-
throw
|
8509
|
+
} catch (s) {
|
8510
|
+
throw s;
|
8545
8511
|
} finally {
|
8546
8512
|
this.isRetrievingVarMap.set(e, !1);
|
8547
8513
|
}
|
8548
8514
|
}
|
8549
8515
|
},
|
8550
8516
|
async setCurrentVarProfileMasterID(e, t) {
|
8551
|
-
var a, o,
|
8517
|
+
var a, o, i, s;
|
8552
8518
|
if (!e)
|
8553
8519
|
return;
|
8554
8520
|
const r = this.varProfileMap.get(e);
|
@@ -8556,13 +8522,13 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8556
8522
|
return;
|
8557
8523
|
const n = (o = (a = r.varProfile) == null ? void 0 : a.varProfileMasters) == null ? void 0 : o.find((l) => l.id === t);
|
8558
8524
|
if (!!n)
|
8559
|
-
if ((
|
8525
|
+
if ((i = n.varProfileDetails) != null && i.length)
|
8560
8526
|
r.currentVarProfileMasterID = t != null ? t : null;
|
8561
8527
|
else {
|
8562
8528
|
this.isRetrievingVarProfileMasterMap.set(e, !0);
|
8563
8529
|
try {
|
8564
8530
|
const l = await QueryByID({ params: { id: n.id } });
|
8565
|
-
n.varProfileDetails = (
|
8531
|
+
n.varProfileDetails = (s = l == null ? void 0 : l.varProfileDetails) != null ? s : [], r.currentVarProfileMasterID = t != null ? t : null;
|
8566
8532
|
} catch (l) {
|
8567
8533
|
throw l;
|
8568
8534
|
} finally {
|
@@ -8593,7 +8559,7 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8593
8559
|
);
|
8594
8560
|
},
|
8595
8561
|
async setCurrentVarGridMasterID(e, t) {
|
8596
|
-
var a, o,
|
8562
|
+
var a, o, i, s;
|
8597
8563
|
if (!e)
|
8598
8564
|
return;
|
8599
8565
|
const r = this.varGridMap.get(e);
|
@@ -8601,13 +8567,13 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8601
8567
|
return;
|
8602
8568
|
const n = (o = (a = r.varGrid) == null ? void 0 : a.varGridMasters) == null ? void 0 : o.find((l) => l.id === t);
|
8603
8569
|
if (!!n)
|
8604
|
-
if ((
|
8570
|
+
if ((i = n.varGridDetails) != null && i.length)
|
8605
8571
|
r.currentVarGridMasterID = t != null ? t : null;
|
8606
8572
|
else {
|
8607
8573
|
this.isRetrievingVarGridMasterMap.set(e, !0);
|
8608
8574
|
try {
|
8609
8575
|
const l = await QueryByID$1({ params: { id: n.id } });
|
8610
|
-
n.varGridDetails = (
|
8576
|
+
n.varGridDetails = (s = l == null ? void 0 : l.varGridDetails) != null ? s : [], r.currentVarGridMasterID = t != null ? t : null;
|
8611
8577
|
} catch (l) {
|
8612
8578
|
throw l;
|
8613
8579
|
} finally {
|
@@ -8642,10 +8608,10 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8642
8608
|
var o;
|
8643
8609
|
if (a) {
|
8644
8610
|
setTimeout(() => n(), 0);
|
8645
|
-
let
|
8646
|
-
Object.entries(r).forEach(([
|
8647
|
-
s
|
8648
|
-
}), a.cmd_prm = JSON.stringify(
|
8611
|
+
let i = JSON.parse((o = a.cmd_prm) != null ? o : "{}");
|
8612
|
+
Object.entries(r).forEach(([s, l]) => {
|
8613
|
+
i[s] = l;
|
8614
|
+
}), a.cmd_prm = JSON.stringify(i), this.varPossibilityMap.set(e, this.varPossibilityMap.get(e));
|
8649
8615
|
}
|
8650
8616
|
},
|
8651
8617
|
{ immediate: !0 }
|
@@ -8658,11 +8624,11 @@ const useKgVarStore = () => (store$6 || (store$6 = defineStore("KgVar", {
|
|
8658
8624
|
() => this.getVarSubmitField(e, t),
|
8659
8625
|
(a) => {
|
8660
8626
|
a && setTimeout(() => {
|
8661
|
-
var
|
8662
|
-
n(), Object.entries(r).forEach(([
|
8663
|
-
|
8627
|
+
var i;
|
8628
|
+
n(), Object.entries(r).forEach(([s, l]) => {
|
8629
|
+
s in a && (a[s] = l);
|
8664
8630
|
});
|
8665
|
-
const o = [...(
|
8631
|
+
const o = [...(i = this.varSubmitFieldMap.get(e)) != null ? i : []];
|
8666
8632
|
o.splice(o.indexOf(a), 1, { ...a }), this.varSubmitFieldMap.set(e, o);
|
8667
8633
|
});
|
8668
8634
|
},
|
@@ -8675,27 +8641,27 @@ function useKgVar(e, t, r = 0) {
|
|
8675
8641
|
var n, a;
|
8676
8642
|
try {
|
8677
8643
|
let o = function(x) {
|
8678
|
-
return isFunction$2(x) ? (
|
8644
|
+
return isFunction$2(x) ? (s.addEventListener(i, "ready", x), getCurrentInstance() && onUnmounted(() => s.removeEventListener(i, "ready", x)), () => s.removeEventListener(i, "ready", x)) : () => {
|
8679
8645
|
};
|
8680
|
-
},
|
8681
|
-
if (!
|
8646
|
+
}, i = e || inject(KG_DI_FORM_ID, "");
|
8647
|
+
if (!i)
|
8682
8648
|
throw new Error("useKgVar() \u65B9\u6CD5\u5FC5\u987B\u4F20\u5165 formID \u53C2\u6570.");
|
8683
|
-
const
|
8684
|
-
t && getCurrentInstance() && (provide(KG_DI_FORM_ID,
|
8685
|
-
|
8649
|
+
const s = useKgVarStore()();
|
8650
|
+
t && getCurrentInstance() && (provide(KG_DI_FORM_ID, i), onMounted(() => {
|
8651
|
+
s.enter({ formID: i, level: r });
|
8686
8652
|
}), onUnmounted(() => {
|
8687
|
-
|
8653
|
+
s.leave(i);
|
8688
8654
|
}));
|
8689
8655
|
const l = (x) => computed(() => {
|
8690
8656
|
var q, Y, Q;
|
8691
|
-
return (Q = (Y = (q =
|
8692
|
-
}), u = computed(() =>
|
8657
|
+
return (Q = (Y = (q = s.getVarCatalog(i, x)) == null ? void 0 : q.var_text) != null ? Y : x) != null ? Q : "";
|
8658
|
+
}), u = computed(() => s.isRetrievingVar(i)), c = computed(() => s.isRetrievingVarProfileMaster(i)), g = computed(() => s.isRetrievingVarGridMaster(i)), p = computed(() => s.isCreating(i)), b = computed(() => s.isCreatingRequesting(i)), m = computed(() => s.isUpdating(i)), v = computed(() => s.isUpdatingRequesting(i)), _ = computed(() => s.isCopying(i)), y = computed(() => s.isCopyingRequesting(i)), C = computed(() => s.isDeleting(i)), E = computed(() => s.isDeletingRequesting(i)), T = computed(() => s.isOtherRequesting(i)), I = computed(() => s.getVarButtons(i)), k = computed(() => s.getVarButtonSearch(i)), w = computed(() => s.getVarButtonCreate(i)), M = computed(() => s.getVarButtonUpdate(i)), A = computed(() => s.getVarButtonCopy(i)), O = computed(() => s.getVarButtonDelete(i)), B = computed(() => s.getVarProfileMasters(i)), $ = computed(() => s.getCurrentVarProfileMaster(i)), P = computed(() => s.getCurrentVarProfileMasterID(i)), D = computed(() => {
|
8693
8659
|
var x, q;
|
8694
8660
|
return (q = (x = $.value) == null ? void 0 : x.varProfileDetails) != null ? q : null;
|
8695
|
-
}), V = computed(() =>
|
8661
|
+
}), V = computed(() => s.getVarGridConfig(i)), R = computed(() => s.getVarGridMasters(i)), L = computed(() => s.getCurrentVarGridMaster(i)), H = computed(() => s.getSystemVarGridDetails(i)), N = computed(() => s.getCurrentVarGridDetails(i));
|
8696
8662
|
return {
|
8697
|
-
formID:
|
8698
|
-
store:
|
8663
|
+
formID: i,
|
8664
|
+
store: s,
|
8699
8665
|
isRetrievingVar: u,
|
8700
8666
|
isRetrievingVarProfileMaster: c,
|
8701
8667
|
isRetrievingVarGridMaster: g,
|
@@ -8743,7 +8709,7 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8743
8709
|
provide(DI_KG_SLOTS, e.kgSlots);
|
8744
8710
|
const r = useKgVar();
|
8745
8711
|
KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE;
|
8746
|
-
const n = computed(() => r.store.getVarSubmitConfig(r.formID)), a = computed(() => r.store.getVarProfileConfig(r.formID)), o = computed(() => r.store.getVarButtonConfig(r.formID)),
|
8712
|
+
const n = computed(() => r.store.getVarSubmitConfig(r.formID)), a = computed(() => r.store.getVarProfileConfig(r.formID)), o = computed(() => r.store.getVarButtonConfig(r.formID)), i = computed(() => {
|
8747
8713
|
var p, b, m, v;
|
8748
8714
|
switch (!0) {
|
8749
8715
|
case r.isCreating.value:
|
@@ -8756,7 +8722,7 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8756
8722
|
return ((v = n.value) == null ? void 0 : v.del_flg) !== 0;
|
8757
8723
|
}
|
8758
8724
|
return !1;
|
8759
|
-
}),
|
8725
|
+
}), s = computed(() => {
|
8760
8726
|
var p;
|
8761
8727
|
return ((p = o.value) == null ? void 0 : p.available_flg) !== 0;
|
8762
8728
|
}), l = computed(() => {
|
@@ -8772,7 +8738,7 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8772
8738
|
}, {
|
8773
8739
|
default: () => {
|
8774
8740
|
var p, b, m;
|
8775
|
-
return [t.default ? t.default() : createVNode(Fragment, null, [l.value && createVNode(KgSearch, null, null),
|
8741
|
+
return [t.default ? t.default() : createVNode(Fragment, null, [l.value && createVNode(KgSearch, null, null), s.value && createVNode(KgButton, null, null), createVNode(KgTable, null, null), (b = (p = e.kgSlots) == null ? void 0 : p.afterKgTable) == null ? void 0 : b.call(p), i.value && createVNode(KgSubmit, {
|
8776
8742
|
kgClass: (m = e.kgSubmitClass) != null ? m : ""
|
8777
8743
|
}, null)])];
|
8778
8744
|
}
|
@@ -8835,9 +8801,9 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8835
8801
|
slots: t,
|
8836
8802
|
emit: r
|
8837
8803
|
}) {
|
8838
|
-
const n = inject(KG_DI_HOST_FORM_ID, ""), a = useKgVar(n), o = inject(KG_DI_VAR_NAME, ""),
|
8839
|
-
useKgVar(
|
8840
|
-
const l = useKgTable(
|
8804
|
+
const n = inject(KG_DI_HOST_FORM_ID, ""), a = useKgVar(n), o = inject(KG_DI_VAR_NAME, ""), i = inject(KG_DI_LOOKUP_ID, ""), s = inject(DI_ON_KG_LOOKUP_BEFORE_OK, null);
|
8805
|
+
useKgVar(i, !0, a.store.getFormLevel(a.formID) + 1);
|
8806
|
+
const l = useKgTable(i), u = computed(() => a.store.getVarLookup(n, o)), c = computed(() => {
|
8841
8807
|
var m;
|
8842
8808
|
return ((m = u == null ? void 0 : u.value) == null ? void 0 : m.mult_flg) === 1;
|
8843
8809
|
}), g = computed(() => {
|
@@ -8852,10 +8818,10 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8852
8818
|
var m, v, _, y, C, E, T;
|
8853
8819
|
if (c.value) {
|
8854
8820
|
const I = (v = (m = l.selectedRows) == null ? void 0 : m.value) != null ? v : [], k = (_ = I.map((w) => w[g.value])) != null ? _ : [];
|
8855
|
-
(!
|
8821
|
+
(!s || s(k, I)) && (r("kgOk", k, I), r("update:visible", !1));
|
8856
8822
|
} else {
|
8857
8823
|
const I = (E = (C = (y = l.selectedRows) == null ? void 0 : y.value) == null ? void 0 : C[0]) != null ? E : null, k = (T = I == null ? void 0 : I[g.value]) != null ? T : "";
|
8858
|
-
(!
|
8824
|
+
(!s || s(k, I)) && (r("kgOk", k, I), r("update:visible", !1));
|
8859
8825
|
}
|
8860
8826
|
}
|
8861
8827
|
return () => {
|
@@ -8896,8 +8862,8 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8896
8862
|
function o() {
|
8897
8863
|
a.value = !0;
|
8898
8864
|
}
|
8899
|
-
function s
|
8900
|
-
r("kgOk",
|
8865
|
+
function i(s, l) {
|
8866
|
+
r("kgOk", s, l);
|
8901
8867
|
}
|
8902
8868
|
return () => createVNode(Fragment, null, [createVNode(Button, {
|
8903
8869
|
onClick: o,
|
@@ -8906,9 +8872,9 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8906
8872
|
}, {
|
8907
8873
|
default: () => [createVNode(SearchOutlined$1, null, null)]
|
8908
8874
|
}), a.value ? createVNode(KgFormItemAddonLookupModal, {
|
8909
|
-
onKgOk:
|
8875
|
+
onKgOk: i,
|
8910
8876
|
visible: a.value,
|
8911
|
-
"onUpdate:visible": (
|
8877
|
+
"onUpdate:visible": (s) => a.value = s
|
8912
8878
|
}, null) : null]);
|
8913
8879
|
}
|
8914
8880
|
}), KgForm_Item = "", KgFormItemCheckbox = defineComponent({
|
@@ -8924,45 +8890,45 @@ const DI_KG_SLOTS = Symbol("DI_KG_SLOTS"), KgVar$1 = "", getProps$t = () => ({
|
|
8924
8890
|
});
|
8925
8891
|
function _useServices$2(e) {
|
8926
8892
|
const t = useKgVar(), r = computed(() => t.store.getVarPossibility(t.formID, e.kgVarName)), n = computed(() => t.store.getVariableConfig(t.formID, e.kgVarName)), a = computed(() => {
|
8927
|
-
var
|
8928
|
-
return KgUtil.tryParseJSON((
|
8893
|
+
var i;
|
8894
|
+
return KgUtil.tryParseJSON((i = n.value) == null ? void 0 : i.ctrl_prop);
|
8929
8895
|
});
|
8930
|
-
function o(
|
8896
|
+
function o(i) {
|
8931
8897
|
var u, c, g, p, b;
|
8932
|
-
if (!
|
8898
|
+
if (!i)
|
8933
8899
|
return [];
|
8934
|
-
const
|
8900
|
+
const s = (c = (u = r.value) == null ? void 0 : u.val_clm) != null ? c : "", l = (p = (g = r.value) == null ? void 0 : g.val_data_type) != null ? p : "string";
|
8935
8901
|
switch (l) {
|
8936
8902
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
8937
|
-
|
8938
|
-
m[
|
8903
|
+
i.forEach((m) => {
|
8904
|
+
m[s] = String(m[s]);
|
8939
8905
|
});
|
8940
8906
|
break;
|
8941
8907
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER:
|
8942
|
-
|
8943
|
-
let v = Number(m[
|
8944
|
-
Number.isNaN(v) && (v = m[
|
8908
|
+
i.forEach((m) => {
|
8909
|
+
let v = Number(m[s]);
|
8910
|
+
Number.isNaN(v) && (v = m[s], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${m[s]} \u8F6C\u6362\u4E3A ${l} \u7C7B\u578B`, {
|
8945
8911
|
frm_id: t.formID,
|
8946
8912
|
var_nam: e.kgVarName,
|
8947
8913
|
VarPossibility: r.value
|
8948
|
-
})), m[
|
8914
|
+
})), m[s] = v;
|
8949
8915
|
});
|
8950
8916
|
break;
|
8951
8917
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
8952
|
-
|
8918
|
+
i.forEach((m) => {
|
8953
8919
|
let v;
|
8954
|
-
String(m[
|
8920
|
+
String(m[s]).toLowerCase() === "true" ? v = !0 : String(m[s]).toLowerCase() === "false" ? v = !1 : (v = m[s], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${m[s]} \u8F6C\u6362\u4E3A ${l} \u7C7B\u578B`, {
|
8955
8921
|
frm_id: t.formID,
|
8956
8922
|
var_nam: e.kgVarName,
|
8957
8923
|
VarPossibility: r.value
|
8958
|
-
})), m[
|
8924
|
+
})), m[s] = v;
|
8959
8925
|
});
|
8960
8926
|
break;
|
8961
8927
|
}
|
8962
|
-
return (b = a.value) != null && b.excludeValues ?
|
8928
|
+
return (b = a.value) != null && b.excludeValues ? i.filter((m) => {
|
8963
8929
|
var v;
|
8964
|
-
return !((v = a.value.excludeValues) != null && v.includes(m[
|
8965
|
-
}) :
|
8930
|
+
return !((v = a.value.excludeValues) != null && v.includes(m[s]));
|
8931
|
+
}) : i;
|
8966
8932
|
}
|
8967
8933
|
return {
|
8968
8934
|
transformDatas: o
|
@@ -8979,16 +8945,16 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
8979
8945
|
attrs: t,
|
8980
8946
|
emit: r
|
8981
8947
|
}) {
|
8982
|
-
const n = useKg(), a = useKgVar(), o = inject(DI_FORM_REF, ref(null)),
|
8983
|
-
transformDatas:
|
8948
|
+
const n = useKg(), a = useKgVar(), o = inject(DI_FORM_REF, ref(null)), i = inject(DI_FORM_MODEL, computed(() => ({}))), {
|
8949
|
+
transformDatas: s
|
8984
8950
|
} = _useServices$2(e), l = ref(!1), u = ref(!1), c = ref([]), g = computed(() => a.store.getVarPossibility(a.formID, e.kgVarName)), p = computed(() => a.store.getVariableConfig(a.formID, e.kgVarName)), b = computed(() => {
|
8985
8951
|
var E;
|
8986
8952
|
let C = KgVarUtil.parseCommandParameter((E = g.value) == null ? void 0 : E.cmd_prm);
|
8987
8953
|
return C = mapValues(C, (T) => {
|
8988
8954
|
if (typeof T == "string" && T.startsWith("{") && T.endsWith("}")) {
|
8989
8955
|
const I = T.slice(1, -1);
|
8990
|
-
if (
|
8991
|
-
return
|
8956
|
+
if (i.value && I in i.value)
|
8957
|
+
return i.value[I];
|
8992
8958
|
}
|
8993
8959
|
return T;
|
8994
8960
|
}), C;
|
@@ -9053,10 +9019,10 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9053
9019
|
else
|
9054
9020
|
switch (!0) {
|
9055
9021
|
case isArrayLike(k):
|
9056
|
-
c.value =
|
9022
|
+
c.value = s(k);
|
9057
9023
|
break;
|
9058
9024
|
case (k && "total" in k && "records" in k):
|
9059
|
-
c.value =
|
9025
|
+
c.value = s(k.records);
|
9060
9026
|
break;
|
9061
9027
|
}
|
9062
9028
|
if (c.value.length > 0) {
|
@@ -9135,17 +9101,17 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9135
9101
|
attrs: n
|
9136
9102
|
}) {
|
9137
9103
|
const a = inject("$dayjs", dayjs), o = computed(() => {
|
9138
|
-
let
|
9139
|
-
if (!!
|
9140
|
-
return
|
9104
|
+
let s = e.value;
|
9105
|
+
if (!!s && (a.isDayjs(s) || (s = a(s)), !!a.isDayjs(s)))
|
9106
|
+
return s;
|
9141
9107
|
});
|
9142
|
-
function s
|
9143
|
-
const l =
|
9108
|
+
function i(s) {
|
9109
|
+
const l = s ? a(s) : void 0;
|
9144
9110
|
r("update:value", l), r("kgChange", l);
|
9145
9111
|
}
|
9146
9112
|
return () => createVNode(DatePicker, {
|
9147
9113
|
value: o.value,
|
9148
|
-
"onUpdate:value":
|
9114
|
+
"onUpdate:value": i,
|
9149
9115
|
id: n.id,
|
9150
9116
|
disabled: e.kgDisabled,
|
9151
9117
|
placeholder: e.kgPlaceholder,
|
@@ -9163,17 +9129,17 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9163
9129
|
attrs: n
|
9164
9130
|
}) {
|
9165
9131
|
const a = inject("$dayjs", dayjs), o = computed(() => {
|
9166
|
-
let
|
9167
|
-
if (!!
|
9168
|
-
return
|
9132
|
+
let s = e.value;
|
9133
|
+
if (!!s && !(!isArray$1(s) || s.length !== 2) && ((!a.isDayjs(s[0]) || !a.isDayjs(s[1])) && (s = [a(s[0]), a(s[1])]), !(!a.isDayjs(s[0]) || !a.isDayjs(s[1]))))
|
9134
|
+
return s;
|
9169
9135
|
});
|
9170
|
-
function s
|
9171
|
-
const l =
|
9136
|
+
function i(s) {
|
9137
|
+
const l = s ? [a(s[0]), a(s[1])] : void 0;
|
9172
9138
|
r("update:value", l), r("kgChange", l);
|
9173
9139
|
}
|
9174
9140
|
return () => createVNode(DatePicker.RangePicker, {
|
9175
9141
|
value: o.value,
|
9176
|
-
"onUpdate:value":
|
9142
|
+
"onUpdate:value": i,
|
9177
9143
|
id: n.id,
|
9178
9144
|
disabled: e.kgDisabled,
|
9179
9145
|
placeholder: [e.kgPlaceholder, e.kgPlaceholder],
|
@@ -9233,11 +9199,11 @@ const KgFormItemCheckboxGroup = defineComponent({
|
|
9233
9199
|
function _useServices$1(e) {
|
9234
9200
|
const t = useKgVar(), r = computed(() => t.store.getVarPossibility(t.formID, e.kgVarName));
|
9235
9201
|
function n(a) {
|
9236
|
-
var
|
9202
|
+
var s, l, u, c;
|
9237
9203
|
if (!a)
|
9238
9204
|
return [];
|
9239
|
-
const o = (l = (
|
9240
|
-
switch (
|
9205
|
+
const o = (l = (s = r.value) == null ? void 0 : s.val_clm) != null ? l : "", i = (c = (u = r.value) == null ? void 0 : u.val_data_type) != null ? c : "string";
|
9206
|
+
switch (i) {
|
9241
9207
|
case KG_POSSIBILITY_DATA_TYPE.STRING:
|
9242
9208
|
a.forEach((g) => {
|
9243
9209
|
g[o] = String(g[o]);
|
@@ -9246,7 +9212,7 @@ function _useServices$1(e) {
|
|
9246
9212
|
case KG_POSSIBILITY_DATA_TYPE.NUMBER:
|
9247
9213
|
a.forEach((g) => {
|
9248
9214
|
let p = Number(g[o]);
|
9249
|
-
Number.isNaN(p) && (p = g[o], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${g[o]} \u8F6C\u6362\u4E3A ${
|
9215
|
+
Number.isNaN(p) && (p = g[o], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${g[o]} \u8F6C\u6362\u4E3A ${i} \u7C7B\u578B`, {
|
9250
9216
|
frm_id: t.formID,
|
9251
9217
|
var_nam: e.kgVarName,
|
9252
9218
|
VarPossibility: r.value
|
@@ -9256,7 +9222,7 @@ function _useServices$1(e) {
|
|
9256
9222
|
case KG_POSSIBILITY_DATA_TYPE.BOOLEAN:
|
9257
9223
|
a.forEach((g) => {
|
9258
9224
|
let p;
|
9259
|
-
String(g[o]).toLowerCase() === "true" ? p = !0 : String(g[o]).toLowerCase() === "false" ? p = !1 : (p = g[o], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${g[o]} \u8F6C\u6362\u4E3A ${
|
9225
|
+
String(g[o]).toLowerCase() === "true" ? p = !0 : String(g[o]).toLowerCase() === "false" ? p = !1 : (p = g[o], Logger.error(`| \u6570\u636E\u6709\u8BEF | \u65E0\u6CD5\u5C06 ${g[o]} \u8F6C\u6362\u4E3A ${i} \u7C7B\u578B`, {
|
9260
9226
|
frm_id: t.formID,
|
9261
9227
|
var_nam: e.kgVarName,
|
9262
9228
|
VarPossibility: r.value
|
@@ -9280,9 +9246,9 @@ const KgFormItemSelect = defineComponent({
|
|
9280
9246
|
}) {
|
9281
9247
|
const n = useKgVar(), a = inject(DI_FORM_MODEL, computed(() => ({}))), {
|
9282
9248
|
transformDatas: o
|
9283
|
-
} = _useServices$1(e),
|
9249
|
+
} = _useServices$1(e), i = ref([]), s = computed(() => n.store.getVarPossibility(n.formID, e.kgVarName)), l = computed(() => {
|
9284
9250
|
var b;
|
9285
|
-
let p = KgVarUtil.parseCommandParameter((b =
|
9251
|
+
let p = KgVarUtil.parseCommandParameter((b = s.value) == null ? void 0 : b.cmd_prm);
|
9286
9252
|
return p = mapValues(p, (m) => {
|
9287
9253
|
var v, _;
|
9288
9254
|
if (typeof m == "string" && m.startsWith("{") && m.endsWith("}")) {
|
@@ -9299,13 +9265,13 @@ const KgFormItemSelect = defineComponent({
|
|
9299
9265
|
});
|
9300
9266
|
watch(l, () => {
|
9301
9267
|
var p;
|
9302
|
-
(p =
|
9268
|
+
(p = s.value) != null && p.id && u();
|
9303
9269
|
}, {
|
9304
9270
|
immediate: !0
|
9305
9271
|
});
|
9306
9272
|
async function u() {
|
9307
9273
|
var y, C, E, T, I, k, w, M;
|
9308
|
-
const p = (y =
|
9274
|
+
const p = (y = s.value) == null ? void 0 : y.cmd, b = (E = (C = s.value) == null ? void 0 : C.cmd_method) != null ? E : "GET", m = (I = (T = s.value) == null ? void 0 : T.val_clm) != null ? I : "", v = (w = (k = s.value) == null ? void 0 : k.lbl_clm) != null ? w : "";
|
9309
9275
|
if (!p || !m || !v) {
|
9310
9276
|
Logger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF.", {
|
9311
9277
|
frm_id: n.formID,
|
@@ -9326,18 +9292,18 @@ const KgFormItemSelect = defineComponent({
|
|
9326
9292
|
} catch {
|
9327
9293
|
}
|
9328
9294
|
if (!isObjectLike(_))
|
9329
|
-
|
9295
|
+
i.value = [];
|
9330
9296
|
else
|
9331
9297
|
switch (!0) {
|
9332
9298
|
case isArrayLike(_):
|
9333
|
-
|
9299
|
+
i.value = o(_);
|
9334
9300
|
break;
|
9335
9301
|
case (_ && "total" in _ && "records" in _):
|
9336
|
-
|
9302
|
+
i.value = o(_.records);
|
9337
9303
|
break;
|
9338
9304
|
}
|
9339
|
-
if (
|
9340
|
-
const A =
|
9305
|
+
if (i.value.length > 0) {
|
9306
|
+
const A = i.value[0];
|
9341
9307
|
(!(m in A) || !(v in A)) && Logger.error("\u4E0B\u62C9\u5217\u8868\u914D\u7F6E\u6709\u8BEF, \u6570\u636E\u5217(val_clm)\u6216\u663E\u793A\u5217(lbl_clm)\u6709\u8BEF.", {
|
9342
9308
|
frm_id: n.formID,
|
9343
9309
|
var_nam: e.kgVarName,
|
@@ -9347,13 +9313,13 @@ const KgFormItemSelect = defineComponent({
|
|
9347
9313
|
\u6240\u6709\u5217: Object.keys(A)
|
9348
9314
|
});
|
9349
9315
|
}
|
9350
|
-
r("kgSelectDatasChange",
|
9316
|
+
r("kgSelectDatasChange", i.value), i.value.find((A) => A[m] === e.value) || r("update:value", void 0);
|
9351
9317
|
}
|
9352
9318
|
function c(p) {
|
9353
9319
|
var m;
|
9354
|
-
const b = (m = toRaw(
|
9320
|
+
const b = (m = toRaw(i.value.find((v) => {
|
9355
9321
|
var _, y;
|
9356
|
-
return v[(y = (_ =
|
9322
|
+
return v[(y = (_ = s.value) == null ? void 0 : _.val_clm) != null ? y : ""] === p;
|
9357
9323
|
}))) != null ? m : null;
|
9358
9324
|
r("kgSelectChange", b), a.value[`${e.kgVarName}_obj`] = b;
|
9359
9325
|
}
|
@@ -9373,19 +9339,19 @@ const KgFormItemSelect = defineComponent({
|
|
9373
9339
|
class: "kg-form-item-select",
|
9374
9340
|
dropdownClassName: "kg-form-item-select-dropdown",
|
9375
9341
|
style: "width: 100%",
|
9376
|
-
"kg-cmd": (p =
|
9377
|
-
"kg-val-clm": (b =
|
9378
|
-
"kg-lbl-clm": (m =
|
9342
|
+
"kg-cmd": (p = s.value) == null ? void 0 : p.cmd,
|
9343
|
+
"kg-val-clm": (b = s.value) == null ? void 0 : b.val_clm,
|
9344
|
+
"kg-lbl-clm": (m = s.value) == null ? void 0 : m.lbl_clm
|
9379
9345
|
}, {
|
9380
|
-
default: () =>
|
9346
|
+
default: () => i.value.map((v) => {
|
9381
9347
|
var _, y, C, E;
|
9382
9348
|
return createVNode(Select.Option, {
|
9383
|
-
"kg-value": v[(y = (_ =
|
9384
|
-
value: v[(E = (C =
|
9349
|
+
"kg-value": v[(y = (_ = s.value) == null ? void 0 : _.val_clm) != null ? y : ""],
|
9350
|
+
value: v[(E = (C = s.value) == null ? void 0 : C.val_clm) != null ? E : ""]
|
9385
9351
|
}, {
|
9386
9352
|
default: () => {
|
9387
9353
|
var T, I;
|
9388
|
-
return [v[(I = (T =
|
9354
|
+
return [v[(I = (T = s.value) == null ? void 0 : T.lbl_clm) != null ? I : ""]];
|
9389
9355
|
}
|
9390
9356
|
});
|
9391
9357
|
}),
|
@@ -9419,10 +9385,10 @@ function _useRules(e) {
|
|
9419
9385
|
return {
|
9420
9386
|
rules: computed(() => {
|
9421
9387
|
var l, u, c, g, p, b, m, v;
|
9422
|
-
let
|
9388
|
+
let s = [];
|
9423
9389
|
switch (e.kgContext) {
|
9424
9390
|
case KG_FORM_CONTEXT.SEARCH:
|
9425
|
-
((l = n.value) == null ? void 0 : l.rqr_flg) === 1 &&
|
9391
|
+
((l = n.value) == null ? void 0 : l.rqr_flg) === 1 && s.push({
|
9426
9392
|
required: !0,
|
9427
9393
|
message: t.t("kg.required")
|
9428
9394
|
});
|
@@ -9430,25 +9396,25 @@ function _useRules(e) {
|
|
9430
9396
|
case KG_FORM_CONTEXT.SUBMIT:
|
9431
9397
|
switch (!0) {
|
9432
9398
|
case r.isCreating.value:
|
9433
|
-
((u = o.value) == null ? void 0 : u.crt_rqr_flg) === 1 &&
|
9399
|
+
((u = o.value) == null ? void 0 : u.crt_rqr_flg) === 1 && s.push({
|
9434
9400
|
required: !0,
|
9435
9401
|
message: t.t("kg.required")
|
9436
9402
|
});
|
9437
9403
|
break;
|
9438
9404
|
case r.isUpdating.value:
|
9439
|
-
((c = o.value) == null ? void 0 : c.upt_rqr_flg) === 1 &&
|
9405
|
+
((c = o.value) == null ? void 0 : c.upt_rqr_flg) === 1 && s.push({
|
9440
9406
|
required: !0,
|
9441
9407
|
message: t.t("kg.required")
|
9442
9408
|
});
|
9443
9409
|
break;
|
9444
9410
|
case r.isCopying.value:
|
9445
|
-
((g = o.value) == null ? void 0 : g.cpy_rqr_flg) === 1 &&
|
9411
|
+
((g = o.value) == null ? void 0 : g.cpy_rqr_flg) === 1 && s.push({
|
9446
9412
|
required: !0,
|
9447
9413
|
message: t.t("kg.required")
|
9448
9414
|
});
|
9449
9415
|
break;
|
9450
9416
|
case r.isDeleting.value:
|
9451
|
-
((p = o.value) == null ? void 0 : p.del_rqr_flg) === 1 &&
|
9417
|
+
((p = o.value) == null ? void 0 : p.del_rqr_flg) === 1 && s.push({
|
9452
9418
|
required: !0,
|
9453
9419
|
message: t.t("kg.required")
|
9454
9420
|
});
|
@@ -9459,14 +9425,14 @@ function _useRules(e) {
|
|
9459
9425
|
switch ((b = a.value) == null ? void 0 : b.data_type) {
|
9460
9426
|
case KG_VAR_INPUT__DATA_TYPE.NUMBER:
|
9461
9427
|
const _ = (m = a.value) == null ? void 0 : m.min;
|
9462
|
-
isNil(_) || (((v = a.value) == null ? void 0 : v.min_include_flg) === 1 ?
|
9428
|
+
isNil(_) || (((v = a.value) == null ? void 0 : v.min_include_flg) === 1 ? s.push({
|
9463
9429
|
validator: (y, C) => Number(C) < _ ? Promise.reject(t.t("kg.KgFormItem.mustGTE", [_])) : Promise.resolve()
|
9464
|
-
}) :
|
9430
|
+
}) : s.push({
|
9465
9431
|
validator: (y, C) => Number(C) <= _ ? Promise.reject(t.t("kg.KgFormItem.mustGT", [_])) : Promise.resolve()
|
9466
9432
|
}));
|
9467
9433
|
break;
|
9468
9434
|
}
|
9469
|
-
return e.kgRules && (
|
9435
|
+
return e.kgRules && (s = [...s, ...e.kgRules]), s;
|
9470
9436
|
})
|
9471
9437
|
};
|
9472
9438
|
}
|
@@ -9479,7 +9445,7 @@ const KgFormItem = defineComponent({
|
|
9479
9445
|
emit: r
|
9480
9446
|
}) {
|
9481
9447
|
provide(KG_DI_VAR_NAME, e.kgVarName), provide(DI_ON_KG_LOOKUP_BEFORE_OK, e.onKgLookupBeforeOk), useKg();
|
9482
|
-
const n = useKgVar(), a = inject(DI_FORM_MODEL, computed(() => ({}))), o = inject(DI_FORM_REF, ref(null)),
|
9448
|
+
const n = useKgVar(), a = inject(DI_FORM_MODEL, computed(() => ({}))), o = inject(DI_FORM_REF, ref(null)), i = computed(() => n.store.getVarLookup(n.formID, e.kgVarName)), s = computed(() => n.store.getVariableConfig(n.formID, e.kgVarName)), l = computed(() => n.store.getVarProfileDetail(n.formID, e.kgVarName)), u = computed(() => n.store.getVarSubmitField(n.formID, e.kgVarName)), {
|
9483
9449
|
rules: c
|
9484
9450
|
} = _useRules(e), g = computed(() => {
|
9485
9451
|
var A, O, B, $, P;
|
@@ -9567,7 +9533,7 @@ const KgFormItem = defineComponent({
|
|
9567
9533
|
}), v = computed(() => {
|
9568
9534
|
var A, O, B, $;
|
9569
9535
|
let M = "kg-form-item";
|
9570
|
-
switch (
|
9536
|
+
switch (i.value && (M += " kg-form-item-lookup"), e.kgContext) {
|
9571
9537
|
case KG_FORM_CONTEXT.SEARCH:
|
9572
9538
|
switch (!0) {
|
9573
9539
|
case ((A = l.value) == null ? void 0 : A.vis_flg) === 0:
|
@@ -9621,7 +9587,7 @@ const KgFormItem = defineComponent({
|
|
9621
9587
|
return M;
|
9622
9588
|
}), y = computed(() => {
|
9623
9589
|
var M;
|
9624
|
-
return (M =
|
9590
|
+
return (M = s.value) == null ? void 0 : M.ctrl_typ;
|
9625
9591
|
}), C = computed(() => encodeURIComponent(`${e.kgContext}~${n.formID}~${e.kgVarName}`)), E = ref(null);
|
9626
9592
|
function T(M, A) {
|
9627
9593
|
var O;
|
@@ -9633,7 +9599,7 @@ const KgFormItem = defineComponent({
|
|
9633
9599
|
varName: e.kgVarName,
|
9634
9600
|
props: _,
|
9635
9601
|
model: a,
|
9636
|
-
varConfig:
|
9602
|
+
varConfig: s,
|
9637
9603
|
varProfileDetail: l,
|
9638
9604
|
varSubmitField: u
|
9639
9605
|
};
|
@@ -9675,11 +9641,11 @@ const KgFormItem = defineComponent({
|
|
9675
9641
|
}
|
9676
9642
|
function w() {
|
9677
9643
|
var M;
|
9678
|
-
return !
|
9644
|
+
return !i.value || !((M = i.value) != null && M.lkp_id) ? null : createVNode(Form.ItemRest, null, {
|
9679
9645
|
default: () => [createVNode(KgFormItemAddonLookup, {
|
9680
9646
|
kgDisabled: g.value,
|
9681
9647
|
onKgOk: T,
|
9682
|
-
kgLookupID:
|
9648
|
+
kgLookupID: i.value.lkp_id
|
9683
9649
|
}, null)]
|
9684
9650
|
});
|
9685
9651
|
}
|
@@ -9689,8 +9655,8 @@ const KgFormItem = defineComponent({
|
|
9689
9655
|
ref: E,
|
9690
9656
|
"kg-frm-id": n.formID,
|
9691
9657
|
"kg-var-nam": e.kgVarName,
|
9692
|
-
"kg-lkp-id": (M =
|
9693
|
-
"kg-lkp-ret-fld": (A =
|
9658
|
+
"kg-lkp-id": (M = i.value) == null ? void 0 : M.lkp_id,
|
9659
|
+
"kg-lkp-ret-fld": (A = i.value) == null ? void 0 : A.ret_fld,
|
9694
9660
|
span: b.value,
|
9695
9661
|
class: v.value,
|
9696
9662
|
style: m.value
|
@@ -9721,17 +9687,17 @@ const KgFormItem = defineComponent({
|
|
9721
9687
|
...e
|
9722
9688
|
}));
|
9723
9689
|
return provide(DI_FORM_MODEL, computed(() => e.model)), provide(DI_FORM_REF, a), r({
|
9724
|
-
resetFields(
|
9725
|
-
var
|
9726
|
-
return (
|
9690
|
+
resetFields(i) {
|
9691
|
+
var s;
|
9692
|
+
return (s = a.value) == null ? void 0 : s.resetFields(i);
|
9727
9693
|
},
|
9728
|
-
clearValidate(
|
9729
|
-
var
|
9730
|
-
return (
|
9694
|
+
clearValidate(i) {
|
9695
|
+
var s;
|
9696
|
+
return (s = a.value) == null ? void 0 : s.clearValidate(i);
|
9731
9697
|
},
|
9732
|
-
validate(
|
9698
|
+
validate(i, s) {
|
9733
9699
|
var l;
|
9734
|
-
return (l = a.value) == null ? void 0 : l.validate(
|
9700
|
+
return (l = a.value) == null ? void 0 : l.validate(i, s);
|
9735
9701
|
}
|
9736
9702
|
}), () => createVNode(Form, mergeProps(o.value, {
|
9737
9703
|
ref: a
|
@@ -9932,11 +9898,11 @@ function useKgSubmit(e) {
|
|
9932
9898
|
return isFunction$2(m) ? (r.addEventListener(t.formID, "close", m), onUnmounted(() => r.removeEventListener(t.formID, "close", m)), () => r.removeEventListener(t.formID, "close", m)) : () => {
|
9933
9899
|
};
|
9934
9900
|
}
|
9935
|
-
function
|
9901
|
+
function i(m) {
|
9936
9902
|
return isFunction$2(m) ? (r.addEventListener(t.formID, "beforeOk", m), onUnmounted(() => r.removeEventListener(t.formID, "beforeOk", m)), () => r.removeEventListener(t.formID, "beforeOk", m)) : () => {
|
9937
9903
|
};
|
9938
9904
|
}
|
9939
|
-
function
|
9905
|
+
function s(m) {
|
9940
9906
|
return isFunction$2(m) ? (r.addEventListener(t.formID, "afterValidate", m), onUnmounted(() => r.removeEventListener(t.formID, "afterValidate", m)), () => r.removeEventListener(t.formID, "afterValidate", m)) : () => {
|
9941
9907
|
};
|
9942
9908
|
}
|
@@ -9990,8 +9956,8 @@ function useKgSubmit(e) {
|
|
9990
9956
|
rules: b,
|
9991
9957
|
displayType: c,
|
9992
9958
|
onOpen: a,
|
9993
|
-
onBeforeOk:
|
9994
|
-
onAfterValidate:
|
9959
|
+
onBeforeOk: i,
|
9960
|
+
onAfterValidate: s,
|
9995
9961
|
onBeforeRequest: l,
|
9996
9962
|
onOk: u,
|
9997
9963
|
onClose: o
|
@@ -10012,25 +9978,25 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10012
9978
|
emit: r,
|
10013
9979
|
attrs: n
|
10014
9980
|
}) {
|
10015
|
-
const a = useKg(), o = useKgVar(e.hostFormID),
|
10016
|
-
let
|
9981
|
+
const a = useKg(), o = useKgVar(e.hostFormID), i = useKgVar(FORM_ID__VAR_SUBMIT_CONFIG, !0, o.store.getFormLevel(o.formID) + 2);
|
9982
|
+
let s = null;
|
10017
9983
|
const l = useKgSubmit(FORM_ID__VAR_SUBMIT_CONFIG);
|
10018
9984
|
return l.onOpen(async ({
|
10019
9985
|
model: u
|
10020
9986
|
}) => {
|
10021
9987
|
const c = o.store.getVarSubmitConfig(o.formID);
|
10022
|
-
return
|
9988
|
+
return s = watch(u, (g) => {
|
10023
9989
|
var p, b, m, v, _, y, C, E, T, I, k, w;
|
10024
9990
|
g && (g.id = (p = c == null ? void 0 : c.id) != null ? p : null, g.frm_id = o.formID, g.resizable_flg = (b = c == null ? void 0 : c.resizable_flg) != null ? b : 1, g.fullscreen_flg = (m = c == null ? void 0 : c.fullscreen_flg) != null ? m : 1, g.dft_fullscreen_flg = (v = c == null ? void 0 : c.dft_fullscreen_flg) != null ? v : 0, g.responsive_flg = (_ = c == null ? void 0 : c.responsive_flg) != null ? _ : 1, g.max_width = (y = c == null ? void 0 : c.max_width) != null ? y : DEFAULT_MAX_WIDTH, g.min_width = (C = c == null ? void 0 : c.min_width) != null ? C : DEFAULT_MIN_WIDTH, g.dft_width = (E = c == null ? void 0 : c.dft_width) != null ? E : DEFAULT_WIDTH, g.layout = (T = c == null ? void 0 : c.layout) != null ? T : KG_VAR_SUBMIT__LAYOUT.VERTICAL, g.label_col = (I = c == null ? void 0 : c.label_col) != null ? I : DEFAULT_LABEL_COL_FOR_SPAN, g.label_col_unit = (k = c == null ? void 0 : c.label_col_unit) != null ? k : KG_WIDTH_UNIT.SPAN, g.display_type = (w = c == null ? void 0 : c.display_type) != null ? w : KG_VAR_SUBMIT__DISPLAY_TYPE.DRAWER);
|
10025
9991
|
}, {
|
10026
9992
|
immediate: !0
|
10027
9993
|
}), !1;
|
10028
|
-
}), l.onClose(async () => (
|
9994
|
+
}), l.onClose(async () => (s == null || s(), r("kgClose"), !1)), l.onBeforeOk(async ({
|
10029
9995
|
rules: u,
|
10030
9996
|
model: c
|
10031
9997
|
}) => (u.value = {}, c.value && c.value.label_col_unit === KG_WIDTH_UNIT.SPAN && !range$1(1, 25).includes(c.value.label_col) && (u.value.label_col = [{
|
10032
9998
|
validator: () => Promise.reject(a.t("kg.KgSubmitHeaderVarSubmitConfig.invalidWidthForSpan"))
|
10033
|
-
}]), !1)), l.onOk(async () => (o.store.retrieve(o.formID), !1)),
|
9999
|
+
}]), !1)), l.onOk(async () => (o.store.retrieve(o.formID), !1)), i.store.setIsUpdating(FORM_ID__VAR_SUBMIT_CONFIG, !0, !0), () => createVNode(KgSubmit, {
|
10034
10000
|
kgShowConfigButton: !1
|
10035
10001
|
}, null);
|
10036
10002
|
}
|
@@ -10060,7 +10026,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10060
10026
|
}) {
|
10061
10027
|
const a = useKgVar(), o = useKgSubmit();
|
10062
10028
|
useKgSubmit(FORM_ID__VAR_SUBMIT_CONFIG).onClose(async () => (c.value = !1, !1));
|
10063
|
-
const
|
10029
|
+
const s = computed(() => a.store.getVarSubmitConfig(a.formID)), l = computed(() => o.store.isLoading(a.formID)), u = computed(() => !!a.store.isCreatingRequesting(a.formID) || !!a.store.isUpdatingRequesting(a.formID) || !!a.store.isCopyingRequesting(a.formID)), c = ref(!1);
|
10064
10030
|
function g() {
|
10065
10031
|
r("update:isFullscreen", !e.isFullscreen);
|
10066
10032
|
}
|
@@ -10072,7 +10038,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10072
10038
|
}
|
10073
10039
|
function m() {
|
10074
10040
|
var y;
|
10075
|
-
return e.kgShowFullscreenButton === !1 || ((y =
|
10041
|
+
return e.kgShowFullscreenButton === !1 || ((y = s.value) == null ? void 0 : y.fullscreen_flg) === 0 ? null : createVNode(Button, {
|
10076
10042
|
onClick: g,
|
10077
10043
|
class: "kg-submit--btn-fullscreen"
|
10078
10044
|
}, {
|
@@ -10103,7 +10069,7 @@ const KgSubmit_Header = "", FORM_ID__VAR_SUBMIT_CONFIG = "kg-submit.VarSubmitCon
|
|
10103
10069
|
}
|
10104
10070
|
}), 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;
|
10105
10071
|
function _useFormModel() {
|
10106
|
-
const e = inject("$dayjs", dayjs), t = useKgVar(), r = useKgTable(), n = useKgSubmit(), a = computed(() => t.store.getVarSubmitFieldsForCreate(t.formID)), o = computed(() => t.store.getVarSubmitFieldsForUpdate(t.formID)),
|
10072
|
+
const e = inject("$dayjs", dayjs), t = useKgVar(), r = useKgTable(), n = useKgSubmit(), a = computed(() => t.store.getVarSubmitFieldsForCreate(t.formID)), o = computed(() => t.store.getVarSubmitFieldsForUpdate(t.formID)), i = computed(() => t.store.getVarSubmitFieldsForCopy(t.formID)), s = computed(() => t.store.getVarSubmitFieldsForDelete(t.formID)), l = computed(() => {
|
10107
10073
|
var c, g, p, b;
|
10108
10074
|
switch (!0) {
|
10109
10075
|
case t.isCreating.value:
|
@@ -10111,9 +10077,9 @@ function _useFormModel() {
|
|
10111
10077
|
case t.isUpdating.value:
|
10112
10078
|
return (g = o.value) != null ? g : [];
|
10113
10079
|
case t.isCopying.value:
|
10114
|
-
return (p =
|
10080
|
+
return (p = i.value) != null ? p : [];
|
10115
10081
|
case t.isDeleting.value:
|
10116
|
-
return (b =
|
10082
|
+
return (b = s.value) != null ? b : [];
|
10117
10083
|
}
|
10118
10084
|
return [];
|
10119
10085
|
}), u = ref({});
|
@@ -10150,23 +10116,23 @@ function _useResizeObserver$1(e) {
|
|
10150
10116
|
let t = null;
|
10151
10117
|
return watch(e, (r) => {
|
10152
10118
|
r && (t = new ResizeObserver((n) => {
|
10153
|
-
var o,
|
10154
|
-
const a = (
|
10119
|
+
var o, i;
|
10120
|
+
const a = (i = (o = n[0].borderBoxSize[0]) == null ? void 0 : o.inlineSize) != null ? i : 0;
|
10155
10121
|
switch (!0) {
|
10156
10122
|
case a < 570:
|
10157
|
-
r.classList.remove(...[2, 3, 4, 5].map((
|
10123
|
+
r.classList.remove(...[2, 3, 4, 5].map((s) => `kg-submit--col-${s}`)), r.classList.add("kg-submit--col-1");
|
10158
10124
|
break;
|
10159
10125
|
case (a >= 570 && a < 864):
|
10160
|
-
r.classList.remove(...[1, 3, 4, 5].map((
|
10126
|
+
r.classList.remove(...[1, 3, 4, 5].map((s) => `kg-submit--col-${s}`)), r.classList.add("kg-submit--col-2");
|
10161
10127
|
break;
|
10162
10128
|
case (a >= 864 && a < 1158):
|
10163
|
-
r.classList.remove(...[1, 2, 4, 5].map((
|
10129
|
+
r.classList.remove(...[1, 2, 4, 5].map((s) => `kg-submit--col-${s}`)), r.classList.add("kg-submit--col-3");
|
10164
10130
|
break;
|
10165
10131
|
case (a >= 1158 && a < 1452):
|
10166
|
-
r.classList.remove(...[1, 2, 3, 5].map((
|
10132
|
+
r.classList.remove(...[1, 2, 3, 5].map((s) => `kg-submit--col-${s}`)), r.classList.add("kg-submit--col-4");
|
10167
10133
|
break;
|
10168
10134
|
case a >= 1452:
|
10169
|
-
r.classList.remove(...[1, 2, 3, 4].map((
|
10135
|
+
r.classList.remove(...[1, 2, 3, 4].map((s) => `kg-submit--col-${s}`)), r.classList.add("kg-submit--col-5");
|
10170
10136
|
break;
|
10171
10137
|
}
|
10172
10138
|
}), t.observe(r));
|
@@ -10180,10 +10146,10 @@ function _useTitle() {
|
|
10180
10146
|
const e = useKg(), t = useKgVar(), r = computed(() => t.store.getVarButtonCreate(t.formID)), n = computed(() => t.store.getVarButtonUpdate(t.formID)), a = computed(() => t.store.getVarButtonCopy(t.formID)), o = computed(() => t.store.getVarButtonDelete(t.formID));
|
10181
10147
|
return {
|
10182
10148
|
title: computed(() => {
|
10183
|
-
var
|
10149
|
+
var s, l, u, c;
|
10184
10150
|
switch (!0) {
|
10185
10151
|
case t.isCreating.value: {
|
10186
|
-
const g = (
|
10152
|
+
const g = (s = r.value) == null ? void 0 : s.var_nam, p = t.t(g).value;
|
10187
10153
|
return g === p ? e.t("kg.create") : p;
|
10188
10154
|
}
|
10189
10155
|
case t.isUpdating.value: {
|
@@ -10208,8 +10174,8 @@ function _useClass(e, t) {
|
|
10208
10174
|
return {
|
10209
10175
|
getClass: computed(() => {
|
10210
10176
|
var l, u, c;
|
10211
|
-
let
|
10212
|
-
return t.isFullscreen && (
|
10177
|
+
let s = "kg-submit";
|
10178
|
+
return t.isFullscreen && (s += " kg-submit--fullscreen"), ((l = a.value) == null ? void 0 : l.responsive_flg) !== 0 && (s += " kg-submit--responsive"), n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? s += " kg-submit--modal" : n.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (s += " kg-submit--table"), r.isDeleting.value && ((c = (u = o.value) == null ? void 0 : u.length) != null ? c : 0) === 0 && (s += " kg-submit--delete-message"), e.kgClass && (s += ` ${e.kgClass}`), s;
|
10213
10179
|
})
|
10214
10180
|
};
|
10215
10181
|
}
|
@@ -10219,15 +10185,15 @@ function _useLayout() {
|
|
10219
10185
|
getLayout: computed(() => {
|
10220
10186
|
var u, c, g, p, b;
|
10221
10187
|
let n = "vertical";
|
10222
|
-
const a = (u = t.value) == null ? void 0 : u.layout, o = (c = t.value) == null ? void 0 : c.crt_layout,
|
10188
|
+
const a = (u = t.value) == null ? void 0 : u.layout, o = (c = t.value) == null ? void 0 : c.crt_layout, i = (g = t.value) == null ? void 0 : g.upt_layout, s = (p = t.value) == null ? void 0 : p.cpy_layout, l = (b = t.value) == null ? void 0 : b.del_layout;
|
10223
10189
|
switch (!0) {
|
10224
10190
|
case (e.isCreating.value && (o === "horizontal" || !o && a === "horizontal")):
|
10225
10191
|
n = "horizontal";
|
10226
10192
|
break;
|
10227
|
-
case (e.isUpdating.value && (
|
10193
|
+
case (e.isUpdating.value && (i === "horizontal" || !i && a === "horizontal")):
|
10228
10194
|
n = "horizontal";
|
10229
10195
|
break;
|
10230
|
-
case (e.isCopying.value && (
|
10196
|
+
case (e.isCopying.value && (s === "horizontal" || !s && a === "horizontal")):
|
10231
10197
|
n = "horizontal";
|
10232
10198
|
break;
|
10233
10199
|
case (e.isDeleting.value && (l === "horizontal" || !l && a === "horizontal")):
|
@@ -10245,7 +10211,7 @@ function _useDefaultWidth() {
|
|
10245
10211
|
var u, c, g, p, b;
|
10246
10212
|
if (!t.value)
|
10247
10213
|
return 0;
|
10248
|
-
const n = (u = t.value) == null ? void 0 : u.dft_width, a = (c = t.value) == null ? void 0 : c.crt_dft_width, o = (g = t.value) == null ? void 0 : g.upt_dft_width,
|
10214
|
+
const n = (u = t.value) == null ? void 0 : u.dft_width, a = (c = t.value) == null ? void 0 : c.crt_dft_width, o = (g = t.value) == null ? void 0 : g.upt_dft_width, i = (p = t.value) == null ? void 0 : p.cpy_dft_width, s = (b = t.value) == null ? void 0 : b.del_dft_width;
|
10249
10215
|
let l = n || DEFAULT_WIDTH;
|
10250
10216
|
switch (!0) {
|
10251
10217
|
case (e.isCreating.value && !!a):
|
@@ -10254,12 +10220,12 @@ function _useDefaultWidth() {
|
|
10254
10220
|
case (e.isUpdating.value && !!o):
|
10255
10221
|
l = o;
|
10256
10222
|
break;
|
10257
|
-
case (e.isCopying.value && !!
|
10258
|
-
l = s;
|
10259
|
-
break;
|
10260
|
-
case (e.isDeleting.value && !!i):
|
10223
|
+
case (e.isCopying.value && !!i):
|
10261
10224
|
l = i;
|
10262
10225
|
break;
|
10226
|
+
case (e.isDeleting.value && !!s):
|
10227
|
+
l = s;
|
10228
|
+
break;
|
10263
10229
|
}
|
10264
10230
|
return l;
|
10265
10231
|
})
|
@@ -10281,11 +10247,11 @@ const getProps$n = () => ({
|
|
10281
10247
|
setup(e, {
|
10282
10248
|
attrs: t
|
10283
10249
|
}) {
|
10284
|
-
const r = inject("$dayjs", dayjs), n = useKg(), a = useKgVar(), o = useKgButton(),
|
10250
|
+
const r = inject("$dayjs", dayjs), n = useKg(), a = useKgVar(), o = useKgButton(), i = useKgTable(), s = useKgSubmit(), l = useKgSearch();
|
10285
10251
|
o.onSubmitSave(async () => (await Z(), !1)), o.onSubmitCancel(async () => (await z(), !1));
|
10286
10252
|
const u = inject(DI_KG_SLOTS, null);
|
10287
10253
|
_useFormModel(), KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE;
|
10288
|
-
const c = computed(() => a.isDeleting.value && M.value.length === 0 && A.value.length === 0), g = computed(() => a.store.getVarButtonCreate(a.formID)), p = computed(() => a.store.getVarButtonUpdate(a.formID)), b = computed(() => a.store.getVarButtonCopy(a.formID)), m = computed(() => a.store.getVarButtonDelete(a.formID)), v = computed(() =>
|
10254
|
+
const c = computed(() => a.isDeleting.value && M.value.length === 0 && A.value.length === 0), g = computed(() => a.store.getVarButtonCreate(a.formID)), p = computed(() => a.store.getVarButtonUpdate(a.formID)), b = computed(() => a.store.getVarButtonCopy(a.formID)), m = computed(() => a.store.getVarButtonDelete(a.formID)), v = computed(() => s.store.isLoading(a.formID)), _ = computed(() => a.store.getVarSubmitConfig(a.formID)), y = computed(() => a.store.getVarSubmitFieldsForCreateKey(a.formID)), C = computed(() => a.store.getVarSubmitFieldsForCreateNotKey(a.formID)), E = computed(() => a.store.getVarSubmitFieldsForUpdateKey(a.formID)), T = computed(() => a.store.getVarSubmitFieldsForUpdateNotKey(a.formID)), I = computed(() => a.store.getVarSubmitFieldsForCopyKey(a.formID)), k = computed(() => a.store.getVarSubmitFieldsForCopyNotKey(a.formID)), w = computed(() => a.store.getVarSubmitFieldsForDelete(a.formID)), M = computed(() => {
|
10289
10255
|
var G, W, J;
|
10290
10256
|
switch (!0) {
|
10291
10257
|
case a.isCreating.value:
|
@@ -10378,14 +10344,14 @@ const getProps$n = () => ({
|
|
10378
10344
|
});
|
10379
10345
|
function K() {
|
10380
10346
|
var W;
|
10381
|
-
const G = watch(
|
10382
|
-
J && Object.keys(J).length > 0 && (setTimeout(() => G()),
|
10347
|
+
const G = watch(s.model, (J) => {
|
10348
|
+
J && Object.keys(J).length > 0 && (setTimeout(() => G()), s.store.emit(a.formID, "open", {
|
10383
10349
|
isCreating: a.isCreating.value,
|
10384
10350
|
isUpdating: a.isUpdating.value,
|
10385
10351
|
isCopying: a.isCopying.value,
|
10386
10352
|
isDeleting: a.isDeleting.value,
|
10387
|
-
row:
|
10388
|
-
model:
|
10353
|
+
row: i.selectedRow.value,
|
10354
|
+
model: s.model
|
10389
10355
|
}));
|
10390
10356
|
}, {
|
10391
10357
|
immediate: !0
|
@@ -10393,7 +10359,7 @@ const getProps$n = () => ({
|
|
10393
10359
|
((W = _.value) == null ? void 0 : W.dft_fullscreen_flg) === 1 && !c.value && (Y.isFullscreen = !0);
|
10394
10360
|
}
|
10395
10361
|
function U() {
|
10396
|
-
P.value.kgWidth = ee.value, Y.isFullscreen = !1,
|
10362
|
+
P.value.kgWidth = ee.value, Y.isFullscreen = !1, s.store.emit(a.formID, "close");
|
10397
10363
|
}
|
10398
10364
|
function z() {
|
10399
10365
|
switch (!0) {
|
@@ -10414,29 +10380,29 @@ const getProps$n = () => ({
|
|
10414
10380
|
async function Z() {
|
10415
10381
|
var G, W;
|
10416
10382
|
try {
|
10417
|
-
if (await
|
10383
|
+
if (await s.store.emit(a.formID, "beforeOk", {
|
10418
10384
|
isCreating: a.isCreating.value,
|
10419
10385
|
isUpdating: a.isUpdating.value,
|
10420
10386
|
isCopying: a.isCopying.value,
|
10421
10387
|
isDeleting: a.isDeleting.value,
|
10422
|
-
row:
|
10423
|
-
rules:
|
10424
|
-
model:
|
10388
|
+
row: i.selectedRow.value,
|
10389
|
+
rules: s.rules,
|
10390
|
+
model: s.model
|
10425
10391
|
}))
|
10426
10392
|
return;
|
10427
10393
|
try {
|
10428
|
-
await ((G =
|
10394
|
+
await ((G = s.formRef.value) == null ? void 0 : G.validate());
|
10429
10395
|
} catch (ae) {
|
10430
10396
|
KgUtil.throwIfNotFormError(ae);
|
10431
10397
|
}
|
10432
|
-
if (await ((W =
|
10398
|
+
if (await ((W = s.formRef.value) == null ? void 0 : W.validate()), await s.store.emit(a.formID, "afterValidate", {
|
10433
10399
|
isCreating: a.isCreating.value,
|
10434
10400
|
isUpdating: a.isUpdating.value,
|
10435
10401
|
isCopying: a.isCopying.value,
|
10436
10402
|
isDeleting: a.isDeleting.value,
|
10437
|
-
row:
|
10438
|
-
rows:
|
10439
|
-
model:
|
10403
|
+
row: i.selectedRow.value,
|
10404
|
+
rows: i.selectedRows.value,
|
10405
|
+
model: s.model
|
10440
10406
|
}))
|
10441
10407
|
return;
|
10442
10408
|
switch (!0) {
|
@@ -10458,7 +10424,7 @@ const getProps$n = () => ({
|
|
10458
10424
|
}
|
10459
10425
|
}
|
10460
10426
|
async function X() {
|
10461
|
-
var W, J, re, ae, oe,
|
10427
|
+
var W, J, re, ae, oe, ie, se, le;
|
10462
10428
|
const G = (W = g.value) == null ? void 0 : W.cmd;
|
10463
10429
|
if (!G) {
|
10464
10430
|
Logger.error("[KgSubmit] '\u521B\u5EFA\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -10468,15 +10434,15 @@ const getProps$n = () => ({
|
|
10468
10434
|
}
|
10469
10435
|
a.store.setIsCreatingRequesting(a.formID, !0);
|
10470
10436
|
try {
|
10471
|
-
let te = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (J = g.value) == null ? void 0 : J.cmd_prm) != null ? re : ""), a.formID, r)), ue = ref(KgUtil.parseParams(toRaw(
|
10472
|
-
if (await
|
10437
|
+
let te = ref(KgUtil.parseParams(KgVarUtil.parseCommandParameter((re = (J = g.value) == null ? void 0 : J.cmd_prm) != null ? re : ""), a.formID, r)), ue = ref(KgUtil.parseParams(toRaw(s.model.value), a.formID, r));
|
10438
|
+
if (await s.store.emit(a.formID, "beforeRequest", {
|
10473
10439
|
isCreating: a.isCreating.value,
|
10474
10440
|
isUpdating: a.isUpdating.value,
|
10475
10441
|
isCopying: a.isCopying.value,
|
10476
10442
|
isDeleting: a.isDeleting.value,
|
10477
|
-
row:
|
10478
|
-
rows:
|
10479
|
-
model:
|
10443
|
+
row: i.selectedFirstRow.value,
|
10444
|
+
rows: i.selectedRows.value,
|
10445
|
+
model: s.model,
|
10480
10446
|
params: te,
|
10481
10447
|
data: ue
|
10482
10448
|
}))
|
@@ -10486,7 +10452,7 @@ const getProps$n = () => ({
|
|
10486
10452
|
url: G,
|
10487
10453
|
params: te.value,
|
10488
10454
|
data: ue.value
|
10489
|
-
}), ((
|
10455
|
+
}), ((ie = g.value) == null ? void 0 : ie.show_success_message_flg) !== 0 && message.success(N.title.value + n.t("kg.succeed")), s.store.emit(a.formID, "ok"), a.store.setIsCreating(a.formID, !1), (le = (se = l.search).value) == null || le.call(se, !0);
|
10490
10456
|
} catch (te) {
|
10491
10457
|
console.error(te);
|
10492
10458
|
} finally {
|
@@ -10494,7 +10460,7 @@ const getProps$n = () => ({
|
|
10494
10460
|
}
|
10495
10461
|
}
|
10496
10462
|
async function de() {
|
10497
|
-
var W, J, re, ae, oe,
|
10463
|
+
var W, J, re, ae, oe, ie, se, le;
|
10498
10464
|
const G = (W = p.value) == null ? void 0 : W.cmd;
|
10499
10465
|
if (!G) {
|
10500
10466
|
Logger.error("[KgSubmit] '\u66F4\u65B0\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -10504,15 +10470,15 @@ const getProps$n = () => ({
|
|
10504
10470
|
}
|
10505
10471
|
try {
|
10506
10472
|
a.store.setIsUpdatingRequesting(a.formID, !0);
|
10507
|
-
let te = ref(KgVarUtil.parseCommandParameter((re = (J = p.value) == null ? void 0 : J.cmd_prm) != null ? re : "")), ue = ref(toRaw(
|
10508
|
-
if (await
|
10473
|
+
let te = ref(KgVarUtil.parseCommandParameter((re = (J = p.value) == null ? void 0 : J.cmd_prm) != null ? re : "")), ue = ref(toRaw(s.model.value));
|
10474
|
+
if (await s.store.emit(a.formID, "beforeRequest", {
|
10509
10475
|
isCreating: a.isCreating.value,
|
10510
10476
|
isUpdating: a.isUpdating.value,
|
10511
10477
|
isCopying: a.isCopying.value,
|
10512
10478
|
isDeleting: a.isDeleting.value,
|
10513
|
-
row:
|
10514
|
-
rows:
|
10515
|
-
model:
|
10479
|
+
row: i.selectedRow.value,
|
10480
|
+
rows: i.selectedRows.value,
|
10481
|
+
model: s.model,
|
10516
10482
|
params: te,
|
10517
10483
|
data: ue
|
10518
10484
|
}))
|
@@ -10522,7 +10488,7 @@ const getProps$n = () => ({
|
|
10522
10488
|
url: G,
|
10523
10489
|
params: te.value,
|
10524
10490
|
data: ue.value
|
10525
|
-
}), ((
|
10491
|
+
}), ((ie = p.value) == null ? void 0 : ie.show_success_message_flg) !== 0 && message.success(n.t("kg.updateSuccess")), s.store.emit(a.formID, "ok"), a.store.setIsUpdating(a.formID, !1), (le = (se = l.search).value) == null || le.call(se);
|
10526
10492
|
} catch (te) {
|
10527
10493
|
console.error(te);
|
10528
10494
|
} finally {
|
@@ -10530,7 +10496,7 @@ const getProps$n = () => ({
|
|
10530
10496
|
}
|
10531
10497
|
}
|
10532
10498
|
async function pe() {
|
10533
|
-
var W, J, re, ae, oe,
|
10499
|
+
var W, J, re, ae, oe, ie, se, le, te, ue;
|
10534
10500
|
const G = (W = b.value) == null ? void 0 : W.cmd;
|
10535
10501
|
if (!G) {
|
10536
10502
|
Logger.error("[KgSubmit] '\u590D\u5236\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -10541,27 +10507,27 @@ const getProps$n = () => ({
|
|
10541
10507
|
try {
|
10542
10508
|
a.store.setIsCopyingRequesting(a.formID, !0);
|
10543
10509
|
let ge = ref(KgVarUtil.parseCommandParameter((re = (J = b.value) == null ? void 0 : J.cmd_prm) != null ? re : "")), fe = ref({
|
10544
|
-
...(ae =
|
10545
|
-
...toRaw(
|
10510
|
+
...(ae = i.selectedFirstRow.value) != null ? ae : {},
|
10511
|
+
...toRaw(s.model.value)
|
10546
10512
|
});
|
10547
|
-
if (((oe = _.value) == null ? void 0 : oe.cpy_clear_id_flg) !== 0 && delete fe.value.id, await
|
10513
|
+
if (((oe = _.value) == null ? void 0 : oe.cpy_clear_id_flg) !== 0 && delete fe.value.id, await s.store.emit(a.formID, "beforeRequest", {
|
10548
10514
|
isCreating: a.isCreating.value,
|
10549
10515
|
isUpdating: a.isUpdating.value,
|
10550
10516
|
isCopying: a.isCopying.value,
|
10551
10517
|
isDeleting: a.isDeleting.value,
|
10552
|
-
row:
|
10553
|
-
rows:
|
10554
|
-
model:
|
10518
|
+
row: i.selectedRow.value,
|
10519
|
+
rows: i.selectedRows.value,
|
10520
|
+
model: s.model,
|
10555
10521
|
params: ge,
|
10556
10522
|
data: fe
|
10557
10523
|
}))
|
10558
10524
|
return;
|
10559
10525
|
await httpClient().request({
|
10560
|
-
method: (
|
10526
|
+
method: (se = (ie = b.value) == null ? void 0 : ie.cmd_method) != null ? se : "POST",
|
10561
10527
|
url: G,
|
10562
10528
|
params: ge.value,
|
10563
10529
|
data: fe.value
|
10564
|
-
}), ((le = b.value) == null ? void 0 : le.show_success_message_flg) !== 0 && message.success(n.t("kg.copySuccess")),
|
10530
|
+
}), ((le = b.value) == null ? void 0 : le.show_success_message_flg) !== 0 && message.success(n.t("kg.copySuccess")), s.store.emit(a.formID, "ok"), a.store.setIsCopying(a.formID, !1), (ue = (te = l.search).value) == null || ue.call(te, !0);
|
10565
10531
|
} catch (ge) {
|
10566
10532
|
console.error(ge);
|
10567
10533
|
} finally {
|
@@ -10569,7 +10535,7 @@ const getProps$n = () => ({
|
|
10569
10535
|
}
|
10570
10536
|
}
|
10571
10537
|
async function be() {
|
10572
|
-
var W, J, re, ae, oe,
|
10538
|
+
var W, J, re, ae, oe, ie, se, le;
|
10573
10539
|
const G = (W = m.value) == null ? void 0 : W.cmd;
|
10574
10540
|
if (!G) {
|
10575
10541
|
Logger.error("[KgSubmit] '\u5220\u9664\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
@@ -10580,19 +10546,19 @@ const getProps$n = () => ({
|
|
10580
10546
|
try {
|
10581
10547
|
a.store.setIsDeletingRequesting(a.formID, !0);
|
10582
10548
|
let te = ref({
|
10583
|
-
ids: (re = (J =
|
10549
|
+
ids: (re = (J = i.selectedRows.value) == null ? void 0 : J.map((fe) => {
|
10584
10550
|
var me, _e, ve;
|
10585
10551
|
return (ve = fe[(_e = (me = m.value) == null ? void 0 : me.del_param_clm) != null ? _e : "id"]) != null ? ve : "";
|
10586
10552
|
})) != null ? re : []
|
10587
10553
|
}), ue = ref({});
|
10588
|
-
if (await
|
10554
|
+
if (await s.store.emit(a.formID, "beforeRequest", {
|
10589
10555
|
isCreating: a.isCreating.value,
|
10590
10556
|
isUpdating: a.isUpdating.value,
|
10591
10557
|
isCopying: a.isCopying.value,
|
10592
10558
|
isDeleting: a.isDeleting.value,
|
10593
|
-
row:
|
10594
|
-
rows:
|
10595
|
-
model:
|
10559
|
+
row: i.selectedFirstRow.value,
|
10560
|
+
rows: i.selectedRows.value,
|
10561
|
+
model: s.model,
|
10596
10562
|
params: te,
|
10597
10563
|
data: ue
|
10598
10564
|
}))
|
@@ -10604,7 +10570,7 @@ const getProps$n = () => ({
|
|
10604
10570
|
data: ue.value
|
10605
10571
|
}, {
|
10606
10572
|
joinParamsToUrl: !0
|
10607
|
-
}), ((
|
10573
|
+
}), ((ie = m.value) == null ? void 0 : ie.show_success_message_flg) !== 0 && message.success(n.t("kg.deleteSuccess")), s.store.emit(a.formID, "ok"), a.store.setIsDeleting(a.formID, !1), (le = (se = l.search).value) == null || le.call(se, !0);
|
10608
10574
|
} catch (te) {
|
10609
10575
|
console.error(te);
|
10610
10576
|
} finally {
|
@@ -10617,35 +10583,35 @@ const getProps$n = () => ({
|
|
10617
10583
|
return isFunction$2(W) ? createVNode(KgForm.Item, {
|
10618
10584
|
kgVarName: G.var_nam,
|
10619
10585
|
kgContext: KG_FORM_CONTEXT.SUBMIT,
|
10620
|
-
kgRules:
|
10586
|
+
kgRules: s.rules.value[G.var_nam],
|
10621
10587
|
onKgSubmit: Z
|
10622
10588
|
}, {
|
10623
10589
|
control: ({
|
10624
10590
|
varName: ae,
|
10625
10591
|
props: oe,
|
10626
|
-
model:
|
10627
|
-
varConfig:
|
10592
|
+
model: ie,
|
10593
|
+
varConfig: se,
|
10628
10594
|
varProfileDetail: le,
|
10629
10595
|
varSubmitField: te
|
10630
10596
|
}) => W({
|
10631
10597
|
varName: ae,
|
10632
10598
|
props: oe,
|
10633
|
-
model:
|
10634
|
-
varConfig:
|
10599
|
+
model: ie,
|
10600
|
+
varConfig: se,
|
10635
10601
|
varProfileDetail: le,
|
10636
10602
|
varSubmitField: te
|
10637
10603
|
})
|
10638
10604
|
}) : createVNode(KgForm.Item, {
|
10639
10605
|
kgVarName: G.var_nam,
|
10640
10606
|
kgContext: KG_FORM_CONTEXT.SUBMIT,
|
10641
|
-
kgRules:
|
10607
|
+
kgRules: s.rules.value[G.var_nam],
|
10642
10608
|
onKgSubmit: Z
|
10643
10609
|
}, null);
|
10644
10610
|
}
|
10645
10611
|
function ye() {
|
10646
10612
|
let G, W;
|
10647
10613
|
return createVNode(KgResizable, {
|
10648
|
-
kgType:
|
10614
|
+
kgType: s.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.MODAL ? "right" : "left",
|
10649
10615
|
kgMinWidth: V.value,
|
10650
10616
|
kgMaxWidth: R.value,
|
10651
10617
|
kgWidth: L.value,
|
@@ -10656,8 +10622,8 @@ const getProps$n = () => ({
|
|
10656
10622
|
spinning: v.value
|
10657
10623
|
}, {
|
10658
10624
|
default: () => [createVNode(KgForm, {
|
10659
|
-
ref:
|
10660
|
-
model:
|
10625
|
+
ref: s.formRef,
|
10626
|
+
model: s.model.value,
|
10661
10627
|
layout: ne.value,
|
10662
10628
|
labelCol: ce.value,
|
10663
10629
|
wrapperCol: F.value
|
@@ -10713,7 +10679,7 @@ const getProps$n = () => ({
|
|
10713
10679
|
}, null);
|
10714
10680
|
}
|
10715
10681
|
return onUnmounted(() => {
|
10716
|
-
|
10682
|
+
s.store.dispose(a.formID);
|
10717
10683
|
}), () => createVNode(Drawer, {
|
10718
10684
|
visible: q.value,
|
10719
10685
|
placement: "right",
|
@@ -10886,7 +10852,7 @@ function useKgTable(e) {
|
|
10886
10852
|
return isFunction$2(y) ? (r.addEventListener(t.formID, "retrieve", y), onUnmounted(() => r.removeEventListener(t.formID, "retrieve", y)), () => r.removeEventListener(t.formID, "retrieve", y)) : () => {
|
10887
10853
|
};
|
10888
10854
|
}
|
10889
|
-
const o = computed(() => r.getIsRetrieving(t.formID)),
|
10855
|
+
const o = computed(() => r.getIsRetrieving(t.formID)), i = computed(() => r.getSelectedRows(t.formID)), s = computed(() => r.getSelectedFirstRow(t.formID)), l = computed(() => r.getSelectedRow(t.formID)), u = computed(() => {
|
10890
10856
|
var y;
|
10891
10857
|
return ((y = t.varGridConfig.value) == null ? void 0 : y.mult_flg) === 1;
|
10892
10858
|
}), c = computed(() => {
|
@@ -10915,8 +10881,8 @@ function useKgTable(e) {
|
|
10915
10881
|
formID: t.formID,
|
10916
10882
|
store: r,
|
10917
10883
|
isRetrieving: o,
|
10918
|
-
selectedRows:
|
10919
|
-
selectedFirstRow:
|
10884
|
+
selectedRows: i,
|
10885
|
+
selectedFirstRow: s,
|
10920
10886
|
selectedRow: l,
|
10921
10887
|
isMultiSelect: u,
|
10922
10888
|
isReadAutomatically: c,
|
@@ -10943,7 +10909,7 @@ const KG_TABLE_TD_DEFAULT_WIDTH = 120, KG_TABLE_TD_MIN_WIDTH = 80, KG_TABLE_TD_M
|
|
10943
10909
|
slots: t,
|
10944
10910
|
emit: r
|
10945
10911
|
}) {
|
10946
|
-
const n = useKg(), a = useKgVar(), o = useKgButton(),
|
10912
|
+
const n = useKg(), a = useKgVar(), o = useKgButton(), i = useKgSubmit(), s = useKgTable();
|
10947
10913
|
o.onSubmitSave(async () => {
|
10948
10914
|
var T;
|
10949
10915
|
try {
|
@@ -10955,10 +10921,10 @@ const KG_TABLE_TD_DEFAULT_WIDTH = 120, KG_TABLE_TD_MIN_WIDTH = 80, KG_TABLE_TD_M
|
|
10955
10921
|
});
|
10956
10922
|
const l = computed(() => e.kgVarName ? a.store.getVarGridDetail(a.formID, e.kgVarName) : null), u = computed(() => a.store.getVarSubmitField(a.formID, e.kgVarName)), c = computed(() => {
|
10957
10923
|
var T, I, k, w, M, A;
|
10958
|
-
return
|
10924
|
+
return i.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((T = e.kgRow) == null ? void 0 : T[s.id.value]) === ((I = s.selectedRow.value) == null ? void 0 : I[s.id.value]) && (!!a.isCreating.value && ((k = u.value) == null ? void 0 : k.crt_flg) === 1 || !!a.isUpdating.value && ((w = u.value) == null ? void 0 : w.upt_flg) === 1 || !!a.isCopying.value && ((M = u.value) == null ? void 0 : M.cpy_flg) === 1 || !!a.isDeleting.value && ((A = u.value) == null ? void 0 : A.del_flg) === 1);
|
10959
10925
|
}), g = computed(() => {
|
10960
10926
|
var T, I;
|
10961
|
-
return
|
10927
|
+
return i.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && ((T = e.kgRow) == null ? void 0 : T[s.id.value]) === ((I = s.selectedRow.value) == null ? void 0 : I[s.id.value]) && (!!a.isCreating.value && !!a.isCreatingRequesting.value || !!a.isUpdating.value && !!a.isUpdatingRequesting.value || !!a.isCopying.value && !!a.isCopyingRequesting.value || !!a.isDeleting.value && !!a.isDeletingRequesting.value);
|
10962
10928
|
}), p = computed(() => {
|
10963
10929
|
var I, k;
|
10964
10930
|
let T = "kg-table-td";
|
@@ -10994,7 +10960,7 @@ const KG_TABLE_TD_DEFAULT_WIDTH = 120, KG_TABLE_TD_MIN_WIDTH = 80, KG_TABLE_TD_M
|
|
10994
10960
|
function y() {
|
10995
10961
|
return createVNode(KgForm, {
|
10996
10962
|
ref: m,
|
10997
|
-
model:
|
10963
|
+
model: i.model.value,
|
10998
10964
|
layout: "vertical",
|
10999
10965
|
wrapperCol: {
|
11000
10966
|
span: 24
|
@@ -11004,7 +10970,7 @@ const KG_TABLE_TD_DEFAULT_WIDTH = 120, KG_TABLE_TD_MIN_WIDTH = 80, KG_TABLE_TD_M
|
|
11004
10970
|
default: () => [createVNode(KgForm.Item, {
|
11005
10971
|
kgVarName: e.kgVarName,
|
11006
10972
|
kgContext: KG_FORM_CONTEXT.SUBMIT,
|
11007
|
-
kgRules:
|
10973
|
+
kgRules: i.rules.value[e.kgVarName],
|
11008
10974
|
kgSpan: 24,
|
11009
10975
|
kgDisabled: g.value ? !0 : void 0,
|
11010
10976
|
onKgSubmit: _
|
@@ -11088,10 +11054,10 @@ const getProps$k = () => ({
|
|
11088
11054
|
}
|
11089
11055
|
function o() {
|
11090
11056
|
}
|
11091
|
-
function
|
11057
|
+
function i() {
|
11092
11058
|
}
|
11093
11059
|
return () => {
|
11094
|
-
let
|
11060
|
+
let s, l, u;
|
11095
11061
|
return createVNode("div", {
|
11096
11062
|
class: "kg-table-info"
|
11097
11063
|
}, [createVNode("div", {
|
@@ -11106,11 +11072,11 @@ const getProps$k = () => ({
|
|
11106
11072
|
onClick: a,
|
11107
11073
|
class: "btn-clear-check",
|
11108
11074
|
type: "link"
|
11109
|
-
}, _isSlot$6(
|
11110
|
-
default: () => [
|
11075
|
+
}, _isSlot$6(s = n.t("kg.KgTableInfo.clearCheck")) ? s : {
|
11076
|
+
default: () => [s]
|
11111
11077
|
}), e.kgShowLocate && createVNode(Button, {
|
11112
11078
|
disabled: e.kgDisabled,
|
11113
|
-
onClick:
|
11079
|
+
onClick: i,
|
11114
11080
|
class: "btn-locate-check",
|
11115
11081
|
type: "link"
|
11116
11082
|
}, _isSlot$6(l = n.t("kg.KgTableInfo.locate")) ? l : {
|
@@ -11141,19 +11107,19 @@ const getProps$k = () => ({
|
|
11141
11107
|
emit: r
|
11142
11108
|
}) {
|
11143
11109
|
const n = useKgVar(e.hostFormID), a = useKg(), o = useKgVar(FORM_ID__VAR_GRID_CONFIG, !0, n ? n.store.getFormLevel(n.formID) + 2 : 2);
|
11144
|
-
let
|
11145
|
-
const
|
11146
|
-
return
|
11110
|
+
let i = null;
|
11111
|
+
const s = useKgSubmit(FORM_ID__VAR_GRID_CONFIG);
|
11112
|
+
return s.onOpen(async ({
|
11147
11113
|
model: l
|
11148
11114
|
}) => {
|
11149
11115
|
const u = n == null ? void 0 : n.store.getVarGridConfig(n.formID);
|
11150
|
-
return
|
11116
|
+
return i = watch(l, (c) => {
|
11151
11117
|
var g, p, b, m, v, _, y, C, E, T, I;
|
11152
11118
|
c && (c.id = (g = u == null ? void 0 : u.id) != null ? g : null, c.frm_id = n == null ? void 0 : n.formID, c.aut_load_flg = (p = u == null ? void 0 : u.aut_load_flg) != null ? p : 0, c.mult_flg = (b = u == null ? void 0 : u.mult_flg) != null ? b : 0, c.show_check_column_flg = (m = u == null ? void 0 : u.show_check_column_flg) != null ? m : 0, c.show_bottom_left_flg = (v = u == null ? void 0 : u.show_bottom_left_flg) != null ? v : 1, c.show_bottom_right_flg = (_ = u == null ? void 0 : u.show_bottom_right_flg) != null ? _ : 1, c.convert_sort_field_to_under_score_flg = (y = u == null ? void 0 : u.convert_sort_field_to_under_score_flg) != null ? y : 0, c.pg_size_opts = (C = u == null ? void 0 : u.pg_size_opts) != null ? C : "[10, 20, 50, 100]", c.pg_size_opt = (E = u == null ? void 0 : u.pg_size_opt) != null ? E : 10, c.cmd_prm = (T = u == null ? void 0 : u.cmd_prm) != null ? T : void 0, c.button_display_type = (I = u == null ? void 0 : u.button_display_type) != null ? I : KG_BUTTON_DISPLAY_TYPE.DEFAULT);
|
11153
11119
|
}, {
|
11154
11120
|
immediate: !0
|
11155
11121
|
}), !1;
|
11156
|
-
}),
|
11122
|
+
}), s.onClose(async () => (i == null || i(), r("kgClose"), !1)), s.onBeforeOk(async ({
|
11157
11123
|
rules: l,
|
11158
11124
|
model: u
|
11159
11125
|
}) => {
|
@@ -11207,7 +11173,7 @@ const getProps$k = () => ({
|
|
11207
11173
|
}];
|
11208
11174
|
}
|
11209
11175
|
return await nextTick(), !1;
|
11210
|
-
}),
|
11176
|
+
}), s.onOk(async () => (n == null || n.store.retrieve(n.formID), !1)), o.store.setIsUpdating(FORM_ID__VAR_GRID_CONFIG, !0, !0), () => createVNode(KgSubmit, null, null);
|
11211
11177
|
}
|
11212
11178
|
}), KgTable_Setting_ConfigModal_VarGridMaster = "", FORM_ID__VAR_GRID_MASTER = "kg-table.VarGridMaster", getProps$i = () => ({
|
11213
11179
|
hostFormID: {
|
@@ -11297,11 +11263,11 @@ const getProps$k = () => ({
|
|
11297
11263
|
function _useServices() {
|
11298
11264
|
const e = useKgVar();
|
11299
11265
|
function t(r, n) {
|
11300
|
-
var o,
|
11266
|
+
var o, i, s, l;
|
11301
11267
|
if (!n)
|
11302
11268
|
return !0;
|
11303
11269
|
let a = n.toLowerCase();
|
11304
|
-
return !!((
|
11270
|
+
return !!((i = (o = e.t(r.var_nam).value) == null ? void 0 : o.toLowerCase()) != null && i.includes(a) || (l = (s = r.var_nam) == null ? void 0 : s.toLowerCase()) != null && l.includes(a));
|
11305
11271
|
}
|
11306
11272
|
return {
|
11307
11273
|
filterVarGridDetailByKey: t
|
@@ -11313,8 +11279,8 @@ function _useObserveMenuItemColumns(e) {
|
|
11313
11279
|
r ? (await nextTick(), setTimeout(() => {
|
11314
11280
|
const n = document.querySelector("div.kg-table-setting-submenu-popup-columns");
|
11315
11281
|
n && (t = new ResizeObserver(() => {
|
11316
|
-
var
|
11317
|
-
const a = (
|
11282
|
+
var i, s, l;
|
11283
|
+
const a = (s = (i = window.visualViewport) == null ? void 0 : i.height) != null ? s : 0, o = n.getBoundingClientRect().bottom;
|
11318
11284
|
if (o > a) {
|
11319
11285
|
const u = (l = n.parentElement) == null ? void 0 : l.parentElement;
|
11320
11286
|
u && (u.style.top = `${a - o}px`);
|
@@ -11336,13 +11302,13 @@ const FORM_ID__VAR_GRID_MASTER__SAVE = "kg-table.VarGridMaster.Save", KgTableSet
|
|
11336
11302
|
useKgVar(FORM_ID__VAR_GRID_MASTER__SAVE, !0, a.store.getFormLevel(a.formID) + 1);
|
11337
11303
|
const o = useKgSubmit(FORM_ID__VAR_GRID_MASTER__SAVE);
|
11338
11304
|
return o.onOpen(async ({
|
11339
|
-
model:
|
11305
|
+
model: i
|
11340
11306
|
}) => {
|
11341
|
-
var
|
11342
|
-
return
|
11307
|
+
var s, l, u, c, g, p, b, m, v, _;
|
11308
|
+
return i.value.grd_var_nam = `${(l = (s = a.currentVarGridMaster.value) == null ? void 0 : s.grd_var_nam) != null ? l : ""}_COPY`, i.value.frm_id = (c = (u = a.currentVarGridMaster.value) == null ? void 0 : u.frm_id) != null ? c : "", i.value.usr_id = (p = (g = a.currentVarGridMaster.value) == null ? void 0 : g.usr_id) != null ? p : "", i.value.grp_nam = (m = (b = a.currentVarGridMaster.value) == null ? void 0 : b.grp_nam) != null ? m : "", i.value.varGridDetails = (_ = (v = a.currentVarGridMaster.value) == null ? void 0 : v.varGridDetails) != null ? _ : [], !1;
|
11343
11309
|
}), o.onBeforeOk(async ({
|
11344
|
-
model:
|
11345
|
-
}) => (
|
11310
|
+
model: i
|
11311
|
+
}) => (i.value, !1)), o.onOk(async () => (a.store.retrieve(a.formID), !1)), () => createVNode(KgSubmit, null, null);
|
11346
11312
|
}
|
11347
11313
|
});
|
11348
11314
|
function _isSlot$5(e) {
|
@@ -11357,12 +11323,12 @@ const KgTableSetting = defineComponent({
|
|
11357
11323
|
const n = useKg(), a = useKgVar();
|
11358
11324
|
useKgSubmit(FORM_ID__VAR_GRID_MASTER__SAVE).onClose(async () => (p.value = !1, !1));
|
11359
11325
|
const {
|
11360
|
-
filterVarGridDetailByKey:
|
11361
|
-
} = _useServices(),
|
11326
|
+
filterVarGridDetailByKey: i
|
11327
|
+
} = _useServices(), s = ref(""), l = ref([]), u = computed(() => l.value.includes("1")), c = reactive({
|
11362
11328
|
visible: !1
|
11363
11329
|
}), g = computed(() => !!a.isCreating.value || !!a.isCreating.value || !!a.isCreating.value || !!a.isCreating.value), p = ref(!1);
|
11364
11330
|
_useObserveMenuItemColumns(u), watch(u, (E) => {
|
11365
|
-
E || (
|
11331
|
+
E || (s.value = "");
|
11366
11332
|
}, {
|
11367
11333
|
immediate: !0
|
11368
11334
|
});
|
@@ -11403,8 +11369,8 @@ const KgTableSetting = defineComponent({
|
|
11403
11369
|
return createVNode("div", {
|
11404
11370
|
class: "columns"
|
11405
11371
|
}, [createVNode(Input, {
|
11406
|
-
value:
|
11407
|
-
"onUpdate:value": (T) =>
|
11372
|
+
value: s.value,
|
11373
|
+
"onUpdate:value": (T) => s.value = T,
|
11408
11374
|
allowClear: !0
|
11409
11375
|
}, null), createVNode("ul", {
|
11410
11376
|
class: "ant-dropdown-menu ant-dropdown-menu-vertical"
|
@@ -11414,7 +11380,7 @@ const KgTableSetting = defineComponent({
|
|
11414
11380
|
I.preventDefault(), I.stopPropagation(), b(T);
|
11415
11381
|
},
|
11416
11382
|
style: {
|
11417
|
-
display:
|
11383
|
+
display: i(T, s.value) ? "flex" : "none"
|
11418
11384
|
},
|
11419
11385
|
"kg-var-nam": T.var_nam
|
11420
11386
|
}, [createVNode(Checkbox, {
|
@@ -11500,11 +11466,11 @@ const KgTableSetting = defineComponent({
|
|
11500
11466
|
});
|
11501
11467
|
function _useColumns() {
|
11502
11468
|
const e = useKgVar(), t = useKgSubmit(), r = useKgTable(), n = computed(() => {
|
11503
|
-
var
|
11504
|
-
return ((
|
11469
|
+
var i;
|
11470
|
+
return ((i = e.store.getVarGridConfig(e.formID)) == null ? void 0 : i.show_check_column_flg) === 1;
|
11505
11471
|
}), a = computed(() => {
|
11506
11472
|
var c, g, p;
|
11507
|
-
const
|
11473
|
+
const i = (c = r.store.getTableWidth(e.formID)) != null ? c : 0, s = (g = e.store.getCurrentVisibleVarGridDetailsTotalWidth(e.formID)) != null ? g : 0, l = e.store.getCurrentVisibleVarGridDetails(e.formID), u = [{
|
11508
11474
|
dataIndex: "index",
|
11509
11475
|
width: KG_TABLE_TD_INDEX_WIDTH,
|
11510
11476
|
fixed: "left",
|
@@ -11563,14 +11529,14 @@ function _useColumns() {
|
|
11563
11529
|
}
|
11564
11530
|
};
|
11565
11531
|
})) != null ? p : []];
|
11566
|
-
return (
|
11532
|
+
return (s === 0 || i > s && !(l != null && l.find((b) => b.width === "auto"))) && u.push({
|
11567
11533
|
width: "auto",
|
11568
11534
|
customRender: () => null
|
11569
11535
|
}), u;
|
11570
11536
|
}), o = computed(() => {
|
11571
|
-
var
|
11572
|
-
let
|
11573
|
-
return n.value && (
|
11537
|
+
var s;
|
11538
|
+
let i = 0;
|
11539
|
+
return n.value && (i += KG_TABLE_TD_CHECK_WIDTH), i += KG_TABLE_TD_INDEX_WIDTH, i += (s = e.store.getCurrentVisibleVarGridDetailsTotalWidth(e.formID)) != null ? s : 0, `${i}px`;
|
11574
11540
|
});
|
11575
11541
|
return {
|
11576
11542
|
columns: a,
|
@@ -11589,10 +11555,10 @@ function _useResizeObserver(e) {
|
|
11589
11555
|
return onMounted(() => {
|
11590
11556
|
var o;
|
11591
11557
|
const a = (o = e.value) == null ? void 0 : o.querySelector("div.ant-table-header");
|
11592
|
-
a && (n = new ResizeObserver((
|
11558
|
+
a && (n = new ResizeObserver((i) => {
|
11593
11559
|
var u, c, g, p;
|
11594
|
-
const
|
11595
|
-
r.store.setTableWidth(t.formID, Math.max(0,
|
11560
|
+
const s = (c = (u = i[0].borderBoxSize[0]) == null ? void 0 : u.inlineSize) != null ? c : 0, l = (p = (g = a.querySelector("th.ant-table-cell-scrollbar")) == null ? void 0 : g.clientWidth) != null ? p : 0;
|
11561
|
+
r.store.setTableWidth(t.formID, Math.max(0, s - l));
|
11596
11562
|
}), n.observe(a));
|
11597
11563
|
}), onUnmounted(() => {
|
11598
11564
|
n == null || n.disconnect();
|
@@ -11604,10 +11570,10 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11604
11570
|
slots: t,
|
11605
11571
|
emit: r
|
11606
11572
|
}) {
|
11607
|
-
const n = inject("$dayjs", dayjs), a = inject(DI_KG_SLOTS, null), o = useKg(),
|
11608
|
-
|
11573
|
+
const n = inject("$dayjs", dayjs), a = inject(DI_KG_SLOTS, null), o = useKg(), i = useKgVar(), s = useKgSearch(), l = useKgButton(), u = useKgTable(), c = useKgSubmit();
|
11574
|
+
s.onSearch((F) => {
|
11609
11575
|
R(F);
|
11610
|
-
}),
|
11576
|
+
}), s.onReset(() => {
|
11611
11577
|
R(!0);
|
11612
11578
|
}), u.store.$onAction(async ({
|
11613
11579
|
name: F,
|
@@ -11615,7 +11581,7 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11615
11581
|
}) => {
|
11616
11582
|
switch (F) {
|
11617
11583
|
case "setSelecte":
|
11618
|
-
if (K[0] ===
|
11584
|
+
if (K[0] === i.formID) {
|
11619
11585
|
const U = K[1], z = K[2];
|
11620
11586
|
switch (!0) {
|
11621
11587
|
case (z && !A.value.includes(U[u.id.value])):
|
@@ -11638,25 +11604,25 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11638
11604
|
_useResizeObserver(_);
|
11639
11605
|
const y = computed(() => {
|
11640
11606
|
var F, K;
|
11641
|
-
return (K = (F =
|
11607
|
+
return (K = (F = i.varButtonSearch.value) == null ? void 0 : F.cmd) != null ? K : null;
|
11642
11608
|
}), C = computed(() => {
|
11643
11609
|
var K, U, z, Z, X, de, pe;
|
11644
11610
|
let F = {
|
11645
11611
|
pageNo: O.pageIndex,
|
11646
11612
|
pageSize: O.pageSize,
|
11647
11613
|
...B,
|
11648
|
-
...(U = (K =
|
11614
|
+
...(U = (K = s.model) == null ? void 0 : K.value) != null ? U : {}
|
11649
11615
|
};
|
11650
|
-
return
|
11616
|
+
return i.varButtonSearch.value && (F = {
|
11651
11617
|
...F,
|
11652
|
-
...KgVarUtil.parseCommandParameter((Z = (z =
|
11653
|
-
}), (X =
|
11618
|
+
...KgVarUtil.parseCommandParameter((Z = (z = i.varButtonSearch.value) == null ? void 0 : z.cmd_prm) != null ? Z : "")
|
11619
|
+
}), (X = i.varGridConfig.value) != null && X.cmd_prm && (F = {
|
11654
11620
|
...F,
|
11655
|
-
...KgVarUtil.parseCommandParameter((de =
|
11656
|
-
}), ((pe =
|
11657
|
-
}), E = computed(() => v.value || !!
|
11621
|
+
...KgVarUtil.parseCommandParameter((de = i.varGridConfig.value.cmd_prm) != null ? de : "")
|
11622
|
+
}), ((pe = i.varGridConfig.value) == null ? void 0 : pe.convert_sort_field_to_under_score_flg) === 1 && F.column && (F.column = snakeCase$1(F.column)), F;
|
11623
|
+
}), E = computed(() => v.value || !!i.isCreating.value || !!i.isUpdating.value || !!i.isCopying.value || !!i.isDeleting.value || O.total === 0), T = computed(() => v.value || !!i.isCreating.value || !!i.isUpdating.value || !!i.isCopying.value || !!i.isDeleting.value), I = computed(() => {
|
11658
11624
|
var F;
|
11659
|
-
if (((F =
|
11625
|
+
if (((F = i.varGridConfig.value) == null ? void 0 : F.show_check_column_flg) === 1)
|
11660
11626
|
return {
|
11661
11627
|
fixed: "left",
|
11662
11628
|
columnWidth: KG_TABLE_TD_CHECK_WIDTH,
|
@@ -11664,7 +11630,7 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11664
11630
|
selectedRowKeys: A,
|
11665
11631
|
preserveSelectedRowKeys: !1,
|
11666
11632
|
getCheckboxProps: (K) => ({
|
11667
|
-
disabled: !!
|
11633
|
+
disabled: !!i.isCreating.value || !!i.isUpdating.value || !!i.isCopying.value || !!i.isDeleting.value
|
11668
11634
|
}),
|
11669
11635
|
onSelect: (K) => H(K),
|
11670
11636
|
onChange: (K) => u.isMultiSelect.value && L(K)
|
@@ -11672,11 +11638,11 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11672
11638
|
}), k = computed(() => {
|
11673
11639
|
var K;
|
11674
11640
|
let F = "kg-table";
|
11675
|
-
return ((K =
|
11641
|
+
return ((K = i.varGridConfig.value) == null ? void 0 : K.show_bottom_border_flg) === 1 && (F += " kg-table--bottom-border"), !u.isShowBottomLeft.value && !u.isShowBottomRight.value && (F += " kg-table--no-bottom"), c.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && (i.isCreating.value || i.isUpdating.value || i.isCopying.value || i.isDeleting.value) && (F += " kg-table--submitting"), F;
|
11676
11642
|
}), w = computed(() => {
|
11677
11643
|
var K;
|
11678
11644
|
let F = "kg-table-bottom";
|
11679
|
-
return ((K =
|
11645
|
+
return ((K = i.varGridConfig.value) == null ? void 0 : K.show_bottom_border_flg) === 1 && (F += " kg-table-bottom--border"), F;
|
11680
11646
|
}), M = ref([]), A = ref([]), O = reactive({
|
11681
11647
|
pageIndex: 1,
|
11682
11648
|
pageSize: 10,
|
@@ -11689,42 +11655,42 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11689
11655
|
});
|
11690
11656
|
watch(u.pageSizeOptions, (F) => {
|
11691
11657
|
F.length > 0 && !F.includes(O.pageSize) && (O.pageSize = u.pageSizeOption.value);
|
11692
|
-
}), watch([y, u.isReadAutomatically,
|
11693
|
-
F && K && U && !u.store.getIsRetrieved(
|
11658
|
+
}), watch([y, u.isReadAutomatically, s.isReady], ([F, K, U]) => {
|
11659
|
+
F && K && U && !u.store.getIsRetrieved(i.formID) && R(!0);
|
11694
11660
|
}, {
|
11695
11661
|
immediate: !0
|
11696
|
-
}), watch(
|
11662
|
+
}), watch(i.isCreating, (F, K) => {
|
11697
11663
|
F === !0 ? P() : F === !1 && K === !0 && D();
|
11698
11664
|
}), onUnmounted(() => {
|
11699
|
-
u.store.dispose(
|
11665
|
+
u.store.dispose(i.formID);
|
11700
11666
|
});
|
11701
11667
|
function P() {
|
11702
11668
|
if (c.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE) {
|
11703
11669
|
const F = {
|
11704
11670
|
[u.id.value]: ID_CREATE
|
11705
11671
|
};
|
11706
|
-
M.value = [F, ...M.value], A.value = [ID_CREATE], u.store.setSelectedRows(
|
11672
|
+
M.value = [F, ...M.value], A.value = [ID_CREATE], u.store.setSelectedRows(i.formID, [F]);
|
11707
11673
|
}
|
11708
11674
|
}
|
11709
11675
|
function D() {
|
11710
11676
|
const F = M.value.find((K) => K[u.id.value] === ID_CREATE);
|
11711
|
-
F && (M.value = without$1(M.value, F), A.value = [], u.store.setSelectedRows(
|
11677
|
+
F && (M.value = without$1(M.value, F), A.value = [], u.store.setSelectedRows(i.formID, []));
|
11712
11678
|
}
|
11713
11679
|
function V(F, K) {
|
11714
|
-
if (!(!!
|
11680
|
+
if (!(!!i.isCreating.value || !!i.isCreating.value || !!i.isCreating.value || !!i.isCreating.value) && !!I.value) {
|
11715
11681
|
if (!K) {
|
11716
|
-
A.value = [], u.store.setSelectedRows(
|
11682
|
+
A.value = [], u.store.setSelectedRows(i.formID, []);
|
11717
11683
|
return;
|
11718
11684
|
}
|
11719
11685
|
switch (F == null ? void 0 : F.detail) {
|
11720
11686
|
case 1:
|
11721
|
-
A.value = [K[u.id.value]], u.store.setSelectedRows(
|
11687
|
+
A.value = [K[u.id.value]], u.store.setSelectedRows(i.formID, A.value.map((U) => {
|
11722
11688
|
var z;
|
11723
11689
|
return (z = M.value) == null ? void 0 : z.find((Z) => Z[u.id.value] === U);
|
11724
11690
|
}).filter((U) => !!U));
|
11725
11691
|
break;
|
11726
11692
|
case 2:
|
11727
|
-
u.store.emit(
|
11693
|
+
u.store.emit(i.formID, "rowDoubleClick", K);
|
11728
11694
|
break;
|
11729
11695
|
}
|
11730
11696
|
}
|
@@ -11739,11 +11705,11 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11739
11705
|
var z, Z;
|
11740
11706
|
if (!y.value) {
|
11741
11707
|
Logger.error("[KgTable] '\u67E5\u8BE2\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
11742
|
-
VarButton:
|
11708
|
+
VarButton: i.varButtonSearch.value
|
11743
11709
|
});
|
11744
11710
|
return;
|
11745
11711
|
}
|
11746
|
-
F && (O.pageIndex = 1), u.store.setIsRetrieving(
|
11712
|
+
F && (O.pageIndex = 1), u.store.setIsRetrieving(i.formID, !0);
|
11747
11713
|
try {
|
11748
11714
|
const X = await httpClient().request({
|
11749
11715
|
method: "GET",
|
@@ -11763,19 +11729,19 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11763
11729
|
M.value = (z = X.records) != null ? z : [], O.total = (Z = X.total) != null ? Z : 0;
|
11764
11730
|
break;
|
11765
11731
|
}
|
11766
|
-
u.store.emit(
|
11732
|
+
u.store.emit(i.formID, "retrieve", {
|
11767
11733
|
page: X,
|
11768
11734
|
datas: M
|
11769
|
-
}), V(), p.value = [], await nextTick(), u.store.setIsRetrieved(
|
11735
|
+
}), V(), p.value = [], await nextTick(), u.store.setIsRetrieved(i.formID, !0);
|
11770
11736
|
} catch (X) {
|
11771
11737
|
throw X;
|
11772
11738
|
} finally {
|
11773
|
-
u.store.setIsRetrieving(
|
11739
|
+
u.store.setIsRetrieving(i.formID, !1);
|
11774
11740
|
}
|
11775
11741
|
}
|
11776
11742
|
}
|
11777
11743
|
function L(F) {
|
11778
|
-
A.value = F, u.store.setSelectedRows(
|
11744
|
+
A.value = F, u.store.setSelectedRows(i.formID, A.value.map((K) => {
|
11779
11745
|
var U;
|
11780
11746
|
return (U = M.value) == null ? void 0 : U.find((z) => z[u.id.value] === K);
|
11781
11747
|
}).filter((K) => !!K));
|
@@ -11796,13 +11762,13 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11796
11762
|
}
|
11797
11763
|
break;
|
11798
11764
|
}
|
11799
|
-
u.store.setSelectedRows(
|
11765
|
+
u.store.setSelectedRows(i.formID, A.value.map((z) => {
|
11800
11766
|
var Z;
|
11801
11767
|
return (Z = M.value) == null ? void 0 : Z.find((X) => X[u.id.value] === z);
|
11802
11768
|
}).filter((z) => !!z));
|
11803
11769
|
}
|
11804
11770
|
function N(F, K) {
|
11805
|
-
K.width = F,
|
11771
|
+
K.width = F, i.store.setVarGridDetailWidth(i.formID, K.dataIndex, F);
|
11806
11772
|
}
|
11807
11773
|
async function x(F, K, U, z) {
|
11808
11774
|
var Z;
|
@@ -11819,7 +11785,7 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11819
11785
|
function q(F, K) {
|
11820
11786
|
var z;
|
11821
11787
|
const U = K[u.id.value];
|
11822
|
-
switch ((z =
|
11788
|
+
switch ((z = i.varGridConfig.value) == null ? void 0 : z.expand_accordion_flg) {
|
11823
11789
|
case 0:
|
11824
11790
|
F ? p.value = uniq([...p.value, U]) : p.value = without$1(p.value, U);
|
11825
11791
|
break;
|
@@ -11832,10 +11798,10 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11832
11798
|
K !== O.pageSize ? (O.pageIndex = 1, O.pageSize = K) : O.pageIndex = F, R();
|
11833
11799
|
}
|
11834
11800
|
function Q(F) {
|
11835
|
-
A.value = [F[u.id.value]], u.store.setSelectedRows(
|
11801
|
+
A.value = [F[u.id.value]], u.store.setSelectedRows(i.formID, A.value.map((K) => {
|
11836
11802
|
var U;
|
11837
11803
|
return (U = M.value) == null ? void 0 : U.find((z) => z[u.id.value] === K);
|
11838
|
-
}).filter((K) => !!K)), l.click(
|
11804
|
+
}).filter((K) => !!K)), l.click(i.formID, KG_BUTTON_TYPE.UPDATE);
|
11839
11805
|
}
|
11840
11806
|
function ne({
|
11841
11807
|
title: F,
|
@@ -11879,13 +11845,13 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11879
11845
|
}) : de;
|
11880
11846
|
}
|
11881
11847
|
function ce() {
|
11882
|
-
return !u.isReadAutomatically.value && !u.store.getIsRetrieved(
|
11848
|
+
return !u.isReadAutomatically.value && !u.store.getIsRetrieved(i.formID) ? o.t("kg.KgTable.emptyText") : o.t("kg.emptyText");
|
11883
11849
|
}
|
11884
11850
|
return () => {
|
11885
11851
|
var F;
|
11886
11852
|
return createVNode("div", {
|
11887
11853
|
class: k.value,
|
11888
|
-
"kg-frm-id":
|
11854
|
+
"kg-frm-id": i.formID,
|
11889
11855
|
ref: _
|
11890
11856
|
}, [createVNode(Table, {
|
11891
11857
|
class: "kg-flex-table",
|
@@ -11970,10 +11936,10 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11970
11936
|
var u, c, g, p, b, m, v, _;
|
11971
11937
|
return r.isCreating.value || r.isUpdating.value || r.isDeleting.value || n.isRetrieving.value || ((u = a.value) == null ? void 0 : u.dis_no_select_flg) === 1 && ((g = (c = n.selectedRows.value) == null ? void 0 : c.length) != null ? g : 0) === 0 || ((p = a.value) == null ? void 0 : p.dis_mult_select_flg) === 1 && ((m = (b = n.selectedRows.value) == null ? void 0 : b.length) != null ? m : 0) > 1 || ((v = a.value) == null ? void 0 : v.permission_type) === 2 && !t.p((_ = a.value) == null ? void 0 : _.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
11972
11938
|
});
|
11973
|
-
async function
|
11939
|
+
async function i() {
|
11974
11940
|
e.onKgClick && await e.onKgClick() || r.store.setIsCopying(r.formID, !0);
|
11975
11941
|
}
|
11976
|
-
function
|
11942
|
+
function s() {
|
11977
11943
|
return e.kgIcon ? createVNode("span", {
|
11978
11944
|
class: "anticon"
|
11979
11945
|
}, [createVNode(Icon, {
|
@@ -11987,9 +11953,9 @@ const KgTable$1 = "", KgTable = defineComponent({
|
|
11987
11953
|
type: "primary",
|
11988
11954
|
disabled: o.value,
|
11989
11955
|
ghost: !e.kgPrimary && !o.value,
|
11990
|
-
onClick:
|
11956
|
+
onClick: i
|
11991
11957
|
}, {
|
11992
|
-
default: () => [
|
11958
|
+
default: () => [s(), l()]
|
11993
11959
|
});
|
11994
11960
|
}
|
11995
11961
|
});
|
@@ -12129,11 +12095,11 @@ function useKgButton(e) {
|
|
12129
12095
|
return isFunction$2(l) ? (r.addEventListener(t.formID, "deleteOk", l), onUnmounted(() => r.removeEventListener(t.formID, "deleteOk", l)), () => r.removeEventListener(t.formID, "deleteOk", l)) : () => {
|
12130
12096
|
};
|
12131
12097
|
}
|
12132
|
-
function
|
12098
|
+
function i(l) {
|
12133
12099
|
return isFunction$2(l) ? (r.addEventListener(t.formID, "submitSave", l), onUnmounted(() => r.removeEventListener(t.formID, "submitSave", l)), () => r.removeEventListener(t.formID, "submitSave", l)) : () => {
|
12134
12100
|
};
|
12135
12101
|
}
|
12136
|
-
function
|
12102
|
+
function s(l) {
|
12137
12103
|
return isFunction$2(l) ? (r.addEventListener(t.formID, "submitCancel", l), onUnmounted(() => r.removeEventListener(t.formID, "submitCancel", l)), () => r.removeEventListener(t.formID, "submitCancel", l)) : () => {
|
12138
12104
|
};
|
12139
12105
|
}
|
@@ -12144,8 +12110,8 @@ function useKgButton(e) {
|
|
12144
12110
|
onClick: n,
|
12145
12111
|
onUpdateBeforeClick: a,
|
12146
12112
|
onDeleteOk: o,
|
12147
|
-
onSubmitSave:
|
12148
|
-
onSubmitCancel:
|
12113
|
+
onSubmitSave: i,
|
12114
|
+
onSubmitCancel: s
|
12149
12115
|
};
|
12150
12116
|
}
|
12151
12117
|
const KgButtonCreate = defineComponent({
|
@@ -12155,9 +12121,9 @@ const KgButtonCreate = defineComponent({
|
|
12155
12121
|
slots: t,
|
12156
12122
|
emit: r
|
12157
12123
|
}) {
|
12158
|
-
const n = useKg(), a = useKgVar(), o = useKgButton(),
|
12124
|
+
const n = useKg(), a = useKgVar(), o = useKgButton(), i = useKgTable(), s = useKgSubmit(), l = computed(() => a.store.getVarButton(a.formID, e.kgVarName)), u = computed(() => {
|
12159
12125
|
var C, E, T, I, k, w, M, A;
|
12160
|
-
return a.isUpdating.value || a.isCopying.value || a.isDeleting.value ||
|
12126
|
+
return a.isUpdating.value || a.isCopying.value || a.isDeleting.value || i.isRetrieving.value || ((C = l.value) == null ? void 0 : C.dis_no_select_flg) === 1 && ((T = (E = i.selectedRows.value) == null ? void 0 : E.length) != null ? T : 0) === 0 || ((I = l.value) == null ? void 0 : I.dis_mult_select_flg) === 1 && ((w = (k = i.selectedRows.value) == null ? void 0 : k.length) != null ? w : 0) > 1 || ((M = l.value) == null ? void 0 : M.permission_type) === 2 && !n.p((A = l.value) == null ? void 0 : A.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12161
12127
|
}), c = computed(() => !!a.isCreatingRequesting.value);
|
12162
12128
|
async function g() {
|
12163
12129
|
e.onKgClick && await e.onKgClick() || a.store.setIsCreating(a.formID, !0);
|
@@ -12179,7 +12145,7 @@ const KgButtonCreate = defineComponent({
|
|
12179
12145
|
return e.kgText ? e.kgText : n.t("kg.create");
|
12180
12146
|
}
|
12181
12147
|
function _() {
|
12182
|
-
return
|
12148
|
+
return s.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && a.isCreating.value ? null : createVNode(Button, {
|
12183
12149
|
type: "primary",
|
12184
12150
|
disabled: u.value,
|
12185
12151
|
onClick: g
|
@@ -12188,7 +12154,7 @@ const KgButtonCreate = defineComponent({
|
|
12188
12154
|
});
|
12189
12155
|
}
|
12190
12156
|
function y() {
|
12191
|
-
return
|
12157
|
+
return s.displayType.value !== KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE || !a.isCreating.value ? null : createVNode(Fragment, null, [createVNode(Button, {
|
12192
12158
|
type: "primary",
|
12193
12159
|
onClick: p,
|
12194
12160
|
disabled: !!a.isCreatingRequesting.value
|
@@ -12213,10 +12179,10 @@ const KgButtonCreate = defineComponent({
|
|
12213
12179
|
var u, c, g, p, b, m, v, _;
|
12214
12180
|
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || n.isRetrieving.value || ((u = a.value) == null ? void 0 : u.dis_no_select_flg) === 1 && ((g = (c = n.selectedRows.value) == null ? void 0 : c.length) != null ? g : 0) === 0 || ((p = a.value) == null ? void 0 : p.dis_mult_select_flg) === 1 && ((m = (b = n.selectedRows.value) == null ? void 0 : b.length) != null ? m : 0) > 1 || ((v = a.value) == null ? void 0 : v.permission_type) === 2 && !t.p((_ = a.value) == null ? void 0 : _.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12215
12181
|
});
|
12216
|
-
async function
|
12182
|
+
async function i() {
|
12217
12183
|
e.onKgClick && await e.onKgClick() || r.store.setIsDeleting(r.formID, !0);
|
12218
12184
|
}
|
12219
|
-
function
|
12185
|
+
function s() {
|
12220
12186
|
return e.kgIcon ? createVNode("span", {
|
12221
12187
|
class: "anticon"
|
12222
12188
|
}, [createVNode(Icon, {
|
@@ -12231,19 +12197,19 @@ const KgButtonCreate = defineComponent({
|
|
12231
12197
|
disabled: o.value,
|
12232
12198
|
danger: e.kgColor === KG_BUTTON_COLOR.DANGER || !e.kgColor,
|
12233
12199
|
ghost: !e.kgPrimary && !o.value,
|
12234
|
-
onClick:
|
12200
|
+
onClick: i
|
12235
12201
|
}, {
|
12236
|
-
default: () => [
|
12202
|
+
default: () => [s(), l()]
|
12237
12203
|
});
|
12238
12204
|
}
|
12239
12205
|
}), KgButtonExport = defineComponent({
|
12240
12206
|
name: "KgButtonExport",
|
12241
12207
|
props: getProps$f(),
|
12242
12208
|
setup(e) {
|
12243
|
-
const t = useKg(), r = useKgVar(), n = useKgSearch(), a = useKgTable(), o = computed(() => r.store.getVarButton(r.formID, e.kgVarName)),
|
12209
|
+
const t = useKg(), r = useKgVar(), n = useKgSearch(), a = useKgTable(), o = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), i = computed(() => {
|
12244
12210
|
var m, v;
|
12245
12211
|
return o.value ? (v = (m = o.value) == null ? void 0 : m.cmd) != null ? v : "" : null;
|
12246
|
-
}),
|
12212
|
+
}), s = computed(() => {
|
12247
12213
|
var m, v;
|
12248
12214
|
return (v = (m = o.value) == null ? void 0 : m.cmd_method) != null ? v : "GET";
|
12249
12215
|
}), l = computed(() => {
|
@@ -12265,7 +12231,7 @@ const KgButtonCreate = defineComponent({
|
|
12265
12231
|
async function g() {
|
12266
12232
|
var m, v, _;
|
12267
12233
|
if (!(e.onKgClick && await e.onKgClick())) {
|
12268
|
-
if (!
|
12234
|
+
if (!i.value) {
|
12269
12235
|
Logger.error("[KgButton] '\u5BFC\u51FA\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
12270
12236
|
VarButton: o.value
|
12271
12237
|
});
|
@@ -12274,8 +12240,8 @@ const KgButtonCreate = defineComponent({
|
|
12274
12240
|
c.value = !0;
|
12275
12241
|
try {
|
12276
12242
|
const y = await httpClient().request({
|
12277
|
-
method:
|
12278
|
-
url:
|
12243
|
+
method: s.value,
|
12244
|
+
url: i.value,
|
12279
12245
|
params: l.value,
|
12280
12246
|
responseType: "blob"
|
12281
12247
|
}, {
|
@@ -12317,32 +12283,32 @@ const KgButtonCreate = defineComponent({
|
|
12317
12283
|
slots: t,
|
12318
12284
|
attrs: r
|
12319
12285
|
}) {
|
12320
|
-
const n = useKg(), a = useKgVar(), o = useKgSearch(),
|
12286
|
+
const n = useKg(), a = useKgVar(), o = useKgSearch(), i = useKgTable(), s = computed(() => a.store.getVarButton(a.formID, e.kgVarName)), l = computed(() => {
|
12321
12287
|
var v, _;
|
12322
|
-
return
|
12288
|
+
return s.value ? (_ = (v = s.value) == null ? void 0 : v.cmd) != null ? _ : "" : null;
|
12323
12289
|
}), u = computed(() => {
|
12324
12290
|
var v, _;
|
12325
|
-
return (_ = (v =
|
12291
|
+
return (_ = (v = s.value) == null ? void 0 : v.cmd_method) != null ? _ : "POST";
|
12326
12292
|
});
|
12327
12293
|
computed(() => {
|
12328
12294
|
var _, y, C;
|
12329
12295
|
let v = {
|
12330
12296
|
...(_ = o.model.value) != null ? _ : {}
|
12331
12297
|
};
|
12332
|
-
return
|
12298
|
+
return s.value && (v = {
|
12333
12299
|
...v,
|
12334
|
-
...KgVarUtil.parseCommandParameter((C = (y =
|
12300
|
+
...KgVarUtil.parseCommandParameter((C = (y = s.value) == null ? void 0 : y.cmd_prm) != null ? C : "")
|
12335
12301
|
}), v;
|
12336
12302
|
});
|
12337
12303
|
const c = computed(() => {
|
12338
12304
|
var v, _, y, C, E, T, I, k;
|
12339
|
-
return a.isCreating.value || a.isUpdating.value || a.isCopying.value || a.isDeleting.value ||
|
12305
|
+
return a.isCreating.value || a.isUpdating.value || a.isCopying.value || a.isDeleting.value || i.isRetrieving.value || ((v = s.value) == null ? void 0 : v.dis_no_select_flg) === 1 && ((y = (_ = i.selectedRows.value) == null ? void 0 : _.length) != null ? y : 0) === 0 || ((C = s.value) == null ? void 0 : C.dis_mult_select_flg) === 1 && ((T = (E = i.selectedRows.value) == null ? void 0 : E.length) != null ? T : 0) > 1 || ((I = s.value) == null ? void 0 : I.permission_type) === 2 && !n.p((k = s.value) == null ? void 0 : k.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12340
12306
|
}), g = ref(!1);
|
12341
12307
|
async function p(v) {
|
12342
12308
|
var _, y;
|
12343
12309
|
if (!l.value)
|
12344
12310
|
return Logger.error("[KgButton] '\u5BFC\u5165\u6309\u94AE'\u6CA1\u6709\u914D\u7F6E\u63A5\u53E3\u5730\u5740.", {
|
12345
|
-
VarButton:
|
12311
|
+
VarButton: s.value
|
12346
12312
|
}), !1;
|
12347
12313
|
g.value = !0;
|
12348
12314
|
try {
|
@@ -12398,10 +12364,10 @@ const KgButtonCreate = defineComponent({
|
|
12398
12364
|
const t = useKg(), r = useKgVar(), n = useKgTable(), a = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), o = computed(() => {
|
12399
12365
|
var p, b;
|
12400
12366
|
return a.value ? (b = (p = a.value) == null ? void 0 : p.cmd) != null ? b : "" : null;
|
12401
|
-
}),
|
12367
|
+
}), i = computed(() => {
|
12402
12368
|
var p, b;
|
12403
12369
|
return (b = (p = a.value) == null ? void 0 : p.cmd_method) != null ? b : "GET";
|
12404
|
-
}),
|
12370
|
+
}), s = computed(() => {
|
12405
12371
|
var p, b, m, v, _, y, C, E;
|
12406
12372
|
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || n.isRetrieving.value || ((p = a.value) == null ? void 0 : p.dis_no_select_flg) === 1 && ((m = (b = n.selectedRows.value) == null ? void 0 : b.length) != null ? m : 0) === 0 || ((v = a.value) == null ? void 0 : v.dis_mult_select_flg) === 1 && ((y = (_ = n.selectedRows.value) == null ? void 0 : _.length) != null ? y : 0) > 1 || ((C = a.value) == null ? void 0 : C.permission_type) === 2 && !t.p((E = a.value) == null ? void 0 : E.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12407
12373
|
}), l = ref(!1);
|
@@ -12416,7 +12382,7 @@ const KgButtonCreate = defineComponent({
|
|
12416
12382
|
l.value = !0;
|
12417
12383
|
try {
|
12418
12384
|
const b = await httpClient().request({
|
12419
|
-
method:
|
12385
|
+
method: i.value,
|
12420
12386
|
url: o.value,
|
12421
12387
|
params: {
|
12422
12388
|
selections: "NULL"
|
@@ -12445,8 +12411,8 @@ const KgButtonCreate = defineComponent({
|
|
12445
12411
|
}
|
12446
12412
|
return () => createVNode(Button, {
|
12447
12413
|
type: "primary",
|
12448
|
-
disabled:
|
12449
|
-
ghost: !e.kgPrimary && !
|
12414
|
+
disabled: s.value,
|
12415
|
+
ghost: !e.kgPrimary && !s.value,
|
12450
12416
|
loading: l.value,
|
12451
12417
|
onClick: u
|
12452
12418
|
}, {
|
@@ -12457,11 +12423,11 @@ const KgButtonCreate = defineComponent({
|
|
12457
12423
|
name: "KgButtonOther",
|
12458
12424
|
props: getProps$f(),
|
12459
12425
|
setup(e) {
|
12460
|
-
const t = useKg(), r = useKgVar(), n = useKgSearch(), a = useKgTable(), o = computed(() => r.store.getVarButton(r.formID, e.kgVarName)),
|
12426
|
+
const t = useKg(), r = useKgVar(), n = useKgSearch(), a = useKgTable(), o = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), i = computed(() => {
|
12461
12427
|
var c, g, p, b, m, v, _, y;
|
12462
12428
|
return r.isCreating.value || r.isUpdating.value || r.isCopying.value || r.isDeleting.value || a.isRetrieving.value || ((c = o.value) == null ? void 0 : c.dis_no_select_flg) === 1 && ((p = (g = a.selectedRows.value) == null ? void 0 : g.length) != null ? p : 0) === 0 || ((b = o.value) == null ? void 0 : b.dis_mult_select_flg) === 1 && ((v = (m = a.selectedRows.value) == null ? void 0 : m.length) != null ? v : 0) > 1 || ((_ = o.value) == null ? void 0 : _.permission_type) === 2 && !t.p((y = o.value) == null ? void 0 : y.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12463
12429
|
});
|
12464
|
-
async function
|
12430
|
+
async function s() {
|
12465
12431
|
var b, m, v;
|
12466
12432
|
if (e.onKgClick && await e.onKgClick())
|
12467
12433
|
return;
|
@@ -12511,10 +12477,10 @@ const KgButtonCreate = defineComponent({
|
|
12511
12477
|
}
|
12512
12478
|
return () => createVNode(Button, {
|
12513
12479
|
type: "primary",
|
12514
|
-
disabled:
|
12480
|
+
disabled: i.value,
|
12515
12481
|
danger: e.kgColor === KG_BUTTON_COLOR.DANGER,
|
12516
|
-
ghost: !e.kgPrimary && !
|
12517
|
-
onClick:
|
12482
|
+
ghost: !e.kgPrimary && !i.value,
|
12483
|
+
onClick: s
|
12518
12484
|
}, {
|
12519
12485
|
default: () => [l(), u()]
|
12520
12486
|
});
|
@@ -12536,7 +12502,7 @@ const KgButtonCreate = defineComponent({
|
|
12536
12502
|
icon: e.kgIcon
|
12537
12503
|
}, null)]) : createVNode(SearchOutlined$1, null, null);
|
12538
12504
|
}
|
12539
|
-
function
|
12505
|
+
function i() {
|
12540
12506
|
return e.kgText ? e.kgText : t.t("kg.query");
|
12541
12507
|
}
|
12542
12508
|
return () => createVNode(Button, {
|
@@ -12546,7 +12512,7 @@ const KgButtonCreate = defineComponent({
|
|
12546
12512
|
ghost: !e.kgPrimary && !n.value,
|
12547
12513
|
onClick: a
|
12548
12514
|
}, {
|
12549
|
-
default: () => [o(),
|
12515
|
+
default: () => [o(), i()]
|
12550
12516
|
});
|
12551
12517
|
}
|
12552
12518
|
}), KgButtonUpdate = defineComponent({
|
@@ -12556,8 +12522,8 @@ const KgButtonCreate = defineComponent({
|
|
12556
12522
|
slots: t,
|
12557
12523
|
emit: r
|
12558
12524
|
}) {
|
12559
|
-
const n = useKg(), a = useKgVar(), o = useKgTable(),
|
12560
|
-
|
12525
|
+
const n = useKg(), a = useKgVar(), o = useKgTable(), i = useKgButton(), s = useKgSubmit();
|
12526
|
+
i.store.$onAction(async ({
|
12561
12527
|
name: _,
|
12562
12528
|
args: y
|
12563
12529
|
}) => {
|
@@ -12572,7 +12538,7 @@ const KgButtonCreate = defineComponent({
|
|
12572
12538
|
return a.isCreating.value || a.isCopying.value || a.isDeleting.value || ((_ = l.value) == null ? void 0 : _.dis_no_select_flg) === 1 && ((C = (y = o.selectedRows.value) == null ? void 0 : y.length) != null ? C : 0) === 0 || ((E = l.value) == null ? void 0 : E.dis_mult_select_flg) === 1 && ((I = (T = o.selectedRows.value) == null ? void 0 : T.length) != null ? I : 0) > 1 || ((k = l.value) == null ? void 0 : k.permission_type) === 2 && !n.p((w = l.value) == null ? void 0 : w.permission_code) ? !0 : isNil(e.kgDisabled) ? !1 : e.kgDisabled;
|
12573
12539
|
});
|
12574
12540
|
async function c() {
|
12575
|
-
e.onKgClick && await e.onKgClick() || await
|
12541
|
+
e.onKgClick && await e.onKgClick() || await i.store.emit(a.formID, "updateBeforeClick", {
|
12576
12542
|
button: e.kgButton,
|
12577
12543
|
row: o.selectedRow.value
|
12578
12544
|
}) || a.store.setIsUpdating(a.formID, !0);
|
@@ -12591,7 +12557,7 @@ const KgButtonCreate = defineComponent({
|
|
12591
12557
|
return e.kgText ? e.kgText : n.t("kg.update");
|
12592
12558
|
}
|
12593
12559
|
function m() {
|
12594
|
-
return
|
12560
|
+
return s.displayType.value === KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE && a.isUpdating.value ? null : createVNode(Button, {
|
12595
12561
|
type: "primary",
|
12596
12562
|
disabled: u.value,
|
12597
12563
|
ghost: !e.kgPrimary && !u.value,
|
@@ -12601,7 +12567,7 @@ const KgButtonCreate = defineComponent({
|
|
12601
12567
|
});
|
12602
12568
|
}
|
12603
12569
|
function v() {
|
12604
|
-
return
|
12570
|
+
return s.displayType.value !== KG_VAR_SUBMIT__DISPLAY_TYPE.TABLE || !a.isUpdating.value ? null : createVNode(Fragment, null, [createVNode(Button, {
|
12605
12571
|
type: "primary"
|
12606
12572
|
}, {
|
12607
12573
|
default: () => [createVNode(CheckOutlined$1, null, null), n.t("kg.save")]
|
@@ -12626,13 +12592,13 @@ const KgButtonItem = defineComponent({
|
|
12626
12592
|
const t = useKg(), r = useKgVar();
|
12627
12593
|
useKgTable();
|
12628
12594
|
const n = computed(() => r.store.getVarButton(r.formID, e.kgVarName)), a = computed(() => {
|
12629
|
-
let
|
12595
|
+
let s = "kg-button-item";
|
12630
12596
|
switch (e.kgColor) {
|
12631
12597
|
case KG_BUTTON_COLOR.WARN:
|
12632
|
-
|
12598
|
+
s += " kg-button-item--warn";
|
12633
12599
|
break;
|
12634
12600
|
}
|
12635
|
-
return
|
12601
|
+
return s;
|
12636
12602
|
}), o = computed(() => {
|
12637
12603
|
var l, u, c, g;
|
12638
12604
|
return {
|
@@ -12644,9 +12610,9 @@ const KgButtonItem = defineComponent({
|
|
12644
12610
|
"kg-cmd": (g = n.value) == null ? void 0 : g.cmd
|
12645
12611
|
};
|
12646
12612
|
});
|
12647
|
-
function
|
12648
|
-
var
|
12649
|
-
if (((
|
12613
|
+
function i() {
|
12614
|
+
var s, l;
|
12615
|
+
if (((s = n.value) == null ? void 0 : s.permission_type) !== 2 && !t.p((l = n.value) == null ? void 0 : l.permission_code))
|
12650
12616
|
return null;
|
12651
12617
|
switch (e.kgType) {
|
12652
12618
|
case KG_BUTTON_TYPE.SEARCH:
|
@@ -12670,11 +12636,11 @@ const KgButtonItem = defineComponent({
|
|
12670
12636
|
}
|
12671
12637
|
}
|
12672
12638
|
return () => {
|
12673
|
-
let
|
12639
|
+
let s;
|
12674
12640
|
return createVNode(ConfigProvider, {
|
12675
12641
|
autoInsertSpaceInButton: !1
|
12676
|
-
}, _isSlot$4(
|
12677
|
-
default: () => [
|
12642
|
+
}, _isSlot$4(s = i()) ? s : {
|
12643
|
+
default: () => [s]
|
12678
12644
|
});
|
12679
12645
|
};
|
12680
12646
|
}
|
@@ -12692,11 +12658,11 @@ const getProps$e = () => ({
|
|
12692
12658
|
function o(b) {
|
12693
12659
|
return n.store.emit(r.formID, "click", b);
|
12694
12660
|
}
|
12695
|
-
function
|
12661
|
+
function i(b) {
|
12696
12662
|
if (e.kgDisabled)
|
12697
12663
|
return e.kgDisabled(b);
|
12698
12664
|
}
|
12699
|
-
function
|
12665
|
+
function s(b) {
|
12700
12666
|
switch (b.primary_flg) {
|
12701
12667
|
case 1:
|
12702
12668
|
return !0;
|
@@ -12729,8 +12695,8 @@ const getProps$e = () => ({
|
|
12729
12695
|
kgIcon: b.icon,
|
12730
12696
|
kgText: l(b),
|
12731
12697
|
kgColor: b.color,
|
12732
|
-
kgPrimary:
|
12733
|
-
kgDisabled:
|
12698
|
+
kgPrimary: s(b),
|
12699
|
+
kgDisabled: i(b),
|
12734
12700
|
onKgClick: () => o(b)
|
12735
12701
|
}, null);
|
12736
12702
|
}
|
@@ -12898,22 +12864,22 @@ const useKgSearchStore = () => (store$2 || (store$2 = defineStore("KgSearch", {
|
|
12898
12864
|
switch (t) {
|
12899
12865
|
case "search":
|
12900
12866
|
{
|
12901
|
-
const
|
12902
|
-
|
12867
|
+
const i = this.onSearchListenersMap.get(o);
|
12868
|
+
i && i.forEach((s) => s(r == null ? void 0 : r.resetPageIndex));
|
12903
12869
|
}
|
12904
12870
|
break;
|
12905
12871
|
case "reset":
|
12906
12872
|
{
|
12907
|
-
const
|
12908
|
-
|
12873
|
+
const i = this.onResetListenersMap.get(o);
|
12874
|
+
i && i.forEach((s) => s());
|
12909
12875
|
}
|
12910
12876
|
break;
|
12911
12877
|
case "ready":
|
12912
12878
|
{
|
12913
|
-
const
|
12914
|
-
|
12915
|
-
l.once && !l.invoked && (l.invoked = !0,
|
12916
|
-
}),
|
12879
|
+
const i = [], s = this.onReadyListenersMap.get(o);
|
12880
|
+
s && s.forEach((l) => {
|
12881
|
+
l.once && !l.invoked && (l.invoked = !0, i.push(l)), l();
|
12882
|
+
}), i.forEach((l) => this.removeEventListener(o, "ready", l));
|
12917
12883
|
}
|
12918
12884
|
break;
|
12919
12885
|
}
|
@@ -12976,15 +12942,15 @@ function useKgSearch(e) {
|
|
12976
12942
|
return isFunction$2(c) ? (g && (c.once = !0), r.addEventListener(t.formID, "ready", c), onUnmounted(() => r.removeEventListener(t.formID, "ready", c)), () => r.removeEventListener(t.formID, "ready", c)) : () => {
|
12977
12943
|
};
|
12978
12944
|
}
|
12979
|
-
const
|
12945
|
+
const i = computed(() => r.getIsReady(t.formID)), s = computed(() => r.getModel(t.formID)), l = computed(() => r.getSearchFn(t.formID)), u = computed(() => r.getResetFn(t.formID));
|
12980
12946
|
return {
|
12981
12947
|
formID: t.formID,
|
12982
12948
|
store: r,
|
12983
12949
|
onSearch: n,
|
12984
12950
|
onReset: a,
|
12985
12951
|
onReady: o,
|
12986
|
-
isReady:
|
12987
|
-
model:
|
12952
|
+
isReady: i,
|
12953
|
+
model: s,
|
12988
12954
|
search: l,
|
12989
12955
|
reset: u
|
12990
12956
|
};
|
@@ -13175,8 +13141,8 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13175
13141
|
setup(e, {
|
13176
13142
|
emit: t
|
13177
13143
|
}) {
|
13178
|
-
const r = useKg(), n = useKgVar(FORM_ID__VAR_PROFILE_MASTER, !0, 1), a = useKgSearch(FORM_ID__VAR_PROFILE_MASTER), o = useKgButton(FORM_ID__VAR_PROFILE_MASTER),
|
13179
|
-
|
13144
|
+
const r = useKg(), n = useKgVar(FORM_ID__VAR_PROFILE_MASTER, !0, 1), a = useKgSearch(FORM_ID__VAR_PROFILE_MASTER), o = useKgButton(FORM_ID__VAR_PROFILE_MASTER), i = useKgSubmit(FORM_ID__VAR_PROFILE_MASTER), s = useKgVar(e.hostFormID);
|
13145
|
+
i.onOpen(async ({
|
13180
13146
|
isCreating: m,
|
13181
13147
|
isUpdating: v,
|
13182
13148
|
isCopying: _,
|
@@ -13184,7 +13150,7 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13184
13150
|
model: C
|
13185
13151
|
}) => {
|
13186
13152
|
var T, I, k;
|
13187
|
-
const E =
|
13153
|
+
const E = s.store.getSystemVarProfileDetails(s.formID);
|
13188
13154
|
switch (l.value = E ? cloneDeep(unref(toRaw(E))) : [], !0) {
|
13189
13155
|
case m:
|
13190
13156
|
u.value = [];
|
@@ -13193,7 +13159,7 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13193
13159
|
case _:
|
13194
13160
|
if (y != null && y.id)
|
13195
13161
|
try {
|
13196
|
-
|
13162
|
+
i.store.setIsLoading(n.formID, !0);
|
13197
13163
|
const w = await QueryByID({
|
13198
13164
|
params: {
|
13199
13165
|
id: y.id
|
@@ -13213,7 +13179,7 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13213
13179
|
} catch (w) {
|
13214
13180
|
throw w;
|
13215
13181
|
} finally {
|
13216
|
-
|
13182
|
+
i.store.setIsLoading(n.formID, !1);
|
13217
13183
|
}
|
13218
13184
|
else
|
13219
13185
|
u.value = [];
|
@@ -13225,13 +13191,13 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13225
13191
|
break;
|
13226
13192
|
}
|
13227
13193
|
return !1;
|
13228
|
-
}),
|
13194
|
+
}), i.onBeforeOk(async ({
|
13229
13195
|
model: m
|
13230
13196
|
}) => {
|
13231
13197
|
var _, y;
|
13232
13198
|
const v = m.value;
|
13233
|
-
return v.frm_id =
|
13234
|
-
}),
|
13199
|
+
return v.frm_id = s.formID, v.varProfileDetails = (y = (_ = l.value) == null ? void 0 : _.filter((C) => u.value.includes(C.id))) != null ? y : [], !1;
|
13200
|
+
}), i.onOk(async () => (s.store.retrieve(s.formID), !1)), o.onUpdateBeforeClick(({
|
13235
13201
|
row: m
|
13236
13202
|
}) => (m == null ? void 0 : m.cust_lvl) === KG_CUSTOM_LEVEL.L0 ? new Promise((v) => {
|
13237
13203
|
KgUtil.confirm({
|
@@ -13246,7 +13212,7 @@ const leftVarProfileDetailColumns = (e) => {
|
|
13246
13212
|
v(!0);
|
13247
13213
|
}
|
13248
13214
|
});
|
13249
|
-
}) : Promise.resolve(!1)), o.onDeleteOk(() => (
|
13215
|
+
}) : Promise.resolve(!1)), o.onDeleteOk(() => (s.store.retrieve(s.formID), Promise.resolve(!1)));
|
13250
13216
|
const l = ref([]), u = ref([]), c = ref({
|
13251
13217
|
KgSubmit: {
|
13252
13218
|
"KgForm.Item": {
|
@@ -13441,8 +13407,8 @@ function _useLayoutHeaderResizeObserver() {
|
|
13441
13407
|
return onMounted(() => {
|
13442
13408
|
const t = document.querySelector("div.jeecg-layout-header-center");
|
13443
13409
|
t && (e = new ResizeObserver((r) => {
|
13444
|
-
var
|
13445
|
-
const n = t.getBoundingClientRect().left, a = (
|
13410
|
+
var i, s;
|
13411
|
+
const n = t.getBoundingClientRect().left, a = (s = (i = r[0].borderBoxSize[0]) == null ? void 0 : i.inlineSize) != null ? s : 0, o = document.querySelector("#kg-search-header-teleport");
|
13446
13412
|
o && (o.style.left = `${n}px`, o.style.width = `${a}px`);
|
13447
13413
|
}), e.observe(t));
|
13448
13414
|
}), onUnmounted(() => {
|
@@ -13455,9 +13421,9 @@ const KgSearch$1 = "", getProps$9 = () => ({}), KgSearch = defineComponent({
|
|
13455
13421
|
setup(e) {
|
13456
13422
|
const t = inject(DI_KG_SLOTS, null), r = useKg(), n = useKgVar(), a = useKgSearch(), o = useKgTable();
|
13457
13423
|
_useLayoutHeaderResizeObserver();
|
13458
|
-
const
|
13424
|
+
const i = computed(() => n.store.getFormLevel(n.formID)), s = computed(() => n.store.getVarProfileConfig(n.formID)), l = computed(() => {
|
13459
13425
|
var N;
|
13460
|
-
return
|
13426
|
+
return i.value > 0 ? !1 : ((N = s.value) == null ? void 0 : N.header_teleport_flg) !== 0;
|
13461
13427
|
}), u = computed(() => getDefaultHeight(n.currentVarProfileDetails.value, l.value)), c = computed(() => getMaxHeight(n.currentVarProfileDetails.value, l.value)), g = computed(() => l.value ? 1 : HEADER_HEIGHT), p = computed(() => {
|
13462
13428
|
var N, x;
|
13463
13429
|
return !!(o.isRetrieving.value || ((N = n.varButtonSearch.value) == null ? void 0 : N.permission_type) === 2 && !r.p((x = n.varButtonSearch.value) == null ? void 0 : x.permission_code) || n.isCreating.value || n.isUpdating.value || n.isCopying.value || n.isDeleting.value);
|
@@ -13483,10 +13449,10 @@ const KgSearch$1 = "", getProps$9 = () => ({}), KgSearch = defineComponent({
|
|
13483
13449
|
}
|
13484
13450
|
}), k = computed(() => {
|
13485
13451
|
var N;
|
13486
|
-
return ((N =
|
13452
|
+
return ((N = s.value) == null ? void 0 : N.vis_flg) === 1;
|
13487
13453
|
}), w = computed(() => {
|
13488
13454
|
var N;
|
13489
|
-
return ((N =
|
13455
|
+
return ((N = s.value) == null ? void 0 : N.resizable_flg) !== 0;
|
13490
13456
|
}), M = computed(() => !!(n.isRetrievingVar.value || n.isRetrievingVarProfileMaster.value || l.value && !!n.isOtherRequesting.value)), A = computed(() => !!n.isRetrievingVar.value || !!n.isRetrievingVarProfileMaster.value), O = computed(() => {
|
13491
13457
|
let N = "kg-search";
|
13492
13458
|
return k.value && (N += " kg-search--visible"), l.value && (N += " kg-search--teleport"), N;
|
@@ -13683,14 +13649,14 @@ function useEventListener(...e) {
|
|
13683
13649
|
if (isString(e[0]) ? ([r, n, a] = e, t = defaultWindow) : [t, r, n, a] = e, !t)
|
13684
13650
|
return noop;
|
13685
13651
|
let o = noop;
|
13686
|
-
const
|
13652
|
+
const i = watch(() => unrefElement(t), (l) => {
|
13687
13653
|
o(), l && (l.addEventListener(r, n, a), o = () => {
|
13688
13654
|
l.removeEventListener(r, n, a), o = noop;
|
13689
13655
|
});
|
13690
|
-
}, { immediate: !0, flush: "post" }),
|
13691
|
-
|
13656
|
+
}, { immediate: !0, flush: "post" }), s = () => {
|
13657
|
+
i(), o();
|
13692
13658
|
};
|
13693
|
-
return tryOnScopeDispose(
|
13659
|
+
return tryOnScopeDispose(s), s;
|
13694
13660
|
}
|
13695
13661
|
const _global = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {}, globalKey = "__vueuse_ssr_handlers__";
|
13696
13662
|
_global[globalKey] = _global[globalKey] || {};
|
@@ -13712,9 +13678,9 @@ function useMagicKeys(e = {}) {
|
|
13712
13678
|
aliasMap: n = DefaultMagicKeysAliasMap,
|
13713
13679
|
passive: a = !0,
|
13714
13680
|
onEventFired: o = noop
|
13715
|
-
} = e,
|
13681
|
+
} = e, i = reactive(/* @__PURE__ */ new Set()), s = { toJSON() {
|
13716
13682
|
return {};
|
13717
|
-
}, current:
|
13683
|
+
}, current: i }, l = t ? reactive(s) : s, u = /* @__PURE__ */ new Set(), c = /* @__PURE__ */ new Set();
|
13718
13684
|
function g(v, _) {
|
13719
13685
|
v in l && (t ? l[v] = _ : l[v].value = _);
|
13720
13686
|
}
|
@@ -13725,12 +13691,12 @@ function useMagicKeys(e = {}) {
|
|
13725
13691
|
function b(v, _) {
|
13726
13692
|
var y, C;
|
13727
13693
|
const E = (y = v.key) == null ? void 0 : y.toLowerCase(), T = (C = v.code) == null ? void 0 : C.toLowerCase(), I = [T, E].filter(Boolean);
|
13728
|
-
T && (_ ?
|
13694
|
+
T && (_ ? i.add(v.code) : i.delete(v.code));
|
13729
13695
|
for (const k of I)
|
13730
13696
|
c.add(k), g(k, _);
|
13731
13697
|
E === "meta" && !_ ? (u.forEach((k) => {
|
13732
|
-
|
13733
|
-
}), u.clear()) : typeof v.getModifierState == "function" && v.getModifierState("Meta") && _ && [...
|
13698
|
+
i.delete(k), g(k, !1);
|
13699
|
+
}), u.clear()) : typeof v.getModifierState == "function" && v.getModifierState("Meta") && _ && [...i, ...I].forEach((k) => u.add(k));
|
13734
13700
|
}
|
13735
13701
|
r && (useEventListener(r, "keydown", (v) => (b(v, !0), o(v)), { passive: a }), useEventListener(r, "keyup", (v) => (b(v, !1), o(v)), { passive: a }), useEventListener("blur", p, { passive: !0 }), useEventListener("focus", p, { passive: !0 }));
|
13736
13702
|
const m = new Proxy(l, {
|
@@ -13779,17 +13745,17 @@ const KgVarConfig_FormIDsModal = "", getProps$8 = () => ({
|
|
13779
13745
|
function o(u, c) {
|
13780
13746
|
switch (u == null ? void 0 : u.detail) {
|
13781
13747
|
case 2:
|
13782
|
-
|
13748
|
+
i();
|
13783
13749
|
break;
|
13784
13750
|
default:
|
13785
13751
|
n.value = [c.id];
|
13786
13752
|
break;
|
13787
13753
|
}
|
13788
13754
|
}
|
13789
|
-
function
|
13755
|
+
function i() {
|
13790
13756
|
t("update:visible", !1), t("kgOk", n.value[0]);
|
13791
13757
|
}
|
13792
|
-
function
|
13758
|
+
function s() {
|
13793
13759
|
t("update:visible", !1);
|
13794
13760
|
}
|
13795
13761
|
function l() {
|
@@ -13805,9 +13771,9 @@ const KgVarConfig_FormIDsModal = "", getProps$8 = () => ({
|
|
13805
13771
|
width: "800px",
|
13806
13772
|
confirmLoading: !1,
|
13807
13773
|
wrapClassName: "kg-var-config-form-ids-modal",
|
13808
|
-
onCancel:
|
13774
|
+
onCancel: s,
|
13809
13775
|
kgFullHeight: !1,
|
13810
|
-
onOk:
|
13776
|
+
onOk: i,
|
13811
13777
|
okButtonProps: {
|
13812
13778
|
disabled: n.value.length < 1
|
13813
13779
|
}
|
@@ -14014,11 +13980,11 @@ const getProps$2 = () => ({
|
|
14014
13980
|
isAllLanguage: a.value
|
14015
13981
|
});
|
14016
13982
|
}
|
14017
|
-
function
|
13983
|
+
function i() {
|
14018
13984
|
t("update:visible", !1);
|
14019
13985
|
}
|
14020
13986
|
return () => {
|
14021
|
-
let
|
13987
|
+
let s, l, u, c;
|
14022
13988
|
return createVNode(KgModal, {
|
14023
13989
|
visible: e.visible,
|
14024
13990
|
title: r.t("kg.KgVarConfig.createConfig"),
|
@@ -14027,7 +13993,7 @@ const getProps$2 = () => ({
|
|
14027
13993
|
width: 500,
|
14028
13994
|
wrapClassName: "kg-var-config-modal-var-create-modal",
|
14029
13995
|
kgFullHeight: !1,
|
14030
|
-
onCancel:
|
13996
|
+
onCancel: i,
|
14031
13997
|
onOk: o
|
14032
13998
|
}, {
|
14033
13999
|
default: () => [createVNode(Row, {
|
@@ -14057,8 +14023,8 @@ const getProps$2 = () => ({
|
|
14057
14023
|
}, {
|
14058
14024
|
default: () => [createVNode(Radio.Button, {
|
14059
14025
|
value: !0
|
14060
|
-
}, _isSlot$1(
|
14061
|
-
default: () => [
|
14026
|
+
}, _isSlot$1(s = r.t("kg.KgVarConfig.allForm")) ? s : {
|
14027
|
+
default: () => [s]
|
14062
14028
|
}), createVNode(Radio.Button, {
|
14063
14029
|
value: !1
|
14064
14030
|
}, _isSlot$1(l = r.t("kg.KgVarConfig.currentForm")) ? l : {
|
@@ -14122,7 +14088,7 @@ function _isSlot(e) {
|
|
14122
14088
|
const KgVarConfigModalVarVarCatalog = defineComponent({
|
14123
14089
|
name: "KgVarConfigModalVarVarCatalog",
|
14124
14090
|
setup() {
|
14125
|
-
const e = inject(DI_CONFIG_FORM_ID, null), t = useKg(), r = useKgVarStore()(), n = useKgVarConfigStore()(), a = ref(!1), o = ref(!1),
|
14091
|
+
const e = inject(DI_CONFIG_FORM_ID, null), t = useKg(), r = useKgVarStore()(), n = useKgVarConfigStore()(), a = ref(!1), o = ref(!1), i = ref(!1), s = ref(null), l = ref({
|
14126
14092
|
var_text: ""
|
14127
14093
|
}), u = ref([]), c = ref(null), g = ref([]), p = ref({
|
14128
14094
|
fixed: !0,
|
@@ -14132,7 +14098,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14132
14098
|
onSelect: ($) => w($)
|
14133
14099
|
}), b = ref({
|
14134
14100
|
visible: !1
|
14135
|
-
}), m = computed(() => !!(unref(c) || unref(a) || unref(o) || unref(
|
14101
|
+
}), m = computed(() => !!(unref(c) || unref(a) || unref(o) || unref(i))), v = computed(() => {
|
14136
14102
|
var $;
|
14137
14103
|
return !!c.value || (($ = n.getSelectedVarCatalog) == null ? void 0 : $.cust_lvl) === KG_CUSTOM_LEVEL.L0;
|
14138
14104
|
}), _ = computed(() => !!(!unref(c) || unref(a) || unref(o))), y = computed(() => !!(!unref(n.getSelectedVarCatalog) || unref(a)));
|
@@ -14142,7 +14108,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14142
14108
|
immediate: !0
|
14143
14109
|
}), watch(() => n.getSelectedVarCatalog, async ($) => {
|
14144
14110
|
var P, D;
|
14145
|
-
l.value.var_text = (P = $ == null ? void 0 : $.var_text) != null ? P : "", (D =
|
14111
|
+
l.value.var_text = (P = $ == null ? void 0 : $.var_text) != null ? P : "", (D = s.value) == null || D.clearValidate();
|
14146
14112
|
});
|
14147
14113
|
async function C($ = !1) {
|
14148
14114
|
var P, D, V;
|
@@ -14177,7 +14143,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14177
14143
|
async function E() {
|
14178
14144
|
var $, P, D;
|
14179
14145
|
try {
|
14180
|
-
o.value = !0, await (($ =
|
14146
|
+
o.value = !0, await (($ = s.value) == null ? void 0 : $.validate());
|
14181
14147
|
const V = new VarCatalog({
|
14182
14148
|
...(P = n.getSelectedVarCatalog) != null ? P : {},
|
14183
14149
|
var_text: (D = l.value) == null ? void 0 : D.var_text
|
@@ -14281,7 +14247,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14281
14247
|
return createVNode("div", {
|
14282
14248
|
class: "form"
|
14283
14249
|
}, [createVNode(Form, {
|
14284
|
-
ref:
|
14250
|
+
ref: s,
|
14285
14251
|
model: l.value,
|
14286
14252
|
onSubmit: E
|
14287
14253
|
}, {
|
@@ -14363,7 +14329,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14363
14329
|
o();
|
14364
14330
|
});
|
14365
14331
|
async function o() {
|
14366
|
-
var
|
14332
|
+
var s;
|
14367
14333
|
if (!!(e != null && e.value)) {
|
14368
14334
|
n.value = !0;
|
14369
14335
|
try {
|
@@ -14376,7 +14342,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14376
14342
|
frm_id: e == null ? void 0 : e.value
|
14377
14343
|
}
|
14378
14344
|
});
|
14379
|
-
a.value = sortBy$1(l != null ? l : [], [(u) => u.frm_id === "ALL" ? 1 : -1, (u) => u.var_nam]), r.setSelectedVar((
|
14345
|
+
a.value = sortBy$1(l != null ? l : [], [(u) => u.frm_id === "ALL" ? 1 : -1, (u) => u.var_nam]), r.setSelectedVar((s = a.value[0]) != null ? s : null);
|
14380
14346
|
} catch (l) {
|
14381
14347
|
console.error(l);
|
14382
14348
|
} finally {
|
@@ -14384,14 +14350,14 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14384
14350
|
}
|
14385
14351
|
}
|
14386
14352
|
}
|
14387
|
-
function s
|
14353
|
+
function i(s) {
|
14388
14354
|
var l;
|
14389
|
-
((l = r.getSelectedVar) == null ? void 0 : l.id) !==
|
14355
|
+
((l = r.getSelectedVar) == null ? void 0 : l.id) !== s.id && (r.getSelectedVarCatalog && !r.getSelectedVarCatalog.id ? KgUtil.confirm({
|
14390
14356
|
content: t.t("kg.KgVarConfig.discardConfirmMessage"),
|
14391
14357
|
onOk: () => {
|
14392
|
-
r.setSelectedVarCatalog(null), r.setSelectedVar(unref(
|
14358
|
+
r.setSelectedVarCatalog(null), r.setSelectedVar(unref(s));
|
14393
14359
|
}
|
14394
|
-
}) : r.setSelectedVar(unref(
|
14360
|
+
}) : r.setSelectedVar(unref(s)));
|
14395
14361
|
}
|
14396
14362
|
return () => createVNode(Card, {
|
14397
14363
|
class: "kg-var-config-modal-var-vars",
|
@@ -14410,12 +14376,12 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14410
14376
|
columns: columns(),
|
14411
14377
|
dataSource: a.value,
|
14412
14378
|
loading: n.value,
|
14413
|
-
rowClassName: (
|
14379
|
+
rowClassName: (s) => {
|
14414
14380
|
var l;
|
14415
|
-
return unref(
|
14381
|
+
return unref(s).id === ((l = r.getSelectedVar) == null ? void 0 : l.id) ? "ant-table-row-selected" : "";
|
14416
14382
|
},
|
14417
|
-
customRow: (
|
14418
|
-
onClick: () => s
|
14383
|
+
customRow: (s) => ({
|
14384
|
+
onClick: () => i(s)
|
14419
14385
|
})
|
14420
14386
|
}, null)]
|
14421
14387
|
});
|
@@ -14461,8 +14427,8 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14461
14427
|
emit: t
|
14462
14428
|
}) {
|
14463
14429
|
const r = inject(DI_CONFIG_FORM_ID, null), n = useKg(), a = ref("1");
|
14464
|
-
watch(() => e.visible, (
|
14465
|
-
|
14430
|
+
watch(() => e.visible, (i) => {
|
14431
|
+
i && (a.value = "1");
|
14466
14432
|
});
|
14467
14433
|
function o() {
|
14468
14434
|
t("update:visible", !1);
|
@@ -14478,7 +14444,7 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14478
14444
|
}, {
|
14479
14445
|
default: () => [createVNode(Tabs, {
|
14480
14446
|
activeKey: a.value,
|
14481
|
-
"onUpdate:activeKey": (
|
14447
|
+
"onUpdate:activeKey": (i) => a.value = i,
|
14482
14448
|
size: "small"
|
14483
14449
|
}, {
|
14484
14450
|
default: () => createVNode(Fragment, null, [createVNode(Tabs.TabPane, {
|
@@ -14533,8 +14499,8 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14533
14499
|
}), a = ref({
|
14534
14500
|
visible: !1
|
14535
14501
|
});
|
14536
|
-
watch(t["Ctrl+Shift+F5"], (
|
14537
|
-
if (!!
|
14502
|
+
watch(t["Ctrl+Shift+F5"], (i) => {
|
14503
|
+
if (!!i)
|
14538
14504
|
if (n.value.visible)
|
14539
14505
|
n.value.visible = !1;
|
14540
14506
|
else
|
@@ -14552,17 +14518,17 @@ const KgVarConfigModalVarVarCatalog = defineComponent({
|
|
14552
14518
|
}, {
|
14553
14519
|
immediate: !0
|
14554
14520
|
});
|
14555
|
-
function o(
|
14556
|
-
r.value =
|
14521
|
+
function o(i) {
|
14522
|
+
r.value = i, n.value.visible = !n.value.visible;
|
14557
14523
|
}
|
14558
14524
|
return () => createVNode(Fragment, null, [createVNode(KgVarConfigFormIDsModal, {
|
14559
14525
|
visible: a.value.visible,
|
14560
14526
|
formIDs: e.getTopFormIDs,
|
14561
|
-
"onUpdate:visible": (
|
14527
|
+
"onUpdate:visible": (i) => a.value.visible = i,
|
14562
14528
|
onKgOk: o
|
14563
14529
|
}, null), createVNode(KgVarConfigModal, {
|
14564
14530
|
visible: n.value.visible,
|
14565
|
-
"onUpdate:visible": (
|
14531
|
+
"onUpdate:visible": (i) => n.value.visible = i
|
14566
14532
|
}, null)]);
|
14567
14533
|
}
|
14568
14534
|
}), WAREHOUSE_000000 = "data:image/svg+xml;base64,PHN2ZyBmaWxsPSdub25lJyBoZWlnaHQ9JzE0JyBzdHlsZT0nY29sb3I6IzAwMDAwMGQ5Oycgdmlld0JveD0nMCAwIDI0IDI0JyB3aWR0aD0nMTQnIHhtbG5zPSdodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2Zyc+DQogIDxwYXRoDQogICAgY2xpcC1ydWxlPSdldmVub2RkJw0KICAgIGQ9J003Ljg5MDI5IDYuMjA3MzlDOC4xNjMwNyA1Ljk5NzU1IDguNTI0NTkgNS45NDI3MyA4Ljg0NzMxIDYuMDYyMjZMMjIuMzQ3MyAxMS4wNjIzQzIyLjczOTYgMTEuMjA3NiAyMyAxMS41ODE3IDIzIDEyVjIyQzIzIDIyLjU1MjMgMjIuNTUyMyAyMyAyMiAyM0gyQzEuNDQ3NzIgMjMgMSAyMi41NTIzIDEgMjJWMTJDMSAxMS42ODk1IDEuMTQ0MiAxMS4zOTY3IDEuMzkwMjkgMTEuMjA3NEw3Ljg5MDI5IDYuMjA3MzlaTTE0IDIxSDE2LjVWMTYuNzIwOEwxNCAxNS44ODc0VjIxWk0xOC41IDIxVjE2QzE4LjUgMTUuNTY5NiAxOC4yMjQ2IDE1LjE4NzQgMTcuODE2MiAxNS4wNTEzTDEzLjMxNjIgMTMuNTUxM0MxMy4wMTEzIDEzLjQ0OTcgMTIuNjc2MSAxMy41MDA4IDEyLjQxNTMgMTMuNjg4OEMxMi4xNTQ1IDEzLjg3NjcgMTIgMTQuMTc4NiAxMiAxNC41VjIxSDkuNVY4LjQzNjc2TDIxIDEyLjY5NlYyMUgxOC41Wk03LjUgOS4wMzA4N1YyMUgzVjEyLjQ5MjRMNy41IDkuMDMwODdaJw0KICAgIGZpbGw9J2N1cnJlbnRDb2xvcicNCiAgICBmaWxsLW9wYWNpdHk9JzAuODUnDQogICAgZmlsbC1ydWxlPSdldmVub2RkJw0KICAvPg0KPC9zdmc+DQo=", WAREHOUSE_1890ff = "data:image/svg+xml;base64,PHN2ZyBmaWxsPSdub25lJyBoZWlnaHQ9JzE0JyBzdHlsZT0nY29sb3I6IzE4OTBmZjsnIHZpZXdCb3g9JzAgMCAyNCAyNCcgd2lkdGg9JzE0JyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnPg0KICA8cGF0aA0KICAgIGNsaXAtcnVsZT0nZXZlbm9kZCcNCiAgICBkPSdNNy44OTAyOSA2LjIwNzM5QzguMTYzMDcgNS45OTc1NSA4LjUyNDU5IDUuOTQyNzMgOC44NDczMSA2LjA2MjI2TDIyLjM0NzMgMTEuMDYyM0MyMi43Mzk2IDExLjIwNzYgMjMgMTEuNTgxNyAyMyAxMlYyMkMyMyAyMi41NTIzIDIyLjU1MjMgMjMgMjIgMjNIMkMxLjQ0NzcyIDIzIDEgMjIuNTUyMyAxIDIyVjEyQzEgMTEuNjg5NSAxLjE0NDIgMTEuMzk2NyAxLjM5MDI5IDExLjIwNzRMNy44OTAyOSA2LjIwNzM5Wk0xNCAyMUgxNi41VjE2LjcyMDhMMTQgMTUuODg3NFYyMVpNMTguNSAyMVYxNkMxOC41IDE1LjU2OTYgMTguMjI0NiAxNS4xODc0IDE3LjgxNjIgMTUuMDUxM0wxMy4zMTYyIDEzLjU1MTNDMTMuMDExMyAxMy40NDk3IDEyLjY3NjEgMTMuNTAwOCAxMi40MTUzIDEzLjY4ODhDMTIuMTU0NSAxMy44NzY3IDEyIDE0LjE3ODYgMTIgMTQuNVYyMUg5LjVWOC40MzY3NkwyMSAxMi42OTZWMjFIMTguNVpNNy41IDkuMDMwODdWMjFIM1YxMi40OTI0TDcuNSA5LjAzMDg3WicNCiAgICBmaWxsPSdjdXJyZW50Q29sb3InDQogICAgZmlsbC1vcGFjaXR5PScwLjg1Jw0KICAgIGZpbGwtcnVsZT0nZXZlbm9kZCcNCiAgLz4NCjwvc3ZnPg0K", LOCAL_STORAGE_KEY = "KgWarehouse.warehouse";
|
@@ -14581,10 +14547,10 @@ const useKgWarehouseStore = (e) => (store || (store = defineStore("KgWarehouse",
|
|
14581
14547
|
var r, n, a, o;
|
14582
14548
|
const t = this.warehouse || store_legacy.get(LOCAL_STORAGE_KEY, null);
|
14583
14549
|
if (!t) {
|
14584
|
-
const
|
14585
|
-
if (((n = (r =
|
14586
|
-
const
|
14587
|
-
return
|
14550
|
+
const i = useKg(e);
|
14551
|
+
if (((n = (r = i.option.value) == null ? void 0 : r.KgWarehouse) == null ? void 0 : n.enable) === !1) {
|
14552
|
+
const s = (o = (a = i.option.value) == null ? void 0 : a.KgWarehouse) == null ? void 0 : o.defaultWarehouseID;
|
14553
|
+
return s ? { whId: s } : null;
|
14588
14554
|
}
|
14589
14555
|
}
|
14590
14556
|
return t;
|
@@ -14654,14 +14620,14 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14654
14620
|
const r = useKg(), n = useKgWarehouse(), a = computed(() => {
|
14655
14621
|
let T = "jeecg-layout-header-action__item kg-warehouse";
|
14656
14622
|
return (!p.value || e.kgInvisible) && (T += " kg-warehouse--invisible"), T;
|
14657
|
-
}), o = ref(""),
|
14623
|
+
}), o = ref(""), i = n.warehouse, s = ref(null), l = ref(!1), u = reactive([{
|
14658
14624
|
width: 80,
|
14659
14625
|
align: "center",
|
14660
14626
|
customRender: ({
|
14661
14627
|
record: T
|
14662
14628
|
}) => {
|
14663
14629
|
var k;
|
14664
|
-
return T.id === ((k =
|
14630
|
+
return T.id === ((k = s.value) == null ? void 0 : k.id) ? createVNode("img", {
|
14665
14631
|
src: WAREHOUSE_1890ff
|
14666
14632
|
}, null) : createVNode("img", {
|
14667
14633
|
src: WAREHOUSE_000000
|
@@ -14699,14 +14665,14 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14699
14665
|
!p.value || n.store.setVisible(!0);
|
14700
14666
|
}
|
14701
14667
|
function m() {
|
14702
|
-
|
14668
|
+
s.value = n.warehouse.value, y();
|
14703
14669
|
}
|
14704
14670
|
function v() {
|
14705
|
-
o.value = "", c.value = [],
|
14671
|
+
o.value = "", c.value = [], s.value = null;
|
14706
14672
|
}
|
14707
14673
|
function _() {
|
14708
14674
|
var T;
|
14709
|
-
!
|
14675
|
+
!s.value || (e.kgInvisible ? (n.store.setWarehouse(s.value), t("kgOk")) : s.value.id !== ((T = n.warehouse.value) == null ? void 0 : T.id) && (n.store.setWarehouse(s.value), KgUtil.confirm({
|
14710
14676
|
content: r.t("kg.KgWarehouse.reloadMessage"),
|
14711
14677
|
kgHideCancelButton: !0,
|
14712
14678
|
okButtonProps: {
|
@@ -14740,10 +14706,10 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14740
14706
|
var k;
|
14741
14707
|
switch (T.detail) {
|
14742
14708
|
case 1:
|
14743
|
-
((k =
|
14709
|
+
((k = s.value) == null ? void 0 : k.id) === I.id ? s.value = null : s.value = I;
|
14744
14710
|
break;
|
14745
14711
|
case 2:
|
14746
|
-
|
14712
|
+
s.value = I, _();
|
14747
14713
|
break;
|
14748
14714
|
}
|
14749
14715
|
}
|
@@ -14754,7 +14720,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14754
14720
|
}, {
|
14755
14721
|
default: () => {
|
14756
14722
|
var T, I;
|
14757
|
-
return [((T =
|
14723
|
+
return [((T = i.value) == null ? void 0 : T.whDsc) || ((I = i.value) == null ? void 0 : I.whId) || r.t("kg.KgWarehouse.selectWarehouse")];
|
14758
14724
|
}
|
14759
14725
|
}), createVNode(KgModal, {
|
14760
14726
|
visible: n.visible.value,
|
@@ -14763,13 +14729,13 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14763
14729
|
width: "500px",
|
14764
14730
|
kgFullHeight: !1,
|
14765
14731
|
wrapClassName: "kg-warehouse-modal",
|
14766
|
-
closable: !e.kgInvisible && !l.value && !!
|
14767
|
-
kgShowCancelButton: !e.kgInvisible && !!
|
14732
|
+
closable: !e.kgInvisible && !l.value && !!s.value,
|
14733
|
+
kgShowCancelButton: !e.kgInvisible && !!s.value,
|
14768
14734
|
cancelButtonProps: {
|
14769
14735
|
disabled: l.value
|
14770
14736
|
},
|
14771
14737
|
okButtonProps: {
|
14772
|
-
disabled: l.value || !
|
14738
|
+
disabled: l.value || !s.value
|
14773
14739
|
},
|
14774
14740
|
onOk: _
|
14775
14741
|
}, {
|
@@ -14798,7 +14764,7 @@ const KgWarehouse$1 = "", getProps = () => ({
|
|
14798
14764
|
customRow: (T) => {
|
14799
14765
|
var I;
|
14800
14766
|
return {
|
14801
|
-
class: T.id === ((I =
|
14767
|
+
class: T.id === ((I = s.value) == null ? void 0 : I.id) ? "selected" : "",
|
14802
14768
|
onClick: (k) => C(k, T)
|
14803
14769
|
};
|
14804
14770
|
}
|
@@ -14823,10 +14789,10 @@ function createKgWarehouseGuard(e, t) {
|
|
14823
14789
|
if (e.currentRoute.value.path === "/login")
|
14824
14790
|
return;
|
14825
14791
|
n.store.setVisible(!0);
|
14826
|
-
const
|
14792
|
+
const i = watch(
|
14827
14793
|
n.warehouse,
|
14828
|
-
(
|
14829
|
-
|
14794
|
+
(s) => {
|
14795
|
+
s && setTimeout(() => i());
|
14830
14796
|
},
|
14831
14797
|
{ immediate: !0 }
|
14832
14798
|
);
|