@gisce/react-ooui 1.2.6 → 1.2.7-rc.0
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/actionbar/TreeActionBar.d.ts.map +1 -1
- package/dist/hooks/useSearch.d.ts.map +1 -1
- package/dist/react-ooui.es.js +327 -321
- package/dist/react-ooui.es.js.map +1 -1
- package/dist/react-ooui.umd.js +9 -9
- package/dist/react-ooui.umd.js.map +1 -1
- package/dist/widgets/views/Tree.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/actionbar/TreeActionBar.tsx +8 -1
- package/src/hooks/useSearch.ts +1 -0
- package/src/widgets/views/SearchTree.tsx +1 -1
- package/src/widgets/views/Tree.tsx +15 -13
package/dist/react-ooui.es.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import qe, { useContext as Y, useState as T, useEffect as ge, useRef as me, useCallback as
|
|
2
|
-
import { Tooltip as ht, theme as $e, Typography as on, Form as it, Row as Se, Col as ce, Modal as We, Button as Ie, Dropdown as Ht, Menu as Le, Spin as
|
|
3
|
-
import { Label as
|
|
1
|
+
import qe, { useContext as Y, useState as T, useEffect as ge, useRef as me, useCallback as Me, forwardRef as wt, useImperativeHandle as bt } from "react";
|
|
2
|
+
import { Tooltip as ht, theme as $e, Typography as on, Form as it, Row as Se, Col as ce, Modal as We, Button as Ie, Dropdown as Ht, Menu as Le, Spin as Ae, Divider as sn, Space as je, Input as Qe, Select as xt, Checkbox as Lt, Alert as ze, Timeline as er, Statistic as qo, Card as zo, Tag as kn, message as wn, DatePicker as Rn, TimePicker as _r, InputNumber as Mn, Progress as Jo, Avatar as Zo, Pagination as Xo, Tabs as Ir, Popover as Qo, Radio as tr, Switch as ei, Steps as nr, Layout as ti } from "antd";
|
|
3
|
+
import { Label as Vt, Field as Fn, Tree as Dr, Reference as ni, Selection as En, Many2one as Vr, Boolean as ri, Container as oi, parseContext as vt, Form as Ar, Integer as On, SearchFieldTypes as ft, SearchFilter as ii, transformDomainForChildWidget as kr, graphProcessor as Rr, parseGraph as $n, graphFieldUtils as si } from "@gisce/ooui";
|
|
4
4
|
import * as rr from "@ant-design/icons";
|
|
5
|
-
import Mr, { QuestionCircleOutlined as Er, ExclamationCircleOutlined as pt, LoadingOutlined as et, DownOutlined as
|
|
5
|
+
import Mr, { QuestionCircleOutlined as Er, ExclamationCircleOutlined as pt, LoadingOutlined as et, DownOutlined as At, WarningOutlined as $r, CloseOutlined as Bt, CheckOutlined as kt, TranslationOutlined as Lr, FolderOpenOutlined as Ln, DownloadOutlined as Nn, ClearOutlined as Pn, StarFilled as Nr, StarOutlined as Pr, UpOutlined as ai, SearchOutlined as Hn, RightCircleOutlined as li, ThunderboltOutlined as Bn, PrinterOutlined as jn, EnterOutlined as Hr, PlusSquareOutlined as ci, MinusSquareOutlined as di, FileAddOutlined as an, AlignLeftOutlined as ui, ApiOutlined as fi, DeleteOutlined as Kn, LeftOutlined as Br, RightOutlined as jr, EyeOutlined as mi, FormOutlined as Nt, TableOutlined as Yn, AreaChartOutlined as hi, CalendarOutlined as pi, LinkOutlined as Kr, SaveOutlined as gi, CopyOutlined as Wn, InfoCircleOutlined as Yr, ReloadOutlined as ln, EditOutlined as Wr, FilterOutlined as Ur, CloseCircleFilled as yi, BorderOuterOutlined as vi, SettingOutlined as wi, ExportOutlined as bi } from "@ant-design/icons";
|
|
6
6
|
import { Interweave as Un } from "interweave";
|
|
7
|
-
import { jsxs as H, jsx as n, Fragment as
|
|
7
|
+
import { jsxs as H, jsx as n, Fragment as Z } from "react/jsx-runtime";
|
|
8
8
|
import * as or from "@tabler/icons-react";
|
|
9
9
|
import xi from "antd/lib/input/TextArea";
|
|
10
10
|
import jt from "styled-components";
|
|
11
11
|
import Gn from "react-measure";
|
|
12
12
|
import _n from "antd/lib/typography/Title";
|
|
13
13
|
import { Line as Ci, Column as Si, Pie as Ti } from "@ant-design/plots";
|
|
14
|
-
import
|
|
14
|
+
import Ct from "use-deep-compare-effect";
|
|
15
15
|
import { Table as Fi } from "@gisce/react-formiga-table";
|
|
16
16
|
import { fileTypeFromBuffer as Oi } from "file-type-buffer-browser";
|
|
17
17
|
import { GridUi as _i } from "@gisce/fiber-diagram";
|
|
@@ -381,7 +381,7 @@ function ve({
|
|
|
381
381
|
if (!o)
|
|
382
382
|
return p();
|
|
383
383
|
const h = /* @__PURE__ */ n(cn, {
|
|
384
|
-
ooui: new
|
|
384
|
+
ooui: new Vt({
|
|
385
385
|
name: d + "_label",
|
|
386
386
|
string: f,
|
|
387
387
|
help: c,
|
|
@@ -403,7 +403,7 @@ function ve({
|
|
|
403
403
|
flex: "auto",
|
|
404
404
|
children: p()
|
|
405
405
|
})]
|
|
406
|
-
}))() : (() => /* @__PURE__ */ H(
|
|
406
|
+
}))() : (() => /* @__PURE__ */ H(Z, {
|
|
407
407
|
children: [h, p()]
|
|
408
408
|
}))();
|
|
409
409
|
}
|
|
@@ -703,7 +703,7 @@ const qr = (e) => {
|
|
|
703
703
|
children: /* @__PURE__ */ H(Ht.Button, {
|
|
704
704
|
disabled: !a || v,
|
|
705
705
|
onClick: A,
|
|
706
|
-
icon: /* @__PURE__ */ n(
|
|
706
|
+
icon: /* @__PURE__ */ n(At, {}),
|
|
707
707
|
type: f ? "primary" : void 0,
|
|
708
708
|
overlay: /* @__PURE__ */ n(Ji, {
|
|
709
709
|
ooui: i,
|
|
@@ -943,7 +943,7 @@ const zr = (e) => {
|
|
|
943
943
|
p(!1), a();
|
|
944
944
|
}
|
|
945
945
|
function M() {
|
|
946
|
-
return c ? /* @__PURE__ */ n(
|
|
946
|
+
return c ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ H(Z, {
|
|
947
947
|
children: [A(), /* @__PURE__ */ n(sn, {}), /* @__PURE__ */ n(Se, {
|
|
948
948
|
justify: "end",
|
|
949
949
|
children: /* @__PURE__ */ H(je, {
|
|
@@ -953,7 +953,7 @@ const zr = (e) => {
|
|
|
953
953
|
disabled: v,
|
|
954
954
|
children: u("cancel")
|
|
955
955
|
}), /* @__PURE__ */ n(Ie, {
|
|
956
|
-
icon: v ? /* @__PURE__ */ n(et, {}) : /* @__PURE__ */ n(
|
|
956
|
+
icon: v ? /* @__PURE__ */ n(et, {}) : /* @__PURE__ */ n(kt, {}),
|
|
957
957
|
disabled: v,
|
|
958
958
|
onClick: I,
|
|
959
959
|
style: {
|
|
@@ -1052,7 +1052,7 @@ const {
|
|
|
1052
1052
|
} = o || {}, [f, c] = T(!1), {
|
|
1053
1053
|
t: m
|
|
1054
1054
|
} = Y(we);
|
|
1055
|
-
return s ? /* @__PURE__ */ H(
|
|
1055
|
+
return s ? /* @__PURE__ */ H(Z, {
|
|
1056
1056
|
children: [/* @__PURE__ */ n("div", {
|
|
1057
1057
|
onClick: () => {
|
|
1058
1058
|
if (u != null && u()) {
|
|
@@ -1086,7 +1086,7 @@ const {
|
|
|
1086
1086
|
c(!1), l == null || l();
|
|
1087
1087
|
}
|
|
1088
1088
|
})]
|
|
1089
|
-
}) : /* @__PURE__ */ n(
|
|
1089
|
+
}) : /* @__PURE__ */ n(Z, {
|
|
1090
1090
|
children: /* @__PURE__ */ H(Se, {
|
|
1091
1091
|
gutter: 8,
|
|
1092
1092
|
wrap: !1,
|
|
@@ -1119,7 +1119,7 @@ const {
|
|
|
1119
1119
|
defaultSeed: os
|
|
1120
1120
|
} = $e, is = rs(os), {
|
|
1121
1121
|
Option: ss
|
|
1122
|
-
} =
|
|
1122
|
+
} = xt, Xr = (e) => {
|
|
1123
1123
|
const {
|
|
1124
1124
|
ooui: t
|
|
1125
1125
|
} = e, {
|
|
@@ -1149,7 +1149,7 @@ const {
|
|
|
1149
1149
|
children: m
|
|
1150
1150
|
}, c);
|
|
1151
1151
|
});
|
|
1152
|
-
return /* @__PURE__ */ n(a && !s ? as :
|
|
1152
|
+
return /* @__PURE__ */ n(a && !s ? as : xt, {
|
|
1153
1153
|
disabled: s,
|
|
1154
1154
|
onChange: r,
|
|
1155
1155
|
value: i,
|
|
@@ -1158,7 +1158,7 @@ const {
|
|
|
1158
1158
|
showSearch: !0,
|
|
1159
1159
|
children: u
|
|
1160
1160
|
});
|
|
1161
|
-
}, as = jt(
|
|
1161
|
+
}, as = jt(xt)`
|
|
1162
1162
|
&.ant-select:not(.ant-select-customize-input) .ant-select-selector {
|
|
1163
1163
|
background-color: ${is.colorPrimaryBg};
|
|
1164
1164
|
}
|
|
@@ -1221,16 +1221,16 @@ var Ts = Ss, Fs = Ts, Os = /^\s+/;
|
|
|
1221
1221
|
function _s(e) {
|
|
1222
1222
|
return e && e.slice(0, Fs(e) + 1).replace(Os, "");
|
|
1223
1223
|
}
|
|
1224
|
-
var Is = _s, Ds = to, Vs = Ds.Symbol, no = Vs, cr = no, ro = Object.prototype, As = ro.hasOwnProperty, ks = ro.toString,
|
|
1224
|
+
var Is = _s, Ds = to, Vs = Ds.Symbol, no = Vs, cr = no, ro = Object.prototype, As = ro.hasOwnProperty, ks = ro.toString, Et = cr ? cr.toStringTag : void 0;
|
|
1225
1225
|
function Rs(e) {
|
|
1226
|
-
var t = As.call(e,
|
|
1226
|
+
var t = As.call(e, Et), r = e[Et];
|
|
1227
1227
|
try {
|
|
1228
|
-
e[
|
|
1228
|
+
e[Et] = void 0;
|
|
1229
1229
|
var i = !0;
|
|
1230
1230
|
} catch {
|
|
1231
1231
|
}
|
|
1232
1232
|
var o = ks.call(e);
|
|
1233
|
-
return i && (t ? e[
|
|
1233
|
+
return i && (t ? e[Et] = r : delete e[Et]), o;
|
|
1234
1234
|
}
|
|
1235
1235
|
var Ms = Rs, Es = Object.prototype, $s = Es.toString;
|
|
1236
1236
|
function Ls(e) {
|
|
@@ -1317,7 +1317,7 @@ function fa(e) {
|
|
|
1317
1317
|
const r = Buffer.from(e, "base64").length / 1e3;
|
|
1318
1318
|
return `${Math.round((r + Number.EPSILON) * 100) / 100} KB`;
|
|
1319
1319
|
}
|
|
1320
|
-
async function
|
|
1320
|
+
async function Dt(e) {
|
|
1321
1321
|
const t = await Oi(
|
|
1322
1322
|
Buffer.from(e, "base64")
|
|
1323
1323
|
);
|
|
@@ -1363,7 +1363,7 @@ const ma = (e) => {
|
|
|
1363
1363
|
i == null || i(c);
|
|
1364
1364
|
};
|
|
1365
1365
|
async function u() {
|
|
1366
|
-
const c = await
|
|
1366
|
+
const c = await Dt(r), m = `data:${c == null ? void 0 : c.mime};base64,${r}`, v = document.createElement("a");
|
|
1367
1367
|
v.href = m, v.download = `image.${c == null ? void 0 : c.ext}`, v.click();
|
|
1368
1368
|
}
|
|
1369
1369
|
async function d(c) {
|
|
@@ -1374,7 +1374,7 @@ const ma = (e) => {
|
|
|
1374
1374
|
function f() {
|
|
1375
1375
|
l(void 0);
|
|
1376
1376
|
}
|
|
1377
|
-
return /* @__PURE__ */ H(
|
|
1377
|
+
return /* @__PURE__ */ H(Z, {
|
|
1378
1378
|
children: [/* @__PURE__ */ H(Se, {
|
|
1379
1379
|
gutter: 8,
|
|
1380
1380
|
wrap: !1,
|
|
@@ -1450,7 +1450,7 @@ const ma = (e) => {
|
|
|
1450
1450
|
r && r(i);
|
|
1451
1451
|
}
|
|
1452
1452
|
});
|
|
1453
|
-
},
|
|
1453
|
+
}, Ot = (e) => {
|
|
1454
1454
|
const t = e.arch, r = e.fields, i = new Dr(r);
|
|
1455
1455
|
return i.parse(t), i;
|
|
1456
1456
|
}, ya = (e, t, r) => e.columns.map((o) => {
|
|
@@ -1490,7 +1490,7 @@ function Xt(e) {
|
|
|
1490
1490
|
t[r.id] = r.colors;
|
|
1491
1491
|
}), t;
|
|
1492
1492
|
}
|
|
1493
|
-
function
|
|
1493
|
+
function _t({
|
|
1494
1494
|
resultsToSort: e,
|
|
1495
1495
|
sorter: t,
|
|
1496
1496
|
fields: r
|
|
@@ -1521,7 +1521,7 @@ const qn = async (e) => {
|
|
|
1521
1521
|
};
|
|
1522
1522
|
let f = [], c;
|
|
1523
1523
|
if (a === "tree" && (o == null ? void 0 : o.arch)) {
|
|
1524
|
-
const h = (p =
|
|
1524
|
+
const h = (p = Ot(o)) == null ? void 0 : p.colors, g = await B.getHandler().readEvalUiObjects({
|
|
1525
1525
|
model: r,
|
|
1526
1526
|
ids: u,
|
|
1527
1527
|
arch: o == null ? void 0 : o.arch,
|
|
@@ -1577,7 +1577,7 @@ const qn = async (e) => {
|
|
|
1577
1577
|
} = t, [s, a] = T(!0), [l, u] = T(), [d, f] = T(/* @__PURE__ */ new Map()), c = Y(Ee), {
|
|
1578
1578
|
getContext: m
|
|
1579
1579
|
} = c || {};
|
|
1580
|
-
|
|
1580
|
+
Ct(() => {
|
|
1581
1581
|
p();
|
|
1582
1582
|
}, [t]);
|
|
1583
1583
|
const v = async (h) => o && o[h] ? o[h] : await B.getHandler().getView({
|
|
@@ -1598,7 +1598,7 @@ const qn = async (e) => {
|
|
|
1598
1598
|
a(!1);
|
|
1599
1599
|
}
|
|
1600
1600
|
};
|
|
1601
|
-
return s ? /* @__PURE__ */ n(
|
|
1601
|
+
return s ? /* @__PURE__ */ n(Ae, {}) : l ? /* @__PURE__ */ n(ze, {
|
|
1602
1602
|
className: "mt-10",
|
|
1603
1603
|
message: l,
|
|
1604
1604
|
type: "error",
|
|
@@ -1628,7 +1628,7 @@ const qn = async (e) => {
|
|
|
1628
1628
|
} = i, _ = s.filter((w) => w.values), b = Y(Ee), {
|
|
1629
1629
|
getContext: A
|
|
1630
1630
|
} = b || {};
|
|
1631
|
-
|
|
1631
|
+
Ct(() => {
|
|
1632
1632
|
M();
|
|
1633
1633
|
}, [s]);
|
|
1634
1634
|
const I = (w) => {
|
|
@@ -1667,7 +1667,7 @@ const qn = async (e) => {
|
|
|
1667
1667
|
message: u,
|
|
1668
1668
|
type: "error",
|
|
1669
1669
|
banner: !0
|
|
1670
|
-
}) : a ? /* @__PURE__ */ n(
|
|
1670
|
+
}) : a ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ H(Z, {
|
|
1671
1671
|
children: [/* @__PURE__ */ n(er, {
|
|
1672
1672
|
style: {
|
|
1673
1673
|
padding: "1rem"
|
|
@@ -1739,7 +1739,7 @@ const qn = async (e) => {
|
|
|
1739
1739
|
} = Ca(), {
|
|
1740
1740
|
ooui: r,
|
|
1741
1741
|
value: i
|
|
1742
|
-
} = e, o = /* @__PURE__ */ H(
|
|
1742
|
+
} = e, o = /* @__PURE__ */ H(Z, {
|
|
1743
1743
|
children: [/* @__PURE__ */ H("span", {
|
|
1744
1744
|
children: [r.label, " "]
|
|
1745
1745
|
}), r.tooltip && /* @__PURE__ */ n(ht, {
|
|
@@ -1777,7 +1777,7 @@ const qn = async (e) => {
|
|
|
1777
1777
|
} else
|
|
1778
1778
|
r[i] = e[i];
|
|
1779
1779
|
}), r;
|
|
1780
|
-
},
|
|
1780
|
+
}, Ft = (e, t) => Fa(e, t), xn = ({
|
|
1781
1781
|
source: e,
|
|
1782
1782
|
target: t,
|
|
1783
1783
|
fields: r
|
|
@@ -1872,7 +1872,7 @@ const qn = async (e) => {
|
|
|
1872
1872
|
function pr(e, t, r) {
|
|
1873
1873
|
return r.indexOf(e) === t;
|
|
1874
1874
|
}
|
|
1875
|
-
const
|
|
1875
|
+
const Rt = ({
|
|
1876
1876
|
values: e,
|
|
1877
1877
|
fields: t
|
|
1878
1878
|
}) => {
|
|
@@ -1917,7 +1917,7 @@ const kt = ({
|
|
|
1917
1917
|
} = r, g = Y(Ee), {
|
|
1918
1918
|
getContext: y
|
|
1919
1919
|
} = g || {};
|
|
1920
|
-
|
|
1920
|
+
Ct(() => {
|
|
1921
1921
|
_();
|
|
1922
1922
|
}, [o]);
|
|
1923
1923
|
const O = (I) => {
|
|
@@ -1932,7 +1932,7 @@ const kt = ({
|
|
|
1932
1932
|
if (p && (I = [["id", "in", s]]), r.domain) {
|
|
1933
1933
|
const x = await B.getHandler().evalDomain({
|
|
1934
1934
|
domain: r.domain,
|
|
1935
|
-
values:
|
|
1935
|
+
values: Rt({
|
|
1936
1936
|
fields: g == null ? void 0 : g.getFields(),
|
|
1937
1937
|
values: g.getPlainValues()
|
|
1938
1938
|
}),
|
|
@@ -2002,10 +2002,10 @@ const kt = ({
|
|
|
2002
2002
|
message: u,
|
|
2003
2003
|
type: "error",
|
|
2004
2004
|
banner: !0
|
|
2005
|
-
}) : /* @__PURE__ */ n(
|
|
2005
|
+
}) : /* @__PURE__ */ n(Z, {
|
|
2006
2006
|
children: /* @__PURE__ */ n("div", {
|
|
2007
2007
|
className: "flex flex-row",
|
|
2008
|
-
children: /* @__PURE__ */ n(
|
|
2008
|
+
children: /* @__PURE__ */ n(xt, {
|
|
2009
2009
|
mode: "multiple",
|
|
2010
2010
|
value: a.length ? s : [],
|
|
2011
2011
|
tagRender: A,
|
|
@@ -2126,14 +2126,14 @@ const kt = ({
|
|
|
2126
2126
|
if (i.push(a), s(l)) {
|
|
2127
2127
|
const u = r - o;
|
|
2128
2128
|
for (let d = 0; d < u; d += 1)
|
|
2129
|
-
i.push(new
|
|
2129
|
+
i.push(new Vt({ string: "" }));
|
|
2130
2130
|
}
|
|
2131
2131
|
}), i;
|
|
2132
2132
|
}, $a = ({
|
|
2133
2133
|
row: e,
|
|
2134
2134
|
numberOfColumns: t
|
|
2135
2135
|
}) => e.map((r) => (r._mustExpand && (r.colspan = t), r)), La = (e, t) => {
|
|
2136
|
-
const r = e.map((i) => i instanceof
|
|
2136
|
+
const r = e.map((i) => i instanceof Vt && i.fieldForLabel || i instanceof oi ? "auto" : "1fr");
|
|
2137
2137
|
if (r.length < t) {
|
|
2138
2138
|
const i = t - r.length;
|
|
2139
2139
|
for (let o = 0; o < i; o++)
|
|
@@ -2169,7 +2169,7 @@ const kt = ({
|
|
|
2169
2169
|
row: p,
|
|
2170
2170
|
numberOfColumns: o,
|
|
2171
2171
|
mustFillWithEmpties: r
|
|
2172
|
-
}), l = l.concat(h)), h.map((g) => (g instanceof
|
|
2172
|
+
}), l = l.concat(h)), h.map((g) => (g instanceof Vt && g.fieldForLabel && (a = !0), /* @__PURE__ */ n("div", {
|
|
2173
2173
|
style: {
|
|
2174
2174
|
...Ma({
|
|
2175
2175
|
item: g,
|
|
@@ -2336,9 +2336,9 @@ const kt = ({
|
|
|
2336
2336
|
setLimit: A,
|
|
2337
2337
|
searchParams: I = [],
|
|
2338
2338
|
setSearchValues: M
|
|
2339
|
-
} = e, [w, x] = T(!1), [F, C] = T(!1), [L, S] = T(), [R, V] = T(1), [E, D] = T(0), [k, N] = T(), [j, W] = T([]), [K, z] = T(void 0), q = me(b || Pt), $ = me([]), P =
|
|
2339
|
+
} = e, [w, x] = T(!1), [F, C] = T(!1), [L, S] = T(), [R, V] = T(1), [E, D] = T(0), [k, N] = T(), [j, W] = T([]), [K, z] = T(void 0), q = me(b || Pt), $ = me([]), P = Me((oe) => {
|
|
2340
2340
|
g == null || g([...oe]), W([...oe]);
|
|
2341
|
-
}, []), Q =
|
|
2341
|
+
}, []), Q = Me(() => y || j, [y, j]), ie = Me(async () => {
|
|
2342
2342
|
const oe = await B.getHandler().nameSearch({
|
|
2343
2343
|
model: t,
|
|
2344
2344
|
payload: l,
|
|
@@ -2347,7 +2347,7 @@ const kt = ({
|
|
|
2347
2347
|
context: d
|
|
2348
2348
|
});
|
|
2349
2349
|
if (N(oe.length), f == null || f(oe.length), oe.length > 0) {
|
|
2350
|
-
const Te = oe.map((Be) => Be == null ? void 0 : Be[0]), { colors: be } =
|
|
2350
|
+
const Te = oe.map((Be) => Be == null ? void 0 : Be[0]), { colors: be } = Ot(c), Fe = await B.getHandler().readEvalUiObjects({
|
|
2351
2351
|
model: t,
|
|
2352
2352
|
ids: Te,
|
|
2353
2353
|
arch: c == null ? void 0 : c.arch,
|
|
@@ -2358,7 +2358,7 @@ const kt = ({
|
|
|
2358
2358
|
}
|
|
2359
2359
|
}), He = Fe[0];
|
|
2360
2360
|
$.current = [...He], z(Xt(Fe[1]));
|
|
2361
|
-
const Ne = He.map((Be) => Be.id), Je = v !== void 0 ?
|
|
2361
|
+
const Ne = He.map((Be) => Be.id), Je = v !== void 0 ? _t({
|
|
2362
2362
|
resultsToSort: He,
|
|
2363
2363
|
sorter: v,
|
|
2364
2364
|
fields: { ...c.fields, ...m.fields }
|
|
@@ -2379,9 +2379,9 @@ const kt = ({
|
|
|
2379
2379
|
v,
|
|
2380
2380
|
h,
|
|
2381
2381
|
f
|
|
2382
|
-
]), se =
|
|
2382
|
+
]), se = Me(
|
|
2383
2383
|
async (oe) => {
|
|
2384
|
-
const { params: Te, newOffset: be } = oe || {}, Fe = fn(Te || I, O), { colors: He } =
|
|
2384
|
+
const { params: Te, newOffset: be } = oe || {}, Fe = fn(Te || I, O), { colors: He } = Ot(c), { totalItems: Ne, results: Je, attrsEvaluated: Be } = await B.getHandler().searchForTree({
|
|
2385
2385
|
params: Fe,
|
|
2386
2386
|
limit: q.current,
|
|
2387
2387
|
offset: be || E,
|
|
@@ -2391,7 +2391,7 @@ const kt = ({
|
|
|
2391
2391
|
attrs: He && { colors: He }
|
|
2392
2392
|
});
|
|
2393
2393
|
z(Xt(Be)), $.current = [...Je];
|
|
2394
|
-
const te = v !== void 0 ?
|
|
2394
|
+
const te = v !== void 0 ? _t({
|
|
2395
2395
|
resultsToSort: Je,
|
|
2396
2396
|
sorter: v,
|
|
2397
2397
|
fields: { ...c.fields, ...m.fields }
|
|
@@ -2423,7 +2423,7 @@ const kt = ({
|
|
|
2423
2423
|
E,
|
|
2424
2424
|
I
|
|
2425
2425
|
]
|
|
2426
|
-
), ee =
|
|
2426
|
+
), ee = Me(
|
|
2427
2427
|
async (oe) => {
|
|
2428
2428
|
try {
|
|
2429
2429
|
x(!0), a == null || a(!0), l && !u.current ? await ie() : await se(oe);
|
|
@@ -2454,10 +2454,12 @@ const kt = ({
|
|
|
2454
2454
|
v,
|
|
2455
2455
|
c
|
|
2456
2456
|
]
|
|
2457
|
-
), J =
|
|
2457
|
+
), J = Me(
|
|
2458
2458
|
(oe) => {
|
|
2459
|
+
if (JSON.stringify(oe) === JSON.stringify(v))
|
|
2460
|
+
return;
|
|
2459
2461
|
p == null || p(oe);
|
|
2460
|
-
const Te = oe !== void 0 ?
|
|
2462
|
+
const Te = oe !== void 0 ? _t({
|
|
2461
2463
|
resultsToSort: Q(),
|
|
2462
2464
|
sorter: oe,
|
|
2463
2465
|
fields: { ...c.fields, ...m.fields }
|
|
@@ -2465,7 +2467,7 @@ const kt = ({
|
|
|
2465
2467
|
P(Te);
|
|
2466
2468
|
},
|
|
2467
2469
|
[p, Q, c, m, P]
|
|
2468
|
-
), pe =
|
|
2470
|
+
), pe = Me(
|
|
2469
2471
|
(oe) => {
|
|
2470
2472
|
const { params: Te, searchValues: be, limit: Fe, offset: He } = oe;
|
|
2471
2473
|
w || (r == null || r(void 0), i == null || i([]), M == null || M(be), o == null || o(Te), s == null || s(!1), C(!0), S(void 0), V(1), Fe && (q.current = Fe, A == null || A(Fe)), He && D(He), ee({
|
|
@@ -2486,12 +2488,12 @@ const kt = ({
|
|
|
2486
2488
|
D,
|
|
2487
2489
|
ee
|
|
2488
2490
|
]
|
|
2489
|
-
), ye =
|
|
2491
|
+
), ye = Me(
|
|
2490
2492
|
(oe) => {
|
|
2491
2493
|
x(!0), V(oe), D((oe - 1) * b);
|
|
2492
2494
|
},
|
|
2493
2495
|
[x, b, D, V]
|
|
2494
|
-
),
|
|
2496
|
+
), ke = Me(() => {
|
|
2495
2497
|
w || (r == null || r(void 0), o == null || o([]), M == null || M({}), S(void 0), D(0), V(1), A == null || A(b || Pt));
|
|
2496
2498
|
}, [
|
|
2497
2499
|
w,
|
|
@@ -2502,7 +2504,7 @@ const kt = ({
|
|
|
2502
2504
|
V,
|
|
2503
2505
|
A,
|
|
2504
2506
|
b
|
|
2505
|
-
]), de =
|
|
2507
|
+
]), de = Me(
|
|
2506
2508
|
async (oe) => {
|
|
2507
2509
|
const Te = oe[(c == null ? void 0 : c.field_parent) || "child_id"], be = await B.getHandler().readObjects({
|
|
2508
2510
|
model: t,
|
|
@@ -2510,13 +2512,13 @@ const kt = ({
|
|
|
2510
2512
|
fields: c.field_parent ? { ...c.fields, [c.field_parent]: {} } : c.fields,
|
|
2511
2513
|
context: d
|
|
2512
2514
|
});
|
|
2513
|
-
return P([...Q(), ...be]), io(
|
|
2515
|
+
return P([...Q(), ...be]), io(Ot(c), be);
|
|
2514
2516
|
},
|
|
2515
2517
|
[c, t, d, Q, P]
|
|
2516
2518
|
);
|
|
2517
2519
|
return {
|
|
2518
2520
|
submit: pe,
|
|
2519
|
-
clear:
|
|
2521
|
+
clear: ke,
|
|
2520
2522
|
fetchResults: ee,
|
|
2521
2523
|
tableRefreshing: w,
|
|
2522
2524
|
searchFilterLoading: F,
|
|
@@ -2558,7 +2560,7 @@ const kt = ({
|
|
|
2558
2560
|
setSearchTreeNameSearch: M,
|
|
2559
2561
|
goToResourceId: w,
|
|
2560
2562
|
limit: x
|
|
2561
|
-
} = e, [F, C] = T(!1), [L, S] = T(!1), [R, V] = T(!1), [E, D] = T(!0), [k, N] = T(!0), [j, W] = T([]), [K, z] = T(!1), [q, $] = T([]), [P, Q] = T(!1), [ie, se] = T(!0), [ee, J] = T(), [pe, ye] = T({}), [
|
|
2563
|
+
} = e, [F, C] = T(!1), [L, S] = T(!1), [R, V] = T(!1), [E, D] = T(!0), [k, N] = T(!0), [j, W] = T([]), [K, z] = T(!1), [q, $] = T([]), [P, Q] = T(!1), [ie, se] = T(!0), [ee, J] = T(), [pe, ye] = T({}), [ke, de] = T(x !== void 0 ? x : Pt), [oe, Te] = T(i);
|
|
2562
2564
|
ge(() => {
|
|
2563
2565
|
m && m.length > 0 && !v && (p == null || p(0), f == null || f(m[0].id));
|
|
2564
2566
|
}, [m]), ge(() => {
|
|
@@ -2622,7 +2624,7 @@ const kt = ({
|
|
|
2622
2624
|
goToResourceId: w,
|
|
2623
2625
|
searchValues: pe,
|
|
2624
2626
|
setSearchValues: ye,
|
|
2625
|
-
limit:
|
|
2627
|
+
limit: ke,
|
|
2626
2628
|
setLimit: de,
|
|
2627
2629
|
setTitle: Te
|
|
2628
2630
|
},
|
|
@@ -2657,7 +2659,7 @@ const kt = ({
|
|
|
2657
2659
|
},
|
|
2658
2660
|
children: t
|
|
2659
2661
|
});
|
|
2660
|
-
},
|
|
2662
|
+
}, Mt = qe.createContext(null), vr = async (e) => {
|
|
2661
2663
|
var t;
|
|
2662
2664
|
for (let r = 0; r < e.length; r++)
|
|
2663
2665
|
await ((t = e == null ? void 0 : e[r]) == null ? void 0 : t.call(e));
|
|
@@ -2670,7 +2672,7 @@ const kt = ({
|
|
|
2670
2672
|
} = u || {}, f = me([]), {
|
|
2671
2673
|
t: c
|
|
2672
2674
|
} = Y(we);
|
|
2673
|
-
|
|
2675
|
+
bt(t, () => ({
|
|
2674
2676
|
openActionModal: b
|
|
2675
2677
|
}));
|
|
2676
2678
|
const [m, v] = T(!1), [p, h] = T({
|
|
@@ -2697,7 +2699,7 @@ const kt = ({
|
|
|
2697
2699
|
ids: D
|
|
2698
2700
|
} = R || {};
|
|
2699
2701
|
let k = D || [];
|
|
2700
|
-
const N = typeof L == "string" ?
|
|
2702
|
+
const N = typeof L == "string" ? vt({
|
|
2701
2703
|
context: L,
|
|
2702
2704
|
fields: x,
|
|
2703
2705
|
values: F
|
|
@@ -2727,7 +2729,7 @@ const kt = ({
|
|
|
2727
2729
|
id: M
|
|
2728
2730
|
}), w.state && s.current === !0) {
|
|
2729
2731
|
s.current = !1, clearInterval(o.current), l(!1);
|
|
2730
|
-
const x = await
|
|
2732
|
+
const x = await Dt(w.result);
|
|
2731
2733
|
un(w.result, x.mime);
|
|
2732
2734
|
}
|
|
2733
2735
|
} catch (x) {
|
|
@@ -2770,7 +2772,7 @@ const kt = ({
|
|
|
2770
2772
|
context: F
|
|
2771
2773
|
}))[0]);
|
|
2772
2774
|
const S = {
|
|
2773
|
-
...typeof (C == null ? void 0 : C.context) == "string" ?
|
|
2775
|
+
...typeof (C == null ? void 0 : C.context) == "string" ? vt({
|
|
2774
2776
|
context: C.context,
|
|
2775
2777
|
fields: w,
|
|
2776
2778
|
values: {
|
|
@@ -2783,7 +2785,7 @@ const kt = ({
|
|
|
2783
2785
|
let R = [];
|
|
2784
2786
|
if (C.domain && (R = await B.getHandler().evalDomain({
|
|
2785
2787
|
domain: C.domain,
|
|
2786
|
-
values:
|
|
2788
|
+
values: Rt({
|
|
2787
2789
|
fields: w,
|
|
2788
2790
|
values: {
|
|
2789
2791
|
...x,
|
|
@@ -2881,13 +2883,13 @@ const kt = ({
|
|
|
2881
2883
|
actionData: void 0
|
|
2882
2884
|
});
|
|
2883
2885
|
}
|
|
2884
|
-
return /* @__PURE__ */ n(
|
|
2885
|
-
children: /* @__PURE__ */ n(
|
|
2886
|
+
return /* @__PURE__ */ n(Z, {
|
|
2887
|
+
children: /* @__PURE__ */ n(Mt.Provider, {
|
|
2886
2888
|
value: {
|
|
2887
2889
|
processAction: O,
|
|
2888
2890
|
globalValues: i
|
|
2889
2891
|
},
|
|
2890
|
-
children: /* @__PURE__ */ H(
|
|
2892
|
+
children: /* @__PURE__ */ H(Z, {
|
|
2891
2893
|
children: [r, /* @__PURE__ */ n(We, {
|
|
2892
2894
|
title: c("generatingReport"),
|
|
2893
2895
|
open: a,
|
|
@@ -2895,7 +2897,7 @@ const kt = ({
|
|
|
2895
2897
|
closable: !1,
|
|
2896
2898
|
centered: !0,
|
|
2897
2899
|
maskClosable: !1,
|
|
2898
|
-
children: /* @__PURE__ */ n(
|
|
2900
|
+
children: /* @__PURE__ */ n(Ae, {})
|
|
2899
2901
|
}), /* @__PURE__ */ n(Ut, {
|
|
2900
2902
|
buttonModal: !0,
|
|
2901
2903
|
parentContext: p.context,
|
|
@@ -2974,7 +2976,7 @@ async function nl({
|
|
|
2974
2976
|
initialView: a
|
|
2975
2977
|
};
|
|
2976
2978
|
}
|
|
2977
|
-
const rl =
|
|
2979
|
+
const rl = wt(tl), ol = ({
|
|
2978
2980
|
error: e,
|
|
2979
2981
|
className: t
|
|
2980
2982
|
}) => {
|
|
@@ -3028,7 +3030,7 @@ function sl(e, t) {
|
|
|
3028
3030
|
} = Y(we), [x, F] = T(!1), [C, L] = T(), [S, R] = T(), [V] = it.useForm(), [E, D] = T(), [k, N] = T(), j = Y(ao), [W, K] = T(), [z, q] = T(!1), $ = me(), P = me({}), Q = me({}), ie = me(!1), se = me(!1), ee = W < il, J = Y(Ee), {
|
|
3029
3031
|
activeId: pe,
|
|
3030
3032
|
getPlainValues: ye
|
|
3031
|
-
} = J || {},
|
|
3033
|
+
} = J || {}, ke = Y(Xe), {
|
|
3032
3034
|
setFormIsSaving: de = void 0,
|
|
3033
3035
|
setFormHasChanges: oe = void 0,
|
|
3034
3036
|
setCurrentId: Te = void 0,
|
|
@@ -3036,14 +3038,14 @@ function sl(e, t) {
|
|
|
3036
3038
|
setAttachments: Fe = void 0,
|
|
3037
3039
|
title: He = void 0,
|
|
3038
3040
|
setTitle: Ne = void 0
|
|
3039
|
-
} = (b ?
|
|
3041
|
+
} = (b ? ke : {}) || {}, Je = Y(Mt), {
|
|
3040
3042
|
processAction: Be,
|
|
3041
3043
|
globalValues: te
|
|
3042
3044
|
} = Je || {};
|
|
3043
|
-
|
|
3045
|
+
bt(t, () => ({
|
|
3044
3046
|
submitForm: qt,
|
|
3045
3047
|
getFields: De,
|
|
3046
|
-
getValues:
|
|
3048
|
+
getValues: Re,
|
|
3047
3049
|
getPlainValues: tt,
|
|
3048
3050
|
getContext: nt,
|
|
3049
3051
|
fetchValues: ot,
|
|
@@ -3077,17 +3079,17 @@ function sl(e, t) {
|
|
|
3077
3079
|
function De() {
|
|
3078
3080
|
return k;
|
|
3079
3081
|
}
|
|
3080
|
-
function
|
|
3082
|
+
function Re() {
|
|
3081
3083
|
const G = {
|
|
3082
3084
|
...ae(k),
|
|
3083
|
-
...
|
|
3085
|
+
...X()
|
|
3084
3086
|
};
|
|
3085
3087
|
for (const U in G)
|
|
3086
3088
|
G[U] === void 0 && delete G[U];
|
|
3087
3089
|
return G;
|
|
3088
3090
|
}
|
|
3089
3091
|
function tt() {
|
|
3090
|
-
const G =
|
|
3092
|
+
const G = Re(), U = De();
|
|
3091
3093
|
let ne = {};
|
|
3092
3094
|
return Object.keys(G).forEach((re) => {
|
|
3093
3095
|
const Ve = G[re];
|
|
@@ -3108,7 +3110,7 @@ function sl(e, t) {
|
|
|
3108
3110
|
...S == null ? void 0 : S.context
|
|
3109
3111
|
};
|
|
3110
3112
|
}
|
|
3111
|
-
function
|
|
3113
|
+
function X() {
|
|
3112
3114
|
return {
|
|
3113
3115
|
id: le(),
|
|
3114
3116
|
active_id: le(),
|
|
@@ -3134,11 +3136,11 @@ function sl(e, t) {
|
|
|
3134
3136
|
fields: k
|
|
3135
3137
|
})).length !== 0, ae = (G) => {
|
|
3136
3138
|
const U = V.getFieldsValue(!0);
|
|
3137
|
-
return
|
|
3139
|
+
return Ft(U, G);
|
|
3138
3140
|
}, Ce = (G, U) => {
|
|
3139
3141
|
Gt({
|
|
3140
3142
|
values: {
|
|
3141
|
-
...
|
|
3143
|
+
...Ft(V.getFieldsValue(!0), k),
|
|
3142
3144
|
[G]: U
|
|
3143
3145
|
},
|
|
3144
3146
|
fields: k,
|
|
@@ -3182,7 +3184,7 @@ function sl(e, t) {
|
|
|
3182
3184
|
}), O && (U = {
|
|
3183
3185
|
...Ia(O),
|
|
3184
3186
|
...U
|
|
3185
|
-
}), P.current =
|
|
3187
|
+
}), P.current = Ft(U, ne), Gt({
|
|
3186
3188
|
values: U,
|
|
3187
3189
|
fields: ne,
|
|
3188
3190
|
reset: !0,
|
|
@@ -3224,7 +3226,7 @@ function sl(e, t) {
|
|
|
3224
3226
|
const gt = {
|
|
3225
3227
|
...ne ? {} : V.getFieldsValue(!0),
|
|
3226
3228
|
...G
|
|
3227
|
-
}, yn =
|
|
3229
|
+
}, yn = Ft(gt, U), Uo = Object.keys(U).map((vn) => {
|
|
3228
3230
|
const Go = yn[vn] !== void 0 ? yn[vn] : void 0;
|
|
3229
3231
|
return {
|
|
3230
3232
|
name: vn,
|
|
@@ -3296,12 +3298,12 @@ function sl(e, t) {
|
|
|
3296
3298
|
});
|
|
3297
3299
|
$.current = re, P.current = ne;
|
|
3298
3300
|
}
|
|
3299
|
-
h && await h([le()]), !g && U && (ue == null || ue(le(),
|
|
3301
|
+
h && await h([le()]), !g && U && (ue == null || ue(le(), Re(), Ze()));
|
|
3300
3302
|
}, Eo = async (G) => {
|
|
3301
3303
|
const {
|
|
3302
3304
|
callOnSubmitSucceed: U = !0
|
|
3303
3305
|
} = G || {};
|
|
3304
|
-
!g && U && (ue == null || ue(le(),
|
|
3306
|
+
!g && U && (ue == null || ue(le(), Re(), Ze()));
|
|
3305
3307
|
}, qt = async (G) => {
|
|
3306
3308
|
let U = !1;
|
|
3307
3309
|
const {
|
|
@@ -3344,7 +3346,7 @@ function sl(e, t) {
|
|
|
3344
3346
|
readOnly: f,
|
|
3345
3347
|
values: wa({
|
|
3346
3348
|
...ne,
|
|
3347
|
-
...
|
|
3349
|
+
...X()
|
|
3348
3350
|
}, G)
|
|
3349
3351
|
}), R(re), re.string && re.string !== He && (Ne == null || Ne(re.string)), j && re.string && ((Ve = j.setTitle) == null || Ve.call(j, re.string));
|
|
3350
3352
|
}, gn = async ({
|
|
@@ -3365,7 +3367,7 @@ function sl(e, t) {
|
|
|
3365
3367
|
}) && G !== !0)
|
|
3366
3368
|
return;
|
|
3367
3369
|
{
|
|
3368
|
-
const re =
|
|
3370
|
+
const re = Ft(V.getFieldsValue(!0), k);
|
|
3369
3371
|
Q.current = re, u == null || u(re), oe == null || oe(!0), Lo(ne);
|
|
3370
3372
|
}
|
|
3371
3373
|
}
|
|
@@ -3456,15 +3458,15 @@ function sl(e, t) {
|
|
|
3456
3458
|
}
|
|
3457
3459
|
});
|
|
3458
3460
|
if (typeof ne == "object" && ne !== null && Object.keys(ne).length === 0 && g)
|
|
3459
|
-
ue == null || ue(le(),
|
|
3461
|
+
ue == null || ue(le(), Re(), Ze());
|
|
3460
3462
|
else if (ne.type && ne.type === "ir.actions.act_window_close")
|
|
3461
|
-
ue == null || ue(le(),
|
|
3463
|
+
ue == null || ue(le(), Re(), Ze());
|
|
3462
3464
|
else if (ne.type) {
|
|
3463
3465
|
let re = {};
|
|
3464
|
-
ne.context && (re =
|
|
3466
|
+
ne.context && (re = vt({
|
|
3465
3467
|
context: ne.context,
|
|
3466
3468
|
fields: k,
|
|
3467
|
-
values:
|
|
3469
|
+
values: Re()
|
|
3468
3470
|
})), await Qn({
|
|
3469
3471
|
actionData: ne,
|
|
3470
3472
|
context: {
|
|
@@ -3483,7 +3485,7 @@ function sl(e, t) {
|
|
|
3483
3485
|
action: G,
|
|
3484
3486
|
payload: le()
|
|
3485
3487
|
});
|
|
3486
|
-
U.type && U.type === "ir.actions.act_window_close" ? ue == null || ue(le(),
|
|
3488
|
+
U.type && U.type === "ir.actions.act_window_close" ? ue == null || ue(le(), Re(), Ze()) : await ot();
|
|
3487
3489
|
}
|
|
3488
3490
|
async function Bo({
|
|
3489
3491
|
action: G,
|
|
@@ -3508,7 +3510,7 @@ function sl(e, t) {
|
|
|
3508
3510
|
} = await (Be == null ? void 0 : Be({
|
|
3509
3511
|
actionData: G,
|
|
3510
3512
|
fields: k,
|
|
3511
|
-
values:
|
|
3513
|
+
values: Re(),
|
|
3512
3514
|
context: {
|
|
3513
3515
|
...y,
|
|
3514
3516
|
...S == null ? void 0 : S.context,
|
|
@@ -3518,7 +3520,7 @@ function sl(e, t) {
|
|
|
3518
3520
|
ot();
|
|
3519
3521
|
}
|
|
3520
3522
|
})) || {};
|
|
3521
|
-
!b && ne && (ue == null || ue(le(),
|
|
3523
|
+
!b && ne && (ue == null || ue(le(), Re(), Ze()));
|
|
3522
3524
|
}
|
|
3523
3525
|
function jo() {
|
|
3524
3526
|
gn({
|
|
@@ -3554,9 +3556,9 @@ function sl(e, t) {
|
|
|
3554
3556
|
Ye(re);
|
|
3555
3557
|
}
|
|
3556
3558
|
}
|
|
3557
|
-
const Yo = () => !S && !C ? /* @__PURE__ */ n(
|
|
3559
|
+
const Yo = () => !S && !C ? /* @__PURE__ */ n(Ae, {}) : !r && !p || !_ ? null : /* @__PURE__ */ n(Z, {
|
|
3558
3560
|
children: /* @__PURE__ */ n(Gi, {
|
|
3559
|
-
getValues:
|
|
3561
|
+
getValues: Re,
|
|
3560
3562
|
getPlainValues: tt,
|
|
3561
3563
|
getFields: De,
|
|
3562
3564
|
domain: O,
|
|
@@ -3584,7 +3586,7 @@ function sl(e, t) {
|
|
|
3584
3586
|
})
|
|
3585
3587
|
})
|
|
3586
3588
|
})
|
|
3587
|
-
}), Wo = () => /* @__PURE__ */ H(
|
|
3589
|
+
}), Wo = () => /* @__PURE__ */ H(Z, {
|
|
3588
3590
|
children: [/* @__PURE__ */ n(sn, {}), /* @__PURE__ */ n(Se, {
|
|
3589
3591
|
justify: "end",
|
|
3590
3592
|
children: /* @__PURE__ */ H(je, {
|
|
@@ -3598,7 +3600,7 @@ function sl(e, t) {
|
|
|
3598
3600
|
}), /* @__PURE__ */ n(Ie, {
|
|
3599
3601
|
disabled: x || f,
|
|
3600
3602
|
loading: x,
|
|
3601
|
-
icon: /* @__PURE__ */ n(
|
|
3603
|
+
icon: /* @__PURE__ */ n(kt, {}),
|
|
3602
3604
|
onClick: async () => {
|
|
3603
3605
|
await qt();
|
|
3604
3606
|
},
|
|
@@ -3626,7 +3628,7 @@ function sl(e, t) {
|
|
|
3626
3628
|
})
|
|
3627
3629
|
}) : null;
|
|
3628
3630
|
}
|
|
3629
|
-
const Wt =
|
|
3631
|
+
const Wt = wt(sl), Ut = (e) => {
|
|
3630
3632
|
const {
|
|
3631
3633
|
visible: t,
|
|
3632
3634
|
id: r,
|
|
@@ -3742,9 +3744,9 @@ const Wt = vt(sl), Ut = (e) => {
|
|
|
3742
3744
|
name: o + "#time",
|
|
3743
3745
|
label: ""
|
|
3744
3746
|
})];
|
|
3745
|
-
return /* @__PURE__ */ H(
|
|
3747
|
+
return /* @__PURE__ */ H(Z, {
|
|
3746
3748
|
children: [r && /* @__PURE__ */ n(cn, {
|
|
3747
|
-
ooui: new
|
|
3749
|
+
ooui: new Vt({
|
|
3748
3750
|
name: o + "_label",
|
|
3749
3751
|
string: i,
|
|
3750
3752
|
help: t.tooltip,
|
|
@@ -3867,9 +3869,9 @@ function ul(e) {
|
|
|
3867
3869
|
},
|
|
3868
3870
|
layout: "vertical"
|
|
3869
3871
|
});
|
|
3870
|
-
return /* @__PURE__ */ H(
|
|
3872
|
+
return /* @__PURE__ */ H(Z, {
|
|
3871
3873
|
children: [r && /* @__PURE__ */ n(cn, {
|
|
3872
|
-
ooui: new
|
|
3874
|
+
ooui: new Vt({
|
|
3873
3875
|
name: i + "_label",
|
|
3874
3876
|
string: o,
|
|
3875
3877
|
help: s,
|
|
@@ -3899,7 +3901,7 @@ const {
|
|
|
3899
3901
|
defaultSeed: ml
|
|
3900
3902
|
} = $e, hl = fl(ml), {
|
|
3901
3903
|
Option: pl
|
|
3902
|
-
} =
|
|
3904
|
+
} = xt, gl = (e) => {
|
|
3903
3905
|
const {
|
|
3904
3906
|
ooui: t
|
|
3905
3907
|
} = e, {
|
|
@@ -3931,7 +3933,7 @@ const {
|
|
|
3931
3933
|
value: v,
|
|
3932
3934
|
children: v
|
|
3933
3935
|
}, m);
|
|
3934
|
-
}), d = a && !s ? vl :
|
|
3936
|
+
}), d = a && !s ? vl : xt;
|
|
3935
3937
|
function f(c) {
|
|
3936
3938
|
const m = c.map((v) => {
|
|
3937
3939
|
const p = l.find(([h, g]) => v === g);
|
|
@@ -3951,7 +3953,7 @@ const {
|
|
|
3951
3953
|
showArrow: !0,
|
|
3952
3954
|
children: u
|
|
3953
3955
|
});
|
|
3954
|
-
}, vl = jt(
|
|
3956
|
+
}, vl = jt(xt)`
|
|
3955
3957
|
&.ant-select:not(.ant-select-customize-input) .ant-select-selector {
|
|
3956
3958
|
background-color: ${hl.colorPrimaryBg};
|
|
3957
3959
|
}
|
|
@@ -4030,7 +4032,7 @@ function bl(e) {
|
|
|
4030
4032
|
onClick: t,
|
|
4031
4033
|
children: [r ? /* @__PURE__ */ n(ai, {
|
|
4032
4034
|
className: "pr-1"
|
|
4033
|
-
}) : /* @__PURE__ */ n(
|
|
4035
|
+
}) : /* @__PURE__ */ n(At, {
|
|
4034
4036
|
className: "pr-1"
|
|
4035
4037
|
}), s(r ? "simple_search" : "advanced_search")]
|
|
4036
4038
|
})
|
|
@@ -4123,7 +4125,7 @@ function uo(e) {
|
|
|
4123
4125
|
}, E))
|
|
4124
4126
|
}, R));
|
|
4125
4127
|
};
|
|
4126
|
-
|
|
4128
|
+
Ct(() => {
|
|
4127
4129
|
b(!1), A.current = new ii(r, t, p), A.current.parse(), g(A.current._simpleSearchContainer), O(A.current._advancedSearchContainer);
|
|
4128
4130
|
}, [t, r]);
|
|
4129
4131
|
const x = w(), F = (C) => {
|
|
@@ -4321,7 +4323,7 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4321
4323
|
t: p
|
|
4322
4324
|
} = Y(we), h = Y(at), {
|
|
4323
4325
|
openRelate: g
|
|
4324
|
-
} = h || {}, y = Y(
|
|
4326
|
+
} = h || {}, y = Y(Mt), {
|
|
4325
4327
|
processAction: O
|
|
4326
4328
|
} = y || {};
|
|
4327
4329
|
if (!t)
|
|
@@ -4345,7 +4347,7 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4345
4347
|
context: i
|
|
4346
4348
|
}))[0];
|
|
4347
4349
|
v({
|
|
4348
|
-
...
|
|
4350
|
+
...Ft(S, C),
|
|
4349
4351
|
active_id: t
|
|
4350
4352
|
}), d(!1);
|
|
4351
4353
|
} catch (F) {
|
|
@@ -4361,7 +4363,7 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4361
4363
|
style: {
|
|
4362
4364
|
padding: 15
|
|
4363
4365
|
},
|
|
4364
|
-
children: /* @__PURE__ */ n(
|
|
4366
|
+
children: /* @__PURE__ */ n(Ae, {})
|
|
4365
4367
|
})
|
|
4366
4368
|
});
|
|
4367
4369
|
if (!f || !f.toolbar)
|
|
@@ -4380,7 +4382,7 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4380
4382
|
icon: /* @__PURE__ */ n(jn, {}),
|
|
4381
4383
|
children: p("report")
|
|
4382
4384
|
}, "print"), /* @__PURE__ */ n(Le.Divider, {}), /* @__PURE__ */ n(Le.ItemGroup, {
|
|
4383
|
-
title: /* @__PURE__ */ H(
|
|
4385
|
+
title: /* @__PURE__ */ H(Z, {
|
|
4384
4386
|
children: [/* @__PURE__ */ n(Hr, {}), " ", /* @__PURE__ */ H("span", {
|
|
4385
4387
|
children: [" ", p("related")]
|
|
4386
4388
|
})]
|
|
@@ -4431,7 +4433,7 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4431
4433
|
fields: f.fields
|
|
4432
4434
|
});
|
|
4433
4435
|
}
|
|
4434
|
-
return /* @__PURE__ */ H(
|
|
4436
|
+
return /* @__PURE__ */ H(Z, {
|
|
4435
4437
|
children: [/* @__PURE__ */ n(Ht, {
|
|
4436
4438
|
overlay: b(),
|
|
4437
4439
|
trigger: ["click"],
|
|
@@ -4460,19 +4462,19 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4460
4462
|
m2oField: t
|
|
4461
4463
|
} = e;
|
|
4462
4464
|
return t ? /* @__PURE__ */ H(je, {
|
|
4463
|
-
children: [/* @__PURE__ */ n(
|
|
4465
|
+
children: [/* @__PURE__ */ n(Z, {
|
|
4464
4466
|
children: t.value
|
|
4465
4467
|
}), /* @__PURE__ */ n(Jn, {
|
|
4466
4468
|
id: t.id,
|
|
4467
4469
|
model: t.model
|
|
4468
4470
|
})]
|
|
4469
|
-
}) : /* @__PURE__ */ n(
|
|
4471
|
+
}) : /* @__PURE__ */ n(Z, {});
|
|
4470
4472
|
}, Il = (e) => {
|
|
4471
4473
|
const {
|
|
4472
4474
|
value: t,
|
|
4473
4475
|
context: r,
|
|
4474
4476
|
selectionValues: i
|
|
4475
|
-
} = e, [o, s] = T(), [a, l] = T(!1), [u, d] = t ? t.split(",") : [], f = parseInt(d), c =
|
|
4477
|
+
} = e, [o, s] = T(), [a, l] = T(!1), [u, d] = t ? t.split(",") : [], f = parseInt(d), c = Me(async () => {
|
|
4476
4478
|
if (!t || t && o)
|
|
4477
4479
|
return;
|
|
4478
4480
|
l(!0);
|
|
@@ -4487,14 +4489,14 @@ const Fl = (e) => /* @__PURE__ */ n(ve, {
|
|
|
4487
4489
|
if (ge(() => {
|
|
4488
4490
|
c();
|
|
4489
4491
|
}, [t]), !t && !a)
|
|
4490
|
-
return /* @__PURE__ */ n(
|
|
4492
|
+
return /* @__PURE__ */ n(Z, {});
|
|
4491
4493
|
if (a)
|
|
4492
4494
|
return /* @__PURE__ */ n(et, {});
|
|
4493
4495
|
const m = i.get(u);
|
|
4494
4496
|
return /* @__PURE__ */ H(je, {
|
|
4495
|
-
children: [/* @__PURE__ */ n(
|
|
4497
|
+
children: [/* @__PURE__ */ n(Z, {
|
|
4496
4498
|
children: `${m}:`
|
|
4497
|
-
}), /* @__PURE__ */ n(
|
|
4499
|
+
}), /* @__PURE__ */ n(Z, {
|
|
4498
4500
|
children: o
|
|
4499
4501
|
}), /* @__PURE__ */ n(Jn, {
|
|
4500
4502
|
id: f,
|
|
@@ -4907,26 +4909,26 @@ const lt = {
|
|
|
4907
4909
|
content: e == null ? void 0 : e.replace(/(?:\r\n|\r|\n)/g, "<br>")
|
|
4908
4910
|
}), Ll = (e) => {
|
|
4909
4911
|
if (!e || e && e.length === 0)
|
|
4910
|
-
return /* @__PURE__ */ n(
|
|
4912
|
+
return /* @__PURE__ */ n(Z, {});
|
|
4911
4913
|
const t = dt(e, lt.date.dateInternalFormat).format(lt.date.dateDisplayFormat);
|
|
4912
|
-
return /* @__PURE__ */ n(
|
|
4914
|
+
return /* @__PURE__ */ n(Z, {
|
|
4913
4915
|
children: t
|
|
4914
4916
|
});
|
|
4915
4917
|
}, Nl = (e) => {
|
|
4916
4918
|
if (!e || e && e.length === 0)
|
|
4917
|
-
return /* @__PURE__ */ n(
|
|
4919
|
+
return /* @__PURE__ */ n(Z, {});
|
|
4918
4920
|
const t = dt(e, lt.time.dateInternalFormat).format(lt.time.dateDisplayFormat);
|
|
4919
|
-
return /* @__PURE__ */ n(
|
|
4921
|
+
return /* @__PURE__ */ n(Z, {
|
|
4920
4922
|
children: t
|
|
4921
4923
|
});
|
|
4922
4924
|
}, xr = (e) => {
|
|
4923
4925
|
const t = Array.isArray(e == null ? void 0 : e.items) ? e == null ? void 0 : e.items.length : 0;
|
|
4924
|
-
return /* @__PURE__ */ n(
|
|
4926
|
+
return /* @__PURE__ */ n(Z, {
|
|
4925
4927
|
children: `( ${t} )`
|
|
4926
4928
|
});
|
|
4927
4929
|
}, Pl = (e) => /* @__PURE__ */ n(mo, {
|
|
4928
4930
|
value: e
|
|
4929
|
-
}), Hl = (e) => /* @__PURE__ */ n(
|
|
4931
|
+
}), Hl = (e) => /* @__PURE__ */ n(Z, {
|
|
4930
4932
|
children: fo(e)
|
|
4931
4933
|
}), Cr = (e) => /* @__PURE__ */ n("div", {
|
|
4932
4934
|
style: {
|
|
@@ -4939,14 +4941,14 @@ const lt = {
|
|
|
4939
4941
|
maxWidth: "50px",
|
|
4940
4942
|
padding: "5px"
|
|
4941
4943
|
}
|
|
4942
|
-
}), jl = (e, t, r, i) => /* @__PURE__ */ n(
|
|
4944
|
+
}), jl = (e, t, r, i) => /* @__PURE__ */ n(Z, {
|
|
4943
4945
|
children: e ? /* @__PURE__ */ n(kn, {
|
|
4944
4946
|
color: r.colors[e],
|
|
4945
4947
|
children: r.selectionValues.get(e)
|
|
4946
4948
|
}) : null
|
|
4947
|
-
}), Kl = (e, t, r, i) => /* @__PURE__ */ n(
|
|
4949
|
+
}), Kl = (e, t, r, i) => /* @__PURE__ */ n(Z, {
|
|
4948
4950
|
children: r.selectionValues.get(e)
|
|
4949
|
-
}), Yl = (e, t, r, i) => /* @__PURE__ */ n(
|
|
4951
|
+
}), Yl = (e, t, r, i) => /* @__PURE__ */ n(Z, {
|
|
4950
4952
|
children: /* @__PURE__ */ n(Il, {
|
|
4951
4953
|
value: e,
|
|
4952
4954
|
selectionValues: r.selectionValues,
|
|
@@ -4983,7 +4985,7 @@ function mn(e) {
|
|
|
4983
4985
|
setTitle: S = void 0
|
|
4984
4986
|
} = (y ? C : {}) || {};
|
|
4985
4987
|
ge(() => {
|
|
4986
|
-
w.current =
|
|
4988
|
+
w.current = Ot(o);
|
|
4987
4989
|
const W = ya(w.current, {
|
|
4988
4990
|
boolean: Ml,
|
|
4989
4991
|
many2one: El,
|
|
@@ -5008,7 +5010,7 @@ function mn(e) {
|
|
|
5008
5010
|
const W = io(w.current, s);
|
|
5009
5011
|
b(W), F.current = r;
|
|
5010
5012
|
}, [s]);
|
|
5011
|
-
const R = (t - 1) * F.current + 1, V = R - 1 + _.length, E = i === void 0 ? null : i === 0 ? x("no_results") : x("summary").replace("{from}", R == null ? void 0 : R.toString()).replace("{to}", V == null ? void 0 : V.toString()).replace("{total}", i == null ? void 0 : i.toString()), D = () => !d || o.isExpandable || l ? null : i === void 0 ? /* @__PURE__ */ n(
|
|
5013
|
+
const R = (t - 1) * F.current + 1, V = R - 1 + _.length, E = i === void 0 ? null : i === 0 ? x("no_results") : x("summary").replace("{from}", R == null ? void 0 : R.toString()).replace("{to}", V == null ? void 0 : V.toString()).replace("{total}", i == null ? void 0 : i.toString()), D = () => !d || o.isExpandable || l ? null : i === void 0 ? /* @__PURE__ */ n(Ae, {
|
|
5012
5014
|
className: "pb-4"
|
|
5013
5015
|
}) : /* @__PURE__ */ H(Se, {
|
|
5014
5016
|
align: "bottom",
|
|
@@ -5051,17 +5053,19 @@ function mn(e) {
|
|
|
5051
5053
|
const K = w.current;
|
|
5052
5054
|
c && K.columns.some((z) => z.sum !== void 0) && (j = c - 30);
|
|
5053
5055
|
}
|
|
5054
|
-
return w.current === null ? /* @__PURE__ */ n(
|
|
5056
|
+
return w.current === null ? /* @__PURE__ */ n(Ae, {
|
|
5055
5057
|
style: {
|
|
5056
5058
|
padding: "2rem"
|
|
5057
5059
|
}
|
|
5058
5060
|
}) : /* @__PURE__ */ H("div", {
|
|
5059
|
-
children: [D(), /* @__PURE__ */ n(
|
|
5061
|
+
children: [D(), l && /* @__PURE__ */ n(Ae, {
|
|
5062
|
+
className: "pb-4"
|
|
5063
|
+
}), /* @__PURE__ */ n(Fi, {
|
|
5060
5064
|
height: j,
|
|
5061
5065
|
columns: N.columns,
|
|
5062
5066
|
dataSource: _,
|
|
5063
|
-
loading:
|
|
5064
|
-
loadingComponent: /* @__PURE__ */ n(
|
|
5067
|
+
loading: !1,
|
|
5068
|
+
loadingComponent: /* @__PURE__ */ n(Ae, {}),
|
|
5065
5069
|
onRowStyle: (W) => {
|
|
5066
5070
|
if (m[W.id])
|
|
5067
5071
|
return {
|
|
@@ -5097,7 +5101,7 @@ function Ul(e, t) {
|
|
|
5097
5101
|
onChangeSelectedRowKeys: m
|
|
5098
5102
|
} = e, [v, p] = T(!1), [h, g] = T(!1), y = me(!1), [O, _] = T(), [b, A] = T(), [I, M] = T(), [w, x] = T(), [F, C] = T(200), L = me(), {
|
|
5099
5103
|
height: S
|
|
5100
|
-
} = dn(), R = Y(
|
|
5104
|
+
} = dn(), R = Y(Mt), {
|
|
5101
5105
|
processAction: V
|
|
5102
5106
|
} = R || {}, E = Y(Xe), {
|
|
5103
5107
|
setResults: D = void 0,
|
|
@@ -5117,7 +5121,7 @@ function Ul(e, t) {
|
|
|
5117
5121
|
setTreeIsLoading: J = void 0,
|
|
5118
5122
|
searchValues: pe = {},
|
|
5119
5123
|
setSearchValues: ye = void 0,
|
|
5120
|
-
limit:
|
|
5124
|
+
limit: ke = Pt,
|
|
5121
5125
|
setLimit: de = void 0
|
|
5122
5126
|
} = (f ? E : {}) || {}, {
|
|
5123
5127
|
submit: oe,
|
|
@@ -5156,10 +5160,10 @@ function Ul(e, t) {
|
|
|
5156
5160
|
domain: u,
|
|
5157
5161
|
currentId: N,
|
|
5158
5162
|
setActionViewTotalItems: se,
|
|
5159
|
-
limit:
|
|
5163
|
+
limit: ke,
|
|
5160
5164
|
setLimit: de
|
|
5161
5165
|
});
|
|
5162
|
-
|
|
5166
|
+
bt(t, () => ({
|
|
5163
5167
|
refreshResults: () => {
|
|
5164
5168
|
y.current = !1, be();
|
|
5165
5169
|
},
|
|
@@ -5168,14 +5172,14 @@ function Ul(e, t) {
|
|
|
5168
5172
|
})), ge(() => {
|
|
5169
5173
|
!h || d && (y.current = !1, be());
|
|
5170
5174
|
}, [Je, Be, h, d, a]);
|
|
5171
|
-
const
|
|
5175
|
+
const Re = async () => {
|
|
5172
5176
|
g(!1), p(!0), x(void 0), J == null || J(!0);
|
|
5173
5177
|
try {
|
|
5174
5178
|
await tt(), g(!0);
|
|
5175
5179
|
} catch (he) {
|
|
5176
|
-
x(he);
|
|
5180
|
+
x(he), J == null || J(!1);
|
|
5177
5181
|
} finally {
|
|
5178
|
-
p(!1)
|
|
5182
|
+
p(!1);
|
|
5179
5183
|
}
|
|
5180
5184
|
}, tt = async () => {
|
|
5181
5185
|
_(r);
|
|
@@ -5193,7 +5197,7 @@ function Ul(e, t) {
|
|
|
5193
5197
|
})), M(he), A(Ke);
|
|
5194
5198
|
};
|
|
5195
5199
|
ge(() => {
|
|
5196
|
-
|
|
5200
|
+
Re();
|
|
5197
5201
|
}, [r]);
|
|
5198
5202
|
const Ze = (he) => {
|
|
5199
5203
|
de == null || de(he);
|
|
@@ -5216,7 +5220,7 @@ function Ul(e, t) {
|
|
|
5216
5220
|
},
|
|
5217
5221
|
context: c
|
|
5218
5222
|
}));
|
|
5219
|
-
},
|
|
5223
|
+
}, X = async (he) => {
|
|
5220
5224
|
const {
|
|
5221
5225
|
id: Ke
|
|
5222
5226
|
} = he;
|
|
@@ -5242,7 +5246,7 @@ function Ul(e, t) {
|
|
|
5242
5246
|
function Oe() {
|
|
5243
5247
|
return b != null && b.isExpandable ? S - 160 : S - (F + 210);
|
|
5244
5248
|
}
|
|
5245
|
-
const ae = () => !b || !I ? null : /* @__PURE__ */ H(
|
|
5249
|
+
const ae = () => !b || !I ? null : /* @__PURE__ */ H(Z, {
|
|
5246
5250
|
children: [/* @__PURE__ */ n(uo, {
|
|
5247
5251
|
fields: {
|
|
5248
5252
|
...b.fields,
|
|
@@ -5251,7 +5255,7 @@ function Ul(e, t) {
|
|
|
5251
5255
|
searchFields: so([I.search_fields, b.search_fields]),
|
|
5252
5256
|
formXml: I.arch,
|
|
5253
5257
|
onClear: Te,
|
|
5254
|
-
limit:
|
|
5258
|
+
limit: ke,
|
|
5255
5259
|
offset: Be,
|
|
5256
5260
|
isSearching: He,
|
|
5257
5261
|
onSubmit: oe,
|
|
@@ -5263,13 +5267,13 @@ function Ul(e, t) {
|
|
|
5263
5267
|
}), /* @__PURE__ */ n(mn, {
|
|
5264
5268
|
context: c,
|
|
5265
5269
|
total: De,
|
|
5266
|
-
limit:
|
|
5270
|
+
limit: ke,
|
|
5267
5271
|
page: Je,
|
|
5268
5272
|
treeView: b,
|
|
5269
5273
|
results: te(),
|
|
5270
5274
|
onRequestPageChange: ue,
|
|
5271
5275
|
loading: Fe,
|
|
5272
|
-
onRowClicked:
|
|
5276
|
+
onRowClicked: X,
|
|
5273
5277
|
scrollY: l || Oe(),
|
|
5274
5278
|
colorsForResults: le,
|
|
5275
5279
|
rowSelection: {
|
|
@@ -5292,10 +5296,10 @@ function Ul(e, t) {
|
|
|
5292
5296
|
style: d ? {} : {
|
|
5293
5297
|
display: "none"
|
|
5294
5298
|
},
|
|
5295
|
-
children: v ? /* @__PURE__ */ n(
|
|
5299
|
+
children: v ? /* @__PURE__ */ n(Ae, {}) : ae()
|
|
5296
5300
|
});
|
|
5297
5301
|
}
|
|
5298
|
-
const vo =
|
|
5302
|
+
const vo = wt(Ul), wo = (e) => {
|
|
5299
5303
|
const {
|
|
5300
5304
|
visible: t,
|
|
5301
5305
|
onCloseModal: r,
|
|
@@ -5324,7 +5328,7 @@ const vo = vt(Ul), wo = (e) => {
|
|
|
5324
5328
|
}
|
|
5325
5329
|
i(v);
|
|
5326
5330
|
}
|
|
5327
|
-
const O = () => /* @__PURE__ */ H(
|
|
5331
|
+
const O = () => /* @__PURE__ */ H(Z, {
|
|
5328
5332
|
children: [/* @__PURE__ */ n(vo, {
|
|
5329
5333
|
model: o,
|
|
5330
5334
|
nameSearch: s,
|
|
@@ -5345,7 +5349,7 @@ const vo = vt(Ul), wo = (e) => {
|
|
|
5345
5349
|
},
|
|
5346
5350
|
children: m("new")
|
|
5347
5351
|
}), /* @__PURE__ */ n(Ie, {
|
|
5348
|
-
icon: /* @__PURE__ */ n(
|
|
5352
|
+
icon: /* @__PURE__ */ n(kt, {}),
|
|
5349
5353
|
onClick: () => {
|
|
5350
5354
|
y();
|
|
5351
5355
|
},
|
|
@@ -5359,7 +5363,7 @@ const vo = vt(Ul), wo = (e) => {
|
|
|
5359
5363
|
})
|
|
5360
5364
|
})]
|
|
5361
5365
|
});
|
|
5362
|
-
return /* @__PURE__ */ H(
|
|
5366
|
+
return /* @__PURE__ */ H(Z, {
|
|
5363
5367
|
children: [/* @__PURE__ */ n(We, {
|
|
5364
5368
|
title: m("search"),
|
|
5365
5369
|
centered: !0,
|
|
@@ -5511,7 +5515,7 @@ const vo = vt(Ul), wo = (e) => {
|
|
|
5511
5515
|
async function z() {
|
|
5512
5516
|
d && (S.current = await B.getHandler().evalDomain({
|
|
5513
5517
|
domain: d,
|
|
5514
|
-
values:
|
|
5518
|
+
values: Rt({
|
|
5515
5519
|
fields: F(),
|
|
5516
5520
|
values: x()
|
|
5517
5521
|
}),
|
|
@@ -6061,7 +6065,7 @@ const {
|
|
|
6061
6065
|
uninformedString: a,
|
|
6062
6066
|
manualIds: l
|
|
6063
6067
|
} = e, [u, d] = T(!1), [f, c] = T(), [m, v] = T(), [p, h] = T(), [g, y] = T("line");
|
|
6064
|
-
return
|
|
6068
|
+
return Ct(() => {
|
|
6065
6069
|
(async () => {
|
|
6066
6070
|
d(!0), c(void 0);
|
|
6067
6071
|
const O = $n(o);
|
|
@@ -6202,7 +6206,7 @@ const uc = {
|
|
|
6202
6206
|
banner: !0
|
|
6203
6207
|
});
|
|
6204
6208
|
if (d)
|
|
6205
|
-
return /* @__PURE__ */ n(
|
|
6209
|
+
return /* @__PURE__ */ n(Ae, {});
|
|
6206
6210
|
if (!f)
|
|
6207
6211
|
return /* @__PURE__ */ n(ze, {
|
|
6208
6212
|
message: "No data to display",
|
|
@@ -6232,7 +6236,7 @@ const uc = {
|
|
|
6232
6236
|
isStack: h
|
|
6233
6237
|
})
|
|
6234
6238
|
})]
|
|
6235
|
-
}) : /* @__PURE__ */ n(
|
|
6239
|
+
}) : /* @__PURE__ */ n(Z, {
|
|
6236
6240
|
children: `Unknown graph type: ${c}`
|
|
6237
6241
|
});
|
|
6238
6242
|
};
|
|
@@ -6257,7 +6261,7 @@ const hc = (e, t) => {
|
|
|
6257
6261
|
} = e, [u, d] = T(!1), [f, c] = T(), [m, v] = T(), p = Y(Xe), {
|
|
6258
6262
|
setGraphIsLoading: h = void 0
|
|
6259
6263
|
} = p || {};
|
|
6260
|
-
|
|
6264
|
+
bt(t, () => ({
|
|
6261
6265
|
refresh: () => {
|
|
6262
6266
|
g();
|
|
6263
6267
|
}
|
|
@@ -6277,7 +6281,7 @@ const hc = (e, t) => {
|
|
|
6277
6281
|
const O = $n(y.arch);
|
|
6278
6282
|
c(O);
|
|
6279
6283
|
} catch (y) {
|
|
6280
|
-
return console.error(y), /* @__PURE__ */ n(
|
|
6284
|
+
return console.error(y), /* @__PURE__ */ n(Z, {
|
|
6281
6285
|
children: JSON.stringify(y)
|
|
6282
6286
|
});
|
|
6283
6287
|
}
|
|
@@ -6333,11 +6337,11 @@ const hc = (e, t) => {
|
|
|
6333
6337
|
manualIds: l
|
|
6334
6338
|
});
|
|
6335
6339
|
default:
|
|
6336
|
-
return /* @__PURE__ */ n(
|
|
6340
|
+
return /* @__PURE__ */ n(Z, {
|
|
6337
6341
|
children: `Graph ${f.type} not implemented`
|
|
6338
6342
|
});
|
|
6339
6343
|
}
|
|
6340
|
-
}, hn =
|
|
6344
|
+
}, hn = wt(hc), {
|
|
6341
6345
|
confirm: pc
|
|
6342
6346
|
} = We, gc = ({
|
|
6343
6347
|
onOk: e,
|
|
@@ -6426,7 +6430,7 @@ const hc = (e, t) => {
|
|
|
6426
6430
|
});
|
|
6427
6431
|
}
|
|
6428
6432
|
function A() {
|
|
6429
|
-
return /* @__PURE__ */ H(
|
|
6433
|
+
return /* @__PURE__ */ H(Z, {
|
|
6430
6434
|
children: [y(), /* @__PURE__ */ n(Ge, {
|
|
6431
6435
|
tooltip: "Previous item",
|
|
6432
6436
|
icon: /* @__PURE__ */ n(Br, {}),
|
|
@@ -6503,7 +6507,7 @@ const Sc = (e) => {
|
|
|
6503
6507
|
domain: Q
|
|
6504
6508
|
} = i, ie = i.type === "many2many", {
|
|
6505
6509
|
id: se
|
|
6506
|
-
} = i, ee = s.filter((
|
|
6510
|
+
} = i, ee = s.filter((X) => (X.values || X.treeValues) && X.operation !== "pendingRemove"), J = me();
|
|
6507
6511
|
ge(() => {
|
|
6508
6512
|
if (J.current !== a) {
|
|
6509
6513
|
J.current = a, pe();
|
|
@@ -6511,21 +6515,21 @@ const Sc = (e) => {
|
|
|
6511
6515
|
}
|
|
6512
6516
|
pe();
|
|
6513
6517
|
}, [s, a]);
|
|
6514
|
-
const pe =
|
|
6515
|
-
(a === "form" && s.some((
|
|
6518
|
+
const pe = Me(() => {
|
|
6519
|
+
(a === "form" && s.some((X) => !X.values) || a === "tree" && s.some((X) => !X.treeValues)) && ke();
|
|
6516
6520
|
}, [s, a]);
|
|
6517
6521
|
ge(() => {
|
|
6518
6522
|
oe();
|
|
6519
6523
|
}, [h]);
|
|
6520
|
-
const ye = (
|
|
6524
|
+
const ye = (X) => {
|
|
6521
6525
|
var fe, Oe;
|
|
6522
6526
|
r == null || r({
|
|
6523
6527
|
fields: ((fe = o.get("form")) == null ? void 0 : fe.fields) || ((Oe = o.get("tree")) == null ? void 0 : Oe.fields),
|
|
6524
|
-
items: Cc(
|
|
6528
|
+
items: Cc(X)
|
|
6525
6529
|
});
|
|
6526
|
-
},
|
|
6530
|
+
}, ke = async () => {
|
|
6527
6531
|
await de(), u > ee.length - 1 && u !== 0 && d(0);
|
|
6528
|
-
}, de = async (
|
|
6532
|
+
}, de = async (X) => {
|
|
6529
6533
|
var fe, Oe, ae;
|
|
6530
6534
|
A(!0), _(!1), M(void 0);
|
|
6531
6535
|
try {
|
|
@@ -6543,9 +6547,9 @@ const Sc = (e) => {
|
|
|
6543
6547
|
...p == null ? void 0 : p(),
|
|
6544
6548
|
...P
|
|
6545
6549
|
},
|
|
6546
|
-
currentView:
|
|
6550
|
+
currentView: X || a
|
|
6547
6551
|
});
|
|
6548
|
-
return W.current || (W.current = Ce.map((Ke) => Ke.id)), (a ||
|
|
6552
|
+
return W.current || (W.current = Ce.map((Ke) => Ke.id)), (a || X) === "tree" && he && z(he), ye(Ce), Ce;
|
|
6549
6553
|
} catch (Ce) {
|
|
6550
6554
|
M(Ce);
|
|
6551
6555
|
} finally {
|
|
@@ -6555,7 +6559,7 @@ const Sc = (e) => {
|
|
|
6555
6559
|
async function oe() {
|
|
6556
6560
|
Q && (k.current = await B.getHandler().evalDomain({
|
|
6557
6561
|
domain: Q,
|
|
6558
|
-
values:
|
|
6562
|
+
values: Rt({
|
|
6559
6563
|
fields: m(),
|
|
6560
6564
|
values: v()
|
|
6561
6565
|
}),
|
|
@@ -6567,7 +6571,7 @@ const Sc = (e) => {
|
|
|
6567
6571
|
})));
|
|
6568
6572
|
}
|
|
6569
6573
|
const Te = () => {
|
|
6570
|
-
const
|
|
6574
|
+
const X = Array.from(o.keys()), fe = X[(X.indexOf(a) + 1) % X.length];
|
|
6571
6575
|
a === "form" ? Ne(() => {
|
|
6572
6576
|
l(fe);
|
|
6573
6577
|
}) : l(fe);
|
|
@@ -6576,14 +6580,14 @@ const Sc = (e) => {
|
|
|
6576
6580
|
d(u - 1);
|
|
6577
6581
|
}) : d(u - 1));
|
|
6578
6582
|
}, Fe = () => {
|
|
6579
|
-
const
|
|
6580
|
-
u <
|
|
6583
|
+
const X = ee.length;
|
|
6584
|
+
u < X - 1 && (a === "form" ? Ne(() => {
|
|
6581
6585
|
d(u + 1);
|
|
6582
6586
|
}) : d(u + 1));
|
|
6583
6587
|
}, He = async () => {
|
|
6584
|
-
const
|
|
6588
|
+
const X = ee[u].id, fe = (await B.getHandler().readObjects({
|
|
6585
6589
|
model: $,
|
|
6586
|
-
ids: [
|
|
6590
|
+
ids: [X],
|
|
6587
6591
|
fields: o.get("form").fields,
|
|
6588
6592
|
context: {
|
|
6589
6593
|
...p == null ? void 0 : p(),
|
|
@@ -6591,26 +6595,26 @@ const Sc = (e) => {
|
|
|
6591
6595
|
}
|
|
6592
6596
|
}))[0], Oe = (await B.getHandler().readObjects({
|
|
6593
6597
|
model: $,
|
|
6594
|
-
ids: [
|
|
6598
|
+
ids: [X],
|
|
6595
6599
|
fields: o.get("tree").fields,
|
|
6596
6600
|
context: {
|
|
6597
6601
|
...p == null ? void 0 : p(),
|
|
6598
6602
|
...P
|
|
6599
6603
|
}
|
|
6600
|
-
}))[0], ae = s.map((Ce) => Ce.id ===
|
|
6604
|
+
}))[0], ae = s.map((Ce) => Ce.id === X ? {
|
|
6601
6605
|
...Ce,
|
|
6602
6606
|
operation: "original",
|
|
6603
6607
|
values: fe,
|
|
6604
6608
|
treeValues: Oe
|
|
6605
6609
|
} : Ce);
|
|
6606
6610
|
ye(ae);
|
|
6607
|
-
}, Ne = (
|
|
6611
|
+
}, Ne = (X) => {
|
|
6608
6612
|
O ? Yt({
|
|
6609
6613
|
lang: g,
|
|
6610
6614
|
onOk: () => {
|
|
6611
|
-
He(),
|
|
6615
|
+
He(), X(), _(!1);
|
|
6612
6616
|
}
|
|
6613
|
-
}) :
|
|
6617
|
+
}) : X();
|
|
6614
6618
|
}, Je = () => {
|
|
6615
6619
|
if (ie) {
|
|
6616
6620
|
vc({
|
|
@@ -6629,11 +6633,11 @@ const Sc = (e) => {
|
|
|
6629
6633
|
});
|
|
6630
6634
|
}, Be = async () => {
|
|
6631
6635
|
const {
|
|
6632
|
-
inv_field:
|
|
6636
|
+
inv_field: X
|
|
6633
6637
|
} = i;
|
|
6634
6638
|
let fe;
|
|
6635
|
-
|
|
6636
|
-
[
|
|
6639
|
+
X && c && (fe = {
|
|
6640
|
+
[X]: c
|
|
6637
6641
|
}), a === "form" ? Ne(() => {
|
|
6638
6642
|
D(!0), S({
|
|
6639
6643
|
defaultValues: fe
|
|
@@ -6649,22 +6653,22 @@ const Sc = (e) => {
|
|
|
6649
6653
|
A(!0), _(!1), M(void 0);
|
|
6650
6654
|
try {
|
|
6651
6655
|
if (ee[u].id > 0) {
|
|
6652
|
-
const
|
|
6656
|
+
const X = s.map((fe) => fe.id === ee[u].id ? {
|
|
6653
6657
|
...fe,
|
|
6654
6658
|
operation: "pendingRemove"
|
|
6655
6659
|
} : fe);
|
|
6656
|
-
ye(
|
|
6660
|
+
ye(X);
|
|
6657
6661
|
} else
|
|
6658
|
-
ye(s.filter((
|
|
6659
|
-
} catch (
|
|
6660
|
-
M(
|
|
6662
|
+
ye(s.filter((X) => X.id !== ee[u].id));
|
|
6663
|
+
} catch (X) {
|
|
6664
|
+
M(X);
|
|
6661
6665
|
}
|
|
6662
6666
|
d(0), A(!1);
|
|
6663
6667
|
}, xe = async () => {
|
|
6664
|
-
const
|
|
6668
|
+
const X = ee.filter((fe) => R.includes(fe.id));
|
|
6665
6669
|
A(!0), _(!1), M(void 0);
|
|
6666
6670
|
try {
|
|
6667
|
-
const fe =
|
|
6671
|
+
const fe = X.map((ae) => ae.id), Oe = s.filter((ae) => !(fe.includes(ae.id) && ae.id < 0)).map((ae) => fe.includes(ae.id) ? {
|
|
6668
6672
|
...ae,
|
|
6669
6673
|
operation: "pendingRemove"
|
|
6670
6674
|
} : ae);
|
|
@@ -6673,19 +6677,19 @@ const Sc = (e) => {
|
|
|
6673
6677
|
M(fe);
|
|
6674
6678
|
}
|
|
6675
6679
|
d(0), A(!1);
|
|
6676
|
-
}, Pe = (
|
|
6680
|
+
}, Pe = (X, fe, Oe) => {
|
|
6677
6681
|
let ae;
|
|
6678
|
-
if (
|
|
6679
|
-
ae = s.map((Ce) => Ce.id ===
|
|
6680
|
-
id:
|
|
6681
|
-
operation:
|
|
6682
|
+
if (X)
|
|
6683
|
+
ae = s.map((Ce) => Ce.id === X ? {
|
|
6684
|
+
id: X,
|
|
6685
|
+
operation: X > 0 ? "pendingUpdate" : "pendingCreate",
|
|
6682
6686
|
values: {
|
|
6683
6687
|
...Oe,
|
|
6684
|
-
id:
|
|
6688
|
+
id: X
|
|
6685
6689
|
},
|
|
6686
6690
|
treeValues: {
|
|
6687
6691
|
...Oe,
|
|
6688
|
-
id:
|
|
6692
|
+
id: X
|
|
6689
6693
|
}
|
|
6690
6694
|
} : Ce);
|
|
6691
6695
|
else {
|
|
@@ -6704,17 +6708,17 @@ const Sc = (e) => {
|
|
|
6704
6708
|
});
|
|
6705
6709
|
}
|
|
6706
6710
|
ye(ae), E || x(!1);
|
|
6707
|
-
}, le = async (
|
|
6711
|
+
}, le = async (X) => {
|
|
6708
6712
|
const {
|
|
6709
6713
|
id: fe
|
|
6710
|
-
} =
|
|
6714
|
+
} = X;
|
|
6711
6715
|
let Oe = s;
|
|
6712
6716
|
const ae = s.find((Ce) => Ce.id === fe);
|
|
6713
6717
|
(ae == null ? void 0 : ae.values) === void 0 && (Oe = await de("form")), S(Oe.find((Ce) => Ce.id === fe)), D(!1), x(!0);
|
|
6714
|
-
}, De = async (
|
|
6718
|
+
}, De = async (X) => {
|
|
6715
6719
|
A(!0);
|
|
6716
6720
|
let fe = s;
|
|
6717
|
-
const Oe =
|
|
6721
|
+
const Oe = X.filter((ae) => !s.find((Ce) => Ce.id === ae));
|
|
6718
6722
|
try {
|
|
6719
6723
|
for (const ae of Oe) {
|
|
6720
6724
|
const Ce = (await B.getHandler().readObjects({
|
|
@@ -6748,19 +6752,19 @@ const Sc = (e) => {
|
|
|
6748
6752
|
A(!1);
|
|
6749
6753
|
}
|
|
6750
6754
|
};
|
|
6751
|
-
function
|
|
6752
|
-
const
|
|
6755
|
+
function Re() {
|
|
6756
|
+
const X = xc[a];
|
|
6753
6757
|
if (a === "graph")
|
|
6754
6758
|
return $n(o.get("graph").arch).string;
|
|
6755
6759
|
{
|
|
6756
|
-
const fe = new
|
|
6760
|
+
const fe = new X(o.get(a).fields);
|
|
6757
6761
|
return fe.parse(o.get(a).arch), fe.string;
|
|
6758
6762
|
}
|
|
6759
6763
|
}
|
|
6760
6764
|
const tt = () => {
|
|
6761
6765
|
var fe, Oe, ae, Ce;
|
|
6762
6766
|
if (a === "form")
|
|
6763
|
-
return ee.length === 0 ? y("noCurrentEntries") : a !== J.current && s.some((he) => !he.values) ? /* @__PURE__ */ n(
|
|
6767
|
+
return ee.length === 0 ? y("noCurrentEntries") : a !== J.current && s.some((he) => !he.values) ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ n(Wt, {
|
|
6764
6768
|
formView: o.get("form"),
|
|
6765
6769
|
values: (fe = ee[u]) == null ? void 0 : fe.values,
|
|
6766
6770
|
parentContext: {
|
|
@@ -6788,8 +6792,8 @@ const Sc = (e) => {
|
|
|
6788
6792
|
},
|
|
6789
6793
|
readOnly: q
|
|
6790
6794
|
});
|
|
6791
|
-
let
|
|
6792
|
-
if (ee.some((he) => he.treeValues) && (
|
|
6795
|
+
let X = [];
|
|
6796
|
+
if (ee.some((he) => he.treeValues) && (X = N ? _t({
|
|
6793
6797
|
resultsToSort: ee.map((he) => he.treeValues),
|
|
6794
6798
|
sorter: N,
|
|
6795
6799
|
fields: {
|
|
@@ -6801,7 +6805,7 @@ const Sc = (e) => {
|
|
|
6801
6805
|
total: ee.length,
|
|
6802
6806
|
limit: ee.length,
|
|
6803
6807
|
treeView: o.get("tree"),
|
|
6804
|
-
results:
|
|
6808
|
+
results: X,
|
|
6805
6809
|
loading: b,
|
|
6806
6810
|
onRowClicked: ((Ce = o.get("form")) == null ? void 0 : Ce.fields) !== void 0 ? le : void 0,
|
|
6807
6811
|
showPagination: !1,
|
|
@@ -6839,10 +6843,10 @@ const Sc = (e) => {
|
|
|
6839
6843
|
banner: !0
|
|
6840
6844
|
});
|
|
6841
6845
|
const Ze = E;
|
|
6842
|
-
return b ? /* @__PURE__ */ n(
|
|
6846
|
+
return b ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ H(Z, {
|
|
6843
6847
|
children: [/* @__PURE__ */ n(bc, {
|
|
6844
6848
|
mode: a,
|
|
6845
|
-
title:
|
|
6849
|
+
title: Re(),
|
|
6846
6850
|
readOnly: q,
|
|
6847
6851
|
isMany2Many: ie,
|
|
6848
6852
|
formHasChanges: O,
|
|
@@ -6883,8 +6887,8 @@ const Sc = (e) => {
|
|
|
6883
6887
|
...P
|
|
6884
6888
|
},
|
|
6885
6889
|
visible: F,
|
|
6886
|
-
onSelectValues: async (
|
|
6887
|
-
C(!1), De(
|
|
6890
|
+
onSelectValues: async (X) => {
|
|
6891
|
+
C(!1), De(X);
|
|
6888
6892
|
},
|
|
6889
6893
|
onCloseModal: () => {
|
|
6890
6894
|
C(!1);
|
|
@@ -6905,7 +6909,7 @@ const Sc = (e) => {
|
|
|
6905
6909
|
const [u, d] = T(!0), [f, c] = T(), [m, v] = T(/* @__PURE__ */ new Map()), p = Y(Ee), {
|
|
6906
6910
|
getContext: h
|
|
6907
6911
|
} = p || {};
|
|
6908
|
-
|
|
6912
|
+
Ct(() => {
|
|
6909
6913
|
y();
|
|
6910
6914
|
}, [t]);
|
|
6911
6915
|
const g = async (_) => o && o[_] ? o[_] : await B.getHandler().getView({
|
|
@@ -6934,7 +6938,7 @@ const Sc = (e) => {
|
|
|
6934
6938
|
d(!1);
|
|
6935
6939
|
}
|
|
6936
6940
|
};
|
|
6937
|
-
return r && r.length > 0 ? l = r[0] : l = "tree", u ? /* @__PURE__ */ n(
|
|
6941
|
+
return r && r.length > 0 ? l = r[0] : l = "tree", u ? /* @__PURE__ */ n(Ae, {}) : f ? /* @__PURE__ */ n(ze, {
|
|
6938
6942
|
className: "mt-10",
|
|
6939
6943
|
message: f,
|
|
6940
6944
|
type: "error",
|
|
@@ -7022,7 +7026,7 @@ function To(e) {
|
|
|
7022
7026
|
showLabel: r = !0,
|
|
7023
7027
|
responsiveBehaviour: i
|
|
7024
7028
|
} = e, o = st(t.icon || "");
|
|
7025
|
-
return /* @__PURE__ */ n(
|
|
7029
|
+
return /* @__PURE__ */ n(Z, {
|
|
7026
7030
|
children: (t.label || o) && r ? /* @__PURE__ */ n(Ii, {
|
|
7027
7031
|
label: t.label,
|
|
7028
7032
|
icon: o,
|
|
@@ -7054,7 +7058,7 @@ function Dc(e) {
|
|
|
7054
7058
|
defaultActiveKey: "1",
|
|
7055
7059
|
tabPosition: t.tabPosition,
|
|
7056
7060
|
children: i.filter((s) => !s.invisible).map((s) => /* @__PURE__ */ n(Ic, {
|
|
7057
|
-
tab: /* @__PURE__ */ H(
|
|
7061
|
+
tab: /* @__PURE__ */ H(Z, {
|
|
7058
7062
|
children: [o(s.icon), " ", s.label]
|
|
7059
7063
|
}),
|
|
7060
7064
|
children: /* @__PURE__ */ n(To, {
|
|
@@ -7118,7 +7122,7 @@ const {
|
|
|
7118
7122
|
} = s || {}, [c, m] = T(!1), {
|
|
7119
7123
|
t: v
|
|
7120
7124
|
} = Y(we);
|
|
7121
|
-
return a ? /* @__PURE__ */ H(
|
|
7125
|
+
return a ? /* @__PURE__ */ H(Z, {
|
|
7122
7126
|
children: [/* @__PURE__ */ n("div", {
|
|
7123
7127
|
onClick: () => {
|
|
7124
7128
|
if (d != null && d()) {
|
|
@@ -7154,7 +7158,7 @@ const {
|
|
|
7154
7158
|
m(!1), u == null || u();
|
|
7155
7159
|
}
|
|
7156
7160
|
})]
|
|
7157
|
-
}) : /* @__PURE__ */ H(
|
|
7161
|
+
}) : /* @__PURE__ */ H(Z, {
|
|
7158
7162
|
children: [/* @__PURE__ */ n(Se, {
|
|
7159
7163
|
gutter: 8,
|
|
7160
7164
|
wrap: !1,
|
|
@@ -7209,7 +7213,7 @@ const {
|
|
|
7209
7213
|
limit: s,
|
|
7210
7214
|
onClose: a
|
|
7211
7215
|
}) => {
|
|
7212
|
-
const l = me({}), u = me(/* @__PURE__ */ new Map()), d =
|
|
7216
|
+
const l = me({}), u = me(/* @__PURE__ */ new Map()), d = Me(
|
|
7213
7217
|
async (g) => {
|
|
7214
7218
|
if (g.selectedKeys === void 0 || g.selectedKeys.length === 0) {
|
|
7215
7219
|
ct(_e("selectAtLeastOneField", r));
|
|
@@ -7231,18 +7235,18 @@ const {
|
|
|
7231
7235
|
format: g.exportType
|
|
7232
7236
|
});
|
|
7233
7237
|
a(), await new Promise((b) => setTimeout(b, 200));
|
|
7234
|
-
const _ = await
|
|
7238
|
+
const _ = await Dt(O);
|
|
7235
7239
|
un(O, _.mime);
|
|
7236
7240
|
},
|
|
7237
7241
|
[r, e, o, s, t, a]
|
|
7238
|
-
), f =
|
|
7242
|
+
), f = Me(async () => {
|
|
7239
7243
|
const g = await B.getHandler().getFields({
|
|
7240
7244
|
model: e,
|
|
7241
7245
|
context: t,
|
|
7242
7246
|
fields: []
|
|
7243
7247
|
});
|
|
7244
7248
|
return l.current["/"] = g, Fr({ fields: g });
|
|
7245
|
-
}, [e, t, l]), c =
|
|
7249
|
+
}, [e, t, l]), c = Me(
|
|
7246
7250
|
async (g) => {
|
|
7247
7251
|
const O = An(g, l.current)[Vn(g)], _ = O.relation, b = await B.getHandler().getFields({
|
|
7248
7252
|
model: _,
|
|
@@ -7260,7 +7264,7 @@ const {
|
|
|
7260
7264
|
});
|
|
7261
7265
|
},
|
|
7262
7266
|
[l.current, e, t]
|
|
7263
|
-
), m =
|
|
7267
|
+
), m = Me(async () => {
|
|
7264
7268
|
const g = await Lc({ model: e, context: t }), y = await Pc({
|
|
7265
7269
|
predefinedExports: g,
|
|
7266
7270
|
fields: l.current,
|
|
@@ -7279,7 +7283,7 @@ const {
|
|
|
7279
7283
|
})),
|
|
7280
7284
|
keysWithChilds: y
|
|
7281
7285
|
};
|
|
7282
|
-
}, [l.current]), v =
|
|
7286
|
+
}, [l.current]), v = Me(
|
|
7283
7287
|
async (g) => {
|
|
7284
7288
|
const y = await h("ir.exports"), O = await h("ir.exports.line"), _ = await B.getHandler().create({
|
|
7285
7289
|
model: "ir.exports",
|
|
@@ -7303,7 +7307,7 @@ const {
|
|
|
7303
7307
|
), { ...g, id: _ };
|
|
7304
7308
|
},
|
|
7305
7309
|
[]
|
|
7306
|
-
), p =
|
|
7310
|
+
), p = Me(
|
|
7307
7311
|
async (g) => {
|
|
7308
7312
|
await B.getHandler().delete({
|
|
7309
7313
|
model: "ir.exports",
|
|
@@ -7311,7 +7315,7 @@ const {
|
|
|
7311
7315
|
});
|
|
7312
7316
|
},
|
|
7313
7317
|
[]
|
|
7314
|
-
), h =
|
|
7318
|
+
), h = Me(
|
|
7315
7319
|
async (g) => {
|
|
7316
7320
|
if (u.current.has(g))
|
|
7317
7321
|
return u.current.get(g);
|
|
@@ -7599,8 +7603,8 @@ var Oo = { exports: {} };
|
|
|
7599
7603
|
return new Date((D === "X" ? 1e3 : 1) * E);
|
|
7600
7604
|
var N = p(D)(E), j = N.year, W = N.month, K = N.day, z = N.hours, q = N.minutes, $ = N.seconds, P = N.milliseconds, Q = N.zone, ie = new Date(), se = K || (j || W ? 1 : ie.getDate()), ee = j || ie.getFullYear(), J = 0;
|
|
7601
7605
|
j && !W || (J = W > 0 ? W - 1 : ie.getMonth());
|
|
7602
|
-
var pe = z || 0, ye = q || 0,
|
|
7603
|
-
return Q ? new Date(Date.UTC(ee, J, se, pe, ye,
|
|
7606
|
+
var pe = z || 0, ye = q || 0, ke = $ || 0, de = P || 0;
|
|
7607
|
+
return Q ? new Date(Date.UTC(ee, J, se, pe, ye, ke, de + 60 * Q.offset * 1e3)) : k ? new Date(Date.UTC(ee, J, se, pe, ye, ke, de)) : new Date(ee, J, se, pe, ye, ke, de);
|
|
7604
7608
|
} catch {
|
|
7605
7609
|
return new Date("");
|
|
7606
7610
|
}
|
|
@@ -7744,11 +7748,11 @@ const Uc = (e) => {
|
|
|
7744
7748
|
i == null || i(_);
|
|
7745
7749
|
};
|
|
7746
7750
|
async function h() {
|
|
7747
|
-
const _ = await
|
|
7751
|
+
const _ = await Dt(r), b = `data:${_ == null ? void 0 : _.mime};base64,${r}`, A = document.createElement("a"), I = c(a), M = c("name");
|
|
7748
7752
|
A.href = b, A.download = I || M, A.click();
|
|
7749
7753
|
}
|
|
7750
7754
|
async function g() {
|
|
7751
|
-
const _ = await
|
|
7755
|
+
const _ = await Dt(r);
|
|
7752
7756
|
un(r, _.mime);
|
|
7753
7757
|
}
|
|
7754
7758
|
async function y(_) {
|
|
@@ -7846,7 +7850,7 @@ function Zn(e) {
|
|
|
7846
7850
|
children: v.type.charAt(0).toUpperCase() + v.type.slice(1)
|
|
7847
7851
|
}), /* @__PURE__ */ n(ce, {
|
|
7848
7852
|
flex: "none",
|
|
7849
|
-
children: /* @__PURE__ */ n(
|
|
7853
|
+
children: /* @__PURE__ */ n(kt, {
|
|
7850
7854
|
style: {
|
|
7851
7855
|
opacity: t.view_id === v.view_id ? 1 : 0
|
|
7852
7856
|
}
|
|
@@ -7907,7 +7911,7 @@ function Zn(e) {
|
|
|
7907
7911
|
borderTopLeftRadius: 0,
|
|
7908
7912
|
borderBottomLeftRadius: 0
|
|
7909
7913
|
},
|
|
7910
|
-
icon: /* @__PURE__ */ n(
|
|
7914
|
+
icon: /* @__PURE__ */ n(At, {
|
|
7911
7915
|
style: {
|
|
7912
7916
|
fontSize: "0.5em"
|
|
7913
7917
|
}
|
|
@@ -7917,7 +7921,7 @@ function Zn(e) {
|
|
|
7917
7921
|
})]
|
|
7918
7922
|
});
|
|
7919
7923
|
}
|
|
7920
|
-
function
|
|
7924
|
+
function It(e) {
|
|
7921
7925
|
const {
|
|
7922
7926
|
icon: t,
|
|
7923
7927
|
tooltip: r,
|
|
@@ -7946,7 +7950,7 @@ function _t(e) {
|
|
|
7946
7950
|
overlay: l(),
|
|
7947
7951
|
disabled: a || !i || i.length === 0,
|
|
7948
7952
|
children: /* @__PURE__ */ H(Ie, {
|
|
7949
|
-
children: [t, " ", s, " ", /* @__PURE__ */ n(
|
|
7953
|
+
children: [t, " ", s, " ", /* @__PURE__ */ n(At, {})]
|
|
7950
7954
|
})
|
|
7951
7955
|
});
|
|
7952
7956
|
}
|
|
@@ -8038,7 +8042,7 @@ const td = (e) => {
|
|
|
8038
8042
|
lang: o
|
|
8039
8043
|
} = Y(we), [s, a] = T(!1), l = /* @__PURE__ */ H(Ie, {
|
|
8040
8044
|
disabled: r,
|
|
8041
|
-
children: [/* @__PURE__ */ n(Kr, {}), `(${t})`, /* @__PURE__ */ n(
|
|
8045
|
+
children: [/* @__PURE__ */ n(Kr, {}), `(${t})`, /* @__PURE__ */ n(At, {
|
|
8042
8046
|
style: {
|
|
8043
8047
|
fontSize: 12
|
|
8044
8048
|
}
|
|
@@ -8062,11 +8066,11 @@ const td = (e) => {
|
|
|
8062
8066
|
onOpenAttachmentDetail: l,
|
|
8063
8067
|
onListAllAttachments: u
|
|
8064
8068
|
} = e;
|
|
8065
|
-
return o ? /* @__PURE__ */ n(
|
|
8069
|
+
return o ? /* @__PURE__ */ n(Ae, {
|
|
8066
8070
|
style: {
|
|
8067
8071
|
padding: 20
|
|
8068
8072
|
}
|
|
8069
|
-
}) : /* @__PURE__ */ H(
|
|
8073
|
+
}) : /* @__PURE__ */ H(Z, {
|
|
8070
8074
|
children: [/* @__PURE__ */ H("a", {
|
|
8071
8075
|
style: {
|
|
8072
8076
|
display: "block",
|
|
@@ -8086,7 +8090,7 @@ const td = (e) => {
|
|
|
8086
8090
|
t(!1), s();
|
|
8087
8091
|
},
|
|
8088
8092
|
children: [/* @__PURE__ */ n(an, {}), " ", _e("addNewAttachment", r)]
|
|
8089
|
-
}), i.length > 0 && /* @__PURE__ */ H(
|
|
8093
|
+
}), i.length > 0 && /* @__PURE__ */ H(Z, {
|
|
8090
8094
|
children: [/* @__PURE__ */ n("li", {
|
|
8091
8095
|
className: "ant-dropdown-menu-item-divider"
|
|
8092
8096
|
}), i.map((d) => {
|
|
@@ -8150,7 +8154,7 @@ function rd(e) {
|
|
|
8150
8154
|
formRef: a
|
|
8151
8155
|
} = Y(Xe), [l, u] = T(!1), [d, f] = T([]), [c, m] = T(!1), {
|
|
8152
8156
|
t: v
|
|
8153
|
-
} = Y(we), p =
|
|
8157
|
+
} = Y(we), p = Me(async () => {
|
|
8154
8158
|
u(!0);
|
|
8155
8159
|
try {
|
|
8156
8160
|
const y = await B.getHandler().readObjects({
|
|
@@ -8169,7 +8173,7 @@ function rd(e) {
|
|
|
8169
8173
|
Ye(y);
|
|
8170
8174
|
}
|
|
8171
8175
|
u(!1);
|
|
8172
|
-
}, t), h =
|
|
8176
|
+
}, t), h = Me(async (y) => {
|
|
8173
8177
|
if (y.link) {
|
|
8174
8178
|
window.open(y.link);
|
|
8175
8179
|
return;
|
|
@@ -8187,16 +8191,16 @@ function rd(e) {
|
|
|
8187
8191
|
}
|
|
8188
8192
|
if (m(!1), !!O)
|
|
8189
8193
|
if (O.datas) {
|
|
8190
|
-
const _ = await
|
|
8194
|
+
const _ = await Dt(O.datas);
|
|
8191
8195
|
un(O.datas, _.mime);
|
|
8192
8196
|
} else
|
|
8193
8197
|
s(O);
|
|
8194
|
-
}, []), g =
|
|
8198
|
+
}, []), g = Me(async (y) => {
|
|
8195
8199
|
s(y);
|
|
8196
8200
|
}, []);
|
|
8197
8201
|
return ge(() => {
|
|
8198
8202
|
p();
|
|
8199
|
-
}, [p]), /* @__PURE__ */ H(
|
|
8203
|
+
}, [p]), /* @__PURE__ */ H(Z, {
|
|
8200
8204
|
children: [/* @__PURE__ */ n(td, {
|
|
8201
8205
|
numberOfAttachments: t.length,
|
|
8202
8206
|
attachments: d,
|
|
@@ -8213,7 +8217,7 @@ function rd(e) {
|
|
|
8213
8217
|
closable: !1,
|
|
8214
8218
|
centered: !0,
|
|
8215
8219
|
maskClosable: !1,
|
|
8216
|
-
children: /* @__PURE__ */ n(
|
|
8220
|
+
children: /* @__PURE__ */ n(Ae, {})
|
|
8217
8221
|
})]
|
|
8218
8222
|
});
|
|
8219
8223
|
}
|
|
@@ -8248,7 +8252,7 @@ function od({
|
|
|
8248
8252
|
} = Y(Xe), {
|
|
8249
8253
|
t: x,
|
|
8250
8254
|
lang: F
|
|
8251
|
-
} = Y(we), C = Y(
|
|
8255
|
+
} = Y(we), C = Y(Mt), {
|
|
8252
8256
|
processAction: L
|
|
8253
8257
|
} = C || {}, S = Y(at), {
|
|
8254
8258
|
openRelate: R,
|
|
@@ -8338,8 +8342,8 @@ function od({
|
|
|
8338
8342
|
}
|
|
8339
8343
|
return r ? /* @__PURE__ */ H(je, {
|
|
8340
8344
|
wrap: !0,
|
|
8341
|
-
children: [O && /* @__PURE__ */ H(
|
|
8342
|
-
children: [/* @__PURE__ */ n(
|
|
8345
|
+
children: [O && /* @__PURE__ */ H(Z, {
|
|
8346
|
+
children: [/* @__PURE__ */ n(Ae, {}), St(), St()]
|
|
8343
8347
|
}), /* @__PURE__ */ n(_o, {
|
|
8344
8348
|
disabled: a || O || p || h
|
|
8345
8349
|
}), /* @__PURE__ */ n(Ue, {
|
|
@@ -8360,7 +8364,7 @@ function od({
|
|
|
8360
8364
|
disabled: a || l === void 0 || p || h || O,
|
|
8361
8365
|
loading: p,
|
|
8362
8366
|
onClick: j
|
|
8363
|
-
}),
|
|
8367
|
+
}), St(), /* @__PURE__ */ n(Ue, {
|
|
8364
8368
|
icon: /* @__PURE__ */ n(Yr, {}),
|
|
8365
8369
|
tooltip: x("showLogs"),
|
|
8366
8370
|
disabled: a || l === void 0 || p || h || O,
|
|
@@ -8378,7 +8382,7 @@ function od({
|
|
|
8378
8382
|
b.current.fetchValues();
|
|
8379
8383
|
});
|
|
8380
8384
|
}
|
|
8381
|
-
}),
|
|
8385
|
+
}), St(), /* @__PURE__ */ n(Zn, {
|
|
8382
8386
|
currentView: r,
|
|
8383
8387
|
previousView: I,
|
|
8384
8388
|
availableViews: t,
|
|
@@ -8387,7 +8391,7 @@ function od({
|
|
|
8387
8391
|
},
|
|
8388
8392
|
disabled: z,
|
|
8389
8393
|
formHasChanges: s
|
|
8390
|
-
}),
|
|
8394
|
+
}), St(), /* @__PURE__ */ H(je, {
|
|
8391
8395
|
children: [/* @__PURE__ */ n(Ue, {
|
|
8392
8396
|
icon: /* @__PURE__ */ n(Br, {}),
|
|
8393
8397
|
tooltip: x("previous"),
|
|
@@ -8405,17 +8409,17 @@ function od({
|
|
|
8405
8409
|
D(k);
|
|
8406
8410
|
}
|
|
8407
8411
|
})]
|
|
8408
|
-
}),
|
|
8412
|
+
}), St(), /* @__PURE__ */ n(It, {
|
|
8409
8413
|
icon: /* @__PURE__ */ n(Bn, {}),
|
|
8410
8414
|
disabled: z,
|
|
8411
8415
|
tooltip: x("actions"),
|
|
8412
8416
|
items: e == null ? void 0 : e.action,
|
|
8413
8417
|
onItemClick: async ($) => {
|
|
8414
|
-
!$ || !(await
|
|
8418
|
+
!$ || !(await Tt({
|
|
8415
8419
|
onFormSave: o
|
|
8416
8420
|
})).succeed || q($);
|
|
8417
8421
|
}
|
|
8418
|
-
}), /* @__PURE__ */ n(
|
|
8422
|
+
}), /* @__PURE__ */ n(It, {
|
|
8419
8423
|
icon: /* @__PURE__ */ n(jn, {}),
|
|
8420
8424
|
disabled: z,
|
|
8421
8425
|
tooltip: x("reports"),
|
|
@@ -8423,7 +8427,7 @@ function od({
|
|
|
8423
8427
|
onItemClick: async ($) => {
|
|
8424
8428
|
if (!$)
|
|
8425
8429
|
return;
|
|
8426
|
-
const P = await
|
|
8430
|
+
const P = await Tt({
|
|
8427
8431
|
onFormSave: o
|
|
8428
8432
|
});
|
|
8429
8433
|
!P.succeed || q({
|
|
@@ -8434,13 +8438,13 @@ function od({
|
|
|
8434
8438
|
}
|
|
8435
8439
|
});
|
|
8436
8440
|
}
|
|
8437
|
-
}), /* @__PURE__ */ n(
|
|
8441
|
+
}), /* @__PURE__ */ n(It, {
|
|
8438
8442
|
icon: /* @__PURE__ */ n(Hr, {}),
|
|
8439
8443
|
disabled: z,
|
|
8440
8444
|
tooltip: x("related"),
|
|
8441
8445
|
items: e == null ? void 0 : e.relate,
|
|
8442
8446
|
onItemClick: async ($) => {
|
|
8443
|
-
!$ || !(await
|
|
8447
|
+
!$ || !(await Tt({
|
|
8444
8448
|
onFormSave: o
|
|
8445
8449
|
})).succeed || R({
|
|
8446
8450
|
relateData: $,
|
|
@@ -8454,7 +8458,7 @@ function od({
|
|
|
8454
8458
|
disabled: z,
|
|
8455
8459
|
attachments: _,
|
|
8456
8460
|
onAddNewAttachment: async () => {
|
|
8457
|
-
const $ = await
|
|
8461
|
+
const $ = await Tt({
|
|
8458
8462
|
onFormSave: o
|
|
8459
8463
|
});
|
|
8460
8464
|
if (!$.succeed)
|
|
@@ -8473,7 +8477,7 @@ function od({
|
|
|
8473
8477
|
});
|
|
8474
8478
|
},
|
|
8475
8479
|
onListAllAttachments: async () => {
|
|
8476
|
-
const $ = await
|
|
8480
|
+
const $ = await Tt({
|
|
8477
8481
|
onFormSave: o
|
|
8478
8482
|
});
|
|
8479
8483
|
if (!$.succeed)
|
|
@@ -8486,7 +8490,7 @@ function od({
|
|
|
8486
8490
|
});
|
|
8487
8491
|
},
|
|
8488
8492
|
onViewAttachmentDetails: async ($) => {
|
|
8489
|
-
!(await
|
|
8493
|
+
!(await Tt({
|
|
8490
8494
|
onFormSave: o
|
|
8491
8495
|
})).succeed || V({
|
|
8492
8496
|
model: "ir.attachment",
|
|
@@ -8497,12 +8501,12 @@ function od({
|
|
|
8497
8501
|
})]
|
|
8498
8502
|
}) : null;
|
|
8499
8503
|
}
|
|
8500
|
-
function
|
|
8504
|
+
function St() {
|
|
8501
8505
|
return /* @__PURE__ */ n("div", {
|
|
8502
8506
|
className: "inline-block w-2"
|
|
8503
8507
|
});
|
|
8504
8508
|
}
|
|
8505
|
-
async function
|
|
8509
|
+
async function Tt({
|
|
8506
8510
|
onFormSave: e
|
|
8507
8511
|
}) {
|
|
8508
8512
|
const t = await (e == null ? void 0 : e());
|
|
@@ -8547,7 +8551,7 @@ const {
|
|
|
8547
8551
|
children: [l ? null : /* @__PURE__ */ n(ce, {
|
|
8548
8552
|
flex: "32px",
|
|
8549
8553
|
children: v ? /* @__PURE__ */ n(Ie, {
|
|
8550
|
-
icon: /* @__PURE__ */ n(
|
|
8554
|
+
icon: /* @__PURE__ */ n(kt, {}),
|
|
8551
8555
|
onClick: () => {
|
|
8552
8556
|
o(r) && (p(!1), g(!1));
|
|
8553
8557
|
},
|
|
@@ -8674,7 +8678,7 @@ const {
|
|
|
8674
8678
|
style: {
|
|
8675
8679
|
marginLeft: 15
|
|
8676
8680
|
},
|
|
8677
|
-
icon: /* @__PURE__ */ n(
|
|
8681
|
+
icon: /* @__PURE__ */ n(kt, {}),
|
|
8678
8682
|
htmlType: "submit",
|
|
8679
8683
|
type: "primary",
|
|
8680
8684
|
disabled: o,
|
|
@@ -8803,7 +8807,7 @@ function pn(e) {
|
|
|
8803
8807
|
} = ud();
|
|
8804
8808
|
function m() {
|
|
8805
8809
|
if ((o == null ? void 0 : o.type) === "form")
|
|
8806
|
-
return s ? u === 0 ? /* @__PURE__ */ H(
|
|
8810
|
+
return s ? u === 0 ? /* @__PURE__ */ H(Z, {
|
|
8807
8811
|
children: [f("editingDocument"), " (id:", " ", /* @__PURE__ */ n(Zt, {
|
|
8808
8812
|
copyable: {
|
|
8809
8813
|
icon: /* @__PURE__ */ n(Wn, {
|
|
@@ -8814,7 +8818,7 @@ function pn(e) {
|
|
|
8814
8818
|
},
|
|
8815
8819
|
children: s
|
|
8816
8820
|
}), ")"]
|
|
8817
|
-
}) : /* @__PURE__ */ H(
|
|
8821
|
+
}) : /* @__PURE__ */ H(Z, {
|
|
8818
8822
|
children: [f("register"), " ", a === void 0 ? 1 : a + 1, " /", " ", l.length, " ", f("of"), " ", u, " - ", f("editingDocument"), " (id:", " ", /* @__PURE__ */ n(Zt, {
|
|
8819
8823
|
copyable: !0,
|
|
8820
8824
|
children: s
|
|
@@ -8822,14 +8826,14 @@ function pn(e) {
|
|
|
8822
8826
|
}) : "";
|
|
8823
8827
|
if ((o == null ? void 0 : o.type) === "tree" && d) {
|
|
8824
8828
|
if (d.length === 1)
|
|
8825
|
-
return /* @__PURE__ */ H(
|
|
8829
|
+
return /* @__PURE__ */ H(Z, {
|
|
8826
8830
|
children: ["1 ", f("selectedRegisters"), " - (id:", " ", /* @__PURE__ */ n(Zt, {
|
|
8827
8831
|
copyable: !0,
|
|
8828
8832
|
children: d[0].id
|
|
8829
8833
|
}), ")"]
|
|
8830
8834
|
});
|
|
8831
8835
|
if (d.length > 1)
|
|
8832
|
-
return /* @__PURE__ */ H(
|
|
8836
|
+
return /* @__PURE__ */ H(Z, {
|
|
8833
8837
|
children: [d.length, " ", f("selectedRegisters"), /* @__PURE__ */ n(Zt, {
|
|
8834
8838
|
copyable: {
|
|
8835
8839
|
text: d.map((v) => v.id).join(", ")
|
|
@@ -8939,7 +8943,7 @@ const md = (e) => {
|
|
|
8939
8943
|
limit: M,
|
|
8940
8944
|
setLimit: w
|
|
8941
8945
|
});
|
|
8942
|
-
return !r || !t ? null : /* @__PURE__ */ H(
|
|
8946
|
+
return !r || !t ? null : /* @__PURE__ */ H(Z, {
|
|
8943
8947
|
children: [/* @__PURE__ */ n(pn, {
|
|
8944
8948
|
title: t.name,
|
|
8945
8949
|
children: /* @__PURE__ */ n(dd, {
|
|
@@ -8965,7 +8969,7 @@ const md = (e) => {
|
|
|
8965
8969
|
searchVisible: g,
|
|
8966
8970
|
searchValues: F,
|
|
8967
8971
|
showLimitOptions: !1
|
|
8968
|
-
}), N ? /* @__PURE__ */ n(
|
|
8972
|
+
}), N ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ n(hn, {
|
|
8969
8973
|
ref: u,
|
|
8970
8974
|
view_id: t.view_id,
|
|
8971
8975
|
model: i,
|
|
@@ -8990,7 +8994,7 @@ const md = (e) => {
|
|
|
8990
8994
|
setResults: c,
|
|
8991
8995
|
setCurrentItemIndex: m
|
|
8992
8996
|
} = e;
|
|
8993
|
-
return t ? /* @__PURE__ */ H(
|
|
8997
|
+
return t ? /* @__PURE__ */ H(Z, {
|
|
8994
8998
|
children: [/* @__PURE__ */ n(pn, {
|
|
8995
8999
|
children: /* @__PURE__ */ n(od, {
|
|
8996
9000
|
toolbar: a == null ? void 0 : a.toolbar
|
|
@@ -9116,7 +9120,7 @@ function yd(e) {
|
|
|
9116
9120
|
} = Y(gd), {
|
|
9117
9121
|
t: L,
|
|
9118
9122
|
lang: S
|
|
9119
|
-
} = Y(we), R = Y(
|
|
9123
|
+
} = Y(we), R = Y(Mt), {
|
|
9120
9124
|
processAction: V
|
|
9121
9125
|
} = R || {}, [E, D] = T(!1), k = y !== void 0 && y.trim().length > 0;
|
|
9122
9126
|
function N() {
|
|
@@ -9180,7 +9184,9 @@ function yd(e) {
|
|
|
9180
9184
|
}
|
|
9181
9185
|
return /* @__PURE__ */ H(je, {
|
|
9182
9186
|
wrap: !0,
|
|
9183
|
-
children: [
|
|
9187
|
+
children: [O && /* @__PURE__ */ H(Z, {
|
|
9188
|
+
children: [/* @__PURE__ */ n(Ae, {}), yt(), yt()]
|
|
9189
|
+
}), x ? null : /* @__PURE__ */ H(Z, {
|
|
9184
9190
|
children: [/* @__PURE__ */ n(pd, {
|
|
9185
9191
|
disabled: l || a || O,
|
|
9186
9192
|
searchText: y,
|
|
@@ -9200,7 +9206,7 @@ function yd(e) {
|
|
|
9200
9206
|
},
|
|
9201
9207
|
disabled: l || a || O,
|
|
9202
9208
|
badgeNumber: v == null ? void 0 : v.length
|
|
9203
|
-
}),
|
|
9209
|
+
}), yt(), /* @__PURE__ */ n(_o, {
|
|
9204
9210
|
disabled: O
|
|
9205
9211
|
}), /* @__PURE__ */ n(Ue, {
|
|
9206
9212
|
icon: /* @__PURE__ */ n(Wn, {}),
|
|
@@ -9214,7 +9220,7 @@ function yd(e) {
|
|
|
9214
9220
|
disabled: !(o && (o == null ? void 0 : o.length) > 0) || O,
|
|
9215
9221
|
loading: a,
|
|
9216
9222
|
onClick: N
|
|
9217
|
-
}),
|
|
9223
|
+
}), yt()]
|
|
9218
9224
|
}), /* @__PURE__ */ n(Ue, {
|
|
9219
9225
|
icon: /* @__PURE__ */ n(Yr, {}),
|
|
9220
9226
|
tooltip: L("showLogs"),
|
|
@@ -9232,8 +9238,8 @@ function yd(e) {
|
|
|
9232
9238
|
var q;
|
|
9233
9239
|
(q = f == null ? void 0 : f.current) == null || q.refreshResults();
|
|
9234
9240
|
}
|
|
9235
|
-
}), !x && /* @__PURE__ */ H(
|
|
9236
|
-
children: [
|
|
9241
|
+
}), !x && /* @__PURE__ */ H(Z, {
|
|
9242
|
+
children: [yt(), /* @__PURE__ */ n(Zn, {
|
|
9237
9243
|
currentView: r,
|
|
9238
9244
|
availableViews: t,
|
|
9239
9245
|
onChangeView: (q) => {
|
|
@@ -9242,7 +9248,7 @@ function yd(e) {
|
|
|
9242
9248
|
previousView: b,
|
|
9243
9249
|
disabled: O
|
|
9244
9250
|
})]
|
|
9245
|
-
}),
|
|
9251
|
+
}), yt(), /* @__PURE__ */ n(It, {
|
|
9246
9252
|
icon: /* @__PURE__ */ n(Bn, {}),
|
|
9247
9253
|
disabled: !(o && (o == null ? void 0 : o.length) > 0) || O,
|
|
9248
9254
|
tooltip: L("actions"),
|
|
@@ -9250,7 +9256,7 @@ function yd(e) {
|
|
|
9250
9256
|
onItemClick: (q) => {
|
|
9251
9257
|
!q || K(q);
|
|
9252
9258
|
}
|
|
9253
|
-
}), /* @__PURE__ */ n(
|
|
9259
|
+
}), /* @__PURE__ */ n(It, {
|
|
9254
9260
|
icon: /* @__PURE__ */ n(jn, {}),
|
|
9255
9261
|
disabled: !(o && (o == null ? void 0 : o.length) > 0) || O,
|
|
9256
9262
|
tooltip: L("reports"),
|
|
@@ -9264,8 +9270,8 @@ function yd(e) {
|
|
|
9264
9270
|
}
|
|
9265
9271
|
});
|
|
9266
9272
|
}
|
|
9267
|
-
}), C && /* @__PURE__ */ H(
|
|
9268
|
-
children: [
|
|
9273
|
+
}), C && /* @__PURE__ */ H(Z, {
|
|
9274
|
+
children: [yt(), /* @__PURE__ */ n(It, {
|
|
9269
9275
|
icon: /* @__PURE__ */ n(Mr, {
|
|
9270
9276
|
component: () => /* @__PURE__ */ H("svg", {
|
|
9271
9277
|
xmlns: "http://www.w3.org/2000/svg",
|
|
@@ -9335,7 +9341,7 @@ function yd(e) {
|
|
|
9335
9341
|
})]
|
|
9336
9342
|
});
|
|
9337
9343
|
}
|
|
9338
|
-
function
|
|
9344
|
+
function yt() {
|
|
9339
9345
|
return /* @__PURE__ */ n("div", {
|
|
9340
9346
|
className: "inline-block w-2"
|
|
9341
9347
|
});
|
|
@@ -9359,7 +9365,7 @@ const vd = (e) => {
|
|
|
9359
9365
|
currentView: p,
|
|
9360
9366
|
setPreviousView: h
|
|
9361
9367
|
} = Y(Xe);
|
|
9362
|
-
return t ? /* @__PURE__ */ H(
|
|
9368
|
+
return t ? /* @__PURE__ */ H(Z, {
|
|
9363
9369
|
children: [/* @__PURE__ */ n(pn, {
|
|
9364
9370
|
children: /* @__PURE__ */ n(yd, {
|
|
9365
9371
|
toolbar: a == null ? void 0 : a.toolbar,
|
|
@@ -9514,7 +9520,7 @@ function Td(e, t) {
|
|
|
9514
9520
|
setCurrentId: J,
|
|
9515
9521
|
tabs: pe,
|
|
9516
9522
|
activeKey: ye,
|
|
9517
|
-
openAction:
|
|
9523
|
+
openAction: ke,
|
|
9518
9524
|
onRemoveTab: de
|
|
9519
9525
|
} = se || {};
|
|
9520
9526
|
ki("ctrl+g,command+g", (te) => {
|
|
@@ -9526,19 +9532,19 @@ function Td(e, t) {
|
|
|
9526
9532
|
function Te(te) {
|
|
9527
9533
|
O(te), ee == null || ee(te);
|
|
9528
9534
|
}
|
|
9529
|
-
|
|
9535
|
+
bt(t, () => ({
|
|
9530
9536
|
canWeClose: Fe
|
|
9531
9537
|
}));
|
|
9532
9538
|
const be = async () => {
|
|
9533
9539
|
I(!0);
|
|
9534
9540
|
const te = [], ue = [];
|
|
9535
9541
|
for (const le of s) {
|
|
9536
|
-
const [De,
|
|
9537
|
-
|
|
9542
|
+
const [De, Re] = le;
|
|
9543
|
+
Re !== "dashboard" ? ue.push({
|
|
9538
9544
|
viewTuple: le,
|
|
9539
9545
|
promise: B.getHandler().getView({
|
|
9540
9546
|
model: i,
|
|
9541
|
-
type:
|
|
9547
|
+
type: Re,
|
|
9542
9548
|
id: De,
|
|
9543
9549
|
context: o
|
|
9544
9550
|
})
|
|
@@ -9551,12 +9557,12 @@ function Td(e, t) {
|
|
|
9551
9557
|
if (!le)
|
|
9552
9558
|
continue;
|
|
9553
9559
|
const [, De] = le.viewTuple;
|
|
9554
|
-
let
|
|
9560
|
+
let Re = le.info;
|
|
9555
9561
|
switch (De) {
|
|
9556
9562
|
case "dashboard": {
|
|
9557
9563
|
const tt = s.find((nt) => {
|
|
9558
|
-
const [,
|
|
9559
|
-
return
|
|
9564
|
+
const [, X] = nt;
|
|
9565
|
+
return X === "form";
|
|
9560
9566
|
});
|
|
9561
9567
|
let Ze;
|
|
9562
9568
|
tt && (Ze = {
|
|
@@ -9578,14 +9584,14 @@ function Td(e, t) {
|
|
|
9578
9584
|
}
|
|
9579
9585
|
case "form": {
|
|
9580
9586
|
te.push({
|
|
9581
|
-
...
|
|
9587
|
+
...Re,
|
|
9582
9588
|
type: De
|
|
9583
9589
|
});
|
|
9584
9590
|
break;
|
|
9585
9591
|
}
|
|
9586
9592
|
case "tree": {
|
|
9587
9593
|
te.push({
|
|
9588
|
-
...
|
|
9594
|
+
...Re,
|
|
9589
9595
|
isExpandable: h,
|
|
9590
9596
|
type: De
|
|
9591
9597
|
});
|
|
@@ -9593,7 +9599,7 @@ function Td(e, t) {
|
|
|
9593
9599
|
}
|
|
9594
9600
|
case "graph": {
|
|
9595
9601
|
te.push({
|
|
9596
|
-
...
|
|
9602
|
+
...Re,
|
|
9597
9603
|
type: De
|
|
9598
9604
|
});
|
|
9599
9605
|
break;
|
|
@@ -9641,7 +9647,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
9641
9647
|
xe = R[ue];
|
|
9642
9648
|
z(!1), W(!1);
|
|
9643
9649
|
const Pe = s.find((De) => De[1] === "form");
|
|
9644
|
-
|
|
9650
|
+
ke({
|
|
9645
9651
|
domain: [],
|
|
9646
9652
|
context: o,
|
|
9647
9653
|
model: i,
|
|
@@ -9718,7 +9724,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
9718
9724
|
Te(te);
|
|
9719
9725
|
}
|
|
9720
9726
|
}
|
|
9721
|
-
return A ? /* @__PURE__ */ n(
|
|
9727
|
+
return A ? /* @__PURE__ */ n(Ae, {}) : y ? /* @__PURE__ */ H(Qa, {
|
|
9722
9728
|
title: a,
|
|
9723
9729
|
currentView: y,
|
|
9724
9730
|
setCurrentView: Te,
|
|
@@ -9753,7 +9759,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
|
|
|
9753
9759
|
})]
|
|
9754
9760
|
}) : null;
|
|
9755
9761
|
}
|
|
9756
|
-
const Ao =
|
|
9762
|
+
const Ao = wt(Td);
|
|
9757
9763
|
async function Fd({
|
|
9758
9764
|
actionId: e,
|
|
9759
9765
|
rootContext: t = {},
|
|
@@ -9762,7 +9768,7 @@ async function Fd({
|
|
|
9762
9768
|
const i = "ir.actions.act_window", o = `${i},${e}`, s = await B.getHandler().getActionData({
|
|
9763
9769
|
action: o,
|
|
9764
9770
|
context: t
|
|
9765
|
-
}), a =
|
|
9771
|
+
}), a = vt({
|
|
9766
9772
|
context: s.context,
|
|
9767
9773
|
values: r,
|
|
9768
9774
|
fields: {}
|
|
@@ -9921,8 +9927,8 @@ function kd(e) {
|
|
|
9921
9927
|
}, q = async () => {
|
|
9922
9928
|
const J = K.current.length > 0 ? K.current : s, pe = fn(M.current, J), {
|
|
9923
9929
|
colors: ye
|
|
9924
|
-
} =
|
|
9925
|
-
totalItems:
|
|
9930
|
+
} = Ot(p), {
|
|
9931
|
+
totalItems: ke,
|
|
9926
9932
|
results: de,
|
|
9927
9933
|
attrsEvaluated: oe
|
|
9928
9934
|
} = await B.getHandler().searchForTree({
|
|
@@ -9937,7 +9943,7 @@ function kd(e) {
|
|
|
9937
9943
|
}
|
|
9938
9944
|
});
|
|
9939
9945
|
S(Xt(oe));
|
|
9940
|
-
const Te =
|
|
9946
|
+
const Te = _t({
|
|
9941
9947
|
resultsToSort: de,
|
|
9942
9948
|
sorter: R,
|
|
9943
9949
|
fields: {
|
|
@@ -9946,7 +9952,7 @@ function kd(e) {
|
|
|
9946
9952
|
}
|
|
9947
9953
|
});
|
|
9948
9954
|
W(!1), C(Te);
|
|
9949
|
-
const be = await
|
|
9955
|
+
const be = await ke;
|
|
9950
9956
|
x(be);
|
|
9951
9957
|
}, $ = async () => {
|
|
9952
9958
|
try {
|
|
@@ -10024,7 +10030,7 @@ function kd(e) {
|
|
|
10024
10030
|
sorter: R,
|
|
10025
10031
|
onChangeSort: (J) => {
|
|
10026
10032
|
V == null || V(J);
|
|
10027
|
-
const pe =
|
|
10033
|
+
const pe = _t({
|
|
10028
10034
|
resultsToSort: F,
|
|
10029
10035
|
sorter: J,
|
|
10030
10036
|
fields: {
|
|
@@ -10042,7 +10048,7 @@ function kd(e) {
|
|
|
10042
10048
|
message: k,
|
|
10043
10049
|
type: "error",
|
|
10044
10050
|
banner: !0
|
|
10045
|
-
}) : u ? /* @__PURE__ */ n(
|
|
10051
|
+
}) : u ? /* @__PURE__ */ n(Ae, {
|
|
10046
10052
|
style: {
|
|
10047
10053
|
padding: "2rem"
|
|
10048
10054
|
}
|
|
@@ -10089,7 +10095,7 @@ function Md(e, t) {
|
|
|
10089
10095
|
} = Y(Xn), h = me(), g = me();
|
|
10090
10096
|
ge(() => {
|
|
10091
10097
|
y();
|
|
10092
|
-
}, [r, o, i]),
|
|
10098
|
+
}, [r, o, i]), bt(t, () => ({
|
|
10093
10099
|
refresh: () => {
|
|
10094
10100
|
y();
|
|
10095
10101
|
},
|
|
@@ -10281,12 +10287,12 @@ function Md(e, t) {
|
|
|
10281
10287
|
const [ee, J] = se, {
|
|
10282
10288
|
actionId: pe,
|
|
10283
10289
|
actionType: ye,
|
|
10284
|
-
title:
|
|
10290
|
+
title: ke,
|
|
10285
10291
|
model: de
|
|
10286
10292
|
} = F, oe = {
|
|
10287
10293
|
action_id: pe,
|
|
10288
10294
|
action_type: ye,
|
|
10289
|
-
name:
|
|
10295
|
+
name: ke,
|
|
10290
10296
|
res_id: ie.id,
|
|
10291
10297
|
res_model: de,
|
|
10292
10298
|
view_id: ee,
|
|
@@ -10349,7 +10355,7 @@ function Md(e, t) {
|
|
|
10349
10355
|
})
|
|
10350
10356
|
});
|
|
10351
10357
|
}
|
|
10352
|
-
const Ed =
|
|
10358
|
+
const Ed = wt(Md), $d = (e) => /* @__PURE__ */ n(ve, {
|
|
10353
10359
|
...e,
|
|
10354
10360
|
children: /* @__PURE__ */ n(Ld, {
|
|
10355
10361
|
...e
|
|
@@ -10393,7 +10399,7 @@ const Ed = vt(Md), $d = (e) => /* @__PURE__ */ n(ve, {
|
|
|
10393
10399
|
} = r, y = Y(Ee), {
|
|
10394
10400
|
getContext: O
|
|
10395
10401
|
} = y || {};
|
|
10396
|
-
|
|
10402
|
+
Ct(() => {
|
|
10397
10403
|
b();
|
|
10398
10404
|
}, [o]);
|
|
10399
10405
|
const _ = (w) => {
|
|
@@ -10407,7 +10413,7 @@ const Ed = vt(Md), $d = (e) => /* @__PURE__ */ n(ve, {
|
|
|
10407
10413
|
if (r.domain) {
|
|
10408
10414
|
const x = await B.getHandler().evalDomain({
|
|
10409
10415
|
domain: r.domain,
|
|
10410
|
-
values:
|
|
10416
|
+
values: Rt({
|
|
10411
10417
|
fields: y == null ? void 0 : y.getFields(),
|
|
10412
10418
|
values: y.getPlainValues()
|
|
10413
10419
|
}),
|
|
@@ -10466,7 +10472,7 @@ const Ed = vt(Md), $d = (e) => /* @__PURE__ */ n(ve, {
|
|
|
10466
10472
|
});
|
|
10467
10473
|
}), _(x);
|
|
10468
10474
|
};
|
|
10469
|
-
return f && a.length === 0 ? /* @__PURE__ */ n(
|
|
10475
|
+
return f && a.length === 0 ? /* @__PURE__ */ n(Ae, {}) : /* @__PURE__ */ n(Z, {
|
|
10470
10476
|
children: /* @__PURE__ */ H("div", {
|
|
10471
10477
|
className: "flex flex-row",
|
|
10472
10478
|
children: [/* @__PURE__ */ n(Lt.Group, {
|
|
@@ -10666,7 +10672,7 @@ function Xd(e, t) {
|
|
|
10666
10672
|
closable: !0,
|
|
10667
10673
|
content: /* @__PURE__ */ n(Zd, {})
|
|
10668
10674
|
}]), f = me(/* @__PURE__ */ new Map()), c = me();
|
|
10669
|
-
|
|
10675
|
+
bt(t, () => ({
|
|
10670
10676
|
retrieveAndOpenAction: p,
|
|
10671
10677
|
openShortcut: y
|
|
10672
10678
|
}));
|
|
@@ -10699,7 +10705,7 @@ function Xd(e, t) {
|
|
|
10699
10705
|
Ye("Action type not supported");
|
|
10700
10706
|
return;
|
|
10701
10707
|
}
|
|
10702
|
-
const [C, L] = b.split(","), S = parseInt(L), R =
|
|
10708
|
+
const [C, L] = b.split(","), S = parseInt(L), R = vt({
|
|
10703
10709
|
context: F.context,
|
|
10704
10710
|
values: i,
|
|
10705
10711
|
fields: {}
|
|
@@ -10806,7 +10812,7 @@ function Xd(e, t) {
|
|
|
10806
10812
|
} = b, [E, D] = L[0], k = {
|
|
10807
10813
|
id: E,
|
|
10808
10814
|
type: D
|
|
10809
|
-
}, N =
|
|
10815
|
+
}, N = vt({
|
|
10810
10816
|
context: F,
|
|
10811
10817
|
values: {
|
|
10812
10818
|
...I,
|
|
@@ -10815,7 +10821,7 @@ function Xd(e, t) {
|
|
|
10815
10821
|
fields: A
|
|
10816
10822
|
}), j = C ? await B.getHandler().evalDomain({
|
|
10817
10823
|
domain: C,
|
|
10818
|
-
values:
|
|
10824
|
+
values: Rt({
|
|
10819
10825
|
fields: A,
|
|
10820
10826
|
values: {
|
|
10821
10827
|
...I,
|
|
@@ -10853,7 +10859,7 @@ function Xd(e, t) {
|
|
|
10853
10859
|
} = b, x = `${I},${A}`, F = await B.getHandler().getActionData({
|
|
10854
10860
|
action: x,
|
|
10855
10861
|
context: o
|
|
10856
|
-
}), C =
|
|
10862
|
+
}), C = vt({
|
|
10857
10863
|
context: F.context,
|
|
10858
10864
|
values: i,
|
|
10859
10865
|
fields: {}
|
|
@@ -11040,7 +11046,7 @@ function Xd(e, t) {
|
|
|
11040
11046
|
})
|
|
11041
11047
|
});
|
|
11042
11048
|
}
|
|
11043
|
-
const Iu =
|
|
11049
|
+
const Iu = wt(Xd), {
|
|
11044
11050
|
useToken: Qd
|
|
11045
11051
|
} = $e;
|
|
11046
11052
|
function eu(e) {
|
|
@@ -11114,7 +11120,7 @@ function Du() {
|
|
|
11114
11120
|
onRemoveTab: i,
|
|
11115
11121
|
onChangeTab: o
|
|
11116
11122
|
} = e || {};
|
|
11117
|
-
return /* @__PURE__ */ n(
|
|
11123
|
+
return /* @__PURE__ */ n(Z, {
|
|
11118
11124
|
children: r.map((s) => /* @__PURE__ */ n(eu, {
|
|
11119
11125
|
tabKey: s.key,
|
|
11120
11126
|
label: s.title,
|
|
@@ -11144,7 +11150,7 @@ function Vu() {
|
|
|
11144
11150
|
} = e || {}, r = (t == null ? void 0 : t.map((i) => /* @__PURE__ */ n(nu, {
|
|
11145
11151
|
tab: i
|
|
11146
11152
|
}, i.key))) || null;
|
|
11147
|
-
return /* @__PURE__ */ n(
|
|
11153
|
+
return /* @__PURE__ */ n(Z, {
|
|
11148
11154
|
children: r
|
|
11149
11155
|
});
|
|
11150
11156
|
}
|
|
@@ -11250,11 +11256,11 @@ const {
|
|
|
11250
11256
|
})
|
|
11251
11257
|
})
|
|
11252
11258
|
})]
|
|
11253
|
-
}), /* @__PURE__ */ n(Le.Divider, {}), c ? /* @__PURE__ */ n(
|
|
11259
|
+
}), /* @__PURE__ */ n(Le.Divider, {}), c ? /* @__PURE__ */ n(Ae, {
|
|
11254
11260
|
style: {
|
|
11255
11261
|
padding: "1rem"
|
|
11256
11262
|
}
|
|
11257
|
-
}) : d.length > 0 ? /* @__PURE__ */ n(
|
|
11263
|
+
}) : d.length > 0 ? /* @__PURE__ */ n(Z, {
|
|
11258
11264
|
children: d.map((E) => /* @__PURE__ */ n(Le.Item, {
|
|
11259
11265
|
children: /* @__PURE__ */ n(R, {
|
|
11260
11266
|
title: E.name,
|
|
@@ -11312,7 +11318,7 @@ const {
|
|
|
11312
11318
|
}
|
|
11313
11319
|
await w(), a(!s);
|
|
11314
11320
|
}
|
|
11315
|
-
return /* @__PURE__ */ H(
|
|
11321
|
+
return /* @__PURE__ */ H(Z, {
|
|
11316
11322
|
children: [/* @__PURE__ */ n(Ie, {
|
|
11317
11323
|
type: s ? "primary" : "default",
|
|
11318
11324
|
icon: s ? /* @__PURE__ */ n(Nr, {
|
|
@@ -11336,7 +11342,7 @@ const {
|
|
|
11336
11342
|
borderTopLeftRadius: 0,
|
|
11337
11343
|
borderBottomLeftRadius: 0
|
|
11338
11344
|
},
|
|
11339
|
-
icon: /* @__PURE__ */ n(
|
|
11345
|
+
icon: /* @__PURE__ */ n(At, {
|
|
11340
11346
|
style: {
|
|
11341
11347
|
fontSize: "0.5em"
|
|
11342
11348
|
}
|