@nivaro/react 0.1.167 → 0.1.168
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/index.js +188 -166
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as e, jsxs as a, Fragment as it } from "react/jsx-runtime";
|
|
2
2
|
import * as _b from "lucide-react";
|
|
3
|
-
import { RefreshCw as Kl, ChevronDown as qn, Check as Tn, X as tn, LayoutGrid as Zp, Bell as Ps, BellRing as oo, Clock as Il, ChartColumn as Tv, History as Dl, FlaskConical as af, Activity as E0, Plus as Dn, Gauge as Sb, Users as go, Lock as ad, Pencil as bl, Trash2 as Ma, Siren as rf, Search as qa, ArrowUpRight as Cb, Eye as Zu, ChevronsUpDown as li, Copy as El, ChevronsLeft as jv, ChevronsRight as Av, Minus as em, ChevronRight as Ja, Sparkles as $i, AlertCircle as Ai, MoreVertical as Lv, MoreHorizontal as tm, Clipboard as $b, Calendar as Ov, Paperclip as Bo, Folder as Rv, File as e0, FileText as du, Phone as ku, MessageSquare as _c, Mail as Yo, UserCheck as qb, UserPlus as M0, User as Nu, Zap as D0, Power as Ev, Filter as rd, Sliders as Mv, Settings as nm, RotateCcw as sd, Pause as Dv, Play as P0, HelpCircle as Fb, Info as ld, AlertTriangle as
|
|
3
|
+
import { RefreshCw as Kl, ChevronDown as qn, Check as Tn, X as tn, LayoutGrid as Zp, Bell as Ps, BellRing as oo, Clock as Il, ChartColumn as Tv, History as Dl, FlaskConical as af, Activity as E0, Plus as Dn, Gauge as Sb, Users as go, Lock as ad, Pencil as bl, Trash2 as Ma, Siren as rf, Search as qa, ArrowUpRight as Cb, Eye as Zu, ChevronsUpDown as li, Copy as El, ChevronsLeft as jv, ChevronsRight as Av, Minus as em, ChevronRight as Ja, Sparkles as $i, AlertCircle as Ai, MoreVertical as Lv, MoreHorizontal as tm, Clipboard as $b, Calendar as Ov, Paperclip as Bo, Folder as Rv, File as e0, FileText as du, Phone as ku, MessageSquare as _c, Mail as Yo, UserCheck as qb, UserPlus as M0, User as Nu, Zap as D0, Power as Ev, Filter as rd, Sliders as Mv, Settings as nm, RotateCcw as sd, Pause as Dv, Play as P0, HelpCircle as Fb, Info as ld, AlertTriangle as Rr, Flag as Pv, Bookmark as Tb, Heart as Kv, Star as qi, Unlock as Iv, EyeOff as zv, Send as am, Upload as ti, Download as Li, Save as wu, Edit2 as Uv, Edit as Bv, XCircle as Wv, CheckCircle as Qv, Share2 as Vv, Link as jb, ExternalLink as id, ArrowDown as Jv, ArrowUp as Hv, ArrowLeft as yo, ArrowRight as Er, MapPin as t0, Loader2 as Ft, MessageSquareWarning as Gv, SmilePlus as K0, GripVertical as Xo, FileVideo as Yv, FileAudio as Xv, FileSpreadsheet as I0, FileCode as Zv, Bold as e1, Italic as t1, UnderlineIcon as n1, Strikethrough as a1, Heading1 as r1, Heading2 as s1, Heading3 as l1, List as i1, ListOrdered as o1, Quote as d1, Code as c1, Link2Off as Ab, FileSymlink as Lb, SlidersHorizontal as Ob, Sigma as Rb, Building2 as Eb, MessageCircle as z0, FileDiff as u1, ClipboardPlus as Mb, CheckCircle2 as m1, Clock3 as p1, Code2 as h1, Satellite as sf, CopyPlus as f1, GitBranch as Um, CalendarClock as x1, GitCompareArrows as b1, Link2 as _u, ClipboardList as g1, GitFork as n0, Network as y1, UploadCloud as v1, Wrench as Db, ShieldAlert as k1, FileDown as lf, ChevronLeft as co, RotateCw as Bm, Map as N1, Rows3 as Su, Rows2 as Pb, BellOff as Cu, Pin as dc, Hash as a0, PlayCircle as w1, LogOut as Kb, Video as _1, CheckCheck as S1, Inbox as $u, ChevronUp as Ib, FileUp as C1, KeyRound as zb, Braces as Ub, Ban as rm, ScrollText as $1, FileBarChart as q1, Users2 as cc, PlugZap as F1, ListChecks as Bb, Camera as uc, Undo2 as Wb, UserRound as r0, ShieldCheck as T1, Flame as j1, Rows4 as A1, PanelLeftClose as L1, Settings2 as Qb, Table as O1, StickyNote as R1, TrendingUp as E1, TrendingDown as M1, ServerCrash as D1, Compass as P1, WifiOff as K1 } from "lucide-react";
|
|
4
4
|
import * as na from "react";
|
|
5
5
|
import gl, { createContext as or, useContext as Da, useState as S, useCallback as Cn, useSyncExternalStore as I1, useEffect as Le, useMemo as ve, useRef as Me, Fragment as ws, useLayoutEffect as od, useId as qu, memo as Vb } from "react";
|
|
6
6
|
import { QueryClientContext as z1, QueryClient as U1, QueryClientProvider as B1, useQuery as se, useQueryClient as jt, useMutation as Ue, useQueries as wa } from "@tanstack/react-query";
|
|
@@ -444,7 +444,7 @@ function xc({
|
|
|
444
444
|
);
|
|
445
445
|
}
|
|
446
446
|
const Mc = "__empty__";
|
|
447
|
-
function
|
|
447
|
+
function $r({
|
|
448
448
|
value: t,
|
|
449
449
|
onChange: n,
|
|
450
450
|
options: r,
|
|
@@ -466,7 +466,7 @@ function Rr({
|
|
|
466
466
|
}
|
|
467
467
|
function cs(t) {
|
|
468
468
|
return /* @__PURE__ */ e(
|
|
469
|
-
|
|
469
|
+
$r,
|
|
470
470
|
{
|
|
471
471
|
...t,
|
|
472
472
|
className: H(
|
|
@@ -548,7 +548,7 @@ function G0({
|
|
|
548
548
|
}
|
|
549
549
|
) : null;
|
|
550
550
|
}
|
|
551
|
-
function
|
|
551
|
+
function Lr({ children: t }) {
|
|
552
552
|
return /* @__PURE__ */ e("p", { className: "mb-1 text-[11px] font-medium uppercase tracking-wide text-slate-400", children: t });
|
|
553
553
|
}
|
|
554
554
|
const mg = "h-8 w-full rounded-md border border-slate-200 bg-white px-2.5 text-[12.5px] outline-none focus:border-nvr-cyan dark:border-border dark:bg-card dark:text-slate-100";
|
|
@@ -562,7 +562,7 @@ function xl({
|
|
|
562
562
|
className: s
|
|
563
563
|
}) {
|
|
564
564
|
return /* @__PURE__ */ e(
|
|
565
|
-
|
|
565
|
+
$r,
|
|
566
566
|
{
|
|
567
567
|
value: t,
|
|
568
568
|
onChange: n,
|
|
@@ -769,7 +769,7 @@ function Ik({
|
|
|
769
769
|
] }),
|
|
770
770
|
children: /* @__PURE__ */ a("div", { className: "space-y-4", children: [
|
|
771
771
|
/* @__PURE__ */ a("div", { children: [
|
|
772
|
-
/* @__PURE__ */ e(
|
|
772
|
+
/* @__PURE__ */ e(Lr, { children: "Alert Metric" }),
|
|
773
773
|
/* @__PURE__ */ e(
|
|
774
774
|
xl,
|
|
775
775
|
{
|
|
@@ -784,7 +784,7 @@ function Ik({
|
|
|
784
784
|
(_ == null ? void 0 : _.description) && /* @__PURE__ */ e("p", { className: "mt-1 text-[11.5px] text-slate-400", children: _.description })
|
|
785
785
|
] }),
|
|
786
786
|
/* @__PURE__ */ a("div", { children: [
|
|
787
|
-
/* @__PURE__ */ e(
|
|
787
|
+
/* @__PURE__ */ e(Lr, { children: "Rule Name" }),
|
|
788
788
|
/* @__PURE__ */ e(
|
|
789
789
|
Fi,
|
|
790
790
|
{
|
|
@@ -797,11 +797,11 @@ function Ik({
|
|
|
797
797
|
] }),
|
|
798
798
|
/* @__PURE__ */ a("div", { className: "flex gap-3", children: [
|
|
799
799
|
/* @__PURE__ */ a("div", { className: "w-[190px] shrink-0", children: [
|
|
800
|
-
/* @__PURE__ */ e(
|
|
800
|
+
/* @__PURE__ */ e(Lr, { children: "Condition" }),
|
|
801
801
|
/* @__PURE__ */ e(xl, { value: h, onChange: f, options: Pk })
|
|
802
802
|
] }),
|
|
803
803
|
/* @__PURE__ */ a("div", { className: "flex-1", children: [
|
|
804
|
-
/* @__PURE__ */ a(
|
|
804
|
+
/* @__PURE__ */ a(Lr, { children: [
|
|
805
805
|
"Threshold",
|
|
806
806
|
_ ? ` (${Kk(_.unit) || _.unit})` : ""
|
|
807
807
|
] }),
|
|
@@ -817,7 +817,7 @@ function Ik({
|
|
|
817
817
|
] })
|
|
818
818
|
] }),
|
|
819
819
|
/* @__PURE__ */ a("div", { children: [
|
|
820
|
-
/* @__PURE__ */ e(
|
|
820
|
+
/* @__PURE__ */ e(Lr, { children: "Check Frequency" }),
|
|
821
821
|
/* @__PURE__ */ e(
|
|
822
822
|
xl,
|
|
823
823
|
{
|
|
@@ -834,7 +834,7 @@ function Ik({
|
|
|
834
834
|
((($ = _ == null ? void 0 : _.supported_filters) == null ? void 0 : $.length) ?? 0) > 0 && /* @__PURE__ */ a("div", { className: "space-y-3 border-t border-slate-100 pt-3 dark:border-border/60", children: [
|
|
835
835
|
/* @__PURE__ */ e("p", { className: "text-[11px] font-medium uppercase tracking-wide text-slate-400", children: "Scope (leave blank for all)" }),
|
|
836
836
|
_.supported_filters.map((j) => /* @__PURE__ */ a("div", { children: [
|
|
837
|
-
/* @__PURE__ */ e(
|
|
837
|
+
/* @__PURE__ */ e(Lr, { children: j.label ?? j.key }),
|
|
838
838
|
/* @__PURE__ */ e(
|
|
839
839
|
pg,
|
|
840
840
|
{
|
|
@@ -853,7 +853,7 @@ function Ik({
|
|
|
853
853
|
/* @__PURE__ */ e(Ys, { checked: b, onChange: F })
|
|
854
854
|
] }),
|
|
855
855
|
r && /* @__PURE__ */ a("div", { children: [
|
|
856
|
-
/* @__PURE__ */ e(
|
|
856
|
+
/* @__PURE__ */ e(Lr, { children: "Status" }),
|
|
857
857
|
/* @__PURE__ */ e(
|
|
858
858
|
xl,
|
|
859
859
|
{
|
|
@@ -926,7 +926,7 @@ function zk({
|
|
|
926
926
|
/* @__PURE__ */ e("p", { className: "mt-0.5 text-[11px]", children: "Collection and event type are fixed at creation — remove and re-subscribe to change them." })
|
|
927
927
|
] }),
|
|
928
928
|
/* @__PURE__ */ a("div", { children: [
|
|
929
|
-
/* @__PURE__ */ e(
|
|
929
|
+
/* @__PURE__ */ e(Lr, { children: "Label" }),
|
|
930
930
|
/* @__PURE__ */ e(
|
|
931
931
|
Fi,
|
|
932
932
|
{
|
|
@@ -939,7 +939,7 @@ function zk({
|
|
|
939
939
|
!F && /* @__PURE__ */ a(it, { children: [
|
|
940
940
|
/* @__PURE__ */ a("div", { className: "flex gap-3", children: [
|
|
941
941
|
/* @__PURE__ */ a("div", { className: "flex-1", children: [
|
|
942
|
-
/* @__PURE__ */ e(
|
|
942
|
+
/* @__PURE__ */ e(Lr, { children: n.event_type === "workflow_transition" ? "State filter field" : "Filter field" }),
|
|
943
943
|
/* @__PURE__ */ e(
|
|
944
944
|
Fi,
|
|
945
945
|
{
|
|
@@ -950,7 +950,7 @@ function zk({
|
|
|
950
950
|
)
|
|
951
951
|
] }),
|
|
952
952
|
/* @__PURE__ */ a("div", { className: "flex-1", children: [
|
|
953
|
-
/* @__PURE__ */ e(
|
|
953
|
+
/* @__PURE__ */ e(Lr, { children: "Filter value" }),
|
|
954
954
|
/* @__PURE__ */ e(
|
|
955
955
|
Fi,
|
|
956
956
|
{
|
|
@@ -962,7 +962,7 @@ function zk({
|
|
|
962
962
|
] })
|
|
963
963
|
] }),
|
|
964
964
|
/* @__PURE__ */ a("div", { children: [
|
|
965
|
-
/* @__PURE__ */ e(
|
|
965
|
+
/* @__PURE__ */ e(Lr, { children: "Advanced filters (JSON)" }),
|
|
966
966
|
/* @__PURE__ */ e(
|
|
967
967
|
"textarea",
|
|
968
968
|
{
|
|
@@ -984,7 +984,7 @@ function zk({
|
|
|
984
984
|
] })
|
|
985
985
|
] }),
|
|
986
986
|
/* @__PURE__ */ a("div", { children: [
|
|
987
|
-
/* @__PURE__ */ e(
|
|
987
|
+
/* @__PURE__ */ e(Lr, { children: "Digest" }),
|
|
988
988
|
/* @__PURE__ */ e(
|
|
989
989
|
xl,
|
|
990
990
|
{
|
|
@@ -1053,7 +1053,7 @@ function Uk({
|
|
|
1053
1053
|
] }),
|
|
1054
1054
|
children: /* @__PURE__ */ a("div", { className: "space-y-4", children: [
|
|
1055
1055
|
/* @__PURE__ */ a("div", { children: [
|
|
1056
|
-
/* @__PURE__ */ e(
|
|
1056
|
+
/* @__PURE__ */ e(Lr, { children: "Rule Name" }),
|
|
1057
1057
|
/* @__PURE__ */ e(
|
|
1058
1058
|
Fi,
|
|
1059
1059
|
{
|
|
@@ -1064,7 +1064,7 @@ function Uk({
|
|
|
1064
1064
|
)
|
|
1065
1065
|
] }),
|
|
1066
1066
|
/* @__PURE__ */ a("div", { children: [
|
|
1067
|
-
/* @__PURE__ */ e(
|
|
1067
|
+
/* @__PURE__ */ e(Lr, { children: "Anomaly Type" }),
|
|
1068
1068
|
/* @__PURE__ */ e(
|
|
1069
1069
|
xl,
|
|
1070
1070
|
{
|
|
@@ -1079,7 +1079,7 @@ function Uk({
|
|
|
1079
1079
|
(N == null ? void 0 : N.description) && /* @__PURE__ */ e("p", { className: "mt-1 text-[11.5px] text-slate-400", children: N.description })
|
|
1080
1080
|
] }),
|
|
1081
1081
|
/* @__PURE__ */ a("div", { children: [
|
|
1082
|
-
/* @__PURE__ */ e(
|
|
1082
|
+
/* @__PURE__ */ e(Lr, { children: "Sensitivity" }),
|
|
1083
1083
|
/* @__PURE__ */ e(
|
|
1084
1084
|
xl,
|
|
1085
1085
|
{
|
|
@@ -1097,7 +1097,7 @@ function Uk({
|
|
|
1097
1097
|
(((T = N == null ? void 0 : N.scope_options) == null ? void 0 : T.length) ?? 0) > 0 && /* @__PURE__ */ a("div", { className: "space-y-3 border-t border-slate-100 pt-3 dark:border-border/60", children: [
|
|
1098
1098
|
/* @__PURE__ */ e("p", { className: "text-[11px] font-medium uppercase tracking-wide text-slate-400", children: "Scope (leave blank for all)" }),
|
|
1099
1099
|
N.scope_options.map(($) => /* @__PURE__ */ a("div", { children: [
|
|
1100
|
-
/* @__PURE__ */ e(
|
|
1100
|
+
/* @__PURE__ */ e(Lr, { children: $.label ?? $.key }),
|
|
1101
1101
|
/* @__PURE__ */ e(
|
|
1102
1102
|
pg,
|
|
1103
1103
|
{
|
|
@@ -1112,7 +1112,7 @@ function Uk({
|
|
|
1112
1112
|
/* @__PURE__ */ e("p", { className: "mb-2 text-[11px] font-medium uppercase tracking-wide text-slate-400", children: "Schedule & Delivery" }),
|
|
1113
1113
|
/* @__PURE__ */ a("div", { className: "space-y-3", children: [
|
|
1114
1114
|
/* @__PURE__ */ a("div", { children: [
|
|
1115
|
-
/* @__PURE__ */ e(
|
|
1115
|
+
/* @__PURE__ */ e(Lr, { children: "Check Frequency" }),
|
|
1116
1116
|
/* @__PURE__ */ e(
|
|
1117
1117
|
xl,
|
|
1118
1118
|
{
|
|
@@ -1126,7 +1126,7 @@ function Uk({
|
|
|
1126
1126
|
)
|
|
1127
1127
|
] }),
|
|
1128
1128
|
/* @__PURE__ */ a("div", { children: [
|
|
1129
|
-
/* @__PURE__ */ e(
|
|
1129
|
+
/* @__PURE__ */ e(Lr, { children: "Status" }),
|
|
1130
1130
|
/* @__PURE__ */ e(
|
|
1131
1131
|
xl,
|
|
1132
1132
|
{
|
|
@@ -6593,7 +6593,7 @@ const Oo = {
|
|
|
6593
6593
|
Bookmark: Tb,
|
|
6594
6594
|
Flag: Pv,
|
|
6595
6595
|
AlertCircle: Ai,
|
|
6596
|
-
AlertTriangle:
|
|
6596
|
+
AlertTriangle: Rr,
|
|
6597
6597
|
Info: ld,
|
|
6598
6598
|
HelpCircle: Fb,
|
|
6599
6599
|
Play: P0,
|
|
@@ -8728,7 +8728,7 @@ function u0({
|
|
|
8728
8728
|
/* @__PURE__ */ e("ul", { className: "space-y-1.5", children: t.map((s, l) => {
|
|
8729
8729
|
const i = s5(s), d = `${s.rule}-${s.row ?? ""}-${s.column ?? ""}-${l}`;
|
|
8730
8730
|
return /* @__PURE__ */ a("li", { className: "flex items-start gap-2 text-[12px]", children: [
|
|
8731
|
-
s.severity === "error" ? /* @__PURE__ */ e(Ai, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-red-500" }) : /* @__PURE__ */ e(
|
|
8731
|
+
s.severity === "error" ? /* @__PURE__ */ e(Ai, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-red-500" }) : /* @__PURE__ */ e(Rr, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-amber-500" }),
|
|
8732
8732
|
/* @__PURE__ */ a(
|
|
8733
8733
|
"span",
|
|
8734
8734
|
{
|
|
@@ -9745,7 +9745,7 @@ function Ds({
|
|
|
9745
9745
|
!ye && "text-muted-foreground"
|
|
9746
9746
|
),
|
|
9747
9747
|
children: [
|
|
9748
|
-
ne && /* @__PURE__ */ e(
|
|
9748
|
+
ne && /* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5 shrink-0 text-amber-500" }),
|
|
9749
9749
|
/* @__PURE__ */ e("span", { className: "truncate", children: ye ?? l ?? "Select…" })
|
|
9750
9750
|
]
|
|
9751
9751
|
}
|
|
@@ -9900,7 +9900,7 @@ function h5({ children: t }) {
|
|
|
9900
9900
|
},
|
|
9901
9901
|
onMouseLeave: () => r(null),
|
|
9902
9902
|
children: [
|
|
9903
|
-
/* @__PURE__ */ e(
|
|
9903
|
+
/* @__PURE__ */ e(Rr, { className: "h-3 w-3 shrink-0 text-amber-500" }),
|
|
9904
9904
|
/* @__PURE__ */ e("span", { className: "min-w-0 truncate", children: t }),
|
|
9905
9905
|
n && Ca(
|
|
9906
9906
|
/* @__PURE__ */ e(
|
|
@@ -10664,7 +10664,7 @@ function N5({
|
|
|
10664
10664
|
Ht.current = !0;
|
|
10665
10665
|
return;
|
|
10666
10666
|
}
|
|
10667
|
-
Ht.current = !1, At.current && (clearTimeout(At.current), At.current = null),
|
|
10667
|
+
Ht.current = !1, At.current && (clearTimeout(At.current), At.current = null), Tr();
|
|
10668
10668
|
}
|
|
10669
10669
|
};
|
|
10670
10670
|
return document.addEventListener("mousedown", Q, !0), () => document.removeEventListener("mousedown", Q, !0);
|
|
@@ -10937,7 +10937,7 @@ function N5({
|
|
|
10937
10937
|
junctionOtherField: fe.many_field
|
|
10938
10938
|
};
|
|
10939
10939
|
}
|
|
10940
|
-
const
|
|
10940
|
+
const qr = JSON.stringify([...Nn.entries()]) + "|" + [...ie].sort().join(",") + "|" + JSON.stringify(kn), ga = ve(() => {
|
|
10941
10941
|
const Q = [
|
|
10942
10942
|
...(Rt ?? []).filter((de) => !ie.has(String(de.id))).map((de) => {
|
|
10943
10943
|
const fe = String(de.id), xe = Nn.has(fe) ? { ...de, ...Nn.get(fe) } : de;
|
|
@@ -10950,7 +10950,7 @@ function N5({
|
|
|
10950
10950
|
xe >= 0 && xe < Q.length && (Q[xe] = de);
|
|
10951
10951
|
}
|
|
10952
10952
|
return Q;
|
|
10953
|
-
}, [Rt,
|
|
10953
|
+
}, [Rt, qr, Xe]), Fs = Xt.length >= dp, ma = I == null ? void 0 : I.report;
|
|
10954
10954
|
Le(() => {
|
|
10955
10955
|
if (ma) {
|
|
10956
10956
|
if (Fs || Ve) {
|
|
@@ -11017,7 +11017,7 @@ function N5({
|
|
|
11017
11017
|
var xe;
|
|
11018
11018
|
Q.set(de, ((xe = zs[fe]) == null ? void 0 : xe.data) ?? []);
|
|
11019
11019
|
}), Q;
|
|
11020
|
-
}, [ns, zs]),
|
|
11020
|
+
}, [ns, zs]), Fr = ve(() => {
|
|
11021
11021
|
const Q = /* @__PURE__ */ new Map();
|
|
11022
11022
|
for (const de of ua) {
|
|
11023
11023
|
const fe = Fa.get(de);
|
|
@@ -11129,7 +11129,7 @@ function N5({
|
|
|
11129
11129
|
xe == null || xe === "" || (Q.has(fe) || Q.set(fe, []), Q.get(fe).push(String(xe)));
|
|
11130
11130
|
};
|
|
11131
11131
|
for (const [fe, xe] of Qr) {
|
|
11132
|
-
const Re =
|
|
11132
|
+
const Re = Fr.get(fe);
|
|
11133
11133
|
if (!(!Re || Re.size === 0)) {
|
|
11134
11134
|
for (const We of xe.values())
|
|
11135
11135
|
for (const ot of We)
|
|
@@ -11158,7 +11158,7 @@ function N5({
|
|
|
11158
11158
|
}
|
|
11159
11159
|
for (const [fe, xe] of Q) Q.set(fe, [...new Set(xe)].sort());
|
|
11160
11160
|
return Q;
|
|
11161
|
-
}, [Qr,
|
|
11161
|
+
}, [Qr, Fr, kn, Nn, ta]), { data: Ba = {} } = se({
|
|
11162
11162
|
queryKey: ["summary-m2o-display", t, ...Array.from(Dr.entries()).flat(2)],
|
|
11163
11163
|
queryFn: async () => {
|
|
11164
11164
|
const Q = {};
|
|
@@ -11225,7 +11225,7 @@ function N5({
|
|
|
11225
11225
|
if (xe < 0) return "—";
|
|
11226
11226
|
const Re = Q.field.slice(0, xe), We = Q.field.slice(xe + 1), ot = Sl(Re, de, fe);
|
|
11227
11227
|
if (ot.length === 0) return "—";
|
|
11228
|
-
const et = (Ut =
|
|
11228
|
+
const et = (Ut = Fr.get(Re)) == null ? void 0 : Ut.get(We), tt = ot.map((dt) => {
|
|
11229
11229
|
var dn;
|
|
11230
11230
|
const qt = dt[We];
|
|
11231
11231
|
return qt == null || qt === "" ? null : et != null && et.one_collection ? ((dn = Ba[et.one_collection]) == null ? void 0 : dn[String(qt)]) ?? String(qt) : String(qt);
|
|
@@ -11238,7 +11238,7 @@ function N5({
|
|
|
11238
11238
|
if (fe < 0) return "—";
|
|
11239
11239
|
const xe = Q.field.slice(0, fe), Re = Q.field.slice(fe + 1), We = Sl(xe, de, !1);
|
|
11240
11240
|
if (We.length === 0) return "—";
|
|
11241
|
-
const ot = (Ut =
|
|
11241
|
+
const ot = (Ut = Fr.get(xe)) == null ? void 0 : Ut.get(Re);
|
|
11242
11242
|
if (!(ot != null && ot.one_collection) || !M) return Vr(Q, de, !1);
|
|
11243
11243
|
const et = ot.one_collection, tt = We.map((dt) => {
|
|
11244
11244
|
var dn;
|
|
@@ -11426,7 +11426,7 @@ function N5({
|
|
|
11426
11426
|
});
|
|
11427
11427
|
}
|
|
11428
11428
|
}
|
|
11429
|
-
async function
|
|
11429
|
+
async function Tr() {
|
|
11430
11430
|
var fe;
|
|
11431
11431
|
if (!Xe) return;
|
|
11432
11432
|
const Q = Xe.rowId, de = () => {
|
|
@@ -11503,7 +11503,7 @@ function N5({
|
|
|
11503
11503
|
St(!1);
|
|
11504
11504
|
}
|
|
11505
11505
|
}
|
|
11506
|
-
const [ls, vr] = S(/* @__PURE__ */ new Set()), [sr, kr] = S(null), [pr, Bs] = S(null), [Jr,
|
|
11506
|
+
const [ls, vr] = S(/* @__PURE__ */ new Set()), [sr, kr] = S(null), [pr, Bs] = S(null), [Jr, jr] = S(!1), [lr, Cl] = S(1), [Ar, U] = S(!1), [Te, pt] = S(!1), [Dt, ln] = S({}), [on, Hn] = S(!1), [ea, Ir] = S({}), [hr, zr] = S(!1);
|
|
11507
11507
|
function Nr(Q, de) {
|
|
11508
11508
|
ln((fe) => ({ ...fe, [Q]: de }));
|
|
11509
11509
|
}
|
|
@@ -11590,14 +11590,14 @@ function N5({
|
|
|
11590
11590
|
), Na();
|
|
11591
11591
|
return;
|
|
11592
11592
|
}
|
|
11593
|
-
|
|
11593
|
+
jr(!0);
|
|
11594
11594
|
try {
|
|
11595
11595
|
await Promise.all(xe.map(
|
|
11596
11596
|
({ row: Re, newOrder: We }) => W.request(Fn(`/items/${t}/${Re.id}${ee}`, { [Ct]: We }))
|
|
11597
11597
|
)), R.invalidateQueries({ queryKey: ["o2m-rows", t, n, r] });
|
|
11598
11598
|
} catch {
|
|
11599
11599
|
} finally {
|
|
11600
|
-
|
|
11600
|
+
jr(!1), Na();
|
|
11601
11601
|
}
|
|
11602
11602
|
}
|
|
11603
11603
|
async function is(Q, de) {
|
|
@@ -11868,7 +11868,7 @@ function N5({
|
|
|
11868
11868
|
{
|
|
11869
11869
|
type: "button",
|
|
11870
11870
|
disabled: _e,
|
|
11871
|
-
onClick:
|
|
11871
|
+
onClick: Tr,
|
|
11872
11872
|
className: "rounded bg-nvr-cyan px-3 py-1 text-[11px] font-medium text-white transition-[filter] hover:brightness-110 disabled:opacity-50",
|
|
11873
11873
|
children: _e ? "Saving…" : Q.saveLabel
|
|
11874
11874
|
}
|
|
@@ -11998,7 +11998,7 @@ function N5({
|
|
|
11998
11998
|
"button",
|
|
11999
11999
|
{
|
|
12000
12000
|
type: "button",
|
|
12001
|
-
disabled:
|
|
12001
|
+
disabled: Ar,
|
|
12002
12002
|
onClick: () => _o(!1),
|
|
12003
12003
|
className: "h-6 px-2.5 rounded border border-slate-200 text-slate-600 hover:border-slate-400 hover:text-slate-800 disabled:opacity-40 transition-colors",
|
|
12004
12004
|
children: [
|
|
@@ -12015,7 +12015,7 @@ function N5({
|
|
|
12015
12015
|
"button",
|
|
12016
12016
|
{
|
|
12017
12017
|
type: "button",
|
|
12018
|
-
disabled:
|
|
12018
|
+
disabled: Ar,
|
|
12019
12019
|
onClick: () => md(Q[0].field),
|
|
12020
12020
|
"data-tip": `Generate ${lr} rows with ${Q[0].field} advancing one month per row (starting next month)`,
|
|
12021
12021
|
className: "h-6 px-2.5 rounded border border-dashed border-slate-300 text-slate-500 hover:border-nvr-cyan/60 hover:text-slate-700 disabled:opacity-40 transition-colors",
|
|
@@ -12152,7 +12152,7 @@ function N5({
|
|
|
12152
12152
|
children: "apply values…"
|
|
12153
12153
|
}
|
|
12154
12154
|
),
|
|
12155
|
-
|
|
12155
|
+
Ar && /* @__PURE__ */ e(Ft, { className: "h-3 w-3 animate-spin text-slate-400" }),
|
|
12156
12156
|
sl,
|
|
12157
12157
|
i && o && !V && /* @__PURE__ */ e(
|
|
12158
12158
|
"button",
|
|
@@ -12238,10 +12238,10 @@ function N5({
|
|
|
12238
12238
|
"button",
|
|
12239
12239
|
{
|
|
12240
12240
|
type: "button",
|
|
12241
|
-
disabled:
|
|
12241
|
+
disabled: Ar,
|
|
12242
12242
|
onClick: () => _o(!0),
|
|
12243
12243
|
className: "rounded px-2 h-9 bg-[#00ceff] text-white text-[11px] font-medium hover:brightness-110 disabled:opacity-50 whitespace-nowrap",
|
|
12244
|
-
children:
|
|
12244
|
+
children: Ar ? "…" : `Add ${lr}`
|
|
12245
12245
|
}
|
|
12246
12246
|
) })
|
|
12247
12247
|
] }),
|
|
@@ -12278,7 +12278,7 @@ function N5({
|
|
|
12278
12278
|
onClick: () => !et && !qt && ui(dn),
|
|
12279
12279
|
onBlur: (gn) => {
|
|
12280
12280
|
!et || _e || qt || gn.currentTarget.contains(gn.relatedTarget) || nn(gn.relatedTarget) || (At.current = setTimeout(() => {
|
|
12281
|
-
Ht.current || nn(document.activeElement) ||
|
|
12281
|
+
Ht.current || nn(document.activeElement) || Tr();
|
|
12282
12282
|
}, 150));
|
|
12283
12283
|
},
|
|
12284
12284
|
onFocus: () => {
|
|
@@ -12332,7 +12332,7 @@ function N5({
|
|
|
12332
12332
|
{
|
|
12333
12333
|
type: "button",
|
|
12334
12334
|
disabled: _e,
|
|
12335
|
-
onClick:
|
|
12335
|
+
onClick: Tr,
|
|
12336
12336
|
className: "rounded px-2 h-9 bg-[#00ceff] text-white text-[11px] font-medium hover:brightness-110 disabled:opacity-50",
|
|
12337
12337
|
children: _e ? "…" : "Save"
|
|
12338
12338
|
}
|
|
@@ -12487,7 +12487,7 @@ function N5({
|
|
|
12487
12487
|
{
|
|
12488
12488
|
type: "button",
|
|
12489
12489
|
disabled: _e,
|
|
12490
|
-
onClick:
|
|
12490
|
+
onClick: Tr,
|
|
12491
12491
|
className: "rounded px-2 h-9 bg-[#00ceff] text-white text-[11px] font-medium hover:brightness-110 disabled:opacity-50",
|
|
12492
12492
|
children: _e ? "…" : "Add"
|
|
12493
12493
|
}
|
|
@@ -12549,7 +12549,7 @@ function N5({
|
|
|
12549
12549
|
onClick: () => !xe && gs(Q, de),
|
|
12550
12550
|
onBlur: (et) => {
|
|
12551
12551
|
!xe || _e || et.currentTarget.contains(et.relatedTarget) || nn(et.relatedTarget) || (At.current = setTimeout(() => {
|
|
12552
|
-
Ht.current || nn(document.activeElement) ||
|
|
12552
|
+
Ht.current || nn(document.activeElement) || Tr();
|
|
12553
12553
|
}, 150));
|
|
12554
12554
|
},
|
|
12555
12555
|
onFocus: () => {
|
|
@@ -12615,7 +12615,7 @@ function N5({
|
|
|
12615
12615
|
{
|
|
12616
12616
|
type: "button",
|
|
12617
12617
|
disabled: _e,
|
|
12618
|
-
onClick:
|
|
12618
|
+
onClick: Tr,
|
|
12619
12619
|
className: "rounded px-2 h-9 bg-[#00ceff] text-white text-[11px] font-medium hover:brightness-110 disabled:opacity-50",
|
|
12620
12620
|
children: _e ? "…" : "Save"
|
|
12621
12621
|
}
|
|
@@ -13624,7 +13624,7 @@ function S5({
|
|
|
13624
13624
|
we(at, ha(T, ie), zt),
|
|
13625
13625
|
$n(at, ie),
|
|
13626
13626
|
Tt && /* @__PURE__ */ e(
|
|
13627
|
-
|
|
13627
|
+
Rr,
|
|
13628
13628
|
{
|
|
13629
13629
|
className: "h-3.5 w-3.5 shrink-0 text-amber-500",
|
|
13630
13630
|
"aria-label": `${Je} ${Tt.available} — ${Tt.qty} requested`
|
|
@@ -13688,7 +13688,7 @@ function S5({
|
|
|
13688
13688
|
we(kt.id, kt.label, zt),
|
|
13689
13689
|
$n(kt.id, kt.row),
|
|
13690
13690
|
mt && /* @__PURE__ */ e(
|
|
13691
|
-
|
|
13691
|
+
Rr,
|
|
13692
13692
|
{
|
|
13693
13693
|
className: "h-3.5 w-3.5 shrink-0 text-amber-500",
|
|
13694
13694
|
"aria-label": `${Je} ${mt.available} — ${mt.qty} requested`
|
|
@@ -13894,7 +13894,7 @@ function S5({
|
|
|
13894
13894
|
})
|
|
13895
13895
|
] }),
|
|
13896
13896
|
mn && /* @__PURE__ */ a("p", { className: "mt-1 flex items-center gap-1 pl-0.5 text-[11px] font-medium text-amber-600 dark:text-amber-400", children: [
|
|
13897
|
-
/* @__PURE__ */ e(
|
|
13897
|
+
/* @__PURE__ */ e(Rr, { className: "h-3 w-3 shrink-0" }),
|
|
13898
13898
|
Je,
|
|
13899
13899
|
" is ",
|
|
13900
13900
|
vn(mn.available, "number"),
|
|
@@ -14379,7 +14379,7 @@ function q5({
|
|
|
14379
14379
|
)
|
|
14380
14380
|
] }),
|
|
14381
14381
|
M.length > 0 && /* @__PURE__ */ a("p", { className: "mt-1.5 flex items-center gap-1 text-[10px] text-amber-600 dark:text-amber-400", children: [
|
|
14382
|
-
/* @__PURE__ */ e(
|
|
14382
|
+
/* @__PURE__ */ e(Rr, { className: "h-3 w-3 shrink-0" }),
|
|
14383
14383
|
M.map((V) => V.label ?? Vt(V.key)).join(", "),
|
|
14384
14384
|
" fill in once the form's warehouse selection is made."
|
|
14385
14385
|
] })
|
|
@@ -15797,7 +15797,7 @@ function ty({
|
|
|
15797
15797
|
ye ? "border-amber-300 bg-amber-50 text-amber-700 dark:border-amber-600 dark:bg-amber-950/30 dark:text-amber-400" : "border-slate-200 bg-slate-50 text-slate-700 dark:border-border dark:bg-muted dark:text-slate-200"
|
|
15798
15798
|
),
|
|
15799
15799
|
children: [
|
|
15800
|
-
ye && /* @__PURE__ */ e(
|
|
15800
|
+
ye && /* @__PURE__ */ e(Rr, { className: "h-3 w-3 shrink-0 text-amber-500" }),
|
|
15801
15801
|
g && (o && c ? /* @__PURE__ */ e(
|
|
15802
15802
|
"button",
|
|
15803
15803
|
{
|
|
@@ -16056,7 +16056,7 @@ function D5({
|
|
|
16056
16056
|
De ? L ? "text-nvr-cyan" : "text-slate-800 dark:text-slate-100" : "text-muted-foreground"
|
|
16057
16057
|
),
|
|
16058
16058
|
children: [
|
|
16059
|
-
Y && /* @__PURE__ */ e(
|
|
16059
|
+
Y && /* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5 shrink-0 text-amber-500" }),
|
|
16060
16060
|
/* @__PURE__ */ e("span", { className: "truncate", children: De ?? "Select…" })
|
|
16061
16061
|
]
|
|
16062
16062
|
}
|
|
@@ -16339,7 +16339,7 @@ function K5({
|
|
|
16339
16339
|
),
|
|
16340
16340
|
children: [
|
|
16341
16341
|
L ? /* @__PURE__ */ e(Ft, { className: "h-3.5 w-3.5 animate-spin text-muted-foreground" }) : /* @__PURE__ */ a("span", { className: H("flex items-center gap-1.5 truncate min-w-0", !R && "text-muted-foreground"), children: [
|
|
16342
|
-
O && /* @__PURE__ */ e(
|
|
16342
|
+
O && /* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5 shrink-0 text-amber-500" }),
|
|
16343
16343
|
/* @__PURE__ */ e("span", { className: "truncate", children: R ?? d ?? "Select…" })
|
|
16344
16344
|
] }),
|
|
16345
16345
|
/* @__PURE__ */ e(qn, { className: "h-4 w-4 shrink-0 opacity-50" })
|
|
@@ -16806,7 +16806,7 @@ function B5({
|
|
|
16806
16806
|
return /* @__PURE__ */ a("div", { className: "space-y-1.5 border-b border-slate-200 bg-slate-50 px-2 py-1.5", children: [
|
|
16807
16807
|
/* @__PURE__ */ a("div", { className: "flex items-center gap-1.5", children: [
|
|
16808
16808
|
/* @__PURE__ */ e(
|
|
16809
|
-
|
|
16809
|
+
$r,
|
|
16810
16810
|
{
|
|
16811
16811
|
value: i,
|
|
16812
16812
|
onChange: d,
|
|
@@ -17380,7 +17380,7 @@ function hl({
|
|
|
17380
17380
|
})();
|
|
17381
17381
|
if (R.length > 0)
|
|
17382
17382
|
return /* @__PURE__ */ e(
|
|
17383
|
-
|
|
17383
|
+
$r,
|
|
17384
17384
|
{
|
|
17385
17385
|
value: A,
|
|
17386
17386
|
onChange: (L) => r(L || null),
|
|
@@ -21749,7 +21749,7 @@ function H6({
|
|
|
21749
21749
|
className: "flex items-start gap-2.5 rounded-lg border border-red-200 bg-red-50 px-3.5 py-2.5 dark:border-red-900/40 dark:bg-red-900/15",
|
|
21750
21750
|
"data-erp-failure-banner": !0,
|
|
21751
21751
|
children: [
|
|
21752
|
-
/* @__PURE__ */ e(
|
|
21752
|
+
/* @__PURE__ */ e(Rr, { className: "mt-0.5 h-4 w-4 shrink-0 text-red-500", strokeWidth: 2 }),
|
|
21753
21753
|
/* @__PURE__ */ a("div", { className: "min-w-0 flex-1", children: [
|
|
21754
21754
|
/* @__PURE__ */ a("p", { className: "text-[12.5px] font-semibold text-red-700 dark:text-red-300", children: [
|
|
21755
21755
|
"External submission failed",
|
|
@@ -25942,7 +25942,7 @@ function xp({
|
|
|
25942
25942
|
] }, `${w.direction}-${w.id}`)) }),
|
|
25943
25943
|
c ? /* @__PURE__ */ a("div", { className: "mt-2 space-y-1.5 rounded-md border border-slate-200 p-2 dark:border-border", children: [
|
|
25944
25944
|
/* @__PURE__ */ e(
|
|
25945
|
-
|
|
25945
|
+
$r,
|
|
25946
25946
|
{
|
|
25947
25947
|
value: x,
|
|
25948
25948
|
onChange: b,
|
|
@@ -26240,7 +26240,7 @@ function Vc({
|
|
|
26240
26240
|
/* @__PURE__ */ a("div", { children: [
|
|
26241
26241
|
/* @__PURE__ */ e(Sn, { className: "mb-1 block text-[11px]", children: "Priority" }),
|
|
26242
26242
|
/* @__PURE__ */ e(
|
|
26243
|
-
|
|
26243
|
+
$r,
|
|
26244
26244
|
{
|
|
26245
26245
|
value: A,
|
|
26246
26246
|
onChange: (R) => N(R),
|
|
@@ -26376,7 +26376,7 @@ function Vc({
|
|
|
26376
26376
|
/* @__PURE__ */ a("div", { children: [
|
|
26377
26377
|
/* @__PURE__ */ e(Sn, { className: "mb-1 block text-[11px]", children: "Priority" }),
|
|
26378
26378
|
/* @__PURE__ */ e(
|
|
26379
|
-
|
|
26379
|
+
$r,
|
|
26380
26380
|
{
|
|
26381
26381
|
value: A,
|
|
26382
26382
|
onChange: (R) => N(R),
|
|
@@ -27194,7 +27194,7 @@ function t3({ group: t }) {
|
|
|
27194
27194
|
"data-content-block": t.key,
|
|
27195
27195
|
className: `flex gap-2.5 rounded-lg border px-3.5 py-2.5 ${l ? "border-amber-200 bg-amber-50/70 dark:border-amber-500/30 dark:bg-amber-500/10" : "border-slate-200 bg-slate-50/70 dark:border-border dark:bg-muted/40"}`,
|
|
27196
27196
|
children: [
|
|
27197
|
-
l ? /* @__PURE__ */ e(
|
|
27197
|
+
l ? /* @__PURE__ */ e(Rr, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-amber-500" }) : /* @__PURE__ */ e(ld, { className: "mt-0.5 h-3.5 w-3.5 shrink-0 text-slate-400" }),
|
|
27198
27198
|
/* @__PURE__ */ a("div", { className: "min-w-0 space-y-1.5", children: [
|
|
27199
27199
|
t.label && t.label !== t.key && /* @__PURE__ */ e(
|
|
27200
27200
|
"p",
|
|
@@ -27485,7 +27485,7 @@ function a3({
|
|
|
27485
27485
|
)
|
|
27486
27486
|
] }),
|
|
27487
27487
|
/* @__PURE__ */ e(
|
|
27488
|
-
|
|
27488
|
+
$r,
|
|
27489
27489
|
{
|
|
27490
27490
|
value: i,
|
|
27491
27491
|
onChange: d,
|
|
@@ -29373,11 +29373,11 @@ function K3({
|
|
|
29373
29373
|
[Tt, mt, On]
|
|
29374
29374
|
), [Wn, Rt] = S([]), ba = Me(!1), ka = Me(!1), [Kn, Jn] = S(/* @__PURE__ */ new Map()), [nr, qs] = S(/* @__PURE__ */ new Map()), fa = Me(
|
|
29375
29375
|
null
|
|
29376
|
-
), ca = Me(/* @__PURE__ */ new Map()), dr = Me(0), Oa = Me(/* @__PURE__ */ new Map()),
|
|
29376
|
+
), ca = Me(/* @__PURE__ */ new Map()), dr = Me(0), Oa = Me(/* @__PURE__ */ new Map()), qr = Me(/* @__PURE__ */ new Map()), ga = ve(
|
|
29377
29377
|
() => ({
|
|
29378
29378
|
getStagedLinks: (E) => Kn.get(E) ?? [],
|
|
29379
29379
|
getStagedUnlinks: (E) => nr.get(E) ?? /* @__PURE__ */ new Set(),
|
|
29380
|
-
getDerivedOrigin: (E) =>
|
|
29380
|
+
getDerivedOrigin: (E) => qr.current.get(E) ?? null,
|
|
29381
29381
|
stageLink: (E, B) => {
|
|
29382
29382
|
var G, le;
|
|
29383
29383
|
if (Jn((me) => {
|
|
@@ -29872,8 +29872,8 @@ function K3({
|
|
|
29872
29872
|
nr.get(G.stagingKey)
|
|
29873
29873
|
);
|
|
29874
29874
|
}), E;
|
|
29875
|
-
}, [Zn, Ul, Kn, nr, L, I]),
|
|
29876
|
-
|
|
29875
|
+
}, [Zn, Ul, Kn, nr, L, I]), Fr = Me(xa);
|
|
29876
|
+
Fr.current = xa, ca.current = new Map(
|
|
29877
29877
|
[...Zn.entries()].map(([E, B]) => [B.stagingKey, E])
|
|
29878
29878
|
);
|
|
29879
29879
|
const Ua = Cn(
|
|
@@ -29912,7 +29912,7 @@ function K3({
|
|
|
29912
29912
|
try {
|
|
29913
29913
|
for (const G of B) {
|
|
29914
29914
|
for (const le of G.ids) ga.unstageLink(G.stagingKey, le);
|
|
29915
|
-
|
|
29915
|
+
qr.current.get(G.parent) === E && qr.current.delete(G.parent);
|
|
29916
29916
|
}
|
|
29917
29917
|
} finally {
|
|
29918
29918
|
dr.current -= 1;
|
|
@@ -29924,7 +29924,7 @@ function K3({
|
|
|
29924
29924
|
), Ka = Cn((E, B, G, le) => {
|
|
29925
29925
|
if (le.length === 0) return;
|
|
29926
29926
|
const me = Oa.current.get(E) ?? [];
|
|
29927
|
-
me.push({ parent: B, stagingKey: G, ids: le }), Oa.current.set(E, me),
|
|
29927
|
+
me.push({ parent: B, stagingKey: G, ids: le }), Oa.current.set(E, me), qr.current.set(B, E);
|
|
29928
29928
|
}, []), Us = Cn(
|
|
29929
29929
|
(E, B, G = 0, le, me) => {
|
|
29930
29930
|
if (B == null || B === "" || G > 3) return;
|
|
@@ -29962,7 +29962,7 @@ function K3({
|
|
|
29962
29962
|
try {
|
|
29963
29963
|
const Ln = va.parent_field;
|
|
29964
29964
|
if (Zn.has(Ln)) {
|
|
29965
|
-
if ((((xt =
|
|
29965
|
+
if ((((xt = Fr.current[Ln]) == null ? void 0 : xt.ids) ?? []).length > 0) continue;
|
|
29966
29966
|
} else {
|
|
29967
29967
|
const Yt = ct.current[Ln];
|
|
29968
29968
|
if (Yt != null && Yt !== "")
|
|
@@ -30018,7 +30018,7 @@ function K3({
|
|
|
30018
30018
|
const Et = va.parent_field;
|
|
30019
30019
|
if (Zn.has(Et)) {
|
|
30020
30020
|
const Yt = Zn.get(Et), _n = new Set(
|
|
30021
|
-
((($t =
|
|
30021
|
+
((($t = Fr.current[Et]) == null ? void 0 : $t.ids) ?? []).map((Gn) => String(Gn))
|
|
30022
30022
|
);
|
|
30023
30023
|
if (_n.size > 0) continue;
|
|
30024
30024
|
const un = (V ?? []).find((Gn) => Gn.field === Et), pn = (Zt = pa((un == null ? void 0 : un.options) ?? null)) == null ? void 0 : Zt.max_values;
|
|
@@ -30038,7 +30038,7 @@ function K3({
|
|
|
30038
30038
|
const Yt = ct.current[Et];
|
|
30039
30039
|
if (Yt != null && Yt !== "") continue;
|
|
30040
30040
|
const _n = ut[0];
|
|
30041
|
-
ct.current = { ...ct.current, [Et]: _n }, Lt((un) => ({ ...un, [Et]: _n })), Ht(!0), (zn = fa.current) == null || zn.call(fa, Et, _n, 1),
|
|
30041
|
+
ct.current = { ...ct.current, [Et]: _n }, Lt((un) => ({ ...un, [Et]: _n })), Ht(!0), (zn = fa.current) == null || zn.call(fa, Et, _n, 1), qr.current.set(Et, Ce), (Pn = Ra.current) == null || Pn.call(Ra, Et, _n, G + 1, Ke, Ce);
|
|
30042
30042
|
}
|
|
30043
30043
|
} catch {
|
|
30044
30044
|
}
|
|
@@ -30105,7 +30105,7 @@ function K3({
|
|
|
30105
30105
|
const ut = Zn.get(Ln);
|
|
30106
30106
|
if (!ut) return;
|
|
30107
30107
|
const Et = new Set(
|
|
30108
|
-
(((pn =
|
|
30108
|
+
(((pn = Fr.current[Ln]) == null ? void 0 : pn.ids) ?? []).map((Gn) => String(Gn))
|
|
30109
30109
|
);
|
|
30110
30110
|
if (Et.size > 0) return;
|
|
30111
30111
|
const Yt = (V ?? []).find((Gn) => Gn.field === Ln), _n = (yn = pa((Yt == null ? void 0 : Yt.options) ?? null)) == null ? void 0 : yn.max_values;
|
|
@@ -30164,7 +30164,7 @@ function K3({
|
|
|
30164
30164
|
for (const [Ce, Ke] of Object.entries(le)) {
|
|
30165
30165
|
const Ee = Zn.get(Ce);
|
|
30166
30166
|
if (!Ee) continue;
|
|
30167
|
-
const Ge = E3(Ke, (me =
|
|
30167
|
+
const Ge = E3(Ke, (me = Fr.current[Ce]) == null ? void 0 : me.ids);
|
|
30168
30168
|
for (const yt of Ge) ga.stageLink(Ee.stagingKey, yt);
|
|
30169
30169
|
}
|
|
30170
30170
|
if (Object.keys(B).length > 0) {
|
|
@@ -30327,21 +30327,21 @@ function K3({
|
|
|
30327
30327
|
takingOver: ui,
|
|
30328
30328
|
requestLock: gs,
|
|
30329
30329
|
requesting: ss
|
|
30330
|
-
} = Q_(t, I ? void 0 : L, mr), Yn = (K == null ? void 0 : K.assignments) ?? [], yr = Yn.some((E) => E.lock_conditions),
|
|
30330
|
+
} = Q_(t, I ? void 0 : L, mr), Yn = (K == null ? void 0 : K.assignments) ?? [], yr = Yn.some((E) => E.lock_conditions), Tr = !!(ye != null && ye.addendums_enabled) && !I, { data: ls } = se({
|
|
30331
30331
|
queryKey: ["current-user-me"],
|
|
30332
30332
|
queryFn: () => q.request(Z("/users/me")).then((E) => E.data ?? null),
|
|
30333
30333
|
staleTime: 5 * 6e4,
|
|
30334
|
-
enabled: yr ||
|
|
30334
|
+
enabled: yr || Tr
|
|
30335
30335
|
}), { data: vr } = se({
|
|
30336
30336
|
queryKey: ["pipeline-instance-lock", t, L],
|
|
30337
30337
|
queryFn: () => q.request(Z(`/pipelines/instance/${t}/${L}`)).then(
|
|
30338
30338
|
(E) => E.data
|
|
30339
30339
|
).catch(() => null),
|
|
30340
30340
|
staleTime: 3e4,
|
|
30341
|
-
enabled: (yr ||
|
|
30341
|
+
enabled: (yr || Tr) && !I
|
|
30342
30342
|
}), sr = ve(() => {
|
|
30343
30343
|
var E, B, G;
|
|
30344
|
-
if (!
|
|
30344
|
+
if (!Tr) return !1;
|
|
30345
30345
|
if (ye != null && ye.addendum_allowed_roles)
|
|
30346
30346
|
try {
|
|
30347
30347
|
const le = JSON.parse(ye.addendum_allowed_roles);
|
|
@@ -30364,7 +30364,7 @@ function K3({
|
|
|
30364
30364
|
}
|
|
30365
30365
|
return !0;
|
|
30366
30366
|
}, [
|
|
30367
|
-
|
|
30367
|
+
Tr,
|
|
30368
30368
|
ye == null ? void 0 : ye.addendum_allowed_roles,
|
|
30369
30369
|
ye == null ? void 0 : ye.addendum_allowed_states,
|
|
30370
30370
|
ls == null ? void 0 : ls.role,
|
|
@@ -30372,7 +30372,7 @@ function K3({
|
|
|
30372
30372
|
]), { data: kr = [] } = se({
|
|
30373
30373
|
queryKey: ["addendums", t, L],
|
|
30374
30374
|
queryFn: () => q.request(Z(`/addendums/${t}/${L}`)).then((E) => E.data ?? []),
|
|
30375
|
-
enabled:
|
|
30375
|
+
enabled: Tr,
|
|
30376
30376
|
staleTime: 3e4
|
|
30377
30377
|
}), pr = ve(() => {
|
|
30378
30378
|
const E = {};
|
|
@@ -30389,11 +30389,11 @@ function K3({
|
|
|
30389
30389
|
var E;
|
|
30390
30390
|
Jr.current || !K || !Bs.length || (E = K.layout) != null && E.addendum_default_view && (Jr.current = !0, Pe(Bs[0].id));
|
|
30391
30391
|
}, [K, Bs]);
|
|
30392
|
-
const
|
|
30392
|
+
const jr = ve(() => {
|
|
30393
30393
|
if (ge === "original") return null;
|
|
30394
30394
|
const E = kr.find((B) => B.id === ge);
|
|
30395
30395
|
return E != null && E.data ? Object.fromEntries(Object.entries(E.data).filter(([, B]) => !Array.isArray(B))) : null;
|
|
30396
|
-
}, [ge, kr]), [lr, Cl] = S(/* @__PURE__ */ new Map()),
|
|
30396
|
+
}, [ge, kr]), [lr, Cl] = S(/* @__PURE__ */ new Map()), Ar = ve(() => {
|
|
30397
30397
|
const E = /* @__PURE__ */ new Map();
|
|
30398
30398
|
for (const B of V ?? [])
|
|
30399
30399
|
if (!(B.computed_type !== "rollup" || !B.computed_formula))
|
|
@@ -30406,8 +30406,8 @@ function K3({
|
|
|
30406
30406
|
E.set(le, [...me]);
|
|
30407
30407
|
}
|
|
30408
30408
|
return E;
|
|
30409
|
-
}, [V]), U = Me(
|
|
30410
|
-
U.current =
|
|
30409
|
+
}, [V]), U = Me(Ar);
|
|
30410
|
+
U.current = Ar;
|
|
30411
30411
|
const Te = Me(/* @__PURE__ */ new Map()), pt = Cn((E, B, G) => {
|
|
30412
30412
|
const le = `${E}.${B}`;
|
|
30413
30413
|
if (G === null) {
|
|
@@ -30445,13 +30445,13 @@ function K3({
|
|
|
30445
30445
|
if (!I)
|
|
30446
30446
|
return [];
|
|
30447
30447
|
const E = [];
|
|
30448
|
-
for (const B of
|
|
30448
|
+
for (const B of Ar.keys()) {
|
|
30449
30449
|
if (lr.has(B)) continue;
|
|
30450
30450
|
const G = Tt.get(B) ?? [];
|
|
30451
30451
|
G.length !== 0 && E.push({ key: B, collection: B.split(".")[0], rows: G });
|
|
30452
30452
|
}
|
|
30453
30453
|
return E;
|
|
30454
|
-
}, [I,
|
|
30454
|
+
}, [I, Ar, lr, Tt]), zr = wa({
|
|
30455
30455
|
queries: hr.map((E) => ({
|
|
30456
30456
|
queryKey: ["field-config", E.collection, null],
|
|
30457
30457
|
queryFn: () => q.request(Z(`/field-config/${E.collection}`)).then((B) => B.data ?? []),
|
|
@@ -30493,8 +30493,8 @@ function K3({
|
|
|
30493
30493
|
}
|
|
30494
30494
|
return E;
|
|
30495
30495
|
}, [V, lr, Nr]), rl = ve(
|
|
30496
|
-
() =>
|
|
30497
|
-
[rt,
|
|
30496
|
+
() => jr ? { ...rt, ...jr } : rt,
|
|
30497
|
+
[rt, jr]
|
|
30498
30498
|
), Na = ge !== "original", Ws = Na ? "nivaro_addendums" : t, is = Na ? ge : L, fr = ve(() => {
|
|
30499
30499
|
const E = {};
|
|
30500
30500
|
for (const B of kr)
|
|
@@ -33562,7 +33562,7 @@ ${le.join(`
|
|
|
33562
33562
|
}
|
|
33563
33563
|
)
|
|
33564
33564
|
] }),
|
|
33565
|
-
!I &&
|
|
33565
|
+
!I && Tr && kr.length > 0 && /* @__PURE__ */ a("div", { className: "relative", children: [
|
|
33566
33566
|
/* @__PURE__ */ a(
|
|
33567
33567
|
"button",
|
|
33568
33568
|
{
|
|
@@ -33769,7 +33769,7 @@ ${le.join(`
|
|
|
33769
33769
|
},
|
|
33770
33770
|
"__owners__"
|
|
33771
33771
|
);
|
|
33772
|
-
const le = xa[G.field], me = Bl.get(G.field), Ce = le ? le.ids : me ?? rl[G.field], Ee = Na && !le &&
|
|
33772
|
+
const le = xa[G.field], me = Bl.get(G.field), Ce = le ? le.ids : me ?? rl[G.field], Ee = Na && !le && jr != null && G.field in jr && String(rt[G.field] ?? "") !== String(jr[G.field] ?? "") ? "text-amber-600 dark:text-amber-400" : G.color === "cyan" ? "text-nvr-cyan" : G.color === "blue" ? "text-blue-600 dark:text-blue-400" : G.color === "green" ? "text-emerald-600 dark:text-emerald-400" : G.color === "amber" ? "text-amber-600 dark:text-amber-400" : G.color === "red" ? "text-red-600 dark:text-red-400" : G.color === "purple" ? "text-purple-600 dark:text-purple-400" : "text-slate-900 dark:text-slate-100", Ge = G.weight === "bold" ? "font-bold" : G.weight === "semibold" ? "font-semibold" : G.weight === "medium" ? "font-medium" : "font-semibold", yt = `${Ee} ${Ge}`, _t = G.displayAs === "pill", It = G.displayAs === "tag";
|
|
33773
33773
|
return /* @__PURE__ */ a(
|
|
33774
33774
|
"div",
|
|
33775
33775
|
{
|
|
@@ -33939,7 +33939,7 @@ ${le.join(`
|
|
|
33939
33939
|
className: "flex items-center gap-3 rounded-lg border border-amber-300 bg-amber-50 px-3.5 py-2.5 dark:border-amber-500/40 dark:bg-amber-500/10",
|
|
33940
33940
|
"data-stale-record-banner": !0,
|
|
33941
33941
|
children: [
|
|
33942
|
-
/* @__PURE__ */ e(
|
|
33942
|
+
/* @__PURE__ */ e(Rr, { className: "h-4 w-4 shrink-0 text-amber-500" }),
|
|
33943
33943
|
/* @__PURE__ */ a("p", { className: "min-w-0 flex-1 text-[12px] text-amber-800 dark:text-amber-300", children: [
|
|
33944
33944
|
/* @__PURE__ */ e("span", { className: "font-semibold", children: Eh }),
|
|
33945
33945
|
" changed this record while you had it open",
|
|
@@ -34733,7 +34733,7 @@ const W3 = [
|
|
|
34733
34733
|
{ label: "Relative time", cfg: { type: "datetime", template: "relative" } },
|
|
34734
34734
|
{ label: "Yes / No", cfg: { type: "boolean", true_label: "Yes", false_label: "No" } },
|
|
34735
34735
|
{ label: "Count (related)", cfg: { type: "count" } }
|
|
34736
|
-
],
|
|
34736
|
+
], Or = (t) => t.replace(/_/g, " ").replace(/\b\w/g, (n) => n.toUpperCase()), hh = ["name", "title", "label", "display_name", "subject", "email", "slug"];
|
|
34737
34737
|
function C0(t, n) {
|
|
34738
34738
|
if (!t) return ["id", n, ...hh].join(",");
|
|
34739
34739
|
const r = [...t.matchAll(/\{\{([\w.]+)\}\}/g)].map((s) => s[1]);
|
|
@@ -35314,7 +35314,7 @@ function G3({
|
|
|
35314
35314
|
{
|
|
35315
35315
|
block: !0,
|
|
35316
35316
|
label: "All",
|
|
35317
|
-
options: o.map((c) => ({ value: String(c), label:
|
|
35317
|
+
options: o.map((c) => ({ value: String(c), label: Or(String(c)) })),
|
|
35318
35318
|
selected: r,
|
|
35319
35319
|
onChange: s,
|
|
35320
35320
|
loading: u,
|
|
@@ -35609,13 +35609,13 @@ function xh({
|
|
|
35609
35609
|
v || y ? m((x) => {
|
|
35610
35610
|
const b = new Set(x);
|
|
35611
35611
|
return b.has(h.field) ? b.delete(h.field) : b.add(h.field), b;
|
|
35612
|
-
}) : d([...r, h.field], [...s,
|
|
35612
|
+
}) : d([...r, h.field], [...s, Or(h.field)], h.type ?? "string");
|
|
35613
35613
|
},
|
|
35614
35614
|
className: "flex w-full items-center gap-1.5 px-3 py-1.5 text-left text-[12.5px] text-slate-700 hover:bg-slate-50 dark:text-slate-200 dark:hover:bg-slate-800",
|
|
35615
35615
|
style: { paddingLeft: `${0.5 + n}rem` },
|
|
35616
35616
|
children: [
|
|
35617
35617
|
v || y ? g ? "▾ " : "▸ " : "",
|
|
35618
|
-
|
|
35618
|
+
Or(h.field),
|
|
35619
35619
|
y && /* @__PURE__ */ e("span", { className: "text-[10px] text-slate-400", children: y.kind })
|
|
35620
35620
|
]
|
|
35621
35621
|
}
|
|
@@ -35626,7 +35626,7 @@ function xh({
|
|
|
35626
35626
|
relatedCollection: v,
|
|
35627
35627
|
depth: n + 1,
|
|
35628
35628
|
path: [...r, h.field],
|
|
35629
|
-
pathLabels: [...s,
|
|
35629
|
+
pathLabels: [...s, Or(h.field)],
|
|
35630
35630
|
filterText: "",
|
|
35631
35631
|
includeAliases: i,
|
|
35632
35632
|
onPick: d
|
|
@@ -35638,7 +35638,7 @@ function xh({
|
|
|
35638
35638
|
aliasInfo: y,
|
|
35639
35639
|
depth: n + 1,
|
|
35640
35640
|
path: [...r, h.field],
|
|
35641
|
-
pathLabels: [...s,
|
|
35641
|
+
pathLabels: [...s, Or(h.field)],
|
|
35642
35642
|
includeAliases: i,
|
|
35643
35643
|
onPick: d
|
|
35644
35644
|
}
|
|
@@ -35735,7 +35735,7 @@ function nS({
|
|
|
35735
35735
|
const h = s.trim().toLowerCase(), f = (x) => !h || x.toLowerCase().includes(h) || x.toLowerCase().replace(/ /g, "_").includes(h), y = [];
|
|
35736
35736
|
for (const x of u.fields) {
|
|
35737
35737
|
if (x.hidden) continue;
|
|
35738
|
-
const b =
|
|
35738
|
+
const b = Or(x.field), F = Ns(u.relations, t, x.field), C = kc(u.relations, t, x.field), A = [...n, x.field], N = [...r, b];
|
|
35739
35739
|
if (F != null && F.one_collection && !Ml(F.one_collection))
|
|
35740
35740
|
f(b) && y.push({
|
|
35741
35741
|
key: x.field,
|
|
@@ -35768,10 +35768,10 @@ function nS({
|
|
|
35768
35768
|
if (!(b != null && b.one_collection) || Ml(b.one_collection)) continue;
|
|
35769
35769
|
const F = p.get(b.one_collection);
|
|
35770
35770
|
if (!F) continue;
|
|
35771
|
-
const C =
|
|
35771
|
+
const C = Or(x.field);
|
|
35772
35772
|
for (const A of F.fields) {
|
|
35773
35773
|
if (A.hidden) continue;
|
|
35774
|
-
const N =
|
|
35774
|
+
const N = Or(A.field);
|
|
35775
35775
|
if (!f(N)) continue;
|
|
35776
35776
|
const w = Ns(F.relations, b.one_collection, A.field);
|
|
35777
35777
|
v.push({
|
|
@@ -35862,7 +35862,7 @@ function aS({
|
|
|
35862
35862
|
autoFocus: !0,
|
|
35863
35863
|
value: i,
|
|
35864
35864
|
onChange: (y) => d(y.target.value),
|
|
35865
|
-
placeholder: `Search ${
|
|
35865
|
+
placeholder: `Search ${Or(t)}…`,
|
|
35866
35866
|
className: "mx-2 mb-1 h-7 shrink-0 rounded border border-slate-200 bg-slate-50 px-2 text-[12px] outline-none focus:border-[#00ceff80] dark:border-slate-700 dark:bg-slate-800 dark:text-slate-100"
|
|
35867
35867
|
}
|
|
35868
35868
|
),
|
|
@@ -36331,7 +36331,7 @@ function lS({
|
|
|
36331
36331
|
children: [
|
|
36332
36332
|
c ? "▾" : "▸",
|
|
36333
36333
|
" ",
|
|
36334
|
-
|
|
36334
|
+
Or(d.field),
|
|
36335
36335
|
u && /* @__PURE__ */ e("span", { className: "text-[10px] text-slate-400", children: u.kind })
|
|
36336
36336
|
]
|
|
36337
36337
|
}
|
|
@@ -36342,7 +36342,7 @@ function lS({
|
|
|
36342
36342
|
relatedCollection: o.one_collection,
|
|
36343
36343
|
depth: 1,
|
|
36344
36344
|
path: [d.field],
|
|
36345
|
-
pathLabels: [
|
|
36345
|
+
pathLabels: [Or(d.field)],
|
|
36346
36346
|
filterText: "",
|
|
36347
36347
|
includeAliases: !0,
|
|
36348
36348
|
onPick: i
|
|
@@ -36354,7 +36354,7 @@ function lS({
|
|
|
36354
36354
|
aliasInfo: u,
|
|
36355
36355
|
depth: 1,
|
|
36356
36356
|
path: [d.field],
|
|
36357
|
-
pathLabels: [
|
|
36357
|
+
pathLabels: [Or(d.field)],
|
|
36358
36358
|
includeAliases: !0,
|
|
36359
36359
|
onPick: i
|
|
36360
36360
|
}
|
|
@@ -36799,7 +36799,7 @@ function dS({
|
|
|
36799
36799
|
},
|
|
36800
36800
|
children: [
|
|
36801
36801
|
/* @__PURE__ */ e(
|
|
36802
|
-
|
|
36802
|
+
$r,
|
|
36803
36803
|
{
|
|
36804
36804
|
value: k,
|
|
36805
36805
|
onChange: T,
|
|
@@ -37047,12 +37047,12 @@ function X6({
|
|
|
37047
37047
|
), ca = (z) => fa[z], dr = (z) => {
|
|
37048
37048
|
const pe = { ...fa }, Fe = pe[z];
|
|
37049
37049
|
Fe ? Fe === "left" ? pe[z] = "right" : delete pe[z] : pe[z] = "left", qs(pe);
|
|
37050
|
-
}, Oa = (z) => T[z] ?? (z.includes(".") ? z.split(".").map(
|
|
37050
|
+
}, Oa = (z) => T[z] ?? (z.includes(".") ? z.split(".").map(Or).join(" › ") : z === "id" ? "ID" : Or(z)), qr = ve(
|
|
37051
37051
|
() => Jn.filter((z) => !z.includes(".")).map((z) => ({ field: z, info: kc(Kn, t, z) })).filter((z) => !!z.info),
|
|
37052
37052
|
[Jn, ka, Kn, t]
|
|
37053
37053
|
), ga = ve(
|
|
37054
|
-
() => [...new Set(
|
|
37055
|
-
[
|
|
37054
|
+
() => [...new Set(qr.map((z) => z.info.relation.many_collection ?? "").filter(Boolean))],
|
|
37055
|
+
[qr]
|
|
37056
37056
|
), Fs = wa({
|
|
37057
37057
|
queries: ga.map((z) => ({
|
|
37058
37058
|
queryKey: ["cbv-collection-meta", z],
|
|
@@ -37069,7 +37069,7 @@ function X6({
|
|
|
37069
37069
|
}, [ga, Fs]), hs = ve(
|
|
37070
37070
|
() => [
|
|
37071
37071
|
...new Set(
|
|
37072
|
-
|
|
37072
|
+
qr.filter((z) => z.info.kind === "m2m").map((z) => {
|
|
37073
37073
|
const pe = z.info.relation.many_collection ?? "", Fe = ma.get(pe), Se = Fe == null ? void 0 : Fe.relations.find(
|
|
37074
37074
|
(Ze) => Ze.many_collection === pe && Ze.many_field === z.info.relation.junction_field
|
|
37075
37075
|
);
|
|
@@ -37077,7 +37077,7 @@ function X6({
|
|
|
37077
37077
|
}).filter(Boolean)
|
|
37078
37078
|
)
|
|
37079
37079
|
],
|
|
37080
|
-
[
|
|
37080
|
+
[qr, ma]
|
|
37081
37081
|
), za = wa({
|
|
37082
37082
|
queries: hs.map((z) => ({
|
|
37083
37083
|
queryKey: ["cbv-collection-meta", z],
|
|
@@ -37093,7 +37093,7 @@ function X6({
|
|
|
37093
37093
|
}), z;
|
|
37094
37094
|
}, [hs, za]), Pa = ve(() => {
|
|
37095
37095
|
const z = {};
|
|
37096
|
-
for (const pe of
|
|
37096
|
+
for (const pe of qr) {
|
|
37097
37097
|
const Fe = pe.info.relation.many_collection ?? "";
|
|
37098
37098
|
if (pe.info.kind === "o2m")
|
|
37099
37099
|
z[pe.field] = `${pe.field}.${Ku(ma.get(Fe))}`;
|
|
@@ -37105,9 +37105,9 @@ function X6({
|
|
|
37105
37105
|
}
|
|
37106
37106
|
}
|
|
37107
37107
|
return z;
|
|
37108
|
-
}, [
|
|
37108
|
+
}, [qr, ma, ar]), tl = ve(() => {
|
|
37109
37109
|
const z = {};
|
|
37110
|
-
for (const pe of
|
|
37110
|
+
for (const pe of qr)
|
|
37111
37111
|
if (pe.info.kind === "o2m")
|
|
37112
37112
|
z[pe.field] = { kind: "o2m" };
|
|
37113
37113
|
else {
|
|
@@ -37117,7 +37117,7 @@ function X6({
|
|
|
37117
37117
|
Ze != null && Ze.one_collection && (z[pe.field] = { kind: "m2m", target: Ze.one_collection });
|
|
37118
37118
|
}
|
|
37119
37119
|
return z;
|
|
37120
|
-
}, [
|
|
37120
|
+
}, [qr, ma]), fs = No(be, 350), ua = ve(() => {
|
|
37121
37121
|
var pe, Fe;
|
|
37122
37122
|
const z = [];
|
|
37123
37123
|
for (const Se of C) {
|
|
@@ -37188,14 +37188,14 @@ function X6({
|
|
|
37188
37188
|
Le(() => {
|
|
37189
37189
|
xa.current !== ua && (xa.current = ua, g(1));
|
|
37190
37190
|
}, [ua]);
|
|
37191
|
-
const
|
|
37191
|
+
const Fr = Object.keys(P).filter((z) => !z.includes(".") && !z.startsWith("__")).sort().join(","), {
|
|
37192
37192
|
data: Ua,
|
|
37193
37193
|
isLoading: Ts,
|
|
37194
37194
|
isFetching: nl,
|
|
37195
37195
|
refetch: xs,
|
|
37196
37196
|
error: as
|
|
37197
37197
|
} = se({
|
|
37198
|
-
queryKey: ["cbv-items", t, F, N, ht ? "grouped" : v, ht ? 500 : Wn, ua,
|
|
37198
|
+
queryKey: ["cbv-items", t, F, N, ht ? "grouped" : v, ht ? 500 : Wn, ua, Fr],
|
|
37199
37199
|
queryFn: () => p.request(
|
|
37200
37200
|
Z(`/items/${t}`, {
|
|
37201
37201
|
limit: ht ? 500 : Wn,
|
|
@@ -37203,7 +37203,7 @@ function X6({
|
|
|
37203
37203
|
...F ? { search: F } : {},
|
|
37204
37204
|
...N ? { sort: N } : {},
|
|
37205
37205
|
...ua ? { conditions: ua } : {},
|
|
37206
|
-
...
|
|
37206
|
+
...Fr ? { agg: Fr } : {}
|
|
37207
37207
|
})
|
|
37208
37208
|
),
|
|
37209
37209
|
enabled: !!t && J,
|
|
@@ -37372,7 +37372,7 @@ function X6({
|
|
|
37372
37372
|
Ot && Yn(pe, { kind: "date", value: `r:${Ot}..${Ot}` });
|
|
37373
37373
|
}
|
|
37374
37374
|
}
|
|
37375
|
-
},
|
|
37375
|
+
}, Tr = (z, pe) => {
|
|
37376
37376
|
if (z === "__state__") return !1;
|
|
37377
37377
|
const Fe = ss(z);
|
|
37378
37378
|
return Fe ? Fe.kind === "in" ? !!Ns(Kn, t, z) && pe[z] != null : Fe.kind === "enum" || Fe.kind === "num" ? pe[z] != null && pe[z] !== "" : Fe.kind === "text" : !1;
|
|
@@ -37489,7 +37489,7 @@ function X6({
|
|
|
37489
37489
|
queryKey: ["cbv-views", t],
|
|
37490
37490
|
queryFn: () => p.request(Z("/saved-views", { collection: t })).then((z) => z.data ?? []),
|
|
37491
37491
|
staleTime: 3e4
|
|
37492
|
-
}),
|
|
37492
|
+
}), jr = () => h.invalidateQueries({ queryKey: ["cbv-views", t] }), lr = (z) => {
|
|
37493
37493
|
var pe, Fe;
|
|
37494
37494
|
if (xn(z.id), A(z.filters ?? []), w(z.sort ?? ""), (pe = z.columns) != null && pe.length) {
|
|
37495
37495
|
const Ze = z.columns.map(B3).filter((Bn) => Bn.includes(".") || ka.has(Bn));
|
|
@@ -37508,7 +37508,7 @@ function X6({
|
|
|
37508
37508
|
return;
|
|
37509
37509
|
}
|
|
37510
37510
|
xn(null), A([]), w(s ?? ""), k(r ?? null), $({}), q({}), W({}), qs(null), g(1);
|
|
37511
|
-
},
|
|
37511
|
+
}, Ar = () => ({
|
|
37512
37512
|
filters: C,
|
|
37513
37513
|
sort: N,
|
|
37514
37514
|
columns: [
|
|
@@ -37558,26 +37558,26 @@ function X6({
|
|
|
37558
37558
|
F && pe.set("search", F), ua && pe.set("conditions", ua), N && pe.set("sort", N), window.open(`/api/export-presets/${z}/run?${pe.toString()}`, "_blank");
|
|
37559
37559
|
}, on = Ue({
|
|
37560
37560
|
mutationFn: () => p.request(
|
|
37561
|
-
Ie("/saved-views", { collection: t, name: Ct.trim(), ...
|
|
37561
|
+
Ie("/saved-views", { collection: t, name: Ct.trim(), ...Ar() })
|
|
37562
37562
|
),
|
|
37563
37563
|
onSuccess: (z) => {
|
|
37564
|
-
wt(!1), an(""), xn(z.data.id),
|
|
37564
|
+
wt(!1), an(""), xn(z.data.id), jr();
|
|
37565
37565
|
}
|
|
37566
37566
|
}), Hn = Ue({
|
|
37567
|
-
mutationFn: (z) => p.request(Fn(`/saved-views/${z}`,
|
|
37568
|
-
onSuccess:
|
|
37567
|
+
mutationFn: (z) => p.request(Fn(`/saved-views/${z}`, Ar())),
|
|
37568
|
+
onSuccess: jr
|
|
37569
37569
|
}), ea = Ue({
|
|
37570
37570
|
mutationFn: ({ id: z, on: pe }) => p.request(Fn(`/saved-views/${z}`, { is_default: pe })),
|
|
37571
|
-
onSuccess:
|
|
37571
|
+
onSuccess: jr
|
|
37572
37572
|
}), Ir = Ue({
|
|
37573
37573
|
mutationFn: () => {
|
|
37574
37574
|
const z = Jr.find((pe) => pe.is_default);
|
|
37575
|
-
return z ? p.request(Fn(`/saved-views/${z.id}`, { ...
|
|
37576
|
-
Ie("/saved-views", { collection: t, name: "Default", is_default: !0, ...
|
|
37575
|
+
return z ? p.request(Fn(`/saved-views/${z.id}`, { ...Ar(), is_default: !0 })) : p.request(
|
|
37576
|
+
Ie("/saved-views", { collection: t, name: "Default", is_default: !0, ...Ar() })
|
|
37577
37577
|
);
|
|
37578
37578
|
},
|
|
37579
37579
|
onSuccess: () => {
|
|
37580
|
-
$e(!1),
|
|
37580
|
+
$e(!1), jr();
|
|
37581
37581
|
}
|
|
37582
37582
|
}), hr = Ue({
|
|
37583
37583
|
mutationFn: (z) => p.request(Mn(`/items/${t}/${z}`)),
|
|
@@ -37585,7 +37585,7 @@ function X6({
|
|
|
37585
37585
|
}), zr = Ue({
|
|
37586
37586
|
mutationFn: (z) => p.request(Mn(`/saved-views/${z}`)),
|
|
37587
37587
|
onSuccess: (z, pe) => {
|
|
37588
|
-
zt === pe && Cl(),
|
|
37588
|
+
zt === pe && Cl(), jr();
|
|
37589
37589
|
}
|
|
37590
37590
|
}), { data: Nr = [] } = se({
|
|
37591
37591
|
queryKey: ["cbv-view-subs"],
|
|
@@ -37931,7 +37931,7 @@ function X6({
|
|
|
37931
37931
|
]
|
|
37932
37932
|
}
|
|
37933
37933
|
),
|
|
37934
|
-
|
|
37934
|
+
Tr(bt.key, bt.row) && bt.cellText && bt.cellText !== "—" && /* @__PURE__ */ a(
|
|
37935
37935
|
"button",
|
|
37936
37936
|
{
|
|
37937
37937
|
type: "button",
|
|
@@ -38267,7 +38267,7 @@ function X6({
|
|
|
38267
38267
|
{
|
|
38268
38268
|
autoFocus: !0,
|
|
38269
38269
|
value: T[z] ?? "",
|
|
38270
|
-
placeholder: z.includes(".") ? z.split(".").map(
|
|
38270
|
+
placeholder: z.includes(".") ? z.split(".").map(Or).join(" › ") : Or(z),
|
|
38271
38271
|
onChange: (Se) => $((Ze) => {
|
|
38272
38272
|
const vt = { ...Ze };
|
|
38273
38273
|
return Se.target.value ? vt[z] = Se.target.value : delete vt[z], vt;
|
|
@@ -38468,7 +38468,7 @@ function X6({
|
|
|
38468
38468
|
className: "flex w-full items-center gap-1.5 rounded px-1.5 py-1 text-left text-[12px] text-slate-600 hover:bg-slate-50 dark:text-slate-300 dark:hover:bg-slate-800",
|
|
38469
38469
|
children: [
|
|
38470
38470
|
/* @__PURE__ */ e("span", { "aria-hidden": !0, className: "text-slate-400", children: "+" }),
|
|
38471
|
-
/* @__PURE__ */ e("span", { className: "truncate", children:
|
|
38471
|
+
/* @__PURE__ */ e("span", { className: "truncate", children: Or(z.field) })
|
|
38472
38472
|
]
|
|
38473
38473
|
},
|
|
38474
38474
|
z.field
|
|
@@ -39504,7 +39504,7 @@ function cS({
|
|
|
39504
39504
|
g && "bg-amber-50/70 dark:bg-amber-400/10"
|
|
39505
39505
|
),
|
|
39506
39506
|
children: [
|
|
39507
|
-
/* @__PURE__ */ e("td", { className: "px-3 py-1.5 text-slate-500 dark:text-muted-foreground", children:
|
|
39507
|
+
/* @__PURE__ */ e("td", { className: "px-3 py-1.5 text-slate-500 dark:text-muted-foreground", children: Or(y.field) }),
|
|
39508
39508
|
v.map((x, b) => /* @__PURE__ */ e(
|
|
39509
39509
|
"td",
|
|
39510
39510
|
{
|
|
@@ -43308,7 +43308,7 @@ val1,val2,val3`,
|
|
|
43308
43308
|
/* @__PURE__ */ a("div", { className: "space-y-1.5", children: [
|
|
43309
43309
|
/* @__PURE__ */ e(Sn, { className: "text-[11.5px]", children: "When a record already exists" }),
|
|
43310
43310
|
/* @__PURE__ */ e(
|
|
43311
|
-
|
|
43311
|
+
$r,
|
|
43312
43312
|
{
|
|
43313
43313
|
value: C,
|
|
43314
43314
|
onChange: A,
|
|
@@ -43743,15 +43743,16 @@ function Tp(t, n) {
|
|
|
43743
43743
|
const l = r.columns ?? {};
|
|
43744
43744
|
if (r.columns && (typeof r.columns != "object" || Array.isArray(r.columns))) return null;
|
|
43745
43745
|
const i = /* @__PURE__ */ new Set(), d = [], o = (p) => {
|
|
43746
|
-
var f, y;
|
|
43746
|
+
var f, y, v, g;
|
|
43747
43747
|
const h = l[p];
|
|
43748
43748
|
return {
|
|
43749
43749
|
col: p,
|
|
43750
43750
|
field: (h == null ? void 0 : h.field) ?? "",
|
|
43751
|
-
type:
|
|
43751
|
+
type: ["number", "int", "date", "datetime", "boolean"].includes((h == null ? void 0 : h.type) ?? "") ? h.type : "",
|
|
43752
43752
|
lookupOn: !!(h != null && h.lookup),
|
|
43753
43753
|
lookupCollection: ((f = h == null ? void 0 : h.lookup) == null ? void 0 : f.collection) ?? "",
|
|
43754
|
-
lookupField: ((y = h == null ? void 0 : h.lookup) == null ? void 0 : y.match_field) ?? ""
|
|
43754
|
+
lookupField: ((y = h == null ? void 0 : h.lookup) == null ? void 0 : y.match_field) ?? "",
|
|
43755
|
+
lookupOnMissing: ((v = h == null ? void 0 : h.lookup) == null ? void 0 : v.on_missing) === "create" || ((g = h == null ? void 0 : h.lookup) == null ? void 0 : g.on_missing) === "null" ? h.lookup.on_missing : ""
|
|
43755
43756
|
};
|
|
43756
43757
|
};
|
|
43757
43758
|
for (const p of n)
|
|
@@ -43780,7 +43781,11 @@ function IS(t) {
|
|
|
43780
43781
|
for (const s of t.rows) {
|
|
43781
43782
|
if (!s.field) continue;
|
|
43782
43783
|
const l = { field: s.field };
|
|
43783
|
-
s.lookupOn && s.lookupCollection && s.lookupField ? l.lookup = {
|
|
43784
|
+
s.lookupOn && s.lookupCollection && s.lookupField ? l.lookup = {
|
|
43785
|
+
collection: s.lookupCollection,
|
|
43786
|
+
match_field: s.lookupField,
|
|
43787
|
+
...s.lookupOnMissing ? { on_missing: s.lookupOnMissing } : {}
|
|
43788
|
+
} : s.type && (l.type = s.type), n[s.col] = l;
|
|
43784
43789
|
}
|
|
43785
43790
|
const r = {
|
|
43786
43791
|
collection: t.collection,
|
|
@@ -44004,14 +44009,17 @@ function zS({
|
|
|
44004
44009
|
}
|
|
44005
44010
|
) }),
|
|
44006
44011
|
/* @__PURE__ */ e("td", { className: "px-2 py-1", children: C.lookupOn ? /* @__PURE__ */ e("span", { className: "text-[11px] text-slate-400", children: "Lookup ↓" }) : /* @__PURE__ */ e(
|
|
44007
|
-
|
|
44012
|
+
$r,
|
|
44008
44013
|
{
|
|
44009
44014
|
value: C.type,
|
|
44010
44015
|
onChange: (_) => N({ type: _ }),
|
|
44011
44016
|
options: [
|
|
44012
44017
|
{ value: "", label: "Text" },
|
|
44013
44018
|
{ value: "number", label: "Number" },
|
|
44014
|
-
{ value: "int", label: "Whole number" }
|
|
44019
|
+
{ value: "int", label: "Whole number" },
|
|
44020
|
+
{ value: "date", label: "Date" },
|
|
44021
|
+
{ value: "datetime", label: "Date & time" },
|
|
44022
|
+
{ value: "boolean", label: "Yes/No" }
|
|
44015
44023
|
],
|
|
44016
44024
|
className: "h-7 w-[130px] text-[12px]"
|
|
44017
44025
|
}
|
|
@@ -44057,7 +44065,21 @@ function zS({
|
|
|
44057
44065
|
onChange: (_) => N({ lookupField: _ })
|
|
44058
44066
|
}
|
|
44059
44067
|
),
|
|
44060
|
-
/* @__PURE__ */ e("span", { children: "equals the file value, and store its id." })
|
|
44068
|
+
/* @__PURE__ */ e("span", { children: "equals the file value, and store its id." }),
|
|
44069
|
+
/* @__PURE__ */ e("span", { className: "ml-1", children: "If no match:" }),
|
|
44070
|
+
/* @__PURE__ */ e(
|
|
44071
|
+
$r,
|
|
44072
|
+
{
|
|
44073
|
+
value: C.lookupOnMissing,
|
|
44074
|
+
onChange: (_) => N({ lookupOnMissing: _ }),
|
|
44075
|
+
options: [
|
|
44076
|
+
{ value: "", label: "skip the file row" },
|
|
44077
|
+
{ value: "null", label: "leave the link empty" },
|
|
44078
|
+
{ value: "create", label: "create a new record" }
|
|
44079
|
+
],
|
|
44080
|
+
className: "h-6 w-[180px] text-[11.5px]"
|
|
44081
|
+
}
|
|
44082
|
+
)
|
|
44061
44083
|
] }) })
|
|
44062
44084
|
] })
|
|
44063
44085
|
] }, C.col);
|
|
@@ -44086,7 +44108,7 @@ function zS({
|
|
|
44086
44108
|
...o,
|
|
44087
44109
|
rows: [
|
|
44088
44110
|
...o.rows,
|
|
44089
|
-
{ col: x.trim(), field: "", type: "", lookupOn: !1, lookupCollection: "", lookupField: "" }
|
|
44111
|
+
{ col: x.trim(), field: "", type: "", lookupOn: !1, lookupCollection: "", lookupField: "", lookupOnMissing: "" }
|
|
44090
44112
|
]
|
|
44091
44113
|
}), b("");
|
|
44092
44114
|
},
|
|
@@ -44434,7 +44456,7 @@ function QS({
|
|
|
44434
44456
|
}
|
|
44435
44457
|
) }),
|
|
44436
44458
|
/* @__PURE__ */ e("td", { className: "px-2 py-1", children: /* @__PURE__ */ e(
|
|
44437
|
-
|
|
44459
|
+
$r,
|
|
44438
44460
|
{
|
|
44439
44461
|
value: m.type,
|
|
44440
44462
|
onChange: (f) => h({ type: f }),
|
|
@@ -45062,7 +45084,7 @@ function YS({
|
|
|
45062
45084
|
label: "Loader",
|
|
45063
45085
|
hint: "Bulk pushes a file to the share and BULK INSERTs it; insert batches rows directly. Ignored in service mode.",
|
|
45064
45086
|
children: /* @__PURE__ */ e(
|
|
45065
|
-
|
|
45087
|
+
$r,
|
|
45066
45088
|
{
|
|
45067
45089
|
value: c.loader,
|
|
45068
45090
|
onChange: (_) => m((k) => ({ ...k, loader: _ })),
|
|
@@ -45082,7 +45104,7 @@ function YS({
|
|
|
45082
45104
|
label: "Processor",
|
|
45083
45105
|
hint: "Stored procedure MERGEs staging rows (no revisions). Items service diffs and writes only real changes — revisions, activity, rules and computed fields apply.",
|
|
45084
45106
|
children: /* @__PURE__ */ e(
|
|
45085
|
-
|
|
45107
|
+
$r,
|
|
45086
45108
|
{
|
|
45087
45109
|
value: c.processor,
|
|
45088
45110
|
onChange: (_) => m((k) => ({ ...k, processor: _ })),
|
|
@@ -45581,7 +45603,7 @@ function t4({
|
|
|
45581
45603
|
] }),
|
|
45582
45604
|
j.validation && j.validation.errors.length > 0 && /* @__PURE__ */ a("div", { className: "rounded-md border border-red-200 bg-red-50 px-3 py-2 text-[11.5px] text-red-800 dark:border-red-900 dark:bg-red-950/40 dark:text-red-300", children: [
|
|
45583
45605
|
/* @__PURE__ */ a("p", { className: "mb-1 flex items-center gap-1.5 font-medium", children: [
|
|
45584
|
-
/* @__PURE__ */ e(
|
|
45606
|
+
/* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5" }),
|
|
45585
45607
|
" This file fails validation — it cannot be queued until fixed"
|
|
45586
45608
|
] }),
|
|
45587
45609
|
j.validation.errors.map((P) => /* @__PURE__ */ a("p", { children: [
|
|
@@ -45617,7 +45639,7 @@ function t4({
|
|
|
45617
45639
|
] }),
|
|
45618
45640
|
D && /* @__PURE__ */ a("div", { className: "rounded-md border border-amber-200 bg-amber-50 px-3 py-2 text-[11.5px] text-amber-800 dark:border-amber-900 dark:bg-amber-950/40 dark:text-amber-300", children: [
|
|
45619
45641
|
/* @__PURE__ */ a("p", { className: "mb-1 flex items-center gap-1.5 font-medium", children: [
|
|
45620
|
-
/* @__PURE__ */ e(
|
|
45642
|
+
/* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5" }),
|
|
45621
45643
|
" This file doesn't match",
|
|
45622
45644
|
" ",
|
|
45623
45645
|
/* @__PURE__ */ e("span", { className: "font-mono", children: j.staging_table })
|
|
@@ -46068,7 +46090,7 @@ function nF({
|
|
|
46068
46090
|
] })
|
|
46069
46091
|
] }),
|
|
46070
46092
|
T && /* @__PURE__ */ a("p", { className: "flex items-center gap-1.5 rounded-md border border-red-200 bg-red-50 px-3 py-2 text-[12px] text-red-700 dark:border-red-900 dark:bg-red-950/40 dark:text-red-400", children: [
|
|
46071
|
-
/* @__PURE__ */ e(
|
|
46093
|
+
/* @__PURE__ */ e(Rr, { className: "h-3.5 w-3.5 shrink-0" }),
|
|
46072
46094
|
T
|
|
46073
46095
|
] }),
|
|
46074
46096
|
m === "collection" ? /* @__PURE__ */ e(RS, { initialJobId: r, onJobOpen: s }) : m === "definitions" ? /* @__PURE__ */ e(
|
|
@@ -61106,7 +61128,7 @@ function E$({
|
|
|
61106
61128
|
] });
|
|
61107
61129
|
}
|
|
61108
61130
|
function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
61109
|
-
var pr, Bs, Jr,
|
|
61131
|
+
var pr, Bs, Jr, jr, lr, Cl, Ar;
|
|
61110
61132
|
const s = jt(), l = je(), { userId: i } = Ss(), d = Is(), { navigate: o } = Ks(), [u, c] = S("all"), [m, p] = S(1), [h, f] = S(() => {
|
|
61111
61133
|
try {
|
|
61112
61134
|
return localStorage.getItem("nvr_table_density") === "comfortable" ? "comfortable" : "compact";
|
|
@@ -61546,7 +61568,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
61546
61568
|
queryKey: ["queue-views", t],
|
|
61547
61569
|
queryFn: () => l.request(Z(`/queues/${t}/views`)),
|
|
61548
61570
|
enabled: !!t
|
|
61549
|
-
}), [dr, Oa] = S(null), [
|
|
61571
|
+
}), [dr, Oa] = S(null), [qr, ga] = S(!1), [Fs, ma] = S(""), [hs, za] = S(!1), [ar, Pa] = S(!1);
|
|
61550
61572
|
function tl(U) {
|
|
61551
61573
|
const Te = U.state ?? {};
|
|
61552
61574
|
c(Te.scope ?? "all"), F({ ...V.current, ...Te.filters ?? {} }), x(Te.sort ?? ""), A(Te.group_by ?? null), we(Te.columns ?? null), $(Te.pins ?? null), Te.view && v(ye.includes(Te.view) ? Te.view : ye[0]), p(1), Oa(U.id);
|
|
@@ -61627,9 +61649,9 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
61627
61649
|
onError: () => {
|
|
61628
61650
|
s.invalidateQueries({ queryKey: ["queue-column-prefs", t] }), Ae.error("Failed to update default view");
|
|
61629
61651
|
}
|
|
61630
|
-
}), [
|
|
61652
|
+
}), [Fr, Ua] = S([]), [Ts, nl] = S(!1);
|
|
61631
61653
|
async function xs(U, Te) {
|
|
61632
|
-
const pt = an.filter((Hn) =>
|
|
61654
|
+
const pt = an.filter((Hn) => Fr.includes(bn(Hn)));
|
|
61633
61655
|
nl(!0);
|
|
61634
61656
|
const Dt = await Promise.allSettled(pt.map(Te)), ln = Dt.filter((Hn) => Hn.status === "fulfilled").length, on = Dt.length - ln;
|
|
61635
61657
|
nl(!1), Ua([]), s.invalidateQueries({ queryKey: ["queue-items", t] }), on ? Ae.warning(`${U}: ${ln} succeeded, ${on} failed`) : Ae.success(`${U}: ${ln} succeeded`);
|
|
@@ -61936,7 +61958,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
61936
61958
|
{ value: "owners", label: "Owner" },
|
|
61937
61959
|
{ value: "aging", label: "Aging" },
|
|
61938
61960
|
...rs.filter((U) => Kr.has(`extra.${U}`)).map((U) => ({ value: `extra.${U}`, label: Be(`extra.${U}`, zd(U)) }))
|
|
61939
|
-
],
|
|
61961
|
+
], Tr = (U) => async (Te) => {
|
|
61940
61962
|
if (!U.target_collection || !U.display_field) return [];
|
|
61941
61963
|
const pt = {
|
|
61942
61964
|
limit: 25,
|
|
@@ -62040,7 +62062,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62040
62062
|
type: "combobox",
|
|
62041
62063
|
multi: !0,
|
|
62042
62064
|
restricted: !!((pt = K[U]) != null && pt.length),
|
|
62043
|
-
loadOptions:
|
|
62065
|
+
loadOptions: Tr(Te)
|
|
62044
62066
|
} : {
|
|
62045
62067
|
key: `extra.${U}`,
|
|
62046
62068
|
placeholder: `Search ${Be(`extra.${U}`, zd(U))}…`,
|
|
@@ -62055,7 +62077,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62055
62077
|
return P ? (r == null ? void 0 : r((P == null ? void 0 : P.status) ?? 500)) ?? null : /* @__PURE__ */ a("div", { className: "flex flex-1 min-h-0 flex-col", children: [
|
|
62056
62078
|
/* @__PURE__ */ a("div", { className: "shrink-0 px-6 pt-6", children: [
|
|
62057
62079
|
(Bt == null ? void 0 : Bt.truncated) && /* @__PURE__ */ a("div", { className: "mb-4 flex items-center gap-2 rounded-lg border border-amber-200 bg-amber-50 px-4 py-3 text-[12px] text-amber-800 dark:border-amber-900 dark:bg-amber-950/40 dark:text-amber-300", children: [
|
|
62058
|
-
/* @__PURE__ */ e(
|
|
62080
|
+
/* @__PURE__ */ e(Rr, { className: "h-4 w-4 shrink-0" }),
|
|
62059
62081
|
/* @__PURE__ */ e("span", { children: "This view hit the row safety limit — the table below may not include every matching item, but the totals above are exact. Narrow the filters (or clear the priority sort on a large queue) to browse everything." })
|
|
62060
62082
|
] }),
|
|
62061
62083
|
/* @__PURE__ */ e(
|
|
@@ -62271,7 +62293,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62271
62293
|
),
|
|
62272
62294
|
children: [
|
|
62273
62295
|
/* @__PURE__ */ e(Su, { className: "h-3.5 w-3.5" }),
|
|
62274
|
-
C ? `Group: ${((
|
|
62296
|
+
C ? `Group: ${((jr = yr.find((U) => U.value === C)) == null ? void 0 : jr.label) ?? C}` : "Group"
|
|
62275
62297
|
]
|
|
62276
62298
|
}
|
|
62277
62299
|
) }),
|
|
@@ -62455,7 +62477,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62455
62477
|
},
|
|
62456
62478
|
U.id
|
|
62457
62479
|
)),
|
|
62458
|
-
/* @__PURE__ */ a(oa, { open:
|
|
62480
|
+
/* @__PURE__ */ a(oa, { open: qr, onOpenChange: ga, children: [
|
|
62459
62481
|
/* @__PURE__ */ e(da, { asChild: !0, children: /* @__PURE__ */ e(
|
|
62460
62482
|
"button",
|
|
62461
62483
|
{
|
|
@@ -62861,7 +62883,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62861
62883
|
rowGroups: Ka ?? void 0,
|
|
62862
62884
|
collapsedGroups: N,
|
|
62863
62885
|
onToggleGroup: sn,
|
|
62864
|
-
selectedIds: Ne ?
|
|
62886
|
+
selectedIds: Ne ? Fr : void 0,
|
|
62865
62887
|
onSelectionChange: Ne ? Ua : void 0,
|
|
62866
62888
|
hideFilterRow: !0,
|
|
62867
62889
|
nowrapCells: !0,
|
|
@@ -62897,7 +62919,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62897
62919
|
Ne && /* @__PURE__ */ e(
|
|
62898
62920
|
y$,
|
|
62899
62921
|
{
|
|
62900
|
-
count:
|
|
62922
|
+
count: Fr.length,
|
|
62901
62923
|
claimsEnabled: te,
|
|
62902
62924
|
states: ((Bt == null ? void 0 : Bt.available_values.state) ?? []).map((U) => ({
|
|
62903
62925
|
value: U,
|
|
@@ -62963,7 +62985,7 @@ function dF({ queueId: t, realtime: n, renderError: r }) {
|
|
|
62963
62985
|
},
|
|
62964
62986
|
{ label: "Peek", run: () => En(Kn.row) },
|
|
62965
62987
|
...te ? [
|
|
62966
|
-
((
|
|
62988
|
+
((Ar = Kn.row.claimed_by) == null ? void 0 : Ar.id) === i ? { label: "Release claim", run: () => $n.mutate(Kn.row) } : { label: "Claim", run: () => vn.mutate(Kn.row) }
|
|
62967
62989
|
] : [],
|
|
62968
62990
|
{
|
|
62969
62991
|
label: "Copy ID",
|
|
@@ -64763,7 +64785,7 @@ function iq({
|
|
|
64763
64785
|
const D = x.find((O) => O.value === $.field);
|
|
64764
64786
|
return /* @__PURE__ */ a("div", { className: "flex items-center gap-1", children: [
|
|
64765
64787
|
/* @__PURE__ */ e(
|
|
64766
|
-
|
|
64788
|
+
$r,
|
|
64767
64789
|
{
|
|
64768
64790
|
value: $.field,
|
|
64769
64791
|
onChange: (O) => m((q) => q.map((P, W) => W === j ? { ...P, field: O } : P)),
|
|
@@ -64773,7 +64795,7 @@ function iq({
|
|
|
64773
64795
|
}
|
|
64774
64796
|
),
|
|
64775
64797
|
(D == null ? void 0 : D.aggregatable) && /* @__PURE__ */ e(
|
|
64776
|
-
|
|
64798
|
+
$r,
|
|
64777
64799
|
{
|
|
64778
64800
|
value: $.agg,
|
|
64779
64801
|
onChange: (O) => m(
|
|
@@ -64785,7 +64807,7 @@ function iq({
|
|
|
64785
64807
|
}
|
|
64786
64808
|
),
|
|
64787
64809
|
/* @__PURE__ */ e(
|
|
64788
|
-
|
|
64810
|
+
$r,
|
|
64789
64811
|
{
|
|
64790
64812
|
value: $.op,
|
|
64791
64813
|
onChange: (O) => m(
|
|
@@ -66324,7 +66346,7 @@ function cF({
|
|
|
66324
66346
|
] })
|
|
66325
66347
|
] }),
|
|
66326
66348
|
/* @__PURE__ */ e(
|
|
66327
|
-
|
|
66349
|
+
$r,
|
|
66328
66350
|
{
|
|
66329
66351
|
value: ($n == null ? void 0 : $n.preset) ?? "",
|
|
66330
66352
|
onChange: (Ve) => b(Ve ? { preset: Ve } : null),
|