@gisce/react-ooui 2.71.0-alpha.1 → 2.71.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/react-ooui.es.js
CHANGED
|
@@ -2,7 +2,7 @@ var Rl = Object.defineProperty;
|
|
|
2
2
|
var Ol = (e, t, n) => t in e ? Rl(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var as = (e, t, n) => (Ol(e, typeof t != "symbol" ? t + "" : t, n), n);
|
|
4
4
|
import { jsx as s, jsxs as N, Fragment as ne } from "react/jsx-runtime";
|
|
5
|
-
import Ft, { useContext as
|
|
5
|
+
import Ft, { useContext as se, useState as I, useEffect as oe, useRef as q, memo as Ze, useCallback as D, useMemo as Q, forwardRef as _t, useImperativeHandle as Dt, Fragment as Rn, createContext as El, createElement as Dl } from "react";
|
|
6
6
|
import { Tooltip as kt, theme as Qe, Typography as Zt, Form as Ot, Row as Ge, Col as _e, Modal as xt, Button as Ye, Dropdown as Pl, Menu as ls, Spin as Xe, Divider as Tr, Space as ot, Input as ft, Select as fn, Checkbox as Un, Alert as yt, Timeline as pi, message as Bn, Popover as kl, App as Vl, Progress as Nl, Avatar as hi, Tag as Io, DatePicker as Fo, ColorPicker as gi, TimePicker as Ll, InputNumber as Ir, Layout as yi, Badge as zn, Pagination as $l, Empty as vi, Statistic as Ml, Card as Ao, Tabs as bi, Radio as cs, Switch as jl, Steps as ds, Carousel as Bl } from "antd";
|
|
7
7
|
import { Label as On, Field as ao, Tree as wi, Reference as Hl, Selection as _o, Many2one as Si, Boolean as Ul, parseContext as Jt, graphProcessor as Ci, graphFieldUtils as Wl, parseContextFields as Yl, parseDomainFields as Gl, Integer as lo, SearchFieldTypes as zt, SearchFilter as xi, parseGraph as Ti, Container as ql, Form as Ii, transformDomainForChildWidget as Ro, Button as Kl } from "@gisce/ooui";
|
|
8
8
|
import * as us from "@ant-design/icons";
|
|
@@ -97,7 +97,7 @@ const Je = Ft.createContext(null), Zc = (e) => {
|
|
|
97
97
|
}
|
|
98
98
|
);
|
|
99
99
|
}, ed = () => {
|
|
100
|
-
const e =
|
|
100
|
+
const e = se(Je);
|
|
101
101
|
return e || {
|
|
102
102
|
activeId: void 0,
|
|
103
103
|
activeModel: "",
|
|
@@ -176,7 +176,7 @@ const { Text: od, Title: sd } = Zt, { useToken: id } = Qe, ad = {
|
|
|
176
176
|
center: "justify-center",
|
|
177
177
|
right: "justify-end"
|
|
178
178
|
}, kr = (e) => {
|
|
179
|
-
const { ooui: t, align: n, responsiveBehaviour: r } = e, { label: o, tooltip: a, fieldForLabel: i, labelSize: l, labelType: c } = t, u =
|
|
179
|
+
const { ooui: t, align: n, responsiveBehaviour: r } = e, { label: o, tooltip: a, fieldForLabel: i, labelSize: l, labelType: c } = t, u = se(Je);
|
|
180
180
|
let d = i !== null && o.length > 1 ? o + " :" : o, p = "";
|
|
181
181
|
if (!t.fieldForLabel && t._id && (d = u.getFieldValue(t._id), t.fieldType === "date" || t.fieldType === "time" || t.fieldType === "datetime")) {
|
|
182
182
|
const v = {
|
|
@@ -421,7 +421,7 @@ const No = (e) => {
|
|
|
421
421
|
icon: l,
|
|
422
422
|
context: c,
|
|
423
423
|
readOnly: u
|
|
424
|
-
} = t, m =
|
|
424
|
+
} = t, m = se(Je), { executeButtonAction: d } = m || {}, [p, h] = I(!1), { t: f } = me();
|
|
425
425
|
async function g() {
|
|
426
426
|
h(!0), await d({ type: a, action: n, context: c }), h(!1);
|
|
427
427
|
}
|
|
@@ -470,7 +470,7 @@ const No = (e) => {
|
|
|
470
470
|
primary: m,
|
|
471
471
|
context: d,
|
|
472
472
|
readOnly: p
|
|
473
|
-
} = n || {}, h =
|
|
473
|
+
} = n || {}, h = se(Je), { executeButtonAction: f } = h || {}, [g, y] = I(!1), { t: v } = me();
|
|
474
474
|
function b() {
|
|
475
475
|
if (g)
|
|
476
476
|
return /* @__PURE__ */ s(Vt, {});
|
|
@@ -585,7 +585,7 @@ function Vr() {
|
|
|
585
585
|
const [e, t] = I(
|
|
586
586
|
vs()
|
|
587
587
|
);
|
|
588
|
-
return
|
|
588
|
+
return oe(() => {
|
|
589
589
|
function n() {
|
|
590
590
|
t(vs());
|
|
591
591
|
}
|
|
@@ -637,7 +637,7 @@ const Hi = (e) => {
|
|
|
637
637
|
});
|
|
638
638
|
}, Ui = (e) => {
|
|
639
639
|
const { visible: t, onCloseModal: n, model: r, id: o, field: a, onSubmitSucceed: i } = e, { modalWidth: l } = Vr(), { t: c } = me(), [u, m] = I([]), [d, p] = I(!1), [h, f] = I(!1), [g, y] = I({}), v = q();
|
|
640
|
-
|
|
640
|
+
oe(() => {
|
|
641
641
|
t ? b() : y({});
|
|
642
642
|
}, [t]);
|
|
643
643
|
async function b() {
|
|
@@ -808,7 +808,7 @@ const Wi = (e) => {
|
|
|
808
808
|
isSearchField: n,
|
|
809
809
|
onChange: r
|
|
810
810
|
}) => {
|
|
811
|
-
const o =
|
|
811
|
+
const o = se(Je), { elementHasLostFocus: a } = o || {}, { readOnly: i, isPassword: l, translatable: c, required: u } = t, m = Q(() => e && (t.selectionValues.size ? t.selectionValues.get(e) : Array.isArray(e) ? e[1] : e), [t.selectionValues, e]), d = Q(
|
|
812
812
|
() => u && !i,
|
|
813
813
|
[u, i]
|
|
814
814
|
), p = Q(
|
|
@@ -857,7 +857,7 @@ const Gi = Ze(
|
|
|
857
857
|
field: n,
|
|
858
858
|
onChange: r
|
|
859
859
|
}) => {
|
|
860
|
-
const o =
|
|
860
|
+
const o = se(Je), {
|
|
861
861
|
activeId: a,
|
|
862
862
|
activeModel: i,
|
|
863
863
|
fetchValues: l,
|
|
@@ -1520,7 +1520,7 @@ const pn = ({
|
|
|
1520
1520
|
]
|
|
1521
1521
|
}
|
|
1522
1522
|
), tu = (e) => {
|
|
1523
|
-
const { ooui: t } = e, { relation: n, context: r, views: o } = t, [a, i] = I(!0), [l, c] = I(), [u, m] = I(/* @__PURE__ */ new Map()), d =
|
|
1523
|
+
const { ooui: t } = e, { relation: n, context: r, views: o } = t, [a, i] = I(!0), [l, c] = I(), [u, m] = I(/* @__PURE__ */ new Map()), d = se(Je), { getContext: p } = d || {};
|
|
1524
1524
|
Mt(() => {
|
|
1525
1525
|
f();
|
|
1526
1526
|
}, [t]);
|
|
@@ -1549,7 +1549,7 @@ const pn = ({
|
|
|
1549
1549
|
titleField: b,
|
|
1550
1550
|
iconField: F,
|
|
1551
1551
|
colorField: C
|
|
1552
|
-
} = r, T = a.filter((_) => _.values), O =
|
|
1552
|
+
} = r, T = a.filter((_) => _.values), O = se(Je), { getContext: S } = O || {};
|
|
1553
1553
|
Mt(() => {
|
|
1554
1554
|
A();
|
|
1555
1555
|
}, [a]);
|
|
@@ -1980,7 +1980,7 @@ const pn = ({
|
|
|
1980
1980
|
devMode: !1,
|
|
1981
1981
|
treeMaxLimit: ta
|
|
1982
1982
|
}, na = Ft.createContext(au), Zn = () => {
|
|
1983
|
-
const e =
|
|
1983
|
+
const e = se(na);
|
|
1984
1984
|
if (!e)
|
|
1985
1985
|
throw new Error(
|
|
1986
1986
|
"useConfigContext must be used within a ConfigContextProvider"
|
|
@@ -2081,7 +2081,7 @@ async function ra({
|
|
|
2081
2081
|
};
|
|
2082
2082
|
}
|
|
2083
2083
|
const cu = (e) => {
|
|
2084
|
-
const [t, n] = I(), [r, o] = I(!0), [a, i] = I(), [l, c] = I(), u =
|
|
2084
|
+
const [t, n] = I(), [r, o] = I(!0), [a, i] = I(), [l, c] = I(), u = se(Je), { getContext: m, getPlainValues: d, activeId: p } = u || {}, { globalValues: h, rootContext: f } = Zn(), g = Q(() => ({ ...m == null ? void 0 : m(), ...f }), [m, f]);
|
|
2085
2085
|
return { actionData: a, treeShortcut: l, loading: r, error: t, fetchData: async () => {
|
|
2086
2086
|
n(void 0), o(!0);
|
|
2087
2087
|
try {
|
|
@@ -2163,7 +2163,7 @@ const cu = (e) => {
|
|
|
2163
2163
|
);
|
|
2164
2164
|
}, ze = (e) => {
|
|
2165
2165
|
const t = q(/* @__PURE__ */ new Map());
|
|
2166
|
-
|
|
2166
|
+
oe(() => () => {
|
|
2167
2167
|
n();
|
|
2168
2168
|
}, []);
|
|
2169
2169
|
const n = D((o) => {
|
|
@@ -2373,7 +2373,7 @@ const { getValueForOperator: xs } = Ci, fu = (e) => {
|
|
|
2373
2373
|
), [j] = ze(
|
|
2374
2374
|
$.getHandler().parseCondition
|
|
2375
2375
|
);
|
|
2376
|
-
|
|
2376
|
+
oe(() => {
|
|
2377
2377
|
M();
|
|
2378
2378
|
}, [t, o]);
|
|
2379
2379
|
async function L({
|
|
@@ -3136,7 +3136,7 @@ function gt(e) {
|
|
|
3136
3136
|
}
|
|
3137
3137
|
const da = (e) => /* @__PURE__ */ s(gt, { ...e, type: "primary", danger: !0 });
|
|
3138
3138
|
function ua(e) {
|
|
3139
|
-
const { disabled: t = !1 } = e, { formHasChanges: n, onNewClicked: r } =
|
|
3139
|
+
const { disabled: t = !1 } = e, { formHasChanges: n, onNewClicked: r } = se(
|
|
3140
3140
|
wt
|
|
3141
3141
|
), { t: o } = me(), a = () => {
|
|
3142
3142
|
if (n) {
|
|
@@ -3219,7 +3219,7 @@ function Mu(e) {
|
|
|
3219
3219
|
const f = h.search;
|
|
3220
3220
|
u.current = f, t(f);
|
|
3221
3221
|
}
|
|
3222
|
-
|
|
3222
|
+
oe(() => {
|
|
3223
3223
|
!c.current && r !== u.current && (u.current = r, a.setFieldsValue({ search: r }), l(r ? r.length > 0 : !1));
|
|
3224
3224
|
}, [r, a]);
|
|
3225
3225
|
function d() {
|
|
@@ -3281,7 +3281,7 @@ const gb = Object.values(Nt), Rt = Ft.createContext(null), ju = (e) => {
|
|
|
3281
3281
|
onRemoveTab: c,
|
|
3282
3282
|
tabs: u
|
|
3283
3283
|
} = e, [m, d] = I(), [p, h] = I(), f = Q(() => u.find((v) => v.key === i), [u, i]), { title: g } = Zn(), y = Q(() => !((u == null ? void 0 : u.length) > 0), [u]);
|
|
3284
|
-
return
|
|
3284
|
+
return oe(() => {
|
|
3285
3285
|
y && (document.title = g, window.history.replaceState({}, "", "/"));
|
|
3286
3286
|
}, [y, g]), /* @__PURE__ */ s(
|
|
3287
3287
|
Rt.Provider,
|
|
@@ -3306,14 +3306,14 @@ const gb = Object.values(Nt), Rt = Ft.createContext(null), ju = (e) => {
|
|
|
3306
3306
|
);
|
|
3307
3307
|
};
|
|
3308
3308
|
function Ho() {
|
|
3309
|
-
return
|
|
3309
|
+
return se(Rt) || {};
|
|
3310
3310
|
}
|
|
3311
3311
|
const kn = Ft.createContext(null), _s = async (e) => {
|
|
3312
3312
|
var t;
|
|
3313
3313
|
for (let n = 0; n < e.length; n++)
|
|
3314
3314
|
await ((t = e == null ? void 0 : e[n]) == null ? void 0 : t.call(e));
|
|
3315
3315
|
}, Bu = (e, t) => {
|
|
3316
|
-
const { children: n, globalValues: r = {} } = e, o = q(), a = q(), [i, l] = I(!1), c =
|
|
3316
|
+
const { children: n, globalValues: r = {} } = e, o = q(), a = q(), [i, l] = I(!1), c = se(
|
|
3317
3317
|
Rt
|
|
3318
3318
|
), { openAction: u } = c || {}, m = q([]), { t: d } = me();
|
|
3319
3319
|
Dt(t, () => ({
|
|
@@ -3603,7 +3603,7 @@ const Uu = _t(Bu), ma = ({
|
|
|
3603
3603
|
selectedRowItems: e,
|
|
3604
3604
|
onRefreshParentValues: t
|
|
3605
3605
|
}) => {
|
|
3606
|
-
const n =
|
|
3606
|
+
const n = se(
|
|
3607
3607
|
kn
|
|
3608
3608
|
), { processAction: r } = n || {};
|
|
3609
3609
|
return D(
|
|
@@ -3798,7 +3798,7 @@ function zu({
|
|
|
3798
3798
|
totalItems: R,
|
|
3799
3799
|
isActive: x,
|
|
3800
3800
|
treeType: _
|
|
3801
|
-
} =
|
|
3801
|
+
} = se(wt), P = Yt(
|
|
3802
3802
|
Nt.FEATURE_ADVANCED_EXPORT
|
|
3803
3803
|
), { t: E } = me(), [j, L] = I(!1), V = q(!0), M = D(() => {
|
|
3804
3804
|
var U;
|
|
@@ -3899,7 +3899,7 @@ function zu({
|
|
|
3899
3899
|
},
|
|
3900
3900
|
[p, e, w, Y, l]
|
|
3901
3901
|
);
|
|
3902
|
-
|
|
3902
|
+
oe(() => {
|
|
3903
3903
|
if (_ === "infinite" && C === void 0) {
|
|
3904
3904
|
if (V.current) {
|
|
3905
3905
|
V.current = !1;
|
|
@@ -4113,7 +4113,7 @@ const { useToken: Qu } = Qe, { Title: Xu, Text: dr } = Zt, jr = ({
|
|
|
4113
4113
|
totalItems: c,
|
|
4114
4114
|
selectedRowItems: u,
|
|
4115
4115
|
treeType: m
|
|
4116
|
-
} =
|
|
4116
|
+
} = se(wt), { t: d } = me(), { token: p } = Qu(), h = Q(() => {
|
|
4117
4117
|
if (!n)
|
|
4118
4118
|
return null;
|
|
4119
4119
|
if ((o == null ? void 0 : o.type) === "form" && a) {
|
|
@@ -4402,9 +4402,9 @@ const tf = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(ba,
|
|
|
4402
4402
|
)
|
|
4403
4403
|
] });
|
|
4404
4404
|
}, Br = (e) => {
|
|
4405
|
-
const { id: t, model: n, context: r = {} } = e, [o, a] = I(), [i, l] = I(), c =
|
|
4405
|
+
const { id: t, model: n, context: r = {} } = e, [o, a] = I(), [i, l] = I(), c = se(
|
|
4406
4406
|
Rt
|
|
4407
|
-
), { openRelate: u, openAction: m } = c || {}, d =
|
|
4407
|
+
), { openRelate: u, openAction: m } = c || {}, d = se(
|
|
4408
4408
|
kn
|
|
4409
4409
|
), { processAction: p } = d || {}, [h, f] = ze(
|
|
4410
4410
|
$.getHandler().getView
|
|
@@ -4549,7 +4549,7 @@ function uf(e) {
|
|
|
4549
4549
|
const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa, { ...e }) }), wa = (e) => {
|
|
4550
4550
|
const { t } = me(), [n, r] = ze(
|
|
4551
4551
|
$.getHandler().readObjects
|
|
4552
|
-
), { getFieldValue: o } =
|
|
4552
|
+
), { getFieldValue: o } = se(Je) || {}, { ooui: a, value: i } = e, [l, c] = I("default");
|
|
4553
4553
|
let u = i, m = Xn, d = i;
|
|
4554
4554
|
a.selectionValues.size ? u = a.selectionValues.get(i) : Array.isArray(i) ? (d = i[0], u = i[1]) : a.fieldType === "boolean" && (u = i ? uf(a.label) : `${t("not")} ${a.label.toLowerCase()}`, m = Xd);
|
|
4555
4555
|
const p = D(async () => {
|
|
@@ -4572,7 +4572,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
4572
4572
|
a.colors === "auto" ? m(d) : a.colors[d] || m(d)
|
|
4573
4573
|
);
|
|
4574
4574
|
}, [a == null ? void 0 : a.colorField]);
|
|
4575
|
-
return
|
|
4575
|
+
return oe(() => {
|
|
4576
4576
|
p().catch((h) => console.error(h));
|
|
4577
4577
|
}, [a == null ? void 0 : a.colorField]), u ? /* @__PURE__ */ s(Yo, { color: l, children: u }) : null;
|
|
4578
4578
|
}, Yo = (e) => {
|
|
@@ -4661,7 +4661,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
4661
4661
|
}) => {
|
|
4662
4662
|
const { token: o } = Qe.useToken(), [a, i] = I(
|
|
4663
4663
|
e ? e.split(";").map((y) => y.trim()).filter((y) => y) : []
|
|
4664
|
-
), [l, c] = I(""), u = q(null), m =
|
|
4664
|
+
), [l, c] = I(""), u = q(null), m = se(Je), { elementHasLostFocus: d } = m || {};
|
|
4665
4665
|
Et(() => {
|
|
4666
4666
|
if (e) {
|
|
4667
4667
|
const y = e.split(";").map((v) => v.trim()).filter(Boolean);
|
|
@@ -4859,7 +4859,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
4859
4859
|
l(!1);
|
|
4860
4860
|
}
|
|
4861
4861
|
}, [r, u, c, e == null ? void 0 : e.items]);
|
|
4862
|
-
|
|
4862
|
+
oe(() => {
|
|
4863
4863
|
e != null && e.items && (e == null ? void 0 : e.items.length) > 0 && m();
|
|
4864
4864
|
}, [e == null ? void 0 : e.items]);
|
|
4865
4865
|
const d = Q(
|
|
@@ -4907,7 +4907,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
4907
4907
|
dependencies: n = []
|
|
4908
4908
|
}) => {
|
|
4909
4909
|
const [r, o] = I(0);
|
|
4910
|
-
return
|
|
4910
|
+
return oe(() => {
|
|
4911
4911
|
const i = () => {
|
|
4912
4912
|
if (e.current) {
|
|
4913
4913
|
const l = window.innerHeight, c = e.current.getBoundingClientRect(), u = l - c.top;
|
|
@@ -4930,7 +4930,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
4930
4930
|
);
|
|
4931
4931
|
return { getColumnState: t, updateColumnState: n };
|
|
4932
4932
|
}, kf = (e) => {
|
|
4933
|
-
|
|
4933
|
+
oe(() => () => {
|
|
4934
4934
|
n(), o();
|
|
4935
4935
|
}, []);
|
|
4936
4936
|
const [t, n] = ze(
|
|
@@ -5017,7 +5017,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
5017
5017
|
return o.current;
|
|
5018
5018
|
}
|
|
5019
5019
|
}, [i, t]);
|
|
5020
|
-
|
|
5020
|
+
oe(() => {
|
|
5021
5021
|
if (!e) {
|
|
5022
5022
|
r(!1);
|
|
5023
5023
|
return;
|
|
@@ -5232,7 +5232,7 @@ const ff = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(wa,
|
|
|
5232
5232
|
}
|
|
5233
5233
|
)
|
|
5234
5234
|
] }), { defaultAlgorithm: Mf, defaultSeed: jf } = Qe, Bf = Mf(jf), Jo = Ze((e) => {
|
|
5235
|
-
const { ooui: t } = e, { id: n, decimalDigits: r, readOnly: o, required: a } = t, i =
|
|
5235
|
+
const { ooui: t } = e, { id: n, decimalDigits: r, readOnly: o, required: a } = t, i = se(Je), { elementHasLostFocus: l } = i || {}, c = Q(() => a && !o, [a, o]), u = Q(
|
|
5236
5236
|
() => c ? Hf : Ir,
|
|
5237
5237
|
[c]
|
|
5238
5238
|
), m = D((p) => p ? /* @__PURE__ */ s(Nr, { content: p }) : null, []), d = D((p) => `${p}`.replace(/[^0-9.-]+/g, ""), []);
|
|
@@ -5258,7 +5258,7 @@ const Hf = mt(Ir)`
|
|
|
5258
5258
|
background-color: ${Bf.colorPrimaryBg};
|
|
5259
5259
|
}
|
|
5260
5260
|
`, { useToken: Uf } = Qe, { defaultAlgorithm: Wf, defaultSeed: Yf } = Qe, Gf = Wf(Yf), qn = Ze((e) => {
|
|
5261
|
-
const { ooui: t, onChange: n } = e, { id: r, readOnly: o, required: a } = t, { token: i } = Uf(), l = a && !o ? { backgroundColor: i.colorPrimaryBg } : void 0, c =
|
|
5261
|
+
const { ooui: t, onChange: n } = e, { id: r, readOnly: o, required: a } = t, { token: i } = Uf(), l = a && !o ? { backgroundColor: i.colorPrimaryBg } : void 0, c = se(Je), { elementHasLostFocus: u } = c || {}, m = Q(() => a && !o, [a, o]), d = Q(
|
|
5262
5262
|
() => m ? qf : Ir,
|
|
5263
5263
|
[m]
|
|
5264
5264
|
), p = D((g) => g ? /* @__PURE__ */ s(Nr, { content: g }) : null, []), h = D((g) => g === void 0 ? "" : typeof g == "string" && !isNaN(parseFloat(g)) ? `${Math.trunc(parseFloat(g))}`.replace(/[^0-9\-]+/g, "") : typeof g == "number" ? `${Math.trunc(g)}`.replace(/[^0-9\-]+/g, "") : "", []), f = D(
|
|
@@ -5428,7 +5428,7 @@ const { useToken: nm } = Qe, { Title: rm } = Zt, { Header: om, Content: sm, Foot
|
|
|
5428
5428
|
},
|
|
5429
5429
|
[t]
|
|
5430
5430
|
);
|
|
5431
|
-
|
|
5431
|
+
oe(() => (e ? (i(!0), document.addEventListener("keydown", m), document.body.style.overflow = "hidden") : (document.removeEventListener("keydown", m), document.body.style.overflow = ""), () => {
|
|
5432
5432
|
document.removeEventListener("keydown", m), document.body.style.overflow = "";
|
|
5433
5433
|
}), [e, m]);
|
|
5434
5434
|
const d = () => {
|
|
@@ -6286,7 +6286,7 @@ var oh = Ja;
|
|
|
6286
6286
|
const ts = /* @__PURE__ */ Bi(oh), sh = _t(
|
|
6287
6287
|
(e, t) => {
|
|
6288
6288
|
const { onSubmit: n, searchValues: r, searchFields: o, onChange: a } = e, [i] = Ot.useForm();
|
|
6289
|
-
|
|
6289
|
+
oe(() => {
|
|
6290
6290
|
i.setFieldsValue(r);
|
|
6291
6291
|
}, [r]), Dt(t, () => ({
|
|
6292
6292
|
submit: i.submit,
|
|
@@ -6338,7 +6338,7 @@ const ts = /* @__PURE__ */ Bi(oh), sh = _t(
|
|
|
6338
6338
|
), Qa = (e) => {
|
|
6339
6339
|
var F;
|
|
6340
6340
|
const { onSubmit: t, isOpen: n, onClose: r, searchFields: o, fields: a, searchValues: i } = e, l = q(), { t: c } = me(), [u, m] = I(), d = q(null), [p, h] = I();
|
|
6341
|
-
|
|
6341
|
+
oe(() => {
|
|
6342
6342
|
n && (h(void 0), setTimeout(() => {
|
|
6343
6343
|
const C = document.querySelector(
|
|
6344
6344
|
"#floating-drawer-overlay input"
|
|
@@ -6515,7 +6515,7 @@ function Wr(e) {
|
|
|
6515
6515
|
searchValues: p,
|
|
6516
6516
|
showLimitOptions: h = !0
|
|
6517
6517
|
} = e, [f, g] = I(), [y, v] = I(), [b, F] = I(!1), C = q(), { token: T } = ch(), [O] = Ot.useForm();
|
|
6518
|
-
|
|
6518
|
+
oe(() => {
|
|
6519
6519
|
O.setFieldsValue(p);
|
|
6520
6520
|
}, [p]);
|
|
6521
6521
|
const S = () => {
|
|
@@ -6686,7 +6686,7 @@ function Xa({
|
|
|
6686
6686
|
}
|
|
6687
6687
|
const ns = () => {
|
|
6688
6688
|
const [e, t] = I(!document.hidden);
|
|
6689
|
-
return
|
|
6689
|
+
return oe(() => {
|
|
6690
6690
|
const n = () => {
|
|
6691
6691
|
t(!document.hidden);
|
|
6692
6692
|
};
|
|
@@ -6726,6 +6726,7 @@ const Yr = ({
|
|
|
6726
6726
|
const n = {};
|
|
6727
6727
|
return e != null && e.colors && (n.colors = e.colors), e != null && e.status && (n.status = e.status), n;
|
|
6728
6728
|
}
|
|
6729
|
+
return {};
|
|
6729
6730
|
}, dh = 3 * 1e3, el = (e) => {
|
|
6730
6731
|
const {
|
|
6731
6732
|
tableRef: t,
|
|
@@ -6747,7 +6748,7 @@ const Yr = ({
|
|
|
6747
6748
|
) : !0,
|
|
6748
6749
|
[o]
|
|
6749
6750
|
);
|
|
6750
|
-
|
|
6751
|
+
oe(() => {
|
|
6751
6752
|
a === !1 && S(), (a === void 0 || a === !0) && !b && S(), (a === void 0 || a === !0) && b && w();
|
|
6752
6753
|
}, [a, b]);
|
|
6753
6754
|
const T = D(() => {
|
|
@@ -6811,8 +6812,10 @@ const Yr = ({
|
|
|
6811
6812
|
y,
|
|
6812
6813
|
u
|
|
6813
6814
|
]);
|
|
6814
|
-
|
|
6815
|
-
g(), v()
|
|
6815
|
+
oe(() => () => {
|
|
6816
|
+
g(), v();
|
|
6817
|
+
}, []), Et(() => ((o == null ? void 0 : o.length) && p && (O(), d.current = setInterval(O, dh)), () => {
|
|
6818
|
+
d.current && (clearInterval(d.current), d.current = null);
|
|
6816
6819
|
}), [
|
|
6817
6820
|
o,
|
|
6818
6821
|
f,
|
|
@@ -6826,7 +6829,7 @@ const Yr = ({
|
|
|
6826
6829
|
}, [g, v]), w = D(() => {
|
|
6827
6830
|
h(!0);
|
|
6828
6831
|
}, []);
|
|
6829
|
-
|
|
6832
|
+
oe(() => () => {
|
|
6830
6833
|
F.current = {};
|
|
6831
6834
|
}, []);
|
|
6832
6835
|
const A = D(() => {
|
|
@@ -6857,11 +6860,13 @@ const Yr = ({
|
|
|
6857
6860
|
), [O, S] = ze(
|
|
6858
6861
|
$.getHandler().parseConditions
|
|
6859
6862
|
), w = ns();
|
|
6860
|
-
|
|
6863
|
+
oe(() => {
|
|
6861
6864
|
o === !1 && j(), (o === void 0 || o === !0) && !w && j(), (o === void 0 || o === !0) && w && L();
|
|
6862
|
-
}, [o, w]),
|
|
6863
|
-
T();
|
|
6864
|
-
}
|
|
6865
|
+
}, [o, w]), oe(() => () => {
|
|
6866
|
+
T(), S();
|
|
6867
|
+
}, []), oe(() => (o || (T(), S()), () => {
|
|
6868
|
+
T(), S();
|
|
6869
|
+
}), [o, T, S]), oe(() => {
|
|
6865
6870
|
if (!p) {
|
|
6866
6871
|
m(!1), d.current = [];
|
|
6867
6872
|
return;
|
|
@@ -6967,11 +6972,11 @@ const Yr = ({
|
|
|
6967
6972
|
P,
|
|
6968
6973
|
uh
|
|
6969
6974
|
)), () => {
|
|
6970
|
-
|
|
6975
|
+
v.current && (clearInterval(v.current), v.current = null);
|
|
6971
6976
|
}), [u, b, P, c]);
|
|
6972
6977
|
const j = D(() => {
|
|
6973
|
-
F(!1), v.current && (clearInterval(v.current), v.current = null), T();
|
|
6974
|
-
}, [T]), L = D(() => {
|
|
6978
|
+
F(!1), v.current && (clearInterval(v.current), v.current = null), T(), S();
|
|
6979
|
+
}, [T, S]), L = D(() => {
|
|
6975
6980
|
F(!0);
|
|
6976
6981
|
}, []);
|
|
6977
6982
|
return {
|
|
@@ -7119,9 +7124,9 @@ function gh(e, t) {
|
|
|
7119
7124
|
} = Xa({ useLocalState: !c }), te = d || de, le = q(te), Ie = Yt(
|
|
7120
7125
|
Nt.FEATURE_MANY2ONE_SORT
|
|
7121
7126
|
);
|
|
7122
|
-
|
|
7127
|
+
oe(() => {
|
|
7123
7128
|
tt();
|
|
7124
|
-
}, []),
|
|
7129
|
+
}, []), oe(() => {
|
|
7125
7130
|
var ce;
|
|
7126
7131
|
(te !== void 0 && le.current === void 0 || typeof te == "string" && typeof le.current == "string" && te !== le.current) && (H == null || H([]), Z == null || Z({}), (ce = h.current) == null || ce.unselectAll(), rn()), le.current = te;
|
|
7127
7132
|
}, [te]);
|
|
@@ -7157,7 +7162,7 @@ function gh(e, t) {
|
|
|
7157
7162
|
treeOoui: ge,
|
|
7158
7163
|
updateAttributes: Fe,
|
|
7159
7164
|
results: W
|
|
7160
|
-
}),
|
|
7165
|
+
}), ie = Tn(() => {
|
|
7161
7166
|
if (ge)
|
|
7162
7167
|
return $r(
|
|
7163
7168
|
ge,
|
|
@@ -7168,8 +7173,8 @@ function gh(e, t) {
|
|
|
7168
7173
|
Ie
|
|
7169
7174
|
);
|
|
7170
7175
|
}, [ge, u, Ie]), Ue = Q(() => {
|
|
7171
|
-
if (
|
|
7172
|
-
return
|
|
7176
|
+
if (ie)
|
|
7177
|
+
return ie.map((ce) => ({
|
|
7173
7178
|
...ce,
|
|
7174
7179
|
render: (Oe, et) => /* @__PURE__ */ s(
|
|
7175
7180
|
rs,
|
|
@@ -7181,7 +7186,7 @@ function gh(e, t) {
|
|
|
7181
7186
|
}
|
|
7182
7187
|
)
|
|
7183
7188
|
}));
|
|
7184
|
-
}, [
|
|
7189
|
+
}, [ie, xe]), $e = Q(() => {
|
|
7185
7190
|
if (!_)
|
|
7186
7191
|
return Ta({
|
|
7187
7192
|
treeViewId: R == null ? void 0 : R.view_id,
|
|
@@ -7395,7 +7400,7 @@ function gh(e, t) {
|
|
|
7395
7400
|
resetTableViewLabel: S("resetTableView")
|
|
7396
7401
|
}),
|
|
7397
7402
|
[S]
|
|
7398
|
-
), hn = Q(() => !
|
|
7403
|
+
), hn = Q(() => !ie || !ge ? null : /* @__PURE__ */ s(
|
|
7399
7404
|
Li,
|
|
7400
7405
|
{
|
|
7401
7406
|
readonly: !1,
|
|
@@ -7424,7 +7429,7 @@ function gh(e, t) {
|
|
|
7424
7429
|
U,
|
|
7425
7430
|
A,
|
|
7426
7431
|
re,
|
|
7427
|
-
|
|
7432
|
+
ie,
|
|
7428
7433
|
Ue,
|
|
7429
7434
|
ht,
|
|
7430
7435
|
Ae,
|
|
@@ -7663,7 +7668,7 @@ const rl = _t(gh), ii = (e, t = "14px -apple-system") => {
|
|
|
7663
7668
|
context: T,
|
|
7664
7669
|
readonly: O,
|
|
7665
7670
|
onSelectAllRecords: S
|
|
7666
|
-
} = e, w = q(null), [A, R] = I([]), x = q(!1), [_, P] = I(), { t: E } = me(), j = q(r), L =
|
|
7671
|
+
} = e, w = q(null), [A, R] = I([]), x = q(!1), [_, P] = I(), { t: E } = me(), j = q(r), L = se(
|
|
7667
7672
|
wt
|
|
7668
7673
|
), { title: V = void 0, setTitle: M = void 0 } = (C ? L : {}) || {}, k = Yt(
|
|
7669
7674
|
Nt.FEATURE_MANY2ONE_SORT
|
|
@@ -7683,16 +7688,16 @@ const rl = _t(gh), ii = (e, t = "14px -apple-system") => {
|
|
|
7683
7688
|
var ee;
|
|
7684
7689
|
(ee = w.current) == null || ee.unselectAll();
|
|
7685
7690
|
}
|
|
7686
|
-
})),
|
|
7691
|
+
})), oe(() => {
|
|
7687
7692
|
const ee = Ut(a);
|
|
7688
7693
|
P(ee), ee.string && V !== ee.string && (M == null || M(ee.string));
|
|
7689
|
-
}, [a, V]),
|
|
7694
|
+
}, [a, V]), oe(() => {
|
|
7690
7695
|
if (!_)
|
|
7691
7696
|
return;
|
|
7692
7697
|
x.current = !1;
|
|
7693
7698
|
const ee = mn(_, i);
|
|
7694
7699
|
R(ee);
|
|
7695
|
-
}, [i]),
|
|
7700
|
+
}, [i]), oe(() => {
|
|
7696
7701
|
j.current = r;
|
|
7697
7702
|
}, [r]);
|
|
7698
7703
|
const Y = (n - 1) * j.current + 1, K = Y - 1 + A.length, Z = o === void 0 ? null : o === 0 ? E("no_results") : E("summary").replace("{from}", Y == null ? void 0 : Y.toString()).replace("{to}", K == null ? void 0 : K.toString()).replace("{total}", o == null ? void 0 : o.toString()), de = Q(() => {
|
|
@@ -7838,10 +7843,10 @@ const sl = (e) => {
|
|
|
7838
7843
|
fields: d.field_parent ? { ...d.fields, [d.field_parent]: {} } : d.fields,
|
|
7839
7844
|
context: u,
|
|
7840
7845
|
attrs: Be
|
|
7841
|
-
}),
|
|
7842
|
-
ue.current = [...
|
|
7843
|
-
const Ue =
|
|
7844
|
-
resultsToSort:
|
|
7846
|
+
}), ie = Te[0];
|
|
7847
|
+
ue.current = [...ie], de(Fn(Te[1])), B(pr(Te[1]));
|
|
7848
|
+
const Ue = ie.map((Me) => Me.id), $e = h !== void 0 ? Sn({
|
|
7849
|
+
resultsToSort: ie,
|
|
7845
7850
|
sorter: h,
|
|
7846
7851
|
fields: { ...d.fields, ...p.fields }
|
|
7847
7852
|
}) : [...ue.current];
|
|
@@ -7863,8 +7868,8 @@ const sl = (e) => {
|
|
|
7863
7868
|
m
|
|
7864
7869
|
]), X = D(
|
|
7865
7870
|
async (ae) => {
|
|
7866
|
-
const { params: Pe, newOffset: xe } = ae || {}, Le = Qt(Pe || O, b), { colors: Be, status: Te } = Ut(d),
|
|
7867
|
-
Be && (
|
|
7871
|
+
const { params: Pe, newOffset: xe } = ae || {}, Le = Qt(Pe || O, b), { colors: Be, status: Te } = Ut(d), ie = {};
|
|
7872
|
+
Be && (ie.colors = Be), Te && (ie.status = Te);
|
|
7868
7873
|
const { totalItems: Ue, results: $e, attrsEvaluated: Me } = await $.getHandler().searchForTree({
|
|
7869
7874
|
params: Le,
|
|
7870
7875
|
limit: W.current,
|
|
@@ -7872,7 +7877,7 @@ const sl = (e) => {
|
|
|
7872
7877
|
model: t,
|
|
7873
7878
|
fields: d.field_parent ? { ...d.fields, [d.field_parent]: {} } : d.fields,
|
|
7874
7879
|
context: u,
|
|
7875
|
-
attrs:
|
|
7880
|
+
attrs: ie
|
|
7876
7881
|
});
|
|
7877
7882
|
de(Fn(Me)), B(pr(Me)), ue.current = [...$e];
|
|
7878
7883
|
const ve = h !== void 0 ? Sn({
|
|
@@ -8028,9 +8033,9 @@ function wh(e, t) {
|
|
|
8028
8033
|
rootTree: m = !1,
|
|
8029
8034
|
parentContext: d = {},
|
|
8030
8035
|
onChangeSelectedRowKeys: p
|
|
8031
|
-
} = e, [h, f] = I(!1), [g, y] = I(!1), v = q(!1), b = q(null), [F, C] = I(), [T, O] = I(), [S, w] = I(), [A, R] = I(), [x, _] = I(200), P = q(), { height: E } = Vr(), j =
|
|
8036
|
+
} = e, [h, f] = I(!1), [g, y] = I(!1), v = q(!1), b = q(null), [F, C] = I(), [T, O] = I(), [S, w] = I(), [A, R] = I(), [x, _] = I(200), P = q(), { height: E } = Vr(), j = se(
|
|
8032
8037
|
kn
|
|
8033
|
-
), { processAction: L } = j || {}, V =
|
|
8038
|
+
), { processAction: L } = j || {}, V = se(
|
|
8034
8039
|
wt
|
|
8035
8040
|
), {
|
|
8036
8041
|
setResults: M = void 0,
|
|
@@ -8066,7 +8071,7 @@ function wh(e, t) {
|
|
|
8066
8071
|
searchError: Le,
|
|
8067
8072
|
page: Be,
|
|
8068
8073
|
limit: Te,
|
|
8069
|
-
offset:
|
|
8074
|
+
offset: ie,
|
|
8070
8075
|
getResults: Ue,
|
|
8071
8076
|
requestPageChange: $e,
|
|
8072
8077
|
changeSort: Me,
|
|
@@ -8106,9 +8111,9 @@ function wh(e, t) {
|
|
|
8106
8111
|
v.current = !1, ae();
|
|
8107
8112
|
},
|
|
8108
8113
|
getFields: () => T == null ? void 0 : T.fields
|
|
8109
|
-
})),
|
|
8114
|
+
})), oe(() => {
|
|
8110
8115
|
g && u && T && (v.current = !1, ae());
|
|
8111
|
-
}, [Be,
|
|
8116
|
+
}, [Be, ie, g, u, i, T]);
|
|
8112
8117
|
const st = async () => {
|
|
8113
8118
|
y(!1), f(!0), R(void 0), X == null || X(!0);
|
|
8114
8119
|
try {
|
|
@@ -8133,7 +8138,7 @@ function wh(e, t) {
|
|
|
8133
8138
|
context: d
|
|
8134
8139
|
})), w(Ae), O(ut);
|
|
8135
8140
|
};
|
|
8136
|
-
|
|
8141
|
+
oe(() => {
|
|
8137
8142
|
st();
|
|
8138
8143
|
}, [n]);
|
|
8139
8144
|
const re = D(
|
|
@@ -8197,7 +8202,7 @@ function wh(e, t) {
|
|
|
8197
8202
|
]),
|
|
8198
8203
|
onClear: Fe,
|
|
8199
8204
|
limit: Ie,
|
|
8200
|
-
offset:
|
|
8205
|
+
offset: ie,
|
|
8201
8206
|
isSearching: xe,
|
|
8202
8207
|
onSubmit: qe,
|
|
8203
8208
|
onLimitChange: re,
|
|
@@ -8244,7 +8249,7 @@ function wh(e, t) {
|
|
|
8244
8249
|
Ue,
|
|
8245
8250
|
Ie,
|
|
8246
8251
|
Te,
|
|
8247
|
-
|
|
8252
|
+
ie,
|
|
8248
8253
|
Re,
|
|
8249
8254
|
re,
|
|
8250
8255
|
Be,
|
|
@@ -8327,7 +8332,7 @@ const il = _t(wh), Sh = Ct, Ch = (e) => {
|
|
|
8327
8332
|
colorsForResults: Le,
|
|
8328
8333
|
statusForResults: Be,
|
|
8329
8334
|
updateAttributes: Te,
|
|
8330
|
-
clearAttributes:
|
|
8335
|
+
clearAttributes: ie
|
|
8331
8336
|
} = Za(), {
|
|
8332
8337
|
isFieldLoading: Ue,
|
|
8333
8338
|
refresh: $e,
|
|
@@ -8437,7 +8442,7 @@ const il = _t(wh), Sh = Ct, Ch = (e) => {
|
|
|
8437
8442
|
f
|
|
8438
8443
|
]
|
|
8439
8444
|
);
|
|
8440
|
-
|
|
8445
|
+
oe(() => {
|
|
8441
8446
|
if (!t)
|
|
8442
8447
|
return () => {
|
|
8443
8448
|
tt(), rt(), fe();
|
|
@@ -8453,7 +8458,7 @@ const il = _t(wh), Sh = Ct, Ch = (e) => {
|
|
|
8453
8458
|
J,
|
|
8454
8459
|
c,
|
|
8455
8460
|
M
|
|
8456
|
-
]),
|
|
8461
|
+
]), oe(() => {
|
|
8457
8462
|
var be;
|
|
8458
8463
|
if (J !== U.current) {
|
|
8459
8464
|
if (J !== void 0 && U.current === void 0 || typeof J == "string" && typeof U.current == "string" && J !== U.current) {
|
|
@@ -8543,9 +8548,9 @@ const il = _t(wh), Sh = Ct, Ch = (e) => {
|
|
|
8543
8548
|
E,
|
|
8544
8549
|
He
|
|
8545
8550
|
]), jt = D(async () => {
|
|
8546
|
-
|
|
8551
|
+
ie(), Ce(), Z(!0), y(0), qe(), g([]), le.current = void 0, J || $e(), await St();
|
|
8547
8552
|
}, [
|
|
8548
|
-
|
|
8553
|
+
ie,
|
|
8549
8554
|
Ce,
|
|
8550
8555
|
y,
|
|
8551
8556
|
qe,
|
|
@@ -8796,7 +8801,7 @@ const il = _t(wh), Sh = Ct, Ch = (e) => {
|
|
|
8796
8801
|
al.displayName = "PaginatedTableComponent";
|
|
8797
8802
|
const ai = (e) => {
|
|
8798
8803
|
const t = q(e);
|
|
8799
|
-
return
|
|
8804
|
+
return oe(() => {
|
|
8800
8805
|
t.current = e;
|
|
8801
8806
|
}, [e]), q((...n) => {
|
|
8802
8807
|
var r;
|
|
@@ -8885,7 +8890,7 @@ function Fh(e, t) {
|
|
|
8885
8890
|
refreshResults: R,
|
|
8886
8891
|
getFields: () => y == null ? void 0 : y.fields
|
|
8887
8892
|
}));
|
|
8888
|
-
const Te = Q(() => Be ? /* @__PURE__ */ s(zo, { aggregates: Le, isLoading: xe }) : null, [Le, xe, Be]),
|
|
8893
|
+
const Te = Q(() => Be ? /* @__PURE__ */ s(zo, { aggregates: Le, isLoading: xe }) : null, [Le, xe, Be]), ie = D(
|
|
8889
8894
|
(ve) => /* @__PURE__ */ s(zn, { color: ve, style: { marginLeft: 7 } }),
|
|
8890
8895
|
[]
|
|
8891
8896
|
), Ue = Q(
|
|
@@ -8949,7 +8954,7 @@ function Fh(e, t) {
|
|
|
8949
8954
|
onGetFirstVisibleColumn: Ie,
|
|
8950
8955
|
setTreeFirstVisibleColumn: le,
|
|
8951
8956
|
footerComp: Te,
|
|
8952
|
-
statusComp:
|
|
8957
|
+
statusComp: ie,
|
|
8953
8958
|
onRowStatus: x,
|
|
8954
8959
|
onRowStyle: Y,
|
|
8955
8960
|
headerCheckboxState: W,
|
|
@@ -8983,8 +8988,8 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
8983
8988
|
return "legacy";
|
|
8984
8989
|
const T = Xi(i.arch, "infinite");
|
|
8985
8990
|
return T ? T === "1" ? "infinite" : T === "0" ? "paginated" : "legacy" : "legacy";
|
|
8986
|
-
}, [i]), { currentView: y, setPreviousView: v, setTreeType: b, setSelectedRowItems: F } =
|
|
8987
|
-
|
|
8991
|
+
}, [i]), { currentView: y, setPreviousView: v, setTreeType: b, setSelectedRowItems: F } = se(wt);
|
|
8992
|
+
oe(() => {
|
|
8988
8993
|
b == null || b(g);
|
|
8989
8994
|
}, [g]);
|
|
8990
8995
|
const C = D(
|
|
@@ -9008,7 +9013,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9008
9013
|
v
|
|
9009
9014
|
]
|
|
9010
9015
|
);
|
|
9011
|
-
return
|
|
9016
|
+
return oe(() => {
|
|
9012
9017
|
f.current && !t && g === "infinite" && (F == null || F([])), f.current = t;
|
|
9013
9018
|
}, [t, g]), t ? /* @__PURE__ */ N(Rn, { children: [
|
|
9014
9019
|
/* @__PURE__ */ s(jr, { showSummary: g !== "infinite", children: /* @__PURE__ */ s(
|
|
@@ -9102,24 +9107,24 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9102
9107
|
x || [],
|
|
9103
9108
|
n.fields
|
|
9104
9109
|
)
|
|
9105
|
-
), [qe, Fe] = I(0), [ae, Pe] = I(void 0), [xe, Le] = I(), [Be, Te] = I(xr), [
|
|
9110
|
+
), [qe, Fe] = I(0), [ae, Pe] = I(void 0), [xe, Le] = I(), [Be, Te] = I(xr), [ie, Ue] = I(
|
|
9106
9111
|
P
|
|
9107
9112
|
), [$e, Me] = I(
|
|
9108
9113
|
A !== void 0 ? A : Ct
|
|
9109
9114
|
), [ve, Ce] = I(r), [Ee, we] = I(
|
|
9110
9115
|
_ || 1
|
|
9111
9116
|
);
|
|
9112
|
-
|
|
9117
|
+
oe(() => {
|
|
9113
9118
|
p && p.length > 0 && !h && (f == null || f(0), m == null || m(p[0].id));
|
|
9114
|
-
}, [p]),
|
|
9119
|
+
}, [p]), oe(() => {
|
|
9115
9120
|
Me(A !== void 0 ? A : Ct);
|
|
9116
|
-
}, [A]),
|
|
9121
|
+
}, [A]), oe(() => {
|
|
9117
9122
|
a.length === 1 ? Ie(a[0]) : a.length > 1 && Ie(
|
|
9118
9123
|
a.filter(
|
|
9119
9124
|
(st) => st.view_id !== n.view_id
|
|
9120
9125
|
)[0]
|
|
9121
9126
|
);
|
|
9122
|
-
}, [a]),
|
|
9127
|
+
}, [a]), oe(() => {
|
|
9123
9128
|
(le == null ? void 0 : le.view_id) === n.view_id && a.length > 1 && Ie(
|
|
9124
9129
|
a.filter(
|
|
9125
9130
|
(st) => st.view_id !== n.view_id
|
|
@@ -9194,7 +9199,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9194
9199
|
setSearchQuery: Le,
|
|
9195
9200
|
treeType: Be,
|
|
9196
9201
|
setTreeType: Te,
|
|
9197
|
-
order:
|
|
9202
|
+
order: ie,
|
|
9198
9203
|
setOrder: Ue,
|
|
9199
9204
|
currentPage: Ee,
|
|
9200
9205
|
setCurrentPage: we
|
|
@@ -9202,8 +9207,8 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9202
9207
|
children: t
|
|
9203
9208
|
}
|
|
9204
9209
|
);
|
|
9205
|
-
}, Oh = () => !!
|
|
9206
|
-
const e =
|
|
9210
|
+
}, Oh = () => !!se(wt), sr = () => {
|
|
9211
|
+
const e = se(wt);
|
|
9207
9212
|
return e || {
|
|
9208
9213
|
title: "",
|
|
9209
9214
|
currentView: {},
|
|
@@ -9310,14 +9315,14 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9310
9315
|
manualIds: l,
|
|
9311
9316
|
fixedHeight: c,
|
|
9312
9317
|
viewData: u
|
|
9313
|
-
} = e, [m, d] = I(!1), [p, h] = I(), f =
|
|
9318
|
+
} = e, [m, d] = I(!1), [p, h] = I(), f = se(
|
|
9314
9319
|
wt
|
|
9315
9320
|
), { setGraphIsLoading: g = void 0 } = f || {}, [y] = ze($.getHandler().getView);
|
|
9316
9321
|
Dt(t, () => ({
|
|
9317
9322
|
refresh: () => {
|
|
9318
9323
|
v();
|
|
9319
9324
|
}
|
|
9320
|
-
})),
|
|
9325
|
+
})), oe(() => {
|
|
9321
9326
|
v();
|
|
9322
9327
|
}, [u, n]);
|
|
9323
9328
|
async function v() {
|
|
@@ -9403,7 +9408,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9403
9408
|
graphData: m
|
|
9404
9409
|
};
|
|
9405
9410
|
}, Ph = (e, t) => {
|
|
9406
|
-
const { view_id: n, model: r, context: o, domain: a, manualIds: i, fixedHeight: l } = e, c =
|
|
9411
|
+
const { view_id: n, model: r, context: o, domain: a, manualIds: i, fixedHeight: l } = e, c = se(
|
|
9407
9412
|
wt
|
|
9408
9413
|
), { setGraphIsLoading: u = void 0 } = c || {}, { error: m, loading: d, graphData: p, fetchData: h } = Dh({
|
|
9409
9414
|
view_id: n,
|
|
@@ -9412,13 +9417,13 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9412
9417
|
context: o,
|
|
9413
9418
|
manualIds: i
|
|
9414
9419
|
});
|
|
9415
|
-
if (
|
|
9420
|
+
if (oe(() => {
|
|
9416
9421
|
u == null || u(d);
|
|
9417
9422
|
}, [d]), Dt(t, () => ({
|
|
9418
9423
|
refresh: () => {
|
|
9419
9424
|
h();
|
|
9420
9425
|
}
|
|
9421
|
-
})),
|
|
9426
|
+
})), oe(() => {
|
|
9422
9427
|
h();
|
|
9423
9428
|
}, [n]), d || !p)
|
|
9424
9429
|
return /* @__PURE__ */ s(er, {});
|
|
@@ -9548,7 +9553,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9548
9553
|
const { token: t } = Vh(), { ooui: n, value: r } = e, { locale: o } = me(), [a, i] = I(n.icon), [l, c] = I(n.color), [u] = ze(
|
|
9549
9554
|
$.getHandler().parseCondition
|
|
9550
9555
|
);
|
|
9551
|
-
|
|
9556
|
+
oe(() => {
|
|
9552
9557
|
async function g(y, v) {
|
|
9553
9558
|
if (y && y.includes(":"))
|
|
9554
9559
|
try {
|
|
@@ -9619,10 +9624,10 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9619
9624
|
}, $h = (e) => {
|
|
9620
9625
|
const { ooui: t } = e, { actionId: n, height: r } = t, { activeId: o } = ed(), { actionData: a, treeShortcut: i, loading: l, error: c, fetchData: u } = cu(n), m = Yt(
|
|
9621
9626
|
Nt.FEATURE_READFORVIEW
|
|
9622
|
-
), d =
|
|
9627
|
+
), d = se(
|
|
9623
9628
|
Rt
|
|
9624
9629
|
), { openShortcut: p } = d || {};
|
|
9625
|
-
if (
|
|
9630
|
+
if (oe(() => {
|
|
9626
9631
|
t && u();
|
|
9627
9632
|
}, [t, o]), c && c.message !== "active_id_not_found")
|
|
9628
9633
|
return /* @__PURE__ */ s(oa, { error: c });
|
|
@@ -9671,7 +9676,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9671
9676
|
const { ooui: t } = e;
|
|
9672
9677
|
return /* @__PURE__ */ s(Ne, { type: "array", ...e, children: /* @__PURE__ */ s(Bh, { ooui: t }) });
|
|
9673
9678
|
}, Bh = (e) => {
|
|
9674
|
-
const { value: t, ooui: n, onChange: r } = e, { items: o = [] } = t || {}, a = o.filter((O) => O.operation !== "pendingRemove").map((O) => O.id), [i, l] = I([]), [c, u] = I(), [m, d] = I(!1), { relation: p, context: h, readOnly: f, field: g } = n, y =
|
|
9679
|
+
const { value: t, ooui: n, onChange: r } = e, { items: o = [] } = t || {}, a = o.filter((O) => O.operation !== "pendingRemove").map((O) => O.id), [i, l] = I([]), [c, u] = I(), [m, d] = I(!1), { relation: p, context: h, readOnly: f, field: g } = n, y = se(Je), { getContext: v } = y || {};
|
|
9675
9680
|
Mt(() => {
|
|
9676
9681
|
F();
|
|
9677
9682
|
}, [o]);
|
|
@@ -9972,7 +9977,7 @@ const Ah = _t(Fh), xr = "legacy", _h = (e) => {
|
|
|
9972
9977
|
} = e, c = q(null), [u, m] = I(!0), [d, p] = ze(
|
|
9973
9978
|
$.getHandler().readObjects
|
|
9974
9979
|
), h = ns();
|
|
9975
|
-
|
|
9980
|
+
oe(() => {
|
|
9976
9981
|
l === !1 && g(), (l === void 0 || l === !0) && !h && g(), (l === void 0 || l === !0) && h && y();
|
|
9977
9982
|
}, [l, h]);
|
|
9978
9983
|
const f = D(async () => {
|
|
@@ -10042,7 +10047,7 @@ function og(e, t) {
|
|
|
10042
10047
|
forcedValues: O = {},
|
|
10043
10048
|
parentWidth: S,
|
|
10044
10049
|
onMustRefreshParent: w
|
|
10045
|
-
} = e, { t: A } = me(), [R, x] = I(!1), [_, P] = I(), [E, j] = I(), [L] = Ot.useForm(), [V, M] = I(), [k, H] = I(), Y =
|
|
10050
|
+
} = e, { t: A } = me(), [R, x] = I(!1), [_, P] = I(), [E, j] = I(), [L] = Ot.useForm(), [V, M] = I(), [k, H] = I(), Y = se(dl), [K, Z] = I(), [de, pe] = I(!1), B = q(), W = q({}), ue = q({}), ee = q(!1), J = q(!1), U = q(!1), te = (S !== void 0 ? S : K) < rg, le = se(Je), { activeId: Ie, getPlainValues: ge } = le || {}, We = q(!1), qe = se(
|
|
10046
10051
|
wt
|
|
10047
10052
|
), {
|
|
10048
10053
|
setFormIsSaving: Fe = void 0,
|
|
@@ -10052,8 +10057,8 @@ function og(e, t) {
|
|
|
10052
10057
|
setAttachments: Le = void 0,
|
|
10053
10058
|
title: Be = void 0,
|
|
10054
10059
|
setTitle: Te = void 0,
|
|
10055
|
-
isActive:
|
|
10056
|
-
} = (C ? qe : {}) || {}, Ue =
|
|
10060
|
+
isActive: ie = void 0
|
|
10061
|
+
} = (C ? qe : {}) || {}, Ue = se(
|
|
10057
10062
|
kn
|
|
10058
10063
|
), { processAction: $e, globalValues: Me } = Ue || {};
|
|
10059
10064
|
Dt(t, () => ({
|
|
@@ -10067,7 +10072,7 @@ function og(e, t) {
|
|
|
10067
10072
|
clearAndReload: () => {
|
|
10068
10073
|
B.current = void 0, j(void 0), hn();
|
|
10069
10074
|
}
|
|
10070
|
-
})),
|
|
10075
|
+
})), oe(() => {
|
|
10071
10076
|
if (P(void 0), !(!n && !f)) {
|
|
10072
10077
|
if (!F) {
|
|
10073
10078
|
B.current = void 0, j(void 0);
|
|
@@ -10075,7 +10080,7 @@ function og(e, t) {
|
|
|
10075
10080
|
}
|
|
10076
10081
|
(r === void 0 && k || r !== void 0 && k && r < 0) && (B.current = void 0, j(void 0)), hn();
|
|
10077
10082
|
}
|
|
10078
|
-
}, [r, n, h, f, F]),
|
|
10083
|
+
}, [r, n, h, f, F]), oe(() => {
|
|
10079
10084
|
de && (Ve({
|
|
10080
10085
|
elementHasLostFocus: !0
|
|
10081
10086
|
}), pe(!1));
|
|
@@ -10087,7 +10092,7 @@ function og(e, t) {
|
|
|
10087
10092
|
}, Ee = (G) => {
|
|
10088
10093
|
Fe == null || Fe(!1), u == null || u(G);
|
|
10089
10094
|
}, we = D(() => r || B.current, [r]), [tt, st] = I(() => B.current);
|
|
10090
|
-
|
|
10095
|
+
oe(() => {
|
|
10091
10096
|
B.current !== tt && st(B.current);
|
|
10092
10097
|
}, [B.current]);
|
|
10093
10098
|
const rt = Q(() => r || tt, [r, tt]);
|
|
@@ -10560,7 +10565,7 @@ function og(e, t) {
|
|
|
10560
10565
|
autorefreshableFields: E == null ? void 0 : E.autorefreshableFields,
|
|
10561
10566
|
fieldDefs: k,
|
|
10562
10567
|
onAutorefreshableFieldsChange: ar,
|
|
10563
|
-
isActive:
|
|
10568
|
+
isActive: ie
|
|
10564
10569
|
});
|
|
10565
10570
|
async function It({
|
|
10566
10571
|
type: G,
|
|
@@ -10676,7 +10681,7 @@ const Nn = _t(og), Ln = (e) => {
|
|
|
10676
10681
|
actionData: l,
|
|
10677
10682
|
...c
|
|
10678
10683
|
} = e, { model: u } = c, { modalWidth: m } = Vr(), [d, p] = I(r), [h, f] = I(!1), [g, y] = I(), { action_id: v, res_id: b, action_type: F, view_id: C } = l || {};
|
|
10679
|
-
|
|
10684
|
+
oe(() => {
|
|
10680
10685
|
i && T();
|
|
10681
10686
|
}, [l, i]);
|
|
10682
10687
|
async function T() {
|
|
@@ -10885,10 +10890,10 @@ const Nn = _t(og), Ln = (e) => {
|
|
|
10885
10890
|
context: l,
|
|
10886
10891
|
id: c,
|
|
10887
10892
|
domain: u
|
|
10888
|
-
} = r, m = o && !i ? { backgroundColor: ul.colorPrimaryBg } : void 0, [d, p] = I(!1), [h, f] = I(!1), [g, y] = I(!1), [v, b] = I(), F = q(!1), [C, T] = I(""), O = q(), S =
|
|
10889
|
-
|
|
10893
|
+
} = r, m = o && !i ? { backgroundColor: ul.colorPrimaryBg } : void 0, [d, p] = I(!1), [h, f] = I(!1), [g, y] = I(!1), [v, b] = I(), F = q(!1), [C, T] = I(""), O = q(), S = se(Je), { domain: w, getValues: A, getFields: R, getContext: x, elementHasLostFocus: _ } = S || {}, P = q([]), [E, j] = I([]), L = t && t[0] || void 0, V = t && t[1] || "";
|
|
10894
|
+
oe(() => {
|
|
10890
10895
|
!Array.isArray(t) && t && K(t);
|
|
10891
|
-
}, [t]),
|
|
10896
|
+
}, [t]), oe(() => {
|
|
10892
10897
|
L && V.length === 0 ? K(L) : L && V.length > 0 ? T(V) : !L && !V && T(O.current || "");
|
|
10893
10898
|
}, [t]);
|
|
10894
10899
|
const M = (B) => {
|
|
@@ -11170,9 +11175,9 @@ const Nn = _t(og), Ln = (e) => {
|
|
|
11170
11175
|
formRef: n,
|
|
11171
11176
|
onRefreshParentValues: r
|
|
11172
11177
|
}) => {
|
|
11173
|
-
const { t: o } = me(), a =
|
|
11178
|
+
const { t: o } = me(), a = se(
|
|
11174
11179
|
kn
|
|
11175
|
-
), i =
|
|
11180
|
+
), i = se(
|
|
11176
11181
|
Rt
|
|
11177
11182
|
), { processAction: l } = a || {}, { openRelate: c } = i || {}, u = D(async () => {
|
|
11178
11183
|
var f;
|
|
@@ -11546,9 +11551,9 @@ function hg(e) {
|
|
|
11546
11551
|
}
|
|
11547
11552
|
const gg = (e) => {
|
|
11548
11553
|
var tt, st, rt;
|
|
11549
|
-
const { value: t, onChange: n, ooui: r, views: o } = e, { items: a = [] } = t || {}, { currentView: i, setCurrentView: l, itemIndex: c, setItemIndex: u } =
|
|
11554
|
+
const { value: t, onChange: n, ooui: r, views: o } = e, { items: a = [] } = t || {}, { currentView: i, setCurrentView: l, itemIndex: c, setItemIndex: u } = se(
|
|
11550
11555
|
$n
|
|
11551
|
-
), m =
|
|
11556
|
+
), m = se(Je), {
|
|
11552
11557
|
activeId: d,
|
|
11553
11558
|
getFields: p,
|
|
11554
11559
|
getValues: h,
|
|
@@ -11563,7 +11568,7 @@ const gg = (e) => {
|
|
|
11563
11568
|
} = r, ee = r.type === "many2many", { id: J } = r, U = a.filter(
|
|
11564
11569
|
(re) => (re.values || re.treeValues) && re.operation !== "pendingRemove"
|
|
11565
11570
|
), X = q();
|
|
11566
|
-
|
|
11571
|
+
oe(() => {
|
|
11567
11572
|
if (X.current !== i) {
|
|
11568
11573
|
X.current = i, te();
|
|
11569
11574
|
return;
|
|
@@ -11573,7 +11578,7 @@ const gg = (e) => {
|
|
|
11573
11578
|
const te = D(() => {
|
|
11574
11579
|
(i === "form" && a.some((re) => !re.values) || i === "tree" && a.some((re) => !re.treeValues)) && Ie();
|
|
11575
11580
|
}, [a, i]);
|
|
11576
|
-
|
|
11581
|
+
oe(() => {
|
|
11577
11582
|
We();
|
|
11578
11583
|
}, [g]);
|
|
11579
11584
|
const le = (re) => {
|
|
@@ -11668,7 +11673,7 @@ const gg = (e) => {
|
|
|
11668
11673
|
hl({
|
|
11669
11674
|
t: v,
|
|
11670
11675
|
onOk: async () => {
|
|
11671
|
-
i === "form" ?
|
|
11676
|
+
i === "form" ? ie() : Ue();
|
|
11672
11677
|
}
|
|
11673
11678
|
});
|
|
11674
11679
|
return;
|
|
@@ -11676,7 +11681,7 @@ const gg = (e) => {
|
|
|
11676
11681
|
pl({
|
|
11677
11682
|
t: v,
|
|
11678
11683
|
onOk: async () => {
|
|
11679
|
-
i === "form" ?
|
|
11684
|
+
i === "form" ? ie() : Ue();
|
|
11680
11685
|
}
|
|
11681
11686
|
});
|
|
11682
11687
|
}, Be = async () => {
|
|
@@ -11689,7 +11694,7 @@ const gg = (e) => {
|
|
|
11689
11694
|
i === "form" ? xe(() => {
|
|
11690
11695
|
x(!0);
|
|
11691
11696
|
}) : x(!0);
|
|
11692
|
-
},
|
|
11697
|
+
}, ie = async () => {
|
|
11693
11698
|
T(!0), F(!1), S(void 0);
|
|
11694
11699
|
try {
|
|
11695
11700
|
if (U[c].id > 0) {
|
|
@@ -11940,8 +11945,8 @@ const gg = (e) => {
|
|
|
11940
11945
|
getValues: o,
|
|
11941
11946
|
getContext: a,
|
|
11942
11947
|
domain: i
|
|
11943
|
-
} =
|
|
11944
|
-
|
|
11948
|
+
} = se(Je) || {};
|
|
11949
|
+
oe(() => {
|
|
11945
11950
|
l();
|
|
11946
11951
|
}, [i]);
|
|
11947
11952
|
async function l() {
|
|
@@ -12027,8 +12032,8 @@ const gg = (e) => {
|
|
|
12027
12032
|
formView: o,
|
|
12028
12033
|
triggerChange: a
|
|
12029
12034
|
}) => {
|
|
12030
|
-
const [i, l] = I(!1), { itemIndex: c } =
|
|
12031
|
-
|
|
12035
|
+
const [i, l] = I(!1), { itemIndex: c } = se($n), { t: u } = me();
|
|
12036
|
+
oe(() => {
|
|
12032
12037
|
const f = e[c];
|
|
12033
12038
|
(!f || (f == null ? void 0 : f.operation) === "original") && l(!1);
|
|
12034
12039
|
}, [c, e]);
|
|
@@ -12104,7 +12109,7 @@ const gg = (e) => {
|
|
|
12104
12109
|
onChange: a
|
|
12105
12110
|
}, i) => {
|
|
12106
12111
|
var u, m;
|
|
12107
|
-
const { itemIndex: l } =
|
|
12112
|
+
const { itemIndex: l } = se($n), { t: c } = me();
|
|
12108
12113
|
return t.length === 0 ? c("noCurrentEntries") : /* @__PURE__ */ s(
|
|
12109
12114
|
Nn,
|
|
12110
12115
|
{
|
|
@@ -12139,7 +12144,7 @@ const Sg = ({
|
|
|
12139
12144
|
selectedRowKeys: o,
|
|
12140
12145
|
setSelectedRowKeys: a
|
|
12141
12146
|
}) => {
|
|
12142
|
-
const { t: i } = me(), { currentView: l, itemIndex: c, setItemIndex: u } =
|
|
12147
|
+
const { t: i } = me(), { currentView: l, itemIndex: c, setItemIndex: u } = se(
|
|
12143
12148
|
$n
|
|
12144
12149
|
), m = D(async () => {
|
|
12145
12150
|
const f = Cg({
|
|
@@ -12445,7 +12450,7 @@ const xg = ({
|
|
|
12445
12450
|
});
|
|
12446
12451
|
}, Rg = ["form", "tree", "graph"], Og = (e) => {
|
|
12447
12452
|
var xe, Le, Be;
|
|
12448
|
-
const t = q(null), { value: n, onChange: r, ooui: o, views: a } = e, { items: i = [] } = n || {}, l = wg({ one2manyItems: i }), { currentView: c, setCurrentView: u, itemIndex: m, setItemIndex: d } =
|
|
12453
|
+
const t = q(null), { value: n, onChange: r, ooui: o, views: a } = e, { items: i = [] } = n || {}, l = wg({ one2manyItems: i }), { currentView: c, setCurrentView: u, itemIndex: m, setItemIndex: d } = se(
|
|
12449
12454
|
$n
|
|
12450
12455
|
), {
|
|
12451
12456
|
readOnly: p,
|
|
@@ -12453,7 +12458,7 @@ const xg = ({
|
|
|
12453
12458
|
context: f,
|
|
12454
12459
|
domain: g,
|
|
12455
12460
|
id: y
|
|
12456
|
-
} = o, v =
|
|
12461
|
+
} = o, v = se(Je), {
|
|
12457
12462
|
activeId: b,
|
|
12458
12463
|
getContext: F,
|
|
12459
12464
|
fetchValues: C
|
|
@@ -12484,9 +12489,9 @@ const xg = ({
|
|
|
12484
12489
|
return Te || o.label;
|
|
12485
12490
|
}, [c, o.label, a]), k = o.type === "many2many", H = D(
|
|
12486
12491
|
(Te) => {
|
|
12487
|
-
var
|
|
12492
|
+
var ie, Ue;
|
|
12488
12493
|
r == null || r({
|
|
12489
|
-
fields: ((
|
|
12494
|
+
fields: ((ie = a.get("form")) == null ? void 0 : ie.fields) || ((Ue = a.get("tree")) == null ? void 0 : Ue.fields),
|
|
12490
12495
|
items: Te
|
|
12491
12496
|
});
|
|
12492
12497
|
},
|
|
@@ -12544,14 +12549,14 @@ const xg = ({
|
|
|
12544
12549
|
selectedRowKeys: _,
|
|
12545
12550
|
setSelectedRowKeys: P
|
|
12546
12551
|
}), We = () => {
|
|
12547
|
-
const Te = Array.from(a.keys()),
|
|
12552
|
+
const Te = Array.from(a.keys()), ie = Te[(Te.indexOf(c) + 1) % Te.length];
|
|
12548
12553
|
c === "form" ? Z(() => {
|
|
12549
|
-
u(
|
|
12550
|
-
}) : u(
|
|
12554
|
+
u(ie);
|
|
12555
|
+
}) : u(ie);
|
|
12551
12556
|
}, qe = At(
|
|
12552
12557
|
(Te) => {
|
|
12553
|
-
var
|
|
12554
|
-
(
|
|
12558
|
+
var ie;
|
|
12559
|
+
(ie = a.get("form")) != null && ie.fields && U(Te);
|
|
12555
12560
|
},
|
|
12556
12561
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
12557
12562
|
[l]
|
|
@@ -12693,7 +12698,7 @@ const xg = ({
|
|
|
12693
12698
|
var O;
|
|
12694
12699
|
const { ooui: t } = e, { mode: n, relation: r, views: o, required: a, context: i } = t;
|
|
12695
12700
|
let l;
|
|
12696
|
-
const [c, u] = I(!0), [m, d] = I(), [p, h] = I(/* @__PURE__ */ new Map()), f =
|
|
12701
|
+
const [c, u] = I(!0), [m, d] = I(), [p, h] = I(/* @__PURE__ */ new Map()), f = se(Je), { getContext: g, formView: y } = f || {}, { view_id: v } = y || {};
|
|
12697
12702
|
Mt(() => {
|
|
12698
12703
|
C();
|
|
12699
12704
|
}, [t]);
|
|
@@ -12770,8 +12775,8 @@ const xg = ({
|
|
|
12770
12775
|
const { ooui: t } = e, { required: n } = t;
|
|
12771
12776
|
return /* @__PURE__ */ s(Ne, { required: n, type: "number", ...e, children: /* @__PURE__ */ s(Ng, { ooui: t }) });
|
|
12772
12777
|
}, Ng = (e) => {
|
|
12773
|
-
const { ooui: t, value: n, onChange: r } = e, { id: o, readOnly: a, required: i } = t, { token: l } = kg(), c = i && !a ? { backgroundColor: l.colorPrimaryBg } : void 0, u = q(), [m, d] = I(), p =
|
|
12774
|
-
|
|
12778
|
+
const { ooui: t, value: n, onChange: r } = e, { id: o, readOnly: a, required: i } = t, { token: l } = kg(), c = i && !a ? { backgroundColor: l.colorPrimaryBg } : void 0, u = q(), [m, d] = I(), p = se(Je), { elementHasLostFocus: h } = p || {};
|
|
12779
|
+
oe(() => {
|
|
12775
12780
|
d(va(n));
|
|
12776
12781
|
}, [n]);
|
|
12777
12782
|
const f = (v) => {
|
|
@@ -12891,7 +12896,7 @@ function Mg(e) {
|
|
|
12891
12896
|
);
|
|
12892
12897
|
}
|
|
12893
12898
|
const { useToken: jg } = Qe, { TextArea: So } = ft, Bg = (e) => {
|
|
12894
|
-
const { ooui: t } = e, { id: n, readOnly: r, required: o, height: a, translatable: i } = t, { token: l } = jg(), c = o && !r ? { backgroundColor: l.colorPrimaryBg } : void 0, u =
|
|
12899
|
+
const { ooui: t } = e, { id: n, readOnly: r, required: o, height: a, translatable: i } = t, { token: l } = jg(), c = o && !r ? { backgroundColor: l.colorPrimaryBg } : void 0, u = se(Je), { elementHasLostFocus: m } = u || {};
|
|
12895
12900
|
return /* @__PURE__ */ s(Ne, { required: o, ...e, children: i ? /* @__PURE__ */ s(
|
|
12896
12901
|
Hg,
|
|
12897
12902
|
{
|
|
@@ -12920,7 +12925,7 @@ const { useToken: jg } = Qe, { TextArea: So } = ft, Bg = (e) => {
|
|
|
12920
12925
|
onChange: r,
|
|
12921
12926
|
height: o
|
|
12922
12927
|
}) => {
|
|
12923
|
-
const a =
|
|
12928
|
+
const a = se(Je), {
|
|
12924
12929
|
activeId: i,
|
|
12925
12930
|
activeModel: l,
|
|
12926
12931
|
fetchValues: c,
|
|
@@ -13306,7 +13311,7 @@ const { useToken: jg } = Qe, { TextArea: So } = ft, Bg = (e) => {
|
|
|
13306
13311
|
return /* @__PURE__ */ s(Ne, { required: n, ...e, children: /* @__PURE__ */ s(oy, { ooui: t }) });
|
|
13307
13312
|
}, oy = (e) => {
|
|
13308
13313
|
const { value: t, onChange: n, ooui: r } = e, { required: o, selectionValues: a, readOnly: i, domain: l } = r, c = t == null ? void 0 : t.split(","), [u, m] = I([]), [d, p] = I();
|
|
13309
|
-
return
|
|
13314
|
+
return oe(() => {
|
|
13310
13315
|
if (!t) {
|
|
13311
13316
|
p(void 0), m([]);
|
|
13312
13317
|
return;
|
|
@@ -13356,7 +13361,7 @@ const { useToken: jg } = Qe, { TextArea: So } = ft, Bg = (e) => {
|
|
|
13356
13361
|
const { ooui: t } = e, { required: n } = t;
|
|
13357
13362
|
return /* @__PURE__ */ s(Ne, { required: n, ...e, children: /* @__PURE__ */ s(ay, { ooui: t }) });
|
|
13358
13363
|
}, ay = (e) => {
|
|
13359
|
-
const { ooui: t, value: n, onChange: r } = e, { readOnly: o, required: a, filenameField: i } = t, { token: l } = sy(), c = a && !o ? { backgroundColor: l.colorPrimaryBg } : void 0, u = q(null), { setFieldValue: m, getFieldValue: d } =
|
|
13364
|
+
const { ooui: t, value: n, onChange: r } = e, { readOnly: o, required: a, filenameField: i } = t, { token: l } = sy(), c = a && !o ? { backgroundColor: l.colorPrimaryBg } : void 0, u = q(null), { setFieldValue: m, getFieldValue: d } = se(Je) || {}, { t: p } = me(), h = n ? Dd(n) : "", f = (F) => {
|
|
13360
13365
|
r == null || r(F);
|
|
13361
13366
|
};
|
|
13362
13367
|
async function g() {
|
|
@@ -13535,7 +13540,7 @@ function cy(e) {
|
|
|
13535
13540
|
onAddNewAttachment: r,
|
|
13536
13541
|
onListAllAttachments: o,
|
|
13537
13542
|
onViewAttachmentDetails: a
|
|
13538
|
-
} = e, { formRef: i } =
|
|
13543
|
+
} = e, { formRef: i } = se(wt), [l, c] = I(!1), [u, m] = I([]), [d, p] = I(!1), { t: h } = me(), f = D(async () => {
|
|
13539
13544
|
if (!(!t || t.length === 0)) {
|
|
13540
13545
|
c(!0);
|
|
13541
13546
|
try {
|
|
@@ -13589,7 +13594,7 @@ function cy(e) {
|
|
|
13589
13594
|
},
|
|
13590
13595
|
[a]
|
|
13591
13596
|
);
|
|
13592
|
-
return
|
|
13597
|
+
return oe(() => {
|
|
13593
13598
|
f();
|
|
13594
13599
|
}, [f]), /* @__PURE__ */ N(ne, { children: [
|
|
13595
13600
|
/* @__PURE__ */ s(
|
|
@@ -13631,7 +13636,7 @@ const dy = () => {
|
|
|
13631
13636
|
} = sr(), [l, c] = ze(
|
|
13632
13637
|
$.getHandler().searchForTree
|
|
13633
13638
|
);
|
|
13634
|
-
|
|
13639
|
+
oe(() => () => {
|
|
13635
13640
|
c();
|
|
13636
13641
|
}, [c]);
|
|
13637
13642
|
const u = Uo(), m = D(
|
|
@@ -13703,7 +13708,7 @@ const dy = () => {
|
|
|
13703
13708
|
};
|
|
13704
13709
|
};
|
|
13705
13710
|
function uy({ toolbar: e }) {
|
|
13706
|
-
const t =
|
|
13711
|
+
const t = se(
|
|
13707
13712
|
Rt
|
|
13708
13713
|
), { t: n } = me(), { onNextClick: r, onPreviousClick: o } = dy(), {
|
|
13709
13714
|
availableViews: a,
|
|
@@ -13998,8 +14003,8 @@ const ui = (e, t) => ({
|
|
|
13998
14003
|
values: { selection_associated_object: `${e},${t}` },
|
|
13999
14004
|
forced_values: { res_model: e, res_id: t }
|
|
14000
14005
|
}), { useToken: my } = Qe, Fl = (e) => {
|
|
14001
|
-
const { ooui: t, value: n, onChange: r, valueValidator: o, linkPrefix: a = "" } = e, { id: i, readOnly: l, required: c } = t, { token: u } = my(), m = c && !l ? { backgroundColor: u.colorPrimaryBg } : void 0, d =
|
|
14002
|
-
|
|
14006
|
+
const { ooui: t, value: n, onChange: r, valueValidator: o, linkPrefix: a = "" } = e, { id: i, readOnly: l, required: c } = t, { token: u } = my(), m = c && !l ? { backgroundColor: u.colorPrimaryBg } : void 0, d = se(Je), { elementHasLostFocus: p } = d || {}, [h, f] = I(!1), [g, y] = I(!1);
|
|
14007
|
+
oe(() => {
|
|
14003
14008
|
l && !h && y(!1), !n && !l && (f(!0), y(!0));
|
|
14004
14009
|
}, [h, l]);
|
|
14005
14010
|
const v = (b) => {
|
|
@@ -14166,7 +14171,7 @@ function yy({ refreshGraph: e }) {
|
|
|
14166
14171
|
graphIsLoading: c,
|
|
14167
14172
|
previousView: u,
|
|
14168
14173
|
setPreviousView: m
|
|
14169
|
-
} =
|
|
14174
|
+
} = se(wt);
|
|
14170
14175
|
return /* @__PURE__ */ N(ot, { wrap: !0, children: [
|
|
14171
14176
|
/* @__PURE__ */ s(
|
|
14172
14177
|
fa,
|
|
@@ -14224,7 +14229,7 @@ const vy = (e) => {
|
|
|
14224
14229
|
formView: i,
|
|
14225
14230
|
treeView: l,
|
|
14226
14231
|
graphView: c
|
|
14227
|
-
} = e, u = q(), m =
|
|
14232
|
+
} = e, u = q(), m = se(
|
|
14228
14233
|
wt
|
|
14229
14234
|
), {
|
|
14230
14235
|
setResults: d = void 0,
|
|
@@ -14247,10 +14252,10 @@ const vy = (e) => {
|
|
|
14247
14252
|
setSearchValues: _,
|
|
14248
14253
|
currentView: P
|
|
14249
14254
|
} = m || {}, [E, j] = I(!0);
|
|
14250
|
-
|
|
14255
|
+
oe(() => {
|
|
14251
14256
|
var K;
|
|
14252
14257
|
(K = u.current) == null || K.refresh();
|
|
14253
|
-
}, [R]),
|
|
14258
|
+
}, [R]), oe(() => {
|
|
14254
14259
|
t.view_id !== P.view_id && j(!0);
|
|
14255
14260
|
}, [P]);
|
|
14256
14261
|
const { clear: L, searchFilterLoading: V, searchError: M, offset: k, tableRefreshing: H } = sl({
|
|
@@ -14385,7 +14390,7 @@ const vy = (e) => {
|
|
|
14385
14390
|
);
|
|
14386
14391
|
};
|
|
14387
14392
|
function Sy() {
|
|
14388
|
-
const { isLoading: e, dashboardRef: t, moveItemsEnabled: n, setMoveItemsEnabled: r } =
|
|
14393
|
+
const { isLoading: e, dashboardRef: t, moveItemsEnabled: n, setMoveItemsEnabled: r } = se(is), { t: o } = me();
|
|
14389
14394
|
return /* @__PURE__ */ N(ot, { wrap: !0, children: [
|
|
14390
14395
|
/* @__PURE__ */ s(
|
|
14391
14396
|
gt,
|
|
@@ -14435,7 +14440,7 @@ function Sy() {
|
|
|
14435
14440
|
] });
|
|
14436
14441
|
}
|
|
14437
14442
|
const Cy = (e) => {
|
|
14438
|
-
const { dashboardData: t, visible: n } = e, r = q(), o =
|
|
14443
|
+
const { dashboardData: t, visible: n } = e, r = q(), o = se(
|
|
14439
14444
|
Rt
|
|
14440
14445
|
), { openShortcut: a } = o || {};
|
|
14441
14446
|
return !t || !n ? null : /* @__PURE__ */ N(
|
|
@@ -14499,12 +14504,12 @@ function Ty({
|
|
|
14499
14504
|
}
|
|
14500
14505
|
const Iy = () => {
|
|
14501
14506
|
const { currentTab: e } = Ho(), { title: t } = Zn(), { shareUrl: n } = Ty({ currentTab: e });
|
|
14502
|
-
|
|
14507
|
+
oe(() => {
|
|
14503
14508
|
if (n) {
|
|
14504
14509
|
const r = new URL(n, window.location.origin);
|
|
14505
14510
|
window.location.pathname + window.location.search !== r.pathname + r.search && window.history.replaceState({}, "", r.pathname + r.search);
|
|
14506
14511
|
}
|
|
14507
|
-
}, [e, n]),
|
|
14512
|
+
}, [e, n]), oe(() => {
|
|
14508
14513
|
document.title = t, e != null && e.title && e.title.length > 0 && (document.title = (e == null ? void 0 : e.title) + " - " + t);
|
|
14509
14514
|
}, [e, t]);
|
|
14510
14515
|
};
|
|
@@ -14530,7 +14535,7 @@ function Fy(e, t) {
|
|
|
14530
14535
|
order: F
|
|
14531
14536
|
} = e, [C, T] = I(), [O, S] = I([]), [w, A] = I(!0), R = p || void 0, [x, _] = I(
|
|
14532
14537
|
R
|
|
14533
|
-
), [P, E] = I([]), [j, L] = I(), [V, M] = I([]), [k, H] = I(), [Y, K] = I(0), [Z, de] = I(!1), [pe, B] = I(!1), [W, ue] = I(), { t: ee } = me(), J = q(), U = q(), X =
|
|
14538
|
+
), [P, E] = I([]), [j, L] = I(), [V, M] = I([]), [k, H] = I(), [Y, K] = I(0), [Z, de] = I(!1), [pe, B] = I(!1), [W, ue] = I(), { t: ee } = me(), J = q(), U = q(), X = se(
|
|
14534
14539
|
Rt
|
|
14535
14540
|
), {
|
|
14536
14541
|
setCurrentView: te,
|
|
@@ -14548,12 +14553,12 @@ function Fy(e, t) {
|
|
|
14548
14553
|
{ enableOnFormTags: !0, preventDefault: !0 },
|
|
14549
14554
|
[ge, Ie, C, j, V]
|
|
14550
14555
|
);
|
|
14551
|
-
function Fe(
|
|
14552
|
-
_(
|
|
14556
|
+
function Fe(ie) {
|
|
14557
|
+
_(ie), le == null || le(ie);
|
|
14553
14558
|
}
|
|
14554
14559
|
const ae = D(
|
|
14555
|
-
(
|
|
14556
|
-
T(
|
|
14560
|
+
(ie) => {
|
|
14561
|
+
T(ie), te == null || te(ie);
|
|
14557
14562
|
},
|
|
14558
14563
|
[te]
|
|
14559
14564
|
);
|
|
@@ -14562,7 +14567,7 @@ function Fy(e, t) {
|
|
|
14562
14567
|
}));
|
|
14563
14568
|
const Pe = D(async () => {
|
|
14564
14569
|
A(!0);
|
|
14565
|
-
const
|
|
14570
|
+
const ie = [], Ue = [];
|
|
14566
14571
|
for (const ve of a) {
|
|
14567
14572
|
const [Ce, Ee] = ve;
|
|
14568
14573
|
Ee !== "dashboard" ? Ue.push({
|
|
@@ -14597,7 +14602,7 @@ function Fy(e, t) {
|
|
|
14597
14602
|
res_model: r,
|
|
14598
14603
|
view_id: we[0],
|
|
14599
14604
|
view_type: we[1]
|
|
14600
|
-
}),
|
|
14605
|
+
}), ie.push({
|
|
14601
14606
|
type: "dashboard",
|
|
14602
14607
|
id: o.active_id,
|
|
14603
14608
|
model: r,
|
|
@@ -14608,7 +14613,7 @@ function Fy(e, t) {
|
|
|
14608
14613
|
break;
|
|
14609
14614
|
}
|
|
14610
14615
|
case "form": {
|
|
14611
|
-
|
|
14616
|
+
ie.push({
|
|
14612
14617
|
...Ee,
|
|
14613
14618
|
type: Ce,
|
|
14614
14619
|
extra: { action_id: h, action_type: f }
|
|
@@ -14616,7 +14621,7 @@ function Fy(e, t) {
|
|
|
14616
14621
|
break;
|
|
14617
14622
|
}
|
|
14618
14623
|
case "tree": {
|
|
14619
|
-
|
|
14624
|
+
ie.push({
|
|
14620
14625
|
...Ee,
|
|
14621
14626
|
isExpandable: g,
|
|
14622
14627
|
type: Ce,
|
|
@@ -14625,7 +14630,7 @@ function Fy(e, t) {
|
|
|
14625
14630
|
break;
|
|
14626
14631
|
}
|
|
14627
14632
|
case "graph": {
|
|
14628
|
-
|
|
14633
|
+
ie.push({
|
|
14629
14634
|
...Ee,
|
|
14630
14635
|
type: Ce,
|
|
14631
14636
|
extra: { action_id: h, action_type: f }
|
|
@@ -14635,9 +14640,9 @@ function Fy(e, t) {
|
|
|
14635
14640
|
}
|
|
14636
14641
|
}
|
|
14637
14642
|
let Me;
|
|
14638
|
-
!u &&
|
|
14643
|
+
!u && ie.find((ve) => ve.type === "tree") ? Me = ie.find(
|
|
14639
14644
|
(Ce) => Ce.type === "tree"
|
|
14640
|
-
) : u ? Me =
|
|
14645
|
+
) : u ? Me = ie.find((Ce) => u.id ? Ce.type === u.type && Ce.view_id === u.id : Ce.type === u.type) : Me = ie.find(
|
|
14641
14646
|
(Ce) => Ce.type === "form"
|
|
14642
14647
|
), Me || (vt(
|
|
14643
14648
|
`Error determining the first view to show for model ${r}.
|
|
@@ -14648,12 +14653,12 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14648
14653
|
model: r,
|
|
14649
14654
|
views: a,
|
|
14650
14655
|
initialView: u,
|
|
14651
|
-
availableViews:
|
|
14656
|
+
availableViews: ie,
|
|
14652
14657
|
currentViewToAssign: Me,
|
|
14653
14658
|
action_id: h,
|
|
14654
14659
|
action_type: f
|
|
14655
14660
|
})
|
|
14656
|
-
), qe == null || qe(c)), ae(Me), S(
|
|
14661
|
+
), qe == null || qe(c)), ae(Me), S(ie), A(!1);
|
|
14657
14662
|
}, [
|
|
14658
14663
|
u,
|
|
14659
14664
|
ae,
|
|
@@ -14668,13 +14673,13 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14668
14673
|
c
|
|
14669
14674
|
]);
|
|
14670
14675
|
l({ tabKey: c, canWeClose: xe }), Et(() => {
|
|
14671
|
-
const
|
|
14672
|
-
ae(Ue ||
|
|
14676
|
+
const ie = O.find(($e) => $e.type === "tree"), Ue = O.find(($e) => u.id ? $e.type === u.type && $e.view_id === u.id : $e.type === u.type);
|
|
14677
|
+
ae(Ue || ie), p ? le == null || le(R) : (Fe(void 0), L(void 0)), Pe();
|
|
14673
14678
|
}, [r, a, p]), Et(() => {
|
|
14674
14679
|
if (ge === c) {
|
|
14675
14680
|
le == null || le(x);
|
|
14676
|
-
const
|
|
14677
|
-
te == null || te({ ...C, extra:
|
|
14681
|
+
const ie = { action_id: h, action_type: f };
|
|
14682
|
+
te == null || te({ ...C, extra: ie });
|
|
14678
14683
|
}
|
|
14679
14684
|
}, [Ie, ge]);
|
|
14680
14685
|
async function xe() {
|
|
@@ -14683,13 +14688,13 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14683
14688
|
async function Le() {
|
|
14684
14689
|
ge === c && (C.type === "form" && !await J.current.cancelUnsavedChanges() || de(!0));
|
|
14685
14690
|
}
|
|
14686
|
-
async function Be(
|
|
14691
|
+
async function Be(ie, Ue) {
|
|
14687
14692
|
var ve;
|
|
14688
14693
|
B(!0);
|
|
14689
14694
|
let $e, Me;
|
|
14690
|
-
if (
|
|
14695
|
+
if (ie.length === 1) {
|
|
14691
14696
|
$e = "form", Me = [];
|
|
14692
|
-
const Ce =
|
|
14697
|
+
const Ce = ie[0], Ee = V.findIndex((tt) => tt.id === Ce);
|
|
14693
14698
|
let we;
|
|
14694
14699
|
if (Ee === -1) {
|
|
14695
14700
|
try {
|
|
@@ -14707,9 +14712,9 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14707
14712
|
} else
|
|
14708
14713
|
we = V[Ee];
|
|
14709
14714
|
} else
|
|
14710
|
-
$e = "tree", Me = [["id", "in",
|
|
14715
|
+
$e = "tree", Me = [["id", "in", ie]];
|
|
14711
14716
|
if (B(!1), de(!1), Ue && $e === "form") {
|
|
14712
|
-
Fe(
|
|
14717
|
+
Fe(ie[0]);
|
|
14713
14718
|
const Ce = O.find(
|
|
14714
14719
|
(Ee) => Ee.type === "form"
|
|
14715
14720
|
);
|
|
@@ -14726,7 +14731,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14726
14731
|
initialView: { id: Ce == null ? void 0 : Ce[0], type: $e },
|
|
14727
14732
|
action_id: h,
|
|
14728
14733
|
action_type: f,
|
|
14729
|
-
res_id:
|
|
14734
|
+
res_id: ie[0]
|
|
14730
14735
|
});
|
|
14731
14736
|
}
|
|
14732
14737
|
}
|
|
@@ -14735,10 +14740,10 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
14735
14740
|
J.current.clearAndReload();
|
|
14736
14741
|
else {
|
|
14737
14742
|
Fe(void 0);
|
|
14738
|
-
const
|
|
14743
|
+
const ie = O.find(
|
|
14739
14744
|
(Ue) => Ue.type === "form"
|
|
14740
14745
|
);
|
|
14741
|
-
ae(
|
|
14746
|
+
ae(ie);
|
|
14742
14747
|
}
|
|
14743
14748
|
}
|
|
14744
14749
|
return w ? /* @__PURE__ */ s(Xe, {}) : C ? /* @__PURE__ */ N(
|
|
@@ -14965,7 +14970,7 @@ function Oy(e) {
|
|
|
14965
14970
|
V(JSON.stringify(U));
|
|
14966
14971
|
}
|
|
14967
14972
|
};
|
|
14968
|
-
|
|
14973
|
+
oe(() => {
|
|
14969
14974
|
m && i && pe();
|
|
14970
14975
|
}, [b, C, m, i]);
|
|
14971
14976
|
const B = async (U) => {
|
|
@@ -14999,7 +15004,7 @@ function Oy(e) {
|
|
|
14999
15004
|
});
|
|
15000
15005
|
g(X);
|
|
15001
15006
|
};
|
|
15002
|
-
|
|
15007
|
+
oe(() => {
|
|
15003
15008
|
t ? B("action") : n && B("model");
|
|
15004
15009
|
}, [t, n]);
|
|
15005
15010
|
const ee = (U) => {
|
|
@@ -15042,7 +15047,7 @@ function Oy(e) {
|
|
|
15042
15047
|
}
|
|
15043
15048
|
const Ey = Ze(Oy), Dy = (e) => {
|
|
15044
15049
|
const { model: t } = e, [n, r] = I();
|
|
15045
|
-
|
|
15050
|
+
oe(() => {
|
|
15046
15051
|
o();
|
|
15047
15052
|
}, [t]);
|
|
15048
15053
|
async function o() {
|
|
@@ -15060,12 +15065,12 @@ function Py(e, t) {
|
|
|
15060
15065
|
setIsLoading: p,
|
|
15061
15066
|
openAction: h,
|
|
15062
15067
|
moveItemsEnabled: f
|
|
15063
|
-
} =
|
|
15068
|
+
} = se(is), g = q(), y = q(), [v] = ze($.getHandler().getView), [b] = ze(
|
|
15064
15069
|
$.getHandler().readObjects
|
|
15065
15070
|
), [F] = ze($.getHandler().update), C = Yt(
|
|
15066
15071
|
Nt.FEATURE_READFORVIEW
|
|
15067
15072
|
);
|
|
15068
|
-
|
|
15073
|
+
oe(() => {
|
|
15069
15074
|
T();
|
|
15070
15075
|
}, [n, o, r]), Dt(t, () => ({
|
|
15071
15076
|
refresh: () => {
|
|
@@ -15326,7 +15331,7 @@ const ky = _t(Py), Vy = (e) => {
|
|
|
15326
15331
|
const { ooui: t } = e;
|
|
15327
15332
|
return /* @__PURE__ */ s(Ne, { type: "array", ...e, children: /* @__PURE__ */ s(Ny, { ooui: t }) });
|
|
15328
15333
|
}, Ny = (e) => {
|
|
15329
|
-
const { value: t, ooui: n, onChange: r } = e, { items: o = [] } = t || {}, a = o.filter((w) => w.operation !== "pendingRemove").map((w) => w.id), [i, l] = I([]), [c, u] = I(), [m, d] = I(!1), { relation: p, context: h, readOnly: f, field: g, columns: y } = n, v =
|
|
15334
|
+
const { value: t, ooui: n, onChange: r } = e, { items: o = [] } = t || {}, a = o.filter((w) => w.operation !== "pendingRemove").map((w) => w.id), [i, l] = I([]), [c, u] = I(), [m, d] = I(!1), { relation: p, context: h, readOnly: f, field: g, columns: y } = n, v = se(Je), { getContext: b } = v || {};
|
|
15330
15335
|
Mt(() => {
|
|
15331
15336
|
C();
|
|
15332
15337
|
}, [o]);
|
|
@@ -15444,7 +15449,7 @@ const ky = _t(Py), Vy = (e) => {
|
|
|
15444
15449
|
const { ooui: t } = e, { required: n } = t;
|
|
15445
15450
|
return /* @__PURE__ */ s(Ne, { required: n, type: "any", ...e, children: /* @__PURE__ */ s(Wy, { ...e }) });
|
|
15446
15451
|
}, Wy = (e) => {
|
|
15447
|
-
const { ooui: t, value: n } = e, { selectionValues: r, errorField: o, lastStep: a } = t, i =
|
|
15452
|
+
const { ooui: t, value: n } = e, { selectionValues: r, errorField: o, lastStep: a } = t, i = se(Je);
|
|
15448
15453
|
let l = [], c;
|
|
15449
15454
|
t.fieldType === "json" && n ? (l = n.map((d) => [d.title, d.title]), c = n.findIndex((d) => d.active)) : (l = Array.from(r.entries()), c = l.map((d) => d[0]).indexOf(n));
|
|
15450
15455
|
let u = "process", m = "";
|
|
@@ -15519,7 +15524,7 @@ const ky = _t(Py), Vy = (e) => {
|
|
|
15519
15524
|
/* @__PURE__ */ s("div", { style: d(h.active) })
|
|
15520
15525
|
] }, f)) });
|
|
15521
15526
|
}, Gy = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(Yy, {}) }), qy = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(Ky, { ...e }) }), Ky = (e) => {
|
|
15522
|
-
const { ooui: t, value: n, onChange: r } = e, { lang: o, height: a, readOnly: i } = t, l =
|
|
15527
|
+
const { ooui: t, value: n, onChange: r } = e, { lang: o, height: a, readOnly: i } = t, l = se(Je), { elementHasLostFocus: c } = l || {}, u = D(
|
|
15523
15528
|
(d) => {
|
|
15524
15529
|
c && d.onDidBlurEditorWidget(() => c());
|
|
15525
15530
|
},
|
|
@@ -15611,7 +15616,7 @@ const Zy = (e) => {
|
|
|
15611
15616
|
}
|
|
15612
15617
|
);
|
|
15613
15618
|
}, tv = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(ev, { ooui: e.ooui }) }), nv = (e) => /* @__PURE__ */ s(Ne, { ...e, children: /* @__PURE__ */ s(Ic, {}) }), rv = (e) => {
|
|
15614
|
-
const { ooui: t } = e, n =
|
|
15619
|
+
const { ooui: t } = e, n = se(Je);
|
|
15615
15620
|
let { title: r, text: o, alertType: a, icon: i, buttons: l } = t;
|
|
15616
15621
|
if (t.fieldType && t.id) {
|
|
15617
15622
|
const m = n.getFieldValue(t.id);
|
|
@@ -16195,7 +16200,7 @@ function hv(e) {
|
|
|
16195
16200
|
);
|
|
16196
16201
|
}
|
|
16197
16202
|
function vb() {
|
|
16198
|
-
const e =
|
|
16203
|
+
const e = se(
|
|
16199
16204
|
Rt
|
|
16200
16205
|
), { activeKey: t, tabs: n, onRemoveTab: r, onChangeTab: o } = e || {};
|
|
16201
16206
|
return /* @__PURE__ */ s(ne, { children: n.map((a) => /* @__PURE__ */ s(
|
|
@@ -16211,7 +16216,7 @@ function vb() {
|
|
|
16211
16216
|
)) });
|
|
16212
16217
|
}
|
|
16213
16218
|
function gv(e) {
|
|
16214
|
-
const { tab: t } = e, n =
|
|
16219
|
+
const { tab: t } = e, n = se(
|
|
16215
16220
|
Rt
|
|
16216
16221
|
), { activeKey: r } = n || {}, o = {
|
|
16217
16222
|
display: "none"
|
|
@@ -16220,7 +16225,7 @@ function gv(e) {
|
|
|
16220
16225
|
}
|
|
16221
16226
|
const yv = Ft.memo(gv, () => !0);
|
|
16222
16227
|
function bb() {
|
|
16223
|
-
const e =
|
|
16228
|
+
const e = se(
|
|
16224
16229
|
Rt
|
|
16225
16230
|
), { tabs: t } = e || {}, n = (t == null ? void 0 : t.map((r) => /* @__PURE__ */ s(yv, { tab: r }, r.key))) || null;
|
|
16226
16231
|
return /* @__PURE__ */ s(ne, { children: n });
|
|
@@ -16232,7 +16237,7 @@ const { useToken: vv } = Qe, wb = (e) => {
|
|
|
16232
16237
|
onAddFavourite: r,
|
|
16233
16238
|
onRemoveFavourite: o,
|
|
16234
16239
|
onDropdownClosed: a
|
|
16235
|
-
} = e, [i, l] = I(!1), [c, u] = I(), { t: m } = me(), { token: d } = vv(), p = q(null), h =
|
|
16240
|
+
} = e, [i, l] = I(!1), [c, u] = I(), { t: m } = me(), { token: d } = vv(), p = q(null), h = se(
|
|
16236
16241
|
Rt
|
|
16237
16242
|
), {
|
|
16238
16243
|
openShortcut: f,
|
|
@@ -16261,7 +16266,7 @@ const { useToken: vv } = Qe, wb = (e) => {
|
|
|
16261
16266
|
if (C)
|
|
16262
16267
|
return JSON.stringify(C);
|
|
16263
16268
|
}, [C]);
|
|
16264
|
-
|
|
16269
|
+
oe(() => {
|
|
16265
16270
|
S();
|
|
16266
16271
|
}, [T]);
|
|
16267
16272
|
function O(x) {
|