@gisce/react-ooui 2.124.0-alpha.1 → 2.124.0-alpha.3
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/{TabContent-964a4dca.mjs → TabContent-6443e6f3.mjs} +277 -257
- package/dist/TabContent-6443e6f3.mjs.map +1 -0
- package/dist/docs.es.js +1 -1
- package/dist/helpers/formHelper.d.ts.map +1 -1
- package/dist/react-ooui.es.js +3 -3
- package/dist/widgets/base/Char.d.ts.map +1 -1
- package/dist/widgets/base/Reference.d.ts.map +1 -1
- package/dist/widgets/base/many2one/Many2one.d.ts.map +1 -1
- package/dist/widgets/modals/FormModal.d.ts.map +1 -1
- package/dist/widgets/modals/SearchModal.d.ts.map +1 -1
- package/dist/widgets/views/searchFilter/SearchField.d.ts.map +1 -1
- package/package.json +2 -2
- package/dist/TabContent-964a4dca.mjs.map +0 -1
|
@@ -17,11 +17,12 @@ import $u from "dayjs/plugin/relativeTime";
|
|
|
17
17
|
import Pu from "dayjs/plugin/weekday";
|
|
18
18
|
import Lu from "dayjs/plugin/localeData";
|
|
19
19
|
import { useLocale as De, Icon as Lr, iconMapper as Lt, useNotificationContext as Vu, FormigaConfigProvider as Bu, mergeStrings as Hu, Many2OneSuffix as ju, Many2OneSuffixModal as Oi, Dropdown as Cl, ToggleDropdownButton as Uu, getTablerIcon as In, DropdownButton as _n, DateValue as Wu, DateTimeValue as zu, useDatePickerLocale as Yu, SkeletonPill as qu, PaginationHeader as Gu, FieldSet as xl, ExportModal as Ku, DateMaskedInput as Sl, DateInput as Ju, HTMLPreview as Qu } from "@gisce/react-formiga-components";
|
|
20
|
+
import yt from "antd/es/alert/ErrorBoundary";
|
|
20
21
|
import Xu from "antd/lib/input/TextArea";
|
|
21
22
|
import ut from "styled-components";
|
|
22
23
|
import Ws from "react-measure";
|
|
23
24
|
import Tl from "lodash/debounce";
|
|
24
|
-
import { useDeepCompareEffect as Je, useDeepCompareCallback as lt, useDeepCompareMemo as
|
|
25
|
+
import { useDeepCompareEffect as Je, useDeepCompareCallback as lt, useDeepCompareMemo as wt } from "use-deep-compare";
|
|
25
26
|
import { nanoid as Vo } from "nanoid";
|
|
26
27
|
import { generate as Zu } from "@ant-design/colors";
|
|
27
28
|
import Ts from "antd/lib/typography/Title";
|
|
@@ -32,7 +33,6 @@ import { InfiniteTable as zs, Table as of, PaginatedTable as sf } from "@gisce/r
|
|
|
32
33
|
import Al from "antd/es/typography/Link";
|
|
33
34
|
import { isPresetStatusColor as Il, isPresetColor as El } from "antd/lib/_util/colors";
|
|
34
35
|
import af from "validator";
|
|
35
|
-
import It from "antd/es/alert/ErrorBoundary";
|
|
36
36
|
import "@gisce/react-formiga-table/style.css";
|
|
37
37
|
import { GridUi as lf } from "@gisce/fiber-diagram";
|
|
38
38
|
import cf from "tinycolor2";
|
|
@@ -970,7 +970,7 @@ Vr.displayName = "BaseInput";
|
|
|
970
970
|
const Pl = (t) => {
|
|
971
971
|
const { ooui: e, isSearchField: n = !1 } = t, { id: r, readOnly: o, required: i, translatable: a } = e;
|
|
972
972
|
let d = /* @__PURE__ */ s(Ll, { ooui: e, isSearchField: n });
|
|
973
|
-
return a && !o && !n && (d = /* @__PURE__ */ s(Vl, { ooui: e, field: r })), /* @__PURE__ */ s(tt, { required: i, ...t, children: d });
|
|
973
|
+
return a && !o && !n && (d = /* @__PURE__ */ s(Vl, { ooui: e, field: r })), /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(tt, { required: i, ...t, children: d }) });
|
|
974
974
|
}, Ll = nt(
|
|
975
975
|
({
|
|
976
976
|
value: t,
|
|
@@ -978,11 +978,17 @@ const Pl = (t) => {
|
|
|
978
978
|
isSearchField: n,
|
|
979
979
|
onChange: r
|
|
980
980
|
}) => {
|
|
981
|
-
const o = Ne(ft), { elementHasLostFocus: i } = o || {}, { readOnly: a, isPassword: d, translatable: c, required: l } = e, f = J(() =>
|
|
981
|
+
const o = Ne(ft), { elementHasLostFocus: i } = o || {}, { readOnly: a, isPassword: d, translatable: c, required: l } = e, f = J(() => {
|
|
982
|
+
var h;
|
|
983
|
+
return t && ((h = e.selectionValues) != null && h.size ? e.selectionValues.get(t) : Array.isArray(t) ? t[1] : t);
|
|
984
|
+
}, [e, t]), u = J(
|
|
982
985
|
() => l && !a,
|
|
983
986
|
[l, a]
|
|
984
987
|
), m = J(
|
|
985
|
-
() =>
|
|
988
|
+
() => {
|
|
989
|
+
var h;
|
|
990
|
+
return Array.isArray(t) || !!((h = e.selectionValues) != null && h.size);
|
|
991
|
+
},
|
|
986
992
|
[t, e.selectionValues]
|
|
987
993
|
), p = S(
|
|
988
994
|
(h) => {
|
|
@@ -1207,31 +1213,36 @@ const om = ut(Mt)`
|
|
|
1207
1213
|
}) => {
|
|
1208
1214
|
const r = {};
|
|
1209
1215
|
return Object.keys(e).forEach((o) => {
|
|
1210
|
-
var a, d;
|
|
1216
|
+
var a, d, c;
|
|
1211
1217
|
if (n[o] ? n[o].type === "one2many" || n[o].type === "many2many" : !1) {
|
|
1212
|
-
const
|
|
1213
|
-
if (
|
|
1218
|
+
const l = JSON.stringify(t[o]), f = JSON.stringify(e[o]);
|
|
1219
|
+
if (l === f)
|
|
1214
1220
|
return;
|
|
1215
1221
|
(((d = (a = e[o]) == null ? void 0 : a.items) == null ? void 0 : d.filter(
|
|
1216
|
-
(
|
|
1222
|
+
(m) => m.operation !== "original"
|
|
1217
1223
|
)) || []).length > 0 && (r[o] = e[o]);
|
|
1218
1224
|
} else if (Array.isArray(e[o]))
|
|
1219
1225
|
if (n[o].type === "many2one") {
|
|
1220
1226
|
if (!ki(t[o]) && !ki(e[o]))
|
|
1221
1227
|
return;
|
|
1222
1228
|
if (Array.isArray(t[o])) {
|
|
1223
|
-
const
|
|
1224
|
-
|
|
1229
|
+
const l = JSON.stringify(t[o]), f = JSON.stringify(e[o]);
|
|
1230
|
+
l !== f && (r[o] = e[o]);
|
|
1225
1231
|
} else {
|
|
1226
|
-
const
|
|
1227
|
-
|
|
1232
|
+
const l = t[o], [f] = e[o];
|
|
1233
|
+
l !== f && (r[o] = e[o]);
|
|
1228
1234
|
}
|
|
1229
1235
|
} else {
|
|
1230
|
-
const
|
|
1231
|
-
|
|
1236
|
+
const l = JSON.stringify(t[o]), f = JSON.stringify(e[o]);
|
|
1237
|
+
l !== f && (r[o] = e[o]);
|
|
1232
1238
|
}
|
|
1233
|
-
else
|
|
1234
|
-
|
|
1239
|
+
else if (t[o] === void 0 && e[o] !== void 0)
|
|
1240
|
+
r[o] = e[o];
|
|
1241
|
+
else if (((c = n[o]) == null ? void 0 : c.type) === "json") {
|
|
1242
|
+
const l = typeof t[o] == "object" ? JSON.stringify(t[o], null, " ") : t[o], f = typeof e[o] == "object" ? JSON.stringify(e[o], null, " ") : e[o];
|
|
1243
|
+
l !== f && (r[o] = e[o]);
|
|
1244
|
+
} else
|
|
1245
|
+
t[o] !== e[o] && (e[o] === void 0 ? r[o] = null : r[o] = e[o]);
|
|
1235
1246
|
}), r;
|
|
1236
1247
|
}, vm = ({
|
|
1237
1248
|
changedFields: t,
|
|
@@ -1920,7 +1931,7 @@ const Ln = ({
|
|
|
1920
1931
|
"useConfigContext must be used within a ConfigContextProvider"
|
|
1921
1932
|
);
|
|
1922
1933
|
return t;
|
|
1923
|
-
},
|
|
1934
|
+
}, Tt = (t) => {
|
|
1924
1935
|
const { userFeatures: e } = on();
|
|
1925
1936
|
return !!e.features[t];
|
|
1926
1937
|
}, rn = (t) => {
|
|
@@ -2935,8 +2946,8 @@ const Wm = zt(jm), zm = ({
|
|
|
2935
2946
|
});
|
|
2936
2947
|
return [...new Set(r.filter((o) => o in t))];
|
|
2937
2948
|
};
|
|
2938
|
-
var
|
|
2939
|
-
const ES = Object.values(
|
|
2949
|
+
var Ct = /* @__PURE__ */ ((t) => (t.FEATURE_MANY2ONE_DISABLE_ARROW_MENU = "widget.many2one.disable.arrow_menu", t.FEATURE_MANY2ONE_DISABLE_FOLDER = "widget.many2one.disable.folder", t.FEATURE_MANY2ONE_SELECTION_TO_LAZY = "widget.many2one.selection_to_many2onelazy", t.FEATURE_ONE2MANY_ENABLE_NEW_TABLE = "widget.one2many.enable_new_table", t.FEATURE_DATE_USE_MASKED_INPUT = "widget.date.use_masked_input", t.FEATURE_TEST_FEATURE = "test.feature", t))(Ct || {});
|
|
2950
|
+
const ES = Object.values(Ct), { defaultAlgorithm: qm, defaultSeed: Gm } = ot, An = qm(Gm), Km = (t) => {
|
|
2940
2951
|
const { ooui: e } = t, { required: n } = e;
|
|
2941
2952
|
return /* @__PURE__ */ s(tt, { required: n, type: "array", validator: async (o, i) => {
|
|
2942
2953
|
if (!i)
|
|
@@ -2975,8 +2986,8 @@ const ES = Object.values(wt), { defaultAlgorithm: qm, defaultSeed: Gm } = ot, An
|
|
|
2975
2986
|
model: a,
|
|
2976
2987
|
permissions: ["create"],
|
|
2977
2988
|
enabled: !0
|
|
2978
|
-
}), V = (X == null ? void 0 : X.create) ?? !1, B =
|
|
2979
|
-
|
|
2989
|
+
}), V = (X == null ? void 0 : X.create) ?? !1, B = Tt(
|
|
2990
|
+
Ct.FEATURE_MANY2ONE_DISABLE_ARROW_MENU
|
|
2980
2991
|
), N = J(() => {
|
|
2981
2992
|
let Z = !0;
|
|
2982
2993
|
return B === !0 && (Z = !1), r.showMenu !== void 0 && (Z = r.showMenu), Z;
|
|
@@ -6362,8 +6373,8 @@ const fh = (t) => /* @__PURE__ */ s(tt, { ...t, children: /* @__PURE__ */ s(_c,
|
|
|
6362
6373
|
padding-left: 10px;
|
|
6363
6374
|
white-space: nowrap;
|
|
6364
6375
|
`, gh = (t) => {
|
|
6365
|
-
const { m2oField: e, ooui: n } = t, r =
|
|
6366
|
-
|
|
6376
|
+
const { m2oField: e, ooui: n } = t, r = Tt(
|
|
6377
|
+
Ct.FEATURE_MANY2ONE_DISABLE_ARROW_MENU
|
|
6367
6378
|
), o = J(() => {
|
|
6368
6379
|
let i = !0;
|
|
6369
6380
|
return r === !0 && (i = !1), n.showMenu !== void 0 && (i = n.showMenu), i;
|
|
@@ -6373,8 +6384,8 @@ const fh = (t) => /* @__PURE__ */ s(tt, { ...t, children: /* @__PURE__ */ s(_c,
|
|
|
6373
6384
|
o && /* @__PURE__ */ s(vr, { id: e.id, model: e.model })
|
|
6374
6385
|
] }) : /* @__PURE__ */ s(Fe, {});
|
|
6375
6386
|
}, yh = (t) => {
|
|
6376
|
-
const { value: e, selectionValues: n } = t, r =
|
|
6377
|
-
|
|
6387
|
+
const { value: e, selectionValues: n } = t, r = Tt(
|
|
6388
|
+
Ct.FEATURE_MANY2ONE_DISABLE_ARROW_MENU
|
|
6378
6389
|
);
|
|
6379
6390
|
if (!e || !e.model || !e.name)
|
|
6380
6391
|
return /* @__PURE__ */ s(Fe, {});
|
|
@@ -6860,7 +6871,7 @@ const Sh = ({
|
|
|
6860
6871
|
ooui: e,
|
|
6861
6872
|
context: n
|
|
6862
6873
|
}) => {
|
|
6863
|
-
const r =
|
|
6874
|
+
const r = wt(
|
|
6864
6875
|
() => (t == null ? void 0 : t.items) || [],
|
|
6865
6876
|
[t == null ? void 0 : t.items]
|
|
6866
6877
|
), o = J(
|
|
@@ -6965,9 +6976,9 @@ const jr = ({
|
|
|
6965
6976
|
tableRef: o
|
|
6966
6977
|
}), f = rn(
|
|
6967
6978
|
kt.FEATURE_MANY2ONE_SORT
|
|
6968
|
-
), u =
|
|
6969
|
-
|
|
6970
|
-
), m =
|
|
6979
|
+
), u = Tt(
|
|
6980
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
6981
|
+
), m = wt(() => {
|
|
6971
6982
|
if (t)
|
|
6972
6983
|
return Ks(
|
|
6973
6984
|
t,
|
|
@@ -7047,7 +7058,7 @@ const Yo = nt(
|
|
|
7047
7058
|
o,
|
|
7048
7059
|
i < a.length - 1 ? /* @__PURE__ */ s("span", { style: { margin: "0 8px", color: n.colorBorder }, children: "|" }) : ""
|
|
7049
7060
|
] }, i)) : null, [t, n.colorBorder]);
|
|
7050
|
-
return /* @__PURE__ */ s(
|
|
7061
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ H(
|
|
7051
7062
|
"div",
|
|
7052
7063
|
{
|
|
7053
7064
|
style: {
|
|
@@ -7074,7 +7085,7 @@ const Gi = ["sum", "count", "max", "min"], si = ({
|
|
|
7074
7085
|
}) => {
|
|
7075
7086
|
const [o, i] = E(), [a, d] = E(!1), [c, l] = ke(
|
|
7076
7087
|
K.getHandler().readAggregates
|
|
7077
|
-
), f =
|
|
7088
|
+
), f = wt(() => {
|
|
7078
7089
|
if (t)
|
|
7079
7090
|
return t.columns.filter((p) => Object.keys(p).some((g) => {
|
|
7080
7091
|
var h;
|
|
@@ -7673,8 +7684,8 @@ function Nc(t) {
|
|
|
7673
7684
|
var f, u;
|
|
7674
7685
|
const { field: e } = t;
|
|
7675
7686
|
e.readOnly = !1, e.required = !1;
|
|
7676
|
-
const { t: n } = De(), r =
|
|
7677
|
-
|
|
7687
|
+
const { t: n } = De(), r = Tt(
|
|
7688
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
7678
7689
|
), o = e.type, i = (f = e.raw_props) == null ? void 0 : f.widget, a = e.fieldType, d = e, c = d.relation || ((u = d.raw_props) == null ? void 0 : u.relation);
|
|
7679
7690
|
if (c && (i === "many2one_lazy" || r && i === "selection" && a === "many2one")) {
|
|
7680
7691
|
const m = new Fo({
|
|
@@ -7713,7 +7724,7 @@ function Nc(t) {
|
|
|
7713
7724
|
case Dn.selection:
|
|
7714
7725
|
return /* @__PURE__ */ s(mg, { layout: "vertical", ooui: e, showLabel: !0 });
|
|
7715
7726
|
default:
|
|
7716
|
-
return /* @__PURE__ */ s(
|
|
7727
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
7717
7728
|
Pl,
|
|
7718
7729
|
{
|
|
7719
7730
|
ooui: e,
|
|
@@ -7721,7 +7732,7 @@ function Nc(t) {
|
|
|
7721
7732
|
showLabel: !0,
|
|
7722
7733
|
isSearchField: !0
|
|
7723
7734
|
}
|
|
7724
|
-
);
|
|
7735
|
+
) });
|
|
7725
7736
|
}
|
|
7726
7737
|
}
|
|
7727
7738
|
const { useToken: vg } = ot, { Title: bg } = Jt, { Header: wg, Content: Cg, Footer: xg } = el, Sg = ({
|
|
@@ -9263,12 +9274,12 @@ const mi = (t) => {
|
|
|
9263
9274
|
searchValues: d,
|
|
9264
9275
|
currentModel: c,
|
|
9265
9276
|
context: l
|
|
9266
|
-
} = t, f = Q(), { t: u } = De(), m =
|
|
9267
|
-
|
|
9277
|
+
} = t, f = Q(), { t: u } = De(), m = Tt(
|
|
9278
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
9268
9279
|
), p = Q(), g = Q(null), {
|
|
9269
9280
|
currentSavedSearch: h,
|
|
9270
9281
|
searchParams: y
|
|
9271
|
-
} = Yt(), [v, b] = E([]), [C, x] = E({}), w =
|
|
9282
|
+
} = Yt(), [v, b] = E([]), [C, x] = E({}), w = wt(() => v, [v]), _ = wt(() => `${u("filter")} (${(w == null ? void 0 : w.length) || 0})`, [u, w]), T = wt(() => {
|
|
9272
9283
|
if (!C)
|
|
9273
9284
|
return 0;
|
|
9274
9285
|
const oe = /* @__PURE__ */ new Set();
|
|
@@ -9397,7 +9408,7 @@ const mi = (t) => {
|
|
|
9397
9408
|
(ue = g.current) == null || ue.resetFields(), (ae = g.current) == null || ae.setFieldsValue({}), (ce = (fe = g.current) == null ? void 0 : fe.resetInitialValues) == null || ce.call(fe), b([]), x({}), V(), o && o();
|
|
9398
9409
|
},
|
|
9399
9410
|
[v, o, V]
|
|
9400
|
-
), ie =
|
|
9411
|
+
), ie = wt(() => N ? U ? /* @__PURE__ */ H(ht.Compact, { size: "small", children: [
|
|
9401
9412
|
/* @__PURE__ */ s(
|
|
9402
9413
|
Ke,
|
|
9403
9414
|
{
|
|
@@ -9652,8 +9663,8 @@ function Ko(t) {
|
|
|
9652
9663
|
searchError: u,
|
|
9653
9664
|
searchValues: m,
|
|
9654
9665
|
showLimitOptions: p = !0
|
|
9655
|
-
} = t, [g, h] = E(), [y, v] = E(), [b, C] = E(!1), x = Q(), { token: w } = Uv(), _ =
|
|
9656
|
-
|
|
9666
|
+
} = t, [g, h] = E(), [y, v] = E(), [b, C] = E(!1), x = Q(), { token: w } = Uv(), _ = Tt(
|
|
9667
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
9657
9668
|
), [T] = Dt.useForm();
|
|
9658
9669
|
he(() => {
|
|
9659
9670
|
T.setFieldsValue(m);
|
|
@@ -9852,8 +9863,8 @@ const Er = () => {
|
|
|
9852
9863
|
onExternalRecordsUpdate: l,
|
|
9853
9864
|
skipFunctionFieldsHandling: f = !1
|
|
9854
9865
|
}) => {
|
|
9855
|
-
const u =
|
|
9856
|
-
|
|
9866
|
+
const u = Tt(
|
|
9867
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
9857
9868
|
), [m, p] = E(!1), g = Q([]), h = e == null ? void 0 : e.fields, y = (e == null ? void 0 : e.fields_in_conditions) !== void 0, [v, b] = E(
|
|
9858
9869
|
/* @__PURE__ */ new Set()
|
|
9859
9870
|
), C = Q(/* @__PURE__ */ new Set()), x = Q([]), w = Q(null), [_, T] = E(!0), [A, O] = ke(
|
|
@@ -10045,8 +10056,8 @@ const Er = () => {
|
|
|
10045
10056
|
treeView: c,
|
|
10046
10057
|
results: l,
|
|
10047
10058
|
onRecordsUpdated: f
|
|
10048
|
-
} = t, u =
|
|
10049
|
-
|
|
10059
|
+
} = t, u = Tt(
|
|
10060
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
10050
10061
|
), m = J(() => c != null && c.field_parent ? { ...c == null ? void 0 : c.fields, [c == null ? void 0 : c.field_parent]: {} } : c == null ? void 0 : c.fields, [c]), p = (c == null ? void 0 : c.fields_in_conditions) !== void 0, g = Q(null), [h, y] = E(!0), [v, b] = ke(
|
|
10051
10062
|
K.getHandler().readObjects
|
|
10052
10063
|
), [C, x] = ke(
|
|
@@ -10321,7 +10332,7 @@ const Er = () => {
|
|
|
10321
10332
|
record: e,
|
|
10322
10333
|
column: n,
|
|
10323
10334
|
isFieldLoading: r
|
|
10324
|
-
}) => r != null && r(e, n.key) ? /* @__PURE__ */ s(qu, {}) : /* @__PURE__ */ s(
|
|
10335
|
+
}) => r != null && r(e, n.key) ? /* @__PURE__ */ s(qu, {}) : /* @__PURE__ */ s(yt, { children: n.render(t, n.key, n == null ? void 0 : n.ooui, n == null ? void 0 : n.context) })
|
|
10325
10336
|
);
|
|
10326
10337
|
Jo.displayName = "CellRenderer";
|
|
10327
10338
|
const md = ({
|
|
@@ -10353,8 +10364,8 @@ function Xv(t, e) {
|
|
|
10353
10364
|
fixedHeight: y,
|
|
10354
10365
|
autoRefresh: v
|
|
10355
10366
|
} = t, b = Q(null);
|
|
10356
|
-
|
|
10357
|
-
|
|
10367
|
+
Tt(
|
|
10368
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
10358
10369
|
);
|
|
10359
10370
|
const C = Q([]), x = Q(!1), { showErrorNotification: w } = Et(), { setCurrentSavedSearch: _ } = Yt(), [T, A] = E(), [O, D] = E(!1), P = Q(), M = Q(null), F = ni({
|
|
10360
10371
|
elementRef: M,
|
|
@@ -10402,9 +10413,9 @@ function Xv(t, e) {
|
|
|
10402
10413
|
(rt = b.current) == null || rt.scrollToTop();
|
|
10403
10414
|
}, 0)), P.current = T, Le.current = me;
|
|
10404
10415
|
}, [T]), he(() => {
|
|
10405
|
-
var Bt,
|
|
10416
|
+
var Bt, It, pn, er;
|
|
10406
10417
|
const rt = me && me.trim().length > 0, gt = we.current && typeof we.current == "string" && we.current.trim().length > 0;
|
|
10407
|
-
rt && !gt || rt && gt && me !== we.current ? (Ve.current = !0, ie == null || ie([]), re == null || re({}), Rt([]), (Bt = b.current) == null || Bt.unselectAll(), te == null || te(0), (
|
|
10418
|
+
rt && !gt || rt && gt && me !== we.current ? (Ve.current = !0, ie == null || ie([]), re == null || re({}), Rt([]), (Bt = b.current) == null || Bt.unselectAll(), te == null || te(0), (It = b.current) == null || It.scrollToTop()) : !rt && gt && (Ve.current = !1, Rt([]), (pn = b.current) == null || pn.unselectAll(), te == null || te(0), (er = b.current) == null || er.scrollToTop(), setTimeout(() => {
|
|
10408
10419
|
ze.current = !0, pt();
|
|
10409
10420
|
}, 0)), we.current = me;
|
|
10410
10421
|
}, [me]);
|
|
@@ -10438,7 +10449,7 @@ function Xv(t, e) {
|
|
|
10438
10449
|
clearAutorefreshableFields: $e,
|
|
10439
10450
|
addRecordsToCheckFunctionFields: Oe,
|
|
10440
10451
|
onHasFunctionFieldsToParseConditions: qe,
|
|
10441
|
-
shouldMakeDeferredFunctionRead:
|
|
10452
|
+
shouldMakeDeferredFunctionRead: _t
|
|
10442
10453
|
} = hi({
|
|
10443
10454
|
model: n,
|
|
10444
10455
|
treeView: B,
|
|
@@ -10449,35 +10460,35 @@ function Xv(t, e) {
|
|
|
10449
10460
|
updateAttributes: le,
|
|
10450
10461
|
results: fe,
|
|
10451
10462
|
autoRefresh: v
|
|
10452
|
-
}),
|
|
10463
|
+
}), At = J(() => (de == null ? void 0 : de.map((rt) => rt.id)) || [], [de]), vt = J(() => {
|
|
10453
10464
|
if (!He)
|
|
10454
10465
|
return;
|
|
10455
10466
|
const rt = me !== void 0;
|
|
10456
10467
|
return He.map((gt) => ({
|
|
10457
10468
|
...gt,
|
|
10458
10469
|
isSortable: rt ? !1 : gt.isSortable,
|
|
10459
|
-
render: (Bt,
|
|
10470
|
+
render: (Bt, It) => /* @__PURE__ */ s(
|
|
10460
10471
|
Jo,
|
|
10461
10472
|
{
|
|
10462
10473
|
value: Bt,
|
|
10463
|
-
record:
|
|
10474
|
+
record: It,
|
|
10464
10475
|
column: gt,
|
|
10465
10476
|
isFieldLoading: _e
|
|
10466
10477
|
}
|
|
10467
10478
|
)
|
|
10468
10479
|
}));
|
|
10469
|
-
}, [He, _e, me]),
|
|
10480
|
+
}, [He, _e, me]), xt = J(
|
|
10470
10481
|
() => bn(oe || [], a),
|
|
10471
10482
|
[a, oe]
|
|
10472
10483
|
), Vt = S(() => {
|
|
10473
|
-
const gt = `${JSON.stringify(me ? a :
|
|
10484
|
+
const gt = `${JSON.stringify(me ? a : xt)}-${me}`;
|
|
10474
10485
|
return gt !== Be.current ? (Be.current = gt, !0) : !1;
|
|
10475
|
-
}, [a,
|
|
10486
|
+
}, [a, xt, me]), tn = S(async () => {
|
|
10476
10487
|
if (!me && !Ie.current) {
|
|
10477
10488
|
Ie.current = !0;
|
|
10478
10489
|
try {
|
|
10479
10490
|
const rt = await I({
|
|
10480
|
-
params: me ? a :
|
|
10491
|
+
params: me ? a : xt,
|
|
10481
10492
|
model: n,
|
|
10482
10493
|
context: l,
|
|
10483
10494
|
name_search: me
|
|
@@ -10491,7 +10502,7 @@ function Xv(t, e) {
|
|
|
10491
10502
|
}
|
|
10492
10503
|
}, [
|
|
10493
10504
|
a,
|
|
10494
|
-
|
|
10505
|
+
xt,
|
|
10495
10506
|
n,
|
|
10496
10507
|
me,
|
|
10497
10508
|
l,
|
|
@@ -10506,12 +10517,12 @@ function Xv(t, e) {
|
|
|
10506
10517
|
}) => {
|
|
10507
10518
|
if (!Re)
|
|
10508
10519
|
return [];
|
|
10509
|
-
let
|
|
10520
|
+
let It;
|
|
10510
10521
|
if (!x.current && Me) {
|
|
10511
10522
|
const Ft = yr({
|
|
10512
10523
|
state: Me
|
|
10513
10524
|
});
|
|
10514
|
-
|
|
10525
|
+
It = Hr(Ft);
|
|
10515
10526
|
} else {
|
|
10516
10527
|
const Ft = Bt == null ? void 0 : Bt.filter((On) => On.sort || On.sortIndex).map((On) => ({
|
|
10517
10528
|
sort: On.sort || void 0,
|
|
@@ -10520,12 +10531,12 @@ function Xv(t, e) {
|
|
|
10520
10531
|
})), ao = Ft && (Ft == null ? void 0 : Ft.length) > 0 ? Ft : void 0, Qo = yr({
|
|
10521
10532
|
state: ao
|
|
10522
10533
|
});
|
|
10523
|
-
We == null || We(ao),
|
|
10534
|
+
We == null || We(ao), It = Hr(Qo);
|
|
10524
10535
|
}
|
|
10525
10536
|
x.current = !0;
|
|
10526
|
-
const pn = me ? a :
|
|
10537
|
+
const pn = me ? a : xt, er = jr({
|
|
10527
10538
|
treeOoui: Re,
|
|
10528
|
-
hasFunctionFieldsToParseConditions:
|
|
10539
|
+
hasFunctionFieldsToParseConditions: _t && qe()
|
|
10529
10540
|
}), { results: Sn, attrsEvaluated: tr } = await $({
|
|
10530
10541
|
params: pn,
|
|
10531
10542
|
limit: gt - rt,
|
|
@@ -10534,11 +10545,11 @@ function Xv(t, e) {
|
|
|
10534
10545
|
fields: B != null && B.field_parent ? { ...B == null ? void 0 : B.fields, [B == null ? void 0 : B.field_parent]: {} } : B == null ? void 0 : B.fields,
|
|
10535
10546
|
context: l,
|
|
10536
10547
|
attrs: er,
|
|
10537
|
-
order:
|
|
10548
|
+
order: It,
|
|
10538
10549
|
name_search: me,
|
|
10539
|
-
skipFunctionFields:
|
|
10550
|
+
skipFunctionFields: _t,
|
|
10540
10551
|
onIdsRetrieved: (Ft) => {
|
|
10541
|
-
|
|
10552
|
+
_t && Oe(Ft);
|
|
10542
10553
|
}
|
|
10543
10554
|
});
|
|
10544
10555
|
if (ce == null || ce({
|
|
@@ -10546,14 +10557,14 @@ function Xv(t, e) {
|
|
|
10546
10557
|
params: pn,
|
|
10547
10558
|
name_search: me,
|
|
10548
10559
|
context: l,
|
|
10549
|
-
order:
|
|
10550
|
-
}), Vt() || Ge.current !==
|
|
10560
|
+
order: It
|
|
10561
|
+
}), Vt() || Ge.current !== It)
|
|
10551
10562
|
ae == null || ae(Sn);
|
|
10552
10563
|
else {
|
|
10553
10564
|
const Ft = [...fe || [], ...Sn];
|
|
10554
10565
|
ae == null || ae(Ft);
|
|
10555
10566
|
}
|
|
10556
|
-
if (Ge.current =
|
|
10567
|
+
if (Ge.current = It, me ? (A(Sn.length), Ee(Sn.length), D(!0)) : D(!1), Sn.length === 0)
|
|
10557
10568
|
return C.current = [], rt === 0 && (A(0), Ee(0)), [];
|
|
10558
10569
|
const nr = await ln(
|
|
10559
10570
|
Re,
|
|
@@ -10569,7 +10580,7 @@ function Xv(t, e) {
|
|
|
10569
10580
|
Me,
|
|
10570
10581
|
Oe,
|
|
10571
10582
|
a,
|
|
10572
|
-
|
|
10583
|
+
xt,
|
|
10573
10584
|
n,
|
|
10574
10585
|
Vt,
|
|
10575
10586
|
me,
|
|
@@ -10584,10 +10595,10 @@ function Xv(t, e) {
|
|
|
10584
10595
|
Re,
|
|
10585
10596
|
B,
|
|
10586
10597
|
le,
|
|
10587
|
-
|
|
10598
|
+
_t
|
|
10588
10599
|
]
|
|
10589
10600
|
), Fn = S(async () => me ? C.current : T ? (await X({
|
|
10590
|
-
params: me ? a :
|
|
10601
|
+
params: me ? a : xt,
|
|
10591
10602
|
model: n,
|
|
10592
10603
|
context: l,
|
|
10593
10604
|
totalItems: T
|
|
@@ -10596,7 +10607,7 @@ function Xv(t, e) {
|
|
|
10596
10607
|
T,
|
|
10597
10608
|
X,
|
|
10598
10609
|
a,
|
|
10599
|
-
|
|
10610
|
+
xt,
|
|
10600
10611
|
n,
|
|
10601
10612
|
l
|
|
10602
10613
|
]), {
|
|
@@ -10610,7 +10621,7 @@ function Xv(t, e) {
|
|
|
10610
10621
|
totalRows: T,
|
|
10611
10622
|
maxRowsToSelect: Qv,
|
|
10612
10623
|
onSelectAll: Fn
|
|
10613
|
-
}),
|
|
10624
|
+
}), bt = S(
|
|
10614
10625
|
async ({
|
|
10615
10626
|
startRow: rt,
|
|
10616
10627
|
endRow: gt,
|
|
@@ -10618,14 +10629,14 @@ function Xv(t, e) {
|
|
|
10618
10629
|
}) => {
|
|
10619
10630
|
try {
|
|
10620
10631
|
U == null || U(!0), rt === 0 && !me && tn();
|
|
10621
|
-
const
|
|
10632
|
+
const It = await Gt({
|
|
10622
10633
|
startRow: rt,
|
|
10623
10634
|
endRow: gt,
|
|
10624
10635
|
state: Bt
|
|
10625
10636
|
});
|
|
10626
|
-
return U == null || U(!1),
|
|
10627
|
-
} catch (
|
|
10628
|
-
throw console.error(
|
|
10637
|
+
return U == null || U(!1), It;
|
|
10638
|
+
} catch (It) {
|
|
10639
|
+
throw console.error(It), A((pn) => pn ?? 0), Ee((pn) => pn ?? 0), U == null || U(!1), w(It), It;
|
|
10629
10640
|
}
|
|
10630
10641
|
},
|
|
10631
10642
|
[
|
|
@@ -10639,7 +10650,7 @@ function Xv(t, e) {
|
|
|
10639
10650
|
), { footerComponent: mn } = Oc({
|
|
10640
10651
|
treeOoui: Re,
|
|
10641
10652
|
model: n,
|
|
10642
|
-
selectedRowKeys:
|
|
10653
|
+
selectedRowKeys: At,
|
|
10643
10654
|
showEmptyValues: !0
|
|
10644
10655
|
}), cn = Q(ye);
|
|
10645
10656
|
cn.current = ye;
|
|
@@ -10648,14 +10659,14 @@ function Xv(t, e) {
|
|
|
10648
10659
|
tableRef: b,
|
|
10649
10660
|
autoRefresh: v
|
|
10650
10661
|
});
|
|
10651
|
-
const Cn = Ve.current ? qt : void 0, Ye =
|
|
10662
|
+
const Cn = Ve.current ? qt : void 0, Ye = wt(() => !vt || !Re ? null : /* @__PURE__ */ s(
|
|
10652
10663
|
zs,
|
|
10653
10664
|
{
|
|
10654
10665
|
readonly: !1,
|
|
10655
10666
|
ref: b,
|
|
10656
10667
|
height: R,
|
|
10657
|
-
columns:
|
|
10658
|
-
onRequestData:
|
|
10668
|
+
columns: vt,
|
|
10669
|
+
onRequestData: bt,
|
|
10659
10670
|
onRowDoubleClick: i,
|
|
10660
10671
|
onRowStyle: ge,
|
|
10661
10672
|
onRowSelectionChange: h ? void 0 : Qe,
|
|
@@ -10663,7 +10674,7 @@ function Xv(t, e) {
|
|
|
10663
10674
|
onGetColumnsState: Z,
|
|
10664
10675
|
onChangeFirstVisibleRowIndex: te,
|
|
10665
10676
|
onGetFirstVisibleRowIndex: dn,
|
|
10666
|
-
selectedRowKeys: h ? void 0 :
|
|
10677
|
+
selectedRowKeys: h ? void 0 : At,
|
|
10667
10678
|
onSelectionCheckboxClicked: h ? void 0 : at,
|
|
10668
10679
|
totalRows: T ?? void 0,
|
|
10669
10680
|
footer: mn,
|
|
@@ -10677,10 +10688,10 @@ function Xv(t, e) {
|
|
|
10677
10688
|
autoRefresh: v
|
|
10678
10689
|
}
|
|
10679
10690
|
), [
|
|
10680
|
-
|
|
10691
|
+
vt,
|
|
10681
10692
|
Re,
|
|
10682
10693
|
R,
|
|
10683
|
-
|
|
10694
|
+
bt,
|
|
10684
10695
|
i,
|
|
10685
10696
|
ge,
|
|
10686
10697
|
h,
|
|
@@ -10689,7 +10700,7 @@ function Xv(t, e) {
|
|
|
10689
10700
|
Z,
|
|
10690
10701
|
te,
|
|
10691
10702
|
dn,
|
|
10692
|
-
|
|
10703
|
+
At,
|
|
10693
10704
|
at,
|
|
10694
10705
|
T,
|
|
10695
10706
|
mn,
|
|
@@ -10721,7 +10732,7 @@ function Xv(t, e) {
|
|
|
10721
10732
|
refreshResults: pt,
|
|
10722
10733
|
getFields: () => B == null ? void 0 : B.fields
|
|
10723
10734
|
}));
|
|
10724
|
-
const
|
|
10735
|
+
const St = J(
|
|
10725
10736
|
() => ({
|
|
10726
10737
|
overflow: "hidden",
|
|
10727
10738
|
height: `${R}px`,
|
|
@@ -10797,8 +10808,8 @@ function Xv(t, e) {
|
|
|
10797
10808
|
[G]
|
|
10798
10809
|
), nn = S(
|
|
10799
10810
|
({ params: rt, values: gt, closeSidebar: Bt = !0 }) => {
|
|
10800
|
-
var
|
|
10801
|
-
Rt([]), (
|
|
10811
|
+
var It;
|
|
10812
|
+
Rt([]), (It = b.current) == null || It.unselectAll(), ue == null || ue(void 0), ie == null || ie(rt), re == null || re(gt), G == null || G(!Bt), Bt || pt(), (!rt || rt.length === 0) && (_ == null || _(null));
|
|
10802
10813
|
},
|
|
10803
10814
|
[
|
|
10804
10815
|
Rt,
|
|
@@ -10830,7 +10841,7 @@ function Xv(t, e) {
|
|
|
10830
10841
|
!g && /* @__PURE__ */ s(
|
|
10831
10842
|
fd,
|
|
10832
10843
|
{
|
|
10833
|
-
selectedRowKeys:
|
|
10844
|
+
selectedRowKeys: At,
|
|
10834
10845
|
totalRows: T,
|
|
10835
10846
|
customMiddleComponent: Fr && /* @__PURE__ */ s(
|
|
10836
10847
|
gi,
|
|
@@ -10840,7 +10851,7 @@ function Xv(t, e) {
|
|
|
10840
10851
|
)
|
|
10841
10852
|
}
|
|
10842
10853
|
),
|
|
10843
|
-
/* @__PURE__ */ s("div", { ref: M, style:
|
|
10854
|
+
/* @__PURE__ */ s("div", { ref: M, style: St, children: L || ee ? /* @__PURE__ */ s(ct, {}) : Ye })
|
|
10844
10855
|
] });
|
|
10845
10856
|
}
|
|
10846
10857
|
const yi = zt(Xv), Da = (t, e = "14px -apple-system") => {
|
|
@@ -10979,7 +10990,7 @@ const pd = nt(({ summary: t }) => {
|
|
|
10979
10990
|
});
|
|
10980
10991
|
pd.displayName = "SummaryValue";
|
|
10981
10992
|
const hd = nt(
|
|
10982
|
-
({ summaries: t }) => /* @__PURE__ */ s(
|
|
10993
|
+
({ summaries: t }) => /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s("div", { className: "p-1 pb-0 pl-2 mt-2", children: t.map((e, n) => /* @__PURE__ */ H("span", { children: [
|
|
10983
10994
|
e.label,
|
|
10984
10995
|
": ",
|
|
10985
10996
|
/* @__PURE__ */ s(pd, { summary: e }),
|
|
@@ -11017,8 +11028,8 @@ const gd = zt(
|
|
|
11017
11028
|
Qt
|
|
11018
11029
|
), { title: j = void 0, setTitle: X = void 0 } = (x ? $ : {}) || {}, V = rn(
|
|
11019
11030
|
kt.FEATURE_MANY2ONE_SORT
|
|
11020
|
-
), B =
|
|
11021
|
-
|
|
11031
|
+
), B = Tt(
|
|
11032
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
11022
11033
|
), N = J(() => {
|
|
11023
11034
|
if (F)
|
|
11024
11035
|
return Ks(
|
|
@@ -11121,7 +11132,7 @@ const gd = zt(
|
|
|
11121
11132
|
if (F !== null && N && N.length > 0)
|
|
11122
11133
|
return Zv(N, O, 600);
|
|
11123
11134
|
}, [N, O, F]), ye = J(() => p && (F != null && F.columns.some((ie) => ie.sum !== void 0)) ? p - 30 : p, [p, F == null ? void 0 : F.columns]);
|
|
11124
|
-
return F === null || !te || ((de = te == null ? void 0 : te.columns) == null ? void 0 : de.length) === 0 ? /* @__PURE__ */ s(ct, { style: { padding: "2rem" } }) : /* @__PURE__ */ H(
|
|
11135
|
+
return F === null || !te || ((de = te == null ? void 0 : te.columns) == null ? void 0 : de.length) === 0 ? /* @__PURE__ */ s(ct, { style: { padding: "2rem" } }) : /* @__PURE__ */ H(yt, { children: [
|
|
11125
11136
|
G,
|
|
11126
11137
|
/* @__PURE__ */ s(
|
|
11127
11138
|
of,
|
|
@@ -11186,8 +11197,8 @@ const yd = (t) => {
|
|
|
11186
11197
|
searchParams: _ = [],
|
|
11187
11198
|
setSearchValues: T,
|
|
11188
11199
|
clearSelection: A
|
|
11189
|
-
} = t, O =
|
|
11190
|
-
|
|
11200
|
+
} = t, O = Tt(
|
|
11201
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
11191
11202
|
), [D, P] = E(!1), [M, F] = E(!1), [R, I] = E(), [k, $] = E(1), [j, X] = E(0), [V, B] = E(), [N, L] = E([]), [U, z] = E(void 0), [G, ne] = E(void 0), te = Q(x || qt), ye = Q([]), de = S(
|
|
11192
11203
|
(pe) => {
|
|
11193
11204
|
y == null || y([...pe]), L([...pe]);
|
|
@@ -11701,8 +11712,8 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11701
11712
|
setOrder: G,
|
|
11702
11713
|
limit: ne,
|
|
11703
11714
|
setLimit: te
|
|
11704
|
-
} = pi({ useLocalState: !i }), { treeMaxLimit: ye } = on(), { setCurrentSavedSearch: de } = Yt(), ie =
|
|
11705
|
-
|
|
11715
|
+
} = pi({ useLocalState: !i }), { treeMaxLimit: ye } = on(), { setCurrentSavedSearch: de } = Yt(), ie = Tt(
|
|
11716
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
11706
11717
|
), se = y ? 0 : Math.min(ne, ye), [oe, re] = E(!0), [W, ue] = E(), [ae, fe] = E([]), [ce, Ee] = E(!1), pe = a || k, Me = Q(pe), We = Q(R), me = Q(x), we = Q(), Ve = Q([]), Be = Q(!1), [Ge, Ie] = ke(
|
|
11707
11718
|
K.getHandler().parseConditions
|
|
11708
11719
|
), Le = S((Ye) => {
|
|
@@ -11710,7 +11721,7 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11710
11721
|
const mt = Ye.find((pt) => pt.id === Xe.id);
|
|
11711
11722
|
return { ...Xe, ...mt };
|
|
11712
11723
|
}), fe((Xe) => Xe.map((mt) => {
|
|
11713
|
-
const pt = Ye.find((
|
|
11724
|
+
const pt = Ye.find((St) => St.id === mt.id);
|
|
11714
11725
|
return { ...mt, ...pt };
|
|
11715
11726
|
}));
|
|
11716
11727
|
}, []), {
|
|
@@ -11767,17 +11778,17 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11767
11778
|
o,
|
|
11768
11779
|
l,
|
|
11769
11780
|
ge
|
|
11770
|
-
]), Oe = S(() => A, [A]), qe = S(() => O, [O]),
|
|
11771
|
-
var Xe, mt, pt,
|
|
11772
|
-
return (pt = g == null ? void 0 : g.current) != null && pt[(mt = (Xe = Ye.node) == null ? void 0 : Xe.data) == null ? void 0 : mt.id] ? { color: g.current[(sn = (
|
|
11773
|
-
}, []),
|
|
11781
|
+
]), Oe = S(() => A, [A]), qe = S(() => O, [O]), _t = S((Ye) => {
|
|
11782
|
+
var Xe, mt, pt, St, sn;
|
|
11783
|
+
return (pt = g == null ? void 0 : g.current) != null && pt[(mt = (Xe = Ye.node) == null ? void 0 : Xe.data) == null ? void 0 : mt.id] ? { color: g.current[(sn = (St = Ye.node) == null ? void 0 : St.data) == null ? void 0 : sn.id] } : {};
|
|
11784
|
+
}, []), At = S(
|
|
11774
11785
|
(Ye) => {
|
|
11775
11786
|
var Xe;
|
|
11776
11787
|
return (Xe = h == null ? void 0 : h.current) == null ? void 0 : Xe[Ye.id];
|
|
11777
11788
|
},
|
|
11778
11789
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
11779
11790
|
[]
|
|
11780
|
-
),
|
|
11791
|
+
), vt = S(() => {
|
|
11781
11792
|
var Ye;
|
|
11782
11793
|
_([]), (Ye = d.current) == null || Ye.unselectAll(), $ == null || $(void 0), M == null || M([]), I == null || I(void 0);
|
|
11783
11794
|
}, [
|
|
@@ -11786,7 +11797,7 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11786
11797
|
$,
|
|
11787
11798
|
M,
|
|
11788
11799
|
I
|
|
11789
|
-
]),
|
|
11800
|
+
]), xt = S(
|
|
11790
11801
|
({ params: Ye, searchValues: Xe }) => {
|
|
11791
11802
|
var mt;
|
|
11792
11803
|
_([]), (mt = d.current) == null || mt.unselectAll(), $ == null || $(void 0), M == null || M(Ye), I == null || I(Xe);
|
|
@@ -11821,7 +11832,7 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11821
11832
|
hasFunctionFieldsToParseConditions: Se && je()
|
|
11822
11833
|
});
|
|
11823
11834
|
!pe && Ae() && $e();
|
|
11824
|
-
const { results: pt, attrsEvaluated:
|
|
11835
|
+
const { results: pt, attrsEvaluated: St } = await Z({
|
|
11825
11836
|
params: Xe,
|
|
11826
11837
|
limit: se,
|
|
11827
11838
|
offset: y ? 0 : ((L || 1) - 1) * se,
|
|
@@ -11851,7 +11862,7 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11851
11862
|
l,
|
|
11852
11863
|
ie
|
|
11853
11864
|
);
|
|
11854
|
-
m == null || m(
|
|
11865
|
+
m == null || m(St, n), C(!1), Ve.current = [...sn], fe([...sn]);
|
|
11855
11866
|
} catch (Ye) {
|
|
11856
11867
|
throw C(!1), ge(Ye), console.error(Ye), Ye;
|
|
11857
11868
|
} finally {
|
|
@@ -11965,10 +11976,10 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11965
11976
|
}), [ee, R, c, o, l, W]), at = S(async () => {
|
|
11966
11977
|
const Ye = await Qe();
|
|
11967
11978
|
_ == null || _(Ye.map((Xe) => ({ id: Xe })));
|
|
11968
|
-
}, [Qe, _]),
|
|
11979
|
+
}, [Qe, _]), bt = J(() => _e.length === 0 ? "unchecked" : _e.length === se && se > 0 || _e.length === W ? "checked" : "indeterminate", [_e, se, W]), mn = S(() => {
|
|
11969
11980
|
var Ye, Xe;
|
|
11970
|
-
|
|
11971
|
-
}, [d, _, ae,
|
|
11981
|
+
bt === "unchecked" ? ((Ye = d.current) == null || Ye.selectAll(), _(ae.map((mt) => ({ id: mt.id })))) : (_([]), (Xe = d.current) == null || Xe.unselectAll());
|
|
11982
|
+
}, [d, _, ae, bt]), cn = S(
|
|
11972
11983
|
(Ye) => {
|
|
11973
11984
|
G(Ye), T(0), D(void 0), U(1);
|
|
11974
11985
|
},
|
|
@@ -11982,8 +11993,8 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
11982
11993
|
({ id: Ye, selected: Xe }) => {
|
|
11983
11994
|
_((mt) => {
|
|
11984
11995
|
if (Xe) {
|
|
11985
|
-
const pt = ae.find((
|
|
11986
|
-
return pt && !mt.some((
|
|
11996
|
+
const pt = ae.find((St) => St.id === Ye);
|
|
11997
|
+
return pt && !mt.some((St) => St.id === Ye) ? [...mt, pt] : mt;
|
|
11987
11998
|
}
|
|
11988
11999
|
return mt.filter((pt) => pt.id !== Ye);
|
|
11989
12000
|
});
|
|
@@ -12008,11 +12019,11 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
12008
12019
|
ids: Xe,
|
|
12009
12020
|
fields: mt,
|
|
12010
12021
|
context: l
|
|
12011
|
-
}),
|
|
12022
|
+
}), St = await ln(
|
|
12012
12023
|
n,
|
|
12013
12024
|
pt,
|
|
12014
12025
|
l
|
|
12015
|
-
), sn = [...ae, ...
|
|
12026
|
+
), sn = [...ae, ...St], xn = jr({
|
|
12016
12027
|
treeOoui: n
|
|
12017
12028
|
});
|
|
12018
12029
|
try {
|
|
@@ -12025,7 +12036,7 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
12025
12036
|
} catch (Xt) {
|
|
12026
12037
|
console.error(Xt);
|
|
12027
12038
|
}
|
|
12028
|
-
return Ve.current = [...sn], fe([...sn]), Se && xe(pt.map((Xt) => Xt.id)),
|
|
12039
|
+
return Ve.current = [...sn], fe([...sn]), Se && xe(pt.map((Xt) => Xt.id)), St;
|
|
12029
12040
|
},
|
|
12030
12041
|
[
|
|
12031
12042
|
r,
|
|
@@ -12046,23 +12057,23 @@ const vd = zt(rb), ob = qt, sb = (t) => {
|
|
|
12046
12057
|
searchValues: F,
|
|
12047
12058
|
selectedRowKeys: _e,
|
|
12048
12059
|
refresh: Gt,
|
|
12049
|
-
onRowStatus:
|
|
12060
|
+
onRowStatus: At,
|
|
12050
12061
|
onGetFirstVisibleRowIndex: Oe,
|
|
12051
12062
|
setTreeFirstVisibleRow: T,
|
|
12052
12063
|
onRowHasBeenSelected: dn,
|
|
12053
|
-
onSearchFilterClear:
|
|
12054
|
-
onSearchFilterSubmit:
|
|
12064
|
+
onSearchFilterClear: vt,
|
|
12065
|
+
onSearchFilterSubmit: xt,
|
|
12055
12066
|
onSideSearchFilterClose: Vt,
|
|
12056
12067
|
onSideSearchFilterSubmit: Fn,
|
|
12057
12068
|
totalRowsLoading: oe,
|
|
12058
12069
|
totalRows: W,
|
|
12059
|
-
onRowStyle:
|
|
12070
|
+
onRowStyle: _t,
|
|
12060
12071
|
results: ae,
|
|
12061
12072
|
onRequestPageChange: Rt,
|
|
12062
12073
|
treeIsLoading: b,
|
|
12063
12074
|
selectAllRecords: at,
|
|
12064
12075
|
onHeaderCheckboxClick: mn,
|
|
12065
|
-
headerCheckboxState:
|
|
12076
|
+
headerCheckboxState: bt,
|
|
12066
12077
|
currentPage: L,
|
|
12067
12078
|
limit: se,
|
|
12068
12079
|
order: z,
|
|
@@ -12376,11 +12387,11 @@ function ub(t, e) {
|
|
|
12376
12387
|
return V.map((qe) => ({
|
|
12377
12388
|
...qe,
|
|
12378
12389
|
isSortable: Oe ? !1 : qe.isSortable,
|
|
12379
|
-
render: (
|
|
12390
|
+
render: (_t, At) => /* @__PURE__ */ s(
|
|
12380
12391
|
Jo,
|
|
12381
12392
|
{
|
|
12382
|
-
value:
|
|
12383
|
-
record:
|
|
12393
|
+
value: _t,
|
|
12394
|
+
record: At,
|
|
12384
12395
|
column: qe,
|
|
12385
12396
|
isFieldLoading: Ie
|
|
12386
12397
|
}
|
|
@@ -12840,7 +12851,7 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
12840
12851
|
P || []
|
|
12841
12852
|
), [re, W] = E(!1), [ue, ae] = E(!0), [fe, ce] = E(), Ee = S(() => {
|
|
12842
12853
|
ce(n), c();
|
|
12843
|
-
}, [n, c, ce]), pe = J(() => !i || i.length === 0 ? (n == null ? void 0 : n.fields) || {} : i.reduce((
|
|
12854
|
+
}, [n, c, ce]), pe = J(() => !i || i.length === 0 ? (n == null ? void 0 : n.fields) || {} : i.reduce((vt, xt) => ({ ...vt, ...xt.fields || {} }), {}), [i, n]), [Me, We] = E(
|
|
12844
12855
|
fc(P || [], pe)
|
|
12845
12856
|
), [me, we] = E(0), [Ve, Be] = E(void 0), [Ge, Ie] = E(), [Le, ze] = E(qn), [Re, He] = E(
|
|
12846
12857
|
F
|
|
@@ -12850,9 +12861,9 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
12850
12861
|
M || 1
|
|
12851
12862
|
), [Z, q] = E(null), [ee, le] = E([]), [Ce, _e] = E(
|
|
12852
12863
|
$ ?? !1
|
|
12853
|
-
), [Ae, $e] = E(0), [Oe, qe] = E({ fn: void 0 }),
|
|
12854
|
-
(
|
|
12855
|
-
qe({ fn:
|
|
12864
|
+
), [Ae, $e] = E(0), [Oe, qe] = E({ fn: void 0 }), _t = S(
|
|
12865
|
+
(vt) => {
|
|
12866
|
+
qe({ fn: vt });
|
|
12856
12867
|
},
|
|
12857
12868
|
[]
|
|
12858
12869
|
);
|
|
@@ -12863,19 +12874,19 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
12863
12874
|
}, [O]), he(() => {
|
|
12864
12875
|
i.length === 1 ? ce(i[0]) : i.length > 1 && ce(
|
|
12865
12876
|
i.filter(
|
|
12866
|
-
(
|
|
12877
|
+
(vt) => vt.view_id !== n.view_id
|
|
12867
12878
|
)[0]
|
|
12868
12879
|
);
|
|
12869
12880
|
}, [i]), he(() => {
|
|
12870
12881
|
(fe == null ? void 0 : fe.view_id) === n.view_id && i.length > 1 && ce(
|
|
12871
12882
|
i.filter(
|
|
12872
|
-
(
|
|
12883
|
+
(vt) => vt.view_id !== n.view_id
|
|
12873
12884
|
)[0]
|
|
12874
12885
|
);
|
|
12875
12886
|
}, [n]);
|
|
12876
|
-
const
|
|
12877
|
-
var
|
|
12878
|
-
return await ((
|
|
12887
|
+
const At = async () => {
|
|
12888
|
+
var vt;
|
|
12889
|
+
return await ((vt = a.current) == null ? void 0 : vt.submitForm());
|
|
12879
12890
|
};
|
|
12880
12891
|
return /* @__PURE__ */ s(
|
|
12881
12892
|
Qt.Provider,
|
|
@@ -12891,7 +12902,7 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
12891
12902
|
setFormHasChanges: B,
|
|
12892
12903
|
formRef: a,
|
|
12893
12904
|
viewRef: d,
|
|
12894
|
-
onFormSave:
|
|
12905
|
+
onFormSave: At,
|
|
12895
12906
|
onNewClicked: Ee,
|
|
12896
12907
|
currentId: l,
|
|
12897
12908
|
setCurrentId: f,
|
|
@@ -12954,7 +12965,7 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
12954
12965
|
commentCount: Ae,
|
|
12955
12966
|
setCommentCount: $e,
|
|
12956
12967
|
refreshComments: Oe.fn,
|
|
12957
|
-
setRefreshComments:
|
|
12968
|
+
setRefreshComments: _t,
|
|
12958
12969
|
permissions: R,
|
|
12959
12970
|
permissionsLoading: I,
|
|
12960
12971
|
permissionsError: k
|
|
@@ -13326,8 +13337,8 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
13326
13337
|
]
|
|
13327
13338
|
}
|
|
13328
13339
|
),
|
|
13329
|
-
!l && /* @__PURE__ */ s("div", { style: { padding: 10 }, children: /* @__PURE__ */ s(
|
|
13330
|
-
l && /* @__PURE__ */ s(
|
|
13340
|
+
!l && /* @__PURE__ */ s("div", { style: { padding: 10 }, children: /* @__PURE__ */ s(yt, { children: n }) }),
|
|
13341
|
+
l && /* @__PURE__ */ s(yt, { children: n })
|
|
13331
13342
|
]
|
|
13332
13343
|
}
|
|
13333
13344
|
);
|
|
@@ -13421,7 +13432,7 @@ const bd = zt(ub), { useToken: fb } = ot, wd = ({
|
|
|
13421
13432
|
cancelRequest: d
|
|
13422
13433
|
};
|
|
13423
13434
|
}, xd = (t) => {
|
|
13424
|
-
const { model: e, view_id: n, fixedHeight: r, autoRefresh: o, actionDomain: i } = t, [a, d] = E(), c = Q(null), l = Q(null), { isActive: f } = Yt(), u = Er(), m =
|
|
13435
|
+
const { model: e, view_id: n, fixedHeight: r, autoRefresh: o, actionDomain: i } = t, [a, d] = E(), c = Q(null), l = Q(null), { isActive: f } = Yt(), u = Er(), m = wt(() => Ul(i || []), [i]), [p, g] = ke(
|
|
13425
13436
|
K.getHandler().search
|
|
13426
13437
|
);
|
|
13427
13438
|
he(() => () => {
|
|
@@ -13629,15 +13640,15 @@ function xb(t) {
|
|
|
13629
13640
|
}
|
|
13630
13641
|
const Sd = nt(xb), { useToken: Sb } = ot, Tb = 3 * 1e3, _b = (t) => {
|
|
13631
13642
|
const { ooui: e } = t, { refreshCounter: n } = Qr(), r = e.actionId !== void 0, o = e.actionField !== void 0;
|
|
13632
|
-
return /* @__PURE__ */ s(tt, { ooui: e, children: r || o ? /* @__PURE__ */ s(
|
|
13643
|
+
return /* @__PURE__ */ s(tt, { ooui: e, children: r || o ? /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(Ib, { ooui: e }, n) }) : /* @__PURE__ */ s(Ab, { ooui: e }, n) });
|
|
13633
13644
|
}, Ab = (t) => {
|
|
13634
13645
|
var T;
|
|
13635
13646
|
const { token: e } = Sb(), { ooui: n, value: r } = t, { locale: o } = De(), { getContext: i } = Qr(), [a, d] = E(n.icon), [c, l] = E(n.color), [f, u] = E(null), [m, p] = E(!1), [g, h] = ke(
|
|
13636
13647
|
K.getHandler().parseCondition
|
|
13637
13648
|
), { fetchReferenceValues: y } = Cb({
|
|
13638
13649
|
context: i == null ? void 0 : i()
|
|
13639
|
-
}), v =
|
|
13640
|
-
|
|
13650
|
+
}), v = Tt(
|
|
13651
|
+
Ct.FEATURE_MANY2ONE_DISABLE_ARROW_MENU
|
|
13641
13652
|
);
|
|
13642
13653
|
he(() => {
|
|
13643
13654
|
async function A(O, D) {
|
|
@@ -13953,7 +13964,7 @@ const Sd = nt(xb), { useToken: Sb } = ot, Tb = 3 * 1e3, _b = (t) => {
|
|
|
13953
13964
|
) }) });
|
|
13954
13965
|
}, Db = (t) => {
|
|
13955
13966
|
const { ooui: e } = t;
|
|
13956
|
-
return /* @__PURE__ */ s(
|
|
13967
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(tt, { ...t, children: /* @__PURE__ */ s(Mb, { ...t, ooui: e }) }) });
|
|
13957
13968
|
}, Mb = (t) => {
|
|
13958
13969
|
var u, m, p;
|
|
13959
13970
|
const { value: e, ooui: n } = t, r = Ne(
|
|
@@ -14310,8 +14321,8 @@ const Vb = (t) => {
|
|
|
14310
14321
|
}, Yb = (t) => t.map((n) => n.reduce((r, o) => r + o.colspan, 0)).reduce((n, r) => Math.max(n, r)), wi = (t) => {
|
|
14311
14322
|
const { container: e, responsiveBehaviour: n } = t, { rows: r } = e;
|
|
14312
14323
|
let { columns: o } = e;
|
|
14313
|
-
const i =
|
|
14314
|
-
|
|
14324
|
+
const i = Tt(
|
|
14325
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
14315
14326
|
), a = Yb(r);
|
|
14316
14327
|
a < o && (o = a);
|
|
14317
14328
|
let d = !1, c = [];
|
|
@@ -14521,9 +14532,9 @@ function Zb(t, e) {
|
|
|
14521
14532
|
} = Qb();
|
|
14522
14533
|
en(e, () => ({
|
|
14523
14534
|
submitForm: Xt,
|
|
14524
|
-
getFields:
|
|
14535
|
+
getFields: _t,
|
|
14525
14536
|
getValues: at,
|
|
14526
|
-
getPlainValues:
|
|
14537
|
+
getPlainValues: At,
|
|
14527
14538
|
getContext: Vt,
|
|
14528
14539
|
fetchValues: Xe,
|
|
14529
14540
|
cancelUnsavedChanges: mt,
|
|
@@ -14559,11 +14570,11 @@ function Zb(t, e) {
|
|
|
14559
14570
|
}, $e = (be) => {
|
|
14560
14571
|
me == null || me(!1), f == null || f(be);
|
|
14561
14572
|
}, Oe = S(() => r || ye.current, [r]), qe = r || ye.current;
|
|
14562
|
-
function
|
|
14573
|
+
function _t() {
|
|
14563
14574
|
return V;
|
|
14564
14575
|
}
|
|
14565
|
-
function
|
|
14566
|
-
const be = at(), Te =
|
|
14576
|
+
function At() {
|
|
14577
|
+
const be = at(), Te = _t(), Pe = {};
|
|
14567
14578
|
return Object.keys(be).forEach((Ue) => {
|
|
14568
14579
|
const Ze = be[Ue];
|
|
14569
14580
|
Te[Ue] && Te[Ue].type === "many2one" && Ze && Array.isArray(Ze) && Ze.length === 2 ? Pe[Ue] = Ze[0] : Te[Ue] && (Te[Ue].type === "one2many" || Te[Ue].type === "many2many") && Ze && Ze.items ? Pe[Ue] = Ze.items.filter((Ot) => Ot.operation !== "pendingRemove").map((Ot) => Ot.id) : Pe[Ue] = Ze;
|
|
@@ -14572,15 +14583,15 @@ function Zb(t, e) {
|
|
|
14572
14583
|
...Pe
|
|
14573
14584
|
};
|
|
14574
14585
|
}
|
|
14575
|
-
function
|
|
14576
|
-
const be =
|
|
14586
|
+
function vt() {
|
|
14587
|
+
const be = At(), Te = pe == null ? void 0 : pe();
|
|
14577
14588
|
return Te ? {
|
|
14578
14589
|
...be,
|
|
14579
14590
|
parent: Te
|
|
14580
14591
|
// Keep parent values separately in case you need them
|
|
14581
14592
|
} : be;
|
|
14582
14593
|
}
|
|
14583
|
-
function
|
|
14594
|
+
function xt() {
|
|
14584
14595
|
const be = {
|
|
14585
14596
|
...Qe(V)
|
|
14586
14597
|
};
|
|
@@ -14628,7 +14639,7 @@ function Zb(t, e) {
|
|
|
14628
14639
|
for (const Te in be)
|
|
14629
14640
|
be[Te] === void 0 && delete be[Te];
|
|
14630
14641
|
return be;
|
|
14631
|
-
}, [Qe, Gt, V]),
|
|
14642
|
+
}, [Qe, Gt, V]), bt = S(() => {
|
|
14632
14643
|
Me.current && (O == null || O()), me == null || me(!1), i == null || i({ id: Oe(), values: at() });
|
|
14633
14644
|
}, [
|
|
14634
14645
|
Oe,
|
|
@@ -14652,7 +14663,7 @@ function Zb(t, e) {
|
|
|
14652
14663
|
action_id: -1,
|
|
14653
14664
|
action_type: "ir.actions.act_window",
|
|
14654
14665
|
readOnly: u
|
|
14655
|
-
}),
|
|
14666
|
+
}), bt == null || bt();
|
|
14656
14667
|
}, [
|
|
14657
14668
|
Se,
|
|
14658
14669
|
qe,
|
|
@@ -14662,10 +14673,10 @@ function Zb(t, e) {
|
|
|
14662
14673
|
Ie,
|
|
14663
14674
|
o,
|
|
14664
14675
|
h,
|
|
14665
|
-
|
|
14676
|
+
bt,
|
|
14666
14677
|
u
|
|
14667
14678
|
]), cn = (be, Te) => {
|
|
14668
|
-
|
|
14679
|
+
St({
|
|
14669
14680
|
values: {
|
|
14670
14681
|
...Hn($.getFieldsValue(!0), V),
|
|
14671
14682
|
[be]: Te
|
|
@@ -14700,7 +14711,7 @@ function Zb(t, e) {
|
|
|
14700
14711
|
Be == null || Be(!0), R(void 0), Ce(), be != null && be.fields ? (Pe = be.fields, Ue = be.arch) : (Pe = V, Ue = j), g && (be == null ? void 0 : be.forceRefresh) !== !0 ? Te = g : { values: Te, defaultGetCalled: Ze } = await sn({
|
|
14701
14712
|
fields: Pe,
|
|
14702
14713
|
arch: Ue
|
|
14703
|
-
}), C && (Te = { ...Ul(C), ...Te }), de.current = Hn(Te, Pe), ie.current === null && (ie.current = Hn(Te, Pe)),
|
|
14714
|
+
}), C && (Te = { ...Ul(C), ...Te }), de.current = Hn(Te, Pe), ie.current === null && (ie.current = Hn(Te, Pe)), St({
|
|
14704
14715
|
values: Te,
|
|
14705
14716
|
fields: Pe,
|
|
14706
14717
|
reset: !0,
|
|
@@ -14710,12 +14721,12 @@ function Zb(t, e) {
|
|
|
14710
14721
|
Rt() ? _r({
|
|
14711
14722
|
t: D,
|
|
14712
14723
|
onOk: () => {
|
|
14713
|
-
|
|
14724
|
+
bt == null || bt(), be(!0);
|
|
14714
14725
|
},
|
|
14715
14726
|
onCancel: () => {
|
|
14716
14727
|
be(!1);
|
|
14717
14728
|
}
|
|
14718
|
-
}) : (
|
|
14729
|
+
}) : (bt == null || bt(), be(!0));
|
|
14719
14730
|
}), pt = async () => {
|
|
14720
14731
|
if (c) {
|
|
14721
14732
|
const be = await K.getHandler().getActionStringForModel(n);
|
|
@@ -14730,7 +14741,7 @@ function Zb(t, e) {
|
|
|
14730
14741
|
id: o,
|
|
14731
14742
|
context: b
|
|
14732
14743
|
});
|
|
14733
|
-
},
|
|
14744
|
+
}, St = S(
|
|
14734
14745
|
({
|
|
14735
14746
|
values: be,
|
|
14736
14747
|
fields: Te,
|
|
@@ -14809,10 +14820,10 @@ function Zb(t, e) {
|
|
|
14809
14820
|
});
|
|
14810
14821
|
ye.current = Ue, de.current = Pe;
|
|
14811
14822
|
}
|
|
14812
|
-
y && await y([Oe()]), !v && Te && (Ae == null || Ae(Oe(), at(),
|
|
14823
|
+
y && await y([Oe()]), !v && Te && (Ae == null || Ae(Oe(), at(), xt()));
|
|
14813
14824
|
}, Zn = async (be) => {
|
|
14814
14825
|
const { callOnSubmitSucceed: Te = !0 } = be || {};
|
|
14815
|
-
!v && Te && (Ae == null || Ae(Oe(), at(),
|
|
14826
|
+
!v && Te && (Ae == null || Ae(Oe(), at(), xt()));
|
|
14816
14827
|
}, Xt = async (be) => {
|
|
14817
14828
|
let Te = !1;
|
|
14818
14829
|
const { callOnSubmitSucceed: Pe = !0 } = be || {};
|
|
@@ -14820,11 +14831,11 @@ function Zb(t, e) {
|
|
|
14820
14831
|
W.current = !1, we == null || we(!1), Ae == null || Ae(
|
|
14821
14832
|
Oe(),
|
|
14822
14833
|
at(),
|
|
14823
|
-
|
|
14834
|
+
xt(),
|
|
14824
14835
|
ue.current
|
|
14825
14836
|
), ue.current = !1;
|
|
14826
14837
|
const Ue = Oe();
|
|
14827
|
-
return m && (ye.current = void 0,
|
|
14838
|
+
return m && (ye.current = void 0, St({
|
|
14828
14839
|
values: oe.current,
|
|
14829
14840
|
fields: V,
|
|
14830
14841
|
reset: !0
|
|
@@ -14836,7 +14847,7 @@ function Zb(t, e) {
|
|
|
14836
14847
|
target: Ue,
|
|
14837
14848
|
fields: V
|
|
14838
14849
|
});
|
|
14839
|
-
return Object.keys(Ze).length > 0 ? (W.current = !1, we == null || we(!1), Ae == null || Ae(Oe(), at(),
|
|
14850
|
+
return Object.keys(Ze).length > 0 ? (W.current = !1, we == null || we(!1), Ae == null || Ae(Oe(), at(), xt()), { succeed: !0, id: Oe() }) : (W.current = !1, we == null || we(!1), bt == null || bt(), { succeed: !0, id: Oe() });
|
|
14840
14851
|
}
|
|
14841
14852
|
if (await Cn())
|
|
14842
14853
|
return W.current = !1, Y({
|
|
@@ -14846,7 +14857,7 @@ function Zb(t, e) {
|
|
|
14846
14857
|
}), { succeed: !1, id: Oe() };
|
|
14847
14858
|
M(!0), me == null || me(!0);
|
|
14848
14859
|
try {
|
|
14849
|
-
p === "api" ? await xn(be) : await Zn(be), m && (ye.current = void 0,
|
|
14860
|
+
p === "api" ? await xn(be) : await Zn(be), m && (ye.current = void 0, St({
|
|
14850
14861
|
values: oe.current,
|
|
14851
14862
|
fields: V,
|
|
14852
14863
|
reset: !0
|
|
@@ -14976,7 +14987,7 @@ function Zb(t, e) {
|
|
|
14976
14987
|
fields: V,
|
|
14977
14988
|
arch: j,
|
|
14978
14989
|
values: Ot
|
|
14979
|
-
}),
|
|
14990
|
+
}), St({
|
|
14980
14991
|
values: Ot,
|
|
14981
14992
|
fields: V,
|
|
14982
14993
|
reset: !1
|
|
@@ -15011,7 +15022,7 @@ function Zb(t, e) {
|
|
|
15011
15022
|
}), B(Ze);
|
|
15012
15023
|
}
|
|
15013
15024
|
};
|
|
15014
|
-
async function
|
|
15025
|
+
async function It({
|
|
15015
15026
|
action: be,
|
|
15016
15027
|
context: Te
|
|
15017
15028
|
}) {
|
|
@@ -15026,9 +15037,9 @@ function Zb(t, e) {
|
|
|
15026
15037
|
}
|
|
15027
15038
|
});
|
|
15028
15039
|
if (typeof Pe == "object" && Pe !== null && Object.keys(Pe).length === 0 && v)
|
|
15029
|
-
Ae == null || Ae(Oe(), at(),
|
|
15040
|
+
Ae == null || Ae(Oe(), at(), xt());
|
|
15030
15041
|
else if (Pe.type && Pe.type === Mm)
|
|
15031
|
-
Ae == null || Ae(Oe(), at(),
|
|
15042
|
+
Ae == null || Ae(Oe(), at(), xt());
|
|
15032
15043
|
else if (Pe.type && Pe.type === Pm)
|
|
15033
15044
|
ge == null || ge(Pe);
|
|
15034
15045
|
else if (Pe.type) {
|
|
@@ -15050,7 +15061,7 @@ function Zb(t, e) {
|
|
|
15050
15061
|
action: be,
|
|
15051
15062
|
payload: Oe()
|
|
15052
15063
|
});
|
|
15053
|
-
Te.type && Te.type === "ir.actions.act_window_close" ? Ae == null || Ae(Oe(), at(),
|
|
15064
|
+
Te.type && Te.type === "ir.actions.act_window_close" ? Ae == null || Ae(Oe(), at(), xt()) : await Xe({ forceRefresh: !0 });
|
|
15054
15065
|
}
|
|
15055
15066
|
async function er({
|
|
15056
15067
|
action: be,
|
|
@@ -15080,7 +15091,7 @@ function Zb(t, e) {
|
|
|
15080
15091
|
Me.current = !0, await Xe({ forceRefresh: !0 });
|
|
15081
15092
|
}
|
|
15082
15093
|
})) || {};
|
|
15083
|
-
!w && Pe && (Ae == null || Ae(Oe(), at(),
|
|
15094
|
+
!w && Pe && (Ae == null || Ae(Oe(), at(), xt()));
|
|
15084
15095
|
}
|
|
15085
15096
|
function tr() {
|
|
15086
15097
|
Fr({ elementHasLostFocus: !0 });
|
|
@@ -15101,13 +15112,13 @@ function Zb(t, e) {
|
|
|
15101
15112
|
de.current = {
|
|
15102
15113
|
...de.current,
|
|
15103
15114
|
...be
|
|
15104
|
-
}, nn({ fields: V, arch: j, values: Te }),
|
|
15115
|
+
}, nn({ fields: V, arch: j, values: Te }), St({
|
|
15105
15116
|
values: Te,
|
|
15106
15117
|
fields: V,
|
|
15107
15118
|
reset: !1
|
|
15108
15119
|
});
|
|
15109
15120
|
},
|
|
15110
|
-
[j,
|
|
15121
|
+
[j, St, V, Qe, nn]
|
|
15111
15122
|
);
|
|
15112
15123
|
Jb({
|
|
15113
15124
|
model: n,
|
|
@@ -15124,7 +15135,7 @@ function Zb(t, e) {
|
|
|
15124
15135
|
context: Pe
|
|
15125
15136
|
}) {
|
|
15126
15137
|
if (be === "cancel") {
|
|
15127
|
-
|
|
15138
|
+
bt == null || bt();
|
|
15128
15139
|
return;
|
|
15129
15140
|
}
|
|
15130
15141
|
if (await Cn()) {
|
|
@@ -15139,7 +15150,7 @@ function Zb(t, e) {
|
|
|
15139
15150
|
try {
|
|
15140
15151
|
!u && (Rt() || Oe() === void 0) && (Ue = !0, nr(!0), p === "2many" ? (await xn({ callOnSubmitSucceed: !1 }), ue.current = !0) : await Xt({ callOnSubmitSucceed: !1 }));
|
|
15141
15152
|
const Ze = ue.current ? tn() : {}, Ot = { ...Pe, ...Ze };
|
|
15142
|
-
be === "object" ? await
|
|
15153
|
+
be === "object" ? await It({ action: Te, context: Ot }) : be === "workflow" ? await pn({ action: Te }) : be === "action" && await er({ action: Te, context: Ot }), Ue && nr(!1);
|
|
15143
15154
|
} catch (Ze) {
|
|
15144
15155
|
Ue && nr(!1), Y(Ze);
|
|
15145
15156
|
}
|
|
@@ -15148,9 +15159,9 @@ function Zb(t, e) {
|
|
|
15148
15159
|
Of,
|
|
15149
15160
|
{
|
|
15150
15161
|
getValues: at,
|
|
15151
|
-
getPlainValues:
|
|
15152
|
-
getAllHierarchyValues:
|
|
15153
|
-
getFields:
|
|
15162
|
+
getPlainValues: At,
|
|
15163
|
+
getAllHierarchyValues: vt,
|
|
15164
|
+
getFields: _t,
|
|
15154
15165
|
domain: C,
|
|
15155
15166
|
activeId: qe,
|
|
15156
15167
|
activeModel: n,
|
|
@@ -15453,7 +15464,7 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15453
15464
|
destroyOnClose: !0,
|
|
15454
15465
|
onCancel: () => i == null ? void 0 : i(),
|
|
15455
15466
|
maskClosable: !1,
|
|
15456
|
-
children: /* @__PURE__ */ s(
|
|
15467
|
+
children: /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
15457
15468
|
Rr,
|
|
15458
15469
|
{
|
|
15459
15470
|
id: n || b,
|
|
@@ -15464,7 +15475,7 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15464
15475
|
...c
|
|
15465
15476
|
},
|
|
15466
15477
|
`${l}-${n}-${v}-${b}-${C}-${x}-${r}`
|
|
15467
|
-
)
|
|
15478
|
+
) })
|
|
15468
15479
|
}
|
|
15469
15480
|
),
|
|
15470
15481
|
/* @__PURE__ */ s(
|
|
@@ -15549,7 +15560,7 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15549
15560
|
destroyOnClose: !0,
|
|
15550
15561
|
maskClosable: !1,
|
|
15551
15562
|
children: [
|
|
15552
|
-
!x && /* @__PURE__ */ s(
|
|
15563
|
+
!x && /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
15553
15564
|
D,
|
|
15554
15565
|
{
|
|
15555
15566
|
formView: C,
|
|
@@ -15563,7 +15574,7 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15563
15574
|
onChangeSelectedRowKeys: u,
|
|
15564
15575
|
filterType: "top"
|
|
15565
15576
|
}
|
|
15566
|
-
),
|
|
15577
|
+
) }),
|
|
15567
15578
|
/* @__PURE__ */ s(Yr, {}),
|
|
15568
15579
|
/* @__PURE__ */ s(dt, { justify: "end", children: /* @__PURE__ */ H(ht, { children: [
|
|
15569
15580
|
/* @__PURE__ */ s(
|
|
@@ -15603,14 +15614,23 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15603
15614
|
] });
|
|
15604
15615
|
}, { defaultAlgorithm: nw, defaultSeed: rw } = ot, _d = nw(rw), ow = (t) => {
|
|
15605
15616
|
const { ooui: e } = t, { required: n } = e;
|
|
15606
|
-
return /* @__PURE__ */ s(
|
|
15607
|
-
|
|
15608
|
-
|
|
15609
|
-
|
|
15610
|
-
|
|
15611
|
-
|
|
15612
|
-
|
|
15613
|
-
|
|
15617
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
15618
|
+
tt,
|
|
15619
|
+
{
|
|
15620
|
+
required: n,
|
|
15621
|
+
type: "array",
|
|
15622
|
+
validator: async (o, i) => {
|
|
15623
|
+
if (!i)
|
|
15624
|
+
throw new Error();
|
|
15625
|
+
if (!Array.isArray(i))
|
|
15626
|
+
throw new Error();
|
|
15627
|
+
if (Array.isArray(i) && !i[0])
|
|
15628
|
+
throw new Error();
|
|
15629
|
+
},
|
|
15630
|
+
...t,
|
|
15631
|
+
children: /* @__PURE__ */ s(Ad, { ooui: e })
|
|
15632
|
+
}
|
|
15633
|
+
) });
|
|
15614
15634
|
}, Ad = (t) => {
|
|
15615
15635
|
const { value: e, onChange: n, ooui: r } = t, {
|
|
15616
15636
|
required: o,
|
|
@@ -15710,10 +15730,10 @@ const Rr = zt(Zb), ew = (t) => {
|
|
|
15710
15730
|
async function ye(W) {
|
|
15711
15731
|
W.keyCode === 13 ? (W.preventDefault(), W.stopPropagation(), await z()) : W.code === "Backspace" && B !== void 0 && (W.preventDefault(), W.stopPropagation(), L([void 0, ""]));
|
|
15712
15732
|
}
|
|
15713
|
-
const de = o && !a ? sw : Mt, ie =
|
|
15714
|
-
|
|
15715
|
-
), se =
|
|
15716
|
-
|
|
15733
|
+
const de = o && !a ? sw : Mt, ie = Tt(
|
|
15734
|
+
Ct.FEATURE_MANY2ONE_DISABLE_FOLDER
|
|
15735
|
+
), se = Tt(
|
|
15736
|
+
Ct.FEATURE_MANY2ONE_DISABLE_ARROW_MENU
|
|
15717
15737
|
), oe = J(() => {
|
|
15718
15738
|
let W = !0;
|
|
15719
15739
|
return ie === !0 && (W = !1), r.showFolder !== void 0 && (W = r.showFolder), W;
|
|
@@ -16945,7 +16965,7 @@ const fw = (t) => {
|
|
|
16945
16965
|
};
|
|
16946
16966
|
}, Pd = ({
|
|
16947
16967
|
one2manyItems: t
|
|
16948
|
-
}) =>
|
|
16968
|
+
}) => wt(() => t.filter((e) => e.operation !== "pendingRemove"), [t]), xi = zt(
|
|
16949
16969
|
({
|
|
16950
16970
|
formView: t,
|
|
16951
16971
|
items: e,
|
|
@@ -17244,9 +17264,9 @@ const Vd = ({
|
|
|
17244
17264
|
treeType: v,
|
|
17245
17265
|
onChangeTreeType: b
|
|
17246
17266
|
}) => {
|
|
17247
|
-
const C = Q(null), x = l || C, w =
|
|
17248
|
-
|
|
17249
|
-
), _ = Q(), T = Q(t), [A, O] = E(0), [D, P] = E(), [M, F] = E(0), R = Q([]), [I, k] = E([]), [$, j] = E(!1), X =
|
|
17267
|
+
const C = Q(null), x = l || C, w = Tt(
|
|
17268
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
17269
|
+
), _ = Q(), T = Q(t), [A, O] = E(0), [D, P] = E(), [M, F] = E(0), R = Q([]), [I, k] = E([]), [$, j] = E(!1), X = wt(() => t.length, [t]), {
|
|
17250
17270
|
columns: V,
|
|
17251
17271
|
strings: B,
|
|
17252
17272
|
colorsForResults: N,
|
|
@@ -17641,8 +17661,8 @@ const Vd = ({
|
|
|
17641
17661
|
xe !== "legacy" && a !== "legacy" && (d == null || d(xe), g(xe));
|
|
17642
17662
|
},
|
|
17643
17663
|
[a, g, d]
|
|
17644
|
-
), Ve =
|
|
17645
|
-
|
|
17664
|
+
), Ve = Tt(
|
|
17665
|
+
Ct.FEATURE_ONE2MANY_ENABLE_NEW_TABLE
|
|
17646
17666
|
), { openAction: Be } = Qn(), Ge = J(() => l.filter((xe) => Wt(xe.id)).map((xe) => xe.id), [l]), Ie = J(() => Ge.length > 0, [Ge]), Le = S(() => {
|
|
17647
17667
|
var xe, je;
|
|
17648
17668
|
Ie && Be({
|
|
@@ -17869,8 +17889,8 @@ const Vd = ({
|
|
|
17869
17889
|
}) => {
|
|
17870
17890
|
const v = Q(), b = c || v, C = Q({}), x = Q(), w = Q(), _ = Q(t), { t: T } = De(), A = rn(
|
|
17871
17891
|
kt.FEATURE_MANY2ONE_SORT
|
|
17872
|
-
), O =
|
|
17873
|
-
|
|
17892
|
+
), O = Tt(
|
|
17893
|
+
Ct.FEATURE_MANY2ONE_SELECTION_TO_LAZY
|
|
17874
17894
|
);
|
|
17875
17895
|
Je(() => {
|
|
17876
17896
|
var j;
|
|
@@ -17892,7 +17912,7 @@ const Vd = ({
|
|
|
17892
17912
|
(N = b == null ? void 0 : b.current) == null || N.updateRows(B);
|
|
17893
17913
|
})(), (j = b == null ? void 0 : b.current) == null || j.unselectAll();
|
|
17894
17914
|
}, [t, o, i]);
|
|
17895
|
-
const D =
|
|
17915
|
+
const D = wt(() => t.length, [t]), P = wt(() => Ks(
|
|
17896
17916
|
o,
|
|
17897
17917
|
{
|
|
17898
17918
|
...zo
|
|
@@ -18322,8 +18342,8 @@ const Vd = ({
|
|
|
18322
18342
|
}
|
|
18323
18343
|
) });
|
|
18324
18344
|
}, Iw = (t) => {
|
|
18325
|
-
const { ooui: e, value: n, userTreeTypePreferenceRef: r, onUserSelectTreeType: o } = t, { treeType: i, setTreeType: a } = Rc(), d =
|
|
18326
|
-
|
|
18345
|
+
const { ooui: e, value: n, userTreeTypePreferenceRef: r, onUserSelectTreeType: o } = t, { treeType: i, setTreeType: a } = Rc(), d = Tt(
|
|
18346
|
+
Ct.FEATURE_ONE2MANY_ENABLE_NEW_TABLE
|
|
18327
18347
|
);
|
|
18328
18348
|
if (Je(() => {
|
|
18329
18349
|
if (d) {
|
|
@@ -18880,8 +18900,8 @@ const { useToken: Nw } = ot, { TextArea: ks } = Mt, kw = (t) => {
|
|
|
18880
18900
|
);
|
|
18881
18901
|
}, qw = (t) => {
|
|
18882
18902
|
const { ooui: e, showTime: n = !1 } = t, { required: r, readOnly: o = !1, timezone: i } = e;
|
|
18883
|
-
return
|
|
18884
|
-
|
|
18903
|
+
return Tt(
|
|
18904
|
+
Ct.FEATURE_DATE_USE_MASKED_INPUT
|
|
18885
18905
|
) ? /* @__PURE__ */ s(tt, { required: r, ...t, children: /* @__PURE__ */ s(
|
|
18886
18906
|
Sl,
|
|
18887
18907
|
{
|
|
@@ -18911,8 +18931,8 @@ const { useToken: Nw } = ot, { TextArea: ks } = Mt, kw = (t) => {
|
|
|
18911
18931
|
const { ooui: e } = t;
|
|
18912
18932
|
return /* @__PURE__ */ s(tt, { ...t, children: /* @__PURE__ */ s(Qw, { ooui: e }) });
|
|
18913
18933
|
}, Qw = (t) => {
|
|
18914
|
-
const { readOnly: e, required: n } = t.ooui, r =
|
|
18915
|
-
|
|
18934
|
+
const { readOnly: e, required: n } = t.ooui, r = Tt(
|
|
18935
|
+
Ct.FEATURE_DATE_USE_MASKED_INPUT
|
|
18916
18936
|
), o = (a) => {
|
|
18917
18937
|
t.onChange && t.onChange(a ?? void 0);
|
|
18918
18938
|
};
|
|
@@ -18938,7 +18958,7 @@ const { useToken: Nw } = ot, { TextArea: ks } = Mt, kw = (t) => {
|
|
|
18938
18958
|
);
|
|
18939
18959
|
}, Xw = (t) => {
|
|
18940
18960
|
const { ooui: e } = t, { required: n } = e;
|
|
18941
|
-
return /* @__PURE__ */ s(tt, { required: n, ...t, children: /* @__PURE__ */ s(Zw, { ooui: e }) });
|
|
18961
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(tt, { required: n, ...t, children: /* @__PURE__ */ s(Zw, { ooui: e }) }) });
|
|
18942
18962
|
}, Zw = (t) => {
|
|
18943
18963
|
const { value: e, onChange: n, ooui: r } = t, { required: o, selectionValues: i, readOnly: a, domain: d } = r, c = e == null ? void 0 : e.split(","), [l, f] = E([]), [u, m] = E();
|
|
18944
18964
|
return he(() => {
|
|
@@ -19937,7 +19957,7 @@ const h0 = {
|
|
|
19937
19957
|
he(() => {
|
|
19938
19958
|
n && V(!0);
|
|
19939
19959
|
}, [n]);
|
|
19940
|
-
const L =
|
|
19960
|
+
const L = wt(
|
|
19941
19961
|
() => bn(P || [], i),
|
|
19942
19962
|
[i, P]
|
|
19943
19963
|
), U = lt(async () => {
|
|
@@ -20134,7 +20154,7 @@ const h0 = {
|
|
|
20134
20154
|
},
|
|
20135
20155
|
children: /* @__PURE__ */ s(ct, { size: "small" })
|
|
20136
20156
|
}
|
|
20137
|
-
) : /* @__PURE__ */ s(
|
|
20157
|
+
) : /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ H("div", { style: c, children: [
|
|
20138
20158
|
/* @__PURE__ */ H("div", { style: w0, children: [
|
|
20139
20159
|
/* @__PURE__ */ s("div", { style: C0, children: /* @__PURE__ */ s(Ba, { style: l, children: u }) }),
|
|
20140
20160
|
/* @__PURE__ */ s(
|
|
@@ -20161,7 +20181,7 @@ const h0 = {
|
|
|
20161
20181
|
{
|
|
20162
20182
|
max: { count: 5, style: { backgroundColor: a.colorPrimary } },
|
|
20163
20183
|
size: 24,
|
|
20164
|
-
children: t.map((m) => /* @__PURE__ */ s(
|
|
20184
|
+
children: t.map((m) => /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(Pt, { title: m.name, children: /* @__PURE__ */ s("span", { children: /* @__PURE__ */ s(Eo, { userName: m.name, size: 24 }) }) }) }, m.id))
|
|
20165
20185
|
}
|
|
20166
20186
|
)
|
|
20167
20187
|
] })
|
|
@@ -20221,7 +20241,7 @@ const h0 = {
|
|
|
20221
20241
|
), f = S(() => {
|
|
20222
20242
|
e(t.tempId);
|
|
20223
20243
|
}, [e, t.tempId]);
|
|
20224
|
-
return /* @__PURE__ */ s(
|
|
20244
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s("div", { style: I0, children: /* @__PURE__ */ H("div", { style: E0, children: [
|
|
20225
20245
|
/* @__PURE__ */ H("div", { style: d, children: [
|
|
20226
20246
|
o && /* @__PURE__ */ H(Fe, { children: [
|
|
20227
20247
|
/* @__PURE__ */ s(Zt, { spin: !0, style: Ha }),
|
|
@@ -20328,7 +20348,7 @@ const h0 = {
|
|
|
20328
20348
|
},
|
|
20329
20349
|
...i
|
|
20330
20350
|
};
|
|
20331
|
-
return /* @__PURE__ */ s(
|
|
20351
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s("div", { ref: e, style: a ?? m, children: /* @__PURE__ */ s(
|
|
20332
20352
|
ff,
|
|
20333
20353
|
{
|
|
20334
20354
|
remarkPlugins: [mf],
|
|
@@ -20348,7 +20368,7 @@ const M0 = {
|
|
|
20348
20368
|
comment: t,
|
|
20349
20369
|
model: e,
|
|
20350
20370
|
resourceId: n
|
|
20351
|
-
}) => /* @__PURE__ */ s(
|
|
20371
|
+
}) => /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(Dt, { children: /* @__PURE__ */ s(
|
|
20352
20372
|
Dt.Item,
|
|
20353
20373
|
{
|
|
20354
20374
|
name: `comment_${t.id}`,
|
|
@@ -20523,7 +20543,7 @@ const M0 = {
|
|
|
20523
20543
|
),
|
|
20524
20544
|
/* @__PURE__ */ s(fo, { style: ja, children: h })
|
|
20525
20545
|
] }) }), j = /* @__PURE__ */ s(Pt, { title: y, children: /* @__PURE__ */ s(fo, { style: O, children: v }) });
|
|
20526
|
-
return /* @__PURE__ */ s(
|
|
20546
|
+
return /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ H(Fe, { children: [
|
|
20527
20547
|
r && o && /* @__PURE__ */ H("div", { style: P0, children: [
|
|
20528
20548
|
/* @__PURE__ */ s("div", { style: x }),
|
|
20529
20549
|
/* @__PURE__ */ s(fo, { style: w, children: o }),
|
|
@@ -20838,7 +20858,7 @@ const H0 = nt(Gd), { Title: j0, Text: U0 } = Jt, { useToken: W0 } = ot, z0 = (t)
|
|
|
20838
20858
|
transition: { type: "spring", stiffness: 300, damping: 30 },
|
|
20839
20859
|
style: Ee,
|
|
20840
20860
|
children: [
|
|
20841
|
-
/* @__PURE__ */ s(
|
|
20861
|
+
/* @__PURE__ */ s(yt, { children: /* @__PURE__ */ H("div", { style: pe, children: [
|
|
20842
20862
|
/* @__PURE__ */ H("div", { style: J0, children: [
|
|
20843
20863
|
/* @__PURE__ */ s(j0, { level: 5, style: K0, children: _("comments") }),
|
|
20844
20864
|
/* @__PURE__ */ s(Pt, { title: _("refresh"), children: /* @__PURE__ */ s(
|
|
@@ -20863,7 +20883,7 @@ const H0 = nt(Gd), { Title: j0, Text: U0 } = Jt, { useToken: W0 } = ot, z0 = (t)
|
|
|
20863
20883
|
}
|
|
20864
20884
|
)
|
|
20865
20885
|
] }) }),
|
|
20866
|
-
b && /* @__PURE__ */ s(
|
|
20886
|
+
b && /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
20867
20887
|
_0,
|
|
20868
20888
|
{
|
|
20869
20889
|
participants: p,
|
|
@@ -20874,7 +20894,7 @@ const H0 = nt(Gd), { Title: j0, Text: U0 } = Jt, { useToken: W0 } = ot, z0 = (t)
|
|
|
20874
20894
|
onToggleMute: ze
|
|
20875
20895
|
}
|
|
20876
20896
|
) }),
|
|
20877
|
-
/* @__PURE__ */ s(
|
|
20897
|
+
/* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s("div", { ref: de, style: ce, children: r && n.length === 0 ? /* @__PURE__ */ s("div", { style: Wa, children: /* @__PURE__ */ s(ct, {}) }) : n.length === 0 ? /* @__PURE__ */ s("div", { style: Wa, children: /* @__PURE__ */ s(
|
|
20878
20898
|
mr,
|
|
20879
20899
|
{
|
|
20880
20900
|
description: _("noComments"),
|
|
@@ -20930,7 +20950,7 @@ const H0 = nt(Gd), { Title: j0, Text: U0 } = Jt, { useToken: W0 } = ot, z0 = (t)
|
|
|
20930
20950
|
)),
|
|
20931
20951
|
/* @__PURE__ */ s("div", { ref: ne })
|
|
20932
20952
|
] }) }) }),
|
|
20933
|
-
m && /* @__PURE__ */ s(
|
|
20953
|
+
m && /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s("div", { style: Me, children: /* @__PURE__ */ H(
|
|
20934
20954
|
"div",
|
|
20935
20955
|
{
|
|
20936
20956
|
style: { display: "flex", gap: 8, alignItems: "flex-end" },
|
|
@@ -21532,7 +21552,7 @@ const aC = ({
|
|
|
21532
21552
|
}), F = {
|
|
21533
21553
|
opacity: M || u ? 0 : 1,
|
|
21534
21554
|
cursor: "grab"
|
|
21535
|
-
}, { visibleButtons: R, widgetMap: I } =
|
|
21555
|
+
}, { visibleButtons: R, widgetMap: I } = wt(() => {
|
|
21536
21556
|
const U = new pu(n).parse(e).rows.flat(), z = U.filter(
|
|
21537
21557
|
(ne) => ne instanceof cl && !ne.invisible
|
|
21538
21558
|
), G = /* @__PURE__ */ new Map();
|
|
@@ -21542,7 +21562,7 @@ const aC = ({
|
|
|
21542
21562
|
visibleButtons: z,
|
|
21543
21563
|
widgetMap: G
|
|
21544
21564
|
};
|
|
21545
|
-
}, [n, e]), k =
|
|
21565
|
+
}, [n, e]), k = wt(() => n.card_fields.filter((N) => {
|
|
21546
21566
|
const L = I.get(N.id);
|
|
21547
21567
|
return !L || !L.invisible;
|
|
21548
21568
|
}), [n.card_fields, I]), $ = S(
|
|
@@ -21634,7 +21654,7 @@ const aC = ({
|
|
|
21634
21654
|
f,
|
|
21635
21655
|
x
|
|
21636
21656
|
]
|
|
21637
|
-
), X =
|
|
21657
|
+
), X = wt(() => R.reduce(
|
|
21638
21658
|
(N, L) => (N[L.id] = (U) => j(U, L), N),
|
|
21639
21659
|
{}
|
|
21640
21660
|
), [R, j]), V = S(
|
|
@@ -21678,7 +21698,7 @@ const aC = ({
|
|
|
21678
21698
|
children: [
|
|
21679
21699
|
i && /* @__PURE__ */ s(fC, { $color: i }),
|
|
21680
21700
|
a && /* @__PURE__ */ s(mC, { $color: a }),
|
|
21681
|
-
/* @__PURE__ */ H(
|
|
21701
|
+
/* @__PURE__ */ H(yt, { children: [
|
|
21682
21702
|
/* @__PURE__ */ s("div", { style: { marginBottom: "8px" }, children: k.map(
|
|
21683
21703
|
(N, L) => $(N, L === 0)
|
|
21684
21704
|
) }),
|
|
@@ -21723,7 +21743,7 @@ const aC = ({
|
|
|
21723
21743
|
he(() => () => {
|
|
21724
21744
|
j(), V(), N();
|
|
21725
21745
|
}, []);
|
|
21726
|
-
const L =
|
|
21746
|
+
const L = wt(() => {
|
|
21727
21747
|
if (!(l != null && l.aggregations))
|
|
21728
21748
|
return;
|
|
21729
21749
|
const te = l.aggregations;
|
|
@@ -21733,7 +21753,7 @@ const aC = ({
|
|
|
21733
21753
|
return Object.keys(te).forEach((de) => {
|
|
21734
21754
|
ye[de] = ["sum"];
|
|
21735
21755
|
}), ye;
|
|
21736
|
-
}, [l == null ? void 0 : l.aggregations]), U =
|
|
21756
|
+
}, [l == null ? void 0 : l.aggregations]), U = wt(() => {
|
|
21737
21757
|
if (!(l != null && l.column_field))
|
|
21738
21758
|
return n;
|
|
21739
21759
|
let te = o;
|
|
@@ -22304,7 +22324,7 @@ const aC = ({
|
|
|
22304
22324
|
width: "100%",
|
|
22305
22325
|
transform: `translateY(${Se.start}px)`
|
|
22306
22326
|
},
|
|
22307
|
-
children: /* @__PURE__ */ s(
|
|
22327
|
+
children: /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
22308
22328
|
Jd,
|
|
22309
22329
|
{
|
|
22310
22330
|
color: G == null ? void 0 : G[ge.id],
|
|
@@ -22610,10 +22630,10 @@ const aC = ({
|
|
|
22610
22630
|
k(Ce);
|
|
22611
22631
|
const Oe = ee.rect;
|
|
22612
22632
|
if (Oe) {
|
|
22613
|
-
const qe = Oe.top + Oe.height / 2,
|
|
22614
|
-
j(
|
|
22633
|
+
const qe = Oe.top + Oe.height / 2, vt = (q.activatorEvent && "clientY" in q.activatorEvent ? q.activatorEvent.clientY : 0) + q.delta.y < qe ? "above" : "below";
|
|
22634
|
+
j(vt), X.current[_e] = {
|
|
22615
22635
|
recordId: Ce,
|
|
22616
|
-
position:
|
|
22636
|
+
position: vt
|
|
22617
22637
|
};
|
|
22618
22638
|
}
|
|
22619
22639
|
} else
|
|
@@ -22626,9 +22646,9 @@ const aC = ({
|
|
|
22626
22646
|
if (qe) {
|
|
22627
22647
|
if (M(qe.id), Ce !== le.id) {
|
|
22628
22648
|
k(Ce);
|
|
22629
|
-
const
|
|
22630
|
-
if (
|
|
22631
|
-
const
|
|
22649
|
+
const _t = ee.rect;
|
|
22650
|
+
if (_t) {
|
|
22651
|
+
const At = _t.top + _t.height / 2, Vt = (q.activatorEvent && "clientY" in q.activatorEvent ? q.activatorEvent.clientY : 0) + q.delta.y < At ? "above" : "below";
|
|
22632
22652
|
j(Vt), X.current[qe.id] = {
|
|
22633
22653
|
recordId: Ce,
|
|
22634
22654
|
position: Vt
|
|
@@ -22748,12 +22768,12 @@ const aC = ({
|
|
|
22748
22768
|
Ae();
|
|
22749
22769
|
return;
|
|
22750
22770
|
}
|
|
22751
|
-
const
|
|
22752
|
-
if (!
|
|
22771
|
+
const _t = Oe[f.column_field], At = (Fn = f.fields) == null ? void 0 : Fn[f.column_field], vt = At ? Un(_t, At, T) : null;
|
|
22772
|
+
if (!vt) {
|
|
22753
22773
|
Ae();
|
|
22754
22774
|
return;
|
|
22755
22775
|
}
|
|
22756
|
-
const
|
|
22776
|
+
const xt = vt.id === qe.id;
|
|
22757
22777
|
let Vt = Ce, tn = _e;
|
|
22758
22778
|
if (!Vt && qe) {
|
|
22759
22779
|
const Qe = X.current[qe.id];
|
|
@@ -22761,7 +22781,7 @@ const aC = ({
|
|
|
22761
22781
|
}
|
|
22762
22782
|
Ae();
|
|
22763
22783
|
try {
|
|
22764
|
-
if (
|
|
22784
|
+
if (xt) {
|
|
22765
22785
|
if (Vt && tn) {
|
|
22766
22786
|
const { prevId: dn, nextId: Cn } = pe(
|
|
22767
22787
|
qe.id,
|
|
@@ -22786,19 +22806,19 @@ const aC = ({
|
|
|
22786
22806
|
return;
|
|
22787
22807
|
}
|
|
22788
22808
|
const Qe = Un(
|
|
22789
|
-
Tt,
|
|
22790
22809
|
_t,
|
|
22810
|
+
At,
|
|
22791
22811
|
T
|
|
22792
22812
|
), at = Un(
|
|
22793
22813
|
qe.originalValue,
|
|
22794
|
-
|
|
22814
|
+
At,
|
|
22795
22815
|
T
|
|
22796
|
-
),
|
|
22816
|
+
), bt = ((Rt = f.on_change_column) == null ? void 0 : Rt.method) || "on_change_column";
|
|
22797
22817
|
if (!(Qe != null && Qe.id) || !(at != null && at.id) || parseInt(Qe == null ? void 0 : Qe.id) === parseInt(at == null ? void 0 : at.id))
|
|
22798
22818
|
return;
|
|
22799
22819
|
const mn = await se({
|
|
22800
22820
|
model: r,
|
|
22801
|
-
action:
|
|
22821
|
+
action: bt,
|
|
22802
22822
|
payload: [
|
|
22803
22823
|
[$e],
|
|
22804
22824
|
f.column_field,
|
|
@@ -22836,9 +22856,9 @@ const aC = ({
|
|
|
22836
22856
|
]
|
|
22837
22857
|
});
|
|
22838
22858
|
}
|
|
22839
|
-
me(
|
|
22859
|
+
me(vt.id, qe.id);
|
|
22840
22860
|
} catch (Qe) {
|
|
22841
|
-
x && x(qe.id,
|
|
22861
|
+
x && x(qe.id, vt.id), A(Qe);
|
|
22842
22862
|
}
|
|
22843
22863
|
},
|
|
22844
22864
|
[
|
|
@@ -22870,26 +22890,26 @@ const aC = ({
|
|
|
22870
22890
|
ee ? L.current[q] = ee : delete L.current[q], y(q, ee);
|
|
22871
22891
|
},
|
|
22872
22892
|
[y]
|
|
22873
|
-
), Re =
|
|
22893
|
+
), Re = wt(() => {
|
|
22874
22894
|
const q = {};
|
|
22875
22895
|
return n.forEach((ee) => {
|
|
22876
22896
|
q[ee.id] = (le) => {
|
|
22877
22897
|
ze(ee.id, le);
|
|
22878
22898
|
};
|
|
22879
22899
|
}), q;
|
|
22880
|
-
}, [n, ze]), He =
|
|
22900
|
+
}, [n, ze]), He = wt(() => {
|
|
22881
22901
|
if (!b)
|
|
22882
22902
|
return {};
|
|
22883
22903
|
const q = {};
|
|
22884
22904
|
return n.forEach((ee) => {
|
|
22885
22905
|
q[ee.id] = () => b(ee);
|
|
22886
22906
|
}), q;
|
|
22887
|
-
}, [n, b]), xe =
|
|
22907
|
+
}, [n, b]), xe = wt(() => {
|
|
22888
22908
|
const q = {};
|
|
22889
22909
|
return de.forEach((ee) => {
|
|
22890
22910
|
q[ee.id] = () => Ve(ee.id, "left");
|
|
22891
22911
|
}), q;
|
|
22892
|
-
}, [de, Ve]), je =
|
|
22912
|
+
}, [de, Ve]), je = wt(() => {
|
|
22893
22913
|
const q = {};
|
|
22894
22914
|
return de.forEach((ee) => {
|
|
22895
22915
|
q[ee.id] = () => Ve(ee.id, "right");
|
|
@@ -22897,7 +22917,7 @@ const aC = ({
|
|
|
22897
22917
|
}, [de, Ve]), Se = J(
|
|
22898
22918
|
() => de.map((q) => ({ id: q.id, label: q.label })),
|
|
22899
22919
|
[de]
|
|
22900
|
-
), ge =
|
|
22920
|
+
), ge = wt(() => {
|
|
22901
22921
|
const q = {};
|
|
22902
22922
|
return de.forEach((ee) => {
|
|
22903
22923
|
q[ee.id] = (le, Ce) => Be(ee.id, le, Ce);
|
|
@@ -22941,7 +22961,7 @@ const aC = ({
|
|
|
22941
22961
|
overflowX: "auto",
|
|
22942
22962
|
height: "100%"
|
|
22943
22963
|
},
|
|
22944
|
-
children: de.map((q, ee) => /* @__PURE__ */ s(
|
|
22964
|
+
children: de.map((q, ee) => /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
22945
22965
|
RC,
|
|
22946
22966
|
{
|
|
22947
22967
|
ref: Re[q.id],
|
|
@@ -23247,7 +23267,7 @@ const aC = ({
|
|
|
23247
23267
|
he(() => {
|
|
23248
23268
|
m == null || m(P);
|
|
23249
23269
|
}, [P, m]);
|
|
23250
|
-
const V =
|
|
23270
|
+
const V = wt(() => _ ? /* @__PURE__ */ s(
|
|
23251
23271
|
Ut,
|
|
23252
23272
|
{
|
|
23253
23273
|
message: C("error_parsing_kanban_view"),
|
|
@@ -23263,7 +23283,7 @@ const aC = ({
|
|
|
23263
23283
|
type: "error",
|
|
23264
23284
|
showIcon: !0
|
|
23265
23285
|
}
|
|
23266
|
-
) : !x || P && D.length === 0 ? /* @__PURE__ */ s(ct, { size: "large" }) : /* @__PURE__ */ s(
|
|
23286
|
+
) : !x || P && D.length === 0 ? /* @__PURE__ */ s(ct, { size: "large" }) : /* @__PURE__ */ s(yt, { children: /* @__PURE__ */ s(
|
|
23267
23287
|
MC,
|
|
23268
23288
|
{
|
|
23269
23289
|
ref: R,
|
|
@@ -25370,7 +25390,7 @@ export {
|
|
|
25370
25390
|
$b as ad,
|
|
25371
25391
|
Pb as ae,
|
|
25372
25392
|
ES as af,
|
|
25373
|
-
|
|
25393
|
+
Ct as ag,
|
|
25374
25394
|
pb as ah,
|
|
25375
25395
|
nC as ai,
|
|
25376
25396
|
hb as aj,
|
|
@@ -25414,4 +25434,4 @@ export {
|
|
|
25414
25434
|
Wm as y,
|
|
25415
25435
|
KC as z
|
|
25416
25436
|
};
|
|
25417
|
-
//# sourceMappingURL=TabContent-
|
|
25437
|
+
//# sourceMappingURL=TabContent-6443e6f3.mjs.map
|