@realtek/core-theme 0.0.168 → 0.0.169

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist-lib/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { C as e, S as t, _ as n, a as r, b as i, c as a, d as o, f as s, g as c, h as l, i as u, l as d, m as f, n as p, o as m, p as h, r as g, s as _, t as v, u as y, v as b, w as x, x as S, y as C } from "./authApi-BPEW_c3Y.js";
2
- import { $ as w, $t as T, A as E, An as D, At as O, B as k, Bt as ee, C as A, Cn as te, Ct as ne, D as j, Dn as M, Dt as re, E as ie, En as N, Et as ae, F as oe, Ft as se, G as ce, Gt as le, H as ue, Ht as de, I as fe, It as pe, J as me, Jt as he, K as ge, Kt as _e, L as ve, Lt as ye, M as be, Mn as P, Mt as xe, N as Se, Nt as Ce, O as we, On as Te, Ot as Ee, P as De, Pt as Oe, Q as ke, Qt as Ae, R as je, Rt as Me, S as Ne, Sn as Pe, St as Fe, T as Ie, Tn as Le, Tt as Re, U as ze, Ut as Be, V as Ve, Vt as He, W as Ue, Wt as We, X as Ge, Xt as Ke, Y as qe, Yt as Je, Z as Ye, Zt as Xe, _ as Ze, _n as Qe, _t as $e, a as et, an as tt, at as nt, b as rt, bn as it, bt as at, c as ot, cn as st, ct, d as lt, dn as ut, dt, en as ft, et as pt, f as mt, fn as ht, ft as gt, g as _t, gn as vt, gt as yt, h as bt, hn as xt, ht as St, i as Ct, in as wt, it as Tt, j as Et, jn as Dt, jt as Ot, k as kt, kn as At, kt as jt, l as Mt, ln as Nt, lt as Pt, m as Ft, mn as It, mt as Lt, n as Rt, nn as zt, nt as Bt, o as Vt, on as Ht, ot as Ut, p as Wt, pn as Gt, pt as Kt, q as qt, qt as Jt, r as Yt, rn as Xt, rt as Zt, s as Qt, sn as $t, st as en, t as tn, tn as nn, tt as rn, u as an, un as on, ut as sn, v as cn, vn as ln, vt as un, w as dn, wn as fn, wt as pn, x as mn, xn as hn, xt as gn, y as _n, yn as vn, yt as yn, z as bn, zt as xn } from "./Breadcrumb-DSsRWbrH.js";
2
+ import { $ as w, $t as T, A as E, An as D, At as O, B as k, Bt as ee, C as A, Cn as te, Ct as ne, D as j, Dn as M, Dt as re, E as N, En as P, Et as ie, F as ae, Ft as oe, G as se, Gt as ce, H as le, Ht as ue, I as de, It as fe, J as pe, Jt as me, K as he, Kt as ge, L as _e, Lt as ve, M as ye, Mn as be, Mt as xe, N as Se, Nt as Ce, O as we, On as Te, Ot as Ee, P as De, Pt as Oe, Q as ke, Qt as Ae, R as je, Rt as Me, S as Ne, Sn as Pe, St as Fe, T as Ie, Tn as Le, Tt as Re, U as ze, Ut as Be, V as Ve, Vt as He, W as Ue, Wt as We, X as Ge, Xt as Ke, Y as qe, Yt as Je, Z as Ye, Zt as Xe, _ as Ze, _n as Qe, _t as $e, a as et, an as tt, at as nt, b as rt, bn as it, bt as at, c as ot, cn as st, ct, d as lt, dn as ut, dt, en as ft, et as pt, f as mt, fn as ht, ft as gt, g as _t, gn as vt, gt as yt, h as bt, hn as xt, ht as St, i as Ct, in as wt, it as Tt, j as Et, jn as Dt, jt as Ot, k as kt, kn as At, kt as jt, l as Mt, ln as Nt, lt as Pt, m as Ft, mn as It, mt as Lt, n as Rt, nn as zt, nt as Bt, o as Vt, on as Ht, ot as Ut, p as Wt, pn as Gt, pt as Kt, q as qt, qt as Jt, r as Yt, rn as Xt, rt as Zt, s as Qt, sn as $t, st as en, t as tn, tn as nn, tt as rn, u as an, un as on, ut as sn, v as cn, vn as ln, vt as un, w as dn, wn as fn, wt as pn, x as mn, xn as hn, xt as gn, y as _n, yn as vn, yt as yn, z as bn, zt as xn } from "./Breadcrumb-DSsRWbrH.js";
3
3
  import { i as Sn } from "./diceCandidateMapper-BKRGwz7g.js";
4
4
  import Cn, { Fragment as wn, useCallback as Tn, useEffect as F, useMemo as I, useRef as En, useState as L } from "react";
5
5
  import { Alert as Dn, AutoComplete as On, Avatar as kn, Badge as An, Breadcrumb as jn, Button as R, Card as Mn, Checkbox as Nn, Col as z, Collapse as Pn, DatePicker as Fn, Divider as In, Drawer as Ln, Dropdown as Rn, Empty as zn, Flex as Bn, Form as B, Input as V, InputNumber as Vn, Layout as Hn, Mentions as Un, Menu as Wn, Modal as Gn, Pagination as Kn, Popconfirm as qn, Popover as Jn, Progress as Yn, Radio as Xn, Result as Zn, Row as Qn, Select as H, Space as U, Spin as $n, Statistic as er, Steps as tr, Switch as W, Table as nr, Tabs as rr, Tag as G, TimePicker as ir, Tooltip as K, Typography as ar, Upload as or, message as q } from "antd";
@@ -245,7 +245,7 @@ function Ea({ userIds: e = [], days: t = void 0, startDay: n = "Sun", renderDayC
245
245
  t !== void 0 && (t || []).forEach((e) => {
246
246
  e?.date && (M[e.date] = e);
247
247
  });
248
- let re = o ?? C, ie = l ?? `${_a[b.month]} ${b.year}`;
248
+ let re = o ?? C, N = l ?? `${_a[b.month]} ${b.year}`;
249
249
  return /* @__PURE__ */ X(Mn, {
250
250
  className: `calendar-card${c ? ` ${c}` : ""}`,
251
251
  title: /* @__PURE__ */ Z("div", {
@@ -253,7 +253,7 @@ function Ea({ userIds: e = [], days: t = void 0, startDay: n = "Sun", renderDayC
253
253
  children: [/* @__PURE__ */ X(vr, {}), /* @__PURE__ */ X(pa, {
254
254
  level: 5,
255
255
  style: { margin: 0 },
256
- children: ie
256
+ children: N
257
257
  })]
258
258
  }),
259
259
  extra: /* @__PURE__ */ Z("div", {
@@ -888,6 +888,10 @@ function po({ current: e, pageSize: t, total: n, onChange: r, onPageSizeChange:
888
888
  value: 10,
889
889
  label: "10"
890
890
  },
891
+ {
892
+ value: 12,
893
+ label: "12"
894
+ },
891
895
  {
892
896
  value: 25,
893
897
  label: "25"
@@ -1454,7 +1458,7 @@ function $o({ group: e }) {
1454
1458
  }, { span: c, maxCount: l } = ko(e, 2), u = (t) => e.colorBy ? go(t, e.colorBy) : e.headingKey ? go(t, e.headingKey) : null, d = (Array.isArray(e.list) ? e.list : []).filter((e) => !a.has(e._id ?? e.id)).map((e, t) => ({
1455
1459
  item: e,
1456
1460
  _i: t
1457
- })).filter(({ item: t, _i: n }) => !Ro(e, u(t), n)).filter(({ item: t }) => Xo(e, t)), [f, p] = L("todo"), m = d.filter(({ item: t }) => !Yo(e, t)), h = d.filter(({ item: t }) => Yo(e, t)), g = e.showTabs, _ = g ? f === "resolved" ? h : m : d, [v, y] = L(e.pageSize || 10), [b, x] = L(1);
1461
+ })).filter(({ item: t, _i: n }) => !Ro(e, u(t), n)).filter(({ item: t }) => Xo(e, t)), [f, p] = L("todo"), m = d.filter(({ item: t }) => !Yo(e, t)), h = d.filter(({ item: t }) => Yo(e, t)), g = e.showTabs, _ = g ? f === "resolved" ? h : m : d, [v, y] = L(e.pageSize || 12), [b, x] = L(1);
1458
1462
  F(() => {
1459
1463
  x(1);
1460
1464
  }, [f, e.dateRange]);
@@ -1506,88 +1510,91 @@ function $o({ group: e }) {
1506
1510
  count: h.length
1507
1511
  }]
1508
1512
  }),
1509
- C.length === 0 ? /* @__PURE__ */ X(zn, { description: "No notes found" }) : /* @__PURE__ */ X(Qn, {
1510
- gutter: [12, 12],
1511
- children: C.map(({ item: t, _i: n }) => {
1512
- let r = Zo(t, e, n), a = So(e, r.type);
1513
- return /* @__PURE__ */ X(z, {
1514
- xs: 24,
1515
- sm: 24,
1516
- md: c >= 12 ? 12 : c * 2,
1517
- lg: c,
1518
- xl: c,
1519
- children: /* @__PURE__ */ Z("div", {
1520
- className: `sticky-note ${a.className}`.trim(),
1521
- style: a.style,
1522
- children: [
1523
- /* @__PURE__ */ Z(U, {
1524
- size: 4,
1525
- className: "sticky-note-hover-actions",
1526
- children: [/* @__PURE__ */ X(K, {
1527
- title: "Edit",
1528
- children: /* @__PURE__ */ X(R, {
1529
- type: "text",
1530
- size: "small",
1531
- icon: /* @__PURE__ */ X(Br, {}),
1532
- onClick: () => i(t)
1533
- })
1534
- }), /* @__PURE__ */ X(K, {
1535
- title: "Resolve",
1536
- children: /* @__PURE__ */ X(R, {
1537
- type: "text",
1538
- size: "small",
1539
- icon: /* @__PURE__ */ X(Sr, {}),
1540
- onClick: () => s(t)
1541
- })
1542
- })]
1543
- }),
1544
- /* @__PURE__ */ Z(U, {
1545
- size: 8,
1546
- align: "center",
1547
- className: "sticky-note-pill-row",
1548
- children: [_o(r.pill) && /* @__PURE__ */ Z(G, {
1549
- style: vo(e, "stickyPill"),
1550
- children: [r.dot && /* @__PURE__ */ X("span", {
1551
- className: "sticky-note-dot",
1552
- style: { background: r.dot }
1553
- }), r.pill]
1554
- }), r.date && /* @__PURE__ */ X(ho, {
1555
- className: "sticky-note-date",
1556
- style: vo(e, "stickyDate"),
1557
- children: r.date
1558
- })]
1559
- }),
1560
- _o(r.heading) && /* @__PURE__ */ X(ho, {
1561
- strong: !0,
1562
- className: "sticky-note-heading",
1563
- style: vo(e, "stickyHeading"),
1564
- children: r.heading
1565
- }),
1566
- _o(r.body) && /* @__PURE__ */ X(Qo, {
1567
- text: r.body,
1568
- lines: e.bodyLines,
1569
- style: vo(e, "stickyBody")
1570
- }),
1571
- /* @__PURE__ */ Z(Qn, {
1572
- justify: "space-between",
1573
- align: "middle",
1574
- className: "sticky-note-footer",
1575
- style: vo(e, "stickyFooter"),
1576
- children: [/* @__PURE__ */ X(z, { children: /* @__PURE__ */ X(ho, {
1577
- style: vo(e, "stickyFooterText"),
1578
- children: r.footerLeft
1579
- }) }), /* @__PURE__ */ X(z, { children: /* @__PURE__ */ X(ho, {
1580
- style: vo(e, "stickyFooterText"),
1581
- children: r.footerRight
1582
- }) })]
1583
- })
1584
- ]
1585
- })
1586
- }, n);
1513
+ C.length === 0 ? /* @__PURE__ */ X(zn, { description: "No notes found" }) : /* @__PURE__ */ X("div", {
1514
+ className: g ? "sticky-notes-scroll" : void 0,
1515
+ children: /* @__PURE__ */ X(Qn, {
1516
+ gutter: [12, 12],
1517
+ children: C.map(({ item: t, _i: n }) => {
1518
+ let r = Zo(t, e, n), a = So(e, r.type);
1519
+ return /* @__PURE__ */ X(z, {
1520
+ xs: 24,
1521
+ sm: 24,
1522
+ md: c >= 12 ? 12 : c * 2,
1523
+ lg: c,
1524
+ xl: c,
1525
+ children: /* @__PURE__ */ Z("div", {
1526
+ className: `sticky-note ${a.className}`.trim(),
1527
+ style: a.style,
1528
+ children: [
1529
+ /* @__PURE__ */ Z(U, {
1530
+ size: 4,
1531
+ className: "sticky-note-hover-actions",
1532
+ children: [/* @__PURE__ */ X(K, {
1533
+ title: "Edit",
1534
+ children: /* @__PURE__ */ X(R, {
1535
+ type: "text",
1536
+ size: "small",
1537
+ icon: /* @__PURE__ */ X(Br, {}),
1538
+ onClick: () => i(t)
1539
+ })
1540
+ }), /* @__PURE__ */ X(K, {
1541
+ title: "Resolve",
1542
+ children: /* @__PURE__ */ X(R, {
1543
+ type: "text",
1544
+ size: "small",
1545
+ icon: /* @__PURE__ */ X(Sr, {}),
1546
+ onClick: () => s(t)
1547
+ })
1548
+ })]
1549
+ }),
1550
+ /* @__PURE__ */ Z(U, {
1551
+ size: 8,
1552
+ align: "center",
1553
+ className: "sticky-note-pill-row",
1554
+ children: [_o(r.pill) && /* @__PURE__ */ Z(G, {
1555
+ style: vo(e, "stickyPill"),
1556
+ children: [r.dot && /* @__PURE__ */ X("span", {
1557
+ className: "sticky-note-dot",
1558
+ style: { background: r.dot }
1559
+ }), r.pill]
1560
+ }), r.date && /* @__PURE__ */ X(ho, {
1561
+ className: "sticky-note-date",
1562
+ style: vo(e, "stickyDate"),
1563
+ children: r.date
1564
+ })]
1565
+ }),
1566
+ _o(r.heading) && /* @__PURE__ */ X(ho, {
1567
+ strong: !0,
1568
+ className: "sticky-note-heading",
1569
+ style: vo(e, "stickyHeading"),
1570
+ children: r.heading
1571
+ }),
1572
+ _o(r.body) && /* @__PURE__ */ X(Qo, {
1573
+ text: r.body,
1574
+ lines: e.bodyLines,
1575
+ style: vo(e, "stickyBody")
1576
+ }),
1577
+ /* @__PURE__ */ Z(Qn, {
1578
+ justify: "space-between",
1579
+ align: "middle",
1580
+ className: "sticky-note-footer",
1581
+ style: vo(e, "stickyFooter"),
1582
+ children: [/* @__PURE__ */ X(z, { children: /* @__PURE__ */ X(ho, {
1583
+ style: vo(e, "stickyFooterText"),
1584
+ children: r.footerLeft
1585
+ }) }), /* @__PURE__ */ X(z, { children: /* @__PURE__ */ X(ho, {
1586
+ style: vo(e, "stickyFooterText"),
1587
+ children: r.footerRight
1588
+ }) })]
1589
+ })
1590
+ ]
1591
+ })
1592
+ }, n);
1593
+ })
1587
1594
  })
1588
1595
  }),
1589
1596
  g && _.length > 0 && /* @__PURE__ */ X("div", {
1590
- style: { marginTop: 16 },
1597
+ className: "sticky-notes-pagination",
1591
1598
  children: /* @__PURE__ */ X(po, {
1592
1599
  current: b,
1593
1600
  pageSize: v,
@@ -2061,12 +2068,12 @@ async function Os(e) {
2061
2068
  return Es(b, e);
2062
2069
  }
2063
2070
  async function ks(e) {
2064
- return e === ds ? fs : e === ps ? ms : Ds(`/filter-dropdown-fields?module=${encodeURIComponent(N(e))}`);
2071
+ return e === ds ? fs : e === ps ? ms : Ds(`/filter-dropdown-fields?module=${encodeURIComponent(P(e))}`);
2065
2072
  }
2066
2073
  async function As(e, { configType: t, userId: n, roleId: r } = {}) {
2067
2074
  if (e === ds) return fs;
2068
2075
  if (e === ps) return ms;
2069
- let i = new URLSearchParams({ module: N(e) });
2076
+ let i = new URLSearchParams({ module: P(e) });
2070
2077
  return t && i.set("configType", t), n != null && i.set("userId", String(n)), r != null && i.set("roleId", String(r)), Os(`/admin/field-config?${i}`);
2071
2078
  }
2072
2079
  async function js({ limit: e = 10, offset: t = 0, search: n = "", module: r = "", keyword: i = "", tags: a = "", active: o } = {}) {
@@ -2120,7 +2127,7 @@ async function Ns(e, t = 10, n = 0, r = {}) {
2120
2127
  };
2121
2128
  }
2122
2129
  let u = new URLSearchParams({
2123
- module: N(e),
2130
+ module: P(e),
2124
2131
  limit: String(t),
2125
2132
  offset: String(n)
2126
2133
  }), d = String(e).trim().toLowerCase() === "jobs" ? Ss(i) : String(i ?? "").trim();
@@ -2240,7 +2247,7 @@ function zs(e) {
2240
2247
  }
2241
2248
  async function Bs(e, t, n = "", r = {}) {
2242
2249
  let { limit: i = 50, offset: a = 0, dataSource: o, groupName: s, lookup: c } = r, l = new URLSearchParams({
2243
- module: N(e),
2250
+ module: P(e),
2244
2251
  field: t,
2245
2252
  value: n,
2246
2253
  limit: String(i),
@@ -4384,53 +4391,53 @@ function dd({ filters: e, onRemove: t, onClearAll: n }) {
4384
4391
  ]
4385
4392
  });
4386
4393
  }
4387
- function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbItems: r = [], dataSource: i = [], className: a = "", initialPageSize: o = 10, onAction: s, onSummaryClick: c, rowKey: l, showSummaryButton: d = !1, summaryButtonLabel: f = "View Summary", summaryRoute: p, tabs: m, tableClassName: h = "job-list-table", fields: g = ad, listName: _ = "", loading: v = !1, total: y, current: x, pageSize: S, onPageChange: C, onPageSizeChange: w, onSearch: T, showSearch: E = !0, searchPlaceholder: D = "Min 3 Chars, press Enter to search", searchFields: O = ad, showViewToggle: k = !1, activeView: ee = "list", onViewChange: A, createAction: te, onRecordClick: ne, selectedRecordId: j, selectionMode: M = "checkbox", compact: re = !1, onSelectionChange: ie, selectedSource: ae, onTabChange: oe, fetchData: se = Ns, responseMapper: ce = Yc, queryParams: le = od, defaultVisibleColumnCount: ue = 6 }) {
4388
- let de = ia(), fe = ra(), pe = N(e), { canView: me, canAdd: he, canEdit: ge, canDelete: _e } = rc(pe), ve = I(() => le ?? od, [JSON.stringify(le ?? od)]), [ye] = oa(), be = rd(ye), [P, xe] = L("all"), [Se, Ce] = L(""), [we, Te] = L(""), [Ee, De] = L(!1), [Oe, ke] = L([]), [Ae, je] = L([]), [Me, Ne] = L([]), [Pe, Fe] = L(0), [Ie, Le] = L({
4394
+ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbItems: r = [], dataSource: i = [], className: a = "", initialPageSize: o = 10, onAction: s, onSummaryClick: c, rowKey: l, showSummaryButton: d = !1, summaryButtonLabel: f = "View Summary", summaryRoute: p, tabs: m, tableClassName: h = "job-list-table", fields: g = ad, listName: _ = "", loading: v = !1, total: y, current: x, pageSize: S, onPageChange: C, onPageSizeChange: w, onSearch: T, showSearch: E = !0, searchPlaceholder: D = "Min 3 Chars, press Enter to search", searchFields: O = ad, showViewToggle: k = !1, activeView: ee = "list", onViewChange: A, createAction: te, onRecordClick: ne, selectedRecordId: j, selectionMode: M = "checkbox", compact: re = !1, onSelectionChange: N, selectedSource: ie, onTabChange: ae, fetchData: oe = Ns, responseMapper: se = Yc, queryParams: ce = od, defaultVisibleColumnCount: le = 6, showAdd: ue = !0 }) {
4395
+ let de = ia(), fe = ra(), pe = P(e), { canView: me, canAdd: he, canEdit: ge, canDelete: _e } = rc(pe), ve = I(() => ce ?? od, [JSON.stringify(ce ?? od)]), [ye] = oa(), be = rd(ye), [xe, Se] = L("all"), [Ce, we] = L(""), [Te, Ee] = L(""), [De, Oe] = L(!1), [ke, Ae] = L([]), [je, Me] = L([]), [Ne, Pe] = L([]), [Fe, Ie] = L(0), [Le, Re] = L({
4389
4396
  current: be,
4390
4397
  pageSize: o
4391
- }), [Re, ze] = L({
4398
+ }), [ze, Be] = L({
4392
4399
  sort: "",
4393
4400
  sortDir: ""
4394
- }), [Be, Ve] = L([]), [He, Ue] = L(!1), [We, Ge] = L([]), Ke = En(null), [qe, Je] = L(0), Ye = En();
4401
+ }), [Ve, He] = L([]), [Ue, We] = L(!1), [Ge, Ke] = L([]), qe = En(null), [Je, Ye] = L(0), Xe = En();
4395
4402
  F(() => {
4396
- let e = Ke.current;
4403
+ let e = qe.current;
4397
4404
  if (!e || typeof ResizeObserver > "u") return;
4398
4405
  let t = new ResizeObserver((e) => {
4399
4406
  let t = e[0]?.contentRect?.width;
4400
- typeof t == "number" && Je(t);
4407
+ typeof t == "number" && Ye(t);
4401
4408
  });
4402
4409
  return t.observe(e), () => t.disconnect();
4403
4410
  }, []);
4404
- let Xe = (e, t) => String(Hu(e, t, l)), Ze = (e, t) => String(Xe(e, t)) === String(j ?? ""), Qe = (e, t) => {
4405
- let n = Xe(e, t);
4411
+ let Ze = (e, t) => String(Hu(e, t, l)), Qe = (e, t) => String(Ze(e, t)) === String(j ?? ""), $e = (e, t) => {
4412
+ let n = Ze(e, t);
4406
4413
  n && ne?.(e, n);
4407
- }, $e = (e, t) => {
4408
- je(e), Ne(t), ie?.(e, t);
4409
- }, [et, tt] = L(i), [nt, rt] = L(i.length), [it, at] = L([]), [ot, st] = L([]), [ct, ut] = L(""), [dt, ft] = L([]), [pt, mt] = L([]), [ht, gt] = L(!1), [_t, vt] = L(null), [yt, bt] = L(null), [xt, St] = L(!1), Ct = !!(C || w || T), wt = Ct ? i : et, Tt = Ct ? y ?? 0 : nt, Et = Ct ? g : ot, Dt = I(() => wt.some((e) => Kl(e)), [wt]), Ot = I(() => Et.some((e) => Gl(e)), [Et]), kt = Dt || Ot ? "card" : ee, At = t.length > 0 ? t : dt, jt = n.length > 0 ? n : pt, Mt = I(() => Xu(At), [At]), Nt = I(() => new Map(Yu(Mt).map((e) => [e.key, e])), [Mt]), Pt = I(() => Ju(Mt, (e) => {
4414
+ }, et = (e, t) => {
4415
+ Me(e), Pe(t), N?.(e, t);
4416
+ }, [tt, nt] = L(i), [rt, it] = L(i.length), [at, ot] = L([]), [st, ct] = L([]), [ut, dt] = L(""), [ft, pt] = L([]), [mt, ht] = L([]), [gt, _t] = L(!1), [vt, yt] = L(null), [bt, xt] = L(null), [St, Ct] = L(!1), wt = !!(C || w || T), Tt = wt ? i : tt, Et = wt ? y ?? 0 : rt, Dt = wt ? g : st, Ot = I(() => Tt.some((e) => Kl(e)), [Tt]), kt = I(() => Dt.some((e) => Gl(e)), [Dt]), At = Ot || kt ? "card" : ee, jt = t.length > 0 ? t : ft, Mt = n.length > 0 ? n : mt, Nt = I(() => Xu(jt), [jt]), Pt = I(() => new Map(Yu(Nt).map((e) => [e.key, e])), [Nt]), Ft = I(() => Ju(Nt, (e) => {
4410
4417
  let t = ac(e);
4411
- return t === "add" && !he || t === "edit" && !ge || t === "delete" && !_e || !lt(e.permission, pe) || e.showInList === !1 ? !1 : e.allowedTabs ? e.allowedTabs.some((e) => Ru(e) === Ru(P)) : !0;
4418
+ return t === "add" && !he || t === "edit" && !ge || t === "delete" && !_e || !lt(e.permission, pe) || e.showInList === !1 ? !1 : e.allowedTabs ? e.allowedTabs.some((e) => Ru(e) === Ru(xe)) : !0;
4412
4419
  }), [
4413
- Mt,
4414
- P,
4420
+ Nt,
4421
+ xe,
4415
4422
  he,
4416
4423
  ge,
4417
4424
  _e,
4418
4425
  pe
4419
- ]), Ft = I(() => Ju(Pt, (e) => (Ae.length === 1 || e.allowMultiple || e.danger) && Zu(e, Me) && !fc(e.key, Me, jt, P)), [
4420
- P,
4421
- jt,
4422
- Ae.length,
4423
- Me,
4424
- Pt
4425
- ]), It = typeof e == "string" ? e.trim().length > 0 : !!e, Lt = It ? `/${pe}-create${te ? `?action=${encodeURIComponent(te)}` : ""}` : "";
4426
+ ]), It = I(() => Ju(Ft, (e) => (je.length === 1 || e.allowMultiple || e.danger) && Zu(e, Ne) && !fc(e.key, Ne, Mt, xe)), [
4427
+ xe,
4428
+ Mt,
4429
+ je.length,
4430
+ Ne,
4431
+ Ft
4432
+ ]), Lt = typeof e == "string" ? e.trim().length > 0 : !!e, Rt = Lt ? `/${pe}-create${te ? `?action=${encodeURIComponent(te)}` : ""}` : "";
4426
4433
  F(() => {
4427
- It && !me && de("/", { replace: !0 });
4434
+ Lt && !me && de("/", { replace: !0 });
4428
4435
  }, [
4429
4436
  me,
4430
- It,
4437
+ Lt,
4431
4438
  de
4432
4439
  ]);
4433
- let Rt = (e, { replace: t = !1 } = {}) => {
4440
+ let zt = (e, { replace: t = !1 } = {}) => {
4434
4441
  let n = new URLSearchParams(ye);
4435
4442
  id(n);
4436
4443
  let r = [n.toString(), e > 1 ? `p${e}` : ""].filter(Boolean).join("&");
@@ -4438,32 +4445,32 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4438
4445
  pathname: fe.pathname,
4439
4446
  search: r ? `?${r}` : ""
4440
4447
  }, { replace: t });
4441
- }, zt = (e, t) => {
4442
- Le((t) => ({
4448
+ }, Bt = (e, t) => {
4449
+ Re((t) => ({
4443
4450
  ...t,
4444
4451
  current: e
4445
- })), Rt(e, t);
4446
- }, Bt = () => {
4447
- zt(1, { replace: !0 });
4448
- }, { config: Vt, loading: Ht, error: Ut } = Xs(!Ct && It ? e : null), Wt = Tn((e) => {
4449
- let t = Re.sort === e, n = Qu(Re.sortDir, t), r = n ? String(e) : "";
4450
- ze({
4452
+ })), zt(e, t);
4453
+ }, Vt = () => {
4454
+ Bt(1, { replace: !0 });
4455
+ }, { config: Ht, loading: Ut, error: Wt } = Xs(!wt && Lt ? e : null), Gt = Tn((e) => {
4456
+ let t = ze.sort === e, n = Qu(ze.sortDir, t), r = n ? String(e) : "";
4457
+ Be({
4451
4458
  sort: r,
4452
4459
  sortDir: n
4453
- }), typeof T == "function" && T(r, n), Bt();
4460
+ }), typeof T == "function" && T(r, n), Vt();
4454
4461
  }, [
4455
4462
  T,
4456
- Bt,
4457
- Re.sort,
4458
- Re.sortDir
4463
+ Vt,
4464
+ ze.sort,
4465
+ ze.sortDir
4459
4466
  ]);
4460
4467
  F(() => {
4461
- Le((e) => e.current === be ? e : {
4468
+ Re((e) => e.current === be ? e : {
4462
4469
  ...e,
4463
4470
  current: be
4464
4471
  });
4465
4472
  }, [be]), F(() => {
4466
- Ct && Le((e) => {
4473
+ wt && Re((e) => {
4467
4474
  let t = nd(x ?? e.current), n = Number(S) > 0 ? Number(S) : e.pageSize;
4468
4475
  return e.current === t && e.pageSize === n ? e : {
4469
4476
  current: t,
@@ -4473,43 +4480,43 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4473
4480
  }, [
4474
4481
  x,
4475
4482
  S,
4476
- Ct
4483
+ wt
4477
4484
  ]);
4478
- let Gt = fe.state?.refreshTimestamp;
4485
+ let Kt = fe.state?.refreshTimestamp;
4479
4486
  F(() => {
4480
- Gt && ($e([], []), Fe((e) => e + 1));
4481
- }, [Gt]);
4482
- let Kt = I(() => [...Array.isArray(m) ? m : [], ...it].find((e, t) => String(zu(e, t)) === P), [
4483
- P,
4484
- it,
4487
+ Kt && (et([], []), Ie((e) => e + 1));
4488
+ }, [Kt]);
4489
+ let qt = I(() => [...Array.isArray(m) ? m : [], ...at].find((e, t) => String(zu(e, t)) === xe), [
4490
+ xe,
4491
+ at,
4485
4492
  m
4486
- ]), qt = Kt?.field ?? Kt?.fieldName ?? Kt?.filterField ?? Kt?.dataIndex ?? ct, Jt = Bu(P) ? "" : P, Yt = !Jt && !Bu(P) && Ru(qt).length > 0, Xt = we.trim().length >= 3, Zt = Xt ? we.trim() : "", Qt = Oe.some((e) => e.field), $t = td({
4493
+ ]), Jt = qt?.field ?? qt?.fieldName ?? qt?.filterField ?? qt?.dataIndex ?? ut, Yt = Bu(xe) ? "" : xe, Xt = !Yt && !Bu(xe) && Ru(Jt).length > 0, Zt = Te.trim().length >= 3, Qt = Zt ? Te.trim() : "", $t = ke.some((e) => e.field), en = td({
4487
4494
  moduleName: e,
4488
- activeTabScope: Jt,
4489
- pageSize: Ie.pageSize,
4490
- sort: Re.sort,
4491
- sortDir: Re.sortDir,
4495
+ activeTabScope: Yt,
4496
+ pageSize: Le.pageSize,
4497
+ sort: ze.sort,
4498
+ sortDir: ze.sortDir,
4492
4499
  queryParams: ve
4493
- }), en = Ie.current === 1 && yt?.key === $t;
4500
+ }), nn = Le.current === 1 && bt?.key === en;
4494
4501
  F(() => {
4495
- if (Ct) return;
4496
- if (!It) {
4497
- tt([]), rt(0), at([]), st([]), ut(""), ft([]), mt([]), vt(null);
4502
+ if (wt) return;
4503
+ if (!Lt) {
4504
+ nt([]), it(0), ot([]), ct([]), dt(""), pt([]), ht([]), yt(null);
4498
4505
  return;
4499
4506
  }
4500
- let t = !1, n = Xt && nt > Ie.pageSize, r = n ? nt : Ie.pageSize, i = n ? 0 : (Ie.current - 1) * Ie.pageSize;
4501
- return gt(!(!Xt && !Qt && Ie.current === 1 && en)), vt(null), se(e, r, i, {
4502
- scope: Jt,
4503
- sort: Re.sort,
4504
- sortDir: Re.sortDir,
4505
- search: Zt,
4506
- filters: Oe,
4507
+ let t = !1, n = Zt && rt > Le.pageSize, r = n ? rt : Le.pageSize, i = n ? 0 : (Le.current - 1) * Le.pageSize;
4508
+ return _t(!(!Zt && !$t && Le.current === 1 && nn)), yt(null), oe(e, r, i, {
4509
+ scope: Yt,
4510
+ sort: ze.sort,
4511
+ sortDir: ze.sortDir,
4512
+ search: Qt,
4513
+ filters: ke,
4507
4514
  queryParams: ve
4508
4515
  }).then((n) => {
4509
4516
  if (t) return;
4510
- let { rows: r, total: i, tabs: a, fields: o, tabField: s, actions: c, actionRules: l } = ce(n, e);
4511
- tt(r), rt(i), at(a), st(o), ut(s), ft(c), mt(l), !Xt && !Qt && Ie.current === 1 && bt({
4512
- key: $t,
4517
+ let { rows: r, total: i, tabs: a, fields: o, tabField: s, actions: c, actionRules: l } = se(n, e);
4518
+ nt(r), it(i), ot(a), ct(o), dt(s), pt(c), ht(l), !Zt && !$t && Le.current === 1 && xt({
4519
+ key: en,
4513
4520
  rows: r,
4514
4521
  total: i,
4515
4522
  tabs: a,
@@ -4519,34 +4526,34 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4519
4526
  actionRules: l
4520
4527
  });
4521
4528
  }).catch((e) => {
4522
- t || (tt([]), rt(0), at([]), st([]), ut(""), ft([]), mt([]), vt(e.message), It && q.error("Invalid module name or data could not be loaded."));
4529
+ t || (nt([]), it(0), ot([]), ct([]), dt(""), pt([]), ht([]), yt(e.message), Lt && q.error("Invalid module name or data could not be loaded."));
4523
4530
  }).finally(() => {
4524
- t || gt(!1);
4531
+ t || _t(!1);
4525
4532
  }), () => {
4526
4533
  t = !0;
4527
4534
  };
4528
4535
  }, [
4529
- Zt,
4530
- Jt,
4531
- Oe,
4532
- $t,
4533
- se,
4534
4536
  Qt,
4535
- Xt,
4536
- It,
4537
+ Yt,
4538
+ ke,
4537
4539
  en,
4540
+ oe,
4541
+ $t,
4542
+ Zt,
4543
+ Lt,
4544
+ nn,
4538
4545
  e,
4539
- nt,
4540
- Ie.current,
4541
- Ie.pageSize,
4542
- Pe,
4543
- ce,
4544
- Re.sort,
4545
- Re.sortDir,
4546
+ rt,
4547
+ Le.current,
4548
+ Le.pageSize,
4549
+ Fe,
4550
+ se,
4551
+ ze.sort,
4552
+ ze.sortDir,
4546
4553
  ve
4547
4554
  ]);
4548
- let nn = I(() => {
4549
- let e = Ct && Array.isArray(g) && g.length, t = !Ct && Array.isArray(ot) && ot.length, n = !Ut && Array.isArray(Vt) && Vt.length, r = e ? g : t ? ot : n ? Vt : [], i = new Map(ot.map((e) => [zl(e), e]).filter(([e]) => e));
4555
+ let rn = I(() => {
4556
+ let e = wt && Array.isArray(g) && g.length, t = !wt && Array.isArray(st) && st.length, n = !Wt && Array.isArray(Ht) && Ht.length, r = e ? g : t ? st : n ? Ht : [], i = new Map(st.map((e) => [zl(e), e]).filter(([e]) => e));
4550
4557
  return hu(r.map((e) => {
4551
4558
  let t = zl(e), n = i.get(t) ?? {};
4552
4559
  return {
@@ -4557,67 +4564,67 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4557
4564
  };
4558
4565
  }).filter((e) => e.key && e.label));
4559
4566
  }, [
4560
- Vt,
4561
- Ut,
4567
+ Ht,
4568
+ Wt,
4562
4569
  g,
4563
- Ct,
4564
- ot
4565
- ]), rn = I(() => nn.filter((e) => typeof e.isVisible == "boolean" ? e.isVisible : typeof e.isVisible == "string" ? e.isVisible.toLowerCase() === "true" : !0).map((e) => ({
4570
+ wt,
4571
+ st
4572
+ ]), an = I(() => rn.filter((e) => typeof e.isVisible == "boolean" ? e.isVisible : typeof e.isVisible == "string" ? e.isVisible.toLowerCase() === "true" : !0).map((e) => ({
4566
4573
  key: e.key,
4567
4574
  label: e.label
4568
- })), [nn]), an = rn.map((e) => e.key), on = Be.filter((e) => an.includes(e)), sn = on.length ? on : rn.slice(0, ue).map((e) => e.key), cn = Math.min(ue, rn.length), ln = sn.length > ue, un = I(() => nn.filter((e) => !e.cardHidden && (e.tableHidden || sn.includes(e.key))), [nn, sn]), dn = I(() => {
4569
- let e = Se.toLowerCase(), t = wt, n = Yt ? t.filter((e) => Vu(e, P, Kt, nn, qt)) : t, r = O.length ? nn.filter((e) => O.includes(e.key)) : nn;
4575
+ })), [rn]), on = an.map((e) => e.key), sn = Ve.filter((e) => on.includes(e)), cn = sn.length ? sn : an.slice(0, le).map((e) => e.key), ln = Math.min(le, an.length), un = cn.length > le, dn = I(() => rn.filter((e) => !e.cardHidden && (e.tableHidden || cn.includes(e.key))), [rn, cn]), fn = I(() => {
4576
+ let e = Ce.toLowerCase(), t = Tt, n = Xt ? t.filter((e) => Vu(e, xe, qt, rn, Jt)) : t, r = O.length ? rn.filter((e) => O.includes(e.key)) : rn;
4570
4577
  return !e || e.length < 3 ? n : n.filter((t) => r.some((n) => String(ql(t, n.key)).toLowerCase().includes(e) || xu(n).some((n) => String(ql(t, n)).toLowerCase().includes(e))));
4571
4578
  }, [
4572
- P,
4573
- Kt,
4579
+ xe,
4574
4580
  qt,
4575
- Yt,
4576
- wt,
4577
- nn,
4578
- Se,
4581
+ Jt,
4582
+ Xt,
4583
+ Tt,
4584
+ rn,
4585
+ Ce,
4579
4586
  O
4580
- ]), fn = I(() => {
4581
- if (!Xt) return dn;
4582
- let e = (Ie.current - 1) * Ie.pageSize;
4583
- return dn.slice(e, e + Ie.pageSize);
4587
+ ]), pn = I(() => {
4588
+ if (!Zt) return fn;
4589
+ let e = (Le.current - 1) * Le.pageSize;
4590
+ return fn.slice(e, e + Le.pageSize);
4584
4591
  }, [
4585
- dn,
4586
- Xt,
4587
- Ie.current,
4588
- Ie.pageSize
4589
- ]), pn = Xt ? dn.length : Tt, mn = we.trim().length >= 3, hn = String(dn.length).padStart(2, "0"), gn = Tt > 0 || wt.length > 0, _n = It ? _t ? "Invalid module name or data could not be loaded." : Ut ? "Field configuration failed to load." : "No data found." : "Please provide a module name to view data.", vn = I(() => {
4592
+ fn,
4593
+ Zt,
4594
+ Le.current,
4595
+ Le.pageSize
4596
+ ]), mn = Zt ? fn.length : Et, hn = Te.trim().length >= 3, gn = String(fn.length).padStart(2, "0"), _n = Et > 0 || Tt.length > 0, vn = Lt ? vt ? "Invalid module name or data could not be loaded." : Wt ? "Field configuration failed to load." : "No data found." : "Please provide a module name to view data.", yn = I(() => {
4590
4597
  let t = Array.isArray(m) ? m : [];
4591
- return t.length ? t : it.length ? it : [{
4598
+ return t.length ? t : at.length ? at : [{
4592
4599
  key: "all",
4593
4600
  title: e ?? "List",
4594
- count: pn
4601
+ count: mn
4595
4602
  }];
4596
4603
  }, [
4597
4604
  e,
4598
- it,
4599
- pn,
4605
+ at,
4606
+ mn,
4600
4607
  m
4601
4608
  ]);
4602
4609
  F(() => {
4603
- if (vn.length && !vn.some((e) => String(e?.key ?? e?.value ?? e?.id) === P)) {
4604
- let e = vn[0]?.key ?? vn[0]?.value ?? vn[0]?.id;
4605
- e && xe(String(e));
4606
- }
4607
- }, [P, vn]), F(() => {
4608
- if (ae === void 0 || !vn.length || ae === Ye.current) return;
4609
- Ye.current = ae;
4610
- let e = vn.find((e, t) => Ru(zu(e, t)) === Ru(ae)), t = e ? String(zu(e)) : "";
4611
- t && xe((e) => t === e ? e : t);
4612
- }, [vn, ae]);
4613
- let yn = (e) => {
4610
+ if (yn.length && !yn.some((e) => String(e?.key ?? e?.value ?? e?.id) === xe)) {
4611
+ let e = yn[0]?.key ?? yn[0]?.value ?? yn[0]?.id;
4612
+ e && Se(String(e));
4613
+ }
4614
+ }, [xe, yn]), F(() => {
4615
+ if (ie === void 0 || !yn.length || ie === Xe.current) return;
4616
+ Xe.current = ie;
4617
+ let e = yn.find((e, t) => Ru(zu(e, t)) === Ru(ie)), t = e ? String(zu(e)) : "";
4618
+ t && Se((e) => t === e ? e : t);
4619
+ }, [yn, ie]);
4620
+ let bn = (e) => {
4614
4621
  de("/popup/preview", { state: {
4615
4622
  background: fe,
4616
4623
  moduleName: pe,
4617
4624
  record: e,
4618
- fields: nn
4625
+ fields: rn
4619
4626
  } });
4620
- }, bn = (e, t) => {
4627
+ }, xn = (e, t) => {
4621
4628
  let n = nu(e, t), r = n.startsWith("/") ? n : `/${n}`, i = t?._id ?? t?.id;
4622
4629
  de(r, { state: {
4623
4630
  background: fe,
@@ -4627,7 +4634,7 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4627
4634
  popupContext: {},
4628
4635
  popupAction: {}
4629
4636
  } });
4630
- }, xn = I(() => {
4637
+ }, Sn = I(() => {
4631
4638
  let e = {
4632
4639
  dataIndex: "icons",
4633
4640
  key: "icons",
@@ -4641,7 +4648,7 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4641
4648
  type: "button",
4642
4649
  className: "job-row-eye-button",
4643
4650
  "aria-label": "Preview job",
4644
- onClick: () => yn(t),
4651
+ onClick: () => bn(t),
4645
4652
  children: /* @__PURE__ */ X("img", {
4646
4653
  src: Fl,
4647
4654
  alt: "",
@@ -4652,64 +4659,64 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4652
4659
  children: /* @__PURE__ */ X(ci, { className: "job-row-linkedin-icon" })
4653
4660
  })]
4654
4661
  })
4655
- }, t = nn.filter((e) => sn.includes(e.key)).map((e, t) => {
4656
- let n = Re.sort === e.key ? Re.sortDir : "";
4662
+ }, t = rn.filter((e) => cn.includes(e.key)).map((e, t) => {
4663
+ let n = ze.sort === e.key ? ze.sortDir : "";
4657
4664
  return {
4658
4665
  title: ed({
4659
4666
  label: e.label,
4660
4667
  sortDir: n,
4661
- sortable: gn,
4662
- onSort: () => Wt(e.key)
4668
+ sortable: _n,
4669
+ onSort: () => Gt(e.key)
4663
4670
  }),
4664
4671
  dataIndex: e.key,
4665
4672
  key: e.key,
4666
4673
  fixed: t === 0 ? "left" : void 0,
4667
4674
  ellipsis: { showTitle: !1 },
4668
- width: Lu(e, fn),
4669
- render: (t, n) => ku(e, n, we, bn, {
4675
+ width: Lu(e, pn),
4676
+ render: (t, n) => ku(e, n, Te, xn, {
4670
4677
  canAdd: he,
4671
4678
  canEdit: ge,
4672
4679
  canDelete: _e
4673
4680
  })
4674
4681
  };
4675
4682
  });
4676
- if (!(ln || Ct) && qe > 0 && t.length > 0) {
4677
- let n = e.width + (gn && M === "checkbox" ? 48 : 0) + Iu, r = t.reduce((e, t) => e + t.width, 0), i = qe - n - r;
4683
+ if (!(un || wt) && Je > 0 && t.length > 0) {
4684
+ let n = e.width + (_n && M === "checkbox" ? 48 : 0) + Iu, r = t.reduce((e, t) => e + t.width, 0), i = Je - n - r;
4678
4685
  i > 0 && r > 0 && t.forEach((e) => {
4679
4686
  e.width = Math.floor(e.width + i * (e.width / r));
4680
4687
  });
4681
4688
  }
4682
4689
  return [e, ...t];
4683
4690
  }, [
4684
- P,
4691
+ xe,
4685
4692
  he,
4686
4693
  _e,
4687
4694
  ge,
4688
- we,
4689
- jt,
4690
- Wt,
4691
- ln,
4692
- gn,
4693
- Ct,
4695
+ Te,
4696
+ Mt,
4697
+ Gt,
4698
+ un,
4699
+ _n,
4700
+ wt,
4694
4701
  fe,
4695
4702
  e,
4696
4703
  de,
4697
- nn,
4698
- fn,
4704
+ rn,
4705
+ pn,
4699
4706
  M,
4700
- Re.sort,
4701
- Re.sortDir,
4702
- qe,
4703
- Pt,
4704
- sn
4705
- ]), Sn = Tn((e) => {
4706
- if (xe(e), je([]), Ne([]), Bt(), typeof oe == "function") {
4707
- let t = vn.find((t, n) => String(zu(t, n)) === e), n = t?.key ?? t?.value ?? t?.id ?? e;
4708
- Ye.current = n, oe(n);
4709
- }
4710
- }, [oe, vn]);
4711
- function Cn(e, t, n) {
4712
- let r = Nt.get(String(e));
4707
+ ze.sort,
4708
+ ze.sortDir,
4709
+ Je,
4710
+ Ft,
4711
+ cn
4712
+ ]), Cn = Tn((e) => {
4713
+ if (Se(e), Me([]), Pe([]), Vt(), typeof ae == "function") {
4714
+ let t = yn.find((t, n) => String(zu(t, n)) === e), n = t?.key ?? t?.value ?? t?.id ?? e;
4715
+ Xe.current = n, ae(n);
4716
+ }
4717
+ }, [ae, yn]);
4718
+ function wn(e, t, n) {
4719
+ let r = Pt.get(String(e));
4713
4720
  if (r && r.actionType !== "group") {
4714
4721
  if (typeof s == "function" && s({
4715
4722
  key: r.key,
@@ -4738,7 +4745,7 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4738
4745
  records: n
4739
4746
  })
4740
4747
  }).then(() => {
4741
- q.success(`${r.label} completed`), Fe((e) => e + 1);
4748
+ q.success(`${r.label} completed`), Ie((e) => e + 1);
4742
4749
  }).catch((e) => q.error(e.message || `${r.label} failed`));
4743
4750
  return;
4744
4751
  }
@@ -4765,15 +4772,15 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4765
4772
  }
4766
4773
  }
4767
4774
  }
4768
- function wn({ key: e }) {
4769
- Cn(e, Ae, Me);
4775
+ function Dn({ key: e }) {
4776
+ wn(e, je, Ne);
4770
4777
  }
4771
- let Dn = sn.length === rn.length, On = sn.length > 0 && !Dn, kn = (e, t) => {
4772
- Ve((n) => {
4773
- let r = rn.slice(0, ue).map((e) => e.key), i = n.length ? n : r;
4774
- return t ? i.includes(e) ? i : [...i, e] : i.length <= cn ? i : i.filter((t) => t !== e);
4778
+ let On = cn.length === an.length, kn = cn.length > 0 && !On, jn = (e, t) => {
4779
+ He((n) => {
4780
+ let r = an.slice(0, le).map((e) => e.key), i = n.length ? n : r;
4781
+ return t ? i.includes(e) ? i : [...i, e] : i.length <= ln ? i : i.filter((t) => t !== e);
4775
4782
  });
4776
- }, jn = () => {
4783
+ }, z = () => {
4777
4784
  if (typeof c == "function") {
4778
4785
  c();
4779
4786
  return;
@@ -4782,55 +4789,55 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4782
4789
  de(p);
4783
4790
  return;
4784
4791
  }
4785
- St(!0);
4792
+ Ct(!0);
4786
4793
  };
4787
4794
  F(() => {
4788
- if (!xt) return;
4795
+ if (!St) return;
4789
4796
  let e = (e) => {
4790
- e.key === "Escape" && St(!1);
4797
+ e.key === "Escape" && Ct(!1);
4791
4798
  };
4792
4799
  return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
4793
- }, [xt]);
4794
- let z = () => {
4795
- en && (tt(yt.rows), rt(yt.total), at(yt.tabs), st(yt.fields), ut(yt.tabField), ft(yt.actions ?? []), mt(yt.actionRules ?? []), vt(null), gt(!1));
4796
- }, Pn = (e) => {
4797
- let t = e.target.value, n = t.trim().length < 3, r = Oe.some((e) => e.field);
4798
- n && (Te(""), r || z()), Ce(t), Bt();
4799
- }, Fn = () => {
4800
- let e = Se.trim();
4801
- e.length >= 3 && (Te(e), Bt());
4800
+ }, [St]);
4801
+ let Pn = () => {
4802
+ nn && (nt(bt.rows), it(bt.total), ot(bt.tabs), ct(bt.fields), dt(bt.tabField), pt(bt.actions ?? []), ht(bt.actionRules ?? []), yt(null), _t(!1));
4803
+ }, Fn = (e) => {
4804
+ let t = e.target.value, n = t.trim().length < 3, r = ke.some((e) => e.field);
4805
+ n && (Ee(""), r || Pn()), we(t), Vt();
4802
4806
  }, In = () => {
4803
- z(), ke([]), $e([], []), Bt();
4807
+ let e = Ce.trim();
4808
+ e.length >= 3 && (Ee(e), Vt());
4809
+ }, Ln = () => {
4810
+ Pn(), Ae([]), et([], []), Vt();
4804
4811
  };
4805
4812
  F(() => {
4806
- kt === "card" && (Ge([]), $e([], []));
4813
+ At === "card" && (Ke([]), et([], []));
4807
4814
  }, [
4808
- Ie.current,
4809
- Ie.pageSize,
4810
- P,
4811
- kt
4815
+ Le.current,
4816
+ Le.pageSize,
4817
+ xe,
4818
+ At
4812
4819
  ]);
4813
- let Ln = (e) => {
4814
- Ge((t) => {
4820
+ let B = (e) => {
4821
+ Ke((t) => {
4815
4822
  let n = t.includes(e) ? t.filter((t) => t !== e) : [...t, e];
4816
- return $e(n, fn.filter((e, t) => n.includes(String(Hu(e, t, l))))), n;
4823
+ return et(n, pn.filter((e, t) => n.includes(String(Hu(e, t, l))))), n;
4817
4824
  });
4818
- }, B = /* @__PURE__ */ Z("div", {
4825
+ }, Vn = /* @__PURE__ */ Z("div", {
4819
4826
  className: "column-visibility-menu",
4820
4827
  onClick: (e) => e.stopPropagation(),
4821
4828
  children: [/* @__PURE__ */ X(Nn, {
4822
- checked: Dn,
4823
- indeterminate: On,
4829
+ checked: On,
4830
+ indeterminate: kn,
4824
4831
  onChange: (e) => {
4825
- Ve(e.target.checked ? rn.map((e) => e.key) : rn.slice(0, ue).map((e) => e.key));
4832
+ He(e.target.checked ? an.map((e) => e.key) : an.slice(0, le).map((e) => e.key));
4826
4833
  },
4827
4834
  children: "Select All"
4828
4835
  }), /* @__PURE__ */ X("div", {
4829
4836
  className: "column-visibility-menu__list",
4830
- children: rn.map((e) => /* @__PURE__ */ X(Nn, {
4831
- checked: sn.includes(e.key),
4832
- disabled: sn.includes(e.key) && sn.length <= cn,
4833
- onChange: (t) => kn(e.key, t.target.checked),
4837
+ children: an.map((e) => /* @__PURE__ */ X(Nn, {
4838
+ checked: cn.includes(e.key),
4839
+ disabled: cn.includes(e.key) && cn.length <= ln,
4840
+ onChange: (t) => jn(e.key, t.target.checked),
4834
4841
  children: e.label
4835
4842
  }, e.key))
4836
4843
  })]
@@ -4848,81 +4855,81 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4848
4855
  align: "center",
4849
4856
  justify: "space-between",
4850
4857
  children: [/* @__PURE__ */ X(Aa, {
4851
- activeKey: P,
4852
- tabs: vn,
4853
- onChange: Sn
4858
+ activeKey: xe,
4859
+ tabs: yn,
4860
+ onChange: Cn
4854
4861
  }), /* @__PURE__ */ Z(Bn, {
4855
4862
  align: "center",
4856
4863
  gap: 8,
4857
4864
  children: [
4858
- gn && /* @__PURE__ */ X(V, {
4865
+ _n && /* @__PURE__ */ X(V, {
4859
4866
  prefix: /* @__PURE__ */ X(ki, { className: "job-search-icon" }),
4860
4867
  placeholder: D,
4861
- value: Se,
4862
- onChange: Pn,
4863
- onPressEnter: Fn,
4868
+ value: Ce,
4869
+ onChange: Fn,
4870
+ onPressEnter: In,
4864
4871
  allowClear: !0,
4865
4872
  className: "job-search-input"
4866
4873
  }),
4867
- !Ct && he && /* @__PURE__ */ X(K, {
4874
+ !wt && he && ue && /* @__PURE__ */ X(K, {
4868
4875
  title: "Add",
4869
4876
  children: /* @__PURE__ */ X(R, {
4870
4877
  "aria-label": "Add",
4871
4878
  className: "job-toolbar-icon-button",
4872
4879
  icon: /* @__PURE__ */ X(J, {}),
4873
4880
  onClick: () => {
4874
- Lt && de(Lt);
4881
+ Rt && de(Rt);
4875
4882
  }
4876
4883
  })
4877
4884
  }),
4878
- gn && /* @__PURE__ */ X(K, {
4885
+ _n && /* @__PURE__ */ X(K, {
4879
4886
  title: "Filter",
4880
4887
  children: /* @__PURE__ */ X(An, {
4881
- count: Oe.filter((e) => e.field && cd(e)).length,
4888
+ count: ke.filter((e) => e.field && cd(e)).length,
4882
4889
  size: "small",
4883
4890
  offset: [-2, 2],
4884
4891
  children: /* @__PURE__ */ X(R, {
4885
4892
  "aria-label": "Filter",
4886
4893
  className: "job-toolbar-icon-button",
4887
4894
  icon: /* @__PURE__ */ X($r, {}),
4888
- onClick: () => De(!0)
4895
+ onClick: () => Oe(!0)
4889
4896
  })
4890
4897
  })
4891
4898
  }),
4892
- k && gn && /* @__PURE__ */ Z(Bn, {
4899
+ k && _n && /* @__PURE__ */ Z(Bn, {
4893
4900
  align: "center",
4894
4901
  gap: 6,
4895
4902
  children: [/* @__PURE__ */ X(K, {
4896
4903
  title: "List View",
4897
4904
  children: /* @__PURE__ */ X(R, {
4898
- className: `job-toolbar-icon-button param-view-toggle-btn${kt === "list" ? " param-view-toggle-btn--active" : ""}`,
4905
+ className: `job-toolbar-icon-button param-view-toggle-btn${At === "list" ? " param-view-toggle-btn--active" : ""}`,
4899
4906
  icon: /* @__PURE__ */ X(Wi, {}),
4900
4907
  onClick: () => {
4901
- A?.("list"), Ge([]), $e([], []);
4908
+ A?.("list"), Ke([]), et([], []);
4902
4909
  }
4903
4910
  })
4904
4911
  }), /* @__PURE__ */ X(K, {
4905
4912
  title: "Card View",
4906
4913
  children: /* @__PURE__ */ X(R, {
4907
- className: `job-toolbar-icon-button param-view-toggle-btn${kt === "card" ? " param-view-toggle-btn--active" : ""}`,
4914
+ className: `job-toolbar-icon-button param-view-toggle-btn${At === "card" ? " param-view-toggle-btn--active" : ""}`,
4908
4915
  icon: /* @__PURE__ */ X(ur, {}),
4909
4916
  onClick: () => {
4910
- A?.("card"), Ge([]), $e([], []);
4917
+ A?.("card"), Ke([]), et([], []);
4911
4918
  }
4912
4919
  })
4913
4920
  })]
4914
4921
  }),
4915
- d && gn && /* @__PURE__ */ X(R, {
4922
+ d && _n && /* @__PURE__ */ X(R, {
4916
4923
  className: "job-summary-button",
4917
4924
  type: "primary",
4918
- onClick: jn,
4925
+ onClick: z,
4919
4926
  children: f
4920
4927
  })
4921
4928
  ]
4922
4929
  })]
4923
4930
  })
4924
4931
  }),
4925
- gn && /* @__PURE__ */ X(Y, { children: /* @__PURE__ */ X(Mn, {
4932
+ _n && /* @__PURE__ */ X(Y, { children: /* @__PURE__ */ X(Mn, {
4926
4933
  className: "job-toolbar-card",
4927
4934
  children: /* @__PURE__ */ Z(Bn, {
4928
4935
  className: "p-flex",
@@ -4932,24 +4939,24 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4932
4939
  align: "center",
4933
4940
  gap: 3,
4934
4941
  children: [
4935
- kt === "card" && /* @__PURE__ */ X(Nn, {
4936
- checked: fn.length > 0 && We.length >= fn.length,
4937
- indeterminate: We.length > 0 && We.length < fn.length,
4942
+ At === "card" && /* @__PURE__ */ X(Nn, {
4943
+ checked: pn.length > 0 && Ge.length >= pn.length,
4944
+ indeterminate: Ge.length > 0 && Ge.length < pn.length,
4938
4945
  className: "param-card-view__select-all",
4939
4946
  onChange: () => {
4940
- if (We.length > 0) Ge([]), $e([], []);
4947
+ if (Ge.length > 0) Ke([]), et([], []);
4941
4948
  else {
4942
- let e = fn.map((e, t) => String(Hu(e, t, l)));
4943
- Ge(e), $e(e, [...fn]);
4949
+ let e = pn.map((e, t) => String(Hu(e, t, l)));
4950
+ Ke(e), et(e, [...pn]);
4944
4951
  }
4945
4952
  },
4946
4953
  children: "Select All"
4947
4954
  }),
4948
4955
  /* @__PURE__ */ X(Rn, {
4949
- open: He,
4950
- onOpenChange: Ue,
4956
+ open: Ue,
4957
+ onOpenChange: We,
4951
4958
  trigger: ["click"],
4952
- dropdownRender: () => B,
4959
+ dropdownRender: () => Vn,
4953
4960
  placement: "bottomLeft",
4954
4961
  overlayClassName: "column-visibility-dropdown",
4955
4962
  children: /* @__PURE__ */ X(R, {
@@ -4965,10 +4972,10 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4965
4972
  children: /* @__PURE__ */ X(Rr, { className: "job-actions-caret" })
4966
4973
  })
4967
4974
  }),
4968
- Ft.length > 0 && Ae.length > 0 && /* @__PURE__ */ X(Rn, {
4975
+ It.length > 0 && je.length > 0 && /* @__PURE__ */ X(Rn, {
4969
4976
  menu: {
4970
- items: Ft.map(qu),
4971
- onClick: wn
4977
+ items: It.map(qu),
4978
+ onClick: Dn
4972
4979
  },
4973
4980
  trigger: ["click"],
4974
4981
  children: /* @__PURE__ */ Z(R, {
@@ -4986,60 +4993,60 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
4986
4993
  ]
4987
4994
  })
4988
4995
  }),
4989
- Ae.length > 0 && /* @__PURE__ */ Z(Ll, {
4996
+ je.length > 0 && /* @__PURE__ */ Z(Ll, {
4990
4997
  className: "job-selected-count",
4991
4998
  children: [
4992
4999
  "Selected (",
4993
- Ae.length,
5000
+ je.length,
4994
5001
  ")"
4995
5002
  ]
4996
5003
  })
4997
5004
  ]
4998
- }), mn && /* @__PURE__ */ Z(Ll, {
5005
+ }), hn && /* @__PURE__ */ Z(Ll, {
4999
5006
  className: "job-search-results-count",
5000
5007
  children: [
5001
5008
  "Search Results (",
5002
- hn,
5009
+ gn,
5003
5010
  ")"
5004
5011
  ]
5005
5012
  })]
5006
5013
  })
5007
5014
  }) }),
5008
- Qt && /* @__PURE__ */ X(dd, {
5009
- filters: Oe,
5015
+ $t && /* @__PURE__ */ X(dd, {
5016
+ filters: ke,
5010
5017
  onRemove: (e) => {
5011
- ke(Oe.filter((t, n) => n !== e)), Bt();
5018
+ Ae(ke.filter((t, n) => n !== e)), Vt();
5012
5019
  },
5013
- onClearAll: In
5020
+ onClearAll: Ln
5014
5021
  }),
5015
5022
  /* @__PURE__ */ X("div", {
5016
- ref: Ke,
5023
+ ref: qe,
5017
5024
  className: "job-table-measure",
5018
5025
  children: /* @__PURE__ */ X($n, {
5019
- spinning: Ct ? v : Ht || ht,
5020
- children: kt === "card" ? fn.length === 0 ? /* @__PURE__ */ X(zn, {
5026
+ spinning: wt ? v : Ut || gt,
5027
+ children: At === "card" ? pn.length === 0 ? /* @__PURE__ */ X(zn, {
5021
5028
  image: zn.PRESENTED_IMAGE_SIMPLE,
5022
- description: _n,
5029
+ description: vn,
5023
5030
  className: "param-card-view__empty",
5024
- children: !Ct && he && Lt && !_t && /* @__PURE__ */ X(R, {
5031
+ children: !wt && he && ue && Rt && !vt && /* @__PURE__ */ X(R, {
5025
5032
  type: "primary",
5026
5033
  icon: /* @__PURE__ */ X(J, {}),
5027
- onClick: () => de(Lt),
5034
+ onClick: () => de(Rt),
5028
5035
  children: "Add New"
5029
5036
  })
5030
5037
  }) : /* @__PURE__ */ X("div", {
5031
5038
  className: "param-card-view__grid",
5032
- children: fn.map((e, t) => {
5039
+ children: pn.map((e, t) => {
5033
5040
  let n = String(Hu(e, t, l));
5034
5041
  return /* @__PURE__ */ X(sd, {
5035
5042
  record: e,
5036
- fields: un,
5037
- selected: M === "checkbox" ? We.includes(n) : Ze(e, t),
5038
- isControlled: Ct,
5039
- onPreview: () => yn(e),
5040
- onSelect: () => Ln(n),
5041
- onPopupAction: bn,
5042
- onRecordClick: ne ? () => Qe(e, t) : void 0,
5043
+ fields: dn,
5044
+ selected: M === "checkbox" ? Ge.includes(n) : Qe(e, t),
5045
+ isControlled: wt,
5046
+ onPreview: () => bn(e),
5047
+ onSelect: () => B(n),
5048
+ onPopupAction: xn,
5049
+ onRecordClick: ne ? () => $e(e, t) : void 0,
5043
5050
  selectionMode: M,
5044
5051
  permissions: {
5045
5052
  canAdd: he,
@@ -5049,89 +5056,89 @@ function fd({ moduleName: e, actions: t = [], actionRules: n = [], breadcrumbIte
5049
5056
  }, n);
5050
5057
  })
5051
5058
  }) : /* @__PURE__ */ X(nr, {
5052
- rowSelection: gn && M === "checkbox" ? {
5059
+ rowSelection: _n && M === "checkbox" ? {
5053
5060
  type: "checkbox",
5054
5061
  fixed: !0,
5055
5062
  columnWidth: 48,
5056
- selectedRowKeys: Ae,
5063
+ selectedRowKeys: je,
5057
5064
  onChange: (e, t) => {
5058
- $e(e, t);
5065
+ et(e, t);
5059
5066
  },
5060
5067
  columnTitle: (() => {
5061
- let e = fn.length, t = e > 0 && Ae.length >= e, n = Ae.length > 0 && !t;
5068
+ let e = pn.length, t = e > 0 && je.length >= e, n = je.length > 0 && !t;
5062
5069
  return /* @__PURE__ */ X(Nn, {
5063
5070
  checked: t,
5064
5071
  indeterminate: n,
5065
5072
  onChange: () => {
5066
- n || t ? $e([], []) : $e(fn.map((e, t) => Hu(e, t, l)), [...fn]);
5073
+ n || t ? et([], []) : et(pn.map((e, t) => Hu(e, t, l)), [...pn]);
5067
5074
  }
5068
5075
  });
5069
5076
  })()
5070
5077
  } : void 0,
5071
- columns: xn,
5072
- dataSource: fn,
5078
+ columns: Sn,
5079
+ dataSource: pn,
5073
5080
  size: "middle",
5074
5081
  tableLayout: "fixed",
5075
5082
  scroll: {
5076
- x: ln || Ct ? "max-content" : void 0,
5083
+ x: un || wt ? "max-content" : void 0,
5077
5084
  y: "calc(100vh - 300px)"
5078
5085
  },
5079
5086
  pagination: !1,
5080
5087
  locale: { emptyText: /* @__PURE__ */ X(zn, {
5081
5088
  image: zn.PRESENTED_IMAGE_SIMPLE,
5082
- description: _n
5089
+ description: vn
5083
5090
  }) },
5084
5091
  className: `${h} ${re ? "list-view-table--compact" : ""}`.trim(),
5085
5092
  onRow: ne ? (e, t) => ({
5086
5093
  onClick: (n) => {
5087
- Uu(n.target) || Qe(e, t);
5094
+ Uu(n.target) || $e(e, t);
5088
5095
  },
5089
- "aria-selected": Ze(e, t)
5096
+ "aria-selected": Qe(e, t)
5090
5097
  }) : void 0,
5091
- rowClassName: j == null ? void 0 : (e, t) => Ze(e, t) ? "list-view-row--active" : "",
5098
+ rowClassName: j == null ? void 0 : (e, t) => Qe(e, t) ? "list-view-row--active" : "",
5092
5099
  rowKey: (e, t) => Hu(e, t, l)
5093
5100
  })
5094
5101
  })
5095
5102
  }),
5096
- gn ? /* @__PURE__ */ X(po, {
5097
- current: Ie.current,
5098
- pageSize: Ie.pageSize,
5099
- total: pn,
5103
+ _n ? /* @__PURE__ */ X(po, {
5104
+ current: Le.current,
5105
+ pageSize: Le.pageSize,
5106
+ total: mn,
5100
5107
  onChange: (e, t) => {
5101
- if (Ct && typeof C == "function") {
5102
- C(e, t ?? Ie.pageSize);
5108
+ if (wt && typeof C == "function") {
5109
+ C(e, t ?? Le.pageSize);
5103
5110
  return;
5104
5111
  }
5105
- zt(e);
5112
+ Bt(e);
5106
5113
  },
5107
5114
  onPageSizeChange: (e) => {
5108
- if (Ct && typeof w == "function") {
5115
+ if (wt && typeof w == "function") {
5109
5116
  w(e);
5110
5117
  return;
5111
5118
  }
5112
- Le({
5119
+ Re({
5113
5120
  current: 1,
5114
5121
  pageSize: e
5115
- }), Rt(1, { replace: !0 });
5122
+ }), zt(1, { replace: !0 });
5116
5123
  }
5117
5124
  }) : void 0,
5118
5125
  /* @__PURE__ */ X(Pl, {
5119
5126
  moduleName: pe,
5120
- open: Ee,
5121
- filters: Oe,
5122
- onClose: () => De(!1),
5127
+ open: De,
5128
+ filters: ke,
5129
+ onClose: () => Oe(!1),
5123
5130
  onApply: ({ filters: e }) => {
5124
- ke(e), Bt();
5131
+ Ae(e), Vt();
5125
5132
  },
5126
- onReset: In
5133
+ onReset: Ln
5127
5134
  }),
5128
5135
  /* @__PURE__ */ X(xl, {
5129
5136
  moduleName: pe,
5130
- open: xt,
5131
- rows: et,
5132
- tabs: vn,
5133
- total: pn,
5134
- onClose: () => St(!1)
5137
+ open: St,
5138
+ rows: tt,
5139
+ tabs: yn,
5140
+ total: mn,
5141
+ onClose: () => Ct(!1)
5135
5142
  })
5136
5143
  ]
5137
5144
  });
@@ -5443,7 +5450,7 @@ function Zd(e = [], t, n, r) {
5443
5450
  ...e,
5444
5451
  show: 1,
5445
5452
  req: 1
5446
- } : e).filter((r) => String(r.field ?? "").trim() !== "" && (r.show === void 0 || Id(r.show)) && r.showOnAdd !== !1 && !Id(r.clientScope) && (!r.visiblePermission || lt(r.visiblePermission, t)) && qt(n, e.name, r.field)).map((t) => me(n, e.name, t.field) ? t : {
5453
+ } : e).filter((r) => String(r.field ?? "").trim() !== "" && (r.show === void 0 || Id(r.show)) && r.showOnAdd !== !1 && !Id(r.clientScope) && (!r.visiblePermission || lt(r.visiblePermission, t)) && qt(n, e.name, r.field)).map((t) => pe(n, e.name, t.field) ? t : {
5447
5454
  ...t,
5448
5455
  disabled: !0
5449
5456
  }).sort((e, t) => Number(e.order ?? 0) - Number(t.order ?? 0))
@@ -5466,7 +5473,7 @@ function $d(e, t) {
5466
5473
  ]) {
5467
5474
  if (!n) continue;
5468
5475
  let t = e[n];
5469
- if (t ??= ue(e, n), t != null) return t;
5476
+ if (t ??= le(e, n), t != null) return t;
5470
5477
  }
5471
5478
  }
5472
5479
  function ef(e) {
@@ -5682,7 +5689,7 @@ function mf(e, t, n, r = !1) {
5682
5689
  }), [
5683
5690
  ...c,
5684
5691
  ...a.map((r) => df(r, e, t, n)),
5685
- ge(e)
5692
+ he(e)
5686
5693
  ];
5687
5694
  }
5688
5695
  function hf(e, t) {
@@ -5782,7 +5789,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5782
5789
  open: !1,
5783
5790
  docs: [],
5784
5791
  index: 0
5785
- }), [O, k] = L(null), ee = En([]), A = Array.isArray(n) && n.length >= 3 && typeof n[1] == "number", ne = e.lookupFilterValueFrom ? zd(e.lookupFilterValueFrom) : [`__lookup_filter_${e.field}`], j = e.lookupFilterValueFrom && A ? [...n.slice(0, 2), ...zd(e.lookupFilterValueFrom)] : ["__noop_row_filter__"], M = B.useWatch(ne, t), re = B.useWatch(j, t), ie = tf(re) ? M : re, N = e.disabledByField ? Array.isArray(n) && n.length > 1 ? [...n.slice(0, -1), e.disabledByField] : [e.disabledByField] : ["__noop_disabled_watch__"], ae = B.useWatch(N, t), oe = e.disabledIf?.field ? zd(e.disabledIf.field) : ["__noop_disabled_if__"], se = e.disabledIf?.field && A ? [...n.slice(0, 2), ...zd(e.disabledIf.field)] : ["__noop_disabled_if_row__"], le = B.useWatch(oe, t), ue = B.useWatch(se, t), de = e.disabledIf?.field ? Yt(e.disabledIf, tf(ue) ? le : ue) : !1, fe = f || !!e.disabled || de || (e.disabledByField ? Id(ae) : !1) || !!l, pe = e.lookupFilterValueFrom ? s[e.lookupFilterValueFrom] : void 0, me = tf(pe) ? ie : pe;
5792
+ }), [O, k] = L(null), ee = En([]), A = Array.isArray(n) && n.length >= 3 && typeof n[1] == "number", ne = e.lookupFilterValueFrom ? zd(e.lookupFilterValueFrom) : [`__lookup_filter_${e.field}`], j = e.lookupFilterValueFrom && A ? [...n.slice(0, 2), ...zd(e.lookupFilterValueFrom)] : ["__noop_row_filter__"], M = B.useWatch(ne, t), re = B.useWatch(j, t), N = tf(re) ? M : re, P = e.disabledByField ? Array.isArray(n) && n.length > 1 ? [...n.slice(0, -1), e.disabledByField] : [e.disabledByField] : ["__noop_disabled_watch__"], ie = B.useWatch(P, t), ae = e.disabledIf?.field ? zd(e.disabledIf.field) : ["__noop_disabled_if__"], oe = e.disabledIf?.field && A ? [...n.slice(0, 2), ...zd(e.disabledIf.field)] : ["__noop_disabled_if_row__"], ce = B.useWatch(ae, t), le = B.useWatch(oe, t), ue = e.disabledIf?.field ? Yt(e.disabledIf, tf(le) ? ce : le) : !1, de = f || !!e.disabled || ue || (e.disabledByField ? Id(ie) : !1) || !!l, fe = e.lookupFilterValueFrom ? s[e.lookupFilterValueFrom] : void 0, pe = tf(fe) ? N : fe;
5786
5793
  F(() => {
5787
5794
  if (d === "location") {
5788
5795
  let t = !1;
@@ -5811,7 +5818,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5811
5818
  "radio",
5812
5819
  "checkbox"
5813
5820
  ].includes(d) || !t || t === "static") return;
5814
- if (t === "lookup" && e.lookupFilterField && tf(me)) {
5821
+ if (t === "lookup" && e.lookupFilterField && tf(pe)) {
5815
5822
  m([]), g(!1);
5816
5823
  return;
5817
5824
  }
@@ -5831,7 +5838,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5831
5838
  displayField: e.displayField ?? "",
5832
5839
  valueField: e.valueField ?? "_id"
5833
5840
  });
5834
- e.displayField2 && t.set("displayField2", e.displayField2), y && t.set("search", y), e.lookupFilterField && !tf(me) && (t.set("filterField", e.lookupFilterField), t.set("filterValue", String(me))), e.extraFields?.length && t.set("extraFields", e.extraFields.join(","));
5841
+ e.displayField2 && t.set("displayField2", e.displayField2), y && t.set("search", y), e.lookupFilterField && !tf(pe) && (t.set("filterField", e.lookupFilterField), t.set("filterValue", String(pe))), e.extraFields?.length && t.set("extraFields", e.extraFields.join(","));
5835
5842
  let n = await u(b, `/admin/lookup-dropdown-values?${t}`);
5836
5843
  i = n?.data ?? n ?? [], e.optionsRequireExtraField && (i = i.filter((t) => t?.extraData?.[e.optionsRequireExtraField] === !0));
5837
5844
  } else if (t === "group") {
@@ -5864,7 +5871,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5864
5871
  e.displayField2,
5865
5872
  e.valueField,
5866
5873
  e.lookupFilterField,
5867
- me,
5874
+ pe,
5868
5875
  e.groupName,
5869
5876
  e.masterName,
5870
5877
  _,
@@ -5875,7 +5882,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5875
5882
  e.optionsRequireExtraField,
5876
5883
  w
5877
5884
  ]);
5878
- let he = Rd(e.options ?? e.values ?? []), ge = p ?? he, _e = (e.multiSelect ? "multiple" : e.mode ?? (Id(e.multiple) ? "multiple" : void 0)) ?? (Ve(e) === "array" ? "multiple" : void 0), ve = ["select", "location"].includes(d), ye = e.hidePlaceholder ? void 0 : e.placeholder ?? `${ve ? "Select" : "Enter"} ${String(e.label ?? "").toLowerCase()}`, be = gf(e), P = (e) => {
5885
+ let me = Rd(e.options ?? e.values ?? []), he = p ?? me, ge = (e.multiSelect ? "multiple" : e.mode ?? (Id(e.multiple) ? "multiple" : void 0)) ?? (Ve(e) === "array" ? "multiple" : void 0), _e = ["select", "location"].includes(d), ve = e.hidePlaceholder ? void 0 : e.placeholder ?? `${_e ? "Select" : "Enter"} ${String(e.label ?? "").toLowerCase()}`, ye = gf(e), be = (e) => {
5879
5886
  o?.(e), setTimeout(() => {
5880
5887
  t.validateFields([n]).catch(() => {});
5881
5888
  }, 0);
@@ -5889,15 +5896,15 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5889
5896
  onDone: (t, n) => {
5890
5897
  T((e) => e + 1);
5891
5898
  let r = Ve(e) !== "array" && !e.multiSelect && !e.multiple;
5892
- t === "create" && n != null && r && P(ce(e) ? { value: n } : n);
5899
+ t === "create" && n != null && r && be(se(e) ? { value: n } : n);
5893
5900
  }
5894
5901
  }), Se = e.validator?.type ? {
5895
5902
  ...e.validator,
5896
5903
  title: e.validator.title || e.label || "Field"
5897
5904
  } : null, Ce = {
5898
- ...be,
5899
- disabled: fe,
5900
- placeholder: ye,
5905
+ ...ye,
5906
+ disabled: de,
5907
+ placeholder: ve,
5901
5908
  prefix: e.icon ? null : Fd[e.field],
5902
5909
  value: i ?? "",
5903
5910
  onChange: (t) => {
@@ -5906,12 +5913,12 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5906
5913
  let { cleaned: e, error: t } = _t(n, Se, "change");
5907
5914
  k(t), n = e;
5908
5915
  }
5909
- P(n);
5916
+ be(n);
5910
5917
  },
5911
5918
  ...Se && {
5912
5919
  onBlur: (e) => {
5913
5920
  let { cleaned: t, error: n } = _t(e.target.value, Se, "blur");
5914
- k(n), t !== e.target.value && P(t);
5921
+ k(n), t !== e.target.value && be(t);
5915
5922
  },
5916
5923
  onKeyPress: (e) => {
5917
5924
  let t = Ze(Se.type);
@@ -5923,49 +5930,49 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5923
5930
  k(t), setTimeout(() => k((e) => e === t ? null : e), 1800);
5924
5931
  }
5925
5932
  },
5926
- maxLength: Se.maxLength ?? be.maxLength
5933
+ maxLength: Se.maxLength ?? ye.maxLength
5927
5934
  }
5928
5935
  };
5929
5936
  if (d === "tagify") return /* @__PURE__ */ X(H, {
5930
5937
  value: i,
5931
5938
  allowClear: !0,
5932
- disabled: fe,
5939
+ disabled: de,
5933
5940
  mode: "tags",
5934
- placeholder: ye,
5935
- onChange: P
5941
+ placeholder: ve,
5942
+ onChange: be
5936
5943
  });
5937
5944
  if (d === "location") return /* @__PURE__ */ X(H, {
5938
5945
  value: i,
5939
5946
  allowClear: !0,
5940
5947
  showSearch: !0,
5941
5948
  filterOption: !1,
5942
- disabled: fe,
5949
+ disabled: de,
5943
5950
  loading: h,
5944
- options: ge,
5945
- placeholder: ye,
5951
+ options: he,
5952
+ placeholder: ve,
5946
5953
  notFoundContent: h ? /* @__PURE__ */ X($n, { size: "small" }) : void 0,
5947
5954
  onSearch: v,
5948
5955
  onFocus: () => v((e) => e),
5949
- onChange: P
5956
+ onChange: be
5950
5957
  });
5951
5958
  if (d === "select") {
5952
- let r = e.dataSource === "lookup", a = e.dataSource === "master", o = r || a, s = e.dataSource === "group", c = ce(e);
5959
+ let r = e.dataSource === "lookup", a = e.dataSource === "master", o = r || a, s = e.dataSource === "group", c = se(e);
5953
5960
  return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(H, {
5954
- value: Ue(e, i, ge),
5961
+ value: Ue(e, i, he),
5955
5962
  labelInValue: c || void 0,
5956
5963
  allowClear: !0,
5957
5964
  showSearch: o || s || void 0,
5958
5965
  optionFilterProp: "label",
5959
5966
  filterOption: o ? !1 : void 0,
5960
- disabled: fe,
5967
+ disabled: de,
5961
5968
  loading: h,
5962
- mode: _e,
5963
- options: ge,
5964
- placeholder: ye,
5969
+ mode: ge,
5970
+ options: he,
5971
+ placeholder: ve,
5965
5972
  notFoundContent: h ? /* @__PURE__ */ X($n, { size: "small" }) : void 0,
5966
5973
  onSearch: r ? x : a ? C : void 0,
5967
5974
  onChange: (r) => {
5968
- if (P(r), e.autofillFrom?.length) {
5975
+ if (be(r), e.autofillFrom?.length) {
5969
5976
  let i = r && !Array.isArray(r) && typeof r == "object" ? r.value : r, a = Array.isArray(n) && n.length >= 3 && typeof n[1] == "number";
5970
5977
  if (r == null) e.autofillFrom.forEach(({ targetField: e }) => {
5971
5978
  let r = a ? [...n.slice(0, 2), ...zd(e)] : zd(e);
@@ -5985,21 +5992,21 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
5985
5992
  }
5986
5993
  if (d === "radio") return /* @__PURE__ */ X(Xn.Group, {
5987
5994
  value: i,
5988
- disabled: fe,
5989
- options: ge,
5990
- onChange: (e) => P(e.target.value)
5995
+ disabled: de,
5996
+ options: he,
5997
+ onChange: (e) => be(e.target.value)
5991
5998
  });
5992
- if (d === "checkbox") return ge.length > 0 ? /* @__PURE__ */ X(Nn.Group, {
5999
+ if (d === "checkbox") return he.length > 0 ? /* @__PURE__ */ X(Nn.Group, {
5993
6000
  value: i,
5994
- disabled: fe,
5995
- options: ge,
5996
- onChange: P
6001
+ disabled: de,
6002
+ options: he,
6003
+ onChange: be
5997
6004
  }) : /* @__PURE__ */ X(Nn, {
5998
6005
  checked: !!(a ?? i),
5999
- disabled: fe,
6006
+ disabled: de,
6000
6007
  onChange: (r) => {
6001
6008
  let i = r.target.checked;
6002
- if (P(i), e.linkedClearField && i) {
6009
+ if (be(i), e.linkedClearField && i) {
6003
6010
  let r = Array.isArray(n) && n.length > 1 ? [...n.slice(0, -1), e.linkedClearField] : [e.linkedClearField];
6004
6011
  t.setFieldValue(r, null);
6005
6012
  }
@@ -6008,14 +6015,14 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6008
6015
  });
6009
6016
  if (d === "text-editor") return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(At, {
6010
6017
  value: i ?? t.getFieldValue(n) ?? "",
6011
- disabled: fe,
6012
- placeholder: ye,
6018
+ disabled: de,
6019
+ placeholder: ve,
6013
6020
  onChange: (e) => {
6014
6021
  if (Se) {
6015
6022
  let { error: t } = _t(e, Se, "change");
6016
6023
  k(t);
6017
6024
  }
6018
- P(e);
6025
+ be(e);
6019
6026
  }
6020
6027
  }), O && /* @__PURE__ */ X("div", {
6021
6028
  className: "v1-input-validator-hint",
@@ -6030,21 +6037,21 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6030
6037
  children: O
6031
6038
  })] });
6032
6039
  if (d === "date") return /* @__PURE__ */ X(Fn, {
6033
- disabled: fe,
6034
- placeholder: ye,
6040
+ disabled: de,
6041
+ placeholder: ve,
6035
6042
  style: { width: "100%" },
6036
6043
  suffixIcon: /* @__PURE__ */ X(vr, {}),
6037
6044
  value: i ?? null,
6038
6045
  disabledDate: _f(e, t, n),
6039
6046
  defaultPickerValue: vf(e),
6040
- onChange: (e) => P(e)
6047
+ onChange: (e) => be(e)
6041
6048
  });
6042
6049
  if (d === "time") return /* @__PURE__ */ X(ir, {
6043
- disabled: fe,
6044
- placeholder: ye,
6050
+ disabled: de,
6051
+ placeholder: ve,
6045
6052
  style: { width: "100%" },
6046
6053
  value: i ?? null,
6047
- onChange: (e) => P(e)
6054
+ onChange: (e) => be(e)
6048
6055
  });
6049
6056
  if (d === "file") {
6050
6057
  let t = e.validations ?? e.validation ?? e.rules ?? [], n = t.find((e) => (typeof e == "string" ? e : e?.type) === "fileType"), r = t.find((e) => (typeof e == "string" ? e : e?.type) === "fileSize"), a = t.find((e) => (typeof e == "string" ? e : e?.type) === "maxFiles"), o = Ft(e), s = o ? o.exts.map((e) => `.${e}`).join(",") : n?.value ? n.value.split(",").map((e) => `.${e.trim().replace(/^\./, "")}`).join(",") : void 0, l = r ? Number(r?.value ?? 5) : void 0, u = a ? Number(a?.value ?? 1) : Id(e.multiple) ? e.maxCount ?? 5 : 1, d = Array.isArray(i) ? i : [], f = d.length < u, p = (e) => e ? e < 1024 * 1024 ? `${(e / 1024).toFixed(0)} KB` : `${(e / 1024 / 1024).toFixed(2)} MB` : "", m = (e) => {
@@ -6062,7 +6069,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6062
6069
  "webp"
6063
6070
  ].includes(t) ? /* @__PURE__ */ X(qr, { className: "v1-file-type-icon v1-file-icon-image" }) : /* @__PURE__ */ X(Jr, { className: "v1-file-type-icon v1-file-icon-default" });
6064
6071
  }, h = (e) => {
6065
- P(d.filter((t, n) => n !== e));
6072
+ be(d.filter((t, n) => n !== e));
6066
6073
  }, g = (e, t) => {
6067
6074
  D({
6068
6075
  open: !0,
@@ -6084,7 +6091,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6084
6091
  return l !== void 0 && e.size / 1024 / 1024 > l ? (q.error(r?.message ?? `File must be smaller than ${l} MB`), or.LIST_IGNORE) : !1;
6085
6092
  }, C = ({ fileList: e }) => {
6086
6093
  let t = e.slice(0, u);
6087
- if (P(t), c && t.length > d.length) {
6094
+ if (be(t), c && t.length > d.length) {
6088
6095
  let e = t[t.length - 1];
6089
6096
  e?.originFileObj && c(e.originFileObj);
6090
6097
  }
@@ -6096,7 +6103,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6096
6103
  maxCount: u,
6097
6104
  beforeUpload: S,
6098
6105
  onChange: C,
6099
- disabled: fe
6106
+ disabled: de
6100
6107
  }, T = d.map((e, t) => /* @__PURE__ */ Z("div", {
6101
6108
  className: "v1-file-item",
6102
6109
  children: [
@@ -6153,7 +6160,7 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6153
6160
  display: "block"
6154
6161
  },
6155
6162
  children: /* @__PURE__ */ Z("div", {
6156
- className: `v1-upload-dropzone v1-upload-dropzone-center${fe ? " v1-upload-dropzone-disabled" : ""}`,
6163
+ className: `v1-upload-dropzone v1-upload-dropzone-center${de ? " v1-upload-dropzone-disabled" : ""}`,
6157
6164
  children: [
6158
6165
  /* @__PURE__ */ Z("div", {
6159
6166
  className: "v1-upload-dropzone-title-row",
@@ -6204,13 +6211,13 @@ function Tf({ field: e, form: t, name: n, moduleName: r, value: i, checked: a, o
6204
6211
  maxCount: 1,
6205
6212
  beforeUpload: S,
6206
6213
  onChange: C,
6207
- disabled: fe,
6214
+ disabled: de,
6208
6215
  style: {
6209
6216
  width: "100%",
6210
6217
  display: "block"
6211
6218
  },
6212
6219
  children: /* @__PURE__ */ Z("div", {
6213
- className: `v1-upload-dropzone v1-upload-dropzone-single${fe ? " v1-upload-dropzone-disabled" : ""}`,
6220
+ className: `v1-upload-dropzone v1-upload-dropzone-single${de ? " v1-upload-dropzone-disabled" : ""}`,
6214
6221
  children: [
6215
6222
  /* @__PURE__ */ X(Ar, { className: "v1-upload-cloud-icon" }),
6216
6223
  /* @__PURE__ */ X("span", {
@@ -6294,7 +6301,7 @@ function kf({ group: e }) {
6294
6301
  });
6295
6302
  }
6296
6303
  function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, loading: o = !1, error: s = "", breadcrumbItems: c = [], formType: l = "add", submitText: u, cancelPath: d = "/candidates", onSubmit: f, initialRecord: p = null, prefillFromUrl: m = !1, extraPayload: h = null, presetClientId: g = null, listViewProps: _ = {}, selectedScope: v = "", searchActionContext: y = null, embedded: b = !1, onSuccess: x = null, onCancel: S = null }) {
6297
- let C = l === "search", w = u ?? (C ? "Search" : "Create"), T = ia(), E = aa(), [D] = oa(), [O] = B.useForm(), ee = B.useWatch([], O), [A, te] = L(!1), [ne, j] = L({}), [M, re] = L([]), [ie, N] = L(!!e), [ae, se] = L(""), [ce, ue] = L(""), [de, pe] = L(!1), [me, he] = L({
6304
+ let C = l === "search", w = u ?? (C ? "Search" : "Create"), T = ia(), E = aa(), [D] = oa(), [O] = B.useForm(), ee = B.useWatch([], O), [A, te] = L(!1), [ne, j] = L({}), [M, re] = L([]), [N, P] = L(!!e), [ie, oe] = L(""), [se, le] = L(""), [ue, fe] = L(!1), [pe, me] = L({
6298
6305
  searched: !1,
6299
6306
  rows: [],
6300
6307
  total: 0,
@@ -6302,10 +6309,10 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6302
6309
  actions: [],
6303
6310
  actionRules: [],
6304
6311
  loading: !1
6305
- }), [ge, _e] = L({
6312
+ }), [he, ge] = L({
6306
6313
  current: 1,
6307
6314
  pageSize: 10
6308
- }), [ye, be] = L({}), [P, xe] = L("internal"), [Se, Ce] = L([]), [we, Te] = L({}), [Ee, Oe] = L([]), [ke, Ae] = L(n ?? ""), [Me, Ne] = L(i ?? ""), [Fe, Ie] = L(null), [Re, Be] = L(!1), [Ve, Ue] = L(null), [We, Ge] = L(() => /* @__PURE__ */ new Set()), Ke = e ? M : a ?? Nd, qe = e ? ie : o, Je = e ? ae : s, Ye = n || g || ke, Xe = i || Me;
6315
+ }), [ve, ye] = L({}), [be, xe] = L("internal"), [Se, Ce] = L([]), [we, Te] = L({}), [Ee, Oe] = L([]), [ke, Ae] = L(n ?? ""), [Me, Ne] = L(i ?? ""), [Fe, Ie] = L(null), [Re, Be] = L(!1), [Ve, Ue] = L(null), [We, Ge] = L(() => /* @__PURE__ */ new Set()), Ke = e ? M : a ?? Nd, qe = e ? N : o, Je = e ? ie : s, Ye = n || g || ke, Xe = i || Me;
6309
6316
  F(() => {
6310
6317
  let t = !1;
6311
6318
  return queueMicrotask(() => {
@@ -6314,7 +6321,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6314
6321
  Ue(null);
6315
6322
  return;
6316
6323
  }
6317
- le({ roleId: localStorage.getItem("roleId") }, e, {
6324
+ ce({ roleId: localStorage.getItem("roleId") }, e, {
6318
6325
  clientId: Ye,
6319
6326
  region: Xe
6320
6327
  }).then((e) => {
@@ -6372,13 +6379,13 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6372
6379
  if (ft) {
6373
6380
  O.resetFields();
6374
6381
  let e = O.getFieldsValue(!0);
6375
- O.setFieldsValue(Object.fromEntries(Object.keys(e).map((e) => [e, void 0]))), he({
6382
+ O.setFieldsValue(Object.fromEntries(Object.keys(e).map((e) => [e, void 0]))), me({
6376
6383
  searched: !1,
6377
6384
  rows: [],
6378
6385
  total: 0,
6379
6386
  fields: [],
6380
6387
  loading: !1
6381
- }), _e({
6388
+ }), ge({
6382
6389
  current: 1,
6383
6390
  pageSize: 10
6384
6391
  });
@@ -6392,18 +6399,18 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6392
6399
  let n = !1;
6393
6400
  async function r() {
6394
6401
  try {
6395
- N(!0), se("");
6402
+ P(!0), oe("");
6396
6403
  let r = C ? await Ot(e, "search", t) : await Pe({
6397
6404
  module: e,
6398
6405
  action: t,
6399
6406
  clientId: Ye,
6400
6407
  region: Xe
6401
6408
  });
6402
- n || (re(Xd(C ? r?.[0] : r)), C && ue(r?.[0]?.label || ""));
6409
+ n || (re(Xd(C ? r?.[0] : r)), C && le(r?.[0]?.label || ""));
6403
6410
  } catch (t) {
6404
- console.error(`Failed to fetch ${e} form groups:`, t), n || se(t?.message || "Failed to fetch form groups");
6411
+ console.error(`Failed to fetch ${e} form groups:`, t), n || oe(t?.message || "Failed to fetch form groups");
6405
6412
  } finally {
6406
- n || N(!1);
6413
+ n || P(!1);
6407
6414
  }
6408
6415
  }
6409
6416
  return r(), () => {
@@ -6500,7 +6507,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6500
6507
  if (i != null) if (n.type === "file") {
6501
6508
  let e = ef(i);
6502
6509
  e.length > 0 && (t[n.field] = e);
6503
- } else t[n.field] = ve(n, i);
6510
+ } else t[n.field] = _e(n, i);
6504
6511
  });
6505
6512
  }), Object.keys(t).length > 0 && O.setFieldsValue(t);
6506
6513
  }, [
@@ -6525,7 +6532,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6525
6532
  return (e.fields ?? []).forEach((e) => {
6526
6533
  if (!e.field || e.type === "file") return;
6527
6534
  let r = $d(t, e);
6528
- r != null && (n[e.field] = Id(e.addRow) ? bn(e, r) : ve(e, r));
6535
+ r != null && (n[e.field] = Id(e.addRow) ? bn(e, r) : _e(e, r));
6529
6536
  }), Object.keys(n).length > 0 ? n : {};
6530
6537
  });
6531
6538
  for (; r.length < n;) r.push({});
@@ -6534,7 +6541,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6534
6541
  let e = {};
6535
6542
  return Ze.forEach((t) => {
6536
6543
  t.addRow && (e[t.name] = Ct(t));
6537
- }), fe(Qe, e);
6544
+ }), de(Qe, e);
6538
6545
  }, [
6539
6546
  Ze,
6540
6547
  gt,
@@ -6546,17 +6553,17 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6546
6553
  O.resetFields(), j({}), xe("internal"), Ce([]);
6547
6554
  }, Dt = Tn(async (t, n, r = {}) => {
6548
6555
  if (!C) return;
6549
- let i = Number(r.pageSize) > 0 ? Number(r.pageSize) : ge.pageSize, a = Number(r.current), o = Number.isFinite(a) && a > 0 ? Math.floor(a) : 1;
6556
+ let i = Number(r.pageSize) > 0 ? Number(r.pageSize) : he.pageSize, a = Number(r.current), o = Number.isFinite(a) && a > 0 ? Math.floor(a) : 1;
6550
6557
  try {
6551
- be(t), _e({
6558
+ ye(t), ge({
6552
6559
  current: o,
6553
6560
  pageSize: i
6554
- }), he((e) => ({
6561
+ }), me((e) => ({
6555
6562
  ...e,
6556
6563
  loading: !0,
6557
6564
  searched: !0
6558
6565
  }));
6559
- let r = gd(t?.selectedSource), a = n ? _d(n, P) : r.includes("internal") ? "internal" : _d(t?.selectedSource, P), s = {
6566
+ let r = gd(t?.selectedSource), a = n ? _d(n, be) : r.includes("internal") ? "internal" : _d(t?.selectedSource, be), s = {
6560
6567
  ...t,
6561
6568
  selectedSource: a
6562
6569
  };
@@ -6565,7 +6572,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6565
6572
  limit: i,
6566
6573
  offset: (o - 1) * i
6567
6574
  }, { scope: a });
6568
- xe(a), he({
6575
+ xe(a), me({
6569
6576
  searched: !0,
6570
6577
  rows: c.rows,
6571
6578
  total: c.total,
@@ -6582,7 +6589,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6582
6589
  backendTabs: c.tabs
6583
6590
  }));
6584
6591
  } catch (e) {
6585
- console.error("Search failed:", e), q.error(e?.message || "Failed to search records"), he({
6592
+ console.error("Search failed:", e), q.error(e?.message || "Failed to search records"), me({
6586
6593
  searched: !0,
6587
6594
  rows: [],
6588
6595
  total: 0,
@@ -6595,8 +6602,8 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6595
6602
  }, [
6596
6603
  C,
6597
6604
  e,
6598
- P,
6599
- ge.pageSize
6605
+ be,
6606
+ he.pageSize
6600
6607
  ]), kt = Tn(async (e, t) => {
6601
6608
  let n = Od(e, t);
6602
6609
  Te((e) => ({
@@ -6633,55 +6640,55 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6633
6640
  }));
6634
6641
  }
6635
6642
  }, []), At = Tn((e) => {
6636
- let t = _d(e, P);
6637
- xe(t), _e({
6643
+ let t = _d(e, be);
6644
+ xe(t), ge({
6638
6645
  current: 1,
6639
- pageSize: ge.pageSize
6640
- }), Object.keys(ye).length > 0 && Dt(ye, t, {
6646
+ pageSize: he.pageSize
6647
+ }), Object.keys(ve).length > 0 && Dt(ve, t, {
6641
6648
  current: 1,
6642
- pageSize: ge.pageSize
6649
+ pageSize: he.pageSize
6643
6650
  });
6644
6651
  }, [
6645
- ge.pageSize,
6646
- ye,
6652
+ he.pageSize,
6653
+ ve,
6647
6654
  Dt,
6648
- P
6655
+ be
6649
6656
  ]), jt = Tn((e, t) => {
6650
- let n = Number(t) > 0 ? Number(t) : ge.pageSize, r = Number(e) > 0 ? Number(e) : 1;
6651
- if (Object.keys(ye).length === 0) {
6652
- _e({
6657
+ let n = Number(t) > 0 ? Number(t) : he.pageSize, r = Number(e) > 0 ? Number(e) : 1;
6658
+ if (Object.keys(ve).length === 0) {
6659
+ ge({
6653
6660
  current: r,
6654
6661
  pageSize: n
6655
6662
  });
6656
6663
  return;
6657
6664
  }
6658
- Dt(ye, P, {
6665
+ Dt(ve, be, {
6659
6666
  current: r,
6660
6667
  pageSize: n
6661
6668
  });
6662
6669
  }, [
6663
6670
  Dt,
6664
- ye,
6665
- ge.pageSize,
6666
- P
6671
+ ve,
6672
+ he.pageSize,
6673
+ be
6667
6674
  ]), Nt = Tn((e) => {
6668
- let t = Number(e) > 0 ? Number(e) : ge.pageSize;
6669
- if (Object.keys(ye).length === 0) {
6670
- _e({
6675
+ let t = Number(e) > 0 ? Number(e) : he.pageSize;
6676
+ if (Object.keys(ve).length === 0) {
6677
+ ge({
6671
6678
  current: 1,
6672
6679
  pageSize: t
6673
6680
  });
6674
6681
  return;
6675
6682
  }
6676
- Dt(ye, P, {
6683
+ Dt(ve, be, {
6677
6684
  current: 1,
6678
6685
  pageSize: t
6679
6686
  });
6680
6687
  }, [
6681
6688
  Dt,
6682
- ye,
6683
- ge.pageSize,
6684
- P
6689
+ ve,
6690
+ he.pageSize,
6691
+ be
6685
6692
  ]), Pt = async (t) => {
6686
6693
  if (C) {
6687
6694
  await Dt(t);
@@ -6696,7 +6703,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6696
6703
  return;
6697
6704
  }
6698
6705
  try {
6699
- pe(!0);
6706
+ fe(!0);
6700
6707
  let n = await hn(e, wf(t, Ze, xt ?? {}, e));
6701
6708
  if (n?.status === !1) {
6702
6709
  q.error(Vt(Ze, e, "add", n?.error || n?.message || n?.data));
@@ -6738,7 +6745,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
6738
6745
  } catch (t) {
6739
6746
  console.error(`Failed to create ${e}:`, t), q.error(Vt(Ze, e, "add", t?.data?.error || t?.data?.message || t?.message));
6740
6747
  } finally {
6741
- pe(!1), tt.current = null;
6748
+ fe(!1), tt.current = null;
6742
6749
  }
6743
6750
  }, Ft = (e, t) => (e.validations ?? e.validation ?? e.rules ?? []).filter((e) => {
6744
6751
  let t = typeof e == "string" ? e : e?.type;
@@ -7079,15 +7086,15 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7079
7086
  }, u));
7080
7087
  }), o;
7081
7088
  }, qt = I(() => {
7082
- if (me.fields?.length) return me.fields;
7083
- let e = me.rows[0];
7089
+ if (pe.fields?.length) return pe.fields;
7090
+ let e = pe.rows[0];
7084
7091
  return e ? Object.keys(e).filter((t) => !t.startsWith("_") && typeof e[t] != "object").map((e) => ({
7085
7092
  value: e,
7086
7093
  field: e,
7087
7094
  label: e.replace(/([A-Z])/g, " $1").replace(/^./, (e) => e.toUpperCase()),
7088
7095
  isVisible: !0
7089
7096
  })) : [];
7090
- }, [me.fields, me.rows]), Jt = (e) => !Array.isArray(e) || e.length === 0 ? "card" : e.some((e) => [
7097
+ }, [pe.fields, pe.rows]), Jt = (e) => !Array.isArray(e) || e.length === 0 ? "card" : e.some((e) => [
7091
7098
  e?.sourceType,
7092
7099
  e?.profileSource,
7093
7100
  e?.selectedSource,
@@ -7098,11 +7105,11 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7098
7105
  let t = String(e).trim().toLowerCase();
7099
7106
  return t ? !["all", "internal"].includes(t) : !1;
7100
7107
  })) ? "list" : "card";
7101
- I(() => Jt(me.rows), [me.rows]);
7108
+ I(() => Jt(pe.rows), [pe.rows]);
7102
7109
  let Yt = I(() => {
7103
7110
  let e = Ed({
7104
- rows: me.rows,
7105
- selectedSource: P
7111
+ rows: pe.rows,
7112
+ selectedSource: be
7106
7113
  });
7107
7114
  if (!e.length) return qt;
7108
7115
  let t = new Set(e.map((e) => e.field));
@@ -7115,7 +7122,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7115
7122
  tableHidden: !0,
7116
7123
  sorter: !1,
7117
7124
  render: (t, n) => {
7118
- if (!Dd(e, n, P)) return null;
7125
+ if (!Dd(e, n, be)) return null;
7119
7126
  let r = Od(e, n), i = we[r] ?? {}, a = !r || i.completed;
7120
7127
  return /* @__PURE__ */ X(R, {
7121
7128
  type: "primary",
@@ -7130,11 +7137,11 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7130
7137
  }, [
7131
7138
  kt,
7132
7139
  qt,
7133
- me.rows,
7134
- P,
7140
+ pe.rows,
7141
+ be,
7135
7142
  we
7136
7143
  ]), Xt = I(() => {
7137
- if (!y) return me.actions;
7144
+ if (!y) return pe.actions;
7138
7145
  let e = (t) => ({
7139
7146
  ...t,
7140
7147
  popupState: {
@@ -7143,9 +7150,9 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7143
7150
  },
7144
7151
  ...t.children ? { children: t.children.map(e) } : {}
7145
7152
  });
7146
- return (me.actions ?? []).map(e);
7147
- }, [me.actions, y]), Zt = (e, t) => {
7148
- let n = e.name ?? e.id ?? String(t), r = e.name ?? n, i = oe(Qe, r), a = !!i && i.leaderName !== r, o = i ? Ze.find((e) => e.name === i.leaderName) ?? e : e, s = Math.max(0, Number(o.minRows ?? 0) || 0), c = Math.max(0, Number(o.maxRows ?? 0) || 0), l = i ? i.memberNames : [r], u = () => {
7153
+ return (pe.actions ?? []).map(e);
7154
+ }, [pe.actions, y]), Zt = (e, t) => {
7155
+ let n = e.name ?? e.id ?? String(t), r = e.name ?? n, i = ae(Qe, r), a = !!i && i.leaderName !== r, o = i ? Ze.find((e) => e.name === i.leaderName) ?? e : e, s = Math.max(0, Number(o.minRows ?? 0) || 0), c = Math.max(0, Number(o.maxRows ?? 0) || 0), l = i ? i.memberNames : [r], u = () => {
7149
7156
  l.forEach((e) => $e.current[e]?.add());
7150
7157
  }, d = (e) => {
7151
7158
  l.forEach((t) => $e.current[t]?.remove(e));
@@ -7216,7 +7223,7 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7216
7223
  className: "v1-card v1-edit-card",
7217
7224
  title: /* @__PURE__ */ X(Ef, {
7218
7225
  icon: Pd[t % Pd.length],
7219
- title: C ? ce || e.label : e.label ?? e.name ?? "Details"
7226
+ title: C ? se || e.label : e.label ?? e.name ?? "Details"
7220
7227
  }),
7221
7228
  extra: /* @__PURE__ */ Z(U, {
7222
7229
  size: 8,
@@ -7336,8 +7343,8 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7336
7343
  /* @__PURE__ */ X(R, {
7337
7344
  type: "primary",
7338
7345
  htmlType: "submit",
7339
- disabled: de || !Ze.length || ct,
7340
- loading: de,
7346
+ disabled: ue || !Ze.length || ct,
7347
+ loading: ue,
7341
7348
  children: w
7342
7349
  })
7343
7350
  ]
@@ -7363,8 +7370,8 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7363
7370
  form: O,
7364
7371
  groups: Ze,
7365
7372
  action: e,
7366
- disabled: !St || de || !Ze.length,
7367
- loading: de,
7373
+ disabled: !St || ue || !Ze.length,
7374
+ loading: ue,
7368
7375
  onFire: () => {
7369
7376
  tt.current = e.afterSubmit ?? { mode: "stay" }, O.submit();
7370
7377
  }
@@ -7375,22 +7382,22 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7375
7382
  onClick: () => {
7376
7383
  tt.current = null, O.submit();
7377
7384
  },
7378
- disabled: !St || de || !Ze.length,
7379
- loading: de,
7385
+ disabled: !St || ue || !Ze.length,
7386
+ loading: ue,
7380
7387
  children: w
7381
7388
  })
7382
7389
  ]
7383
7390
  })]
7384
7391
  }),
7385
- C && me.searched && /* @__PURE__ */ X(fd, {
7392
+ C && pe.searched && /* @__PURE__ */ X(fd, {
7386
7393
  moduleName: e,
7387
7394
  breadcrumbItems: [],
7388
- dataSource: me.rows,
7395
+ dataSource: pe.rows,
7389
7396
  fields: Yt,
7390
- total: me.total,
7391
- loading: me.loading,
7392
- current: ge.current,
7393
- pageSize: ge.pageSize,
7397
+ total: pe.total,
7398
+ loading: pe.loading,
7399
+ current: he.current,
7400
+ pageSize: he.pageSize,
7394
7401
  showViewToggle: !0,
7395
7402
  activeView: at,
7396
7403
  onViewChange: st,
@@ -7398,10 +7405,10 @@ function Af({ moduleName: e, action: t, clientId: n, region: i, formGroups: a, l
7398
7405
  onPageSizeChange: Nt,
7399
7406
  showSearch: !1,
7400
7407
  tabs: Se,
7401
- selectedSource: P,
7408
+ selectedSource: be,
7402
7409
  onTabChange: At,
7403
7410
  actions: Xt,
7404
- actionRules: me.actionRules
7411
+ actionRules: pe.actionRules
7405
7412
  })
7406
7413
  ]
7407
7414
  })] });
@@ -8280,7 +8287,7 @@ function Ip(e, t) {
8280
8287
  return Number.isNaN(n) ? String(e) : `${t.currencySymbol ?? ""}${n.toLocaleString(void 0, { maximumFractionDigits: 2 })}`;
8281
8288
  }
8282
8289
  function Lp({ field: e }) {
8283
- let { value: t, type: n, prefix: r = "", suffix: i = "", color: a = "", capitalize: o } = e ?? {}, s = e?.renderOptions ?? {}, c = be(), l = c.emptyPlaceholder, u = c.separator || ", ", d = a ? { color: a } : void 0, f = s.tagColor || a || void 0, p = s.textTransform && s.textTransform !== "none" ? s.textTransform : null, m = (e) => `${r ? `${r} ` : ""}${e}${i ? ` ${i}` : ""}`, h = (e) => p ? kp(e, p) : e, g = (e) => /* @__PURE__ */ X(Sp, {
8290
+ let { value: t, type: n, prefix: r = "", suffix: i = "", color: a = "", capitalize: o } = e ?? {}, s = e?.renderOptions ?? {}, c = ye(), l = c.emptyPlaceholder, u = c.separator || ", ", d = a ? { color: a } : void 0, f = s.tagColor || a || void 0, p = s.textTransform && s.textTransform !== "none" ? s.textTransform : null, m = (e) => `${r ? `${r} ` : ""}${e}${i ? ` ${i}` : ""}`, h = (e) => p ? kp(e, p) : e, g = (e) => /* @__PURE__ */ X(Sp, {
8284
8291
  strong: !0,
8285
8292
  className: "v1-detail-value",
8286
8293
  style: d,
@@ -8525,7 +8532,7 @@ function Kp({ moduleName: e, id: t, refreshKey: n = 0, onDescriptionSaved: r })
8525
8532
  value: t
8526
8533
  } : {
8527
8534
  ...e,
8528
- value: ue(t, e.field)
8535
+ value: le(t, e.field)
8529
8536
  }, C = (e, t, n) => {
8530
8537
  let r = e.name ?? e.id ?? String(t), i = Array.isArray(e.rows) ? e.rows : [];
8531
8538
  return /* @__PURE__ */ X(Mn, {
@@ -9411,72 +9418,72 @@ function Vm({ moduleName: e, id: t, customConfigName: n, onAction: r, onTabChang
9411
9418
  F(() => {
9412
9419
  w && a && a(w);
9413
9420
  }, [w]);
9414
- let { eyebrow: T, title: E = "-", status: D, titleIds: O = [], meta: k = [], ids: ee = [], tabs: A = [], stats: te = [], timestamp: ne = null } = w ?? {}, { canAdd: j, canEdit: M, canDelete: re } = rc(e), ie = I(() => jm(f, t), [f, t]), N = sp(A, {
9421
+ let { eyebrow: T, title: E = "-", status: D, titleIds: O = [], meta: k = [], ids: ee = [], tabs: A = [], stats: te = [], timestamp: ne = null } = w ?? {}, { canAdd: j, canEdit: M, canDelete: re } = rc(e), N = I(() => jm(f, t), [f, t]), P = sp(A, {
9415
9422
  id: t,
9416
9423
  moduleName: e,
9417
- record: ie
9418
- }), ae = Dm(C)?.resolveScope, [oe, se] = L(void 0);
9424
+ record: N
9425
+ }), ie = Dm(C)?.resolveScope, [ae, oe] = L(void 0);
9419
9426
  F(() => {
9420
- if (typeof ae != "function" || !t) return;
9427
+ if (typeof ie != "function" || !t) return;
9421
9428
  let n = !1, r = Number(localStorage.getItem("userId")) || 0;
9422
- return Promise.resolve().then(() => ae({
9429
+ return Promise.resolve().then(() => ie({
9423
9430
  id: t,
9424
9431
  moduleName: e,
9425
- record: ie,
9432
+ record: N,
9426
9433
  currentUserId: r
9427
9434
  })).then((e) => {
9428
- n || se(e ?? null);
9435
+ n || oe(e ?? null);
9429
9436
  }).catch(() => {
9430
- n || se(null);
9437
+ n || oe(null);
9431
9438
  }), () => {
9432
9439
  n = !0;
9433
9440
  };
9434
9441
  }, [
9435
- ae,
9442
+ ie,
9436
9443
  t,
9437
9444
  e,
9438
9445
  f
9439
9446
  ]);
9440
- let ce = typeof ae != "function" || oe !== void 0, le = I(() => ce ? m.filter((e) => e.showInDetail ?? e.showInList).map(zm).filter((e) => !Im(e, ie, g, oe ?? void 0)) : [], [
9447
+ let se = typeof ie != "function" || ae !== void 0, ce = I(() => se ? m.filter((e) => e.showInDetail ?? e.showInList).map(zm).filter((e) => !Im(e, N, g, ae ?? void 0)) : [], [
9441
9448
  g,
9442
9449
  m,
9443
- ie,
9444
- oe,
9445
- ce
9450
+ N,
9451
+ ae,
9452
+ se
9446
9453
  ]);
9447
- function ue(e) {
9454
+ function le(e) {
9448
9455
  let t = ac(e);
9449
9456
  if (t === "add" && !j || t === "edit" && !M || t === "delete" && !re || !lt(e.permission, C)) return !1;
9450
9457
  if (e.permissionKey) {
9451
- let t = Pm(ie, `actionPermission.${e.permissionKey}`);
9458
+ let t = Pm(N, `actionPermission.${e.permissionKey}`);
9452
9459
  if (t === !1 || t === 0 || t === "0") return !1;
9453
9460
  }
9454
9461
  return !0;
9455
9462
  }
9456
- let [de, fe] = L({
9463
+ let [ue, de] = L({
9457
9464
  sourceDefaultTab: s,
9458
9465
  selectedTab: s
9459
- }), pe = de.sourceDefaultTab === s ? de.selectedTab : s, me = N.some((e) => e.key === pe) ? pe : N[0]?.key, he = (e) => !e.allowedTabs?.length || e.allowedTabs.some((e) => Fm(e) === Fm(me)), ge = le.filter((e) => e.detailPlacement === "primary" && ue(e) && he(e)), _e = le.filter((e) => e.detailPlacement !== "primary" && ue(e) && he(e));
9466
+ }), fe = ue.sourceDefaultTab === s ? ue.selectedTab : s, pe = P.some((e) => e.key === fe) ? fe : P[0]?.key, me = (e) => !e.allowedTabs?.length || e.allowedTabs.some((e) => Fm(e) === Fm(pe)), he = ce.filter((e) => e.detailPlacement === "primary" && le(e) && me(e)), ge = ce.filter((e) => e.detailPlacement !== "primary" && le(e) && me(e));
9460
9467
  if (!w) return null;
9461
- let ve = (n) => {
9462
- let i = [...ge, ..._e].find((e) => e.key === n);
9468
+ let _e = (n) => {
9469
+ let i = [...he, ...ge].find((e) => e.key === n);
9463
9470
  if (i?.actionType === "document" && i.documentField) {
9464
9471
  let e = Bm(f, i.documentField);
9465
9472
  e.length ? (S(e), y(!0)) : q.warning(`No ${(i.label || "document").toLowerCase()} available`);
9466
9473
  return;
9467
9474
  }
9468
9475
  if (i?.actionType === "copy") {
9469
- let e = Pm(ie, i.copyField || "id");
9476
+ let e = Pm(N, i.copyField || "id");
9470
9477
  navigator.clipboard.writeText(Mm(e)).then(() => q.success("Copied to clipboard")).catch(() => q.error("Could not copy to clipboard"));
9471
9478
  return;
9472
9479
  }
9473
9480
  if (i?.actionType === "api" && i.apiPath) {
9474
- let e = Nm(i.apiPath, ie), n = String(i.apiMethod || "POST").toUpperCase();
9481
+ let e = Nm(i.apiPath, N), n = String(i.apiMethod || "POST").toUpperCase();
9475
9482
  u(b, e.startsWith("/") ? e : `/${e}`, {
9476
9483
  method: n,
9477
9484
  body: ["GET", "DELETE"].includes(n) ? void 0 : JSON.stringify({
9478
9485
  ids: [t],
9479
- record: ie
9486
+ record: N
9480
9487
  })
9481
9488
  }).then(() => q.success(`${i.label} completed`)).catch((e) => q.error(e.message || `${i.label} failed`));
9482
9489
  return;
@@ -9491,7 +9498,7 @@ function Vm({ moduleName: e, id: t, customConfigName: n, onAction: r, onTabChang
9491
9498
  background: d,
9492
9499
  moduleName: e,
9493
9500
  selectedIds: [t],
9494
- selectedRecords: [ie],
9501
+ selectedRecords: [N],
9495
9502
  popupContext: i.popupState ?? {},
9496
9503
  popupAction: {
9497
9504
  key: i.key,
@@ -9508,23 +9515,23 @@ function Vm({ moduleName: e, id: t, customConfigName: n, onAction: r, onTabChang
9508
9515
  id: t,
9509
9516
  action: i
9510
9517
  });
9511
- }, ye = (n) => {
9512
- fe({
9518
+ }, ve = (n) => {
9519
+ de({
9513
9520
  sourceDefaultTab: s,
9514
9521
  selectedTab: n
9515
9522
  }), i?.(n, {
9516
9523
  moduleName: e,
9517
9524
  id: t
9518
9525
  });
9519
- }, be = _e.map((e) => {
9520
- let t = Lm(e, ie, oe ?? void 0), n = !t && Rm(e, ie, g, oe ?? void 0);
9526
+ }, ye = ge.map((e) => {
9527
+ let t = Lm(e, N, ae ?? void 0), n = !t && Rm(e, N, g, ae ?? void 0);
9521
9528
  return {
9522
9529
  key: e.key,
9523
9530
  label: t ? t.label : e.label,
9524
9531
  danger: e.danger,
9525
9532
  disabled: !!t || !!n,
9526
9533
  title: n || void 0,
9527
- onClick: t || n ? void 0 : () => ve(e.key)
9534
+ onClick: t || n ? void 0 : () => _e(e.key)
9528
9535
  };
9529
9536
  });
9530
9537
  return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ Z(Mn, {
@@ -9598,23 +9605,23 @@ function Vm({ moduleName: e, id: t, customConfigName: n, onAction: r, onTabChang
9598
9605
  children: [
9599
9606
  /* @__PURE__ */ Z("div", {
9600
9607
  className: "znx-dh-actions",
9601
- children: [ge.map((e) => {
9602
- let t = Lm(e, ie, oe ?? void 0), n = !t && Rm(e, ie, g, oe ?? void 0), r = /* @__PURE__ */ X(R, {
9608
+ children: [he.map((e) => {
9609
+ let t = Lm(e, N, ae ?? void 0), n = !t && Rm(e, N, g, ae ?? void 0), r = /* @__PURE__ */ X(R, {
9603
9610
  type: "text",
9604
9611
  disabled: !!t || !!n,
9605
9612
  className: `znx-dh-btn znx-dh-btn--${t ? t.tone : e.tone ?? "primary"}${t ? " znx-dh-btn--done" : ""}`,
9606
9613
  icon: t ? /* @__PURE__ */ X(Sr, {}) : e.icon ? km[e.icon] : void 0,
9607
- onClick: t || n ? void 0 : () => ve(e.key),
9614
+ onClick: t || n ? void 0 : () => _e(e.key),
9608
9615
  children: t ? t.label : e.label
9609
9616
  }, e.key);
9610
9617
  return n ? /* @__PURE__ */ X(K, {
9611
9618
  title: n,
9612
9619
  children: /* @__PURE__ */ X("span", { children: r })
9613
9620
  }, e.key) : r;
9614
- }), _e.length > 0 && /* @__PURE__ */ X(Rn, {
9621
+ }), ge.length > 0 && /* @__PURE__ */ X(Rn, {
9615
9622
  trigger: ["click"],
9616
9623
  placement: "bottomRight",
9617
- menu: { items: be },
9624
+ menu: { items: ye },
9618
9625
  children: /* @__PURE__ */ X(R, {
9619
9626
  type: "text",
9620
9627
  className: "znx-dh-more",
@@ -9641,12 +9648,12 @@ function Vm({ moduleName: e, id: t, customConfigName: n, onAction: r, onTabChang
9641
9648
  })
9642
9649
  ]
9643
9650
  })]
9644
- }), N.length > 0 && /* @__PURE__ */ X("div", {
9651
+ }), P.length > 0 && /* @__PURE__ */ X("div", {
9645
9652
  className: "znx-dh-tabs",
9646
- children: N.map((e) => /* @__PURE__ */ X("button", {
9653
+ children: P.map((e) => /* @__PURE__ */ X("button", {
9647
9654
  type: "button",
9648
- className: `znx-dh-tab${me === e.key ? " is-active" : ""}`,
9649
- onClick: () => ye(e.key),
9655
+ className: `znx-dh-tab${pe === e.key ? " is-active" : ""}`,
9656
+ onClick: () => ve(e.key),
9650
9657
  children: e.label
9651
9658
  }, e.key))
9652
9659
  })]
@@ -10037,7 +10044,7 @@ function yh(e = [], t, n, r) {
10037
10044
  ...e,
10038
10045
  show: 1,
10039
10046
  req: 1
10040
- } : e).filter((r) => String(r.field ?? "").trim() !== "" && (r.show === void 0 || sh(r.show)) && (!r.visiblePermission || lt(r.visiblePermission, t)) && qt(n, e.name, r.field)).map((t) => me(n, e.name, t.field) ? t : {
10047
+ } : e).filter((r) => String(r.field ?? "").trim() !== "" && (r.show === void 0 || sh(r.show)) && (!r.visiblePermission || lt(r.visiblePermission, t)) && qt(n, e.name, r.field)).map((t) => pe(n, e.name, t.field) ? t : {
10041
10048
  ...t,
10042
10049
  disabled: !0
10043
10050
  }).sort((e, t) => Number(e.order ?? 0) - Number(t.order ?? 0))
@@ -10248,7 +10255,7 @@ function Mh(e, t, n, r = !1) {
10248
10255
  }), [
10249
10256
  ...c,
10250
10257
  ...a.map((r) => kh(r, e, t, n)),
10251
- ge(e)
10258
+ he(e)
10252
10259
  ];
10253
10260
  }
10254
10261
  function Nh(e, t) {
@@ -10325,7 +10332,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10325
10332
  open: !1,
10326
10333
  docs: [],
10327
10334
  index: 0
10328
- }), [D, O] = L(null), [k, ee] = L(0), A = En([]), ne = Array.isArray(n) && n.length >= 3 && typeof n[1] == "number", j = e.lookupFilterValueFrom ? dn(e.lookupFilterValueFrom) : [`__lookup_filter_${e.field}`], M = e.lookupFilterValueFrom && ne ? [...n.slice(0, 2), ...dn(e.lookupFilterValueFrom)] : ["__noop_row_filter__"], re = B.useWatch(j, t), ie = B.useWatch(M, t), N = lh(ie) ? re : ie, ae = e.lookupFilterValueFrom ? c[e.lookupFilterValueFrom] : void 0, oe = lh(ae) ? N : ae, se = e.disabledByField ? Array.isArray(n) && n.length > 1 ? [...n.slice(0, -1), e.disabledByField] : [e.disabledByField] : ["__noop_disabled_watch__"], le = B.useWatch(se, t), ue = e.disabledIf?.field ? dn(e.disabledIf.field) : ["__noop_disabled_if__"], de = e.disabledIf?.field && ne ? [...n.slice(0, 2), ...dn(e.disabledIf.field)] : ["__noop_disabled_if_row__"], fe = B.useWatch(ue, t), pe = B.useWatch(de, t), me = e.disabledIf?.field ? Yt(e.disabledIf, lh(pe) ? fe : pe) : !1, he = p || !!e.disabled || me || (e.disabledByField ? sh(le) : !1) || !!d;
10335
+ }), [D, O] = L(null), [k, ee] = L(0), A = En([]), ne = Array.isArray(n) && n.length >= 3 && typeof n[1] == "number", j = e.lookupFilterValueFrom ? dn(e.lookupFilterValueFrom) : [`__lookup_filter_${e.field}`], M = e.lookupFilterValueFrom && ne ? [...n.slice(0, 2), ...dn(e.lookupFilterValueFrom)] : ["__noop_row_filter__"], re = B.useWatch(j, t), N = B.useWatch(M, t), P = lh(N) ? re : N, ie = e.lookupFilterValueFrom ? c[e.lookupFilterValueFrom] : void 0, ae = lh(ie) ? P : ie, oe = e.disabledByField ? Array.isArray(n) && n.length > 1 ? [...n.slice(0, -1), e.disabledByField] : [e.disabledByField] : ["__noop_disabled_watch__"], ce = B.useWatch(oe, t), le = e.disabledIf?.field ? dn(e.disabledIf.field) : ["__noop_disabled_if__"], ue = e.disabledIf?.field && ne ? [...n.slice(0, 2), ...dn(e.disabledIf.field)] : ["__noop_disabled_if_row__"], de = B.useWatch(le, t), fe = B.useWatch(ue, t), pe = e.disabledIf?.field ? Yt(e.disabledIf, lh(fe) ? de : fe) : !1, me = p || !!e.disabled || pe || (e.disabledByField ? sh(ce) : !1) || !!d;
10329
10336
  F(() => {
10330
10337
  if (f === "location") {
10331
10338
  let t = !1;
@@ -10354,7 +10361,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10354
10361
  "radio",
10355
10362
  "checkbox"
10356
10363
  ].includes(f) || !t || t === "static") return;
10357
- if (t === "lookup" && e.lookupFilterField && lh(oe)) {
10364
+ if (t === "lookup" && e.lookupFilterField && lh(ae)) {
10358
10365
  h([]), _(!1);
10359
10366
  return;
10360
10367
  }
@@ -10374,7 +10381,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10374
10381
  displayField: e.displayField ?? "",
10375
10382
  valueField: e.valueField ?? "_id"
10376
10383
  });
10377
- e.displayField2 && t.set("displayField2", e.displayField2), x && t.set("search", x), e.lookupFilterField && !lh(oe) && (t.set("filterField", e.lookupFilterField), t.set("filterValue", String(oe))), e.extraFields?.length && t.set("extraFields", e.extraFields.join(","));
10384
+ e.displayField2 && t.set("displayField2", e.displayField2), x && t.set("search", x), e.lookupFilterField && !lh(ae) && (t.set("filterField", e.lookupFilterField), t.set("filterValue", String(ae))), e.extraFields?.length && t.set("extraFields", e.extraFields.join(","));
10378
10385
  let n = await u(b, `/admin/lookup-dropdown-values?${t}`);
10379
10386
  r = n?.data ?? n ?? [], e.optionsRequireExtraField && (r = r.filter((t) => t?.extraData?.[e.optionsRequireExtraField] === !0));
10380
10387
  } else if (t === "group") {
@@ -10406,7 +10413,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10406
10413
  e.displayField2,
10407
10414
  e.valueField,
10408
10415
  e.lookupFilterField,
10409
- oe,
10416
+ ae,
10410
10417
  e.groupName,
10411
10418
  e.masterName,
10412
10419
  e.limit,
@@ -10418,7 +10425,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10418
10425
  e.optionsRequireExtraField,
10419
10426
  k
10420
10427
  ]);
10421
- let ge = fh([e.options, e.values].find((e) => Array.isArray(e) && e.length > 0) ?? Xm(e)), _e = m ?? ge, ve = (e.multiSelect ? "multiple" : e.mode ?? (sh(e.multiple) ? "multiple" : void 0)) ?? (Ve(e) === "array" ? "multiple" : void 0), ye = ["select", "location"].includes(f), be = e.hidePlaceholder ? void 0 : e.placeholder ?? `${ye ? "Select" : "Enter"} ${String(e.label ?? "").toLowerCase()}`, P = Ph(e), xe = () => {
10428
+ let he = fh([e.options, e.values].find((e) => Array.isArray(e) && e.length > 0) ?? Xm(e)), ge = m ?? he, _e = (e.multiSelect ? "multiple" : e.mode ?? (sh(e.multiple) ? "multiple" : void 0)) ?? (Ve(e) === "array" ? "multiple" : void 0), ve = ["select", "location"].includes(f), ye = e.hidePlaceholder ? void 0 : e.placeholder ?? `${ve ? "Select" : "Enter"} ${String(e.label ?? "").toLowerCase()}`, be = Ph(e), xe = () => {
10422
10429
  setTimeout(() => {
10423
10430
  t.validateFields([n]).catch(() => {});
10424
10431
  });
@@ -10434,16 +10441,16 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10434
10441
  onDone: (t, n) => {
10435
10442
  ee((e) => e + 1);
10436
10443
  let r = Ve(e) !== "array" && !e.multiSelect && !e.multiple;
10437
- t === "create" && n != null && r && Se(ce(e) ? { value: n } : n);
10444
+ t === "create" && n != null && r && Se(se(e) ? { value: n } : n);
10438
10445
  }
10439
10446
  }), Ee = e.validator?.type ? {
10440
10447
  ...e.validator,
10441
10448
  title: e.validator.title || e.label || "Field"
10442
10449
  } : null, De = {
10443
- ...P,
10450
+ ...be,
10444
10451
  value: r,
10445
- disabled: he,
10446
- placeholder: be,
10452
+ disabled: me,
10453
+ placeholder: ye,
10447
10454
  prefix: e.icon ? null : oh[e.field],
10448
10455
  onChange: (t) => {
10449
10456
  let n = e.formatter ? Lh(t.target.value, e.formatter) : t.target.value;
@@ -10468,15 +10475,15 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10468
10475
  O(t), setTimeout(() => O((e) => e === t ? null : e), 1800);
10469
10476
  }
10470
10477
  },
10471
- maxLength: Ee.maxLength ?? P.maxLength
10478
+ maxLength: Ee.maxLength ?? be.maxLength
10472
10479
  }
10473
10480
  };
10474
10481
  if (f === "tagify") return /* @__PURE__ */ X(H, {
10475
10482
  value: r,
10476
10483
  allowClear: !0,
10477
- disabled: he,
10484
+ disabled: me,
10478
10485
  mode: "tags",
10479
- placeholder: be,
10486
+ placeholder: ye,
10480
10487
  onChange: Se
10481
10488
  });
10482
10489
  if (f === "location") return /* @__PURE__ */ X(H, {
@@ -10484,29 +10491,29 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10484
10491
  allowClear: !0,
10485
10492
  showSearch: !0,
10486
10493
  filterOption: !1,
10487
- disabled: he,
10494
+ disabled: me,
10488
10495
  loading: g,
10489
- options: _e,
10490
- placeholder: be,
10496
+ options: ge,
10497
+ placeholder: ye,
10491
10498
  notFoundContent: g ? /* @__PURE__ */ X($n, { size: "small" }) : void 0,
10492
10499
  onSearch: y,
10493
10500
  onFocus: () => y((e) => e),
10494
10501
  onChange: Se
10495
10502
  });
10496
10503
  if (f === "select") {
10497
- let i = e.dataSource === "lookup", a = e.dataSource === "master", o = i || a, s = e.dataSource === "group", c = ce(e);
10504
+ let i = e.dataSource === "lookup", a = e.dataSource === "master", o = i || a, s = e.dataSource === "group", c = se(e);
10498
10505
  return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(H, {
10499
- value: Ue(e, r, _e),
10506
+ value: Ue(e, r, ge),
10500
10507
  allowClear: !0,
10501
- disabled: he,
10508
+ disabled: me,
10502
10509
  loading: g,
10503
10510
  labelInValue: c || void 0,
10504
10511
  showSearch: o || s || void 0,
10505
10512
  optionFilterProp: "label",
10506
10513
  filterOption: o ? !1 : void 0,
10507
- mode: ve,
10508
- options: _e,
10509
- placeholder: be,
10514
+ mode: _e,
10515
+ options: ge,
10516
+ placeholder: ye,
10510
10517
  notFoundContent: g ? /* @__PURE__ */ X($n, { size: "small" }) : void 0,
10511
10518
  onSearch: i ? S : a ? w : void 0,
10512
10519
  onChange: (r) => {
@@ -10530,18 +10537,18 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10530
10537
  }
10531
10538
  if (f === "radio") return /* @__PURE__ */ X(Xn.Group, {
10532
10539
  value: r,
10533
- disabled: he,
10534
- options: _e,
10540
+ disabled: me,
10541
+ options: ge,
10535
10542
  onChange: (e) => Se(e.target.value)
10536
10543
  });
10537
- if (f === "checkbox") return _e.length > 0 ? /* @__PURE__ */ X(Nn.Group, {
10544
+ if (f === "checkbox") return ge.length > 0 ? /* @__PURE__ */ X(Nn.Group, {
10538
10545
  value: r,
10539
- disabled: he,
10540
- options: _e,
10546
+ disabled: me,
10547
+ options: ge,
10541
10548
  onChange: Se
10542
10549
  }) : /* @__PURE__ */ X(Nn, {
10543
10550
  checked: i,
10544
- disabled: he,
10551
+ disabled: me,
10545
10552
  onChange: (r) => {
10546
10553
  let i = r.target.checked;
10547
10554
  if (Se(i), e.linkedClearField && i) {
@@ -10553,8 +10560,8 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10553
10560
  });
10554
10561
  if (f === "text-editor") return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(At, {
10555
10562
  value: r ?? s ?? "",
10556
- disabled: he,
10557
- placeholder: be,
10563
+ disabled: me,
10564
+ placeholder: ye,
10558
10565
  onChange: (e) => {
10559
10566
  if (Ee) {
10560
10567
  let { error: t } = _t(e, Ee, "change");
@@ -10576,8 +10583,8 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10576
10583
  })] });
10577
10584
  if (f === "date") return /* @__PURE__ */ X(Fn, {
10578
10585
  value: r,
10579
- disabled: he,
10580
- placeholder: be,
10586
+ disabled: me,
10587
+ placeholder: ye,
10581
10588
  style: { width: "100%" },
10582
10589
  suffixIcon: /* @__PURE__ */ X(vr, {}),
10583
10590
  disabledDate: Fh(e, t, n),
@@ -10586,8 +10593,8 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10586
10593
  });
10587
10594
  if (f === "time") return /* @__PURE__ */ X(ir, {
10588
10595
  value: r,
10589
- disabled: he,
10590
- placeholder: be,
10596
+ disabled: me,
10597
+ placeholder: ye,
10591
10598
  style: { width: "100%" },
10592
10599
  onChange: (e) => Se(e)
10593
10600
  });
@@ -10641,7 +10648,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10641
10648
  maxCount: u,
10642
10649
  beforeUpload: S,
10643
10650
  onChange: C,
10644
- disabled: he
10651
+ disabled: me
10645
10652
  }, D = d.map((e, t) => /* @__PURE__ */ Z("div", {
10646
10653
  className: "v1-file-item",
10647
10654
  children: [
@@ -10698,7 +10705,7 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10698
10705
  display: "block"
10699
10706
  },
10700
10707
  children: /* @__PURE__ */ Z("div", {
10701
- className: `v1-upload-dropzone v1-upload-dropzone-center${he ? " v1-upload-dropzone-disabled" : ""}`,
10708
+ className: `v1-upload-dropzone v1-upload-dropzone-center${me ? " v1-upload-dropzone-disabled" : ""}`,
10702
10709
  children: [
10703
10710
  /* @__PURE__ */ Z("div", {
10704
10711
  className: "v1-upload-dropzone-title-row",
@@ -10749,13 +10756,13 @@ function Rh({ field: e, form: t, name: n, value: r, checked: i, fileList: a, mod
10749
10756
  maxCount: 1,
10750
10757
  beforeUpload: S,
10751
10758
  onChange: C,
10752
- disabled: he,
10759
+ disabled: me,
10753
10760
  style: {
10754
10761
  width: "100%",
10755
10762
  display: "block"
10756
10763
  },
10757
10764
  children: /* @__PURE__ */ Z("div", {
10758
- className: `v1-upload-dropzone v1-upload-dropzone-single${he ? " v1-upload-dropzone-disabled" : ""}`,
10765
+ className: `v1-upload-dropzone v1-upload-dropzone-single${me ? " v1-upload-dropzone-disabled" : ""}`,
10759
10766
  children: [
10760
10767
  /* @__PURE__ */ X(Ar, { className: "v1-upload-cloud-icon" }),
10761
10768
  /* @__PURE__ */ X("span", {
@@ -10805,7 +10812,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10805
10812
  ee(null);
10806
10813
  return;
10807
10814
  }
10808
- le({ roleId: localStorage.getItem("roleId") }, e, {
10815
+ ce({ roleId: localStorage.getItem("roleId") }, e, {
10809
10816
  clientId: n,
10810
10817
  region: r
10811
10818
  }).then((e) => {
@@ -10844,16 +10851,16 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10844
10851
  e,
10845
10852
  O,
10846
10853
  te
10847
- ]), M = I(() => De(j), [j]), re = En({}), ie = mn({
10854
+ ]), M = I(() => De(j), [j]), re = En({}), N = mn({
10848
10855
  form: h,
10849
10856
  groups: j,
10850
10857
  module: e
10851
- }), N = I(() => {
10858
+ }), P = I(() => {
10852
10859
  let e = {};
10853
10860
  return j.forEach((t) => {
10854
10861
  t.addRow && (e[t.name] = A(t));
10855
- }), fe(M, e);
10856
- }, [j, M]), ae = {
10862
+ }), de(M, e);
10863
+ }, [j, M]), ie = {
10857
10864
  jobs: {
10858
10865
  list: "Jobs",
10859
10866
  path: "/jobs",
@@ -10869,8 +10876,8 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10869
10876
  path: "/submissions",
10870
10877
  edit: "Edit Submission"
10871
10878
  }
10872
- }, se = f ? [] : i.length > 0 ? i : (() => {
10873
- let t = ae[dh(e)];
10879
+ }, oe = f ? [] : i.length > 0 ? i : (() => {
10880
+ let t = ie[dh(e)];
10874
10881
  return t ? [
10875
10882
  {
10876
10883
  label: "Home",
@@ -10918,19 +10925,19 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10918
10925
  j,
10919
10926
  h
10920
10927
  ]);
10921
- let ce = (e) => {
10928
+ let se = (e) => {
10922
10929
  _((t) => ({
10923
10930
  ...t,
10924
10931
  [e]: !t[e]
10925
10932
  }));
10926
10933
  };
10927
- function ue(t) {
10934
+ function le(t) {
10928
10935
  let n = je(t, j, { module: e });
10929
10936
  return Object.entries(c).forEach(([e, t]) => {
10930
10937
  n[e] !== void 0 && (n[t] = n[e], delete n[e]);
10931
10938
  }), n;
10932
10939
  }
10933
- async function de(n) {
10940
+ async function ue(n) {
10934
10941
  if (!(u && await Promise.resolve().then(() => u(n)).catch(() => !1) === !1)) try {
10935
10942
  T(!0), D("");
10936
10943
  let r = k(n, j, {
@@ -10951,7 +10958,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10951
10958
  }
10952
10959
  }
10953
10960
  await Bt(e, t, {
10954
- ...ue(n),
10961
+ ...le(n),
10955
10962
  ...d ?? {}
10956
10963
  }, l?.useLegacyUpload ? [] : r);
10957
10964
  let i = Qt(j, e, "edit");
@@ -10968,9 +10975,9 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10968
10975
  T(!1);
10969
10976
  }
10970
10977
  }
10971
- let pe = (e) => {
10978
+ let fe = (e) => {
10972
10979
  _({}), et(e, h);
10973
- }, [me, he] = L({}), ge = (e) => String(e?.field ?? ""), _e = (e, t, n) => {
10980
+ }, [pe, me] = L({}), he = (e) => String(e?.field ?? ""), ge = (e, t, n) => {
10974
10981
  if (!e?.field) return !0;
10975
10982
  let r = t(n == null ? [e.field] : [...Array.isArray(n) ? n : [n], e.field]);
10976
10983
  switch (e.operator) {
@@ -10983,7 +10990,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
10983
10990
  case "notIn": return !String(e.value ?? "").split(",").map((e) => e.trim()).includes(String(r ?? ""));
10984
10991
  default: return !0;
10985
10992
  }
10986
- }, ve = (t, r, i, a = {}) => {
10993
+ }, _e = (t, r, i, a = {}) => {
10987
10994
  let o = typeof t.field == "string" && t.field.includes(".") ? t.field.split(".") : null, s = o ?? t.field, c = r === void 0 ? s : [r, ...o ?? [t.field]], l = i !== void 0 && r !== void 0 ? [...Array.isArray(i) ? i : [i], ...Array.isArray(c) ? c : [c]] : c, u = t.type === "checkbox" && (t.options && t.options.length > 0 || t.dataSource && t.dataSource !== "static"), d = !u && t.type === "checkbox" ? "checked" : "value", f = !!t.editablePermission && !lt(t.editablePermission, e), p = i !== void 0 && r !== void 0 ? [...Array.isArray(i) ? i : [i], r] : null, m = (e) => p && (!a.rowFieldKeys || a.rowFieldKeys.has(e)) ? p : null, g = a.inline || a.hideLabel || !u && t.type === "checkbox" ? "" : /* @__PURE__ */ X(nh, {
10988
10995
  form: h,
10989
10996
  field: t,
@@ -11013,14 +11020,14 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11013
11020
  moduleName: e,
11014
11021
  initialValue: t.value,
11015
11022
  scopeValues: { clientId: n },
11016
- onAiUpload: x ? (e) => ie.runAction(a.groupNameForActions, t, x, e) : void 0,
11017
- formDisabled: ie.busy
11023
+ onAiUpload: x ? (e) => N.runAction(a.groupNameForActions, t, x, e) : void 0,
11024
+ formDisabled: N.busy
11018
11025
  })
11019
11026
  }), C = b.length > 0 ? (() => {
11020
11027
  let e = rt(b), n = (n) => /* @__PURE__ */ X(_n, {
11021
11028
  position: n,
11022
11029
  actions: e[n],
11023
- aiActions: ie,
11030
+ aiActions: N,
11024
11031
  groupName: a.groupNameForActions,
11025
11032
  field: t
11026
11033
  }, n);
@@ -11053,7 +11060,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11053
11060
  return t.showIf?.field ? /* @__PURE__ */ Z(Cn.Fragment, { children: [T, /* @__PURE__ */ X(B.Item, {
11054
11061
  shouldUpdate: !0,
11055
11062
  noStyle: !0,
11056
- children: ({ getFieldValue: e }) => _e(t.showIf, e, m(t.showIf.field)) ? /* @__PURE__ */ X(z, {
11063
+ children: ({ getFieldValue: e }) => ge(t.showIf, e, m(t.showIf.field)) ? /* @__PURE__ */ X(z, {
11057
11064
  xs: 24,
11058
11065
  md: _,
11059
11066
  style: y,
@@ -11067,7 +11074,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11067
11074
  className: a.inline ? "v1-combine-cell" : void 0,
11068
11075
  children: w
11069
11076
  })] }, t.field);
11070
- }, ye = (t) => {
11077
+ }, ve = (t) => {
11071
11078
  let r = typeof t.field == "string" && t.field.includes(".") ? t.field.split(".") : [t.field], i = !!t.editablePermission && !lt(t.editablePermission, e), a = /* @__PURE__ */ X(gh, {
11072
11079
  field: t,
11073
11080
  label: t.label,
@@ -11109,7 +11116,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11109
11116
  children: s ? /* @__PURE__ */ X(Qn, {
11110
11117
  gutter: [24, 0],
11111
11118
  align: "top",
11112
- children: P(c, u, r[0], !1, t.field)
11119
+ children: be(c, u, r[0], !1, t.field)
11113
11120
  }) : /* @__PURE__ */ X(B.Item, {
11114
11121
  name: [u],
11115
11122
  noStyle: !0,
@@ -11122,7 +11129,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11122
11129
  name: [...r, u],
11123
11130
  moduleName: e,
11124
11131
  scopeValues: { clientId: n },
11125
- formDisabled: ie.busy
11132
+ formDisabled: N.busy
11126
11133
  })
11127
11134
  })
11128
11135
  })]
@@ -11140,7 +11147,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11140
11147
  })
11141
11148
  })
11142
11149
  }, t.field);
11143
- }, be = (t, r, i) => {
11150
+ }, ye = (t, r, i) => {
11144
11151
  let a = typeof t.field == "string" && t.field.includes(".") ? t.field.split(".") : [t.field], o = !!t.editablePermission && !lt(t.editablePermission, e), s = /* @__PURE__ */ X(gh, {
11145
11152
  field: t,
11146
11153
  label: t.label,
@@ -11188,7 +11195,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11188
11195
  children: l ? /* @__PURE__ */ X(Qn, {
11189
11196
  gutter: [24, 0],
11190
11197
  align: "top",
11191
- children: P(u, o, m, !1, t.field)
11198
+ children: be(u, o, m, !1, t.field)
11192
11199
  }) : /* @__PURE__ */ X(B.Item, {
11193
11200
  name: [o],
11194
11201
  noStyle: !0,
@@ -11201,7 +11208,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11201
11208
  name: s,
11202
11209
  moduleName: e,
11203
11210
  scopeValues: { clientId: n },
11204
- formDisabled: ie.busy
11211
+ formDisabled: N.busy
11205
11212
  })
11206
11213
  })
11207
11214
  })]
@@ -11220,20 +11227,20 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11220
11227
  })
11221
11228
  })
11222
11229
  }, `${i}-${r}-${t.field}`);
11223
- }, P = (e, t, n, r = !1, i) => {
11230
+ }, be = (e, t, n, r = !1, i) => {
11224
11231
  let a = /* @__PURE__ */ new Set(), o = [], s = new Set(e.map((e) => e.field).filter(Boolean));
11225
11232
  return e.forEach((c) => {
11226
11233
  if (sh(c.addRow) && t === void 0) {
11227
- o.push(ye(c));
11234
+ o.push(ve(c));
11228
11235
  return;
11229
11236
  }
11230
11237
  if (sh(c.addRow) && t !== void 0) {
11231
- o.push(be(c, t, n));
11238
+ o.push(ye(c, t, n));
11232
11239
  return;
11233
11240
  }
11234
11241
  let l = c.combineKey?.trim?.();
11235
11242
  if (!l) {
11236
- o.push(ve(c, t, n, {
11243
+ o.push(_e(c, t, n, {
11237
11244
  hideLabel: r,
11238
11245
  groupNameForActions: i,
11239
11246
  rowFieldKeys: s
@@ -11249,7 +11256,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11249
11256
  field: d.find((e) => e.combineLabel) ?? c,
11250
11257
  siblingPrefix: n !== void 0 && t !== void 0 ? [...Array.isArray(n) ? n : [n], t] : null,
11251
11258
  combined: !0
11252
- }), p = d.find((e) => e.combineToggleTarget)?.combineToggleTarget, m = d.find((e) => e.combineToggleLabel)?.combineToggleLabel ?? "Show range", g = d.some((e) => sh(e.combineWrap)), _ = Number(d.find((e) => [12, 24].includes(Number(e.combineSpan)))?.combineSpan), v = p ? d.find((e) => ge(e) === p) : null, y = v?.field?.includes?.(".") ? v.field.split(".") : [v?.field].filter(Boolean), b = v ? n !== void 0 && t !== void 0 ? [
11259
+ }), p = d.find((e) => e.combineToggleTarget)?.combineToggleTarget, m = d.find((e) => e.combineToggleLabel)?.combineToggleLabel ?? "Show range", g = d.some((e) => sh(e.combineWrap)), _ = Number(d.find((e) => [12, 24].includes(Number(e.combineSpan)))?.combineSpan), v = p ? d.find((e) => he(e) === p) : null, y = v?.field?.includes?.(".") ? v.field.split(".") : [v?.field].filter(Boolean), b = v ? n !== void 0 && t !== void 0 ? [
11253
11260
  n,
11254
11261
  t,
11255
11262
  ...y
@@ -11266,20 +11273,20 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11266
11273
  noStyle: !0,
11267
11274
  shouldUpdate: !0,
11268
11275
  children: ({ getFieldValue: e }) => {
11269
- let r = b ? !lh(e(b)) : !1, i = me[u] ?? r, a = p && !i ? d.filter((e) => ge(e) !== p) : d;
11276
+ let r = b ? !lh(e(b)) : !1, i = pe[u] ?? r, a = p && !i ? d.filter((e) => he(e) !== p) : d;
11270
11277
  return /* @__PURE__ */ Z(Y, { children: [/* @__PURE__ */ X(Qn, {
11271
11278
  gutter: [8, 0],
11272
11279
  align: "top",
11273
11280
  wrap: g,
11274
11281
  className: `v1-combine-row${g ? " v1-combine-row-wrap" : ""}`,
11275
- children: a.map((e) => ve(e, t, n, { inline: !0 }))
11282
+ children: a.map((e) => _e(e, t, n, { inline: !0 }))
11276
11283
  }), p && /* @__PURE__ */ Z("div", {
11277
11284
  className: "v1-combine-range",
11278
11285
  children: [/* @__PURE__ */ X(W, {
11279
11286
  size: "small",
11280
11287
  checked: i,
11281
11288
  onChange: (e) => {
11282
- !e && b && (h.setFieldValue(b, void 0), h.validateFields([b]).catch(() => {})), he((t) => ({
11289
+ !e && b && (h.setFieldValue(b, void 0), h.validateFields([b]).catch(() => {})), me((t) => ({
11283
11290
  ...t,
11284
11291
  [u]: e
11285
11292
  }));
@@ -11296,13 +11303,13 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11296
11303
  }, u));
11297
11304
  }), o;
11298
11305
  }, xe = (e, t) => {
11299
- let n = e.name ?? e.id ?? String(t), r = e.name ?? n, i = oe(M, r), a = !!i && i.leaderName !== r, o = i ? j.find((e) => e.name === i.leaderName) ?? e : e, s = Math.max(0, Number(o.minRows ?? 0) || 0), c = Math.max(0, Number(o.maxRows ?? 0) || 0), l = i ? i.memberNames : [r], u = () => {
11306
+ let n = e.name ?? e.id ?? String(t), r = e.name ?? n, i = ae(M, r), a = !!i && i.leaderName !== r, o = i ? j.find((e) => e.name === i.leaderName) ?? e : e, s = Math.max(0, Number(o.minRows ?? 0) || 0), c = Math.max(0, Number(o.maxRows ?? 0) || 0), l = i ? i.memberNames : [r], u = () => {
11300
11307
  l.forEach((e) => re.current[e]?.add());
11301
11308
  }, d = (e) => {
11302
11309
  l.forEach((t) => re.current[t]?.remove(e));
11303
11310
  }, f = e.addRow ? /* @__PURE__ */ X(B.List, {
11304
11311
  name: r,
11305
- initialValue: N[e.name] ?? [],
11312
+ initialValue: P[e.name] ?? [],
11306
11313
  rules: a ? [] : [{ validator: async (t, n = []) => {
11307
11314
  if (!(sh(e.toggleEnabled) && e.toggleField && h.getFieldValue(e.toggleField))) {
11308
11315
  if (s > 0 && n.length < s) throw Error(`Keep at least ${s} row${s > 1 ? "s" : ""}.`);
@@ -11336,7 +11343,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11336
11343
  md: e.col ?? 12,
11337
11344
  className: "v1-addrow-header-label",
11338
11345
  children: e.label
11339
- }, ge(e)))
11346
+ }, he(e)))
11340
11347
  }),
11341
11348
  t.map(({ key: n, name: i }) => /* @__PURE__ */ Z("div", {
11342
11349
  className: "v1-addrow-item",
@@ -11352,7 +11359,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11352
11359
  children: /* @__PURE__ */ X(Qn, {
11353
11360
  gutter: [24, 0],
11354
11361
  align: "top",
11355
- children: P(e.fields, i, r, sh(e.sharedRowLabels), r)
11362
+ children: be(e.fields, i, r, sh(e.sharedRowLabels), r)
11356
11363
  })
11357
11364
  })]
11358
11365
  }, n)),
@@ -11361,7 +11368,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11361
11368
  }))
11362
11369
  }) : /* @__PURE__ */ X(Qn, {
11363
11370
  gutter: [24, 0],
11364
- children: P(e.fields, void 0, void 0, !1, r)
11371
+ children: be(e.fields, void 0, void 0, !1, r)
11365
11372
  });
11366
11373
  return /* @__PURE__ */ X(Mn, {
11367
11374
  className: "v1-card v1-edit-card",
@@ -11381,7 +11388,7 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11381
11388
  size: "small",
11382
11389
  icon: g[n] ? /* @__PURE__ */ X(Rr, {}) : /* @__PURE__ */ X(Gi, {}),
11383
11390
  onClick: (e) => {
11384
- e.stopPropagation(), ce(n);
11391
+ e.stopPropagation(), se(n);
11385
11392
  }
11386
11393
  })
11387
11394
  ]
@@ -11399,13 +11406,13 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11399
11406
  })
11400
11407
  }, n);
11401
11408
  };
11402
- return /* @__PURE__ */ Z("main", { children: [se.length > 0 && /* @__PURE__ */ X(tn, { items: se }), /* @__PURE__ */ Z("div", {
11409
+ return /* @__PURE__ */ Z("main", { children: [oe.length > 0 && /* @__PURE__ */ X(tn, { items: oe }), /* @__PURE__ */ Z("div", {
11403
11410
  className: "v1-edit-page",
11404
11411
  children: [/* @__PURE__ */ X("div", {
11405
11412
  className: "v1-page-inner",
11406
11413
  children: /* @__PURE__ */ Z($n, {
11407
- spinning: b || ie.busy,
11408
- tip: ie.busy ? "Running AI action…" : "Loading form fields...",
11414
+ spinning: b || N.busy,
11415
+ tip: N.busy ? "Running AI action…" : "Loading form fields...",
11409
11416
  children: [
11410
11417
  S && /* @__PURE__ */ X(Dn, {
11411
11418
  type: "error",
@@ -11424,13 +11431,13 @@ function Bh({ moduleName: e, recordId: t, clientId: n, region: r, breadcrumbItem
11424
11431
  layout: "vertical",
11425
11432
  colon: !1,
11426
11433
  className: "v1-form",
11427
- disabled: ie.busy,
11434
+ disabled: N.busy,
11428
11435
  requiredMark: (e, { required: t }) => /* @__PURE__ */ Z(Y, { children: [e, t && /* @__PURE__ */ X("span", {
11429
11436
  className: "v1-required-mark",
11430
11437
  children: " *"
11431
11438
  })] }),
11432
- onFinish: de,
11433
- onFinishFailed: pe,
11439
+ onFinish: ue,
11440
+ onFinishFailed: fe,
11434
11441
  children: [j.map((e, t) => e.showIf?.field ? /* @__PURE__ */ X(mh, {
11435
11442
  form: h,
11436
11443
  showIf: e.showIf,
@@ -12008,7 +12015,7 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12008
12015
  ...e,
12009
12016
  key: ag(e),
12010
12017
  label: ig(e)
12011
- })).filter((e) => e.key && e.label && !e.tableHidden), [t]), ie = O.length ? O : re.map((e) => e.key), N = I(() => {
12018
+ })).filter((e) => e.key && e.label && !e.tableHidden), [t]), N = O.length ? O : re.map((e) => e.key), P = I(() => {
12012
12019
  if (u) return r;
12013
12020
  let e = b.toLowerCase();
12014
12021
  return !e || e.length < 3 ? r : r.filter((t) => re.some((n) => String(og(t, n.key)).toLowerCase().includes(e)));
@@ -12017,16 +12024,16 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12017
12024
  re,
12018
12025
  u,
12019
12026
  b
12020
- ]), ae = typeof a == "number" ? a : b.trim() ? N.length : r.length, oe = I(() => {
12021
- if (j) return N;
12027
+ ]), ie = typeof a == "number" ? a : b.trim() ? P.length : r.length, ae = I(() => {
12028
+ if (j) return P;
12022
12029
  let e = (M.current - 1) * M.pageSize;
12023
- return N.slice(e, e + M.pageSize);
12030
+ return P.slice(e, e + M.pageSize);
12024
12031
  }, [
12025
12032
  M.current,
12026
12033
  M.pageSize,
12027
- N,
12034
+ P,
12028
12035
  j
12029
- ]), se = I(() => re.filter((e) => ie.includes(e.key)).map((e) => ({
12036
+ ]), oe = I(() => re.filter((e) => N.includes(e.key)).map((e) => ({
12030
12037
  title: e.label,
12031
12038
  dataIndex: e.key,
12032
12039
  key: e.key,
@@ -12039,24 +12046,24 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12039
12046
  className: "job-cell-primary",
12040
12047
  children: og(n, e.key)
12041
12048
  })
12042
- })), [re, ie]), ce = ie.length === re.length, le = ie.length > 0 && !ce, ue = (e, t) => {
12049
+ })), [re, N]), se = N.length === re.length, ce = N.length > 0 && !se, le = (e, t) => {
12043
12050
  k((n) => {
12044
12051
  let r = n.length ? n : re.map((e) => e.key);
12045
12052
  return t ? r.includes(e) ? r : [...r, e] : r.filter((t) => t !== e);
12046
12053
  });
12047
- }, de = /* @__PURE__ */ Z("div", {
12054
+ }, ue = /* @__PURE__ */ Z("div", {
12048
12055
  className: "column-visibility-menu",
12049
12056
  onClick: (e) => e.stopPropagation(),
12050
12057
  children: [/* @__PURE__ */ X(Nn, {
12051
- checked: ce,
12052
- indeterminate: le,
12058
+ checked: se,
12059
+ indeterminate: ce,
12053
12060
  onChange: (e) => {
12054
12061
  k(e.target.checked ? re.map((e) => e.key) : []);
12055
12062
  },
12056
12063
  children: "Select All"
12057
12064
  }), re.map((e) => /* @__PURE__ */ X(Nn, {
12058
- checked: ie.includes(e.key),
12059
- onChange: (t) => ue(e.key, t.target.checked),
12065
+ checked: N.includes(e.key),
12066
+ onChange: (t) => le(e.key, t.target.checked),
12060
12067
  children: e.label
12061
12068
  }, e.key))]
12062
12069
  });
@@ -12070,7 +12077,7 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12070
12077
  activeKey: v,
12071
12078
  items: [{
12072
12079
  key: "all",
12073
- label: sg(e, ae)
12080
+ label: sg(e, ie)
12074
12081
  }],
12075
12082
  onChange: (e) => {
12076
12083
  y(e), D({
@@ -12131,7 +12138,7 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12131
12138
  open: ee,
12132
12139
  onOpenChange: A,
12133
12140
  trigger: ["click"],
12134
- dropdownRender: () => de,
12141
+ dropdownRender: () => ue,
12135
12142
  placement: "bottomLeft",
12136
12143
  overlayClassName: "column-visibility-dropdown",
12137
12144
  children: /* @__PURE__ */ X(R, {
@@ -12180,8 +12187,8 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12180
12187
  C(e), T(t);
12181
12188
  }
12182
12189
  } : void 0,
12183
- columns: se,
12184
- dataSource: oe,
12190
+ columns: oe,
12191
+ dataSource: ae,
12185
12192
  size: "middle",
12186
12193
  scroll: { x: "max-content" },
12187
12194
  showSorterTooltip: !1,
@@ -12194,7 +12201,7 @@ function cg({ listName: e = "List", fields: t = [], actions: n = [], dataSource:
12194
12201
  /* @__PURE__ */ X(po, {
12195
12202
  current: M.current,
12196
12203
  pageSize: M.pageSize,
12197
- total: ae,
12204
+ total: ie,
12198
12205
  onChange: (e) => {
12199
12206
  j ? c?.(e) : D((t) => ({
12200
12207
  ...t,
@@ -15038,11 +15045,11 @@ function Av({ type: e, record: t, lookups: n, identity: r, referralOptions: i, o
15038
15045
  u
15039
15046
  ]);
15040
15047
  A && (h || Number(j.referralRate));
15041
- let M = j.currency, re = u.readOnly, ie = (e) => {
15048
+ let M = j.currency, re = u.readOnly, N = (e) => {
15042
15049
  g(e);
15043
15050
  let t = (i ?? []).find((t) => t.value === e);
15044
15051
  t?.lastRate != null && v(Number(t.lastRate) || 0), t?.type && b(t.type), a?.(e, t);
15045
- }, N = async (e) => {
15052
+ }, P = async (e) => {
15046
15053
  if (!e) return;
15047
15054
  if (e.requireReason && !x.trim()) {
15048
15055
  w(!0);
@@ -15076,7 +15083,7 @@ function Av({ type: e, record: t, lookups: n, identity: r, referralOptions: i, o
15076
15083
  } finally {
15077
15084
  E("");
15078
15085
  }
15079
- }, ae = u.actions.primary, oe = u.actions.reject;
15086
+ }, ie = u.actions.primary, ae = u.actions.reject;
15080
15087
  return /* @__PURE__ */ Z("div", {
15081
15088
  className: `fa-panel fa-variant-${l}`,
15082
15089
  children: [
@@ -15398,7 +15405,7 @@ function Av({ type: e, record: t, lookups: n, identity: r, referralOptions: i, o
15398
15405
  className: "fa-referral-select",
15399
15406
  placeholder: "Select a referral",
15400
15407
  value: h ?? void 0,
15401
- onChange: ie,
15408
+ onChange: N,
15402
15409
  options: i ?? [],
15403
15410
  showSearch: !0,
15404
15411
  optionFilterProp: "label"
@@ -15524,7 +15531,7 @@ function Av({ type: e, record: t, lookups: n, identity: r, referralOptions: i, o
15524
15531
  ]
15525
15532
  })]
15526
15533
  }),
15527
- oe?.requireReason && /* @__PURE__ */ Z("div", {
15534
+ ae?.requireReason && /* @__PURE__ */ Z("div", {
15528
15535
  className: "fa-reason",
15529
15536
  children: [
15530
15537
  /* @__PURE__ */ Z("label", {
@@ -15578,20 +15585,20 @@ function Av({ type: e, record: t, lookups: n, identity: r, referralOptions: i, o
15578
15585
  onClick: c,
15579
15586
  children: "Cancel"
15580
15587
  }),
15581
- oe && /* @__PURE__ */ X(Sl, {
15588
+ ae && /* @__PURE__ */ X(Sl, {
15582
15589
  danger: !0,
15583
- loading: T === oe.key,
15590
+ loading: T === ae.key,
15584
15591
  disabled: !!T,
15585
- onClick: () => N(oe),
15586
- children: oe.label
15592
+ onClick: () => P(ae),
15593
+ children: ae.label
15587
15594
  }),
15588
- ae && /* @__PURE__ */ X(Sl, {
15595
+ ie && /* @__PURE__ */ X(Sl, {
15589
15596
  variant: "primary",
15590
15597
  icon: /* @__PURE__ */ X(Cr, {}),
15591
- loading: T === ae.key,
15598
+ loading: T === ie.key,
15592
15599
  disabled: !!T,
15593
- onClick: () => N(ae),
15594
- children: ae.label
15600
+ onClick: () => P(ie),
15601
+ children: ie.label
15595
15602
  })
15596
15603
  ]
15597
15604
  })]
@@ -16368,7 +16375,7 @@ function By({ onLogin: e, defaultRedirectPath: t = "/" }) {
16368
16375
  className: "auth-login-page",
16369
16376
  children: [/* @__PURE__ */ X("section", {
16370
16377
  className: "auth-login-bg",
16371
- style: { background: P.brand },
16378
+ style: { background: be.brand },
16372
16379
  children: /* @__PURE__ */ Z("div", {
16373
16380
  className: "auth-login-static-section",
16374
16381
  children: [
@@ -16735,7 +16742,7 @@ function hb() {
16735
16742
  className: "auth-login-page",
16736
16743
  children: [/* @__PURE__ */ X("section", {
16737
16744
  className: "auth-login-bg",
16738
- style: { background: P.brand },
16745
+ style: { background: be.brand },
16739
16746
  children: /* @__PURE__ */ Z("div", {
16740
16747
  className: "auth-login-static-section",
16741
16748
  children: [
@@ -18500,7 +18507,7 @@ function ux({ field: e, index: t, configType: n, moduleKey: r, onUpdate: i, onRe
18500
18507
  ...n
18501
18508
  }, O({ actionButtons: r });
18502
18509
  }
18503
- function ie(t) {
18510
+ function N(t) {
18504
18511
  let n = [...e.actionButtons ?? []];
18505
18512
  n.splice(t, 1), O({ actionButtons: n });
18506
18513
  }
@@ -18585,7 +18592,7 @@ function ux({ field: e, index: t, configType: n, moduleKey: r, onUpdate: i, onRe
18585
18592
  removeSecondaryField: ne,
18586
18593
  addActionButton: j,
18587
18594
  updateActionButton: M,
18588
- removeActionButton: ie,
18595
+ removeActionButton: N,
18589
18596
  moduleKey: r,
18590
18597
  fieldKey: e.fieldKey,
18591
18598
  update: O
@@ -18795,7 +18802,7 @@ function vx({ role: e }) {
18795
18802
  }
18796
18803
  c(!0);
18797
18804
  try {
18798
- let r = await le(e, t, n);
18805
+ let r = await ce(e, t, n);
18799
18806
  o(Array.isArray(r) ? r : []);
18800
18807
  } catch {
18801
18808
  q.error("Failed to load form permissions"), o([]);
@@ -20096,7 +20103,7 @@ function qx(e = []) {
20096
20103
  function Jx({ collection: e, displayField: t, valueField: n, value: r, labelValue: i, onChange: a }) {
20097
20104
  let [o, s] = L([]), [c, l] = L(!1), u = En(""), d = () => {
20098
20105
  let r = `${e}|${t}|${n}`;
20099
- !e || !t || u.current === r || (l(!0), pe(e, t, n || "_id").then((e) => {
20106
+ !e || !t || u.current === r || (l(!0), fe(e, t, n || "_id").then((e) => {
20100
20107
  u.current = r, s(e);
20101
20108
  }).catch(() => s([])).finally(() => l(!1)));
20102
20109
  }, f = r && !o.some((e) => e.value === r) ? [{
@@ -23020,7 +23027,7 @@ function $x({ open: e, editingGroup: t, defaultModule: n, moduleOptions: r, allG
23020
23027
  searchLabel: `${e.label} ${e.value}`.toLowerCase()
23021
23028
  }));
23022
23029
  }
23023
- async function ie() {
23030
+ async function N() {
23024
23031
  try {
23025
23032
  let e = await c.validateFields(), n = {
23026
23033
  ...c.getFieldsValue(!0),
@@ -23096,7 +23103,7 @@ function $x({ open: e, editingGroup: t, defaultModule: n, moduleOptions: r, allG
23096
23103
  u(!1);
23097
23104
  }
23098
23105
  }
23099
- let N = I(() => re(d || n), [
23106
+ let P = I(() => re(d || n), [
23100
23107
  i,
23101
23108
  n,
23102
23109
  t,
@@ -23123,7 +23130,7 @@ function $x({ open: e, editingGroup: t, defaultModule: n, moduleOptions: r, allG
23123
23130
  }), /* @__PURE__ */ X(R, {
23124
23131
  type: "primary",
23125
23132
  loading: l,
23126
- onClick: ie,
23133
+ onClick: N,
23127
23134
  icon: X(t ? Br : J, {}),
23128
23135
  children: t ? "Update Group" : "Create Group"
23129
23136
  })]
@@ -24024,9 +24031,9 @@ function $x({ open: e, editingGroup: t, defaultModule: n, moduleOptions: r, allG
24024
24031
  children: "Open only the field you want to change"
24025
24032
  }),
24026
24033
  h && /* @__PURE__ */ X($n, { size: "small" }),
24027
- !h && N.length > 0 && /* @__PURE__ */ Z("span", {
24034
+ !h && P.length > 0 && /* @__PURE__ */ Z("span", {
24028
24035
  className: "fg-fields-hint",
24029
- children: [N.length, " fields available"]
24036
+ children: [P.length, " fields available"]
24030
24037
  })
24031
24038
  ]
24032
24039
  }), /* @__PURE__ */ X(B.List, {
@@ -24038,7 +24045,7 @@ function $x({ open: e, editingGroup: t, defaultModule: n, moduleOptions: r, allG
24038
24045
  remove: n,
24039
24046
  move: r,
24040
24047
  absBase: [],
24041
- moduleFieldOptions: N,
24048
+ moduleFieldOptions: P,
24042
24049
  fieldsLoading: h,
24043
24050
  dragIndexRef: O,
24044
24051
  dragOverIndex: y,
@@ -25123,7 +25130,7 @@ function rS() {
25123
25130
  await Promise.all(t.map(({ g: e, index: t }) => st(e.id, {
25124
25131
  ...e,
25125
25132
  order: t
25126
- }, N(e.module || o)))), q.success("Group order updated"), O(o), o !== "all" && O("all");
25133
+ }, P(e.module || o)))), q.success("Group order updated"), O(o), o !== "all" && O("all");
25127
25134
  } catch (e) {
25128
25135
  q.error(e.message || "Could not reorder groups"), O(o);
25129
25136
  }
@@ -25131,7 +25138,7 @@ function rS() {
25131
25138
  function re(e) {
25132
25139
  p(Ax[e]);
25133
25140
  }
25134
- function ie(e) {
25141
+ function N(e) {
25135
25142
  let t = {
25136
25143
  ...v,
25137
25144
  ...e
@@ -25147,13 +25154,13 @@ function rS() {
25147
25154
  loading: !1
25148
25155
  })));
25149
25156
  }
25150
- function N(e = o) {
25157
+ function P(e = o) {
25151
25158
  return e === "jobs" ? v : {};
25152
25159
  }
25153
- function ae(e) {
25160
+ function ie(e) {
25154
25161
  C(JSON.parse(JSON.stringify(e))), q.success(`Copied settings from ${e.label || e.name}`);
25155
25162
  }
25156
- async function oe(e) {
25163
+ async function ae(e) {
25157
25164
  if (S) try {
25158
25165
  let t = {
25159
25166
  ...e,
@@ -25161,15 +25168,15 @@ function rS() {
25161
25168
  payloadKey: S.payloadKey ?? e.payloadKey,
25162
25169
  fields: JSON.parse(JSON.stringify(S.fields ?? []))
25163
25170
  };
25164
- await st(e.id, t, N(e.module || o)), q.success(`Pasted settings into ${e.label || e.name}`), O(o), o !== "all" && O("all");
25171
+ await st(e.id, t, P(e.module || o)), q.success(`Pasted settings into ${e.label || e.name}`), O(o), o !== "all" && O("all");
25165
25172
  } catch (e) {
25166
25173
  q.error(e.message || "Could not paste settings");
25167
25174
  }
25168
25175
  }
25169
- function se() {
25176
+ function oe() {
25170
25177
  p(null), a(Ux(w)), O(o), o !== "all" && O("all");
25171
25178
  }
25172
- let ce = w.map(({ key: e, label: t, color: n }) => {
25179
+ let se = w.map(({ key: e, label: t, color: n }) => {
25173
25180
  let r = i[e] ?? {
25174
25181
  groups: [],
25175
25182
  loading: !1,
@@ -25222,8 +25229,8 @@ function rS() {
25222
25229
  groups: a,
25223
25230
  onEdit: A,
25224
25231
  onDelete: j,
25225
- onCopy: ae,
25226
- onPaste: oe,
25232
+ onCopy: ie,
25233
+ onPaste: ae,
25227
25234
  canPaste: !!S,
25228
25235
  onReorder: e === "all" ? void 0 : M
25229
25236
  })
@@ -25231,7 +25238,7 @@ function rS() {
25231
25238
  ]
25232
25239
  })
25233
25240
  };
25234
- }), le = [
25241
+ }), ce = [
25235
25242
  {
25236
25243
  key: "module",
25237
25244
  label: "Module Form",
@@ -25258,7 +25265,7 @@ function rS() {
25258
25265
  value: e._id ?? e.id,
25259
25266
  label: e.clientName ?? e.name ?? e.clientRefrenceId ?? e._id
25260
25267
  })).filter((e) => e.value),
25261
- onChange: (e) => ie({ clientId: e ?? "" })
25268
+ onChange: (e) => N({ clientId: e ?? "" })
25262
25269
  }),
25263
25270
  /* @__PURE__ */ X(R, {
25264
25271
  size: "small",
@@ -25281,7 +25288,7 @@ function rS() {
25281
25288
  children: /* @__PURE__ */ X(rr, {
25282
25289
  activeKey: o,
25283
25290
  onChange: k,
25284
- items: ce,
25291
+ items: se,
25285
25292
  size: "middle",
25286
25293
  className: "fg-tabs"
25287
25294
  })
@@ -25294,7 +25301,7 @@ function rS() {
25294
25301
  allGroupsByModule: Object.fromEntries(Object.entries(i).filter(([e]) => e !== "all").map(([e, t]) => [e, t.groups ?? []])),
25295
25302
  onClose: te,
25296
25303
  onSaved: ne,
25297
- onSaveGroup: (e, t) => t ? st(t.id, e, N(e.module)) : Tt(e, N(e.module))
25304
+ onSaveGroup: (e, t) => t ? st(t.id, e, P(e.module)) : Tt(e, P(e.module))
25298
25305
  }),
25299
25306
  /* @__PURE__ */ X(Ln, {
25300
25307
  open: b,
@@ -25394,7 +25401,7 @@ function rS() {
25394
25401
  children: /* @__PURE__ */ X(rr, {
25395
25402
  activeKey: m,
25396
25403
  onChange: h,
25397
- items: le,
25404
+ items: ce,
25398
25405
  size: "middle",
25399
25406
  className: "fg-top-tabs",
25400
25407
  tabBarStyle: {
@@ -25413,7 +25420,7 @@ function rS() {
25413
25420
  confirmLabel: f?.confirmLabel,
25414
25421
  danger: f?.danger,
25415
25422
  onCancel: () => p(null),
25416
- onVerified: se
25423
+ onVerified: oe
25417
25424
  })
25418
25425
  ]
25419
25426
  });
@@ -25770,7 +25777,7 @@ function bS({ open: e, fieldMeta: t, value: n, onClose: r, onSave: i }) {
25770
25777
  style: { width: "100%" },
25771
25778
  value: y,
25772
25779
  onChange: (e) => p("renderType", e),
25773
- options: ie
25780
+ options: N
25774
25781
  }),
25775
25782
  /* @__PURE__ */ X(iS, {
25776
25783
  type: "secondary",
@@ -26371,7 +26378,7 @@ function wS({ open: e, module: t, onClose: n }) {
26371
26378
  if (!r.trim()) return q.warning("Enter a record _id to preview");
26372
26379
  c(!0), u("");
26373
26380
  try {
26374
- let [e] = await Promise.all([de(t, r.trim()), Se()]);
26381
+ let [e] = await Promise.all([ue(t, r.trim()), Se()]);
26375
26382
  o(e), e.length || u("No groups returned — check the id and module.");
26376
26383
  } catch (e) {
26377
26384
  u(e?.message || "Failed to load preview");
@@ -26470,7 +26477,7 @@ function TS(e) {
26470
26477
  }), Array.isArray(e?.documentNameOrder) && e.documentNameOrder.length && (t.documentNameOrder = e.documentNameOrder), t;
26471
26478
  }
26472
26479
  function ES({ open: e, onClose: t }) {
26473
- let [n, r] = L(() => ({ ...be() })), [i, a] = L(!1);
26480
+ let [n, r] = L(() => ({ ...ye() })), [i, a] = L(!1);
26474
26481
  F(() => {
26475
26482
  if (!e) return;
26476
26483
  let t = !1;
@@ -26651,16 +26658,16 @@ function ES({ open: e, onClose: t }) {
26651
26658
  });
26652
26659
  }
26653
26660
  function DS() {
26654
- let [e, t] = L([]), [n, r] = L(!0), [i, a] = L(""), [o, s] = L([]), [c, l] = L([]), [u, d] = L([]), [f, p] = L({}), [m, h] = L([]), [g, _] = L(!1), [v, y] = L(""), [b, x] = L(!1), [S, C] = L(null), [w, T] = L(null), [E, D] = L(!1), [O, k] = L(!1), [ee, A] = L(null), [te, ne] = L(0), [j, M] = L(""), [re, ie] = L({});
26655
- function N(e) {
26661
+ let [e, t] = L([]), [n, r] = L(!0), [i, a] = L(""), [o, s] = L([]), [c, l] = L([]), [u, d] = L([]), [f, p] = L({}), [m, h] = L([]), [g, _] = L(!1), [v, y] = L(""), [b, x] = L(!1), [S, C] = L(null), [w, T] = L(null), [E, D] = L(!1), [O, k] = L(!1), [ee, A] = L(null), [te, ne] = L(0), [j, M] = L(""), [re, N] = L({});
26662
+ function P(e) {
26656
26663
  A(lS[e]);
26657
26664
  }
26658
- async function ae(e, t, n, r) {
26665
+ async function ie(e, t, n, r) {
26659
26666
  let i = o;
26660
26667
  s((r) => r.map((r) => r.id === e.id ? {
26661
26668
  ...r,
26662
26669
  [t]: n
26663
- } : r)), ie((n) => ({
26670
+ } : r)), N((n) => ({
26664
26671
  ...n,
26665
26672
  [`${e.id}:${t}`]: !0
26666
26673
  }));
@@ -26672,20 +26679,20 @@ function DS() {
26672
26679
  } catch (e) {
26673
26680
  s(i), q.error(e?.message || "Could not update group visibility");
26674
26681
  } finally {
26675
- ie((n) => {
26682
+ N((n) => {
26676
26683
  let r = { ...n };
26677
26684
  return delete r[`${e.id}:${t}`], r;
26678
26685
  });
26679
26686
  }
26680
26687
  }
26681
- let oe = (e, t) => ae(e, "hideGroup", t, {
26688
+ let ae = (e, t) => ie(e, "hideGroup", t, {
26682
26689
  on: "Group hidden from add/edit forms and the detail view",
26683
26690
  off: "Group is visible again"
26684
- }), se = (e, t) => ae(e, "hideGroupInDetail", t, {
26691
+ }), oe = (e, t) => ie(e, "hideGroupInDetail", t, {
26685
26692
  on: "Group hidden from the detail view only — add/edit forms keep it",
26686
26693
  off: "Group is visible in the detail view again"
26687
26694
  });
26688
- function ce() {
26695
+ function se() {
26689
26696
  A(null), ne((e) => e + 1);
26690
26697
  }
26691
26698
  F(() => {
@@ -26721,11 +26728,11 @@ function DS() {
26721
26728
  e = !0;
26722
26729
  };
26723
26730
  }, [i, te]);
26724
- let le = I(() => c.map((e) => ({
26731
+ let ce = I(() => c.map((e) => ({
26725
26732
  value: e.key,
26726
26733
  label: `${e.label} (${e.key})`
26727
26734
  })), [c]);
26728
- async function ue() {
26735
+ async function le() {
26729
26736
  x(!0);
26730
26737
  try {
26731
26738
  let e = Object.entries(f).map(([e, t]) => hS(e, t)).filter(Boolean), { nextGroups: t, changed: n } = vS(o, f);
@@ -26743,7 +26750,7 @@ function DS() {
26743
26750
  x(!1);
26744
26751
  }
26745
26752
  }
26746
- function de(e) {
26753
+ function ue(e) {
26747
26754
  p((t) => ({
26748
26755
  ...t,
26749
26756
  [S.key]: {
@@ -26752,19 +26759,19 @@ function DS() {
26752
26759
  }
26753
26760
  })), C(null);
26754
26761
  }
26755
- function fe(e) {
26762
+ function de(e) {
26756
26763
  p((t) => {
26757
26764
  let n = { ...t };
26758
26765
  return delete n[e], n;
26759
26766
  });
26760
26767
  }
26761
- function pe(e) {
26768
+ function fe(e) {
26762
26769
  h((t) => {
26763
26770
  let n = [...t];
26764
26771
  return w.index === null ? n.push(e) : n[w.index] = e, n;
26765
26772
  }), T(null);
26766
26773
  }
26767
- function me(e, t) {
26774
+ function pe(e, t) {
26768
26775
  p((n) => {
26769
26776
  let r = n[e] ?? { field: e };
26770
26777
  return {
@@ -26776,7 +26783,7 @@ function DS() {
26776
26783
  };
26777
26784
  });
26778
26785
  }
26779
- let he = (e) => {
26786
+ let me = (e) => {
26780
26787
  if (!e) return null;
26781
26788
  let t = [];
26782
26789
  e.label && t.push(/* @__PURE__ */ X(G, {
@@ -26807,7 +26814,7 @@ function DS() {
26807
26814
  style: { fontSize: 12 },
26808
26815
  children: "—"
26809
26816
  });
26810
- }, ge = [
26817
+ }, he = [
26811
26818
  {
26812
26819
  title: "Group",
26813
26820
  dataIndex: "label",
@@ -26881,7 +26888,7 @@ function DS() {
26881
26888
  unCheckedChildren: "Show",
26882
26889
  checked: pS(t.hideGroup),
26883
26890
  loading: !!re[`${t.id}:hideGroup`],
26884
- onChange: (e) => oe(t, e)
26891
+ onChange: (e) => ae(t, e)
26885
26892
  })
26886
26893
  })
26887
26894
  },
@@ -26898,11 +26905,11 @@ function DS() {
26898
26905
  unCheckedChildren: "Show",
26899
26906
  checked: pS(t.hideGroupInDetail),
26900
26907
  loading: !!re[`${t.id}:hideGroupInDetail`],
26901
- onChange: (e) => se(t, e)
26908
+ onChange: (e) => oe(t, e)
26902
26909
  })
26903
26910
  })
26904
26911
  }
26905
- ], _e = (e) => {
26912
+ ], ge = (e) => {
26906
26913
  let t = e.fields ?? [];
26907
26914
  return t.length ? /* @__PURE__ */ X("div", {
26908
26915
  className: "fg-expanded-fields",
@@ -26945,7 +26952,7 @@ function DS() {
26945
26952
  }),
26946
26953
  /* @__PURE__ */ X("div", {
26947
26954
  className: "fg-field-row-flags",
26948
- children: he(n)
26955
+ children: me(n)
26949
26956
  }),
26950
26957
  /* @__PURE__ */ Z(U, {
26951
26958
  size: 4,
@@ -26958,7 +26965,7 @@ function DS() {
26958
26965
  checkedChildren: "Hide",
26959
26966
  unCheckedChildren: "Show",
26960
26967
  checked: r,
26961
- onChange: (e) => me(t.field, e)
26968
+ onChange: (e) => pe(t.field, e)
26962
26969
  })
26963
26970
  }),
26964
26971
  /* @__PURE__ */ X(K, {
@@ -26977,7 +26984,7 @@ function DS() {
26977
26984
  size: "small",
26978
26985
  danger: !0,
26979
26986
  icon: /* @__PURE__ */ X(Si, {}),
26980
- onClick: () => fe(t.field)
26987
+ onClick: () => de(t.field)
26981
26988
  })
26982
26989
  })
26983
26990
  ]
@@ -26990,7 +26997,7 @@ function DS() {
26990
26997
  style: { fontSize: 12 },
26991
26998
  children: "No fields in this group."
26992
26999
  });
26993
- }, ve = I(() => {
27000
+ }, _e = I(() => {
26994
27001
  let e = j.trim().toLowerCase();
26995
27002
  return [...o].filter((t) => !e || [
26996
27003
  t.label,
@@ -27001,7 +27008,7 @@ function DS() {
27001
27008
  e.type
27002
27009
  ])
27003
27010
  ].some((t) => String(t ?? "").toLowerCase().includes(e))).sort((e, t) => (e.order ?? 0) - (t.order ?? 0));
27004
- }, [o, j]), ye = [
27011
+ }, [o, j]), ve = [
27005
27012
  {
27006
27013
  title: "Label",
27007
27014
  dataIndex: "label",
@@ -27063,7 +27070,7 @@ function DS() {
27063
27070
  })]
27064
27071
  })
27065
27072
  }
27066
- ], be = e.map((e) => ({
27073
+ ], ye = e.map((e) => ({
27067
27074
  key: e.key,
27068
27075
  label: e.label
27069
27076
  }));
@@ -27084,13 +27091,13 @@ function DS() {
27084
27091
  key: "save",
27085
27092
  label: "Save current as default",
27086
27093
  icon: /* @__PURE__ */ X(Oi, {}),
27087
- onClick: () => N("save")
27094
+ onClick: () => P("save")
27088
27095
  },
27089
27096
  {
27090
27097
  key: "restore",
27091
27098
  label: "Restore saved default",
27092
27099
  icon: /* @__PURE__ */ X(kr, {}),
27093
- onClick: () => N("restore")
27100
+ onClick: () => P("restore")
27094
27101
  },
27095
27102
  { type: "divider" },
27096
27103
  {
@@ -27098,7 +27105,7 @@ function DS() {
27098
27105
  label: "Reset all detail settings",
27099
27106
  icon: /* @__PURE__ */ X(Si, {}),
27100
27107
  danger: !0,
27101
- onClick: () => N("reset")
27108
+ onClick: () => P("reset")
27102
27109
  }
27103
27110
  ] },
27104
27111
  children: /* @__PURE__ */ X(R, {
@@ -27126,7 +27133,7 @@ function DS() {
27126
27133
  icon: /* @__PURE__ */ X(Oi, {}),
27127
27134
  loading: b,
27128
27135
  disabled: !i,
27129
- onClick: ue,
27136
+ onClick: le,
27130
27137
  children: "Save Configuration"
27131
27138
  })
27132
27139
  ]
@@ -27145,7 +27152,7 @@ function DS() {
27145
27152
  /* @__PURE__ */ X(rr, {
27146
27153
  activeKey: i,
27147
27154
  onChange: a,
27148
- items: be.map((e) => ({
27155
+ items: ye.map((e) => ({
27149
27156
  ...e,
27150
27157
  children: null
27151
27158
  })),
@@ -27181,13 +27188,13 @@ function DS() {
27181
27188
  }),
27182
27189
  /* @__PURE__ */ X(nr, {
27183
27190
  rowKey: (e) => e.id ?? e.name,
27184
- dataSource: ve,
27185
- columns: ge,
27191
+ dataSource: _e,
27192
+ columns: he,
27186
27193
  pagination: !1,
27187
27194
  size: "small",
27188
27195
  className: "fg-table",
27189
27196
  expandable: {
27190
- expandedRowRender: _e,
27197
+ expandedRowRender: ge,
27191
27198
  rowExpandable: () => !0
27192
27199
  },
27193
27200
  locale: { emptyText: /* @__PURE__ */ X(zn, {
@@ -27220,7 +27227,7 @@ function DS() {
27220
27227
  /* @__PURE__ */ X(nr, {
27221
27228
  rowKey: "key",
27222
27229
  dataSource: m,
27223
- columns: ye,
27230
+ columns: ve,
27224
27231
  pagination: !1,
27225
27232
  size: "small",
27226
27233
  className: "fg-table",
@@ -27242,15 +27249,15 @@ function DS() {
27242
27249
  ...f[S.key] ?? {}
27243
27250
  } : null,
27244
27251
  onClose: () => C(null),
27245
- onSave: de
27252
+ onSave: ue
27246
27253
  }, S?.key ?? "field-closed"),
27247
27254
  /* @__PURE__ */ X(CS, {
27248
27255
  open: !!w,
27249
27256
  merge: w?.merge,
27250
- fieldOptions: le,
27257
+ fieldOptions: ce,
27251
27258
  groupOptions: u,
27252
27259
  onClose: () => T(null),
27253
- onSave: pe
27260
+ onSave: fe
27254
27261
  }, w ? `merge-${w.index ?? "new"}` : "merge-closed"),
27255
27262
  /* @__PURE__ */ X(ES, {
27256
27263
  open: O,
@@ -27270,7 +27277,7 @@ function DS() {
27270
27277
  confirmLabel: ee?.confirmLabel,
27271
27278
  danger: ee?.danger,
27272
27279
  onCancel: () => A(null),
27273
- onVerified: ce
27280
+ onVerified: se
27274
27281
  })
27275
27282
  ]
27276
27283
  });
@@ -27908,7 +27915,7 @@ function eC() {
27908
27915
  t([]);
27909
27916
  });
27910
27917
  }, []), F(() => {
27911
- Promise.all([Me().catch(() => []), ye().catch(() => [])]).then(([e, t]) => {
27918
+ Promise.all([Me().catch(() => []), ve().catch(() => [])]).then(([e, t]) => {
27912
27919
  A([...new Set(e.map((e) => e.MENUNAME ?? e.menuName).filter(Boolean))]), ne([...new Set(t.map((e) => e.permissionKey ?? e.PERMISSIONKEY).filter(Boolean))]);
27913
27920
  });
27914
27921
  }, []);
@@ -27968,14 +27975,14 @@ function eC() {
27968
27975
  } catch (e) {
27969
27976
  q.error(e.message);
27970
27977
  }
27971
- }, [ie, N] = L(null), ae = (e = null) => {
27972
- N(typeof e == "string" ? e : null), x(null), y(!0);
27973
- }, oe = (e, t = null) => {
27974
- N(t), x(e), y(!0);
27975
- }, se = async (e) => {
27978
+ }, [N, P] = L(null), ie = (e = null) => {
27979
+ P(typeof e == "string" ? e : null), x(null), y(!0);
27980
+ }, ae = (e, t = null) => {
27981
+ P(t), x(e), y(!0);
27982
+ }, oe = async (e) => {
27976
27983
  let t;
27977
- t = ie ? c.map((t) => {
27978
- if (t.key !== ie) return t;
27984
+ t = N ? c.map((t) => {
27985
+ if (t.key !== N) return t;
27979
27986
  let n = t.children ?? [], r = b ? n.map((t) => t.key === b.key ? {
27980
27987
  ...t,
27981
27988
  ...e
@@ -28013,24 +28020,24 @@ function eC() {
28013
28020
  } catch (e) {
28014
28021
  q.error(e.message), String(e.message ?? "").toLowerCase().includes("already exists") && j();
28015
28022
  }
28016
- }, ce = (e, t = null) => {
28023
+ }, se = (e, t = null) => {
28017
28024
  l(t ? (n) => n.map((n) => n.key === t ? {
28018
28025
  ...n,
28019
28026
  children: (n.children ?? []).filter((t) => t.key !== e)
28020
28027
  } : n) : (t) => t.filter((t) => t.key !== e)), d(!0);
28021
- }, le = (e, t) => {
28028
+ }, ce = (e, t) => {
28022
28029
  l((n) => {
28023
28030
  let r = [...n], i = e + t;
28024
28031
  return i < 0 || i >= r.length ? n : ([r[e], r[i]] = [r[i], r[e]], r);
28025
28032
  }), d(!0);
28026
28033
  };
28027
- function ue(e) {
28034
+ function le(e) {
28028
28035
  D(WS[e]);
28029
28036
  }
28030
- function de() {
28037
+ function ue() {
28031
28038
  D(null), j();
28032
28039
  }
28033
- let fe = I(() => {
28040
+ let de = I(() => {
28034
28041
  let e = O.trim().toLowerCase();
28035
28042
  return e ? c.filter((t) => [
28036
28043
  t.label,
@@ -28041,7 +28048,7 @@ function eC() {
28041
28048
  t.apiPath,
28042
28049
  t.permissionKey
28043
28050
  ].some((t) => String(t ?? "").toLowerCase().includes(e))) : c;
28044
- }, [c, O]), pe = [
28051
+ }, [c, O]), fe = [
28045
28052
  {
28046
28053
  title: "Order",
28047
28054
  key: "order",
@@ -28050,13 +28057,13 @@ function eC() {
28050
28057
  size: "small",
28051
28058
  type: "text",
28052
28059
  disabled: t._actionIndex === 0,
28053
- onClick: () => le(t._actionIndex, -1),
28060
+ onClick: () => ce(t._actionIndex, -1),
28054
28061
  children: "↑"
28055
28062
  }), /* @__PURE__ */ X(R, {
28056
28063
  size: "small",
28057
28064
  type: "text",
28058
28065
  disabled: t._actionIndex === c.length - 1,
28059
- onClick: () => le(t._actionIndex, 1),
28066
+ onClick: () => ce(t._actionIndex, 1),
28060
28067
  children: "↓"
28061
28068
  })] })
28062
28069
  },
@@ -28147,7 +28154,7 @@ function eC() {
28147
28154
  size: "small",
28148
28155
  type: "text",
28149
28156
  icon: /* @__PURE__ */ X(J, {}),
28150
- onClick: () => ae(t.key)
28157
+ onClick: () => ie(t.key)
28151
28158
  })
28152
28159
  }),
28153
28160
  /* @__PURE__ */ X(K, {
@@ -28156,12 +28163,12 @@ function eC() {
28156
28163
  size: "small",
28157
28164
  type: "text",
28158
28165
  icon: /* @__PURE__ */ X(Br, {}),
28159
- onClick: () => oe(t)
28166
+ onClick: () => ae(t)
28160
28167
  })
28161
28168
  }),
28162
28169
  /* @__PURE__ */ X(qn, {
28163
28170
  title: "Remove this action?",
28164
- onConfirm: () => ce(t.key),
28171
+ onConfirm: () => se(t.key),
28165
28172
  okText: "Remove",
28166
28173
  okType: "danger",
28167
28174
  children: /* @__PURE__ */ X(K, {
@@ -28176,7 +28183,7 @@ function eC() {
28176
28183
  })
28177
28184
  ] })
28178
28185
  }
28179
- ], me = (e) => [
28186
+ ], pe = (e) => [
28180
28187
  {
28181
28188
  title: "Action",
28182
28189
  key: "identity",
@@ -28235,11 +28242,11 @@ function eC() {
28235
28242
  size: "small",
28236
28243
  type: "text",
28237
28244
  icon: /* @__PURE__ */ X(Br, {}),
28238
- onClick: () => oe(n, e)
28245
+ onClick: () => ae(n, e)
28239
28246
  })
28240
28247
  }), /* @__PURE__ */ X(qn, {
28241
28248
  title: "Remove this child action?",
28242
- onConfirm: () => ce(n.key, e),
28249
+ onConfirm: () => se(n.key, e),
28243
28250
  okText: "Remove",
28244
28251
  okType: "danger",
28245
28252
  children: /* @__PURE__ */ X(K, {
@@ -28267,13 +28274,13 @@ function eC() {
28267
28274
  key: "save",
28268
28275
  label: "Save current as default",
28269
28276
  icon: /* @__PURE__ */ X(Oi, {}),
28270
- onClick: () => ue("save")
28277
+ onClick: () => le("save")
28271
28278
  },
28272
28279
  {
28273
28280
  key: "restore",
28274
28281
  label: "Restore saved default",
28275
28282
  icon: /* @__PURE__ */ X(kr, {}),
28276
- onClick: () => ue("restore")
28283
+ onClick: () => le("restore")
28277
28284
  },
28278
28285
  { type: "divider" },
28279
28286
  {
@@ -28281,7 +28288,7 @@ function eC() {
28281
28288
  label: "Reset all actions",
28282
28289
  icon: /* @__PURE__ */ X(Si, {}),
28283
28290
  danger: !0,
28284
- onClick: () => ue("reset")
28291
+ onClick: () => le("reset")
28285
28292
  }
28286
28293
  ] },
28287
28294
  children: /* @__PURE__ */ X(R, {
@@ -28384,7 +28391,7 @@ function eC() {
28384
28391
  }),
28385
28392
  /* @__PURE__ */ X(R, {
28386
28393
  icon: /* @__PURE__ */ X(J, {}),
28387
- onClick: () => ae(),
28394
+ onClick: () => ie(),
28388
28395
  children: "New action"
28389
28396
  }),
28390
28397
  /* @__PURE__ */ X(R, {
@@ -28412,13 +28419,13 @@ function eC() {
28412
28419
  }), /* @__PURE__ */ X($n, {
28413
28420
  spinning: f,
28414
28421
  children: /* @__PURE__ */ X(nr, {
28415
- dataSource: fe.map((e, t) => ({
28422
+ dataSource: de.map((e, t) => ({
28416
28423
  ...e,
28417
28424
  _actionIndex: c.indexOf(e),
28418
28425
  _rowKey: e.key || e._localKey || t
28419
28426
  })),
28420
28427
  rowKey: "_rowKey",
28421
- columns: pe,
28428
+ columns: fe,
28422
28429
  pagination: !1,
28423
28430
  size: "small",
28424
28431
  className: "fg-table admin-config-table",
@@ -28432,7 +28439,7 @@ function eC() {
28432
28439
  _rowKey: e.key || e._localKey || t
28433
28440
  })),
28434
28441
  rowKey: "_rowKey",
28435
- columns: me(e.key),
28442
+ columns: pe(e.key),
28436
28443
  pagination: !1,
28437
28444
  size: "small",
28438
28445
  className: "fg-table admin-config-table",
@@ -28445,13 +28452,13 @@ function eC() {
28445
28452
  /* @__PURE__ */ X($S, {
28446
28453
  open: v,
28447
28454
  initial: b,
28448
- isChild: !!ie,
28455
+ isChild: !!N,
28449
28456
  popupForms: S,
28450
28457
  templateOptions: w,
28451
28458
  permissionModules: ee,
28452
28459
  permissionActions: te,
28453
28460
  onClose: () => y(!1),
28454
- onSave: se
28461
+ onSave: oe
28455
28462
  }),
28456
28463
  /* @__PURE__ */ X(Ex, {
28457
28464
  open: !!E,
@@ -28462,7 +28469,7 @@ function eC() {
28462
28469
  confirmLabel: E?.confirmLabel,
28463
28470
  danger: E?.danger,
28464
28471
  onCancel: () => D(null),
28465
- onVerified: de
28472
+ onVerified: ue
28466
28473
  })
28467
28474
  ]
28468
28475
  });
@@ -31539,7 +31546,7 @@ function VC() {
31539
31546
  children: "top"
31540
31547
  })
31541
31548
  }
31542
- ], ie = [
31549
+ ], N = [
31543
31550
  {
31544
31551
  title: "Target",
31545
31552
  key: "target",
@@ -31577,7 +31584,7 @@ function VC() {
31577
31584
  children: "Insert if missing"
31578
31585
  }) : /* @__PURE__ */ X(G, { children: "Update" })
31579
31586
  }
31580
- ], N = e.map((e) => ({
31587
+ ], P = e.map((e) => ({
31581
31588
  key: e.key,
31582
31589
  label: e.label
31583
31590
  }));
@@ -31610,7 +31617,7 @@ function VC() {
31610
31617
  /* @__PURE__ */ X(rr, {
31611
31618
  activeKey: i,
31612
31619
  onChange: a,
31613
- items: N.map((e) => ({
31620
+ items: P.map((e) => ({
31614
31621
  ...e,
31615
31622
  children: null
31616
31623
  })),
@@ -32029,7 +32036,7 @@ function VC() {
32029
32036
  title: "Related Updates",
32030
32037
  description: "Best-effort side-effect writes to other collections after a successful insert — board state, activity logs. Combine with ForEach + a Hierarchy Expansion to seed one document per user in a chain.",
32031
32038
  rules: u.relatedUpdates ?? [],
32032
- columns: ie,
32039
+ columns: N,
32033
32040
  onAdd: () => D({
32034
32041
  index: null,
32035
32042
  rule: null
@@ -32809,7 +32816,7 @@ function tw({ open: e, record: t, onClose: n, onSaved: r }) {
32809
32816
  return;
32810
32817
  }
32811
32818
  u(!0), d.current = setTimeout(() => {
32812
- se(e.trim()).then(c).catch(() => c([])).finally(() => u(!1));
32819
+ oe(e.trim()).then(c).catch(() => c([])).finally(() => u(!1));
32813
32820
  }, 350);
32814
32821
  }
32815
32822
  async function m() {
@@ -33404,35 +33411,35 @@ function Cw({ title: e, description: t, selectedName: n, loading: r, saving: i,
33404
33411
  });
33405
33412
  }
33406
33413
  function ww({ onLogout: e }) {
33407
- let [t] = B.useForm(), [n] = B.useForm(), [r, i] = L("users"), [a, o] = L(!0), [s, c] = L(!1), [l, u] = L(!1), [f, p] = L([]), [m, h] = L([]), [g, _] = L([]), [v, y] = L([]), [b, x] = L(null), [S, C] = L([]), [w, T] = L(!1), [E, D] = L(null), [O, k] = L(!1), [ee, A] = L(null), [te, ne] = L(!1), [j, M] = L(null), [re, ie] = L(!1), [N, ae] = L(null), [oe, se] = L("listView"), [ce, le] = L([]), [ue, de] = L([]), [fe, pe] = L(!1), [me, he] = L(!1), ge = d(), _e = I(() => ce.filter((e) => !e.disabled), [ce]), ve = !fe && _e.length === 0, ye = Tn(async () => {
33408
- pe(!0);
33414
+ let [t] = B.useForm(), [n] = B.useForm(), [r, i] = L("users"), [a, o] = L(!0), [s, c] = L(!1), [l, u] = L(!1), [f, p] = L([]), [m, h] = L([]), [g, _] = L([]), [v, y] = L([]), [b, x] = L(null), [S, C] = L([]), [w, T] = L(!1), [E, D] = L(null), [O, k] = L(!1), [ee, A] = L(null), [te, ne] = L(!1), [j, M] = L(null), [re, N] = L(!1), [P, ie] = L(null), [ae, oe] = L("listView"), [se, ce] = L([]), [le, ue] = L([]), [de, fe] = L(!1), [pe, me] = L(!1), he = d(), ge = I(() => se.filter((e) => !e.disabled), [se]), _e = !de && ge.length === 0, ve = Tn(async () => {
33415
+ fe(!0);
33409
33416
  try {
33410
33417
  let [e, t] = await Promise.all([Oe(), Ee()]), n = _w(e.modules, t), r = new Set(n.filter((e) => !e.disabled).map((e) => e.value));
33411
- le(n), de((e) => e.filter((e) => r.has(e)));
33418
+ ce(n), ue((e) => e.filter((e) => r.has(e)));
33412
33419
  } catch {
33413
33420
  q.error("Failed to load seed status");
33414
33421
  } finally {
33415
- pe(!1);
33422
+ fe(!1);
33416
33423
  }
33417
33424
  }, []);
33418
33425
  F(() => {
33419
- ye();
33420
- }, [ye]);
33421
- async function be() {
33422
- if (ue.length === 0) {
33423
- q.warning(ve ? "All modules already seeded." : "Select at least one module to seed.");
33426
+ ve();
33427
+ }, [ve]);
33428
+ async function ye() {
33429
+ if (le.length === 0) {
33430
+ q.warning(_e ? "All modules already seeded." : "Select at least one module to seed.");
33424
33431
  return;
33425
33432
  }
33426
- he(!0);
33433
+ me(!0);
33427
33434
  try {
33428
- await $t(ue), q.success("User type field config seeded"), de([]), await ye();
33435
+ await $t(le), q.success("User type field config seeded"), ue([]), await ve();
33429
33436
  } catch (e) {
33430
33437
  q.error(e?.message || "Seed failed");
33431
33438
  } finally {
33432
- he(!1);
33439
+ me(!1);
33433
33440
  }
33434
33441
  }
33435
- async function P() {
33442
+ async function be() {
33436
33443
  o(!0);
33437
33444
  try {
33438
33445
  let [e, t, n, r] = await Promise.allSettled([
@@ -33450,7 +33457,7 @@ function ww({ onLogout: e }) {
33450
33457
  }
33451
33458
  F(() => {
33452
33459
  queueMicrotask(() => {
33453
- P();
33460
+ be();
33454
33461
  });
33455
33462
  }, []), F(() => {
33456
33463
  queueMicrotask(() => {
@@ -33604,7 +33611,7 @@ function ww({ onLogout: e }) {
33604
33611
  permission_id: e.permissionId,
33605
33612
  permission_key: e.permissionKey,
33606
33613
  access_value: e.accessValue,
33607
- updated_by: ge?.userId ?? null
33614
+ updated_by: he?.userId ?? null
33608
33615
  }))), q.success("Role permissions updated");
33609
33616
  } catch (e) {
33610
33617
  q.error(e.message || "Unable to save role permissions");
@@ -33638,10 +33645,10 @@ function ww({ onLogout: e }) {
33638
33645
  let t = {
33639
33646
  ...e,
33640
33647
  status: e.status === 1 || e.status === "1" || e.status === !0 ? "ACTIVE" : e.status === 0 || e.status === "0" || e.status === !1 ? "INACTIVE" : String(e.status ?? "ACTIVE").toUpperCase(),
33641
- updated_by: ge?.userId ?? null,
33642
- created_by: ge?.userId ?? null
33648
+ updated_by: he?.userId ?? null,
33649
+ created_by: he?.userId ?? null
33643
33650
  };
33644
- t.password || delete t.password, E ? (await Pb(E.user_id, t), q.success("User updated")) : (await Nb(t), q.success("User created")), T(!1), D(null), await P();
33651
+ t.password || delete t.password, E ? (await Pb(E.user_id, t), q.success("User updated")) : (await Nb(t), q.success("User created")), T(!1), D(null), await be();
33645
33652
  } catch (e) {
33646
33653
  q.error(e.message || "Unable to save user");
33647
33654
  } finally {
@@ -33651,7 +33658,7 @@ function ww({ onLogout: e }) {
33651
33658
  async function Ie(e) {
33652
33659
  A(e);
33653
33660
  try {
33654
- await Fb(e), q.success("User deleted"), await P();
33661
+ await Fb(e), q.success("User deleted"), await be();
33655
33662
  } catch (e) {
33656
33663
  q.error(e.message || "Unable to delete user");
33657
33664
  } finally {
@@ -33659,7 +33666,7 @@ function ww({ onLogout: e }) {
33659
33666
  }
33660
33667
  }
33661
33668
  function Le(e, t) {
33662
- se("listView"), ae({
33669
+ oe("listView"), ie({
33663
33670
  kind: e,
33664
33671
  record: t
33665
33672
  }), e === "role" && x(t.user_type_id);
@@ -33680,9 +33687,9 @@ function ww({ onLogout: e }) {
33680
33687
  M(e), ne(!0), n.setFieldsValue(e);
33681
33688
  }
33682
33689
  async function Ve(e) {
33683
- ie(!0);
33690
+ N(!0);
33684
33691
  try {
33685
- let t = ge?.userId ?? null, n = !!j, r = n ? await Rb(j.user_type_id, {
33692
+ let t = he?.userId ?? null, n = !!j, r = n ? await Rb(j.user_type_id, {
33686
33693
  ...e,
33687
33694
  updated_by: t
33688
33695
  }) : await Lb({
@@ -33690,7 +33697,7 @@ function ww({ onLogout: e }) {
33690
33697
  created_by: t,
33691
33698
  visible_menu_ids: []
33692
33699
  }), i = r.user_type_id;
33693
- q.success(n ? "User type updated" : "User type created. Customize its menus and permissions."), ne(!1), await P(), x(i), n || (se("permissions"), ae({
33700
+ q.success(n ? "User type updated" : "User type created. Customize its menus and permissions."), ne(!1), await be(), x(i), n || (oe("permissions"), ie({
33694
33701
  kind: "role",
33695
33702
  record: {
33696
33703
  ...e,
@@ -33702,12 +33709,12 @@ function ww({ onLogout: e }) {
33702
33709
  } catch (e) {
33703
33710
  q.error(e.message || "Unable to save role");
33704
33711
  } finally {
33705
- ie(!1);
33712
+ N(!1);
33706
33713
  }
33707
33714
  }
33708
33715
  async function He(e) {
33709
33716
  try {
33710
- await zb(e), q.success("Role deleted"), await P();
33717
+ await zb(e), q.success("Role deleted"), await be();
33711
33718
  } catch (e) {
33712
33719
  q.error(e.message || "Unable to delete role");
33713
33720
  }
@@ -33858,19 +33865,19 @@ function ww({ onLogout: e }) {
33858
33865
  mode: "multiple",
33859
33866
  allowClear: !0,
33860
33867
  showSearch: !0,
33861
- value: ue,
33862
- options: ce,
33863
- placeholder: ve ? "All modules already seeded" : "Select modules or collections to seed",
33864
- disabled: fe || me || ve,
33865
- loading: fe,
33866
- onChange: de,
33868
+ value: le,
33869
+ options: se,
33870
+ placeholder: _e ? "All modules already seeded" : "Select modules or collections to seed",
33871
+ disabled: de || pe || _e,
33872
+ loading: de,
33873
+ onChange: ue,
33867
33874
  style: { width: "100%" }
33868
33875
  })
33869
33876
  }), /* @__PURE__ */ X(R, {
33870
33877
  type: "primary",
33871
- loading: me,
33872
- disabled: fe || ue.length === 0,
33873
- onClick: be,
33878
+ loading: pe,
33879
+ disabled: de || le.length === 0,
33880
+ onClick: ye,
33874
33881
  children: "Seed Field Config"
33875
33882
  })]
33876
33883
  }), /* @__PURE__ */ X(dw, {
@@ -33880,7 +33887,7 @@ function ww({ onLogout: e }) {
33880
33887
  marginTop: 8,
33881
33888
  fontSize: 12
33882
33889
  },
33883
- children: ve ? "Seed is disabled because all configured modules already have user type field config data." : "Already seeded modules are disabled. New modules or collections can still be seeded."
33890
+ children: _e ? "Seed is disabled because all configured modules already have user type field config data." : "Already seeded modules are disabled. New modules or collections can still be seeded."
33884
33891
  })]
33885
33892
  }), /* @__PURE__ */ Z("section", {
33886
33893
  className: "admin-section",
@@ -34023,9 +34030,9 @@ function ww({ onLogout: e }) {
34023
34030
  }) }),
34024
34031
  /* @__PURE__ */ Z(Gn, {
34025
34032
  className: "uss-modal",
34026
- title: `Configure User Type: ${N?.record?.user_type_name ?? ""}`,
34027
- open: !!N,
34028
- onCancel: () => ae(null),
34033
+ title: `Configure User Type: ${P?.record?.user_type_name ?? ""}`,
34034
+ open: !!P,
34035
+ onCancel: () => ie(null),
34029
34036
  footer: null,
34030
34037
  destroyOnHidden: !0,
34031
34038
  width: 900,
@@ -34055,11 +34062,11 @@ function ww({ onLogout: e }) {
34055
34062
  }
34056
34063
  ].map((e) => /* @__PURE__ */ X("button", {
34057
34064
  type: "button",
34058
- className: `uss-config-btn${oe === e.key ? " active" : ""}`,
34059
- onClick: () => se(e.key),
34065
+ className: `uss-config-btn${ae === e.key ? " active" : ""}`,
34066
+ onClick: () => oe(e.key),
34060
34067
  children: e.label
34061
34068
  }, e.key))
34062
- }), N && oe === "permissions" ? /* @__PURE__ */ X(Cw, {
34069
+ }), P && ae === "permissions" ? /* @__PURE__ */ X(Cw, {
34063
34070
  title: "Role Permissions",
34064
34071
  description: "Configure menu permissions for this user type",
34065
34072
  selectedName: xe?.user_type_name,
@@ -34069,22 +34076,22 @@ function ww({ onLogout: e }) {
34069
34076
  onChange: je,
34070
34077
  onMove: Re,
34071
34078
  onSave: Me
34072
- }) : N && oe === "actions" ? /* @__PURE__ */ X(Cx, { role: {
34073
- ...N.record,
34074
- roleId: N.record.user_type_id,
34075
- roleName: N.record.user_type_name
34076
- } }, `${N.record?.user_type_id}-actions`) : N && oe === "form" ? /* @__PURE__ */ X(vx, { role: {
34077
- ...N.record,
34078
- roleId: N.record.user_type_id,
34079
- roleName: N.record.user_type_name
34080
- } }, `${N.record?.user_type_id}-form`) : N ? /* @__PURE__ */ X(dx, {
34079
+ }) : P && ae === "actions" ? /* @__PURE__ */ X(Cx, { role: {
34080
+ ...P.record,
34081
+ roleId: P.record.user_type_id,
34082
+ roleName: P.record.user_type_name
34083
+ } }, `${P.record?.user_type_id}-actions`) : P && ae === "form" ? /* @__PURE__ */ X(vx, { role: {
34084
+ ...P.record,
34085
+ roleId: P.record.user_type_id,
34086
+ roleName: P.record.user_type_name
34087
+ } }, `${P.record?.user_type_id}-form`) : P ? /* @__PURE__ */ X(dx, {
34081
34088
  role: {
34082
- ...N.record,
34083
- roleId: N.record.user_type_id,
34084
- roleName: N.record.user_type_name
34089
+ ...P.record,
34090
+ roleId: P.record.user_type_id,
34091
+ roleName: P.record.user_type_name
34085
34092
  },
34086
- configType: oe
34087
- }, `${N.record?.user_type_id}-${oe}`) : null]
34093
+ configType: ae
34094
+ }, `${P.record?.user_type_id}-${ae}`) : null]
34088
34095
  }),
34089
34096
  /* @__PURE__ */ X(Gn, {
34090
34097
  className: "admin-role-modal",
@@ -35644,7 +35651,7 @@ function JT({ form: e, fields: t, initialValues: n, dynamicOptions: r, popupCont
35644
35651
  }), typeof e.validator == "function" && l.push({ validator: (t, n) => {
35645
35652
  let r = e.validator(n, i);
35646
35653
  return r ? Promise.reject(Error(r)) : Promise.resolve();
35647
- } }), qT.has(e.type) && l.push(ge({
35654
+ } }), qT.has(e.type) && l.push(he({
35648
35655
  label: e.label,
35649
35656
  field: e.name,
35650
35657
  type: e.type
@@ -35928,13 +35935,13 @@ function nE({ open: e = !0, config: t, context: n = {}, onClose: r, onSubmit: i,
35928
35935
  F(() => {
35929
35936
  !e || !ee || E();
35930
35937
  }, [e, ee]);
35931
- let A = p.length, te = String(h).replace(/s$/i, ""), ne = A === 1 ? te : h, j = m[0] ?? {}, M = t?.getTitleText ? t.getTitleText(A, ne, j, f) : t?.title, re = A === 1 ? j.jobTitle ?? j.title ?? j.name ?? j.fullName ?? j.candidateName ?? null : null, ie = t?.getBodyText ? t.getBodyText(A, te, ne, re, f) : t?.bodyText ?? null, N = typeof t?.getNote == "function" ? t.getNote(f) : t?.note, ae = _.filter((e) => e.required).every((e) => {
35938
+ let A = p.length, te = String(h).replace(/s$/i, ""), ne = A === 1 ? te : h, j = m[0] ?? {}, M = t?.getTitleText ? t.getTitleText(A, ne, j, f) : t?.title, re = A === 1 ? j.jobTitle ?? j.title ?? j.name ?? j.fullName ?? j.candidateName ?? null : null, N = t?.getBodyText ? t.getBodyText(A, te, ne, re, f) : t?.bodyText ?? null, P = typeof t?.getNote == "function" ? t.getNote(f) : t?.note, ie = _.filter((e) => e.required).every((e) => {
35932
35939
  let t = d[e.name];
35933
35940
  return !(t == null || t === "" || Array.isArray(t) && t.length === 0 || typeof t == "object" && !Array.isArray(t) && Object.keys(t).length === 0);
35934
- }), oe = t?.disabledUntilFilled && !ae;
35941
+ }), ae = t?.disabledUntilFilled && !ie;
35935
35942
  if (!t || !e || ee) return null;
35936
- let se = t.component;
35937
- return se ? /* @__PURE__ */ X(Gn, {
35943
+ let oe = t.component;
35944
+ return oe ? /* @__PURE__ */ X(Gn, {
35938
35945
  open: e,
35939
35946
  title: t.title || t.getTitleText ? /* @__PURE__ */ X(xT, {
35940
35947
  titleText: M,
@@ -35946,7 +35953,7 @@ function nE({ open: e = !0, config: t, context: n = {}, onClose: r, onSubmit: i,
35946
35953
  maskClosable: !1,
35947
35954
  onCancel: () => T(),
35948
35955
  className: `dynamic-popup${t.className ? ` ${t.className}` : ""}`,
35949
- children: /* @__PURE__ */ X(se, {
35956
+ children: /* @__PURE__ */ X(oe, {
35950
35957
  context: f,
35951
35958
  selectedIds: g,
35952
35959
  selectedRecords: m,
@@ -35965,7 +35972,7 @@ function nE({ open: e = !0, config: t, context: n = {}, onClose: r, onSubmit: i,
35965
35972
  onCancel: () => T(),
35966
35973
  okButtonProps: {
35967
35974
  danger: t.okButtonDanger,
35968
- disabled: oe,
35975
+ disabled: ae,
35969
35976
  loading: D
35970
35977
  },
35971
35978
  cancelButtonProps: { disabled: D },
@@ -35976,12 +35983,12 @@ function nE({ open: e = !0, config: t, context: n = {}, onClose: r, onSubmit: i,
35976
35983
  className: `dynamic-popup${t.className ? ` ${t.className}` : ""}`,
35977
35984
  children: [
35978
35985
  /* @__PURE__ */ X(ST, {
35979
- note: N,
35986
+ note: P,
35980
35987
  description: t.description,
35981
35988
  showSelectedCount: t.showSelectedCount,
35982
35989
  count: A,
35983
35990
  itemLabel: ne,
35984
- bodyText: ie,
35991
+ bodyText: N,
35985
35992
  deleteError: O
35986
35993
  }),
35987
35994
  /* @__PURE__ */ X(CT, { footerNote: t.footerNote }),
@@ -36997,12 +37004,12 @@ function nD() {
36997
37004
  bcc: kw(e.bcc).filter((e) => !t.has(e)).join(", ")
36998
37005
  });
36999
37006
  }
37000
- let ie = (kw(M.to).length || kw(M.bcc).length) && Aw(M.to) && Aw(M.cc) && Aw(M.bcc) && M.subject.trim(), N = (e) => e === "myVendor" ? b : S;
37001
- function ae() {
37007
+ let N = (kw(M.to).length || kw(M.bcc).length) && Aw(M.to) && Aw(M.cc) && Aw(M.bcc) && M.subject.trim(), P = (e) => e === "myVendor" ? b : S;
37008
+ function ie() {
37002
37009
  e(-1);
37003
37010
  }
37004
- function oe() {
37005
- ie && eD.submit({
37011
+ function ae() {
37012
+ N && eD.submit({
37006
37013
  jobId: l,
37007
37014
  toMail: kw(M.to),
37008
37015
  ccMail: kw(M.cc),
@@ -37019,7 +37026,7 @@ function nD() {
37019
37026
  q.error(e?.message || "Failed to send mail. Please try again.");
37020
37027
  });
37021
37028
  }
37022
- let se = I(() => {
37029
+ let oe = I(() => {
37023
37030
  if (!g) return v;
37024
37031
  let e = g.toLowerCase();
37025
37032
  return v.filter((t) => (t.vendorName ?? "").toLowerCase().includes(e) || (t.vendorEmail ?? "").toLowerCase().includes(e) || (t.vendorLocation ?? "").toLowerCase().includes(e));
@@ -37027,19 +37034,19 @@ function nD() {
37027
37034
  return /* @__PURE__ */ X(Ln, {
37028
37035
  open: !0,
37029
37036
  placement: "right",
37030
- onClose: ae,
37037
+ onClose: ie,
37031
37038
  closable: !1,
37032
37039
  rootClassName: "vendor-share",
37033
37040
  width: "95%",
37034
37041
  footer: /* @__PURE__ */ Z("div", {
37035
37042
  className: "vendor-share__footer",
37036
37043
  children: [/* @__PURE__ */ X(R, {
37037
- onClick: ae,
37044
+ onClick: ie,
37038
37045
  children: "Cancel"
37039
37046
  }), /* @__PURE__ */ X(R, {
37040
37047
  type: "primary",
37041
- disabled: !ie,
37042
- onClick: oe,
37048
+ disabled: !N,
37049
+ onClick: ae,
37043
37050
  children: "Send"
37044
37051
  })]
37045
37052
  }),
@@ -37056,7 +37063,7 @@ function nD() {
37056
37063
  /* @__PURE__ */ X(R, {
37057
37064
  type: "text",
37058
37065
  icon: /* @__PURE__ */ X(Or, {}),
37059
- onClick: ae,
37066
+ onClick: ie,
37060
37067
  size: "small",
37061
37068
  style: { marginRight: 8 }
37062
37069
  }),
@@ -37091,7 +37098,7 @@ function nD() {
37091
37098
  children: [
37092
37099
  e.label,
37093
37100
  " (",
37094
- N(e.key),
37101
+ P(e.key),
37095
37102
  ")"
37096
37103
  ]
37097
37104
  }, e.key))
@@ -37102,7 +37109,7 @@ function nD() {
37102
37109
  children: /* @__PURE__ */ X(nr, {
37103
37110
  rowKey: (e) => e.vendorId,
37104
37111
  columns: tD,
37105
- dataSource: se,
37112
+ dataSource: oe,
37106
37113
  loading: ee,
37107
37114
  pagination: !1,
37108
37115
  size: "small",
@@ -37742,7 +37749,7 @@ function bD() {
37742
37749
  let [e, t] = L([]), [n, r] = L(0), [i, a] = L(!1), [o, s] = L(1), [c, l] = L(10), [u, d] = L(""), f = Tn(async ({ offset: e, limit: n, searchQuery: i } = {}) => {
37743
37750
  a(!0);
37744
37751
  try {
37745
- let a = await ae({
37752
+ let a = await ie({
37746
37753
  offset: e,
37747
37754
  limit: n,
37748
37755
  searchQuery: i ?? ""
@@ -38304,9 +38311,9 @@ function FD({ menuName: e, menuData: t, permKeys: n, onChange: r, displayName: i
38304
38311
  });
38305
38312
  }
38306
38313
  function ID({ role: e, moduleLabels: t = {}, actionLabels: n = {}, onModuleLabelSave: r = () => {}, onActionLabelSave: i = () => {} }) {
38307
- let [a, o] = L({}), [s, c] = L({}), [l, u] = L(!1), [d, f] = L(!1), [p, m] = L(!1), h = _e(e);
38314
+ let [a, o] = L({}), [s, c] = L({}), [l, u] = L(!1), [d, f] = L(!1), [p, m] = L(!1), h = ge(e);
38308
38315
  F(() => {
38309
- h && (u(!0), m(!1), he(h).then((e) => {
38316
+ h && (u(!0), m(!1), me(h).then((e) => {
38310
38317
  o(e), c(e);
38311
38318
  }).catch(() => q.error("Failed to load permissions")).finally(() => u(!1)));
38312
38319
  }, [h]);
@@ -38717,7 +38724,7 @@ function YD({ open: e, onClose: t }) {
38717
38724
  async function C() {
38718
38725
  h(!0);
38719
38726
  try {
38720
- p(await ye());
38727
+ p(await ve());
38721
38728
  } catch {
38722
38729
  q.error("Failed to load actions");
38723
38730
  } finally {
@@ -40216,7 +40223,7 @@ function EO() {
40216
40223
  behavior: "smooth",
40217
40224
  block: "center"
40218
40225
  });
40219
- }, []), ie = [
40226
+ }, []), N = [
40220
40227
  "bulk-dropzone",
40221
40228
  u ? "bulk-dropzone-dragging" : "",
40222
40229
  f ? "bulk-dropzone-has-file" : "",
@@ -40301,7 +40308,7 @@ function EO() {
40301
40308
  }),
40302
40309
  /* @__PURE__ */ Z("button", {
40303
40310
  type: "button",
40304
- className: ie,
40311
+ className: N,
40305
40312
  disabled: !O,
40306
40313
  onClick: () => n.current?.click(),
40307
40314
  onDragOver: (e) => {
@@ -40705,7 +40712,7 @@ function RO() {
40705
40712
  flow: NO(t),
40706
40713
  step_order: void 0
40707
40714
  });
40708
- }, ie = (e) => {
40715
+ }, N = (e) => {
40709
40716
  let n = jO[e];
40710
40717
  p({
40711
40718
  open: !0,
@@ -40714,18 +40721,18 @@ function RO() {
40714
40721
  name: "",
40715
40722
  type: n.label
40716
40723
  });
40717
- }, N = () => {
40724
+ }, P = () => {
40718
40725
  p((e) => ({
40719
40726
  ...e,
40720
40727
  open: !1
40721
40728
  })), t.resetFields();
40722
- }, ae = async () => {
40729
+ }, ie = async () => {
40723
40730
  try {
40724
40731
  let n = NO((await t.validateFields()).name), r = await qy({
40725
40732
  name: n,
40726
40733
  type: x.dbName
40727
40734
  });
40728
- k(f.typeKey, r?.items ?? []), e.setFieldsValue({ [x.formField]: n }), q.success(`${x.label} added successfully.`), N();
40735
+ k(f.typeKey, r?.items ?? []), e.setFieldsValue({ [x.formField]: n }), q.success(`${x.label} added successfully.`), P();
40729
40736
  } catch (e) {
40730
40737
  if (e?.errorFields) return;
40731
40738
  console.error("Unable to save testing option:", e), q.error(`Unable to add ${x.label.toLowerCase()}.`);
@@ -40809,7 +40816,7 @@ function RO() {
40809
40816
  "aria-label": "Add module",
40810
40817
  icon: /* @__PURE__ */ X(J, {}),
40811
40818
  style: { marginTop: 30 },
40812
- onClick: () => ie("module")
40819
+ onClick: () => N("module")
40813
40820
  })]
40814
40821
  })
40815
40822
  }),
@@ -40956,9 +40963,9 @@ function RO() {
40956
40963
  open: f.open,
40957
40964
  confirmLoading: m,
40958
40965
  okText: "Add",
40959
- onCancel: N,
40966
+ onCancel: P,
40960
40967
  onOk: () => {
40961
- h(!0), ae();
40968
+ h(!0), ie();
40962
40969
  },
40963
40970
  destroyOnHidden: !0,
40964
40971
  children: /* @__PURE__ */ Z(B, {
@@ -41064,14 +41071,14 @@ function KO(e, t) {
41064
41071
  })));
41065
41072
  }
41066
41073
  function qO() {
41067
- let [e] = B.useForm(), t = ia(), [n] = oa(), r = n.get("edit"), i = !!r, a = I(() => _(), []), [o, s] = L([]), [c, l] = L([]), [u, d] = L([]), [f, p] = L(DO), [m, h] = L({}), [g, v] = L(!1), [y, b] = L(!1), [x, S] = L(!1), [C, w] = L(!1), [T, E] = L(!1), D = B.useWatch("module", e), O = B.useWatch("submodule", e), k = B.useWatch("actions", e), ee = !!D, A = !!O, te = I(() => GO(m, k), [m, k]), ne = I(() => HO(o, "modulename"), [o]), j = I(() => HO(c, "submodulename"), [c]), M = I(() => o.find((e) => e.id === D)?.modulename ?? "", [o, D]), re = I(() => c.find((e) => e.id === O)?.submodulename ?? "", [O, c]), ie = Tn(async () => {
41074
+ let [e] = B.useForm(), t = ia(), [n] = oa(), r = n.get("edit"), i = !!r, a = I(() => _(), []), [o, s] = L([]), [c, l] = L([]), [u, d] = L([]), [f, p] = L(DO), [m, h] = L({}), [g, v] = L(!1), [y, b] = L(!1), [x, S] = L(!1), [C, w] = L(!1), [T, E] = L(!1), D = B.useWatch("module", e), O = B.useWatch("submodule", e), k = B.useWatch("actions", e), ee = !!D, A = !!O, te = I(() => GO(m, k), [m, k]), ne = I(() => HO(o, "modulename"), [o]), j = I(() => HO(c, "submodulename"), [c]), M = I(() => o.find((e) => e.id === D)?.modulename ?? "", [o, D]), re = I(() => c.find((e) => e.id === O)?.submodulename ?? "", [O, c]), N = Tn(async () => {
41068
41075
  try {
41069
41076
  let e = await Jy();
41070
41077
  Array.isArray(e?.options) && e.options.length > 0 && p(e.options), e?.rules && typeof e.rules == "object" && h(e.rules);
41071
41078
  } catch (e) {
41072
41079
  console.error("Unable to load action field rules:", e), q.error("Unable to load action validation rules.");
41073
41080
  }
41074
- }, []), N = Tn(async (e) => {
41081
+ }, []), P = Tn(async (e) => {
41075
41082
  if (!e) {
41076
41083
  s([]);
41077
41084
  return;
@@ -41087,7 +41094,7 @@ function qO() {
41087
41094
  } finally {
41088
41095
  v(!1);
41089
41096
  }
41090
- }, []), ae = Tn(async (e, t) => {
41097
+ }, []), ie = Tn(async (e, t) => {
41091
41098
  if (!e || !t) {
41092
41099
  l([]);
41093
41100
  return;
@@ -41104,7 +41111,7 @@ function qO() {
41104
41111
  } finally {
41105
41112
  b(!1);
41106
41113
  }
41107
- }, []), oe = Tn(async (t, n, r, i = "") => {
41114
+ }, []), ae = Tn(async (t, n, r, i = "") => {
41108
41115
  if (!t || !n || !r) {
41109
41116
  d([]), e.setFieldsValue({ step_order: void 0 });
41110
41117
  return;
@@ -41128,7 +41135,7 @@ function qO() {
41128
41135
  } finally {
41129
41136
  S(!1);
41130
41137
  }
41131
- }, [e]), se = Tn(async (e = "") => {
41138
+ }, [e]), oe = Tn(async (e = "") => {
41132
41139
  if (!(!a?.id || !D || !O)) {
41133
41140
  S(!0);
41134
41141
  try {
@@ -41149,12 +41156,12 @@ function qO() {
41149
41156
  a?.id,
41150
41157
  D,
41151
41158
  O
41152
- ]), ce = Tn(async () => {
41159
+ ]), se = Tn(async () => {
41153
41160
  if (!(!r || !a?.name)) {
41154
41161
  E(!0);
41155
41162
  try {
41156
41163
  let t = await ub(r);
41157
- await ae(a.name, t.module), d((await cb({
41164
+ await ie(a.name, t.module), d((await cb({
41158
41165
  product_parent_ID: t.product_parent_ID,
41159
41166
  module_parent_ID: t.module_parent_ID,
41160
41167
  submodule_parent_ID: t.submodule_parent_ID,
@@ -41180,7 +41187,7 @@ function qO() {
41180
41187
  }, [
41181
41188
  r,
41182
41189
  e,
41183
- ae,
41190
+ ie,
41184
41191
  t,
41185
41192
  a?.name
41186
41193
  ]);
@@ -41190,15 +41197,15 @@ function qO() {
41190
41197
  return;
41191
41198
  }
41192
41199
  Promise.resolve().then(async () => {
41193
- await ie(), await N(a.name), r && await ce();
41200
+ await N(), await P(a.name), r && await se();
41194
41201
  });
41195
41202
  }, [
41196
41203
  a,
41197
41204
  t,
41198
- ie,
41199
41205
  N,
41206
+ P,
41200
41207
  r,
41201
- ce
41208
+ se
41202
41209
  ]), a ? /* @__PURE__ */ Z("main", {
41203
41210
  className: "jobs-list-page",
41204
41211
  children: [/* @__PURE__ */ Z(Qn, {
@@ -41252,7 +41259,7 @@ function qO() {
41252
41259
  value: void 0,
41253
41260
  expected: void 0,
41254
41261
  description: void 0
41255
- }), await oe(o.product_parent_ID, o.module_parent_ID, o.submodule_parent_ID);
41262
+ }), await ae(o.product_parent_ID, o.module_parent_ID, o.submodule_parent_ID);
41256
41263
  } catch (e) {
41257
41264
  console.error("Unable to save test case:", e), q.error(i ? "Unable to update test case." : "Unable to save step.");
41258
41265
  } finally {
@@ -41304,7 +41311,7 @@ function qO() {
41304
41311
  "key",
41305
41312
  "value",
41306
41313
  "expected"
41307
- ]), l([]), d([]), ae(a?.name, n);
41314
+ ]), l([]), d([]), ie(a?.name, n);
41308
41315
  }
41309
41316
  })
41310
41317
  })
@@ -41335,7 +41342,7 @@ function qO() {
41335
41342
  "key",
41336
41343
  "value",
41337
41344
  "expected"
41338
- ]), oe(a?.id, D, t);
41345
+ ]), ae(a?.id, D, t);
41339
41346
  }
41340
41347
  })
41341
41348
  })
@@ -41434,7 +41441,7 @@ function qO() {
41434
41441
  "key",
41435
41442
  "value",
41436
41443
  "expected"
41437
- ]), se(t || "");
41444
+ ]), oe(t || "");
41438
41445
  }
41439
41446
  })
41440
41447
  })
@@ -42299,14 +42306,14 @@ function _k() {
42299
42306
  } finally {
42300
42307
  p(!1);
42301
42308
  }
42302
- }, ie = async () => {
42309
+ }, N = async () => {
42303
42310
  try {
42304
42311
  let e = await Jy();
42305
42312
  Array.isArray(e?.options) && e.options.length > 0 && l(e.options), e?.rules && typeof e.rules == "object" && d(e.rules);
42306
42313
  } catch (e) {
42307
42314
  console.error("Unable to load action field rules:", e), q.error("Unable to load action validation rules.");
42308
42315
  }
42309
- }, N = Tn(async (t) => {
42316
+ }, P = Tn(async (t) => {
42310
42317
  let n = pk(t);
42311
42318
  if (a([]), s([]), e.setFieldsValue({ step_order: void 0 }), n) {
42312
42319
  h(!0);
@@ -42323,7 +42330,7 @@ function _k() {
42323
42330
  h(!1);
42324
42331
  }
42325
42332
  }
42326
- }, [e]), ae = Tn(async (t, n, r) => {
42333
+ }, [e]), ie = Tn(async (t, n, r) => {
42327
42334
  let i = pk(t), a = pk(n);
42328
42335
  if (!i || !a) {
42329
42336
  e.setFieldsValue({ step_order: void 0 });
@@ -42340,19 +42347,19 @@ function _k() {
42340
42347
  }, [e]);
42341
42348
  F(() => {
42342
42349
  Promise.resolve().then(async () => {
42343
- await Promise.all([re(), ie()]);
42350
+ await Promise.all([re(), N()]);
42344
42351
  });
42345
42352
  }, []), F(() => {
42346
- Promise.resolve().then(() => N(D));
42347
- }, [N, D]), F(() => {
42348
- Promise.resolve().then(() => ae(D, O, i));
42353
+ Promise.resolve().then(() => P(D));
42354
+ }, [P, D]), F(() => {
42355
+ Promise.resolve().then(() => ie(D, O, i));
42349
42356
  }, [
42350
42357
  i,
42351
- ae,
42358
+ ie,
42352
42359
  O,
42353
42360
  D
42354
42361
  ]);
42355
- let oe = async (t) => {
42362
+ let ae = async (t) => {
42356
42363
  let n = {
42357
42364
  module: pk(t.module),
42358
42365
  flow: pk(t.flow),
@@ -42373,9 +42380,9 @@ function _k() {
42373
42380
  } finally {
42374
42381
  C(!1);
42375
42382
  }
42376
- }, se = (t, n) => {
42383
+ }, oe = (t, n) => {
42377
42384
  e.setFieldsValue({ [t]: pk(n) });
42378
- }, ce = (t) => {
42385
+ }, se = (t) => {
42379
42386
  e.setFieldsValue({
42380
42387
  module: pk(t),
42381
42388
  flow: void 0,
@@ -42392,7 +42399,7 @@ function _k() {
42392
42399
  "value",
42393
42400
  "expected"
42394
42401
  ]);
42395
- }, le = (t) => {
42402
+ }, ce = (t) => {
42396
42403
  e.setFieldsValue({
42397
42404
  flow: pk(t),
42398
42405
  step_order: void 0,
@@ -42406,7 +42413,7 @@ function _k() {
42406
42413
  "value",
42407
42414
  "expected"
42408
42415
  ]);
42409
- }, ue = (t) => {
42416
+ }, le = (t) => {
42410
42417
  let n = uk(u, t);
42411
42418
  e.setFieldsValue({
42412
42419
  keyword: pk(t),
@@ -42418,7 +42425,7 @@ function _k() {
42418
42425
  "value",
42419
42426
  "expected"
42420
42427
  ]);
42421
- }, de = (e) => {
42428
+ }, ue = (e) => {
42422
42429
  let n = ck[e];
42423
42430
  _({
42424
42431
  open: !0,
@@ -42427,18 +42434,18 @@ function _k() {
42427
42434
  name: "",
42428
42435
  type: n.label
42429
42436
  });
42430
- }, fe = () => {
42437
+ }, de = () => {
42431
42438
  _((e) => ({
42432
42439
  ...e,
42433
42440
  open: !1
42434
42441
  })), t.resetFields();
42435
- }, pe = async () => {
42442
+ }, fe = async () => {
42436
42443
  try {
42437
42444
  let n = pk((await t.validateFields()).name), r = await qy({
42438
42445
  name: n,
42439
42446
  type: T.dbName
42440
42447
  });
42441
- M(g.typeKey, r?.items ?? []), e.setFieldsValue({ [T.formField]: n }), q.success(`${T.label} added successfully.`), fe();
42448
+ M(g.typeKey, r?.items ?? []), e.setFieldsValue({ [T.formField]: n }), q.success(`${T.label} added successfully.`), de();
42442
42449
  } catch (e) {
42443
42450
  if (e?.errorFields) return;
42444
42451
  console.error("Unable to save testing option:", e), q.error(`Unable to add ${T.label.toLowerCase()}.`);
@@ -42484,7 +42491,7 @@ function _k() {
42484
42491
  children: " *"
42485
42492
  })] }),
42486
42493
  initialValues: sk,
42487
- onFinish: oe,
42494
+ onFinish: ae,
42488
42495
  autoComplete: "off",
42489
42496
  children: [/* @__PURE__ */ X(Mn, {
42490
42497
  className: "v1-card",
@@ -42516,13 +42523,13 @@ function _k() {
42516
42523
  optionFilterProp: "label",
42517
42524
  placeholder: "Select module",
42518
42525
  options: E,
42519
- onChange: ce
42526
+ onChange: se
42520
42527
  })
42521
42528
  }), /* @__PURE__ */ X(R, {
42522
42529
  "aria-label": "Add module",
42523
42530
  icon: /* @__PURE__ */ X(J, {}),
42524
42531
  style: { marginTop: 30 },
42525
- onClick: () => de("module")
42532
+ onClick: () => ue("module")
42526
42533
  })]
42527
42534
  })
42528
42535
  }),
@@ -42538,7 +42545,7 @@ function _k() {
42538
42545
  disabled: te,
42539
42546
  options: o,
42540
42547
  placeholder: m ? "Loading flows" : "Enter flow",
42541
- onChange: le,
42548
+ onChange: ce,
42542
42549
  filterOption: (e, t) => t?.value?.toLowerCase().includes(e.toLowerCase())
42543
42550
  })
42544
42551
  })
@@ -42570,7 +42577,7 @@ function _k() {
42570
42577
  optionFilterProp: "label",
42571
42578
  placeholder: "Select action",
42572
42579
  options: c,
42573
- onChange: ue
42580
+ onChange: le
42574
42581
  })
42575
42582
  })
42576
42583
  }),
@@ -42585,7 +42592,7 @@ function _k() {
42585
42592
  disabled: ne,
42586
42593
  placeholder: "Enter description",
42587
42594
  showCount: !0,
42588
- onBlur: (e) => se("description", e.target.value)
42595
+ onBlur: (e) => oe("description", e.target.value)
42589
42596
  })
42590
42597
  })
42591
42598
  }),
@@ -42603,7 +42610,7 @@ function _k() {
42603
42610
  maxLength: 255,
42604
42611
  disabled: ne || !!k && !j.key,
42605
42612
  placeholder: ne ? "Select module and flow first" : k ? j.key ? "Required — Enter selector / locator" : "Not needed for this action" : "Select an action first",
42606
- onBlur: (e) => se("target", e.target.value)
42613
+ onBlur: (e) => oe("target", e.target.value)
42607
42614
  })
42608
42615
  })
42609
42616
  }),
@@ -42618,7 +42625,7 @@ function _k() {
42618
42625
  disabled: ne,
42619
42626
  placeholder: "Enter tags",
42620
42627
  prefix: /* @__PURE__ */ X(Ri, { className: "v1-input-icon" }),
42621
- onBlur: (e) => se("tags", e.target.value)
42628
+ onBlur: (e) => oe("tags", e.target.value)
42622
42629
  })
42623
42630
  })
42624
42631
  }),
@@ -42636,7 +42643,7 @@ function _k() {
42636
42643
  rows: 4,
42637
42644
  disabled: ne || !!k && !j.value,
42638
42645
  placeholder: ne ? "Select module and flow first" : k ? j.value ? "Required — Enter value" : "Not needed for this action" : "Select an action first",
42639
- onBlur: (e) => se("value", e.target.value)
42646
+ onBlur: (e) => oe("value", e.target.value)
42640
42647
  })
42641
42648
  })
42642
42649
  }),
@@ -42654,7 +42661,7 @@ function _k() {
42654
42661
  rows: 4,
42655
42662
  disabled: ne || !!k && !j.expected,
42656
42663
  placeholder: ne ? "Select module and flow first" : k ? j.expected ? "Required — Enter expected result" : "Not needed for this action" : "Select an action first",
42657
- onBlur: (e) => se("expected", e.target.value)
42664
+ onBlur: (e) => oe("expected", e.target.value)
42658
42665
  })
42659
42666
  })
42660
42667
  })
@@ -42681,9 +42688,9 @@ function _k() {
42681
42688
  open: g.open,
42682
42689
  confirmLoading: v,
42683
42690
  okText: "Add",
42684
- onCancel: fe,
42691
+ onCancel: de,
42685
42692
  onOk: () => {
42686
- y(!0), pe();
42693
+ y(!0), fe();
42687
42694
  },
42688
42695
  destroyOnHidden: !0,
42689
42696
  children: /* @__PURE__ */ Z(B, {
@@ -43006,6 +43013,6 @@ async function Jk(e, t, n, r = 10, i = 0, a = {}) {
43006
43013
  //#region src/index.js
43007
43014
  var Yk = fD, Xk = gb(lO), Zk = gb(dO), Qk = gb(EO), $k = gb(RO), eA = gb(qO), tA = gb(XO), nA = gb($O), rA = gb(nk), iA = gb(ik), aA = gb(_k), oA = gb(yk);
43008
43015
  //#endregion
43009
- export { l as ADMIN_API_URL, c as ADMIN_APP_ID, n as APP_ID, b as AUTH_URL, Gf as ActivityTab, YE as AddBatchCandidatePopup, Af as AddFormV1, fD as AdminDashboard, ww as AdminDashboardContent, Yk as AdminPage, jf as AppAlert, Sl as AppButton, zy as AppShell, K_ as ApprovalActionBar, Kf as AssigneeAvatars, Ly as AuthGuard, Og as BILLING_STATUS_FLOW, tn as Breadcrumb, Qk as BulkUploadPage, C as CANDIDATES_URL, uv as CONTRACT_C2C, lv as CONTRACT_W2, Ea as CalendarCard, Ow as CoreThemeAdminApp, Dw as CoreThemeAdminRoutes, po as CustomPagination, z_ as DayLogModal, ap as DescriptionBlock, Vm as DetailHeaderCard, Jm as DetailViewPage, Kp as DetailViewV1, Te as DocumentViewer, rs as DynamicCards, nE as DynamicPopup, QE as DynamicPopupRoute, Aa as DynamicTabs, Bh as EditFormV1, iv as FINANCE_APPROVAL_CONFIG, ev as FINANCE_TYPE_CFO, $_ as FINANCE_TYPE_ONBOARDING_MANAGER, nv as FINANCE_TYPE_ONBOARDING_MANAGER_REAPPROVE, Q_ as FINANCE_TYPE_SUBMISSION_MANAGER, tv as FINANCE_TYPE_SUBMISSION_MANAGER_REAPPROVE, Av as FinanceApprovalPanel, d_ as FinanceAvatar, h_ as FinanceBadge, J_ as FinanceDayCell, x_ as FinanceDetailHeader, t_ as FinanceDivider, f_ as FinanceEmployeeCell, Qg as FinanceEmptyState, n_ as FinanceEquation, o_ as FinanceHistoryTimeline, Zg as FinanceHoursGrid, Xg as FinanceKpiRow, e_ as FinanceLine, c_ as FinanceListToolbar, g_ as FinanceMarginBadge, m_ as FinanceMoneyCell, y_ as FinanceRecordsTable, __ as FinanceRowChevron, $g as FinanceSection, Yg as FinanceStatusPill, p_ as FinanceTextCell, X_ as FinanceTimesheetAnalysis, r_ as FinanceWorkflowSteps, ly as Header, i as JOBS_URL, Xk as LegacyAdminPage, fd as ListView, oA as LmsHomePage, aA as LmsTestForm, By as Login, Iw as MailPopup, tA as ManageModules, nA as ManageSubmodules, Yh as ModuleRowActions, G_ as NotesPanel, kg as PAYROLL_STATUS_FLOW, HE as POPUP_CONFIGS, ng as ParamCardView, cg as ParamListView, mT as PreviewPopup, hb as ProjectSelect, W_ as ProofUploadPreview, H_ as QuickLogBar, B_ as QuickLogSelectionBar, V_ as RejectionReasonModal, S as SUBMISSIONS_URL, Ny as Sidebar, ug as StatusBadge, Zk as StickyNotesFullPage, fg as StylishDynamicTabs, _g as TemplateEditor, $k as TestForm, iA as TestingHomePage, P_ as TimesheetDayCell, U_ as TimesheetSummaryPanel, At as TipTapEditor, dD as UserForm, nD as VendorShareDrawer, xl as ViewSummaryWidget, bT as WizardPopup, rA as ZinnextTableView, eA as ZinnextTestForm, $a as approveSubmission, Ug as buildCsv, Lg as buildDailyRows, M_ as buildDayGradient, Cv as buildRateHistoryEntries, Bg as buildWeeklyRollup, p as clearSelectedProject, P as colors, xv as computeFinance, Vg as computeMarginBand, t as configureCoreTheme, Kk as createAllWorkflowsListFetcher, Vk as createWorkflowStageListFetcher, Ig as deriveDayStats, qg as downloadCsv, hv as findEmployerRow, mv as flattenGroups, wv as formatFinanceMoney, bg as formatHours, yg as formatMoney, xg as formatRate, Ye as getActivity, qk as getAllWorkflowsModuleList, Tg as getApprovalDate, Ag as getBillingActionStates, m as getCurrentRoleName, Gg as getFieldLabel, ov as getFinanceApprovalConfig, Fv as getFormGroupsRaw, fo as getModuleConfig, w as getModuleDataDetail, jg as getPayrollActionStates, _ as getSelectedProject, a as getStoredToken, d as getStoredUser, y as getUserRoles, eo as getVMSApprove, Kg as getValueStyle, Jk as getWorkflowStageModuleList, Mg as getWorkflowSteps, wg as humanizeEvent, Ad as i, Wg as indexFieldConfig, Sg as initialsOf, o as isTester, h as logout, cv as marginIncludesReferral, bv as matchLocationTax, Zm as n, _v as normalizeContract, qf as r, to as rejectSubmission, Hf as resolveActivityMeta, Sv as resolveAndCompute, yv as resolveFinanceInputs, Ak as resolveMergeKey, sv as resolveRejectionReason, Iv as resolveSubmissionFinance, f as setSelectedProject, Hk as stageCountKey, Vy as t, Ys as useDropdownFields, Cl as useDropdownValues, Lv as useEditForm, Xs as useFieldConfig, Zs as useFilterFields, rc as useMenuPermission, Hh as useModuleActions, Gm as useRecordRefresh, e as withAdminAppId, x as withAppId, gb as withAuthGuard };
43016
+ export { l as ADMIN_API_URL, c as ADMIN_APP_ID, n as APP_ID, b as AUTH_URL, Gf as ActivityTab, YE as AddBatchCandidatePopup, Af as AddFormV1, fD as AdminDashboard, ww as AdminDashboardContent, Yk as AdminPage, jf as AppAlert, Sl as AppButton, zy as AppShell, K_ as ApprovalActionBar, Kf as AssigneeAvatars, Ly as AuthGuard, Og as BILLING_STATUS_FLOW, tn as Breadcrumb, Qk as BulkUploadPage, C as CANDIDATES_URL, uv as CONTRACT_C2C, lv as CONTRACT_W2, Ea as CalendarCard, Ow as CoreThemeAdminApp, Dw as CoreThemeAdminRoutes, po as CustomPagination, z_ as DayLogModal, ap as DescriptionBlock, Vm as DetailHeaderCard, Jm as DetailViewPage, Kp as DetailViewV1, Te as DocumentViewer, rs as DynamicCards, nE as DynamicPopup, QE as DynamicPopupRoute, Aa as DynamicTabs, Bh as EditFormV1, iv as FINANCE_APPROVAL_CONFIG, ev as FINANCE_TYPE_CFO, $_ as FINANCE_TYPE_ONBOARDING_MANAGER, nv as FINANCE_TYPE_ONBOARDING_MANAGER_REAPPROVE, Q_ as FINANCE_TYPE_SUBMISSION_MANAGER, tv as FINANCE_TYPE_SUBMISSION_MANAGER_REAPPROVE, Av as FinanceApprovalPanel, d_ as FinanceAvatar, h_ as FinanceBadge, J_ as FinanceDayCell, x_ as FinanceDetailHeader, t_ as FinanceDivider, f_ as FinanceEmployeeCell, Qg as FinanceEmptyState, n_ as FinanceEquation, o_ as FinanceHistoryTimeline, Zg as FinanceHoursGrid, Xg as FinanceKpiRow, e_ as FinanceLine, c_ as FinanceListToolbar, g_ as FinanceMarginBadge, m_ as FinanceMoneyCell, y_ as FinanceRecordsTable, __ as FinanceRowChevron, $g as FinanceSection, Yg as FinanceStatusPill, p_ as FinanceTextCell, X_ as FinanceTimesheetAnalysis, r_ as FinanceWorkflowSteps, ly as Header, i as JOBS_URL, Xk as LegacyAdminPage, fd as ListView, oA as LmsHomePage, aA as LmsTestForm, By as Login, Iw as MailPopup, tA as ManageModules, nA as ManageSubmodules, Yh as ModuleRowActions, G_ as NotesPanel, kg as PAYROLL_STATUS_FLOW, HE as POPUP_CONFIGS, ng as ParamCardView, cg as ParamListView, mT as PreviewPopup, hb as ProjectSelect, W_ as ProofUploadPreview, H_ as QuickLogBar, B_ as QuickLogSelectionBar, V_ as RejectionReasonModal, S as SUBMISSIONS_URL, Ny as Sidebar, ug as StatusBadge, Zk as StickyNotesFullPage, fg as StylishDynamicTabs, _g as TemplateEditor, $k as TestForm, iA as TestingHomePage, P_ as TimesheetDayCell, U_ as TimesheetSummaryPanel, At as TipTapEditor, dD as UserForm, nD as VendorShareDrawer, xl as ViewSummaryWidget, bT as WizardPopup, rA as ZinnextTableView, eA as ZinnextTestForm, $a as approveSubmission, Ug as buildCsv, Lg as buildDailyRows, M_ as buildDayGradient, Cv as buildRateHistoryEntries, Bg as buildWeeklyRollup, p as clearSelectedProject, be as colors, xv as computeFinance, Vg as computeMarginBand, t as configureCoreTheme, Kk as createAllWorkflowsListFetcher, Vk as createWorkflowStageListFetcher, Ig as deriveDayStats, qg as downloadCsv, hv as findEmployerRow, mv as flattenGroups, wv as formatFinanceMoney, bg as formatHours, yg as formatMoney, xg as formatRate, Ye as getActivity, qk as getAllWorkflowsModuleList, Tg as getApprovalDate, Ag as getBillingActionStates, m as getCurrentRoleName, Gg as getFieldLabel, ov as getFinanceApprovalConfig, Fv as getFormGroupsRaw, fo as getModuleConfig, w as getModuleDataDetail, jg as getPayrollActionStates, _ as getSelectedProject, a as getStoredToken, d as getStoredUser, y as getUserRoles, eo as getVMSApprove, Kg as getValueStyle, Jk as getWorkflowStageModuleList, Mg as getWorkflowSteps, wg as humanizeEvent, Ad as i, Wg as indexFieldConfig, Sg as initialsOf, o as isTester, h as logout, cv as marginIncludesReferral, bv as matchLocationTax, Zm as n, _v as normalizeContract, qf as r, to as rejectSubmission, Hf as resolveActivityMeta, Sv as resolveAndCompute, yv as resolveFinanceInputs, Ak as resolveMergeKey, sv as resolveRejectionReason, Iv as resolveSubmissionFinance, f as setSelectedProject, Hk as stageCountKey, Vy as t, Ys as useDropdownFields, Cl as useDropdownValues, Lv as useEditForm, Xs as useFieldConfig, Zs as useFilterFields, rc as useMenuPermission, Hh as useModuleActions, Gm as useRecordRefresh, e as withAdminAppId, x as withAppId, gb as withAuthGuard };
43010
43017
 
43011
43018
  //# sourceMappingURL=index.js.map