@gisce/react-ooui 2.51.0 → 2.51.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -4,11 +4,11 @@ var ko = (e, t, n) => (Ja(e, typeof t != "symbol" ? t + "" : t, n), n);
4
4
  import { jsx as i, jsxs as D, Fragment as ae } from "react/jsx-runtime";
5
5
  import pt, { useContext as te, useState as x, useEffect as le, useRef as Y, memo as yt, useCallback as P, useMemo as oe, createContext as Qa, forwardRef as wt, useImperativeHandle as bt, createElement as Xa, Fragment as Rn } from "react";
6
6
  import { Tooltip as Rt, theme as We, Typography as kt, Form as ht, Row as je, Col as Ce, Modal as dt, Button as He, Dropdown as Za, Menu as $o, Spin as Ke, Divider as Qn, Space as Xe, Input as rt, Select as Gt, Checkbox as Cn, Alert as ot, Timeline as ji, Empty as Bi, Statistic as el, Card as Jr, Tag as Qr, message as wr, App as tl, Progress as nl, Avatar as Hi, DatePicker as Xr, TimePicker as rl, InputNumber as Xn, Layout as Ui, Badge as Zn, Pagination as ol, Tabs as Wi, Radio as No, Switch as il, Steps as Mo, Carousel as sl } from "antd";
7
- import { Label as un, Field as Er, Tree as Gi, Reference as al, Selection as Zr, Many2one as Ki, Boolean as ll, parseContext as jt, graphProcessor as qi, graphFieldUtils as cl, parseGraph as Yi, Container as dl, Form as zi, parseContextFields as ul, parseDomainFields as fl, Integer as Dr, SearchFieldTypes as Vt, SearchFilter as Ji, transformDomainForChildWidget as eo, Button as ml } from "@gisce/ooui";
7
+ import { Label as un, Field as Vr, Tree as Gi, Reference as al, Selection as Zr, Many2one as Ki, Boolean as ll, parseContext as jt, graphProcessor as qi, graphFieldUtils as cl, parseGraph as Yi, Container as dl, Form as zi, parseContextFields as ul, parseDomainFields as fl, Integer as Dr, SearchFieldTypes as Et, SearchFilter as Ji, transformDomainForChildWidget as eo, Button as ml } from "@gisce/ooui";
8
8
  import * as Lo from "@ant-design/icons";
9
9
  import Qi, { QuestionCircleOutlined as Xi, ExclamationCircleOutlined as $t, LoadingOutlined as St, DownOutlined as er, WarningOutlined as Zi, CloseOutlined as fn, CheckOutlined as tr, TranslationOutlined as es, FolderOpenOutlined as to, DownloadOutlined as no, ClearOutlined as nr, InfoCircleOutlined as ro, ExportOutlined as pl, StarFilled as hl, StarOutlined as gl, ThunderboltOutlined as oo, PrinterOutlined as io, EnterOutlined as so, SearchOutlined as rr, UpOutlined as yl, PlusSquareOutlined as vl, MinusSquareOutlined as wl, FileAddOutlined as or, AlignLeftOutlined as bl, ApiOutlined as Sl, DeleteOutlined as ao, LeftOutlined as ts, RightOutlined as ns, EyeOutlined as Cl, FormOutlined as xn, TableOutlined as lo, AreaChartOutlined as xl, CalendarOutlined as Il, LinkOutlined as jo, SaveOutlined as Tl, CopyOutlined as co, ReloadOutlined as ir, EditOutlined as rs, PlusOutlined as Al, FilterOutlined as os, CloseCircleFilled as Ol, BorderOuterOutlined as Fl, SettingOutlined as Rl } from "@ant-design/icons";
10
10
  import { Interweave as In } from "interweave";
11
- import { useLocale as fe, FormigaConfigProvider as _l, mergeStrings as Vl, Many2OneSuffix as El, Many2OneSuffixModal as Bo, FieldSet as Dl, ExportModal as Pl, Dropdown as is, DropdownButton as rn, HTMLPreview as kl, FavouriteButton as $l } from "@gisce/react-formiga-components";
11
+ import { useLocale as fe, FormigaConfigProvider as _l, mergeStrings as El, Many2OneSuffix as Vl, Many2OneSuffixModal as Bo, FieldSet as Dl, ExportModal as Pl, Dropdown as is, DropdownButton as rn, HTMLPreview as kl, FavouriteButton as $l } from "@gisce/react-formiga-components";
12
12
  import * as Ho from "@tabler/icons-react";
13
13
  import Nl from "antd/lib/input/TextArea";
14
14
  import ut from "styled-components";
@@ -326,13 +326,25 @@ function Go(e, t) {
326
326
  var l;
327
327
  return pt.createElement(Ho[o], {
328
328
  fill: "transparent",
329
+ // eslint-disable-next-line react/prop-types
329
330
  size: ((l = t == null ? void 0 : t.style) == null ? void 0 : l.fontSize) || 17
330
331
  });
331
332
  };
332
- return () => pt.createElement(Qi, {
333
- component: s,
334
- ...t
335
- });
333
+ return () => (
334
+ // eslint-disable-next-line react/no-children-prop
335
+ pt.createElement("span", {
336
+ style: {
337
+ display: "inline-flex",
338
+ alignItems: "center",
339
+ lineHeight: "1",
340
+ verticalAlign: "middle"
341
+ },
342
+ children: pt.createElement(Qi, {
343
+ component: s,
344
+ ...t
345
+ })
346
+ })
347
+ );
336
348
  }
337
349
  }
338
350
  const mo = (e) => {
@@ -422,7 +434,7 @@ const mo = (e) => {
422
434
  if (t.buttons.length === 0)
423
435
  return null;
424
436
  if (t.buttons.length > 1)
425
- return /* @__PURE__ */ i(_e, { ooui: new Er({ defaultButton: n }), children: /* @__PURE__ */ D(
437
+ return /* @__PURE__ */ i(_e, { ooui: new Vr({ defaultButton: n }), children: /* @__PURE__ */ D(
426
438
  Za.Button,
427
439
  {
428
440
  disabled: !a || p,
@@ -579,22 +591,22 @@ const ds = (e) => {
579
591
  params: [["translatable", "=", "1"]],
580
592
  fieldsToRetrieve: ["code", "name"],
581
593
  model: "res.lang"
582
- })).map((V) => ({
583
- code: V.code,
584
- name: V.name
594
+ })).map((E) => ({
595
+ code: E.code,
596
+ name: E.name
585
597
  }));
586
598
  return f == null || f(b), b;
587
599
  }
588
600
  async function C(R) {
589
601
  const b = {};
590
- for (const V of R) {
602
+ for (const E of R) {
591
603
  const F = (await N.getHandler().readObjects({
592
604
  model: r,
593
605
  ids: [o],
594
606
  fieldsToRetrieve: [s],
595
- context: { lang: V.code }
607
+ context: { lang: E.code }
596
608
  }))[0];
597
- b[V.code] = F[s] || "";
609
+ b[E.code] = F[s] || "";
598
610
  }
599
611
  v.current = b, y(b);
600
612
  }
@@ -606,10 +618,10 @@ const ds = (e) => {
606
618
  {
607
619
  rows: 4,
608
620
  value: g[R.code] || "",
609
- onChange: (V) => {
621
+ onChange: (E) => {
610
622
  y({
611
623
  ...g,
612
- [R.code]: V.target.value
624
+ [R.code]: E.target.value
613
625
  });
614
626
  },
615
627
  disabled: h
@@ -735,9 +747,7 @@ const fs = (e) => {
735
747
  const o = te(Ue), { elementHasLostFocus: s } = o || {}, { readOnly: a, isPassword: l, translatable: c, required: u } = t, f = oe(() => e && (t.selectionValues.size ? t.selectionValues.get(e) : Array.isArray(e) ? e[1] : e), [t.selectionValues, e]), d = oe(
736
748
  () => u && !a,
737
749
  [u, a]
738
- );
739
- t._id === "name" && console.log({ value: e }), console.log({ isRequired: d });
740
- const p = oe(
750
+ ), p = oe(
741
751
  () => Array.isArray(e) || !!t.selectionValues.size,
742
752
  [e, t.selectionValues]
743
753
  ), h = P(
@@ -747,7 +757,7 @@ const fs = (e) => {
747
757
  [r]
748
758
  );
749
759
  if (l) {
750
- const g = d ? Ec : rt.Password;
760
+ const g = d ? Vc : rt.Password;
751
761
  return /* @__PURE__ */ i(
752
762
  An,
753
763
  {
@@ -807,7 +817,7 @@ const ps = yt(
807
817
  d(!1);
808
818
  }, []), I = P(() => {
809
819
  d(!1), l == null || l();
810
- }, [l]), C = g ? Vc : _c;
820
+ }, [l]), C = g ? Ec : _c;
811
821
  return s ? /* @__PURE__ */ D(ae, { children: [
812
822
  /* @__PURE__ */ i("div", { onClick: v, children: /* @__PURE__ */ i(
813
823
  An,
@@ -862,7 +872,7 @@ const _c = ut(rt)`
862
872
  cursor: ${(e) => e.disabled ? "pointer" : "text"};
863
873
  pointer-events: ${(e) => e.disabled ? "none" : "auto"};
864
874
  }
865
- `, Vc = ut(rt)`
875
+ `, Ec = ut(rt)`
866
876
  &.ant-input {
867
877
  background-color: ${po.colorPrimaryBg};
868
878
  cursor: pointer;
@@ -872,7 +882,7 @@ const _c = ut(rt)`
872
882
  &.ant-input {
873
883
  background-color: ${po.colorPrimaryBg};
874
884
  }
875
- `, Ec = ut(rt.Password)`
885
+ `, Vc = ut(rt.Password)`
876
886
  &.ant-input-affix-wrapper {
877
887
  background-color: ${po.colorPrimaryBg};
878
888
  }
@@ -1042,7 +1052,7 @@ const ho = (e) => {
1042
1052
  }
1043
1053
  }
1044
1054
  );
1045
- }, Et = (e) => {
1055
+ }, Vt = (e) => {
1046
1056
  const t = e.arch, n = e.fields, r = new Gi(n);
1047
1057
  return r.parse(t), r;
1048
1058
  };
@@ -1149,7 +1159,7 @@ const yo = async (e) => {
1149
1159
  };
1150
1160
  let d = [], p;
1151
1161
  if (a === "tree" && (o != null && o.arch)) {
1152
- const y = (g = Et(o)) == null ? void 0 : g.colors, v = await N.getHandler().readEvalUiObjects({
1162
+ const y = (g = Vt(o)) == null ? void 0 : g.colors, v = await N.getHandler().readEvalUiObjects({
1153
1163
  model: n,
1154
1164
  ids: u,
1155
1165
  arch: o == null ? void 0 : o.arch,
@@ -1493,7 +1503,7 @@ const Kt = ({
1493
1503
  return /* @__PURE__ */ i(ot, { className: "mt-10", message: c, type: "error", banner: !0 });
1494
1504
  if (a)
1495
1505
  return /* @__PURE__ */ i(Ke, {});
1496
- const V = (O) => {
1506
+ const E = (O) => {
1497
1507
  const k = ft(O);
1498
1508
  return k && /* @__PURE__ */ i(k, {});
1499
1509
  }, F = S.map((O) => {
@@ -1512,7 +1522,7 @@ const Kt = ({
1512
1522
  }
1513
1523
  )
1514
1524
  };
1515
- return (L = O.values) != null && L[I] && (k.dot = V(O.values[I])), (W = O.values) != null && W[C] && (k.color = !ls(O.values[C]) && !cs(O.values[C]) && !O.values[C].toString().startsWith("#") ? _n(O.values[C]) : O.values[C]), k;
1525
+ return (L = O.values) != null && L[I] && (k.dot = E(O.values[I])), (W = O.values) != null && W[C] && (k.color = !ls(O.values[C]) && !cs(O.values[C]) && !O.values[C].toString().startsWith("#") ? _n(O.values[C]) : O.values[C]), k;
1516
1526
  });
1517
1527
  return /* @__PURE__ */ D(ae, { children: [
1518
1528
  /* @__PURE__ */ i(ji, { style: { padding: "1rem" }, items: F }),
@@ -1885,7 +1895,7 @@ const Kt = ({
1885
1895
  _l,
1886
1896
  {
1887
1897
  locale: t,
1888
- localizedStrings: Vl(yd, n),
1898
+ localizedStrings: El(yd, n),
1889
1899
  children: a
1890
1900
  }
1891
1901
  ) });
@@ -1997,7 +2007,7 @@ const bd = (e) => {
1997
2007
  }
1998
2008
  o(!1);
1999
2009
  } };
2000
- }, Vn = () => /* @__PURE__ */ i(
2010
+ }, En = () => /* @__PURE__ */ i(
2001
2011
  "div",
2002
2012
  {
2003
2013
  style: {
@@ -2231,7 +2241,7 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2231
2241
  operator: f,
2232
2242
  manualIds: d,
2233
2243
  fixedHeight: p
2234
- } = e, [h, m] = x(!1), [g, y] = x(), [v, w] = x(0), [I, C] = x(), [S, A] = x(), [T, R] = x(), [b, V] = x(), [F] = Ye(
2244
+ } = e, [h, m] = x(!1), [g, y] = x(), [v, w] = x(0), [I, C] = x(), [S, A] = x(), [T, R] = x(), [b, E] = x(), [F] = Ye(
2235
2245
  N.getHandler().searchAllIds
2236
2246
  ), [O] = Ye(
2237
2247
  N.getHandler().readObjects
@@ -2246,14 +2256,14 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2246
2256
  B();
2247
2257
  }, [t, o]);
2248
2258
  async function L({
2249
- domain: E,
2259
+ domain: V,
2250
2260
  isTotal: Z
2251
2261
  }) {
2252
2262
  if (Z)
2253
- return await W({ domain: E });
2263
+ return await W({ domain: V });
2254
2264
  if (u && f) {
2255
2265
  const ne = d || await F({
2256
- params: E,
2266
+ params: V,
2257
2267
  model: t,
2258
2268
  context: r
2259
2269
  }), Q = await O({
@@ -2269,14 +2279,14 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2269
2279
  } else
2270
2280
  return d ? d.length : await k({
2271
2281
  model: t,
2272
- params: E,
2282
+ params: V,
2273
2283
  context: r
2274
2284
  });
2275
2285
  }
2276
- async function W({ domain: E }) {
2286
+ async function W({ domain: V }) {
2277
2287
  if (u && f) {
2278
2288
  const Z = await F({
2279
- params: E,
2289
+ params: V,
2280
2290
  model: t,
2281
2291
  context: r
2282
2292
  }), ne = await O({
@@ -2292,13 +2302,13 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2292
2302
  } else
2293
2303
  return await k({
2294
2304
  model: t,
2295
- params: E,
2305
+ params: V,
2296
2306
  context: r
2297
2307
  });
2298
2308
  }
2299
2309
  async function B() {
2300
- m(!0), V(void 0);
2301
- let E, Z;
2310
+ m(!0), E(void 0);
2311
+ let V, Z;
2302
2312
  try {
2303
2313
  const ne = await L({ domain: n, isTotal: !1 });
2304
2314
  if (y(ne), s) {
@@ -2307,12 +2317,12 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2307
2317
  values: {},
2308
2318
  context: r
2309
2319
  });
2310
- E = await L({
2320
+ V = await L({
2311
2321
  domain: Q,
2312
2322
  isTotal: !0
2313
- }), C(E);
2323
+ }), C(V);
2314
2324
  }
2315
- if (E ? (Z = Math.round(ne / E * 100 * 100) / 100, w(Z)) : w(0), o) {
2325
+ if (V ? (Z = Math.round(ne / V * 100 * 100) / 100, w(Z)) : w(0), o) {
2316
2326
  const Q = await $({
2317
2327
  condition: o,
2318
2328
  values: { value: ne, percent: Z },
@@ -2330,13 +2340,13 @@ const { getValueForOperator: Qo } = qi, xd = (e) => {
2330
2340
  R(Q);
2331
2341
  } else
2332
2342
  R(l);
2333
- V(void 0);
2343
+ E(void 0);
2334
2344
  } catch (ne) {
2335
- V(JSON.stringify(ne));
2345
+ E(JSON.stringify(ne));
2336
2346
  }
2337
2347
  m(!1);
2338
2348
  }
2339
- return h ? /* @__PURE__ */ i(Vn, {}) : b ? /* @__PURE__ */ i(ot, { className: "mt-10", message: b, type: "error", banner: !0 }) : /* @__PURE__ */ i(
2349
+ return h ? /* @__PURE__ */ i(En, {}) : b ? /* @__PURE__ */ i(ot, { className: "mt-10", message: b, type: "error", banner: !0 }) : /* @__PURE__ */ i(
2340
2350
  As,
2341
2351
  {
2342
2352
  value: g,
@@ -2511,7 +2521,7 @@ const Sr = (e) => (t) => {
2511
2521
  useGrouping: !0
2512
2522
  });
2513
2523
  if (_d(e)) {
2514
- const t = Vd(e);
2524
+ const t = Ed(e);
2515
2525
  return t === null ? e : at(e, Yn.input[t]).format(
2516
2526
  Yn.output[t]
2517
2527
  );
@@ -2611,7 +2621,7 @@ const Yn = {
2611
2621
  years: "YYYY"
2612
2622
  }
2613
2623
  };
2614
- function Vd(e) {
2624
+ function Ed(e) {
2615
2625
  for (const t in Yn.input)
2616
2626
  if (at(
2617
2627
  e,
@@ -2621,7 +2631,7 @@ function Vd(e) {
2621
2631
  return t;
2622
2632
  return null;
2623
2633
  }
2624
- const Ed = {
2634
+ const Vd = {
2625
2635
  inner: {
2626
2636
  label: {
2627
2637
  type: "inner",
@@ -2740,7 +2750,7 @@ function Md(e) {
2740
2750
  fixedHeight: c
2741
2751
  } = e;
2742
2752
  let u = { ...Xo[t] };
2743
- if (u || (u = { ...Xo.default }), u.data = n, u.height = c, t === "pie" ? (u.colorField = "x", u.angleField = "value", u = { ...u, ...Ed.inner }, u.legend.itemValue = s, u.label.content = a) : (u.xField = "x", u.yField = "value", u.seriesField = "type", u.isGroup = r, o && (u.isStack = !0, u.groupField = "stacked")), t === "line" && l.mode === "auto" && l.valueOpts) {
2753
+ if (u || (u = { ...Xo.default }), u.data = n, u.height = c, t === "pie" ? (u.colorField = "x", u.angleField = "value", u = { ...u, ...Vd.inner }, u.legend.itemValue = s, u.label.content = a) : (u.xField = "x", u.yField = "value", u.seriesField = "type", u.isGroup = r, o && (u.isStack = !0, u.groupField = "stacked")), t === "line" && l.mode === "auto" && l.valueOpts) {
2744
2754
  const f = l.valueOpts.min, d = l.valueOpts.max;
2745
2755
  u.yAxis = {
2746
2756
  min: f,
@@ -2770,7 +2780,7 @@ const Ld = ({
2770
2780
  if (Tt(() => {
2771
2781
  h();
2772
2782
  }, [e, t, o, r, n]), u || !f)
2773
- return /* @__PURE__ */ i(Vn, {});
2783
+ return /* @__PURE__ */ i(En, {});
2774
2784
  const { data: m, isGroup: g, isStack: y, yAxisOpts: v } = f;
2775
2785
  return c ? /* @__PURE__ */ i(ot, { message: c, type: "error", banner: !0 }) : /* @__PURE__ */ i(
2776
2786
  _s,
@@ -2813,8 +2823,8 @@ const Ld = ({
2813
2823
  setSearchTreeNameSearch: T,
2814
2824
  goToResourceId: R,
2815
2825
  limit: b,
2816
- isActive: V
2817
- } = e, [F, O] = x(!1), [k, _] = x(!1), [$, L] = x(!1), [W, B] = x(!0), [E, Z] = x(!0), [ne, Q] = x([]), [H, re] = x(!1), [ee, G] = x([]), [M, j] = x(!1), [ge, z] = x(!0), [J, ie] = x(), [me, ke] = x({}), [$e, Ee] = x(0), [Ne, Be] = x(), [Oe, de] = x(!1), [xe, ue] = x(
2826
+ isActive: E
2827
+ } = e, [F, O] = x(!1), [k, _] = x(!1), [$, L] = x(!1), [W, B] = x(!0), [V, Z] = x(!0), [ne, Q] = x([]), [H, re] = x(!1), [ee, G] = x([]), [M, j] = x(!1), [ge, z] = x(!0), [J, ie] = x(), [me, ke] = x({}), [$e, Ve] = x(0), [Ne, Be] = x(), [Oe, de] = x(!1), [xe, ue] = x(
2818
2828
  b !== void 0 ? b : Pt
2819
2829
  ), [Fe, q] = x(r);
2820
2830
  le(() => {
@@ -2865,7 +2875,7 @@ const Ld = ({
2865
2875
  setRemovingItem: L,
2866
2876
  formIsLoading: W,
2867
2877
  setFormIsLoading: B,
2868
- treeIsLoading: E,
2878
+ treeIsLoading: V,
2869
2879
  setTreeIsLoading: Z,
2870
2880
  attachments: ne,
2871
2881
  setAttachments: Q,
@@ -2893,8 +2903,8 @@ const Ld = ({
2893
2903
  limit: xe,
2894
2904
  setLimit: ue,
2895
2905
  setTitle: q,
2896
- isActive: V,
2897
- setTreeFirstVisibleRow: Ee,
2906
+ isActive: E,
2907
+ setTreeFirstVisibleRow: Ve,
2898
2908
  treeFirstVisibleRow: $e,
2899
2909
  searchQuery: Ne,
2900
2910
  setSearchQuery: Be,
@@ -3019,7 +3029,7 @@ const Ld = ({
3019
3029
  }
3020
3030
  }
3021
3031
  if (u || !d)
3022
- return /* @__PURE__ */ i(Vn, {});
3032
+ return /* @__PURE__ */ i(En, {});
3023
3033
  switch (d.type) {
3024
3034
  case "indicatorField":
3025
3035
  case "indicator": {
@@ -3107,7 +3117,7 @@ const rv = Object.values(pn), Ud = (e) => {
3107
3117
  })), le(() => {
3108
3118
  h();
3109
3119
  }, [n]), d || !p)
3110
- return /* @__PURE__ */ i(Vn, {});
3120
+ return /* @__PURE__ */ i(En, {});
3111
3121
  if (f)
3112
3122
  return /* @__PURE__ */ i(ot, { className: "mt-10", message: f, type: "error", banner: !0 });
3113
3123
  switch (p.type) {
@@ -3148,7 +3158,7 @@ const rv = Object.values(pn), Ud = (e) => {
3148
3158
  default:
3149
3159
  return /* @__PURE__ */ i(ae, { children: `Graph ${p.type} not implemented` });
3150
3160
  }
3151
- }, Vs = wt(Wd), Ct = pt.createContext(null), Gd = (e) => {
3161
+ }, Es = wt(Wd), Ct = pt.createContext(null), Gd = (e) => {
3152
3162
  const {
3153
3163
  children: t,
3154
3164
  openAction: n,
@@ -3180,7 +3190,7 @@ const rv = Object.values(pn), Ud = (e) => {
3180
3190
  children: t
3181
3191
  }
3182
3192
  );
3183
- }, { useToken: Kd } = We, { Text: ei } = kt, Es = (e) => {
3193
+ }, { useToken: Kd } = We, { Text: ei } = kt, Vs = (e) => {
3184
3194
  const { title: t, children: n, action: r, openAction: o, parms: s, tooltip: a } = e, { token: l } = Kd(), c = Object.keys(s).length > 0;
3185
3195
  return /* @__PURE__ */ D(
3186
3196
  "div",
@@ -3279,9 +3289,9 @@ const rv = Object.values(pn), Ud = (e) => {
3279
3289
  t && u();
3280
3290
  }, [t, o]), c && c.message !== "active_id_not_found")
3281
3291
  return /* @__PURE__ */ i(Ts, { error: c });
3282
- const { id: h, model: m, limit: g, domain: y, context: v, initialView: w, description: I } = s || {}, C = f ? Vs : mn;
3292
+ const { id: h, model: m, limit: g, domain: y, context: v, initialView: w, description: I } = s || {}, C = f ? Es : mn;
3283
3293
  return /* @__PURE__ */ D(
3284
- Es,
3294
+ Vs,
3285
3295
  {
3286
3296
  id: h,
3287
3297
  parms: {},
@@ -3290,8 +3300,8 @@ const rv = Object.values(pn), Ud = (e) => {
3290
3300
  openAction: p,
3291
3301
  tooltip: I,
3292
3302
  children: [
3293
- l && /* @__PURE__ */ i(Vn, {}),
3294
- !l && /* @__PURE__ */ i(ae, { children: o ? /* @__PURE__ */ i(
3303
+ l && /* @__PURE__ */ i(En, {}),
3304
+ !l && /* @__PURE__ */ i(ae, { children: o ? (w == null ? void 0 : w.id) && /* @__PURE__ */ i(
3295
3305
  C,
3296
3306
  {
3297
3307
  view_id: w.id,
@@ -3370,9 +3380,9 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3370
3380
  fieldsToRetrieve: [g],
3371
3381
  context: { ...v == null ? void 0 : v(), ...h }
3372
3382
  })).map((b) => {
3373
- const V = b[g];
3374
- let F = V;
3375
- return Array.isArray(V) && (F = V[1]), { label: F, value: b.id };
3383
+ const E = b[g];
3384
+ let F = E;
3385
+ return Array.isArray(E) && (F = E[1]), { label: F, value: b.id };
3376
3386
  });
3377
3387
  l(R);
3378
3388
  } catch (T) {
@@ -3390,14 +3400,14 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3390
3400
  T.push({ id: b, operation: "pendingLink" });
3391
3401
  }), w(T);
3392
3402
  }, S = (A) => {
3393
- const { label: T, closable: R, onClose: b } = A, V = (O) => {
3403
+ const { label: T, closable: R, onClose: b } = A, E = (O) => {
3394
3404
  O.preventDefault(), O.stopPropagation();
3395
3405
  }, F = _n(T);
3396
3406
  return /* @__PURE__ */ i(
3397
3407
  bo,
3398
3408
  {
3399
3409
  color: F,
3400
- onMouseDown: V,
3410
+ onMouseDown: E,
3401
3411
  closable: R,
3402
3412
  onClose: b,
3403
3413
  closeIcon: /* @__PURE__ */ i("span", { style: { color: F }, children: "X" }),
@@ -3462,7 +3472,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3462
3472
  case "many2many":
3463
3473
  return Ch;
3464
3474
  case "separator":
3465
- return Eh;
3475
+ return Vh;
3466
3476
  case "reference":
3467
3477
  return Kh;
3468
3478
  case "binary":
@@ -3490,7 +3500,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3490
3500
  case "markdown":
3491
3501
  return Rg;
3492
3502
  case "radio":
3493
- return Vg;
3503
+ return Eg;
3494
3504
  case "switch":
3495
3505
  return Dg;
3496
3506
  case "steps":
@@ -3653,7 +3663,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3653
3663
  }
3654
3664
  );
3655
3665
  async function y(T) {
3656
- const { reportData: R, fields: b, values: V, context: F = {} } = T, {
3666
+ const { reportData: R, fields: b, values: E, context: F = {} } = T, {
3657
3667
  context: O,
3658
3668
  model: k,
3659
3669
  datas: _ = {},
@@ -3664,10 +3674,10 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3664
3674
  st(`${L} action not supported`);
3665
3675
  return;
3666
3676
  }
3667
- const { ids: W } = _ || {}, B = W || [], E = typeof O == "string" ? jt({
3677
+ const { ids: W } = _ || {}, B = W || [], V = typeof O == "string" ? jt({
3668
3678
  context: O,
3669
3679
  fields: b,
3670
- values: V
3680
+ values: E
3671
3681
  }) : O;
3672
3682
  try {
3673
3683
  const Z = await N.getHandler().createReport({
@@ -3675,7 +3685,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3675
3685
  name: $,
3676
3686
  datas: _,
3677
3687
  ids: B,
3678
- context: { ...F, ...E }
3688
+ context: { ...F, ...V }
3679
3689
  });
3680
3690
  l(!0), s.current = !0, o.current = setInterval(() => {
3681
3691
  v(Z);
@@ -3702,7 +3712,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3702
3712
  actionData: T,
3703
3713
  fields: R,
3704
3714
  values: b,
3705
- context: V,
3715
+ context: E,
3706
3716
  onRefreshParentValues: F
3707
3717
  }) {
3708
3718
  const { type: O } = T;
@@ -3711,13 +3721,13 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3711
3721
  reportData: T,
3712
3722
  fields: R,
3713
3723
  values: b,
3714
- context: V
3724
+ context: E
3715
3725
  });
3716
3726
  if (O === "ir.actions.act_window")
3717
- return await I({ actionData: T, fields: R, values: b, context: V });
3727
+ return await I({ actionData: T, fields: R, values: b, context: E });
3718
3728
  if (O === "ir.actions.act_url")
3719
3729
  window.open(
3720
- dd(T.url, { ...b, context: V }),
3730
+ dd(T.url, { ...b, context: E }),
3721
3731
  "_blank"
3722
3732
  );
3723
3733
  else
@@ -3727,21 +3737,21 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3727
3737
  actionData: T,
3728
3738
  fields: R = {},
3729
3739
  values: b = {},
3730
- context: V = {}
3740
+ context: E = {}
3731
3741
  }) {
3732
3742
  var $;
3733
3743
  let F = T;
3734
3744
  T.res_model || (F = (await N.getHandler().readObjects({
3735
3745
  model: "ir.actions.act_window",
3736
3746
  ids: [parseInt(T.id)],
3737
- context: V
3747
+ context: E
3738
3748
  }))[0]);
3739
3749
  const O = typeof (F == null ? void 0 : F.context) == "string" ? jt({
3740
3750
  context: F.context,
3741
3751
  fields: R,
3742
3752
  values: { ...b, ...r }
3743
3753
  }) : F.context, k = {
3744
- ...V,
3754
+ ...E,
3745
3755
  ...O
3746
3756
  };
3747
3757
  let _ = [];
@@ -3790,16 +3800,16 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3790
3800
  domain: T,
3791
3801
  model: R,
3792
3802
  formView: b,
3793
- context: V,
3803
+ context: E,
3794
3804
  actionData: F
3795
3805
  }) {
3796
- p ? S({ domain: T, model: R, formView: b, context: V, actionData: F }) : (g({ domain: T, model: R, context: V, formView: b, actionData: F }), h(!0));
3806
+ p ? S({ domain: T, model: R, formView: b, context: E, actionData: F }) : (g({ domain: T, model: R, context: E, formView: b, actionData: F }), h(!0));
3797
3807
  }
3798
3808
  async function S({
3799
3809
  domain: T,
3800
3810
  model: R,
3801
3811
  formView: b,
3802
- context: V,
3812
+ context: E,
3803
3813
  actionData: F
3804
3814
  }) {
3805
3815
  g({
@@ -3808,7 +3818,7 @@ const Zd = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ds,
3808
3818
  context: {},
3809
3819
  formView: void 0,
3810
3820
  actionData: void 0
3811
- }), h(!1), await new Promise((O) => setTimeout(O, 300)), g({ domain: T, model: R, context: V, formView: b, actionData: F }), h(!0);
3821
+ }), h(!1), await new Promise((O) => setTimeout(O, 300)), g({ domain: T, model: R, context: E, formView: b, actionData: F }), h(!0);
3812
3822
  }
3813
3823
  async function A() {
3814
3824
  ni(f.current), f.current = [], h(!1), g({
@@ -4015,7 +4025,7 @@ function Cu(e, t) {
4015
4025
  forcedValues: A = {},
4016
4026
  parentWidth: T,
4017
4027
  onMustRefreshParent: R
4018
- } = e, { t: b } = fe(), [V, F] = x(!1), [O, k] = x(), [_, $] = x(), [L] = ht.useForm(), [W, B] = x(), [E, Z] = x(), ne = te(Ps), [Q, H] = x(), [re, ee] = x(!1), G = Y(), M = Y({}), j = Y({}), ge = Y(!1), z = Y(!1), J = Y(!1), me = (T !== void 0 ? T : Q) < Su, ke = te(Ue), { activeId: $e, getPlainValues: Ee } = ke || {}, Ne = Y(!1), Be = te(
4028
+ } = e, { t: b } = fe(), [E, F] = x(!1), [O, k] = x(), [_, $] = x(), [L] = ht.useForm(), [W, B] = x(), [V, Z] = x(), ne = te(Ps), [Q, H] = x(), [re, ee] = x(!1), G = Y(), M = Y({}), j = Y({}), ge = Y(!1), z = Y(!1), J = Y(!1), me = (T !== void 0 ? T : Q) < Su, ke = te(Ue), { activeId: $e, getPlainValues: Ve } = ke || {}, Ne = Y(!1), Be = te(
4019
4029
  lt
4020
4030
  ), {
4021
4031
  setFormIsSaving: Oe = void 0,
@@ -4046,7 +4056,7 @@ function Cu(e, t) {
4046
4056
  G.current = void 0, $(void 0);
4047
4057
  return;
4048
4058
  }
4049
- (r === void 0 && E || r !== void 0 && E && r < 0) && (G.current = void 0, $(void 0)), tt();
4059
+ (r === void 0 && V || r !== void 0 && V && r < 0) && (G.current = void 0, $(void 0)), tt();
4050
4060
  }
4051
4061
  }, [r, n, h, m, I]), le(() => {
4052
4062
  re && (hr({
@@ -4065,11 +4075,11 @@ function Cu(e, t) {
4065
4075
  }, [G.current]);
4066
4076
  const Le = oe(() => r || X, [r, X]);
4067
4077
  function Te() {
4068
- return E;
4078
+ return V;
4069
4079
  }
4070
4080
  function be() {
4071
4081
  const U = {
4072
- ...Re(E),
4082
+ ...Re(V),
4073
4083
  ...mt()
4074
4084
  };
4075
4085
  for (const K in U)
@@ -4085,7 +4095,7 @@ function Cu(e, t) {
4085
4095
  }
4086
4096
  function Qe() {
4087
4097
  const U = {
4088
- ...Re(E)
4098
+ ...Re(V)
4089
4099
  };
4090
4100
  for (const K in U)
4091
4101
  U[K] === void 0 && delete U[K];
@@ -4114,8 +4124,8 @@ function Cu(e, t) {
4114
4124
  }, It = () => Object.keys(
4115
4125
  br({
4116
4126
  source: M.current,
4117
- target: Re(E),
4118
- fields: E
4127
+ target: Re(V),
4128
+ fields: V
4119
4129
  })
4120
4130
  ).length !== 0, Re = (U) => {
4121
4131
  const K = L.getFieldsValue(!0);
@@ -4123,10 +4133,10 @@ function Cu(e, t) {
4123
4133
  }, ct = (U, K) => {
4124
4134
  vt({
4125
4135
  values: {
4126
- ...en(L.getFieldsValue(!0), E),
4136
+ ...en(L.getFieldsValue(!0), V),
4127
4137
  [U]: K
4128
4138
  },
4129
- fields: E,
4139
+ fields: V,
4130
4140
  reset: !1
4131
4141
  });
4132
4142
  }, he = (U) => L.getFieldsValue(!0)[U];
@@ -4152,7 +4162,7 @@ function Cu(e, t) {
4152
4162
  }
4153
4163
  }, ze = async (U) => {
4154
4164
  let K, se, ce, Ae;
4155
- ue == null || ue(!0), k(void 0), U != null && U.fields ? (se = U.fields, ce = U.arch) : (se = E, ce = W), h && (U == null ? void 0 : U.forceRefresh) !== !0 ? K = h : { values: K, defaultGetCalled: Ae } = await $n({
4165
+ ue == null || ue(!0), k(void 0), U != null && U.fields ? (se = U.fields, ce = U.arch) : (se = V, ce = W), h && (U == null ? void 0 : U.forceRefresh) !== !0 ? K = h : { values: K, defaultGetCalled: Ae } = await $n({
4156
4166
  fields: se,
4157
4167
  arch: ce
4158
4168
  }), w && (K = { ...ad(w), ...K }), M.current = en(K, se), vt({
@@ -4235,24 +4245,24 @@ function Cu(e, t) {
4235
4245
  if (ve()) {
4236
4246
  const se = br({
4237
4247
  source: M.current,
4238
- target: Re(E),
4239
- fields: E
4248
+ target: Re(V),
4249
+ fields: V
4240
4250
  });
4241
4251
  await N.getHandler().update({
4242
4252
  model: n,
4243
4253
  id: ve(),
4244
4254
  values: { ...se, ...A },
4245
- fields: E,
4255
+ fields: V,
4246
4256
  context: {
4247
4257
  ...v,
4248
4258
  ..._ == null ? void 0 : _.context
4249
4259
  }
4250
- }), M.current = Re(E);
4260
+ }), M.current = Re(V);
4251
4261
  } else {
4252
- const se = Re(E), ce = await N.getHandler().create({
4262
+ const se = Re(V), ce = await N.getHandler().create({
4253
4263
  model: n,
4254
4264
  values: { ...se, ...A },
4255
- fields: E,
4265
+ fields: V,
4256
4266
  context: {
4257
4267
  ...v,
4258
4268
  ..._ == null ? void 0 : _.context
@@ -4275,7 +4285,7 @@ function Cu(e, t) {
4275
4285
  J.current
4276
4286
  ), J.current = !1;
4277
4287
  const ce = ve();
4278
- return d && (G.current = void 0, vt({ values: {}, fields: E, reset: !0 })), { succeed: !0, id: ce };
4288
+ return d && (G.current = void 0, vt({ values: {}, fields: V, reset: !0 })), { succeed: !0, id: ce };
4279
4289
  }
4280
4290
  if (!It() && ve() && se)
4281
4291
  return z.current = !1, de == null || de(!1), Me == null || Me(), { succeed: !0, id: ve() };
@@ -4283,7 +4293,7 @@ function Cu(e, t) {
4283
4293
  return z.current = !1, ti(b), { succeed: !1, id: ve() };
4284
4294
  F(!0), Oe == null || Oe(!0);
4285
4295
  try {
4286
- p === "api" ? await bn(U) : await Nn(U), d && (G.current = void 0, vt({ values: {}, fields: E, reset: !0 })), await ze({ forceRefresh: !0 }), K = !0, wr.success(b("savedRegisters"));
4296
+ p === "api" ? await bn(U) : await Nn(U), d && (G.current = void 0, vt({ values: {}, fields: V, reset: !0 })), await ze({ forceRefresh: !0 }), K = !0, wr.success(b("savedRegisters"));
4287
4297
  } catch (ce) {
4288
4298
  z.current = !1, F(!1), Oe == null || Oe(!1), Je == null || Je(ce), wr.error(b("errorWhileSavingForm")), k(ce != null && ce.message ? ce.message : ce);
4289
4299
  } finally {
@@ -4334,8 +4344,8 @@ function Cu(e, t) {
4334
4344
  return;
4335
4345
  const K = br({
4336
4346
  source: j.current,
4337
- target: Re(E),
4338
- fields: E
4347
+ target: Re(V),
4348
+ fields: V
4339
4349
  }), se = Object.keys(K);
4340
4350
  if (se.length !== 0 && !(id({
4341
4351
  changedFields: se,
@@ -4352,7 +4362,7 @@ function Cu(e, t) {
4352
4362
  "many2one"
4353
4363
  ]
4354
4364
  }) && U !== !0)) {
4355
- const ce = en(L.getFieldsValue(!0), E);
4365
+ const ce = en(L.getFieldsValue(!0), V);
4356
4366
  j.current = ce, c == null || c(ce), de == null || de(!0), Ma(se);
4357
4367
  }
4358
4368
  }, Na = Ml(hr, 100), Ma = async (U) => {
@@ -4368,44 +4378,44 @@ function Cu(e, t) {
4368
4378
  const K = _ == null ? void 0 : _.onChangeFields[U];
4369
4379
  if (!K) {
4370
4380
  Nt({
4371
- fields: E,
4381
+ fields: V,
4372
4382
  arch: W,
4373
- values: Re(E)
4383
+ values: Re(V)
4374
4384
  });
4375
4385
  return;
4376
4386
  }
4377
4387
  const se = ld({
4378
4388
  values: {
4379
- ...Re(E),
4389
+ ...Re(V),
4380
4390
  context: {
4381
4391
  ...v,
4382
4392
  ..._ == null ? void 0 : _.context
4383
4393
  }
4384
4394
  },
4385
- parentValues: Ee == null ? void 0 : Ee(),
4395
+ parentValues: Ve == null ? void 0 : Ve(),
4386
4396
  onChangeFieldActionArgs: K.args
4387
4397
  }), ce = await N.getHandler().executeOnChange({
4388
4398
  model: n,
4389
4399
  action: K.method,
4390
4400
  ids: ve() ? [ve()] : [],
4391
4401
  payload: se,
4392
- fields: E
4402
+ fields: V
4393
4403
  });
4394
4404
  if (ce.value) {
4395
4405
  const Ae = {
4396
- ...Re(E),
4406
+ ...Re(V),
4397
4407
  ...ce.value
4398
4408
  }, Ze = Qc({
4399
4409
  values: Ae,
4400
- fields: E
4410
+ fields: V
4401
4411
  });
4402
4412
  Nt({
4403
- fields: E,
4413
+ fields: V,
4404
4414
  arch: W,
4405
4415
  values: Ze
4406
4416
  }), vt({
4407
4417
  values: Ze,
4408
- fields: E,
4418
+ fields: V,
4409
4419
  reset: !1
4410
4420
  });
4411
4421
  }
@@ -4418,7 +4428,7 @@ function Cu(e, t) {
4418
4428
  if (ce.domain && Object.keys(ce.domain).length > 0) {
4419
4429
  const Ae = sd({
4420
4430
  fieldsDomain: ce.domain,
4421
- fields: E
4431
+ fields: V
4422
4432
  });
4423
4433
  Nt({
4424
4434
  fields: Ae,
@@ -4449,7 +4459,7 @@ function Cu(e, t) {
4449
4459
  let ce = {};
4450
4460
  se.context && (ce = jt({
4451
4461
  context: se.context,
4452
- fields: E,
4462
+ fields: V,
4453
4463
  values: be()
4454
4464
  })), await Po({
4455
4465
  actionData: se,
@@ -4483,7 +4493,7 @@ function Cu(e, t) {
4483
4493
  }) {
4484
4494
  const { closeParent: se } = await (Pe == null ? void 0 : Pe({
4485
4495
  actionData: U,
4486
- fields: E,
4496
+ fields: V,
4487
4497
  values: be(),
4488
4498
  context: {
4489
4499
  ...v,
@@ -4501,9 +4511,9 @@ function Cu(e, t) {
4501
4511
  }
4502
4512
  function gr(U) {
4503
4513
  Nt({
4504
- fields: E,
4514
+ fields: V,
4505
4515
  arch: W,
4506
- values: Re(E),
4516
+ values: Re(V),
4507
4517
  operationInProgress: U
4508
4518
  });
4509
4519
  }
@@ -4511,24 +4521,24 @@ function Cu(e, t) {
4511
4521
  (U) => {
4512
4522
  if (!W)
4513
4523
  return;
4514
- const K = { ...Re(E), ...U };
4524
+ const K = { ...Re(V), ...U };
4515
4525
  M.current = {
4516
4526
  ...M.current,
4517
4527
  ...U
4518
- }, Nt({ fields: E, arch: W, values: K }), vt({
4528
+ }, Nt({ fields: V, arch: W, values: K }), vt({
4519
4529
  values: K,
4520
- fields: E,
4530
+ fields: V,
4521
4531
  reset: !1
4522
4532
  });
4523
4533
  },
4524
- [W, vt, E, Re, Nt]
4534
+ [W, vt, V, Re, Nt]
4525
4535
  );
4526
4536
  bu({
4527
4537
  model: n,
4528
4538
  id: Le,
4529
4539
  context: v,
4530
4540
  autorefreshableFields: _ == null ? void 0 : _.autorefreshableFields,
4531
- fieldDefs: E,
4541
+ fieldDefs: V,
4532
4542
  onAutorefreshableFieldsChange: Wa,
4533
4543
  isActive: Ie
4534
4544
  });
@@ -4597,7 +4607,7 @@ function Cu(e, t) {
4597
4607
  He,
4598
4608
  {
4599
4609
  icon: /* @__PURE__ */ i(fn, {}),
4600
- disabled: V,
4610
+ disabled: E,
4601
4611
  onClick: async () => {
4602
4612
  await _t();
4603
4613
  },
@@ -4607,8 +4617,8 @@ function Cu(e, t) {
4607
4617
  /* @__PURE__ */ i(
4608
4618
  He,
4609
4619
  {
4610
- disabled: V || f,
4611
- loading: V,
4620
+ disabled: E || f,
4621
+ loading: E,
4612
4622
  icon: /* @__PURE__ */ i(tr, {}),
4613
4623
  onClick: async () => {
4614
4624
  await zt();
@@ -4664,12 +4674,12 @@ const yn = wt(Cu), vn = (e) => {
4664
4674
  shortcut_id: g
4665
4675
  });
4666
4676
  else {
4667
- const { action_id: b, res_id: V, action_type: F, view_id: O } = l;
4677
+ const { action_id: b, res_id: E, action_type: F, view_id: O } = l;
4668
4678
  await N.getHandler().addFavourite({
4669
4679
  action_id: b,
4670
4680
  action_type: F,
4671
4681
  view_id: O,
4672
- res_id: V || !1
4682
+ res_id: E || !1
4673
4683
  });
4674
4684
  }
4675
4685
  m(!h);
@@ -4862,7 +4872,7 @@ const Tu = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ls,
4862
4872
  }, [l, e]);
4863
4873
  return /* @__PURE__ */ D(Rn, { children: [
4864
4874
  /* @__PURE__ */ i(
4865
- El,
4875
+ Vl,
4866
4876
  {
4867
4877
  onRetrieveData: f,
4868
4878
  onItemClick: (d) => {
@@ -5015,7 +5025,7 @@ const Tu = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ls,
5015
5025
  /* @__PURE__ */ i(ae, { children: o }),
5016
5026
  /* @__PURE__ */ i(Co, { id: f, model: c })
5017
5027
  ] });
5018
- }, Vu = (e) => {
5028
+ }, Eu = (e) => {
5019
5029
  const { ooui: t, value: n } = e;
5020
5030
  if (!n)
5021
5031
  return null;
@@ -5023,13 +5033,13 @@ const Tu = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ls,
5023
5033
  t.selectionValues.size ? r = t.selectionValues.get(n) : Array.isArray(n) && (r = n[1]);
5024
5034
  const o = r.toString().split(" ").filter((a) => a.length > 1).slice(0, 3).map((a) => a[0].toUpperCase()).join(""), s = _n(r);
5025
5035
  return /* @__PURE__ */ i(Rt, { title: r, children: /* @__PURE__ */ i(Hi, { alt: r, style: { backgroundColor: s }, children: o }) });
5026
- }, Eu = {
5036
+ }, Vu = {
5027
5037
  en_US: Xl,
5028
5038
  es_ES: Zl,
5029
5039
  ca_ES: ec
5030
5040
  }, xo = () => {
5031
5041
  const { locale: e } = fe();
5032
- return Eu[e];
5042
+ return Vu[e];
5033
5043
  }, { useToken: Du } = We, Ft = {
5034
5044
  date: {
5035
5045
  placeholder: "__/__/____",
@@ -5256,7 +5266,7 @@ const Tu = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ls,
5256
5266
  key: t,
5257
5267
  ooui: n,
5258
5268
  context: r
5259
- }) => oe(() => /* @__PURE__ */ i(Vu, { ooui: n, value: e }), [n, e]), zu = ({
5269
+ }) => oe(() => /* @__PURE__ */ i(Eu, { ooui: n, value: e }), [n, e]), zu = ({
5260
5270
  value: e,
5261
5271
  key: t,
5262
5272
  ooui: n,
@@ -5617,11 +5627,11 @@ const Tu = (e) => /* @__PURE__ */ i(_e, { ...e, children: /* @__PURE__ */ i(Ls,
5617
5627
  );
5618
5628
  }, of = (e) => {
5619
5629
  const { ooui: t, showLabel: n = !1 } = e, { label: r, id: o } = t, s = xo(), a = [
5620
- new Er({
5630
+ new Vr({
5621
5631
  name: o + "#date",
5622
5632
  label: ""
5623
5633
  }),
5624
- new Er({
5634
+ new Vr({
5625
5635
  name: o + "#time",
5626
5636
  label: ""
5627
5637
  })
@@ -5825,7 +5835,7 @@ function Gs(e) {
5825
5835
  t.readOnly = !1, t.required = !1;
5826
5836
  const { t: n } = fe();
5827
5837
  switch (t.type) {
5828
- case Vt.boolean: {
5838
+ case Et.boolean: {
5829
5839
  const o = new Zr({
5830
5840
  name: t._id,
5831
5841
  string: t.label,
@@ -5836,16 +5846,16 @@ function Gs(e) {
5836
5846
  });
5837
5847
  return /* @__PURE__ */ i(gs, { layout: "vertical", ooui: o, showLabel: !0 });
5838
5848
  }
5839
- case Vt.float:
5840
- case Vt.progressbar:
5841
- case Vt.float_time:
5842
- case Vt.integer:
5849
+ case Et.float:
5850
+ case Et.progressbar:
5851
+ case Et.float_time:
5852
+ case Et.integer:
5843
5853
  return /* @__PURE__ */ i(gf, { ooui: t, showLabel: !0 });
5844
- case Vt.date:
5854
+ case Et.date:
5845
5855
  return /* @__PURE__ */ i(rf, { ooui: t, layout: "vertical", showLabel: !0 });
5846
- case Vt.datetime:
5856
+ case Et.datetime:
5847
5857
  return /* @__PURE__ */ i(of, { ooui: t, layout: "vertical", showLabel: !0 });
5848
- case Vt.selection:
5858
+ case Et.selection:
5849
5859
  return /* @__PURE__ */ i(Sf, { layout: "vertical", ooui: t, showLabel: !0 });
5850
5860
  default:
5851
5861
  return /* @__PURE__ */ i(
@@ -5932,14 +5942,14 @@ const ai = (e) => typeof e == "string" && e === "true" || e === "false" ? e ===
5932
5942
  return t.forEach((o) => {
5933
5943
  Array.isArray(o) && o[0] ? r.includes(o[0]) || n.push(o) : r.includes(o) || n.push(o);
5934
5944
  }), n;
5935
- }, { useToken: Vf } = We, { Title: Ef } = kt, { Header: Df, Content: Pf, Footer: kf } = Ui, $f = ({
5945
+ }, { useToken: Ef } = We, { Title: Vf } = kt, { Header: Df, Content: Pf, Footer: kf } = Ui, $f = ({
5936
5946
  isOpen: e,
5937
5947
  onClose: t,
5938
5948
  children: n,
5939
5949
  title: r,
5940
5950
  footer: o
5941
5951
  }) => {
5942
- const [s, a] = x(e), l = Y(null), { token: c } = Vf(), u = P(
5952
+ const [s, a] = x(e), l = Y(null), { token: c } = Ef(), u = P(
5943
5953
  (h) => {
5944
5954
  h.preventDefault(), h.stopPropagation(), t();
5945
5955
  },
@@ -6011,7 +6021,7 @@ const ai = (e) => typeof e == "string" && e === "true" || e === "false" ? e ===
6011
6021
  },
6012
6022
  children: [
6013
6023
  /* @__PURE__ */ D(Df, { style: p, children: [
6014
- /* @__PURE__ */ i(Ef, { level: 3, style: { margin: 0, flex: 1 }, children: r }),
6024
+ /* @__PURE__ */ i(Vf, { level: 3, style: { margin: 0, flex: 1 }, children: r }),
6015
6025
  /* @__PURE__ */ i(
6016
6026
  He,
6017
6027
  {
@@ -6295,7 +6305,7 @@ var Ys = Hn, zs = function() {
6295
6305
  return o;
6296
6306
  }, pm = mm, Js = Function.prototype.bind || pm, gi = {}.hasOwnProperty, Tr = Function.prototype.call, hm = Tr.bind ? Tr.bind(gi) : function(e, t) {
6297
6307
  return Tr.call(gi, e, t);
6298
- }, Ve, dn = SyntaxError, Qs = Function, sn = TypeError, Ar = function(e) {
6308
+ }, Ee, dn = SyntaxError, Qs = Function, sn = TypeError, Ar = function(e) {
6299
6309
  try {
6300
6310
  return Qs('"use strict"; return (' + e + ").constructor;")();
6301
6311
  } catch {
@@ -6321,22 +6331,22 @@ var Or = function() {
6321
6331
  }
6322
6332
  }() : Or, Jt = am(), ym = cm(), et = Object.getPrototypeOf || (ym ? function(e) {
6323
6333
  return e.__proto__;
6324
- } : null), tn = {}, vm = typeof Uint8Array > "u" || !et ? Ve : et(Uint8Array), Ut = {
6325
- "%AggregateError%": typeof AggregateError > "u" ? Ve : AggregateError,
6334
+ } : null), tn = {}, vm = typeof Uint8Array > "u" || !et ? Ee : et(Uint8Array), Ut = {
6335
+ "%AggregateError%": typeof AggregateError > "u" ? Ee : AggregateError,
6326
6336
  "%Array%": Array,
6327
- "%ArrayBuffer%": typeof ArrayBuffer > "u" ? Ve : ArrayBuffer,
6328
- "%ArrayIteratorPrototype%": Jt && et ? et([][Symbol.iterator]()) : Ve,
6329
- "%AsyncFromSyncIteratorPrototype%": Ve,
6337
+ "%ArrayBuffer%": typeof ArrayBuffer > "u" ? Ee : ArrayBuffer,
6338
+ "%ArrayIteratorPrototype%": Jt && et ? et([][Symbol.iterator]()) : Ee,
6339
+ "%AsyncFromSyncIteratorPrototype%": Ee,
6330
6340
  "%AsyncFunction%": tn,
6331
6341
  "%AsyncGenerator%": tn,
6332
6342
  "%AsyncGeneratorFunction%": tn,
6333
6343
  "%AsyncIteratorPrototype%": tn,
6334
- "%Atomics%": typeof Atomics > "u" ? Ve : Atomics,
6335
- "%BigInt%": typeof BigInt > "u" ? Ve : BigInt,
6336
- "%BigInt64Array%": typeof BigInt64Array > "u" ? Ve : BigInt64Array,
6337
- "%BigUint64Array%": typeof BigUint64Array > "u" ? Ve : BigUint64Array,
6344
+ "%Atomics%": typeof Atomics > "u" ? Ee : Atomics,
6345
+ "%BigInt%": typeof BigInt > "u" ? Ee : BigInt,
6346
+ "%BigInt64Array%": typeof BigInt64Array > "u" ? Ee : BigInt64Array,
6347
+ "%BigUint64Array%": typeof BigUint64Array > "u" ? Ee : BigUint64Array,
6338
6348
  "%Boolean%": Boolean,
6339
- "%DataView%": typeof DataView > "u" ? Ve : DataView,
6349
+ "%DataView%": typeof DataView > "u" ? Ee : DataView,
6340
6350
  "%Date%": Date,
6341
6351
  "%decodeURI%": decodeURI,
6342
6352
  "%decodeURIComponent%": decodeURIComponent,
@@ -6346,49 +6356,49 @@ var Or = function() {
6346
6356
  "%eval%": eval,
6347
6357
  // eslint-disable-line no-eval
6348
6358
  "%EvalError%": EvalError,
6349
- "%Float32Array%": typeof Float32Array > "u" ? Ve : Float32Array,
6350
- "%Float64Array%": typeof Float64Array > "u" ? Ve : Float64Array,
6351
- "%FinalizationRegistry%": typeof FinalizationRegistry > "u" ? Ve : FinalizationRegistry,
6359
+ "%Float32Array%": typeof Float32Array > "u" ? Ee : Float32Array,
6360
+ "%Float64Array%": typeof Float64Array > "u" ? Ee : Float64Array,
6361
+ "%FinalizationRegistry%": typeof FinalizationRegistry > "u" ? Ee : FinalizationRegistry,
6352
6362
  "%Function%": Qs,
6353
6363
  "%GeneratorFunction%": tn,
6354
- "%Int8Array%": typeof Int8Array > "u" ? Ve : Int8Array,
6355
- "%Int16Array%": typeof Int16Array > "u" ? Ve : Int16Array,
6356
- "%Int32Array%": typeof Int32Array > "u" ? Ve : Int32Array,
6364
+ "%Int8Array%": typeof Int8Array > "u" ? Ee : Int8Array,
6365
+ "%Int16Array%": typeof Int16Array > "u" ? Ee : Int16Array,
6366
+ "%Int32Array%": typeof Int32Array > "u" ? Ee : Int32Array,
6357
6367
  "%isFinite%": isFinite,
6358
6368
  "%isNaN%": isNaN,
6359
- "%IteratorPrototype%": Jt && et ? et(et([][Symbol.iterator]())) : Ve,
6360
- "%JSON%": typeof JSON == "object" ? JSON : Ve,
6361
- "%Map%": typeof Map > "u" ? Ve : Map,
6362
- "%MapIteratorPrototype%": typeof Map > "u" || !Jt || !et ? Ve : et((/* @__PURE__ */ new Map())[Symbol.iterator]()),
6369
+ "%IteratorPrototype%": Jt && et ? et(et([][Symbol.iterator]())) : Ee,
6370
+ "%JSON%": typeof JSON == "object" ? JSON : Ee,
6371
+ "%Map%": typeof Map > "u" ? Ee : Map,
6372
+ "%MapIteratorPrototype%": typeof Map > "u" || !Jt || !et ? Ee : et((/* @__PURE__ */ new Map())[Symbol.iterator]()),
6363
6373
  "%Math%": Math,
6364
6374
  "%Number%": Number,
6365
6375
  "%Object%": Object,
6366
6376
  "%parseFloat%": parseFloat,
6367
6377
  "%parseInt%": parseInt,
6368
- "%Promise%": typeof Promise > "u" ? Ve : Promise,
6369
- "%Proxy%": typeof Proxy > "u" ? Ve : Proxy,
6378
+ "%Promise%": typeof Promise > "u" ? Ee : Promise,
6379
+ "%Proxy%": typeof Proxy > "u" ? Ee : Proxy,
6370
6380
  "%RangeError%": RangeError,
6371
6381
  "%ReferenceError%": ReferenceError,
6372
- "%Reflect%": typeof Reflect > "u" ? Ve : Reflect,
6382
+ "%Reflect%": typeof Reflect > "u" ? Ee : Reflect,
6373
6383
  "%RegExp%": RegExp,
6374
- "%Set%": typeof Set > "u" ? Ve : Set,
6375
- "%SetIteratorPrototype%": typeof Set > "u" || !Jt || !et ? Ve : et((/* @__PURE__ */ new Set())[Symbol.iterator]()),
6376
- "%SharedArrayBuffer%": typeof SharedArrayBuffer > "u" ? Ve : SharedArrayBuffer,
6384
+ "%Set%": typeof Set > "u" ? Ee : Set,
6385
+ "%SetIteratorPrototype%": typeof Set > "u" || !Jt || !et ? Ee : et((/* @__PURE__ */ new Set())[Symbol.iterator]()),
6386
+ "%SharedArrayBuffer%": typeof SharedArrayBuffer > "u" ? Ee : SharedArrayBuffer,
6377
6387
  "%String%": String,
6378
- "%StringIteratorPrototype%": Jt && et ? et(""[Symbol.iterator]()) : Ve,
6379
- "%Symbol%": Jt ? Symbol : Ve,
6388
+ "%StringIteratorPrototype%": Jt && et ? et(""[Symbol.iterator]()) : Ee,
6389
+ "%Symbol%": Jt ? Symbol : Ee,
6380
6390
  "%SyntaxError%": dn,
6381
6391
  "%ThrowTypeError%": gm,
6382
6392
  "%TypedArray%": vm,
6383
6393
  "%TypeError%": sn,
6384
- "%Uint8Array%": typeof Uint8Array > "u" ? Ve : Uint8Array,
6385
- "%Uint8ClampedArray%": typeof Uint8ClampedArray > "u" ? Ve : Uint8ClampedArray,
6386
- "%Uint16Array%": typeof Uint16Array > "u" ? Ve : Uint16Array,
6387
- "%Uint32Array%": typeof Uint32Array > "u" ? Ve : Uint32Array,
6394
+ "%Uint8Array%": typeof Uint8Array > "u" ? Ee : Uint8Array,
6395
+ "%Uint8ClampedArray%": typeof Uint8ClampedArray > "u" ? Ee : Uint8ClampedArray,
6396
+ "%Uint16Array%": typeof Uint16Array > "u" ? Ee : Uint16Array,
6397
+ "%Uint32Array%": typeof Uint32Array > "u" ? Ee : Uint32Array,
6388
6398
  "%URIError%": URIError,
6389
- "%WeakMap%": typeof WeakMap > "u" ? Ve : WeakMap,
6390
- "%WeakRef%": typeof WeakRef > "u" ? Ve : WeakRef,
6391
- "%WeakSet%": typeof WeakSet > "u" ? Ve : WeakSet
6399
+ "%WeakMap%": typeof WeakMap > "u" ? Ee : WeakMap,
6400
+ "%WeakRef%": typeof WeakRef > "u" ? Ee : WeakRef,
6401
+ "%WeakSet%": typeof WeakSet > "u" ? Ee : WeakSet
6392
6402
  };
6393
6403
  if (et)
6394
6404
  try {
@@ -6465,7 +6475,7 @@ var bm = function e(t) {
6465
6475
  "%URIErrorPrototype%": ["URIError", "prototype"],
6466
6476
  "%WeakMapPrototype%": ["WeakMap", "prototype"],
6467
6477
  "%WeakSetPrototype%": ["WeakSet", "prototype"]
6468
- }, En = Js, zn = hm, Sm = En.call(Function.call, Array.prototype.concat), Cm = En.call(Function.apply, Array.prototype.splice), vi = En.call(Function.call, String.prototype.replace), Jn = En.call(Function.call, String.prototype.slice), xm = En.call(Function.call, RegExp.prototype.exec), Im = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, Tm = /\\(\\)?/g, Am = function(t) {
6478
+ }, Vn = Js, zn = hm, Sm = Vn.call(Function.call, Array.prototype.concat), Cm = Vn.call(Function.apply, Array.prototype.splice), vi = Vn.call(Function.call, String.prototype.replace), Jn = Vn.call(Function.call, String.prototype.slice), xm = Vn.call(Function.call, RegExp.prototype.exec), Im = /[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g, Tm = /\\(\\)?/g, Am = function(t) {
6469
6479
  var n = Jn(t, 0, 1), r = Jn(t, -1);
6470
6480
  if (n === "%" && r !== "%")
6471
6481
  throw new dn("invalid intrinsic syntax, expected closing `%`");
@@ -6551,11 +6561,11 @@ var Oo = Xs.exports, Zs = Dn, ea = Oo, Fm = ea(Zs("String.prototype.indexOf")),
6551
6561
  return Rm && t && typeof t == "object" && Symbol.toStringTag in t ? !1 : Mr(t) === "[object Arguments]";
6552
6562
  }, na = function(t) {
6553
6563
  return mr(t) ? !0 : t !== null && typeof t == "object" && typeof t.length == "number" && t.length >= 0 && Mr(t) !== "[object Array]" && Mr(t.callee) === "[object Function]";
6554
- }, Vm = function() {
6564
+ }, Em = function() {
6555
6565
  return mr(arguments);
6556
6566
  }();
6557
6567
  mr.isLegacyArguments = na;
6558
- var Em = Vm ? mr : na, Dm = Dn, Lr = Dm("%Object.defineProperty%", !0), jr = function() {
6568
+ var Vm = Em ? mr : na, Dm = Dn, Lr = Dm("%Object.defineProperty%", !0), jr = function() {
6559
6569
  if (Lr)
6560
6570
  try {
6561
6571
  return Lr({}, "a", { value: 1 }), !0;
@@ -6744,12 +6754,12 @@ var Tp = ga, Ap = Date.prototype.getDay, Op = function(t) {
6744
6754
  } catch {
6745
6755
  return !1;
6746
6756
  }
6747
- }, Fp = Object.prototype.toString, Rp = "[object Date]", _p = Ao(), Vp = function(t) {
6757
+ }, Fp = Object.prototype.toString, Rp = "[object Date]", _p = Ao(), Ep = function(t) {
6748
6758
  return typeof t != "object" || t === null ? !1 : _p ? Op(t) : Fp.call(t) === Rp;
6749
- }, Ai = Ys, Oi = Em, Fi = Qm, Ri = tp, _i = Tp, Vi = Vp, Ei = Date.prototype.getTime;
6759
+ }, Ai = Ys, Oi = Vm, Fi = Qm, Ri = tp, _i = Tp, Ei = Ep, Vi = Date.prototype.getTime;
6750
6760
  function ya(e, t, n) {
6751
6761
  var r = n || {};
6752
- return (r.strict ? Fi(e, t) : e === t) ? !0 : !e || !t || typeof e != "object" && typeof t != "object" ? r.strict ? Fi(e, t) : e == t : Ep(e, t, r);
6762
+ return (r.strict ? Fi(e, t) : e === t) ? !0 : !e || !t || typeof e != "object" && typeof t != "object" ? r.strict ? Fi(e, t) : e == t : Vp(e, t, r);
6753
6763
  }
6754
6764
  function Di(e) {
6755
6765
  return e == null;
@@ -6757,7 +6767,7 @@ function Di(e) {
6757
6767
  function Pi(e) {
6758
6768
  return !(!e || typeof e != "object" || typeof e.length != "number" || typeof e.copy != "function" || typeof e.slice != "function" || e.length > 0 && typeof e[0] != "number");
6759
6769
  }
6760
- function Ep(e, t, n) {
6770
+ function Vp(e, t, n) {
6761
6771
  var r, o;
6762
6772
  if (typeof e != typeof t || Di(e) || Di(t) || e.prototype !== t.prototype || Oi(e) !== Oi(t))
6763
6773
  return !1;
@@ -6766,8 +6776,8 @@ function Ep(e, t, n) {
6766
6776
  return !1;
6767
6777
  if (s || a)
6768
6778
  return e.source === t.source && _i(e) === _i(t);
6769
- if (Vi(e) && Vi(t))
6770
- return Ei.call(e) === Ei.call(t);
6779
+ if (Ei(e) && Ei(t))
6780
+ return Vi.call(e) === Vi.call(t);
6771
6781
  var l = Pi(e), c = Pi(t);
6772
6782
  if (l !== c)
6773
6783
  return !1;
@@ -7048,7 +7058,7 @@ function _o(e) {
7048
7058
  ($ = C.current) == null ? void 0 : $._advancedSearchContainer
7049
7059
  );
7050
7060
  o({ params: _, offset: k, limit: O, searchValues: F });
7051
- }, V = P(() => {
7061
+ }, E = P(() => {
7052
7062
  if (!m || !y)
7053
7063
  return !1;
7054
7064
  const F = m.rows.reduce(
@@ -7083,7 +7093,7 @@ function _o(e) {
7083
7093
  /* @__PURE__ */ i(
7084
7094
  Np,
7085
7095
  {
7086
- hideAdvancedFilter: (V() || (y == null ? void 0 : y._rows.length) === 0) && !h,
7096
+ hideAdvancedFilter: (E() || (y == null ? void 0 : y._rows.length) === 0) && !h,
7087
7097
  advancedFilter: w,
7088
7098
  onAdvancedFilterToggle: () => {
7089
7099
  I(!w);
@@ -7245,7 +7255,7 @@ function Gp(e, t) {
7245
7255
  } = e, h = Y({}), m = Y(), g = Y(null), y = Y([]), v = $s(), [w, I] = x(!0), [C, S] = x(), { t: A } = fe(), T = Y(null), R = Ju({
7246
7256
  elementRef: T,
7247
7257
  offset: Up
7248
- }), { treeView: b, formView: V, loading: F } = Ns({
7258
+ }), { treeView: b, formView: E, loading: F } = Ns({
7249
7259
  model: n,
7250
7260
  formViewProps: r,
7251
7261
  treeViewProps: o,
@@ -7258,7 +7268,7 @@ function Gp(e, t) {
7258
7268
  setTreeFirstVisibleRow: L,
7259
7269
  treeFirstVisibleRow: W,
7260
7270
  selectedRowItems: B,
7261
- setSearchParams: E,
7271
+ setSearchParams: V,
7262
7272
  searchValues: Z,
7263
7273
  searchParams: ne,
7264
7274
  setSearchValues: Q,
@@ -7274,11 +7284,11 @@ function Gp(e, t) {
7274
7284
  de();
7275
7285
  }, []), le(() => {
7276
7286
  var he;
7277
- (z !== void 0 && J.current === void 0 || typeof z == "string" && typeof J.current == "string" && z !== J.current) && (E == null || E([]), Q == null || Q({}), (he = g.current) == null || he.unselectAll(), Qe()), J.current = z;
7287
+ (z !== void 0 && J.current === void 0 || typeof z == "string" && typeof J.current == "string" && z !== J.current) && (V == null || V([]), Q == null || Q({}), (he = g.current) == null || he.unselectAll(), Qe()), J.current = z;
7278
7288
  }, [z]);
7279
7289
  const ie = oe(() => {
7280
7290
  if (b)
7281
- return Et(b);
7291
+ return Vt(b);
7282
7292
  }, [b]);
7283
7293
  Hp({
7284
7294
  model: n,
@@ -7302,7 +7312,7 @@ function Gp(e, t) {
7302
7312
  model: n
7303
7313
  }), [n, b == null ? void 0 : b.view_id]), {
7304
7314
  loading: $e,
7305
- getColumnState: Ee,
7315
+ getColumnState: Ve,
7306
7316
  updateColumnState: Ne
7307
7317
  } = Hs(ke), Be = oe(
7308
7318
  () => cn(ne || [], a),
@@ -7492,7 +7502,7 @@ function Gp(e, t) {
7492
7502
  onRowStyle: q,
7493
7503
  onRowSelectionChange: ue,
7494
7504
  onColumnChanged: Ne,
7495
- onGetColumnsState: Ee,
7505
+ onGetColumnsState: Ve,
7496
7506
  onChangeFirstVisibleRowIndex: L,
7497
7507
  onGetFirstVisibleRowIndex: pe,
7498
7508
  selectedRowKeys: ye,
@@ -7510,7 +7520,7 @@ function Gp(e, t) {
7510
7520
  me,
7511
7521
  pe,
7512
7522
  Me,
7513
- Ee,
7523
+ Ve,
7514
7524
  Fe,
7515
7525
  s,
7516
7526
  ve,
@@ -7549,9 +7559,9 @@ function Gp(e, t) {
7549
7559
  [R, l]
7550
7560
  ), At = oe(
7551
7561
  () => ({
7552
- fields: { ...V == null ? void 0 : V.fields, ...b == null ? void 0 : b.fields },
7562
+ fields: { ...E == null ? void 0 : E.fields, ...b == null ? void 0 : b.fields },
7553
7563
  searchFields: Gn([
7554
- V == null ? void 0 : V.search_fields,
7564
+ E == null ? void 0 : E.search_fields,
7555
7565
  b == null ? void 0 : b.search_fields
7556
7566
  ]),
7557
7567
  showLimitOptions: !1,
@@ -7562,45 +7572,45 @@ function Gp(e, t) {
7562
7572
  searchVisible: !0
7563
7573
  }),
7564
7574
  [
7565
- V == null ? void 0 : V.fields,
7566
- V == null ? void 0 : V.search_fields,
7575
+ E == null ? void 0 : E.fields,
7576
+ E == null ? void 0 : E.search_fields,
7567
7577
  b == null ? void 0 : b.fields,
7568
7578
  b == null ? void 0 : b.search_fields,
7569
7579
  Z
7570
7580
  ]
7571
7581
  ), mt = P(() => {
7572
7582
  var he;
7573
- $ == null || $([]), (he = g.current) == null || he.unselectAll(), re == null || re(void 0), E == null || E([]), Q == null || Q(void 0);
7583
+ $ == null || $([]), (he = g.current) == null || he.unselectAll(), re == null || re(void 0), V == null || V([]), Q == null || Q(void 0);
7574
7584
  }, [
7575
7585
  $,
7576
7586
  re,
7577
- E,
7587
+ V,
7578
7588
  Q
7579
7589
  ]), qt = P(
7580
7590
  ({ params: he, searchValues: Ge }) => {
7581
7591
  var tt;
7582
- $ == null || $([]), (tt = g.current) == null || tt.unselectAll(), re == null || re(void 0), E == null || E(he), Q == null || Q(Ge);
7592
+ $ == null || $([]), (tt = g.current) == null || tt.unselectAll(), re == null || re(void 0), V == null || V(he), Q == null || Q(Ge);
7583
7593
  },
7584
7594
  [
7585
7595
  $,
7586
7596
  re,
7587
- E,
7597
+ V,
7588
7598
  Q
7589
7599
  ]
7590
7600
  ), It = oe(
7591
7601
  () => ({
7592
7602
  isOpen: k,
7593
- fields: { ...V == null ? void 0 : V.fields, ...b == null ? void 0 : b.fields },
7603
+ fields: { ...E == null ? void 0 : E.fields, ...b == null ? void 0 : b.fields },
7594
7604
  searchFields: Gn([
7595
- V == null ? void 0 : V.search_fields,
7605
+ E == null ? void 0 : E.search_fields,
7596
7606
  b == null ? void 0 : b.search_fields
7597
7607
  ]),
7598
7608
  searchValues: Z
7599
7609
  }),
7600
7610
  [
7601
7611
  k,
7602
- V == null ? void 0 : V.fields,
7603
- V == null ? void 0 : V.search_fields,
7612
+ E == null ? void 0 : E.fields,
7613
+ E == null ? void 0 : E.search_fields,
7604
7614
  b == null ? void 0 : b.fields,
7605
7615
  b == null ? void 0 : b.search_fields,
7606
7616
  Z
@@ -7611,12 +7621,12 @@ function Gp(e, t) {
7611
7621
  ), ct = P(
7612
7622
  ({ params: he, values: Ge }) => {
7613
7623
  var tt;
7614
- $ == null || $([]), (tt = g.current) == null || tt.unselectAll(), re == null || re(void 0), E == null || E(he), Q == null || Q(Ge), _ == null || _(!1);
7624
+ $ == null || $([]), (tt = g.current) == null || tt.unselectAll(), re == null || re(void 0), V == null || V(he), Q == null || Q(Ge), _ == null || _(!1);
7615
7625
  },
7616
7626
  [
7617
7627
  $,
7618
7628
  re,
7619
- E,
7629
+ V,
7620
7630
  Q,
7621
7631
  _
7622
7632
  ]
@@ -7735,9 +7745,9 @@ const wa = wt(Gp), ki = (e, t = "14px -apple-system") => {
7735
7745
  context: S,
7736
7746
  readonly: A,
7737
7747
  onSelectAllRecords: T
7738
- } = e, R = Y(null), [b, V] = x([]), F = Y(!1), [O, k] = x(), { t: _ } = fe(), $ = Y(r), L = te(
7748
+ } = e, R = Y(null), [b, E] = x([]), F = Y(!1), [O, k] = x(), { t: _ } = fe(), $ = Y(r), L = te(
7739
7749
  lt
7740
- ), { title: W = void 0, setTitle: B = void 0 } = (C ? L : {}) || {}, E = oe(() => {
7750
+ ), { title: W = void 0, setTitle: B = void 0 } = (C ? L : {}) || {}, V = oe(() => {
7741
7751
  if (O)
7742
7752
  return go(
7743
7753
  O,
@@ -7753,14 +7763,14 @@ const wa = wt(Gp), ki = (e, t = "14px -apple-system") => {
7753
7763
  (j = R.current) == null || j.unselectAll();
7754
7764
  }
7755
7765
  })), le(() => {
7756
- const j = Et(s);
7766
+ const j = Vt(s);
7757
7767
  k(j), j.string && W !== j.string && (B == null || B(j.string));
7758
7768
  }, [s, W]), le(() => {
7759
7769
  if (!O)
7760
7770
  return;
7761
7771
  F.current = !1;
7762
7772
  const j = ur(O, a);
7763
- V(j);
7773
+ E(j);
7764
7774
  }, [a]), le(() => {
7765
7775
  $.current = r;
7766
7776
  }, [r]);
@@ -7816,9 +7826,9 @@ const wa = wt(Gp), ki = (e, t = "14px -apple-system") => {
7816
7826
  ge.push(`${J.label}: ${Math.round(ie * 100) / 100}`);
7817
7827
  }), /* @__PURE__ */ i("div", { className: "p-1 pb-0 pl-2 mt-2 ", children: ge.join(", ") });
7818
7828
  }, [b, d, O]), ee = oe(() => {
7819
- if (O !== null && E && E.length > 0)
7820
- return Kp(E, b, 600);
7821
- }, [E, b, O]), G = oe(() => h && (O != null && O.columns.some((j) => j.sum !== void 0)) ? h - 30 : h, [h, O == null ? void 0 : O.columns]);
7829
+ if (O !== null && V && V.length > 0)
7830
+ return Kp(V, b, 600);
7831
+ }, [V, b, O]), G = oe(() => h && (O != null && O.columns.some((j) => j.sum !== void 0)) ? h - 30 : h, [h, O == null ? void 0 : O.columns]);
7822
7832
  return O === null || !ee || ((M = ee == null ? void 0 : ee.columns) == null ? void 0 : M.length) === 0 ? /* @__PURE__ */ i(Ke, { style: { padding: "2rem" } }) : /* @__PURE__ */ D(Un, { children: [
7823
7833
  H,
7824
7834
  /* @__PURE__ */ i(
@@ -7884,7 +7894,7 @@ const Sa = (e) => {
7884
7894
  searchParams: A = [],
7885
7895
  setSearchValues: T,
7886
7896
  clearSelection: R
7887
- } = e, [b, V] = x(!1), [F, O] = x(!1), [k, _] = x(), [$, L] = x(1), [W, B] = x(0), [E, Z] = x(), [ne, Q] = x([]), [H, re] = x(void 0), [ee, G] = x(void 0), M = Y(C || Pt), j = Y([]), ge = P(
7897
+ } = e, [b, E] = x(!1), [F, O] = x(!1), [k, _] = x(), [$, L] = x(1), [W, B] = x(0), [V, Z] = x(), [ne, Q] = x([]), [H, re] = x(void 0), [ee, G] = x(void 0), M = Y(C || Pt), j = Y([]), ge = P(
7888
7898
  (de) => {
7889
7899
  y == null || y([...de]), Q([...de]);
7890
7900
  },
@@ -7898,7 +7908,7 @@ const Sa = (e) => {
7898
7908
  context: u
7899
7909
  });
7900
7910
  if (Z(de.length), f == null || f(de.length), de.length > 0) {
7901
- const xe = de.map((Se) => Se == null ? void 0 : Se[0]), { colors: ue, status: Fe } = Et(d), q = {};
7911
+ const xe = de.map((Se) => Se == null ? void 0 : Se[0]), { colors: ue, status: Fe } = Vt(d), q = {};
7902
7912
  ue && (q.colors = ue), Fe && (q.status = Fe);
7903
7913
  const ye = await N.getHandler().readEvalUiObjects({
7904
7914
  model: t,
@@ -7917,7 +7927,7 @@ const Sa = (e) => {
7917
7927
  ge(Pe), qe.length > 0 ? g == null || g(0) : g == null || g(void 0);
7918
7928
  } else
7919
7929
  ge([]), g == null || g(void 0);
7920
- V(!1), c.current = !0;
7930
+ E(!1), c.current = !0;
7921
7931
  }, [
7922
7932
  ge,
7923
7933
  c,
@@ -7932,7 +7942,7 @@ const Sa = (e) => {
7932
7942
  f
7933
7943
  ]), ie = P(
7934
7944
  async (de) => {
7935
- const { params: xe, newOffset: ue } = de || {}, Fe = cn(xe || A, w), { colors: q, status: ye } = Et(d), Ie = {};
7945
+ const { params: xe, newOffset: ue } = de || {}, Fe = cn(xe || A, w), { colors: q, status: ye } = Vt(d), Ie = {};
7936
7946
  q && (Ie.colors = q), ye && (Ie.status = ye);
7937
7947
  const { totalItems: qe, results: Pe, attrsEvaluated: Se } = await N.getHandler().searchForTree({
7938
7948
  params: Fe,
@@ -7956,7 +7966,7 @@ const Sa = (e) => {
7956
7966
  Je === -1 ? g == null || g(0) : g == null || g(Je);
7957
7967
  } else
7958
7968
  g == null || g(void 0);
7959
- V(!1);
7969
+ E(!1);
7960
7970
  const Me = await qe();
7961
7971
  Z(Me), f == null || f(Me);
7962
7972
  },
@@ -7978,9 +7988,9 @@ const Sa = (e) => {
7978
7988
  ), me = P(
7979
7989
  async (de) => {
7980
7990
  try {
7981
- V(!0), a == null || a(!0), l && !c.current ? await J() : await ie(de), R == null || R();
7991
+ E(!0), a == null || a(!0), l && !c.current ? await J() : await ie(de), R == null || R();
7982
7992
  } catch (xe) {
7983
- _(typeof xe == "string" ? xe : xe.message), V(!1);
7993
+ _(typeof xe == "string" ? xe : xe.message), E(!1);
7984
7994
  } finally {
7985
7995
  r == null || r([]), O(!1), a == null || a(!1);
7986
7996
  }
@@ -8032,11 +8042,11 @@ const Sa = (e) => {
8032
8042
  me,
8033
8043
  S
8034
8044
  ]
8035
- ), Ee = P(
8045
+ ), Ve = P(
8036
8046
  (de) => {
8037
- V(!0), L(de), B((de - 1) * C);
8047
+ E(!0), L(de), B((de - 1) * C);
8038
8048
  },
8039
- [V, C, B, L]
8049
+ [E, C, B, L]
8040
8050
  ), Ne = P(() => {
8041
8051
  b || (n == null || n(void 0), o == null || o([]), T == null || T({}), _(void 0), B(0), L(1), S == null || S(C || Pt));
8042
8052
  }, [
@@ -8054,15 +8064,15 @@ const Sa = (e) => {
8054
8064
  fields: d.field_parent ? { ...d.fields, [d.field_parent]: {} } : d.fields,
8055
8065
  context: u
8056
8066
  });
8057
- return ge([...z(), ...ue]), ur(Et(d), ue);
8067
+ return ge([...z(), ...ue]), ur(Vt(d), ue);
8058
8068
  },
8059
8069
  [d, t, u, z, ge]
8060
8070
  ), Oe = P(async () => await N.getHandler().searchAllIds({
8061
8071
  params: cn(A, w),
8062
8072
  model: t,
8063
8073
  context: u,
8064
- totalItems: E
8065
- }), [t, u, E, A, w]);
8074
+ totalItems: V
8075
+ }), [t, u, V, A, w]);
8066
8076
  return {
8067
8077
  submit: $e,
8068
8078
  clear: Ne,
@@ -8074,12 +8084,12 @@ const Sa = (e) => {
8074
8084
  offset: W,
8075
8085
  limit: M.current,
8076
8086
  getResults: z,
8077
- requestPageChange: Ee,
8087
+ requestPageChange: Ve,
8078
8088
  changeSort: ke,
8079
8089
  fetchChildrenForRecord: Be,
8080
8090
  colorsForResults: H,
8081
8091
  statusForResults: ee,
8082
- totalItems: E,
8092
+ totalItems: V,
8083
8093
  getAllIds: Oe
8084
8094
  };
8085
8095
  };
@@ -8097,13 +8107,13 @@ function zp(e, t) {
8097
8107
  rootTree: f = !1,
8098
8108
  parentContext: d = {},
8099
8109
  onChangeSelectedRowKeys: p
8100
- } = e, [h, m] = x(!1), [g, y] = x(!1), v = Y(!1), w = Y(null), [I, C] = x(), [S, A] = x(), [T, R] = x(), [b, V] = x(), [F, O] = x(200), k = Y(), { height: _ } = lr(), $ = te(
8110
+ } = e, [h, m] = x(!1), [g, y] = x(!1), v = Y(!1), w = Y(null), [I, C] = x(), [S, A] = x(), [T, R] = x(), [b, E] = x(), [F, O] = x(200), k = Y(), { height: _ } = lr(), $ = te(
8101
8111
  gn
8102
8112
  ), { processAction: L } = $ || {}, W = te(
8103
8113
  lt
8104
8114
  ), {
8105
8115
  setResults: B = void 0,
8106
- setCurrentItemIndex: E = void 0,
8116
+ setCurrentItemIndex: V = void 0,
8107
8117
  currentId: Z = void 0,
8108
8118
  results: ne = void 0,
8109
8119
  selectedRowItems: Q = void 0,
@@ -8120,7 +8130,7 @@ function zp(e, t) {
8120
8130
  searchValues: me = {},
8121
8131
  setSearchValues: ke = void 0,
8122
8132
  limit: $e = Pt,
8123
- setLimit: Ee = void 0
8133
+ setLimit: Ve = void 0
8124
8134
  } = (f ? W : {}) || {}, Ne = P(
8125
8135
  (Re) => {
8126
8136
  H == null || H(Re.map((ct) => ({ id: ct }))), p == null || p(Re);
@@ -8160,14 +8170,14 @@ function zp(e, t) {
8160
8170
  treeView: S,
8161
8171
  sorter: j,
8162
8172
  setSorter: ge,
8163
- setCurrentItemIndex: E,
8173
+ setCurrentItemIndex: V,
8164
8174
  setResultsActionView: B,
8165
8175
  resultsActionView: ne,
8166
8176
  domain: c,
8167
8177
  currentId: Z,
8168
8178
  setActionViewTotalItems: z,
8169
8179
  limit: $e,
8170
- setLimit: Ee,
8180
+ setLimit: Ve,
8171
8181
  clearSelection: (It = w.current) == null ? void 0 : It.unselectAll
8172
8182
  });
8173
8183
  bt(t, () => ({
@@ -8180,11 +8190,11 @@ function zp(e, t) {
8180
8190
  g && u && S && (v.current = !1, de());
8181
8191
  }, [q, Ie, g, u, a, S]);
8182
8192
  const we = async () => {
8183
- y(!1), m(!0), V(void 0), ie == null || ie(!0);
8193
+ y(!1), m(!0), E(void 0), ie == null || ie(!0);
8184
8194
  try {
8185
8195
  await Le(), y(!0);
8186
8196
  } catch (Re) {
8187
- V(Re), ie == null || ie(!1);
8197
+ E(Re), ie == null || ie(!1);
8188
8198
  } finally {
8189
8199
  m(!1);
8190
8200
  }
@@ -8208,9 +8218,9 @@ function zp(e, t) {
8208
8218
  }, [n]);
8209
8219
  const Te = P(
8210
8220
  (Re) => {
8211
- Ee == null || Ee(Re);
8221
+ Ve == null || Ve(Re);
8212
8222
  },
8213
- [Ee]
8223
+ [Ve]
8214
8224
  ), be = P(
8215
8225
  async (Re) => {
8216
8226
  const { id: ct } = Re;
@@ -8337,7 +8347,7 @@ function zp(e, t) {
8337
8347
  ]), qt = b || Fe;
8338
8348
  return qt ? /* @__PURE__ */ i(ot, { className: "mt-10", message: qt, type: "error", banner: !0 }) : /* @__PURE__ */ i("div", { style: u ? {} : { display: "none" }, children: h ? /* @__PURE__ */ i(Ke, {}) : mt() });
8339
8349
  }
8340
- const Ca = wt(zp), Vo = ({
8350
+ const Ca = wt(zp), Eo = ({
8341
8351
  visible: e,
8342
8352
  onCloseModal: t,
8343
8353
  onSelectValues: n,
@@ -8386,7 +8396,7 @@ const Ca = wt(zp), Vo = ({
8386
8396
  [I]
8387
8397
  ), b = P(() => {
8388
8398
  c(!0);
8389
- }, []), V = P(() => {
8399
+ }, []), E = P(() => {
8390
8400
  c(!1), S();
8391
8401
  }, [S]), F = P(
8392
8402
  (O) => {
@@ -8456,7 +8466,7 @@ const Ca = wt(zp), Vo = ({
8456
8466
  visible: l,
8457
8467
  parentContext: a,
8458
8468
  onSubmitSucceed: F,
8459
- onCancel: V
8469
+ onCancel: E
8460
8470
  }
8461
8471
  )
8462
8472
  ] });
@@ -8478,7 +8488,7 @@ const Ca = wt(zp), Vo = ({
8478
8488
  context: l,
8479
8489
  id: c,
8480
8490
  domain: u
8481
- } = r, f = o && !a ? { backgroundColor: xa.colorPrimaryBg } : void 0, [d, p] = x(!1), [h, m] = x(!1), [g, y] = x(!1), [v, w] = x(), I = Y(!1), [C, S] = x(""), A = Y(), T = te(Ue), { domain: R, getValues: b, getFields: V, getContext: F, elementHasLostFocus: O } = T || {}, k = Y([]), [_, $] = x([]), L = t && t[0] || void 0, W = t && t[1] || "";
8491
+ } = r, f = o && !a ? { backgroundColor: xa.colorPrimaryBg } : void 0, [d, p] = x(!1), [h, m] = x(!1), [g, y] = x(!1), [v, w] = x(), I = Y(!1), [C, S] = x(""), A = Y(), T = te(Ue), { domain: R, getValues: b, getFields: E, getContext: F, elementHasLostFocus: O } = T || {}, k = Y([]), [_, $] = x([]), L = t && t[0] || void 0, W = t && t[1] || "";
8482
8492
  le(() => {
8483
8493
  !Array.isArray(t) && t && Q(t);
8484
8494
  }, [t]), le(() => {
@@ -8486,7 +8496,7 @@ const Ca = wt(zp), Vo = ({
8486
8496
  }, [t]);
8487
8497
  const B = (G) => {
8488
8498
  n == null || n(G), O == null || O();
8489
- }, E = (G) => {
8499
+ }, V = (G) => {
8490
8500
  A.current = G.target.value, B([void 0, ""]);
8491
8501
  }, Z = async () => {
8492
8502
  if (!g && C !== W) {
@@ -8544,10 +8554,10 @@ const Ca = wt(zp), Vo = ({
8544
8554
  u && (k.current = await N.getHandler().evalDomain({
8545
8555
  domain: u,
8546
8556
  values: Kt({
8547
- fields: V(),
8557
+ fields: E(),
8548
8558
  values: b()
8549
8559
  }),
8550
- fields: V(),
8560
+ fields: E(),
8551
8561
  context: F()
8552
8562
  })), R && R.length > 0 && (k.current = k.current.concat(
8553
8563
  eo({
@@ -8566,7 +8576,7 @@ const Ca = wt(zp), Vo = ({
8566
8576
  type: "text",
8567
8577
  value: C,
8568
8578
  disabled: a,
8569
- onChange: E,
8579
+ onChange: V,
8570
8580
  style: {
8571
8581
  ...f,
8572
8582
  borderTopRightRadius: 0,
@@ -8609,7 +8619,7 @@ const Ca = wt(zp), Vo = ({
8609
8619
  }
8610
8620
  ) }),
8611
8621
  /* @__PURE__ */ i(
8612
- Vo,
8622
+ Eo,
8613
8623
  {
8614
8624
  model: s,
8615
8625
  domain: _,
@@ -8897,7 +8907,7 @@ const ih = (e) => {
8897
8907
  getContext: m,
8898
8908
  domain: g,
8899
8909
  fetchValues: y
8900
- } = f || {}, { t: v } = fe(), [w, I] = x(!1), [C, S] = x(!1), [A, T] = x(), [R, b] = x(!1), [V, F] = x(!1), [O, k] = x(), [_, $] = x([]), [L, W] = x(!1), B = Y([]), [E, Z] = x(), ne = Y(), [Q, H] = x(void 0), {
8910
+ } = f || {}, { t: v } = fe(), [w, I] = x(!1), [C, S] = x(!1), [A, T] = x(), [R, b] = x(!1), [E, F] = x(!1), [O, k] = x(), [_, $] = x([]), [L, W] = x(!1), B = Y([]), [V, Z] = x(), ne = Y(), [Q, H] = x(void 0), {
8901
8911
  readOnly: re,
8902
8912
  relation: ee,
8903
8913
  context: G,
@@ -8916,7 +8926,7 @@ const ih = (e) => {
8916
8926
  (a === "form" && s.some((X) => !X.values) || a === "tree" && s.some((X) => !X.treeValues)) && ke();
8917
8927
  }, [s, a]);
8918
8928
  le(() => {
8919
- Ee();
8929
+ Ve();
8920
8930
  }, [g]);
8921
8931
  const me = (X) => {
8922
8932
  var we, Le;
@@ -8950,7 +8960,7 @@ const ih = (e) => {
8950
8960
  S(!1);
8951
8961
  }
8952
8962
  };
8953
- async function Ee() {
8963
+ async function Ve() {
8954
8964
  M && (B.current = await N.getHandler().evalDomain({
8955
8965
  domain: M,
8956
8966
  values: Kt({
@@ -9157,9 +9167,9 @@ const ih = (e) => {
9157
9167
  }
9158
9168
  );
9159
9169
  let X = [];
9160
- if (z.some((De) => De.treeValues) && (X = E ? on({
9170
+ if (z.some((De) => De.treeValues) && (X = V ? on({
9161
9171
  resultsToSort: z.map((De) => De.treeValues),
9162
- sorter: E,
9172
+ sorter: V,
9163
9173
  fields: {
9164
9174
  ...o.get("tree").fields,
9165
9175
  ...((Te = o.get("form")) == null ? void 0 : Te.fields) || {}
@@ -9177,7 +9187,7 @@ const ih = (e) => {
9177
9187
  showPagination: !1,
9178
9188
  selectedRowKeys: _,
9179
9189
  onRowSelectionChange: $,
9180
- sorter: E,
9190
+ sorter: V,
9181
9191
  onChangeSort: Z,
9182
9192
  context: { ...m == null ? void 0 : m(), ...G },
9183
9193
  colorsForResults: Q,
@@ -9248,12 +9258,12 @@ const ih = (e) => {
9248
9258
  }
9249
9259
  ),
9250
9260
  /* @__PURE__ */ i(
9251
- Vo,
9261
+ Eo,
9252
9262
  {
9253
9263
  domain: B.current,
9254
9264
  model: ee,
9255
9265
  context: { ...m == null ? void 0 : m(), ...G },
9256
- visible: V,
9266
+ visible: E,
9257
9267
  onSelectValues: async (X) => {
9258
9268
  F(!1), Se(X);
9259
9269
  },
@@ -9306,7 +9316,7 @@ const ih = (e) => {
9306
9316
  s.length === 0 ? h = !0 : h = !1, h ? (a(r), (m = o.current) == null || m.setSelectedRows(r)) : (a([]), (g = o.current) == null || g.setSelectedRows([]));
9307
9317
  }, [r, o, s.length]), u = P((h) => {
9308
9318
  l.current = h;
9309
- }, []), f = P(() => l.current, []), d = oe(() => Et(e), [e]);
9319
+ }, []), f = P(() => l.current, []), d = oe(() => Vt(e), [e]);
9310
9320
  return {
9311
9321
  onTreeFetchRows: gt(
9312
9322
  async ({
@@ -9335,9 +9345,9 @@ const ih = (e) => {
9335
9345
  context: n,
9336
9346
  attrs: S,
9337
9347
  treeOoui: d
9338
- }), V = C.length < g - m && I.length > 0 ? [...C, ...I.map((O) => O.id)] : C;
9348
+ }), E = C.length < g - m && I.length > 0 ? [...C, ...I.map((O) => O.id)] : C;
9339
9349
  return { results: ed({
9340
- finalResultIds: V,
9350
+ finalResultIds: E,
9341
9351
  fetchedItems: A,
9342
9352
  otherItems: I
9343
9353
  }), colors: T, status: R };
@@ -9561,19 +9571,19 @@ const mh = ({
9561
9571
  treeValues: { ...T, id: S }
9562
9572
  });
9563
9573
  else if (S)
9564
- b = o.map((V) => V.id === S ? {
9574
+ b = o.map((E) => E.id === S ? {
9565
9575
  id: S,
9566
9576
  operation: S > 0 ? "pendingUpdate" : "pendingCreate",
9567
9577
  values: { ...T, id: S },
9568
9578
  treeValues: { ...T, id: S }
9569
- } : V);
9579
+ } : E);
9570
9580
  else {
9571
- const V = Cs(o);
9581
+ const E = Cs(o);
9572
9582
  b = o.concat({
9573
- id: V,
9583
+ id: E,
9574
9584
  operation: "pendingCreate",
9575
- values: { ...T, id: V },
9576
- treeValues: { ...T, id: V }
9585
+ values: { ...T, id: E },
9586
+ treeValues: { ...T, id: E }
9577
9587
  });
9578
9588
  }
9579
9589
  s(b), g || p(!1);
@@ -9696,25 +9706,25 @@ const mh = ({
9696
9706
  ...Io
9697
9707
  },
9698
9708
  s
9699
- ), [s, o]), V = P(
9709
+ ), [s, o]), E = P(
9700
9710
  async ({
9701
9711
  startRow: $,
9702
9712
  endRow: L,
9703
9713
  sortFields: W
9704
9714
  }) => {
9705
- const { results: B, colors: E, status: Z } = await a({
9715
+ const { results: B, colors: V, status: Z } = await a({
9706
9716
  allItems: A.current,
9707
9717
  startRow: $,
9708
9718
  endRow: L,
9709
9719
  sortFields: W
9710
9720
  });
9711
- return I.current = { ...I.current, ...E }, !C.current && Z && (C.current = {}), Z && (C.current = { ...C.current, ...Z }), B;
9721
+ return I.current = { ...I.current, ...V }, !C.current && Z && (C.current = {}), Z && (C.current = { ...C.current, ...Z }), B;
9712
9722
  },
9713
9723
  [a]
9714
9724
  ), F = P(($) => {
9715
- var L, W, B, E;
9725
+ var L, W, B, V;
9716
9726
  if (I.current[(W = (L = $.node) == null ? void 0 : L.data) == null ? void 0 : W.id])
9717
- return { color: I.current[(E = (B = $.node) == null ? void 0 : B.data) == null ? void 0 : E.id] };
9727
+ return { color: I.current[(V = (B = $.node) == null ? void 0 : B.data) == null ? void 0 : V.id] };
9718
9728
  }, []), { loading: O, getColumnState: k, updateColumnState: _ } = Hs(
9719
9729
  hh({
9720
9730
  ...h,
@@ -9727,7 +9737,7 @@ const mh = ({
9727
9737
  ref: w,
9728
9738
  height: t || gh,
9729
9739
  columns: b,
9730
- onRequestData: V,
9740
+ onRequestData: E,
9731
9741
  onRowDoubleClick: n,
9732
9742
  showPointerCursorInRows: y,
9733
9743
  readonly: r,
@@ -9784,7 +9794,7 @@ const mh = ({
9784
9794
  fieldName: y
9785
9795
  }), {
9786
9796
  treeOoui: b,
9787
- onTreeFetchRows: V,
9797
+ onTreeFetchRows: E,
9788
9798
  selectedRowKeys: F,
9789
9799
  setSelectedRowKeys: O,
9790
9800
  onChangeFirstVisibleRowIndex: k,
@@ -9804,7 +9814,7 @@ const mh = ({
9804
9814
  }), W = oe(() => {
9805
9815
  const { title: ue } = s.get(c) || {};
9806
9816
  return ue || o.label;
9807
- }, [c, o.label, s]), B = o.type === "many2many", E = P(
9817
+ }, [c, o.label, s]), B = o.type === "many2many", V = P(
9808
9818
  (ue) => {
9809
9819
  var Fe, q;
9810
9820
  r == null || r({
@@ -9824,7 +9834,7 @@ const mh = ({
9824
9834
  treeView: s.get("tree"),
9825
9835
  relation: h,
9826
9836
  context: T,
9827
- triggerChange: E
9837
+ triggerChange: V
9828
9838
  }), {
9829
9839
  showFormModal: re,
9830
9840
  modalItem: ee,
@@ -9838,7 +9848,7 @@ const mh = ({
9838
9848
  inv_field: o.inv_field,
9839
9849
  showFormChangesDialogIfNeeded: Q,
9840
9850
  currentView: c,
9841
- triggerChange: E,
9851
+ triggerChange: V,
9842
9852
  items: l,
9843
9853
  setCurrentView: u,
9844
9854
  setItemIndex: d,
@@ -9853,7 +9863,7 @@ const mh = ({
9853
9863
  } = ph({
9854
9864
  showFormChangesDialogIfNeeded: Q,
9855
9865
  currentView: c,
9856
- triggerChange: E,
9866
+ triggerChange: V,
9857
9867
  items: l,
9858
9868
  views: s,
9859
9869
  context: T,
@@ -9861,11 +9871,11 @@ const mh = ({
9861
9871
  }), { showRemoveConfirm: $e } = uh({
9862
9872
  isMany2many: B,
9863
9873
  items: l,
9864
- triggerChange: E,
9874
+ triggerChange: V,
9865
9875
  setFormHasChanges: H,
9866
9876
  selectedRowKeys: F,
9867
9877
  setSelectedRowKeys: O
9868
- }), Ee = () => {
9878
+ }), Ve = () => {
9869
9879
  const ue = Array.from(s.keys()), Fe = ue[(ue.indexOf(c) + 1) % ue.length];
9870
9880
  c === "form" ? Q(() => {
9871
9881
  u(Fe);
@@ -9909,7 +9919,7 @@ const mh = ({
9909
9919
  currentItemIndex: f,
9910
9920
  onDelete: $e,
9911
9921
  onCreateItem: ge,
9912
- onToggleViewMode: Ee,
9922
+ onToggleViewMode: Ve,
9913
9923
  onPreviousItem: Be,
9914
9924
  onNextItem: Oe,
9915
9925
  onSearchItem: ke,
@@ -9925,7 +9935,7 @@ const mh = ({
9925
9935
  height: o.height,
9926
9936
  items: l,
9927
9937
  readOnly: p || !1,
9928
- onFetchRecords: V,
9938
+ onFetchRecords: E,
9929
9939
  ooui: b,
9930
9940
  context: T,
9931
9941
  onRowDoubleClick: Ne,
@@ -9976,7 +9986,7 @@ const mh = ({
9976
9986
  }
9977
9987
  ),
9978
9988
  /* @__PURE__ */ i(
9979
- Vo,
9989
+ Eo,
9980
9990
  {
9981
9991
  domain: R,
9982
9992
  model: h,
@@ -10162,7 +10172,7 @@ function Fh(e) {
10162
10172
  const { useToken: Rh } = We, { TextArea: Kr } = rt, _h = (e) => {
10163
10173
  const { ooui: t } = e, { id: n, readOnly: r, required: o, height: s, translatable: a } = t, { token: l } = Rh(), c = o && !r ? { backgroundColor: l.colorPrimaryBg } : void 0, u = te(Ue), { elementHasLostFocus: f } = u || {};
10164
10174
  return /* @__PURE__ */ i(_e, { required: o, ...e, children: a ? /* @__PURE__ */ i(
10165
- Vh,
10175
+ Eh,
10166
10176
  {
10167
10177
  field: n,
10168
10178
  height: s,
@@ -10182,7 +10192,7 @@ const { useToken: Rh } = We, { TextArea: Kr } = rt, _h = (e) => {
10182
10192
  onBlur: f
10183
10193
  }
10184
10194
  ) });
10185
- }, Vh = ({
10195
+ }, Eh = ({
10186
10196
  value: e,
10187
10197
  field: t,
10188
10198
  requiredStyle: n,
@@ -10272,7 +10282,7 @@ const { useToken: Rh } = We, { TextArea: Kr } = rt, _h = (e) => {
10272
10282
  }
10273
10283
  ) })
10274
10284
  ] });
10275
- }, Eh = (e) => {
10285
+ }, Vh = (e) => {
10276
10286
  const { ooui: t } = e, { label: n, icon: r } = t, o = ft(r || "");
10277
10287
  return /* @__PURE__ */ i(Qn, { orientation: "left", className: "text-sm", children: (o || n) && /* @__PURE__ */ D(Xe, { children: [
10278
10288
  o ? /* @__PURE__ */ i(o, {}) : null,
@@ -10708,7 +10718,7 @@ const { useToken: Rh } = We, { TextArea: Kr } = rt, _h = (e) => {
10708
10718
  function Ni(e) {
10709
10719
  return e ? (_r == null ? void 0 : _r[e.type]) || /* @__PURE__ */ i(xn, {}) : /* @__PURE__ */ i(xn, {});
10710
10720
  }
10711
- function Eo(e) {
10721
+ function Vo(e) {
10712
10722
  const {
10713
10723
  currentView: t,
10714
10724
  availableViews: n,
@@ -10816,8 +10826,8 @@ function it(e) {
10816
10826
  }
10817
10827
  );
10818
10828
  }
10819
- const Va = (e) => /* @__PURE__ */ i(it, { ...e, type: "primary", danger: !0 });
10820
- function Ea(e) {
10829
+ const Ea = (e) => /* @__PURE__ */ i(it, { ...e, type: "primary", danger: !0 });
10830
+ function Va(e) {
10821
10831
  const { disabled: t = !1 } = e, { formHasChanges: n, onNewClicked: r } = te(
10822
10832
  lt
10823
10833
  ), { t: o } = fe(), s = () => {
@@ -11164,12 +11174,12 @@ function eg({ toolbar: e }) {
11164
11174
  formIsLoading: T,
11165
11175
  attachments: R,
11166
11176
  formRef: b,
11167
- setFormHasChanges: V,
11177
+ setFormHasChanges: E,
11168
11178
  previousView: F,
11169
11179
  setPreviousView: O,
11170
11180
  goToResourceId: k,
11171
11181
  isActive: _
11172
- } = wo(), { processAction: $ } = t || {}, { openRelate: L, openDefaultActionForModel: W } = n || {}, B = d || I || T || C, E = P(
11182
+ } = wo(), { processAction: $ } = t || {}, { openRelate: L, openDefaultActionForModel: W } = n || {}, B = d || I || T || C, V = P(
11173
11183
  (H) => {
11174
11184
  f ? hn({ t: r, onOk: H }) : H();
11175
11185
  },
@@ -11230,14 +11240,14 @@ function eg({ toolbar: e }) {
11230
11240
  );
11231
11241
  return Lt(
11232
11242
  "pagedown",
11233
- () => _ && E(o),
11243
+ () => _ && V(o),
11234
11244
  { enableOnFormTags: !0, preventDefault: !0 },
11235
- [_, E, o]
11245
+ [_, V, o]
11236
11246
  ), Lt(
11237
11247
  "pageup",
11238
- () => _ && E(s),
11248
+ () => _ && V(s),
11239
11249
  { enableOnFormTags: !0, preventDefault: !0 },
11240
- [_, E, s]
11250
+ [_, V, s]
11241
11251
  ), Lt(
11242
11252
  "ctrl+s,command+s",
11243
11253
  () => _ && (u == null ? void 0 : u()),
@@ -11256,7 +11266,7 @@ function eg({ toolbar: e }) {
11256
11266
  Xt(),
11257
11267
  Xt()
11258
11268
  ] }),
11259
- /* @__PURE__ */ i(Ea, { disabled: B }),
11269
+ /* @__PURE__ */ i(Va, { disabled: B }),
11260
11270
  /* @__PURE__ */ i(
11261
11271
  it,
11262
11272
  {
@@ -11282,7 +11292,7 @@ function eg({ toolbar: e }) {
11282
11292
  }
11283
11293
  ),
11284
11294
  /* @__PURE__ */ i(
11285
- Va,
11295
+ Ea,
11286
11296
  {
11287
11297
  icon: /* @__PURE__ */ i(ao, {}),
11288
11298
  tooltip: r("delete"),
@@ -11311,18 +11321,18 @@ function eg({ toolbar: e }) {
11311
11321
  icon: /* @__PURE__ */ i(ir, {}),
11312
11322
  tooltip: r("refresh"),
11313
11323
  disabled: B || p === void 0,
11314
- onClick: () => E(() => b.current.fetchValues())
11324
+ onClick: () => V(() => b.current.fetchValues())
11315
11325
  }
11316
11326
  ),
11317
11327
  Xt(),
11318
11328
  /* @__PURE__ */ i(
11319
- Eo,
11329
+ Vo,
11320
11330
  {
11321
11331
  currentView: l,
11322
11332
  previousView: F,
11323
11333
  availableViews: a,
11324
11334
  onChangeView: (H) => {
11325
- O == null || O(l), V == null || V(!1), c == null || c(H);
11335
+ O == null || O(l), E == null || E(!1), c == null || c(H);
11326
11336
  },
11327
11337
  disabled: B,
11328
11338
  formHasChanges: f
@@ -11336,7 +11346,7 @@ function eg({ toolbar: e }) {
11336
11346
  icon: /* @__PURE__ */ i(ts, {}),
11337
11347
  tooltip: r("previous"),
11338
11348
  disabled: B,
11339
- onClick: () => E(s)
11349
+ onClick: () => V(s)
11340
11350
  }
11341
11351
  ),
11342
11352
  /* @__PURE__ */ i(
@@ -11345,7 +11355,7 @@ function eg({ toolbar: e }) {
11345
11355
  icon: /* @__PURE__ */ i(ns, {}),
11346
11356
  tooltip: r("next"),
11347
11357
  disabled: B,
11348
- onClick: () => E(o)
11358
+ onClick: () => V(o)
11349
11359
  }
11350
11360
  )
11351
11361
  ] }),
@@ -11686,7 +11696,7 @@ function sg({ refreshGraph: e }) {
11686
11696
  }
11687
11697
  ),
11688
11698
  /* @__PURE__ */ i(
11689
- Eo,
11699
+ Vo,
11690
11700
  {
11691
11701
  currentView: r,
11692
11702
  availableViews: n,
@@ -11824,7 +11834,7 @@ const { useToken: ag } = We, { Title: lg, Text: jn } = kt, pr = ({
11824
11834
  limit: T,
11825
11835
  setLimit: R,
11826
11836
  searchParams: b,
11827
- searchValues: V,
11837
+ searchValues: E,
11828
11838
  setSearchValues: F,
11829
11839
  currentView: O
11830
11840
  } = u || {}, [k, _] = x(!0);
@@ -11834,7 +11844,7 @@ const { useToken: ag } = We, { Title: lg, Text: jn } = kt, pr = ({
11834
11844
  }, [b]), le(() => {
11835
11845
  t.view_id !== O.view_id && _(!0);
11836
11846
  }, [O]);
11837
- const { clear: $, searchFilterLoading: L, searchError: W, offset: B, tableRefreshing: E } = Sa({
11847
+ const { clear: $, searchFilterLoading: L, searchError: W, offset: B, tableRefreshing: V } = Sa({
11838
11848
  model: r,
11839
11849
  setSearchTreeNameSearch: S,
11840
11850
  setSelectedRowItems: m,
@@ -11883,11 +11893,11 @@ const { useToken: ag } = We, { Title: lg, Text: jn } = kt, pr = ({
11883
11893
  },
11884
11894
  searchError: W,
11885
11895
  searchVisible: y,
11886
- searchValues: V,
11896
+ searchValues: E,
11887
11897
  showLimitOptions: !1
11888
11898
  }
11889
11899
  ),
11890
- E ? /* @__PURE__ */ i(Ke, {}) : /* @__PURE__ */ i(
11900
+ V ? /* @__PURE__ */ i(Ke, {}) : /* @__PURE__ */ i(
11891
11901
  mn,
11892
11902
  {
11893
11903
  ref: c,
@@ -12005,11 +12015,11 @@ function fg(e) {
12005
12015
  totalItems: T,
12006
12016
  isActive: R,
12007
12017
  isInfiniteTree: b
12008
- } = te(lt), { parentContext: V = {}, treeExpandable: F, toolbar: O } = e, k = fr(
12018
+ } = te(lt), { parentContext: E = {}, treeExpandable: F, toolbar: O } = e, k = fr(
12009
12019
  pn.FEATURE_ADVANCED_EXPORT
12010
12020
  ), { t: _ } = fe(), $ = te(
12011
12021
  gn
12012
- ), { processAction: L } = $ || {}, [W, B] = x(!1), E = Y(!0);
12022
+ ), { processAction: L } = $ || {}, [W, B] = x(!1), V = Y(!0);
12013
12023
  Lt(
12014
12024
  "ctrl+l,command+l",
12015
12025
  () => {
@@ -12027,8 +12037,8 @@ function fg(e) {
12027
12037
  ), le(() => {
12028
12038
  var M;
12029
12039
  if (b && v === void 0) {
12030
- if (E.current) {
12031
- E.current = !1;
12040
+ if (V.current) {
12041
+ V.current = !1;
12032
12042
  return;
12033
12043
  }
12034
12044
  (M = f == null ? void 0 : f.current) == null || M.refreshResults();
@@ -12059,7 +12069,7 @@ function fg(e) {
12059
12069
  s == null || s(!0), await N.getHandler().deleteObjects({
12060
12070
  model: u,
12061
12071
  ids: o.map((j) => j.id),
12062
- context: { ...V }
12072
+ context: { ...E }
12063
12073
  }), d == null || d(void 0), p == null || p(void 0), (M = f == null ? void 0 : f.current) == null || M.refreshResults();
12064
12074
  } catch (j) {
12065
12075
  st(j);
@@ -12075,7 +12085,7 @@ function fg(e) {
12075
12085
  await N.getHandler().duplicate({
12076
12086
  id: j,
12077
12087
  model: u,
12078
- context: { ...V }
12088
+ context: { ...E }
12079
12089
  }) && ((M = f == null ? void 0 : f.current) == null || M.refreshResults());
12080
12090
  } catch (j) {
12081
12091
  st(j);
@@ -12092,7 +12102,7 @@ function fg(e) {
12092
12102
  },
12093
12103
  fields: {},
12094
12104
  context: {
12095
- ...V,
12105
+ ...E,
12096
12106
  active_id: o == null ? void 0 : o.map((j) => j.id)[0],
12097
12107
  active_ids: o == null ? void 0 : o.map((j) => j.id)
12098
12108
  },
@@ -12139,7 +12149,7 @@ function fg(e) {
12139
12149
  }
12140
12150
  ),
12141
12151
  Mt(),
12142
- /* @__PURE__ */ i(Ea, { disabled: w }),
12152
+ /* @__PURE__ */ i(Va, { disabled: w }),
12143
12153
  /* @__PURE__ */ i(
12144
12154
  it,
12145
12155
  {
@@ -12151,7 +12161,7 @@ function fg(e) {
12151
12161
  }
12152
12162
  ),
12153
12163
  /* @__PURE__ */ i(
12154
- Va,
12164
+ Ea,
12155
12165
  {
12156
12166
  icon: /* @__PURE__ */ i(ao, {}),
12157
12167
  tooltip: _("delete"),
@@ -12190,7 +12200,7 @@ function fg(e) {
12190
12200
  !F && /* @__PURE__ */ D(ae, { children: [
12191
12201
  Mt(),
12192
12202
  /* @__PURE__ */ i(
12193
- Eo,
12203
+ Vo,
12194
12204
  {
12195
12205
  currentView: n,
12196
12206
  availableViews: t,
@@ -12316,7 +12326,7 @@ function fg(e) {
12316
12326
  totalRegisters: T || 0,
12317
12327
  selectedRegistersToExport: o,
12318
12328
  visibleRegisters: (S == null ? void 0 : S.length) || 0,
12319
- context: V
12329
+ context: E
12320
12330
  }
12321
12331
  )
12322
12332
  ] })
@@ -12533,7 +12543,7 @@ function wg(e, t) {
12533
12543
  limit: y
12534
12544
  } = e, [v, w] = x(), [I, C] = x([]), [S, A] = x(!0), T = p || void 0, [R, b] = x(
12535
12545
  T
12536
- ), [V, F] = x([]), [O, k] = x(), [_, $] = x([]), [L, W] = x(), [B, E] = x(0), [Z, ne] = x(!1), [Q, H] = x(!1), [re, ee] = x(), { t: G } = fe(), M = Y(), j = Y(), ge = te(
12546
+ ), [E, F] = x([]), [O, k] = x(), [_, $] = x([]), [L, W] = x(), [B, V] = x(0), [Z, ne] = x(!1), [Q, H] = x(!1), [re, ee] = x(), { t: G } = fe(), M = Y(), j = Y(), ge = te(
12537
12547
  Ct
12538
12548
  ), {
12539
12549
  setCurrentView: z,
@@ -12551,7 +12561,7 @@ function wg(e, t) {
12551
12561
  { enableOnFormTags: !0, preventDefault: !0 },
12552
12562
  [me, ie, v, O, _]
12553
12563
  );
12554
- function Ee(q) {
12564
+ function Ve(q) {
12555
12565
  b(q), J == null || J(q);
12556
12566
  }
12557
12567
  function Ne(q) {
@@ -12644,7 +12654,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12644
12654
  };
12645
12655
  l({ tabKey: c, canWeClose: Oe }), le(() => {
12646
12656
  const q = I.find((Ie) => Ie.type === "tree"), ye = I.find((Ie) => u.id ? Ie.type === u.type && Ie.view_id === u.id : Ie.type === u.type);
12647
- Ne(ye || q), p ? J == null || J(T) : (Ee(void 0), k(void 0)), Be();
12657
+ Ne(ye || q), p ? J == null || J(T) : (Ve(void 0), k(void 0)), Be();
12648
12658
  }, [r, s, p]), le(() => {
12649
12659
  if (me === c) {
12650
12660
  J == null || J(R);
@@ -12684,7 +12694,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12684
12694
  } else
12685
12695
  Ie = "tree", qe = [["id", "in", q]];
12686
12696
  if (H(!1), ne(!1), ye && Ie === "form") {
12687
- Ee(q[0]);
12697
+ Ve(q[0]);
12688
12698
  const Se = I.find(
12689
12699
  (pe) => pe.type === "form"
12690
12700
  );
@@ -12743,7 +12753,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12743
12753
  availableViews: I,
12744
12754
  results: _,
12745
12755
  setCurrentItemIndex: k,
12746
- setCurrentId: Ee,
12756
+ setCurrentId: Ve,
12747
12757
  setCurrentView: Ne
12748
12758
  },
12749
12759
  `${q.type}-${q.view_id}`
@@ -12778,7 +12788,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12778
12788
  if (R === void 0 && v.type === "form")
12779
12789
  M.current.clearAndReload();
12780
12790
  else {
12781
- Ee(void 0);
12791
+ Ve(void 0);
12782
12792
  const q = I.find(
12783
12793
  (ye) => ye.type === "form"
12784
12794
  );
@@ -12796,7 +12806,7 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12796
12806
  searchTreeRef: j,
12797
12807
  onNewClicked: Fe,
12798
12808
  currentId: R,
12799
- setCurrentId: Ee,
12809
+ setCurrentId: Ve,
12800
12810
  setCurrentItemIndex: k,
12801
12811
  currentItemIndex: O,
12802
12812
  results: _,
@@ -12805,8 +12815,8 @@ Please, make sure the view ids on the fields_view_get responses are the same as
12805
12815
  sorter: L,
12806
12816
  setSorter: W,
12807
12817
  totalItems: B,
12808
- setTotalItems: E,
12809
- selectedRowItems: V,
12818
+ setTotalItems: V,
12819
+ selectedRowItems: E,
12810
12820
  setSelectedRowItems: F,
12811
12821
  setSearchTreeNameSearch: ee,
12812
12822
  searchTreeNameSearch: re,
@@ -12870,10 +12880,10 @@ function Cg(e) {
12870
12880
  domain: s = [],
12871
12881
  visible: a = !0,
12872
12882
  parentContext: l = {}
12873
- } = e, [c, u] = x(!1), [f, d] = x(!1), [p, h] = x(), [m, g] = x(), [y, v] = x(), [w, I] = x(1), [C, S] = x(0), A = Y(Pt), T = Y([]), [R, b] = x(0), [V, F] = x([]), [O, k] = x(void 0), [_, $] = x(), [L, W] = x(), [B, E] = x(), [Z, ne] = x(!1), Q = Y([]), H = (J) => {
12883
+ } = e, [c, u] = x(!1), [f, d] = x(!1), [p, h] = x(), [m, g] = x(), [y, v] = x(), [w, I] = x(1), [C, S] = x(0), A = Y(Pt), T = Y([]), [R, b] = x(0), [E, F] = x([]), [O, k] = x(void 0), [_, $] = x(), [L, W] = x(), [B, V] = x(), [Z, ne] = x(!1), Q = Y([]), H = (J) => {
12874
12884
  ne(!0), I(J), S((J - 1) * A.current);
12875
12885
  }, re = async () => {
12876
- const J = Q.current.length > 0 ? Q.current : s, ie = cn(T.current, J), { colors: me } = Et(m), { totalItems: ke, results: $e, attrsEvaluated: Ee } = await N.getHandler().searchForTree({
12886
+ const J = Q.current.length > 0 ? Q.current : s, ie = cn(T.current, J), { colors: me } = Vt(m), { totalItems: ke, results: $e, attrsEvaluated: Ve } = await N.getHandler().searchForTree({
12877
12887
  params: ie,
12878
12888
  limit: A.current,
12879
12889
  offset: C,
@@ -12882,7 +12892,7 @@ function Cg(e) {
12882
12892
  context: l,
12883
12893
  attrs: me && { colors: me }
12884
12894
  });
12885
- k(ln(Ee));
12895
+ k(ln(Ve));
12886
12896
  const Ne = on({
12887
12897
  resultsToSort: $e,
12888
12898
  sorter: _,
@@ -12902,11 +12912,11 @@ function Cg(e) {
12902
12912
  f && a && ee();
12903
12913
  }, [w, C, f, a]);
12904
12914
  const G = async (J) => {
12905
- d(!1), u(!0), E(void 0);
12915
+ d(!1), u(!0), V(void 0);
12906
12916
  try {
12907
12917
  J === "action" ? await M() : await j(), d(!0);
12908
12918
  } catch (ie) {
12909
- E(ie);
12919
+ V(ie);
12910
12920
  } finally {
12911
12921
  u(!1);
12912
12922
  }
@@ -12952,7 +12962,7 @@ function Cg(e) {
12952
12962
  limit: A.current,
12953
12963
  page: w,
12954
12964
  treeView: m,
12955
- results: V,
12965
+ results: E,
12956
12966
  onRequestPageChange: H,
12957
12967
  loading: Z,
12958
12968
  onRowClicked: ge,
@@ -12961,7 +12971,7 @@ function Cg(e) {
12961
12971
  onChangeSort: (J) => {
12962
12972
  $ == null || $(J);
12963
12973
  const ie = on({
12964
- resultsToSort: V,
12974
+ resultsToSort: E,
12965
12975
  sorter: J,
12966
12976
  fields: { ...m.fields, ...y.fields }
12967
12977
  });
@@ -12987,7 +12997,7 @@ const xg = yt(Cg), Ig = (e) => {
12987
12997
  s.length > 0 && r(s[0].id);
12988
12998
  }
12989
12999
  return /* @__PURE__ */ i("div", { style: { padding: "0.5rem", overflowY: "scroll" }, children: /* @__PURE__ */ i(yn, { ...e, model: t, id: n, readOnly: !0 }) });
12990
- }, Vr = "line_ids";
13000
+ }, Er = "line_ids";
12991
13001
  function Tg(e, t) {
12992
13002
  const { model: n, context: r = {}, id: o, configAction: s } = e, [a, l] = x([]), [c, u] = x(!1), [f, d] = x(), {
12993
13003
  setIsLoading: p,
@@ -13009,7 +13019,7 @@ function Tg(e, t) {
13009
13019
  async function S() {
13010
13020
  u(!0), p(!0), d(void 0);
13011
13021
  try {
13012
- const O = await A(), k = await R(O), _ = O.fields[Vr].relation, $ = k[Vr].items;
13022
+ const O = await A(), k = await R(O), _ = O.fields[Er].relation, $ = k[Er].items;
13013
13023
  y.current = O.fields;
13014
13024
  const L = await T({
13015
13025
  items: $,
@@ -13068,13 +13078,13 @@ function Tg(e, t) {
13068
13078
  const W = parseInt(L.action_id[0], 10), B = Is({
13069
13079
  actionId: W,
13070
13080
  rootContext: r
13071
- }).then((E) => ({ ...$, actionData: E }));
13081
+ }).then((V) => ({ ...$, actionData: V }));
13072
13082
  k.push(B);
13073
13083
  }
13074
13084
  }
13075
13085
  return await Promise.all(k);
13076
13086
  }
13077
- async function V(O) {
13087
+ async function E(O) {
13078
13088
  if (!m)
13079
13089
  return;
13080
13090
  const k = O.filter((W) => {
@@ -13085,17 +13095,17 @@ function Tg(e, t) {
13085
13095
  return !1;
13086
13096
  if (!B.position)
13087
13097
  return !0;
13088
- const E = {
13098
+ const V = {
13089
13099
  ...JSON.parse(B.position.replace(/'/g, '"')),
13090
13100
  id: B.id
13091
13101
  };
13092
- return JSON.stringify(W) !== JSON.stringify(E);
13102
+ return JSON.stringify(W) !== JSON.stringify(V);
13093
13103
  });
13094
13104
  if (k.length === 0)
13095
13105
  return;
13096
13106
  const $ = a.filter((W) => k.map((B) => B.id).includes(W.id)).map((W) => {
13097
13107
  const B = {
13098
- ...k.find((E) => E.id === W.id)
13108
+ ...k.find((V) => V.id === W.id)
13099
13109
  };
13100
13110
  return delete B.id, { ...W }, {
13101
13111
  ...W,
@@ -13112,7 +13122,7 @@ function Tg(e, t) {
13112
13122
  await I({
13113
13123
  model: n,
13114
13124
  id: o,
13115
- values: { [Vr]: L },
13125
+ values: { [Er]: L },
13116
13126
  fields: y.current,
13117
13127
  context: r
13118
13128
  });
@@ -13120,10 +13130,10 @@ function Tg(e, t) {
13120
13130
  async function F() {
13121
13131
  h(s);
13122
13132
  }
13123
- return c ? /* @__PURE__ */ i(St, {}) : f ? /* @__PURE__ */ i(ot, { className: "mt-10 mb-20", message: f, type: "error", banner: !0 }) : /* @__PURE__ */ i(Sg, { onPositionItemsChanged: V, children: a.map((O, k) => {
13133
+ return c ? /* @__PURE__ */ i(St, {}) : f ? /* @__PURE__ */ i(ot, { className: "mt-10 mb-20", message: f, type: "error", banner: !0 }) : /* @__PURE__ */ i(Sg, { onPositionItemsChanged: E, children: a.map((O, k) => {
13124
13134
  const { actionData: _, values: $ } = O, { position: L, id: W } = $, {
13125
13135
  actionId: B,
13126
- actionType: E,
13136
+ actionType: V,
13127
13137
  key: Z,
13128
13138
  title: ne,
13129
13139
  description: Q,
@@ -13142,7 +13152,7 @@ function Tg(e, t) {
13142
13152
  }
13143
13153
  let z = null;
13144
13154
  if ((M == null ? void 0 : M.type) === "graph") {
13145
- const ke = $.server_action === !0 && C ? Vs : mn;
13155
+ const ke = $.server_action === !0 && C ? Es : mn;
13146
13156
  z = /* @__PURE__ */ i(
13147
13157
  ke,
13148
13158
  {
@@ -13169,11 +13179,11 @@ function Tg(e, t) {
13169
13179
  )[0][0],
13170
13180
  onRowClicked: (me) => {
13171
13181
  const ke = H.find(($e) => {
13172
- const [, Ee] = $e;
13173
- return Ee === "form";
13182
+ const [, Ve] = $e;
13183
+ return Ve === "form";
13174
13184
  });
13175
13185
  if (ke) {
13176
- const [$e, Ee] = ke, {
13186
+ const [$e, Ve] = ke, {
13177
13187
  actionId: Ne,
13178
13188
  actionType: Be,
13179
13189
  title: Oe,
@@ -13185,7 +13195,7 @@ function Tg(e, t) {
13185
13195
  res_id: me.id,
13186
13196
  res_model: de,
13187
13197
  view_id: $e,
13188
- view_type: Ee
13198
+ view_type: Ve
13189
13199
  };
13190
13200
  h(xe);
13191
13201
  }
@@ -13199,7 +13209,7 @@ function Tg(e, t) {
13199
13209
  $a,
13200
13210
  {
13201
13211
  action_id: B,
13202
- action_type: E,
13212
+ action_type: V,
13203
13213
  tabKey: Z,
13204
13214
  title: ne,
13205
13215
  views: H,
@@ -13222,13 +13232,13 @@ function Tg(e, t) {
13222
13232
  if (ie) {
13223
13233
  const [me, ke] = ie, {
13224
13234
  actionId: $e,
13225
- actionType: Ee,
13235
+ actionType: Ve,
13226
13236
  title: Ne,
13227
13237
  model: Be
13228
13238
  } = _;
13229
13239
  J = {
13230
13240
  action_id: $e,
13231
- action_type: Ee,
13241
+ action_type: Ve,
13232
13242
  name: Ne,
13233
13243
  res_id: !1,
13234
13244
  res_model: Be,
@@ -13238,7 +13248,7 @@ function Tg(e, t) {
13238
13248
  };
13239
13249
  }
13240
13250
  return /* @__PURE__ */ i(
13241
- Es,
13251
+ Vs,
13242
13252
  {
13243
13253
  id: W,
13244
13254
  title: ne,
@@ -13281,7 +13291,7 @@ const Ag = wt(Tg), Og = (e) => {
13281
13291
  R = [...R, ...b];
13282
13292
  }
13283
13293
  try {
13284
- const V = (await N.getHandler().search({
13294
+ const E = (await N.getHandler().search({
13285
13295
  model: p,
13286
13296
  params: R,
13287
13297
  fieldsToRetrieve: [g],
@@ -13291,7 +13301,7 @@ const Ag = wt(Tg), Og = (e) => {
13291
13301
  let k = O;
13292
13302
  return Array.isArray(O) && (k = O[1]), { label: k, value: F.id };
13293
13303
  });
13294
- l(V);
13304
+ l(E);
13295
13305
  } catch (b) {
13296
13306
  u(b);
13297
13307
  } finally {
@@ -13308,8 +13318,8 @@ const Ag = wt(Tg), Og = (e) => {
13308
13318
  const b = o.map((F) => R.includes(F.id) ? F.operation == "pendingRemove" ? {
13309
13319
  ...F,
13310
13320
  operation: "original"
13311
- } : F : { id: F.id, operation: "pendingRemove" }), V = b.map((F) => F.id);
13312
- R.filter((F) => !V.includes(F)).map((F) => {
13321
+ } : F : { id: F.id, operation: "pendingRemove" }), E = b.map((F) => F.id);
13322
+ R.filter((F) => !E.includes(F)).map((F) => {
13313
13323
  b.push({ id: F, operation: "pendingLink" });
13314
13324
  }), I(b);
13315
13325
  };
@@ -13355,10 +13365,10 @@ const Ag = wt(Tg), Og = (e) => {
13355
13365
  )
13356
13366
  }
13357
13367
  );
13358
- }, Vg = (e) => {
13359
- const { ooui: t } = e, { required: n } = t;
13360
- return /* @__PURE__ */ i(_e, { required: n, type: "any", ...e, children: /* @__PURE__ */ i(Eg, { ...e }) });
13361
13368
  }, Eg = (e) => {
13369
+ const { ooui: t } = e, { required: n } = t;
13370
+ return /* @__PURE__ */ i(_e, { required: n, type: "any", ...e, children: /* @__PURE__ */ i(Vg, { ...e }) });
13371
+ }, Vg = (e) => {
13362
13372
  const { ooui: t, onChange: n, value: r } = e, { selectionValues: o, readOnly: s, direction: a } = t, l = Array.from(o.entries()), c = l && l.length && l.map((u) => {
13363
13373
  const [f, d] = u;
13364
13374
  return /* @__PURE__ */ i(No, { value: f, children: d }, f);
@@ -13625,30 +13635,30 @@ function ry(e, t) {
13625
13635
  res_id: R,
13626
13636
  domain: b = []
13627
13637
  }) {
13628
- const V = await N.getHandler().getActionData({
13638
+ const E = await N.getHandler().getActionData({
13629
13639
  action: C,
13630
13640
  context: l
13631
13641
  });
13632
- if (V.type === "ir.actions.wizard") {
13642
+ if (E.type === "ir.actions.wizard") {
13633
13643
  st("Action type not supported");
13634
13644
  return;
13635
13645
  }
13636
13646
  const [F, O] = C.split(","), k = parseInt(O), _ = jt({
13637
- context: V.context,
13647
+ context: E.context,
13638
13648
  values: a,
13639
13649
  fields: {}
13640
- }), $ = V.domain ? await N.getHandler().evalDomain({
13641
- domain: V.domain,
13650
+ }), $ = E.domain ? await N.getHandler().evalDomain({
13651
+ domain: E.domain,
13642
13652
  values: a,
13643
13653
  context: { ...l, ..._ }
13644
13654
  }) : [], {
13645
13655
  res_model: L,
13646
13656
  views: W,
13647
13657
  name: B,
13648
- target: E,
13658
+ target: V,
13649
13659
  view_type: Z,
13650
13660
  limit: ne
13651
- } = V, Q = Z === "tree", H = [];
13661
+ } = E, Q = Z === "tree", H = [];
13652
13662
  for (const ee of W) {
13653
13663
  const [G, M] = ee;
13654
13664
  if (G)
@@ -13681,7 +13691,7 @@ function ry(e, t) {
13681
13691
  model: L,
13682
13692
  views: H,
13683
13693
  title: B,
13684
- target: E,
13694
+ target: V,
13685
13695
  initialView: re,
13686
13696
  action_type: F,
13687
13697
  action_id: k,
@@ -13719,14 +13729,14 @@ function ry(e, t) {
13719
13729
  }) {
13720
13730
  const {
13721
13731
  res_model: b,
13722
- context: V,
13732
+ context: E,
13723
13733
  domain: F,
13724
13734
  views: O,
13725
13735
  target: k,
13726
13736
  string: _,
13727
13737
  limit: $
13728
- } = C, [L, W] = O[0], B = { id: L, type: W }, E = jt({
13729
- context: V,
13738
+ } = C, [L, W] = O[0], B = { id: L, type: W }, V = jt({
13739
+ context: E,
13730
13740
  values: { ...A, ...a },
13731
13741
  fields: S
13732
13742
  }), Z = F ? await N.getHandler().evalDomain({
@@ -13736,13 +13746,13 @@ function ry(e, t) {
13736
13746
  values: { ...A, ...a }
13737
13747
  }),
13738
13748
  fields: S,
13739
- context: { ...l, ...E }
13749
+ context: { ...l, ...V }
13740
13750
  }) : [];
13741
13751
  I({
13742
13752
  model: b,
13743
13753
  target: k,
13744
13754
  views: O,
13745
- context: { ...l, ...E },
13755
+ context: { ...l, ...V },
13746
13756
  domain: Z,
13747
13757
  title: _,
13748
13758
  initialView: B,
@@ -13758,27 +13768,27 @@ function ry(e, t) {
13758
13768
  res_id: T,
13759
13769
  view_id: R,
13760
13770
  overrideUnsettedLimit: b = !1,
13761
- values: V = {},
13771
+ values: E = {},
13762
13772
  domain: F
13763
13773
  } = C, O = `${A},${S}`, k = await N.getHandler().getActionData({
13764
13774
  action: O,
13765
13775
  context: l
13766
13776
  }), _ = jt({
13767
13777
  context: k.context,
13768
- values: { ...a, ...V },
13778
+ values: { ...a, ...E },
13769
13779
  fields: {}
13770
13780
  });
13771
13781
  let $ = [];
13772
13782
  (F == null ? void 0 : F.length) > 0 ? $ = F : k.domain && ($ = await N.getHandler().evalDomain({
13773
13783
  domain: k.domain,
13774
- values: { ...a, ...V },
13784
+ values: { ...a, ...E },
13775
13785
  context: { ...l, ..._ }
13776
13786
  }));
13777
13787
  const {
13778
13788
  res_model: L,
13779
13789
  views: W,
13780
13790
  name: B,
13781
- target: E,
13791
+ target: V,
13782
13792
  view_type: Z,
13783
13793
  limit: ne
13784
13794
  } = k, Q = Z === "tree", H = [];
@@ -13811,7 +13821,7 @@ function ry(e, t) {
13811
13821
  model: L,
13812
13822
  views: H,
13813
13823
  title: B,
13814
- target: E,
13824
+ target: V,
13815
13825
  initialView: G,
13816
13826
  action_id: S,
13817
13827
  action_type: A,
@@ -13828,9 +13838,9 @@ function ry(e, t) {
13828
13838
  res_id: R,
13829
13839
  domain: b
13830
13840
  }) {
13831
- const V = await N.getHandler().getActionStringForModel(C);
13841
+ const E = await N.getHandler().getActionStringForModel(C);
13832
13842
  await m({
13833
- action: V,
13843
+ action: E,
13834
13844
  values: S,
13835
13845
  forced_values: A,
13836
13846
  initialViewType: T,
@@ -13845,7 +13855,7 @@ function ry(e, t) {
13845
13855
  views: T,
13846
13856
  title: R,
13847
13857
  target: b,
13848
- initialView: V,
13858
+ initialView: E,
13849
13859
  action_id: F,
13850
13860
  action_type: O,
13851
13861
  res_id: k,
@@ -13856,26 +13866,26 @@ function ry(e, t) {
13856
13866
  }) {
13857
13867
  const B = fo();
13858
13868
  if (b !== "current") {
13859
- const E = await N.getHandler().getView({
13869
+ const V = await N.getHandler().getView({
13860
13870
  model: A,
13861
13871
  type: "form",
13862
- id: V.type === "form" ? V.id : void 0,
13872
+ id: E.type === "form" ? E.id : void 0,
13863
13873
  context: { ...l, ...S }
13864
13874
  });
13865
13875
  d.current.openActionModal({
13866
13876
  domain: C,
13867
13877
  model: A,
13868
- formView: E,
13878
+ formView: V,
13869
13879
  context: { ...l, ...S },
13870
13880
  actionData: {
13871
13881
  action_id: F,
13872
13882
  action_type: O,
13873
13883
  res_id: k,
13874
- view_id: E.view_id
13884
+ view_id: V.view_id
13875
13885
  }
13876
13886
  });
13877
13887
  } else {
13878
- const E = V && Array.isArray(V.id) ? { ...V, id: V.id[0] } : V;
13888
+ const V = E && Array.isArray(E.id) ? { ...E, id: E.id[0] } : E;
13879
13889
  g({
13880
13890
  title: R,
13881
13891
  action: {
@@ -13894,7 +13904,7 @@ function ry(e, t) {
13894
13904
  context: { ...l, ...S },
13895
13905
  domain: C,
13896
13906
  setCanWeClose: h,
13897
- initialView: E,
13907
+ initialView: V,
13898
13908
  res_id: k,
13899
13909
  formDefaultValues: _,
13900
13910
  formForcedValues: $,
@@ -14106,7 +14116,7 @@ const { useToken: ly } = We, av = (e) => {
14106
14116
  }))
14107
14117
  }
14108
14118
  ];
14109
- }, [t, f]), V = P(async () => {
14119
+ }, [t, f]), E = P(async () => {
14110
14120
  if (a && c)
14111
14121
  await o(c);
14112
14122
  else {
@@ -14142,7 +14152,7 @@ const { useToken: ly } = We, av = (e) => {
14142
14152
  {
14143
14153
  ref: p,
14144
14154
  isFavourite: a,
14145
- onToggleFavourite: V,
14155
+ onToggleFavourite: E,
14146
14156
  onItemClick: A,
14147
14157
  placement: "bottomRight",
14148
14158
  header: /* @__PURE__ */ D("div", { style: { width: 300, padding: 5, display: "flex" }, children: [
@@ -14193,7 +14203,7 @@ export {
14193
14203
  Th as FloatTime,
14194
14204
  yn as Form,
14195
14205
  vn as FormModal,
14196
- Es as GraphCard,
14206
+ Vs as GraphCard,
14197
14207
  xd as GraphIndicator,
14198
14208
  Ra as Group,
14199
14209
  Yg as HTMLPreview,
@@ -14206,14 +14216,14 @@ export {
14206
14216
  Fh as Notebook,
14207
14217
  Ch as One2many,
14208
14218
  Tu as ProgressBar,
14209
- Vg as Radio,
14219
+ Eg as Radio,
14210
14220
  Kh as Reference,
14211
14221
  ov as RootView,
14212
14222
  _o as SearchFilter,
14213
- Vo as SearchModal,
14223
+ Eo as SearchModal,
14214
14224
  Ca as SearchTree,
14215
14225
  gs as Selection,
14216
- Eh as Separator,
14226
+ Vh as Separator,
14217
14227
  Gr as Spinner,
14218
14228
  kg as Steps,
14219
14229
  Dg as Switch,