braid-ui 1.0.41 → 1.0.42
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/css/braid-ui.css +17 -0
- package/dist/css/braid-ui.min.css +1 -1
- package/dist/index.cjs +1783 -236
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +14 -5
- package/dist/index.d.ts +14 -5
- package/dist/index.js +1782 -239
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -556,8 +556,8 @@ var reducer = (state, action) => {
|
|
|
556
556
|
if (toastId) {
|
|
557
557
|
addToRemoveQueue(toastId);
|
|
558
558
|
} else {
|
|
559
|
-
state.toasts.forEach((
|
|
560
|
-
addToRemoveQueue(
|
|
559
|
+
state.toasts.forEach((toast6) => {
|
|
560
|
+
addToRemoveQueue(toast6.id);
|
|
561
561
|
});
|
|
562
562
|
}
|
|
563
563
|
return {
|
|
@@ -4459,7 +4459,7 @@ function DatePicker({
|
|
|
4459
4459
|
) })
|
|
4460
4460
|
] });
|
|
4461
4461
|
if (label) {
|
|
4462
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("space-y-
|
|
4462
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: cn("space-y-4", wrapperClassName), children: [
|
|
4463
4463
|
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70", children: label }),
|
|
4464
4464
|
picker
|
|
4465
4465
|
] });
|
|
@@ -8403,7 +8403,8 @@ var DetailPageLayout = ({
|
|
|
8403
8403
|
description,
|
|
8404
8404
|
cards,
|
|
8405
8405
|
actions,
|
|
8406
|
-
initialEditingState = {}
|
|
8406
|
+
initialEditingState = {},
|
|
8407
|
+
headerContent
|
|
8407
8408
|
}) => {
|
|
8408
8409
|
const [editingCards, setEditingCards] = React15.useState(
|
|
8409
8410
|
initialEditingState
|
|
@@ -8422,6 +8423,7 @@ var DetailPageLayout = ({
|
|
|
8422
8423
|
{
|
|
8423
8424
|
title,
|
|
8424
8425
|
description,
|
|
8426
|
+
headerContent,
|
|
8425
8427
|
actions: actions?.map((action) => ({
|
|
8426
8428
|
label: action.label,
|
|
8427
8429
|
variant: action.variant || "default",
|
|
@@ -11620,6 +11622,53 @@ var CounterpartyDetail = () => {
|
|
|
11620
11622
|
);
|
|
11621
11623
|
};
|
|
11622
11624
|
var CounterpartyDetail_default = CounterpartyDetail;
|
|
11625
|
+
var CreateCounterpartyView = ({
|
|
11626
|
+
paymentMethods,
|
|
11627
|
+
onPaymentMethodsChange,
|
|
11628
|
+
onBasicInfoChange,
|
|
11629
|
+
onCancel,
|
|
11630
|
+
onSubmit
|
|
11631
|
+
}) => {
|
|
11632
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
11633
|
+
PageLayout,
|
|
11634
|
+
{
|
|
11635
|
+
title: "Create Counterparty",
|
|
11636
|
+
description: "Create a new counterparty with all required information",
|
|
11637
|
+
actions: [
|
|
11638
|
+
{ label: "Cancel", variant: "outline", onClick: onCancel },
|
|
11639
|
+
{ label: "Create Counterparty", variant: "default", onClick: onSubmit }
|
|
11640
|
+
],
|
|
11641
|
+
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-6", children: [
|
|
11642
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11643
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(CardTitle, { children: "Basic Information" }) }),
|
|
11644
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(CounterpartyBasicInfo, { onDataChange: onBasicInfoChange }) })
|
|
11645
|
+
] }),
|
|
11646
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11647
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(CardTitle, { children: [
|
|
11648
|
+
"Address",
|
|
11649
|
+
paymentMethods.some((m) => m.type === "wire") && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-destructive ml-1", children: "*" })
|
|
11650
|
+
] }) }),
|
|
11651
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CardContent, { children: [
|
|
11652
|
+
paymentMethods.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground mb-4", children: "Optional for ACH payments, required for wire transfers" }),
|
|
11653
|
+
paymentMethods.some((m) => m.type === "wire") && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground mb-4", children: "Required because you have wire payment methods" }),
|
|
11654
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
11655
|
+
AddressForm,
|
|
11656
|
+
{
|
|
11657
|
+
title: "",
|
|
11658
|
+
description: "",
|
|
11659
|
+
showApartment: true
|
|
11660
|
+
}
|
|
11661
|
+
)
|
|
11662
|
+
] })
|
|
11663
|
+
] }),
|
|
11664
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11665
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(CardTitle, { children: "Payment Configuration" }) }),
|
|
11666
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(PaymentInformationSection, { onPaymentMethodsChange }) })
|
|
11667
|
+
] })
|
|
11668
|
+
] })
|
|
11669
|
+
}
|
|
11670
|
+
);
|
|
11671
|
+
};
|
|
11623
11672
|
var CreateCounterparty = () => {
|
|
11624
11673
|
const navigate = reactRouterDom.useNavigate();
|
|
11625
11674
|
const [counterpartyData, setCounterpartyData] = React15.useState(null);
|
|
@@ -11630,11 +11679,11 @@ var CreateCounterparty = () => {
|
|
|
11630
11679
|
const handleBasicInfoChange = (data) => {
|
|
11631
11680
|
setCounterpartyData(data);
|
|
11632
11681
|
};
|
|
11633
|
-
const counterpartyType = counterpartyData?.type || "";
|
|
11634
11682
|
const handleCancel = () => {
|
|
11635
11683
|
navigate("/counterparty");
|
|
11636
11684
|
};
|
|
11637
11685
|
const handleSubmit = () => {
|
|
11686
|
+
const counterpartyType = counterpartyData?.type || "";
|
|
11638
11687
|
if (!counterpartyType) {
|
|
11639
11688
|
toast({
|
|
11640
11689
|
title: "Error",
|
|
@@ -11667,42 +11716,13 @@ var CreateCounterparty = () => {
|
|
|
11667
11716
|
}, 1e3);
|
|
11668
11717
|
};
|
|
11669
11718
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
11670
|
-
|
|
11719
|
+
CreateCounterpartyView,
|
|
11671
11720
|
{
|
|
11672
|
-
|
|
11673
|
-
|
|
11674
|
-
|
|
11675
|
-
|
|
11676
|
-
|
|
11677
|
-
],
|
|
11678
|
-
children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-6", children: [
|
|
11679
|
-
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11680
|
-
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(CardTitle, { children: "Basic Information" }) }),
|
|
11681
|
-
/* @__PURE__ */ jsxRuntime.jsx(CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(CounterpartyBasicInfo, { onDataChange: handleBasicInfoChange }) })
|
|
11682
|
-
] }),
|
|
11683
|
-
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11684
|
-
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(CardTitle, { children: [
|
|
11685
|
-
"Address",
|
|
11686
|
-
paymentMethods.some((m) => m.type === "wire") && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-destructive ml-1", children: "*" })
|
|
11687
|
-
] }) }),
|
|
11688
|
-
/* @__PURE__ */ jsxRuntime.jsxs(CardContent, { children: [
|
|
11689
|
-
paymentMethods.length === 0 && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground mb-4", children: "Optional for ACH payments, required for wire transfers" }),
|
|
11690
|
-
paymentMethods.some((m) => m.type === "wire") && /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-muted-foreground mb-4", children: "Required because you have wire payment methods" }),
|
|
11691
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
11692
|
-
AddressForm,
|
|
11693
|
-
{
|
|
11694
|
-
title: "",
|
|
11695
|
-
description: "",
|
|
11696
|
-
showApartment: true
|
|
11697
|
-
}
|
|
11698
|
-
)
|
|
11699
|
-
] })
|
|
11700
|
-
] }),
|
|
11701
|
-
/* @__PURE__ */ jsxRuntime.jsxs(Card, { children: [
|
|
11702
|
-
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(CardTitle, { children: "Payment Configuration" }) }),
|
|
11703
|
-
/* @__PURE__ */ jsxRuntime.jsx(CardContent, { children: /* @__PURE__ */ jsxRuntime.jsx(PaymentInformationSection, { onPaymentMethodsChange: handlePaymentMethodsChange }) })
|
|
11704
|
-
] })
|
|
11705
|
-
] })
|
|
11721
|
+
paymentMethods,
|
|
11722
|
+
onPaymentMethodsChange: handlePaymentMethodsChange,
|
|
11723
|
+
onBasicInfoChange: handleBasicInfoChange,
|
|
11724
|
+
onCancel: handleCancel,
|
|
11725
|
+
onSubmit: handleSubmit
|
|
11706
11726
|
}
|
|
11707
11727
|
);
|
|
11708
11728
|
};
|
|
@@ -14253,7 +14273,7 @@ var TransactionDetail = () => {
|
|
|
14253
14273
|
/* @__PURE__ */ jsxRuntime.jsx(Button, { onClick: () => navigate("/transactions/history"), children: "Back to Transaction History" })
|
|
14254
14274
|
] }) });
|
|
14255
14275
|
}
|
|
14256
|
-
const
|
|
14276
|
+
const getStatusVariant3 = (status) => {
|
|
14257
14277
|
switch (status) {
|
|
14258
14278
|
case "POSTED":
|
|
14259
14279
|
return "success";
|
|
@@ -14309,7 +14329,7 @@ var TransactionDetail = () => {
|
|
|
14309
14329
|
isInbound: transaction.isInbound
|
|
14310
14330
|
}
|
|
14311
14331
|
),
|
|
14312
|
-
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant:
|
|
14332
|
+
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getStatusVariant3(transaction.status), children: transaction.status }),
|
|
14313
14333
|
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getProcessingStatusVariant(transaction.processingStatus), children: transaction.processingStatus })
|
|
14314
14334
|
] }),
|
|
14315
14335
|
maxWidth: "full",
|
|
@@ -14408,22 +14428,22 @@ function UIKit() {
|
|
|
14408
14428
|
] })
|
|
14409
14429
|
] }) }) });
|
|
14410
14430
|
}
|
|
14411
|
-
function
|
|
14431
|
+
function VelocityLimitFiltersSheet({
|
|
14412
14432
|
filters,
|
|
14413
14433
|
onFilterChange,
|
|
14414
14434
|
onResetFilters
|
|
14415
14435
|
}) {
|
|
14416
|
-
const hasActiveFilters = filters.status !== "" || filters.
|
|
14436
|
+
const hasActiveFilters = filters.accountNumber !== "" || filters.counterpartyId !== "" || filters.productId !== "" || filters.programId !== "" || filters.limitName !== "" || filters.limitType !== "" || filters.status !== "" || filters.aggregationLevel !== "" || filters.action !== "" || filters.transactionType !== "" || filters.transactionGroup !== "";
|
|
14417
14437
|
return /* @__PURE__ */ jsxRuntime.jsxs(Sheet, { children: [
|
|
14418
14438
|
/* @__PURE__ */ jsxRuntime.jsx(SheetTrigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsxs(Button, { variant: "outline", children: [
|
|
14419
14439
|
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Filter, { className: "mr-2 h-4 w-4" }),
|
|
14420
14440
|
"Filters",
|
|
14421
|
-
hasActiveFilters && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-2 flex h-5 w-5 items-center justify-center rounded-full bg-primary text-xs text-primary-foreground", children:
|
|
14441
|
+
hasActiveFilters && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "ml-2 flex h-5 w-5 items-center justify-center rounded-full bg-primary text-xs text-primary-foreground", children: Object.values(filters).filter((v) => v !== "").length })
|
|
14422
14442
|
] }) }),
|
|
14423
14443
|
/* @__PURE__ */ jsxRuntime.jsxs(SheetContent, { className: "w-full sm:max-w-md overflow-y-auto", children: [
|
|
14424
14444
|
/* @__PURE__ */ jsxRuntime.jsxs(SheetHeader, { children: [
|
|
14425
14445
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
14426
|
-
/* @__PURE__ */ jsxRuntime.jsx(SheetTitle, { children: "Filter
|
|
14446
|
+
/* @__PURE__ */ jsxRuntime.jsx(SheetTitle, { children: "Filter Velocity Limits" }),
|
|
14427
14447
|
hasActiveFilters && /* @__PURE__ */ jsxRuntime.jsxs(
|
|
14428
14448
|
Button,
|
|
14429
14449
|
{
|
|
@@ -14438,20 +14458,78 @@ function OFACFiltersSheet({
|
|
|
14438
14458
|
}
|
|
14439
14459
|
)
|
|
14440
14460
|
] }),
|
|
14441
|
-
/* @__PURE__ */ jsxRuntime.jsx(SheetDescription, { children: "Filter
|
|
14461
|
+
/* @__PURE__ */ jsxRuntime.jsx(SheetDescription, { children: "Filter velocity limits by account, limit details, and transaction settings" })
|
|
14442
14462
|
] }),
|
|
14443
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "
|
|
14463
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4 mt-6", children: [
|
|
14464
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14465
|
+
EnhancedInput,
|
|
14466
|
+
{
|
|
14467
|
+
label: "Account Number",
|
|
14468
|
+
placeholder: "Enter account number",
|
|
14469
|
+
value: filters.accountNumber,
|
|
14470
|
+
onChange: (e) => onFilterChange("accountNumber", e.target.value)
|
|
14471
|
+
}
|
|
14472
|
+
),
|
|
14473
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14474
|
+
EnhancedInput,
|
|
14475
|
+
{
|
|
14476
|
+
label: "Counterparty ID",
|
|
14477
|
+
placeholder: "Enter counterparty ID",
|
|
14478
|
+
value: filters.counterpartyId,
|
|
14479
|
+
onChange: (e) => onFilterChange("counterpartyId", e.target.value)
|
|
14480
|
+
}
|
|
14481
|
+
),
|
|
14482
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14483
|
+
EnhancedInput,
|
|
14484
|
+
{
|
|
14485
|
+
label: "Product ID",
|
|
14486
|
+
placeholder: "Enter product ID",
|
|
14487
|
+
value: filters.productId,
|
|
14488
|
+
onChange: (e) => onFilterChange("productId", e.target.value)
|
|
14489
|
+
}
|
|
14490
|
+
),
|
|
14491
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14492
|
+
EnhancedInput,
|
|
14493
|
+
{
|
|
14494
|
+
label: "Program ID",
|
|
14495
|
+
placeholder: "Enter program ID",
|
|
14496
|
+
value: filters.programId,
|
|
14497
|
+
onChange: (e) => onFilterChange("programId", e.target.value)
|
|
14498
|
+
}
|
|
14499
|
+
),
|
|
14500
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14501
|
+
EnhancedInput,
|
|
14502
|
+
{
|
|
14503
|
+
label: "Limit Name",
|
|
14504
|
+
placeholder: "Enter limit name",
|
|
14505
|
+
value: filters.limitName,
|
|
14506
|
+
onChange: (e) => onFilterChange("limitName", e.target.value)
|
|
14507
|
+
}
|
|
14508
|
+
),
|
|
14509
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14510
|
+
EnhancedSelect,
|
|
14511
|
+
{
|
|
14512
|
+
label: "Limit Type",
|
|
14513
|
+
placeholder: "Select limit type",
|
|
14514
|
+
options: [
|
|
14515
|
+
{ value: "all", label: "All types" },
|
|
14516
|
+
{ value: "AMOUNT", label: "Amount" },
|
|
14517
|
+
{ value: "COUNT", label: "Count" }
|
|
14518
|
+
],
|
|
14519
|
+
value: filters.limitType || "all",
|
|
14520
|
+
onValueChange: (value) => onFilterChange("limitType", value === "all" ? "" : value)
|
|
14521
|
+
}
|
|
14522
|
+
),
|
|
14444
14523
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14445
14524
|
EnhancedSelect,
|
|
14446
14525
|
{
|
|
14447
14526
|
label: "Status",
|
|
14448
|
-
placeholder: "
|
|
14527
|
+
placeholder: "Select status",
|
|
14449
14528
|
options: [
|
|
14450
14529
|
{ value: "all", label: "All statuses" },
|
|
14451
|
-
{ value: "
|
|
14452
|
-
{ value: "
|
|
14453
|
-
{ value: "
|
|
14454
|
-
{ value: "CONFIRMED", label: "Confirmed" }
|
|
14530
|
+
{ value: "ACTIVE", label: "Active" },
|
|
14531
|
+
{ value: "INACTIVE", label: "Inactive" },
|
|
14532
|
+
{ value: "DELETED", label: "Deleted" }
|
|
14455
14533
|
],
|
|
14456
14534
|
value: filters.status || "all",
|
|
14457
14535
|
onValueChange: (value) => onFilterChange("status", value === "all" ? "" : value)
|
|
@@ -14460,180 +14538,246 @@ function OFACFiltersSheet({
|
|
|
14460
14538
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14461
14539
|
EnhancedSelect,
|
|
14462
14540
|
{
|
|
14463
|
-
label: "
|
|
14464
|
-
placeholder: "
|
|
14541
|
+
label: "Aggregation Level",
|
|
14542
|
+
placeholder: "Select aggregation level",
|
|
14465
14543
|
options: [
|
|
14466
|
-
{ value: "all", label: "All
|
|
14467
|
-
{ value: "
|
|
14468
|
-
{ value: "
|
|
14469
|
-
{ value: "
|
|
14544
|
+
{ value: "all", label: "All levels" },
|
|
14545
|
+
{ value: "ACCOUNT", label: "Account" },
|
|
14546
|
+
{ value: "PROGRAM", label: "Program" },
|
|
14547
|
+
{ value: "PRODUCT", label: "Product" }
|
|
14470
14548
|
],
|
|
14471
|
-
value: filters.
|
|
14472
|
-
onValueChange: (value) => onFilterChange("
|
|
14549
|
+
value: filters.aggregationLevel || "all",
|
|
14550
|
+
onValueChange: (value) => onFilterChange("aggregationLevel", value === "all" ? "" : value)
|
|
14473
14551
|
}
|
|
14474
14552
|
),
|
|
14475
14553
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14476
|
-
|
|
14554
|
+
EnhancedSelect,
|
|
14477
14555
|
{
|
|
14478
|
-
|
|
14479
|
-
|
|
14480
|
-
|
|
14481
|
-
|
|
14556
|
+
label: "Action",
|
|
14557
|
+
placeholder: "Select action",
|
|
14558
|
+
options: [
|
|
14559
|
+
{ value: "all", label: "All actions" },
|
|
14560
|
+
{ value: "DECLINE", label: "Decline" },
|
|
14561
|
+
{ value: "FLAG", label: "Flag" }
|
|
14562
|
+
],
|
|
14563
|
+
value: filters.action || "all",
|
|
14564
|
+
onValueChange: (value) => onFilterChange("action", value === "all" ? "" : value)
|
|
14482
14565
|
}
|
|
14483
14566
|
),
|
|
14484
14567
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14485
|
-
|
|
14568
|
+
EnhancedSelect,
|
|
14486
14569
|
{
|
|
14487
|
-
|
|
14488
|
-
|
|
14489
|
-
|
|
14490
|
-
|
|
14491
|
-
|
|
14570
|
+
label: "Transaction Type",
|
|
14571
|
+
placeholder: "Select transaction type",
|
|
14572
|
+
options: [
|
|
14573
|
+
{ value: "all", label: "All types" },
|
|
14574
|
+
{ value: "WIRE", label: "Wire" },
|
|
14575
|
+
{ value: "ACH", label: "ACH" },
|
|
14576
|
+
{ value: "CARD", label: "Card" }
|
|
14577
|
+
],
|
|
14578
|
+
value: filters.transactionType || "all",
|
|
14579
|
+
onValueChange: (value) => onFilterChange("transactionType", value === "all" ? "" : value)
|
|
14492
14580
|
}
|
|
14493
|
-
)
|
|
14581
|
+
),
|
|
14582
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-2", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
14583
|
+
EnhancedSelect,
|
|
14584
|
+
{
|
|
14585
|
+
label: "Transaction Group",
|
|
14586
|
+
placeholder: "Select transaction group",
|
|
14587
|
+
options: [
|
|
14588
|
+
{ value: "all", label: "All groups" },
|
|
14589
|
+
{ value: "INBOUND", label: "Inbound" },
|
|
14590
|
+
{ value: "OUTBOUND", label: "Outbound" }
|
|
14591
|
+
],
|
|
14592
|
+
value: filters.transactionGroup || "all",
|
|
14593
|
+
onValueChange: (value) => onFilterChange("transactionGroup", value === "all" ? "" : value)
|
|
14594
|
+
}
|
|
14595
|
+
) })
|
|
14494
14596
|
] })
|
|
14495
14597
|
] })
|
|
14496
14598
|
] });
|
|
14497
14599
|
}
|
|
14498
14600
|
|
|
14499
|
-
// src/lib/mock-data/
|
|
14500
|
-
var
|
|
14501
|
-
{
|
|
14502
|
-
id: "
|
|
14503
|
-
created: "
|
|
14504
|
-
|
|
14505
|
-
|
|
14506
|
-
|
|
14507
|
-
|
|
14508
|
-
|
|
14509
|
-
|
|
14510
|
-
|
|
14511
|
-
|
|
14512
|
-
|
|
14513
|
-
|
|
14514
|
-
|
|
14515
|
-
|
|
14516
|
-
|
|
14517
|
-
|
|
14518
|
-
|
|
14519
|
-
|
|
14520
|
-
|
|
14521
|
-
|
|
14522
|
-
|
|
14523
|
-
|
|
14524
|
-
|
|
14525
|
-
|
|
14526
|
-
|
|
14527
|
-
|
|
14528
|
-
|
|
14529
|
-
|
|
14530
|
-
|
|
14531
|
-
|
|
14532
|
-
|
|
14533
|
-
|
|
14534
|
-
|
|
14535
|
-
|
|
14536
|
-
|
|
14537
|
-
|
|
14538
|
-
|
|
14539
|
-
|
|
14540
|
-
|
|
14541
|
-
|
|
14542
|
-
|
|
14543
|
-
|
|
14544
|
-
|
|
14545
|
-
|
|
14546
|
-
|
|
14547
|
-
|
|
14548
|
-
|
|
14549
|
-
|
|
14550
|
-
|
|
14551
|
-
|
|
14552
|
-
|
|
14553
|
-
|
|
14554
|
-
|
|
14555
|
-
|
|
14556
|
-
|
|
14557
|
-
|
|
14558
|
-
|
|
14559
|
-
|
|
14560
|
-
|
|
14561
|
-
|
|
14562
|
-
|
|
14563
|
-
|
|
14564
|
-
|
|
14565
|
-
|
|
14566
|
-
|
|
14567
|
-
|
|
14568
|
-
|
|
14569
|
-
entityType: "
|
|
14570
|
-
|
|
14571
|
-
|
|
14572
|
-
|
|
14573
|
-
|
|
14574
|
-
|
|
14575
|
-
|
|
14576
|
-
|
|
14577
|
-
|
|
14578
|
-
|
|
14579
|
-
|
|
14580
|
-
|
|
14581
|
-
|
|
14582
|
-
|
|
14583
|
-
|
|
14584
|
-
|
|
14585
|
-
|
|
14586
|
-
|
|
14587
|
-
|
|
14588
|
-
|
|
14589
|
-
|
|
14601
|
+
// src/lib/mock-data/velocity-limit-data.ts
|
|
14602
|
+
var mockVelocityLimits = [
|
|
14603
|
+
{
|
|
14604
|
+
id: "1",
|
|
14605
|
+
created: "2025-11-13T10:00:00Z",
|
|
14606
|
+
limitName: "QA - Decline inbound wire",
|
|
14607
|
+
limitType: "transaction",
|
|
14608
|
+
action: "DECLINE",
|
|
14609
|
+
status: "ACTIVE",
|
|
14610
|
+
associatedEntity: "Account",
|
|
14611
|
+
associatedEntityId: "9539334834",
|
|
14612
|
+
transactionGroup: ["inbound"],
|
|
14613
|
+
transactionType: ["wire"],
|
|
14614
|
+
aggregationLevel: "account",
|
|
14615
|
+
timePeriod: "daily",
|
|
14616
|
+
maxAmount: "50000",
|
|
14617
|
+
maxCount: "10"
|
|
14618
|
+
},
|
|
14619
|
+
{
|
|
14620
|
+
id: "2",
|
|
14621
|
+
created: "2025-11-13T10:00:00Z",
|
|
14622
|
+
limitName: "QA - Decline inbound wire",
|
|
14623
|
+
limitType: "transaction",
|
|
14624
|
+
action: "DECLINE",
|
|
14625
|
+
status: "ACTIVE",
|
|
14626
|
+
associatedEntity: "Account",
|
|
14627
|
+
associatedEntityId: "8895578481",
|
|
14628
|
+
transactionType: ["wire"],
|
|
14629
|
+
aggregationLevel: "account",
|
|
14630
|
+
timePeriod: "daily",
|
|
14631
|
+
maxAmount: "100000",
|
|
14632
|
+
maxCount: "20"
|
|
14633
|
+
},
|
|
14634
|
+
{
|
|
14635
|
+
id: "3",
|
|
14636
|
+
created: "2025-11-13T10:00:00Z",
|
|
14637
|
+
limitName: "QA - Decline inbound wire",
|
|
14638
|
+
limitType: "transaction",
|
|
14639
|
+
action: "DECLINE",
|
|
14640
|
+
status: "ACTIVE",
|
|
14641
|
+
associatedEntity: "Account",
|
|
14642
|
+
associatedEntityId: "86046257",
|
|
14643
|
+
transactionType: ["wire"],
|
|
14644
|
+
aggregationLevel: "transaction",
|
|
14645
|
+
maxAmount: "25000"
|
|
14646
|
+
},
|
|
14647
|
+
{
|
|
14648
|
+
id: "4",
|
|
14649
|
+
created: "2025-11-13T10:00:00Z",
|
|
14650
|
+
limitName: "QA - Decline inbound wire",
|
|
14651
|
+
limitType: "transaction",
|
|
14652
|
+
action: "DECLINE",
|
|
14653
|
+
status: "ACTIVE",
|
|
14654
|
+
associatedEntity: "Account",
|
|
14655
|
+
associatedEntityId: "86046257",
|
|
14656
|
+
transactionType: ["ACH_RECEIVER_CREDIT", "ACH_ORIGINATOR_CREDIT", "WIRE_INBOUND", "WIRE_OUTBOUND", "CARD_TRANSACTION"],
|
|
14657
|
+
aggregationLevel: "account",
|
|
14658
|
+
timePeriod: "monthly",
|
|
14659
|
+
maxAmount: "500000",
|
|
14660
|
+
maxCount: "50"
|
|
14661
|
+
},
|
|
14662
|
+
{
|
|
14663
|
+
id: "5",
|
|
14664
|
+
created: "2025-10-23T10:00:00Z",
|
|
14665
|
+
limitName: "prohibited country list v2",
|
|
14666
|
+
limitType: "prohibited_entity",
|
|
14667
|
+
action: "DECLINE",
|
|
14668
|
+
status: "DELETED",
|
|
14669
|
+
associatedEntity: "Global",
|
|
14670
|
+
entityListName: "OFAC Sanctioned Countries",
|
|
14671
|
+
entityType: "country",
|
|
14672
|
+
prohibitedEntities: "Iran, North Korea, Syria, Cuba"
|
|
14673
|
+
},
|
|
14674
|
+
{
|
|
14675
|
+
id: "6",
|
|
14676
|
+
created: "2025-10-16T10:00:00Z",
|
|
14677
|
+
limitName: "global wire debit limit",
|
|
14678
|
+
limitType: "transaction",
|
|
14679
|
+
action: "DECLINE",
|
|
14680
|
+
status: "INACTIVE",
|
|
14681
|
+
associatedEntity: "Global",
|
|
14682
|
+
transactionType: ["wire"],
|
|
14683
|
+
aggregationLevel: "program",
|
|
14684
|
+
timePeriod: "daily",
|
|
14685
|
+
maxAmount: "1000000",
|
|
14686
|
+
maxCount: "100"
|
|
14687
|
+
},
|
|
14688
|
+
{
|
|
14689
|
+
id: "7",
|
|
14690
|
+
created: "2025-10-16T10:00:00Z",
|
|
14691
|
+
limitName: "global wire debit limit",
|
|
14692
|
+
limitType: "transaction",
|
|
14693
|
+
action: "DECLINE",
|
|
14694
|
+
status: "ACTIVE",
|
|
14695
|
+
associatedEntity: "Global",
|
|
14696
|
+
transactionType: ["wire"],
|
|
14697
|
+
aggregationLevel: "program",
|
|
14698
|
+
timePeriod: "daily",
|
|
14699
|
+
maxAmount: "1000000",
|
|
14700
|
+
maxCount: "100"
|
|
14701
|
+
},
|
|
14702
|
+
{
|
|
14703
|
+
id: "8",
|
|
14704
|
+
created: "2025-09-04T10:00:00Z",
|
|
14705
|
+
limitName: "wire_ach_rounded_amt",
|
|
14706
|
+
limitType: "round_number",
|
|
14707
|
+
action: "FLAG",
|
|
14708
|
+
status: "ACTIVE",
|
|
14709
|
+
associatedEntity: "Program",
|
|
14710
|
+
associatedEntityId: "167989",
|
|
14711
|
+
amountThreshold: "10000",
|
|
14712
|
+
roundPattern: "1000, 5000, 10000, 50000"
|
|
14713
|
+
},
|
|
14714
|
+
{
|
|
14715
|
+
id: "9",
|
|
14716
|
+
created: "2025-08-20T10:00:00Z",
|
|
14717
|
+
limitName: "receiver name validation",
|
|
14718
|
+
limitType: "receiver_name_mismatch",
|
|
14719
|
+
action: "FLAG",
|
|
14720
|
+
status: "ACTIVE",
|
|
14721
|
+
associatedEntity: "Global",
|
|
14722
|
+
mismatchThreshold: "80",
|
|
14723
|
+
comparisonMethod: "fuzzy"
|
|
14590
14724
|
}
|
|
14591
14725
|
];
|
|
14592
14726
|
var getStatusVariant = (status) => {
|
|
14593
14727
|
switch (status) {
|
|
14594
|
-
case "
|
|
14728
|
+
case "ACTIVE":
|
|
14595
14729
|
return "success";
|
|
14596
|
-
case "
|
|
14730
|
+
case "INACTIVE":
|
|
14597
14731
|
return "warning";
|
|
14598
|
-
case "
|
|
14599
|
-
return "active";
|
|
14600
|
-
case "CONFIRMED":
|
|
14732
|
+
case "DELETED":
|
|
14601
14733
|
return "destructive";
|
|
14602
14734
|
default:
|
|
14603
14735
|
return "secondary";
|
|
14604
14736
|
}
|
|
14605
14737
|
};
|
|
14606
|
-
var
|
|
14607
|
-
switch (
|
|
14608
|
-
case "
|
|
14609
|
-
return
|
|
14610
|
-
case "
|
|
14611
|
-
return
|
|
14612
|
-
case "Counterparty":
|
|
14613
|
-
return `/counterparty/${entityId}`;
|
|
14738
|
+
var getActionVariant = (action) => {
|
|
14739
|
+
switch (action) {
|
|
14740
|
+
case "DECLINE":
|
|
14741
|
+
return "destructive";
|
|
14742
|
+
case "FLAG":
|
|
14743
|
+
return "warning";
|
|
14614
14744
|
default:
|
|
14615
|
-
return "
|
|
14745
|
+
return "secondary";
|
|
14616
14746
|
}
|
|
14617
14747
|
};
|
|
14618
|
-
function
|
|
14748
|
+
function VelocityLimits() {
|
|
14619
14749
|
const navigate = reactRouterDom.useNavigate();
|
|
14620
14750
|
const [sortField, setSortField] = React15.useState("created");
|
|
14621
14751
|
const [sortDirection, setSortDirection] = React15.useState("desc");
|
|
14622
14752
|
const [filters, setFilters] = React15.useState({
|
|
14753
|
+
accountNumber: "",
|
|
14754
|
+
counterpartyId: "",
|
|
14755
|
+
productId: "",
|
|
14756
|
+
programId: "",
|
|
14757
|
+
limitName: "",
|
|
14758
|
+
limitType: "",
|
|
14623
14759
|
status: "",
|
|
14624
|
-
|
|
14625
|
-
|
|
14626
|
-
|
|
14760
|
+
aggregationLevel: "",
|
|
14761
|
+
action: "",
|
|
14762
|
+
transactionType: "",
|
|
14763
|
+
transactionGroup: ""
|
|
14627
14764
|
});
|
|
14628
14765
|
const handleFilterChange = (field, value) => {
|
|
14629
14766
|
setFilters((prev) => ({ ...prev, [field]: value }));
|
|
14630
14767
|
};
|
|
14631
14768
|
const handleResetFilters = () => {
|
|
14632
14769
|
setFilters({
|
|
14770
|
+
accountNumber: "",
|
|
14771
|
+
counterpartyId: "",
|
|
14772
|
+
productId: "",
|
|
14773
|
+
programId: "",
|
|
14774
|
+
limitName: "",
|
|
14775
|
+
limitType: "",
|
|
14633
14776
|
status: "",
|
|
14634
|
-
|
|
14635
|
-
|
|
14636
|
-
|
|
14777
|
+
aggregationLevel: "",
|
|
14778
|
+
action: "",
|
|
14779
|
+
transactionType: "",
|
|
14780
|
+
transactionGroup: ""
|
|
14637
14781
|
});
|
|
14638
14782
|
};
|
|
14639
14783
|
const handleSort = (field) => {
|
|
@@ -14644,27 +14788,24 @@ function OFAC() {
|
|
|
14644
14788
|
setSortDirection("desc");
|
|
14645
14789
|
}
|
|
14646
14790
|
};
|
|
14647
|
-
const
|
|
14648
|
-
return
|
|
14649
|
-
if (filters.
|
|
14791
|
+
const filteredLimits = React15.useMemo(() => {
|
|
14792
|
+
return mockVelocityLimits.filter((limit) => {
|
|
14793
|
+
if (filters.accountNumber && limit.associatedEntityId && !limit.associatedEntityId.includes(filters.accountNumber)) {
|
|
14650
14794
|
return false;
|
|
14651
14795
|
}
|
|
14652
|
-
if (filters.
|
|
14796
|
+
if (filters.limitName && !limit.limitName.toLowerCase().includes(filters.limitName.toLowerCase())) {
|
|
14653
14797
|
return false;
|
|
14654
14798
|
}
|
|
14655
|
-
if (filters.
|
|
14656
|
-
|
|
14657
|
-
|
|
14658
|
-
|
|
14659
|
-
|
|
14660
|
-
if (filters.endDate && dateFns.isAfter(checkDate, dateFns.endOfDay(filters.endDate))) {
|
|
14661
|
-
return false;
|
|
14662
|
-
}
|
|
14799
|
+
if (filters.action && limit.action !== filters.action) {
|
|
14800
|
+
return false;
|
|
14801
|
+
}
|
|
14802
|
+
if (filters.status && limit.status !== filters.status) {
|
|
14803
|
+
return false;
|
|
14663
14804
|
}
|
|
14664
14805
|
return true;
|
|
14665
14806
|
});
|
|
14666
14807
|
}, [filters]);
|
|
14667
|
-
const
|
|
14808
|
+
const sortedLimits = [...filteredLimits].sort((a, b) => {
|
|
14668
14809
|
const aValue = a[sortField];
|
|
14669
14810
|
const bValue = b[sortField];
|
|
14670
14811
|
if (aValue == null) return 1;
|
|
@@ -14680,69 +14821,1471 @@ function OFAC() {
|
|
|
14680
14821
|
key: "created",
|
|
14681
14822
|
title: "Created",
|
|
14682
14823
|
sortable: true,
|
|
14683
|
-
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm
|
|
14684
|
-
},
|
|
14685
|
-
{
|
|
14686
|
-
key: "entityName",
|
|
14687
|
-
title: "Entity",
|
|
14688
|
-
render: (value, row) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
14689
|
-
"button",
|
|
14690
|
-
{
|
|
14691
|
-
onClick: () => navigate(getEntityUrl(row.entityType, row.entityId)),
|
|
14692
|
-
className: "text-sm text-primary hover:underline font-medium",
|
|
14693
|
-
children: value
|
|
14694
|
-
}
|
|
14695
|
-
)
|
|
14824
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: dateFns.format(dateFns.parseISO(value), "yyyy-MM-dd") })
|
|
14696
14825
|
},
|
|
14697
14826
|
{
|
|
14698
|
-
key: "
|
|
14699
|
-
title: "
|
|
14827
|
+
key: "limitName",
|
|
14828
|
+
title: "Limit Name",
|
|
14700
14829
|
sortable: true,
|
|
14701
|
-
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value })
|
|
14830
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium", children: value })
|
|
14702
14831
|
},
|
|
14703
14832
|
{
|
|
14704
|
-
key: "
|
|
14705
|
-
title: "
|
|
14706
|
-
|
|
14707
|
-
|
|
14708
|
-
{
|
|
14709
|
-
onClick: () => navigate(`/alerts/${value}`),
|
|
14710
|
-
className: "text-sm text-primary hover:underline font-medium",
|
|
14711
|
-
children: value
|
|
14712
|
-
}
|
|
14713
|
-
) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: "\u2014" })
|
|
14833
|
+
key: "action",
|
|
14834
|
+
title: "Action",
|
|
14835
|
+
sortable: true,
|
|
14836
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getActionVariant(value), children: value })
|
|
14714
14837
|
},
|
|
14715
14838
|
{
|
|
14716
14839
|
key: "status",
|
|
14717
14840
|
title: "Status",
|
|
14718
14841
|
sortable: true,
|
|
14719
14842
|
render: (value) => /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getStatusVariant(value), children: value })
|
|
14843
|
+
},
|
|
14844
|
+
{
|
|
14845
|
+
key: "associatedEntity",
|
|
14846
|
+
title: "Associated Entity",
|
|
14847
|
+
sortable: true,
|
|
14848
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value })
|
|
14849
|
+
},
|
|
14850
|
+
{
|
|
14851
|
+
key: "associatedEntityId",
|
|
14852
|
+
title: "Associated Entity ID",
|
|
14853
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value || "\u2014" })
|
|
14720
14854
|
}
|
|
14721
14855
|
];
|
|
14722
14856
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col h-screen bg-gradient-subtle", children: [
|
|
14723
14857
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-none border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 py-6 max-w-none", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
14724
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold text-foreground", children: "
|
|
14725
|
-
/* @__PURE__ */ jsxRuntime.
|
|
14726
|
-
|
|
14727
|
-
|
|
14728
|
-
|
|
14729
|
-
|
|
14730
|
-
|
|
14731
|
-
|
|
14732
|
-
|
|
14858
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold text-foreground", children: "Velocity Limits" }) }),
|
|
14859
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
14860
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14861
|
+
VelocityLimitFiltersSheet,
|
|
14862
|
+
{
|
|
14863
|
+
filters,
|
|
14864
|
+
onFilterChange: handleFilterChange,
|
|
14865
|
+
onResetFilters: handleResetFilters
|
|
14866
|
+
}
|
|
14867
|
+
),
|
|
14868
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Button, { onClick: () => navigate("/compliance/velocity/create"), children: [
|
|
14869
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Plus, { className: "mr-2 h-4 w-4" }),
|
|
14870
|
+
"Create Limit"
|
|
14871
|
+
] })
|
|
14872
|
+
] })
|
|
14733
14873
|
] }) }) }),
|
|
14734
14874
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 h-full max-w-none flex flex-col", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 mt-4 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
14735
14875
|
DataTable,
|
|
14736
14876
|
{
|
|
14737
14877
|
columns: columns3,
|
|
14738
|
-
data:
|
|
14878
|
+
data: sortedLimits,
|
|
14739
14879
|
sortBy: sortField,
|
|
14740
14880
|
sortDirection,
|
|
14741
|
-
onSort: handleSort
|
|
14881
|
+
onSort: handleSort,
|
|
14882
|
+
onRowClick: (limit) => navigate(`/compliance/velocity/${limit.id}`),
|
|
14883
|
+
pagination: {
|
|
14884
|
+
pageSize: 10,
|
|
14885
|
+
currentPage: 1,
|
|
14886
|
+
totalItems: sortedLimits.length,
|
|
14887
|
+
onPageChange: () => {
|
|
14888
|
+
}
|
|
14889
|
+
}
|
|
14742
14890
|
}
|
|
14743
14891
|
) }) }) })
|
|
14744
14892
|
] });
|
|
14745
14893
|
}
|
|
14894
|
+
function CreateVelocityLimit() {
|
|
14895
|
+
const navigate = reactRouterDom.useNavigate();
|
|
14896
|
+
const [limitType, setLimitType] = React15.useState("");
|
|
14897
|
+
const [formData, setFormData] = React15.useState({
|
|
14898
|
+
limitName: "",
|
|
14899
|
+
action: "",
|
|
14900
|
+
associatedEntityType: "",
|
|
14901
|
+
associatedEntityId: "",
|
|
14902
|
+
transactionFilterType: "",
|
|
14903
|
+
// "type" or "group"
|
|
14904
|
+
transactionType: "",
|
|
14905
|
+
transactionGroup: "",
|
|
14906
|
+
aggregationLevel: ""
|
|
14907
|
+
// Type-specific fields will be added based on limitType
|
|
14908
|
+
});
|
|
14909
|
+
const handleFieldChange = (field, value) => {
|
|
14910
|
+
setFormData((prev) => ({ ...prev, [field]: value }));
|
|
14911
|
+
};
|
|
14912
|
+
const handleSubmit = (e) => {
|
|
14913
|
+
e.preventDefault();
|
|
14914
|
+
console.log("Creating velocity limit:", { limitType, ...formData });
|
|
14915
|
+
navigate("/compliance/velocity");
|
|
14916
|
+
};
|
|
14917
|
+
const renderTypeSpecificFields = () => {
|
|
14918
|
+
switch (limitType) {
|
|
14919
|
+
case "receiver_name_mismatch":
|
|
14920
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
14921
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14922
|
+
EnhancedInput,
|
|
14923
|
+
{
|
|
14924
|
+
label: "Mismatch Threshold (%)",
|
|
14925
|
+
placeholder: "Enter threshold percentage",
|
|
14926
|
+
onChange: (e) => handleFieldChange("mismatchThreshold", e.target.value)
|
|
14927
|
+
}
|
|
14928
|
+
),
|
|
14929
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14930
|
+
EnhancedSelect,
|
|
14931
|
+
{
|
|
14932
|
+
label: "Comparison Method",
|
|
14933
|
+
placeholder: "Select method",
|
|
14934
|
+
options: [
|
|
14935
|
+
{ value: "exact", label: "Exact Match" },
|
|
14936
|
+
{ value: "fuzzy", label: "Fuzzy Match" },
|
|
14937
|
+
{ value: "partial", label: "Partial Match" }
|
|
14938
|
+
],
|
|
14939
|
+
onValueChange: (value) => handleFieldChange("comparisonMethod", value)
|
|
14940
|
+
}
|
|
14941
|
+
)
|
|
14942
|
+
] }) });
|
|
14943
|
+
case "round_number":
|
|
14944
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
14945
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14946
|
+
EnhancedInput,
|
|
14947
|
+
{
|
|
14948
|
+
label: "Amount Threshold",
|
|
14949
|
+
placeholder: "Enter amount",
|
|
14950
|
+
onChange: (e) => handleFieldChange("amountThreshold", e.target.value)
|
|
14951
|
+
}
|
|
14952
|
+
),
|
|
14953
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14954
|
+
EnhancedInput,
|
|
14955
|
+
{
|
|
14956
|
+
label: "Round Number Pattern",
|
|
14957
|
+
placeholder: "e.g., 1000, 5000, 10000",
|
|
14958
|
+
onChange: (e) => handleFieldChange("roundPattern", e.target.value)
|
|
14959
|
+
}
|
|
14960
|
+
)
|
|
14961
|
+
] }) });
|
|
14962
|
+
case "transaction":
|
|
14963
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
14964
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mb-6", children: [
|
|
14965
|
+
/* @__PURE__ */ jsxRuntime.jsx("label", { className: "text-sm font-medium text-foreground mb-3 block", children: "Filter By" }),
|
|
14966
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-6", children: [
|
|
14967
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-6", children: [
|
|
14968
|
+
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 cursor-pointer", children: [
|
|
14969
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14970
|
+
"input",
|
|
14971
|
+
{
|
|
14972
|
+
type: "radio",
|
|
14973
|
+
name: "transactionFilterType",
|
|
14974
|
+
value: "type",
|
|
14975
|
+
checked: formData.transactionFilterType === "type",
|
|
14976
|
+
onChange: (e) => {
|
|
14977
|
+
handleFieldChange("transactionFilterType", e.target.value);
|
|
14978
|
+
handleFieldChange("transactionGroup", "");
|
|
14979
|
+
},
|
|
14980
|
+
className: "w-4 h-4 text-primary border-border focus:ring-2 focus:ring-primary"
|
|
14981
|
+
}
|
|
14982
|
+
),
|
|
14983
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-foreground", children: "Transaction Type" })
|
|
14984
|
+
] }),
|
|
14985
|
+
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 cursor-pointer", children: [
|
|
14986
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
14987
|
+
"input",
|
|
14988
|
+
{
|
|
14989
|
+
type: "radio",
|
|
14990
|
+
name: "transactionFilterType",
|
|
14991
|
+
value: "group",
|
|
14992
|
+
checked: formData.transactionFilterType === "group",
|
|
14993
|
+
onChange: (e) => {
|
|
14994
|
+
handleFieldChange("transactionFilterType", e.target.value);
|
|
14995
|
+
handleFieldChange("transactionType", "");
|
|
14996
|
+
},
|
|
14997
|
+
className: "w-4 h-4 text-primary border-border focus:ring-2 focus:ring-primary"
|
|
14998
|
+
}
|
|
14999
|
+
),
|
|
15000
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-foreground", children: "Transaction Group" })
|
|
15001
|
+
] })
|
|
15002
|
+
] }),
|
|
15003
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1", children: [
|
|
15004
|
+
formData.transactionFilterType === "type" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15005
|
+
EnhancedSelect,
|
|
15006
|
+
{
|
|
15007
|
+
label: "",
|
|
15008
|
+
placeholder: "Select type",
|
|
15009
|
+
options: [
|
|
15010
|
+
{ value: "wire", label: "Wire" },
|
|
15011
|
+
{ value: "ach", label: "ACH" },
|
|
15012
|
+
{ value: "card", label: "Card" }
|
|
15013
|
+
],
|
|
15014
|
+
value: formData.transactionType,
|
|
15015
|
+
onValueChange: (value) => handleFieldChange("transactionType", value)
|
|
15016
|
+
}
|
|
15017
|
+
),
|
|
15018
|
+
formData.transactionFilterType === "group" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15019
|
+
EnhancedSelect,
|
|
15020
|
+
{
|
|
15021
|
+
label: "",
|
|
15022
|
+
placeholder: "Select group",
|
|
15023
|
+
options: [
|
|
15024
|
+
{ value: "inbound", label: "Inbound" },
|
|
15025
|
+
{ value: "outbound", label: "Outbound" }
|
|
15026
|
+
],
|
|
15027
|
+
value: formData.transactionGroup,
|
|
15028
|
+
onValueChange: (value) => handleFieldChange("transactionGroup", value)
|
|
15029
|
+
}
|
|
15030
|
+
)
|
|
15031
|
+
] })
|
|
15032
|
+
] })
|
|
15033
|
+
] }),
|
|
15034
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15035
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15036
|
+
EnhancedSelect,
|
|
15037
|
+
{
|
|
15038
|
+
label: "Aggregation Level",
|
|
15039
|
+
placeholder: "Select level",
|
|
15040
|
+
options: [
|
|
15041
|
+
{ value: "transaction", label: "Transaction" },
|
|
15042
|
+
{ value: "account", label: "Account" },
|
|
15043
|
+
{ value: "program", label: "Program" },
|
|
15044
|
+
{ value: "product", label: "Product" }
|
|
15045
|
+
],
|
|
15046
|
+
onValueChange: (value) => handleFieldChange("aggregationLevel", value)
|
|
15047
|
+
}
|
|
15048
|
+
),
|
|
15049
|
+
formData.aggregationLevel !== "transaction" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15050
|
+
EnhancedSelect,
|
|
15051
|
+
{
|
|
15052
|
+
label: "Time Period",
|
|
15053
|
+
placeholder: "Select period",
|
|
15054
|
+
options: [
|
|
15055
|
+
{ value: "daily", label: "Daily" },
|
|
15056
|
+
{ value: "weekly", label: "Weekly" },
|
|
15057
|
+
{ value: "monthly", label: "Monthly" }
|
|
15058
|
+
],
|
|
15059
|
+
onValueChange: (value) => handleFieldChange("timePeriod", value)
|
|
15060
|
+
}
|
|
15061
|
+
),
|
|
15062
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15063
|
+
EnhancedInput,
|
|
15064
|
+
{
|
|
15065
|
+
label: "Max Transaction Amount",
|
|
15066
|
+
placeholder: "Enter amount",
|
|
15067
|
+
onChange: (e) => handleFieldChange("maxAmount", e.target.value)
|
|
15068
|
+
}
|
|
15069
|
+
),
|
|
15070
|
+
formData.aggregationLevel !== "transaction" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15071
|
+
EnhancedInput,
|
|
15072
|
+
{
|
|
15073
|
+
label: "Max Transaction Count",
|
|
15074
|
+
placeholder: "Enter count",
|
|
15075
|
+
onChange: (e) => handleFieldChange("maxCount", e.target.value)
|
|
15076
|
+
}
|
|
15077
|
+
)
|
|
15078
|
+
] })
|
|
15079
|
+
] });
|
|
15080
|
+
case "prohibited_entity":
|
|
15081
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15082
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15083
|
+
EnhancedInput,
|
|
15084
|
+
{
|
|
15085
|
+
label: "Entity List Name",
|
|
15086
|
+
placeholder: "Enter list name",
|
|
15087
|
+
onChange: (e) => handleFieldChange("entityListName", e.target.value)
|
|
15088
|
+
}
|
|
15089
|
+
),
|
|
15090
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15091
|
+
EnhancedSelect,
|
|
15092
|
+
{
|
|
15093
|
+
label: "Entity Type",
|
|
15094
|
+
placeholder: "Select type",
|
|
15095
|
+
options: [
|
|
15096
|
+
{ value: "country", label: "Country" },
|
|
15097
|
+
{ value: "individual", label: "Individual" },
|
|
15098
|
+
{ value: "business", label: "Business" }
|
|
15099
|
+
],
|
|
15100
|
+
onValueChange: (value) => handleFieldChange("entityType", value)
|
|
15101
|
+
}
|
|
15102
|
+
),
|
|
15103
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "col-span-2", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
15104
|
+
EnhancedInput,
|
|
15105
|
+
{
|
|
15106
|
+
label: "Prohibited Entities (comma-separated)",
|
|
15107
|
+
placeholder: "Enter entities",
|
|
15108
|
+
onChange: (e) => handleFieldChange("prohibitedEntities", e.target.value)
|
|
15109
|
+
}
|
|
15110
|
+
) })
|
|
15111
|
+
] }) });
|
|
15112
|
+
default:
|
|
15113
|
+
return null;
|
|
15114
|
+
}
|
|
15115
|
+
};
|
|
15116
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col h-screen bg-gradient-subtle", children: [
|
|
15117
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-none border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 py-6 max-w-none", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-4", children: [
|
|
15118
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
15119
|
+
Button,
|
|
15120
|
+
{
|
|
15121
|
+
variant: "ghost",
|
|
15122
|
+
size: "sm",
|
|
15123
|
+
onClick: () => navigate("/compliance/velocity"),
|
|
15124
|
+
children: [
|
|
15125
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowLeft, { className: "mr-2 h-4 w-4" }),
|
|
15126
|
+
"Back"
|
|
15127
|
+
]
|
|
15128
|
+
}
|
|
15129
|
+
),
|
|
15130
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold text-foreground", children: "Create Velocity Limit" }) })
|
|
15131
|
+
] }) }) }),
|
|
15132
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 py-6 max-w-4xl", children: /* @__PURE__ */ jsxRuntime.jsx("form", { onSubmit: handleSubmit, children: /* @__PURE__ */ jsxRuntime.jsx(Card, { className: "p-6", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-6", children: [
|
|
15133
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
15134
|
+
/* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-lg font-semibold mb-4", children: "Select Limit Type" }),
|
|
15135
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15136
|
+
EnhancedSelect,
|
|
15137
|
+
{
|
|
15138
|
+
label: "Limit Type",
|
|
15139
|
+
placeholder: "Select a limit type",
|
|
15140
|
+
options: [
|
|
15141
|
+
{ value: "receiver_name_mismatch", label: "Receiver Name Mismatch" },
|
|
15142
|
+
{ value: "round_number", label: "Round Number" },
|
|
15143
|
+
{ value: "transaction", label: "Transaction" },
|
|
15144
|
+
{ value: "prohibited_entity", label: "Prohibited Entity" }
|
|
15145
|
+
],
|
|
15146
|
+
value: limitType,
|
|
15147
|
+
onValueChange: (value) => setLimitType(value)
|
|
15148
|
+
}
|
|
15149
|
+
)
|
|
15150
|
+
] }),
|
|
15151
|
+
limitType && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
15152
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-t pt-6", children: [
|
|
15153
|
+
/* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-lg font-semibold mb-4", children: "Basic Information" }),
|
|
15154
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15155
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15156
|
+
EnhancedInput,
|
|
15157
|
+
{
|
|
15158
|
+
label: "Limit Name",
|
|
15159
|
+
placeholder: "Enter limit name",
|
|
15160
|
+
value: formData.limitName,
|
|
15161
|
+
onChange: (e) => handleFieldChange("limitName", e.target.value)
|
|
15162
|
+
}
|
|
15163
|
+
),
|
|
15164
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15165
|
+
EnhancedSelect,
|
|
15166
|
+
{
|
|
15167
|
+
label: "Action",
|
|
15168
|
+
placeholder: "Select action",
|
|
15169
|
+
options: [
|
|
15170
|
+
{ value: "decline", label: "Decline" },
|
|
15171
|
+
{ value: "flag", label: "Flag" }
|
|
15172
|
+
],
|
|
15173
|
+
onValueChange: (value) => handleFieldChange("action", value)
|
|
15174
|
+
}
|
|
15175
|
+
),
|
|
15176
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15177
|
+
EnhancedSelect,
|
|
15178
|
+
{
|
|
15179
|
+
label: "Associated Entity Type",
|
|
15180
|
+
placeholder: "Select entity type",
|
|
15181
|
+
options: [
|
|
15182
|
+
{ value: "global", label: "Global" },
|
|
15183
|
+
{ value: "program", label: "Program" },
|
|
15184
|
+
{ value: "product", label: "Product" },
|
|
15185
|
+
{ value: "account", label: "Account" }
|
|
15186
|
+
],
|
|
15187
|
+
value: formData.associatedEntityType,
|
|
15188
|
+
onValueChange: (value) => {
|
|
15189
|
+
handleFieldChange("associatedEntityType", value);
|
|
15190
|
+
handleFieldChange("associatedEntityId", "");
|
|
15191
|
+
}
|
|
15192
|
+
}
|
|
15193
|
+
),
|
|
15194
|
+
formData.associatedEntityType && formData.associatedEntityType !== "global" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15195
|
+
EnhancedInput,
|
|
15196
|
+
{
|
|
15197
|
+
label: `${formData.associatedEntityType.charAt(0).toUpperCase() + formData.associatedEntityType.slice(1)} ID`,
|
|
15198
|
+
placeholder: `Enter ${formData.associatedEntityType} ID`,
|
|
15199
|
+
value: formData.associatedEntityId,
|
|
15200
|
+
onChange: (e) => handleFieldChange("associatedEntityId", e.target.value)
|
|
15201
|
+
}
|
|
15202
|
+
)
|
|
15203
|
+
] })
|
|
15204
|
+
] }),
|
|
15205
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "border-t pt-6", children: [
|
|
15206
|
+
/* @__PURE__ */ jsxRuntime.jsx("h2", { className: "text-lg font-semibold mb-4", children: "Limit Configuration" }),
|
|
15207
|
+
renderTypeSpecificFields()
|
|
15208
|
+
] }),
|
|
15209
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-end gap-3 border-t pt-6", children: [
|
|
15210
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15211
|
+
Button,
|
|
15212
|
+
{
|
|
15213
|
+
type: "button",
|
|
15214
|
+
variant: "outline",
|
|
15215
|
+
onClick: () => navigate("/compliance/velocity"),
|
|
15216
|
+
children: "Cancel"
|
|
15217
|
+
}
|
|
15218
|
+
),
|
|
15219
|
+
/* @__PURE__ */ jsxRuntime.jsx(Button, { type: "submit", children: "Create Limit" })
|
|
15220
|
+
] })
|
|
15221
|
+
] })
|
|
15222
|
+
] }) }) }) }) })
|
|
15223
|
+
] });
|
|
15224
|
+
}
|
|
15225
|
+
var getStatusVariant2 = (status) => {
|
|
15226
|
+
switch (status) {
|
|
15227
|
+
case "ACTIVE":
|
|
15228
|
+
return "success";
|
|
15229
|
+
case "INACTIVE":
|
|
15230
|
+
return "warning";
|
|
15231
|
+
case "DELETED":
|
|
15232
|
+
return "destructive";
|
|
15233
|
+
default:
|
|
15234
|
+
return "secondary";
|
|
15235
|
+
}
|
|
15236
|
+
};
|
|
15237
|
+
var getActionVariant2 = (action) => {
|
|
15238
|
+
switch (action) {
|
|
15239
|
+
case "DECLINE":
|
|
15240
|
+
return "destructive";
|
|
15241
|
+
case "FLAG":
|
|
15242
|
+
return "warning";
|
|
15243
|
+
default:
|
|
15244
|
+
return "secondary";
|
|
15245
|
+
}
|
|
15246
|
+
};
|
|
15247
|
+
var VelocityLimitDetailsCard = ({
|
|
15248
|
+
isEditing,
|
|
15249
|
+
onToggleEdit,
|
|
15250
|
+
limit
|
|
15251
|
+
}) => {
|
|
15252
|
+
const renderTransactionFields = () => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
15253
|
+
limit.transactionType && limit.transactionType.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15254
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
15255
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm font-medium text-muted-foreground mb-1", children: "Transaction Type" }),
|
|
15256
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: limit.transactionType.map((type, index) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-foreground", children: type }, index)) })
|
|
15257
|
+
] }),
|
|
15258
|
+
limit.transactionGroup && limit.transactionGroup.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
15259
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm font-medium text-muted-foreground mb-1", children: "Transaction Group" }),
|
|
15260
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: limit.transactionGroup.map((group, index) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-foreground", children: group.toUpperCase() }, index)) })
|
|
15261
|
+
] })
|
|
15262
|
+
] }),
|
|
15263
|
+
!limit.transactionType && limit.transactionGroup && limit.transactionGroup.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-2 gap-4", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
15264
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm font-medium text-muted-foreground mb-1", children: "Transaction Group" }),
|
|
15265
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1", children: limit.transactionGroup.map((group, index) => /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-foreground", children: group.toUpperCase() }, index)) })
|
|
15266
|
+
] }) }),
|
|
15267
|
+
(limit.aggregationLevel || limit.timePeriod) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15268
|
+
limit.aggregationLevel && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15269
|
+
InfoField,
|
|
15270
|
+
{
|
|
15271
|
+
label: "Aggregation Level",
|
|
15272
|
+
value: limit.aggregationLevel.charAt(0).toUpperCase() + limit.aggregationLevel.slice(1),
|
|
15273
|
+
layout: "horizontal"
|
|
15274
|
+
}
|
|
15275
|
+
),
|
|
15276
|
+
limit.timePeriod && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15277
|
+
InfoField,
|
|
15278
|
+
{
|
|
15279
|
+
label: "Time Period",
|
|
15280
|
+
value: limit.timePeriod.charAt(0).toUpperCase() + limit.timePeriod.slice(1),
|
|
15281
|
+
layout: "horizontal"
|
|
15282
|
+
}
|
|
15283
|
+
)
|
|
15284
|
+
] }),
|
|
15285
|
+
(limit.maxAmount || limit.maxCount) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15286
|
+
limit.maxAmount && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15287
|
+
InfoField,
|
|
15288
|
+
{
|
|
15289
|
+
label: "Max Amount",
|
|
15290
|
+
value: `$${parseFloat(limit.maxAmount).toLocaleString()}`,
|
|
15291
|
+
layout: "horizontal"
|
|
15292
|
+
}
|
|
15293
|
+
),
|
|
15294
|
+
limit.maxCount && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15295
|
+
InfoField,
|
|
15296
|
+
{
|
|
15297
|
+
label: "Max Count",
|
|
15298
|
+
value: limit.maxCount,
|
|
15299
|
+
layout: "horizontal"
|
|
15300
|
+
}
|
|
15301
|
+
)
|
|
15302
|
+
] })
|
|
15303
|
+
] });
|
|
15304
|
+
const renderReceiverNameMismatchFields = () => /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: limit.mismatchThreshold && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15305
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15306
|
+
InfoField,
|
|
15307
|
+
{
|
|
15308
|
+
label: "Mismatch Threshold",
|
|
15309
|
+
value: `${limit.mismatchThreshold}%`,
|
|
15310
|
+
layout: "horizontal"
|
|
15311
|
+
}
|
|
15312
|
+
),
|
|
15313
|
+
limit.comparisonMethod && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15314
|
+
InfoField,
|
|
15315
|
+
{
|
|
15316
|
+
label: "Comparison Method",
|
|
15317
|
+
value: limit.comparisonMethod.charAt(0).toUpperCase() + limit.comparisonMethod.slice(1),
|
|
15318
|
+
layout: "horizontal"
|
|
15319
|
+
}
|
|
15320
|
+
)
|
|
15321
|
+
] }) });
|
|
15322
|
+
const renderRoundNumberFields = () => /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: limit.amountThreshold && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15323
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15324
|
+
InfoField,
|
|
15325
|
+
{
|
|
15326
|
+
label: "Amount Threshold",
|
|
15327
|
+
value: `$${parseFloat(limit.amountThreshold).toLocaleString()}`,
|
|
15328
|
+
layout: "horizontal"
|
|
15329
|
+
}
|
|
15330
|
+
),
|
|
15331
|
+
limit.roundPattern && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15332
|
+
InfoField,
|
|
15333
|
+
{
|
|
15334
|
+
label: "Round Patterns",
|
|
15335
|
+
value: limit.roundPattern,
|
|
15336
|
+
layout: "horizontal"
|
|
15337
|
+
}
|
|
15338
|
+
)
|
|
15339
|
+
] }) });
|
|
15340
|
+
const renderProhibitedEntityFields = () => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
15341
|
+
limit.entityListName && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15342
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15343
|
+
InfoField,
|
|
15344
|
+
{
|
|
15345
|
+
label: "Entity List Name",
|
|
15346
|
+
value: limit.entityListName,
|
|
15347
|
+
layout: "horizontal"
|
|
15348
|
+
}
|
|
15349
|
+
),
|
|
15350
|
+
limit.entityType && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15351
|
+
InfoField,
|
|
15352
|
+
{
|
|
15353
|
+
label: "Entity Type",
|
|
15354
|
+
value: limit.entityType.charAt(0).toUpperCase() + limit.entityType.slice(1),
|
|
15355
|
+
layout: "horizontal"
|
|
15356
|
+
}
|
|
15357
|
+
)
|
|
15358
|
+
] }),
|
|
15359
|
+
limit.prohibitedEntities && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-2 gap-4", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
15360
|
+
InfoField,
|
|
15361
|
+
{
|
|
15362
|
+
label: "Prohibited Entities",
|
|
15363
|
+
value: limit.prohibitedEntities,
|
|
15364
|
+
layout: "horizontal"
|
|
15365
|
+
}
|
|
15366
|
+
) })
|
|
15367
|
+
] });
|
|
15368
|
+
const viewContent = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
|
|
15369
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15370
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15371
|
+
InfoField,
|
|
15372
|
+
{
|
|
15373
|
+
label: "Limit Name",
|
|
15374
|
+
value: limit.limitName,
|
|
15375
|
+
layout: "horizontal"
|
|
15376
|
+
}
|
|
15377
|
+
),
|
|
15378
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15379
|
+
InfoField,
|
|
15380
|
+
{
|
|
15381
|
+
label: "Limit Type",
|
|
15382
|
+
value: limit.limitType.replace(/_/g, " ").replace(/\b\w/g, (l) => l.toUpperCase()),
|
|
15383
|
+
layout: "horizontal"
|
|
15384
|
+
}
|
|
15385
|
+
)
|
|
15386
|
+
] }),
|
|
15387
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15388
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15389
|
+
InfoField,
|
|
15390
|
+
{
|
|
15391
|
+
label: "Action",
|
|
15392
|
+
value: /* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getActionVariant2(limit.action), children: limit.action }),
|
|
15393
|
+
layout: "horizontal"
|
|
15394
|
+
}
|
|
15395
|
+
),
|
|
15396
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15397
|
+
InfoField,
|
|
15398
|
+
{
|
|
15399
|
+
label: "Created",
|
|
15400
|
+
value: dateFns.format(dateFns.parseISO(limit.created), "MMM dd, yyyy 'at' h:mm a"),
|
|
15401
|
+
layout: "horizontal"
|
|
15402
|
+
}
|
|
15403
|
+
)
|
|
15404
|
+
] }),
|
|
15405
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
|
|
15406
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15407
|
+
InfoField,
|
|
15408
|
+
{
|
|
15409
|
+
label: "Associated Entity",
|
|
15410
|
+
value: limit.associatedEntity,
|
|
15411
|
+
layout: "horizontal"
|
|
15412
|
+
}
|
|
15413
|
+
),
|
|
15414
|
+
limit.associatedEntityId && /* @__PURE__ */ jsxRuntime.jsx(
|
|
15415
|
+
InfoField,
|
|
15416
|
+
{
|
|
15417
|
+
label: "Associated Entity ID",
|
|
15418
|
+
value: limit.associatedEntityId,
|
|
15419
|
+
layout: "horizontal"
|
|
15420
|
+
}
|
|
15421
|
+
)
|
|
15422
|
+
] }),
|
|
15423
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
|
|
15424
|
+
limit.limitType === "transaction" && renderTransactionFields(),
|
|
15425
|
+
limit.limitType === "receiver_name_mismatch" && renderReceiverNameMismatchFields(),
|
|
15426
|
+
limit.limitType === "round_number" && renderRoundNumberFields(),
|
|
15427
|
+
limit.limitType === "prohibited_entity" && renderProhibitedEntityFields()
|
|
15428
|
+
] })
|
|
15429
|
+
] });
|
|
15430
|
+
const editContent = /* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-sm text-muted-foreground", children: "Edit mode coming soon..." });
|
|
15431
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
15432
|
+
EditableFormCard,
|
|
15433
|
+
{
|
|
15434
|
+
title: "Velocity Limit Details",
|
|
15435
|
+
viewContent,
|
|
15436
|
+
editContent,
|
|
15437
|
+
isEditing,
|
|
15438
|
+
onToggleEdit,
|
|
15439
|
+
variant: "subtle"
|
|
15440
|
+
}
|
|
15441
|
+
);
|
|
15442
|
+
};
|
|
15443
|
+
function VelocityLimitDetail() {
|
|
15444
|
+
const { id } = reactRouterDom.useParams();
|
|
15445
|
+
const navigate = reactRouterDom.useNavigate();
|
|
15446
|
+
const limit = mockVelocityLimits.find((l) => l.id === id);
|
|
15447
|
+
if (!limit) {
|
|
15448
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 py-8", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
|
|
15449
|
+
/* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-2xl font-bold mb-2", children: "Velocity Limit Not Found" }),
|
|
15450
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground mb-4", children: "The velocity limit could not be found." }),
|
|
15451
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Button, { onClick: () => navigate("/compliance/velocity"), children: [
|
|
15452
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowLeft, { className: "mr-2 h-4 w-4" }),
|
|
15453
|
+
"Back to Velocity Limits"
|
|
15454
|
+
] })
|
|
15455
|
+
] }) });
|
|
15456
|
+
}
|
|
15457
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
15458
|
+
DetailPageLayout,
|
|
15459
|
+
{
|
|
15460
|
+
title: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
|
|
15461
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { children: limit.limitName }),
|
|
15462
|
+
/* @__PURE__ */ jsxRuntime.jsx(Badge, { variant: getStatusVariant2(limit.status), children: limit.status })
|
|
15463
|
+
] }),
|
|
15464
|
+
cards: [
|
|
15465
|
+
{
|
|
15466
|
+
key: "details",
|
|
15467
|
+
component: (props) => /* @__PURE__ */ jsxRuntime.jsx(VelocityLimitDetailsCard, { ...props, limit })
|
|
15468
|
+
}
|
|
15469
|
+
],
|
|
15470
|
+
actions: [
|
|
15471
|
+
{
|
|
15472
|
+
label: "Deactivate",
|
|
15473
|
+
variant: "destructive",
|
|
15474
|
+
onClick: () => console.log("Deactivate limit")
|
|
15475
|
+
}
|
|
15476
|
+
]
|
|
15477
|
+
}
|
|
15478
|
+
);
|
|
15479
|
+
}
|
|
15480
|
+
function UploadReconDialog({ open, onOpenChange }) {
|
|
15481
|
+
const [fileType, setFileType] = React15.useState(null);
|
|
15482
|
+
const [selectedFile, setSelectedFile] = React15.useState(null);
|
|
15483
|
+
const [isUploading, setIsUploading] = React15.useState(false);
|
|
15484
|
+
const fileInputRef = React15.useRef(null);
|
|
15485
|
+
const handleFileChange = (event) => {
|
|
15486
|
+
const file = event.target.files?.[0];
|
|
15487
|
+
if (file) {
|
|
15488
|
+
setSelectedFile(file);
|
|
15489
|
+
}
|
|
15490
|
+
};
|
|
15491
|
+
const handleRemoveFile = () => {
|
|
15492
|
+
setSelectedFile(null);
|
|
15493
|
+
if (fileInputRef.current) {
|
|
15494
|
+
fileInputRef.current.value = "";
|
|
15495
|
+
}
|
|
15496
|
+
};
|
|
15497
|
+
const handleReset = () => {
|
|
15498
|
+
setFileType(null);
|
|
15499
|
+
setSelectedFile(null);
|
|
15500
|
+
if (fileInputRef.current) {
|
|
15501
|
+
fileInputRef.current.value = "";
|
|
15502
|
+
}
|
|
15503
|
+
};
|
|
15504
|
+
const handleUpload = async () => {
|
|
15505
|
+
if (!selectedFile || !fileType) return;
|
|
15506
|
+
setIsUploading(true);
|
|
15507
|
+
setTimeout(() => {
|
|
15508
|
+
setIsUploading(false);
|
|
15509
|
+
sonner.toast.success(`${fileType} file uploaded successfully`);
|
|
15510
|
+
handleReset();
|
|
15511
|
+
onOpenChange(false);
|
|
15512
|
+
}, 2e3);
|
|
15513
|
+
};
|
|
15514
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxRuntime.jsxs(DialogContent, { className: "sm:max-w-[500px]", children: [
|
|
15515
|
+
/* @__PURE__ */ jsxRuntime.jsx(DialogHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(DialogTitle, { children: "Upload Recon File" }) }),
|
|
15516
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4 py-4", children: [
|
|
15517
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-3", children: [
|
|
15518
|
+
/* @__PURE__ */ jsxRuntime.jsx(Label, { children: "File Type" }),
|
|
15519
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-3", children: [
|
|
15520
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
15521
|
+
"button",
|
|
15522
|
+
{
|
|
15523
|
+
type: "button",
|
|
15524
|
+
onClick: () => setFileType("ACH"),
|
|
15525
|
+
className: cn(
|
|
15526
|
+
"flex flex-col items-center gap-3 p-4 border-2 rounded-lg transition-all",
|
|
15527
|
+
fileType === "ACH" ? "border-primary bg-primary/5" : "border-border hover:border-primary/50"
|
|
15528
|
+
),
|
|
15529
|
+
children: [
|
|
15530
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.ArrowRightLeft, { className: "h-8 w-8 text-primary" }),
|
|
15531
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
|
|
15532
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-medium", children: "ACH" }),
|
|
15533
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs text-muted-foreground mt-1", children: "ACH Originated/Received Entries Detail Report in .csv format" })
|
|
15534
|
+
] })
|
|
15535
|
+
]
|
|
15536
|
+
}
|
|
15537
|
+
),
|
|
15538
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
15539
|
+
"button",
|
|
15540
|
+
{
|
|
15541
|
+
type: "button",
|
|
15542
|
+
onClick: () => setFileType("Wire"),
|
|
15543
|
+
className: cn(
|
|
15544
|
+
"flex flex-col items-center gap-3 p-4 border-2 rounded-lg transition-all",
|
|
15545
|
+
fileType === "Wire" ? "border-primary bg-primary/5" : "border-border hover:border-primary/50"
|
|
15546
|
+
),
|
|
15547
|
+
children: [
|
|
15548
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Zap, { className: "h-8 w-8 text-primary" }),
|
|
15549
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
|
|
15550
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "font-medium", children: "Wire" }),
|
|
15551
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-xs text-muted-foreground mt-1", children: "FedTransaction Analyzer report in .csv format" })
|
|
15552
|
+
] })
|
|
15553
|
+
]
|
|
15554
|
+
}
|
|
15555
|
+
)
|
|
15556
|
+
] })
|
|
15557
|
+
] }),
|
|
15558
|
+
fileType && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "border-2 border-dashed border-border rounded-lg p-6", children: !selectedFile ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center justify-center gap-4", children: [
|
|
15559
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Upload, { className: "h-12 w-12 text-muted-foreground" }),
|
|
15560
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-center", children: [
|
|
15561
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium", children: "Select a file to upload" }),
|
|
15562
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-xs text-muted-foreground mt-1", children: "CSV, TXT files supported" })
|
|
15563
|
+
] }),
|
|
15564
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15565
|
+
"input",
|
|
15566
|
+
{
|
|
15567
|
+
ref: fileInputRef,
|
|
15568
|
+
type: "file",
|
|
15569
|
+
onChange: handleFileChange,
|
|
15570
|
+
className: "hidden",
|
|
15571
|
+
accept: ".csv,.txt",
|
|
15572
|
+
id: "recon-file-upload"
|
|
15573
|
+
}
|
|
15574
|
+
),
|
|
15575
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15576
|
+
Button,
|
|
15577
|
+
{
|
|
15578
|
+
type: "button",
|
|
15579
|
+
variant: "outline",
|
|
15580
|
+
onClick: () => fileInputRef.current?.click(),
|
|
15581
|
+
children: "Select File"
|
|
15582
|
+
}
|
|
15583
|
+
)
|
|
15584
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-4", children: [
|
|
15585
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3 flex-1 min-w-0", children: [
|
|
15586
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.File, { className: "h-8 w-8 text-primary flex-shrink-0" }),
|
|
15587
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-0", children: [
|
|
15588
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm font-medium truncate", children: selectedFile.name }),
|
|
15589
|
+
/* @__PURE__ */ jsxRuntime.jsxs("p", { className: "text-xs text-muted-foreground", children: [
|
|
15590
|
+
(selectedFile.size / 1024).toFixed(2),
|
|
15591
|
+
" KB"
|
|
15592
|
+
] })
|
|
15593
|
+
] })
|
|
15594
|
+
] }),
|
|
15595
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15596
|
+
Button,
|
|
15597
|
+
{
|
|
15598
|
+
type: "button",
|
|
15599
|
+
variant: "ghost",
|
|
15600
|
+
size: "icon",
|
|
15601
|
+
onClick: handleRemoveFile,
|
|
15602
|
+
className: "flex-shrink-0",
|
|
15603
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.X, { className: "h-4 w-4" })
|
|
15604
|
+
}
|
|
15605
|
+
)
|
|
15606
|
+
] }) })
|
|
15607
|
+
] }),
|
|
15608
|
+
/* @__PURE__ */ jsxRuntime.jsxs(DialogFooter, { children: [
|
|
15609
|
+
/* @__PURE__ */ jsxRuntime.jsx(Button, { variant: "outline", onClick: () => {
|
|
15610
|
+
handleReset();
|
|
15611
|
+
onOpenChange(false);
|
|
15612
|
+
}, children: "Cancel" }),
|
|
15613
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
15614
|
+
Button,
|
|
15615
|
+
{
|
|
15616
|
+
onClick: handleUpload,
|
|
15617
|
+
disabled: !selectedFile || !fileType || isUploading,
|
|
15618
|
+
children: isUploading ? "Uploading..." : "Upload"
|
|
15619
|
+
}
|
|
15620
|
+
)
|
|
15621
|
+
] })
|
|
15622
|
+
] }) });
|
|
15623
|
+
}
|
|
15624
|
+
|
|
15625
|
+
// src/lib/mock-data/recon-data.ts
|
|
15626
|
+
var mockReconUploads = [
|
|
15627
|
+
{
|
|
15628
|
+
id: "1",
|
|
15629
|
+
uploaded: "2025-11-14T10:30:00Z",
|
|
15630
|
+
fileName: "OE_ACH Originated Entries ...",
|
|
15631
|
+
type: "FED_ACH_CONF...",
|
|
15632
|
+
status: "Processed",
|
|
15633
|
+
requester: "bcontrucci@ssbp...",
|
|
15634
|
+
totalRecords: 2872,
|
|
15635
|
+
matchedRecords: 2872,
|
|
15636
|
+
exceptionRecords: 0,
|
|
15637
|
+
skippedRecords: 0,
|
|
15638
|
+
invalidRecords: 0
|
|
15639
|
+
},
|
|
15640
|
+
{
|
|
15641
|
+
id: "2",
|
|
15642
|
+
uploaded: "2025-11-14T09:15:00Z",
|
|
15643
|
+
fileName: "RER_ACH Received Entries ...",
|
|
15644
|
+
type: "FED_ACH_CONF...",
|
|
15645
|
+
status: "Processed",
|
|
15646
|
+
requester: "bcontrucci@ssbp...",
|
|
15647
|
+
totalRecords: 220,
|
|
15648
|
+
matchedRecords: 220,
|
|
15649
|
+
exceptionRecords: 0,
|
|
15650
|
+
skippedRecords: 0,
|
|
15651
|
+
invalidRecords: 0
|
|
15652
|
+
},
|
|
15653
|
+
{
|
|
15654
|
+
id: "3",
|
|
15655
|
+
uploaded: "2025-11-14T08:45:00Z",
|
|
15656
|
+
fileName: "243073959_335935.csv",
|
|
15657
|
+
type: "FED_WIRE_CON...",
|
|
15658
|
+
status: "Processed",
|
|
15659
|
+
requester: "bcontrucci@ssbp...",
|
|
15660
|
+
totalRecords: 304,
|
|
15661
|
+
matchedRecords: 220,
|
|
15662
|
+
exceptionRecords: 2,
|
|
15663
|
+
skippedRecords: 82,
|
|
15664
|
+
invalidRecords: 0
|
|
15665
|
+
},
|
|
15666
|
+
{
|
|
15667
|
+
id: "4",
|
|
15668
|
+
uploaded: "2025-11-13T16:20:00Z",
|
|
15669
|
+
fileName: "OE_ACH Originated Entries ...",
|
|
15670
|
+
type: "FED_ACH_CONF...",
|
|
15671
|
+
status: "Processed",
|
|
15672
|
+
requester: "bcontrucci@ssbp...",
|
|
15673
|
+
totalRecords: 4813,
|
|
15674
|
+
matchedRecords: 4811,
|
|
15675
|
+
exceptionRecords: 2,
|
|
15676
|
+
skippedRecords: 0,
|
|
15677
|
+
invalidRecords: 0
|
|
15678
|
+
},
|
|
15679
|
+
{
|
|
15680
|
+
id: "5",
|
|
15681
|
+
uploaded: "2025-11-13T15:10:00Z",
|
|
15682
|
+
fileName: "243073959_335846.csv",
|
|
15683
|
+
type: "FED_WIRE_CON...",
|
|
15684
|
+
status: "Processed",
|
|
15685
|
+
requester: "bcontrucci@ssbp...",
|
|
15686
|
+
totalRecords: 391,
|
|
15687
|
+
matchedRecords: 258,
|
|
15688
|
+
exceptionRecords: 2,
|
|
15689
|
+
skippedRecords: 131,
|
|
15690
|
+
invalidRecords: 0
|
|
15691
|
+
},
|
|
15692
|
+
{
|
|
15693
|
+
id: "6",
|
|
15694
|
+
uploaded: "2025-11-13T14:30:00Z",
|
|
15695
|
+
fileName: "RER_ACH Received Entries ...",
|
|
15696
|
+
type: "FED_ACH_CONF...",
|
|
15697
|
+
status: "Processed",
|
|
15698
|
+
requester: "bcontrucci@ssbp...",
|
|
15699
|
+
totalRecords: 227,
|
|
15700
|
+
matchedRecords: 221,
|
|
15701
|
+
exceptionRecords: 6,
|
|
15702
|
+
skippedRecords: 0,
|
|
15703
|
+
invalidRecords: 0
|
|
15704
|
+
},
|
|
15705
|
+
{
|
|
15706
|
+
id: "7",
|
|
15707
|
+
uploaded: "2025-11-13T13:45:00Z",
|
|
15708
|
+
fileName: "OE_ACH Originated Entries ...",
|
|
15709
|
+
type: "FED_ACH_CONF...",
|
|
15710
|
+
status: "Processed",
|
|
15711
|
+
requester: "bcontrucci@ssbp...",
|
|
15712
|
+
totalRecords: 6471,
|
|
15713
|
+
matchedRecords: 6471,
|
|
15714
|
+
exceptionRecords: 0,
|
|
15715
|
+
skippedRecords: 0,
|
|
15716
|
+
invalidRecords: 0
|
|
15717
|
+
},
|
|
15718
|
+
{
|
|
15719
|
+
id: "8",
|
|
15720
|
+
uploaded: "2025-11-12T11:20:00Z",
|
|
15721
|
+
fileName: "OE_ACH Originated Entries ...",
|
|
15722
|
+
type: "FED_ACH_CONF...",
|
|
15723
|
+
status: "Failed",
|
|
15724
|
+
requester: "bcontrucci@ssbp...",
|
|
15725
|
+
totalRecords: 0,
|
|
15726
|
+
matchedRecords: 0,
|
|
15727
|
+
exceptionRecords: 0,
|
|
15728
|
+
skippedRecords: 0,
|
|
15729
|
+
invalidRecords: 0
|
|
15730
|
+
},
|
|
15731
|
+
{
|
|
15732
|
+
id: "9",
|
|
15733
|
+
uploaded: "2025-11-12T10:15:00Z",
|
|
15734
|
+
fileName: "RER_ACH Received Entries ...",
|
|
15735
|
+
type: "FED_ACH_CONF...",
|
|
15736
|
+
status: "Processed",
|
|
15737
|
+
requester: "bcontrucci@ssbp...",
|
|
15738
|
+
totalRecords: 189,
|
|
15739
|
+
matchedRecords: 170,
|
|
15740
|
+
exceptionRecords: 19,
|
|
15741
|
+
skippedRecords: 0,
|
|
15742
|
+
invalidRecords: 0
|
|
15743
|
+
}
|
|
15744
|
+
];
|
|
15745
|
+
function ReconUpload() {
|
|
15746
|
+
const [sortField, setSortField] = React15.useState("uploaded");
|
|
15747
|
+
const [sortDirection, setSortDirection] = React15.useState("desc");
|
|
15748
|
+
const [uploadDialogOpen, setUploadDialogOpen] = React15.useState(false);
|
|
15749
|
+
const handleSort = (field) => {
|
|
15750
|
+
if (sortField === field) {
|
|
15751
|
+
setSortDirection(sortDirection === "asc" ? "desc" : "asc");
|
|
15752
|
+
} else {
|
|
15753
|
+
setSortField(field);
|
|
15754
|
+
setSortDirection("desc");
|
|
15755
|
+
}
|
|
15756
|
+
};
|
|
15757
|
+
const sortedUploads = [...mockReconUploads].sort((a, b) => {
|
|
15758
|
+
const aValue = a[sortField];
|
|
15759
|
+
const bValue = b[sortField];
|
|
15760
|
+
if (aValue == null) return 1;
|
|
15761
|
+
if (bValue == null) return -1;
|
|
15762
|
+
if (sortDirection === "asc") {
|
|
15763
|
+
return aValue > bValue ? 1 : -1;
|
|
15764
|
+
} else {
|
|
15765
|
+
return aValue < bValue ? 1 : -1;
|
|
15766
|
+
}
|
|
15767
|
+
});
|
|
15768
|
+
const columns3 = [
|
|
15769
|
+
{
|
|
15770
|
+
key: "uploaded",
|
|
15771
|
+
title: "Uploaded",
|
|
15772
|
+
sortable: true,
|
|
15773
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: dateFns.format(dateFns.parseISO(value), "yyyy-MM-dd") })
|
|
15774
|
+
},
|
|
15775
|
+
{
|
|
15776
|
+
key: "fileName",
|
|
15777
|
+
title: "File Name",
|
|
15778
|
+
render: (value, row) => {
|
|
15779
|
+
const isACH = row.type.includes("ACH");
|
|
15780
|
+
const Icon2 = isACH ? lucideReact.ArrowRightLeft : lucideReact.Zap;
|
|
15781
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
15782
|
+
/* @__PURE__ */ jsxRuntime.jsx(Icon2, { className: "h-4 w-4 text-muted-foreground flex-shrink-0" }),
|
|
15783
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm font-medium", children: value })
|
|
15784
|
+
] });
|
|
15785
|
+
}
|
|
15786
|
+
},
|
|
15787
|
+
{
|
|
15788
|
+
key: "status",
|
|
15789
|
+
title: "Status",
|
|
15790
|
+
render: (value) => {
|
|
15791
|
+
if (value === "Processed") {
|
|
15792
|
+
return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.CheckCircle2, { className: "h-5 w-5 text-green-600" });
|
|
15793
|
+
}
|
|
15794
|
+
if (value === "Failed") {
|
|
15795
|
+
return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.XCircle, { className: "h-5 w-5 text-red-600" });
|
|
15796
|
+
}
|
|
15797
|
+
if (value === "Processing") {
|
|
15798
|
+
return /* @__PURE__ */ jsxRuntime.jsx(lucideReact.Circle, { className: "h-5 w-5 text-green-600" });
|
|
15799
|
+
}
|
|
15800
|
+
return /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value });
|
|
15801
|
+
}
|
|
15802
|
+
},
|
|
15803
|
+
{
|
|
15804
|
+
key: "requester",
|
|
15805
|
+
title: "Requester",
|
|
15806
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value })
|
|
15807
|
+
},
|
|
15808
|
+
{
|
|
15809
|
+
key: "totalRecords",
|
|
15810
|
+
title: "Total",
|
|
15811
|
+
sortable: true,
|
|
15812
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value.toLocaleString() })
|
|
15813
|
+
},
|
|
15814
|
+
{
|
|
15815
|
+
key: "matchedRecords",
|
|
15816
|
+
title: "Matched",
|
|
15817
|
+
sortable: true,
|
|
15818
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value.toLocaleString() })
|
|
15819
|
+
},
|
|
15820
|
+
{
|
|
15821
|
+
key: "exceptionRecords",
|
|
15822
|
+
title: "Exception",
|
|
15823
|
+
sortable: true,
|
|
15824
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value.toLocaleString() })
|
|
15825
|
+
},
|
|
15826
|
+
{
|
|
15827
|
+
key: "skippedRecords",
|
|
15828
|
+
title: "Skipped",
|
|
15829
|
+
sortable: true,
|
|
15830
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value.toLocaleString() })
|
|
15831
|
+
},
|
|
15832
|
+
{
|
|
15833
|
+
key: "invalidRecords",
|
|
15834
|
+
title: "Invalid",
|
|
15835
|
+
sortable: true,
|
|
15836
|
+
render: (value) => /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: value.toLocaleString() })
|
|
15837
|
+
}
|
|
15838
|
+
];
|
|
15839
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col h-screen bg-gradient-subtle", children: [
|
|
15840
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-none border-b bg-background/95 backdrop-blur supports-[backdrop-filter]:bg-background/60", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 py-6 max-w-none", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
15841
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { children: /* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold text-foreground", children: "Recon File Uploads" }) }),
|
|
15842
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex items-center gap-3", children: /* @__PURE__ */ jsxRuntime.jsxs(Button, { onClick: () => setUploadDialogOpen(true), children: [
|
|
15843
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Upload, { className: "mr-2 h-4 w-4" }),
|
|
15844
|
+
"Upload Recon file"
|
|
15845
|
+
] }) })
|
|
15846
|
+
] }) }) }),
|
|
15847
|
+
/* @__PURE__ */ jsxRuntime.jsx(UploadReconDialog, { open: uploadDialogOpen, onOpenChange: setUploadDialogOpen }),
|
|
15848
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 overflow-hidden", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "container mx-auto px-4 h-full max-w-none flex flex-col", children: /* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 mt-4 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
15849
|
+
DataTable,
|
|
15850
|
+
{
|
|
15851
|
+
columns: columns3,
|
|
15852
|
+
data: sortedUploads,
|
|
15853
|
+
sortBy: sortField,
|
|
15854
|
+
sortDirection,
|
|
15855
|
+
onSort: handleSort
|
|
15856
|
+
}
|
|
15857
|
+
) }) }) })
|
|
15858
|
+
] });
|
|
15859
|
+
}
|
|
15860
|
+
|
|
15861
|
+
// src/lib/mock-data/recon-exception-data.ts
|
|
15862
|
+
var mockBraidTransactions = [
|
|
15863
|
+
{
|
|
15864
|
+
id: "BT-001",
|
|
15865
|
+
amount: 15e3,
|
|
15866
|
+
postDate: "2025-01-15",
|
|
15867
|
+
senderAccount: "1234567890",
|
|
15868
|
+
receiverAccount: "9876543210",
|
|
15869
|
+
type: "ACH"
|
|
15870
|
+
},
|
|
15871
|
+
{
|
|
15872
|
+
id: "BT-002",
|
|
15873
|
+
amount: 8500.5,
|
|
15874
|
+
postDate: "2025-01-15",
|
|
15875
|
+
senderAccount: "2345678901",
|
|
15876
|
+
receiverAccount: "8765432109",
|
|
15877
|
+
type: "ACH"
|
|
15878
|
+
},
|
|
15879
|
+
{
|
|
15880
|
+
id: "BT-003",
|
|
15881
|
+
amount: 25e3,
|
|
15882
|
+
postDate: "2025-01-16",
|
|
15883
|
+
senderAccount: "3456789012",
|
|
15884
|
+
receiverAccount: "7654321098",
|
|
15885
|
+
type: "ACH"
|
|
15886
|
+
},
|
|
15887
|
+
{
|
|
15888
|
+
id: "BT-004",
|
|
15889
|
+
amount: 5e4,
|
|
15890
|
+
postDate: "2025-01-15",
|
|
15891
|
+
senderAccount: "4567890123",
|
|
15892
|
+
receiverAccount: "6543210987",
|
|
15893
|
+
type: "Wire"
|
|
15894
|
+
},
|
|
15895
|
+
{
|
|
15896
|
+
id: "BT-005",
|
|
15897
|
+
amount: 12500.75,
|
|
15898
|
+
postDate: "2025-01-16",
|
|
15899
|
+
senderAccount: "5678901234",
|
|
15900
|
+
receiverAccount: "5432109876",
|
|
15901
|
+
type: "Wire"
|
|
15902
|
+
},
|
|
15903
|
+
{
|
|
15904
|
+
id: "BT-006",
|
|
15905
|
+
amount: 3200,
|
|
15906
|
+
postDate: "2025-01-17",
|
|
15907
|
+
senderAccount: "6789012345",
|
|
15908
|
+
receiverAccount: "4321098765",
|
|
15909
|
+
type: "ACH"
|
|
15910
|
+
}
|
|
15911
|
+
];
|
|
15912
|
+
var mockFedSettlements = [
|
|
15913
|
+
{
|
|
15914
|
+
id: "FS-001",
|
|
15915
|
+
amount: 15e3,
|
|
15916
|
+
settlementDate: "2025-01-15",
|
|
15917
|
+
receiverAccount: "9876543210",
|
|
15918
|
+
type: "ACH"
|
|
15919
|
+
},
|
|
15920
|
+
{
|
|
15921
|
+
id: "FS-002",
|
|
15922
|
+
amount: 8500.5,
|
|
15923
|
+
settlementDate: "2025-01-15",
|
|
15924
|
+
receiverAccount: "8765432109",
|
|
15925
|
+
type: "ACH"
|
|
15926
|
+
},
|
|
15927
|
+
{
|
|
15928
|
+
id: "FS-003",
|
|
15929
|
+
amount: 24999,
|
|
15930
|
+
settlementDate: "2025-01-16",
|
|
15931
|
+
receiverAccount: "7654321098",
|
|
15932
|
+
type: "ACH"
|
|
15933
|
+
},
|
|
15934
|
+
{
|
|
15935
|
+
id: "FS-004",
|
|
15936
|
+
amount: 5e4,
|
|
15937
|
+
settlementDate: "2025-01-15",
|
|
15938
|
+
receiverAccount: "6543210987",
|
|
15939
|
+
type: "Wire"
|
|
15940
|
+
},
|
|
15941
|
+
{
|
|
15942
|
+
id: "FS-005",
|
|
15943
|
+
amount: 12500.75,
|
|
15944
|
+
settlementDate: "2025-01-16",
|
|
15945
|
+
receiverAccount: "5432109876",
|
|
15946
|
+
type: "Wire"
|
|
15947
|
+
},
|
|
15948
|
+
{
|
|
15949
|
+
id: "FS-006",
|
|
15950
|
+
amount: 7800,
|
|
15951
|
+
settlementDate: "2025-01-17",
|
|
15952
|
+
receiverAccount: "3210987654",
|
|
15953
|
+
type: "ACH"
|
|
15954
|
+
}
|
|
15955
|
+
];
|
|
15956
|
+
function ReconExceptions() {
|
|
15957
|
+
const [fromDate, setFromDate] = React15.useState();
|
|
15958
|
+
const [toDate, setToDate] = React15.useState();
|
|
15959
|
+
const [transactionType, setTransactionType] = React15.useState("ACH");
|
|
15960
|
+
const [braidData, setBraidData] = React15.useState(mockBraidTransactions);
|
|
15961
|
+
const [fedData, setFedData] = React15.useState(mockFedSettlements);
|
|
15962
|
+
const [selectedBraid, setSelectedBraid] = React15.useState(null);
|
|
15963
|
+
const [selectedFed, setSelectedFed] = React15.useState(null);
|
|
15964
|
+
const [dataLoaded, setDataLoaded] = React15.useState(true);
|
|
15965
|
+
const [braidPage, setBraidPage] = React15.useState(1);
|
|
15966
|
+
const [braidRowsPerPage, setBraidRowsPerPage] = React15.useState(10);
|
|
15967
|
+
const [fedPage, setFedPage] = React15.useState(1);
|
|
15968
|
+
const [fedRowsPerPage, setFedRowsPerPage] = React15.useState(10);
|
|
15969
|
+
const handleSearch = () => {
|
|
15970
|
+
if (!fromDate || !toDate) {
|
|
15971
|
+
toast({
|
|
15972
|
+
title: "Missing Date Range",
|
|
15973
|
+
description: "Please select both from and to dates",
|
|
15974
|
+
variant: "destructive"
|
|
15975
|
+
});
|
|
15976
|
+
return;
|
|
15977
|
+
}
|
|
15978
|
+
const filteredBraid = mockBraidTransactions.filter((t) => {
|
|
15979
|
+
const tDate = new Date(t.postDate);
|
|
15980
|
+
return t.type === transactionType && tDate >= fromDate && tDate <= toDate;
|
|
15981
|
+
});
|
|
15982
|
+
const filteredFed = mockFedSettlements.filter((s) => {
|
|
15983
|
+
const sDate = new Date(s.settlementDate);
|
|
15984
|
+
return s.type === transactionType && sDate >= fromDate && sDate <= toDate;
|
|
15985
|
+
});
|
|
15986
|
+
setBraidData(filteredBraid);
|
|
15987
|
+
setFedData(filteredFed);
|
|
15988
|
+
setDataLoaded(true);
|
|
15989
|
+
setSelectedBraid(null);
|
|
15990
|
+
setSelectedFed(null);
|
|
15991
|
+
setBraidPage(1);
|
|
15992
|
+
setFedPage(1);
|
|
15993
|
+
toast({
|
|
15994
|
+
title: "Data Loaded",
|
|
15995
|
+
description: `Found ${filteredBraid.length} Braid transactions and ${filteredFed.length} Fed settlements`
|
|
15996
|
+
});
|
|
15997
|
+
};
|
|
15998
|
+
const handleMatch = () => {
|
|
15999
|
+
if (!selectedBraid || !selectedFed) {
|
|
16000
|
+
toast({
|
|
16001
|
+
title: "Selection Required",
|
|
16002
|
+
description: "Please select one transaction from each table",
|
|
16003
|
+
variant: "destructive"
|
|
16004
|
+
});
|
|
16005
|
+
return;
|
|
16006
|
+
}
|
|
16007
|
+
const braidTxn = braidData.find((t) => t.id === selectedBraid);
|
|
16008
|
+
const fedTxn = fedData.find((s) => s.id === selectedFed);
|
|
16009
|
+
setBraidData((prev) => prev.filter((t) => t.id !== selectedBraid));
|
|
16010
|
+
setFedData((prev) => prev.filter((s) => s.id !== selectedFed));
|
|
16011
|
+
setSelectedBraid(null);
|
|
16012
|
+
setSelectedFed(null);
|
|
16013
|
+
toast({
|
|
16014
|
+
title: "Transactions Matched",
|
|
16015
|
+
description: `Matched ${braidTxn?.id} with ${fedTxn?.id}`
|
|
16016
|
+
});
|
|
16017
|
+
};
|
|
16018
|
+
const canMatch = selectedBraid && selectedFed;
|
|
16019
|
+
const braidTotalPages = Math.ceil(braidData.length / braidRowsPerPage);
|
|
16020
|
+
const braidStartIndex = (braidPage - 1) * braidRowsPerPage;
|
|
16021
|
+
const braidPaginatedData = braidData.slice(braidStartIndex, braidStartIndex + braidRowsPerPage);
|
|
16022
|
+
const fedTotalPages = Math.ceil(fedData.length / fedRowsPerPage);
|
|
16023
|
+
const fedStartIndex = (fedPage - 1) * fedRowsPerPage;
|
|
16024
|
+
const fedPaginatedData = fedData.slice(fedStartIndex, fedStartIndex + fedRowsPerPage);
|
|
16025
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container, { size: "full", padding: "lg", children: /* @__PURE__ */ jsxRuntime.jsxs(Stack, { spacing: "lg", children: [
|
|
16026
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
16027
|
+
/* @__PURE__ */ jsxRuntime.jsx("h1", { className: "text-3xl font-bold tracking-tight", children: "Exception Review" }),
|
|
16028
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-muted-foreground mt-2", children: "Compare Braid posted transactions with Fed settlement records for reconciliation" })
|
|
16029
|
+
] }),
|
|
16030
|
+
/* @__PURE__ */ jsxRuntime.jsx(Card, { children: /* @__PURE__ */ jsxRuntime.jsx(CardContent, { className: "pt-6", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-end gap-4", children: [
|
|
16031
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-w-[200px]", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16032
|
+
DatePicker,
|
|
16033
|
+
{
|
|
16034
|
+
label: "From Date",
|
|
16035
|
+
date: fromDate,
|
|
16036
|
+
onDateChange: setFromDate,
|
|
16037
|
+
placeholder: "Select from date"
|
|
16038
|
+
}
|
|
16039
|
+
) }),
|
|
16040
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex-1 min-w-[200px]", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16041
|
+
DatePicker,
|
|
16042
|
+
{
|
|
16043
|
+
label: "To Date",
|
|
16044
|
+
date: toDate,
|
|
16045
|
+
onDateChange: setToDate,
|
|
16046
|
+
placeholder: "Select to date"
|
|
16047
|
+
}
|
|
16048
|
+
) }),
|
|
16049
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex-1 min-w-[200px]", children: [
|
|
16050
|
+
/* @__PURE__ */ jsxRuntime.jsx(Label, { children: "Transaction Type" }),
|
|
16051
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-4 mt-2", children: [
|
|
16052
|
+
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 cursor-pointer", children: [
|
|
16053
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16054
|
+
"input",
|
|
16055
|
+
{
|
|
16056
|
+
type: "radio",
|
|
16057
|
+
value: "ACH",
|
|
16058
|
+
checked: transactionType === "ACH",
|
|
16059
|
+
onChange: (e) => setTransactionType(e.target.value),
|
|
16060
|
+
className: "w-4 h-4 text-primary"
|
|
16061
|
+
}
|
|
16062
|
+
),
|
|
16063
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: "ACH" })
|
|
16064
|
+
] }),
|
|
16065
|
+
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 cursor-pointer", children: [
|
|
16066
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16067
|
+
"input",
|
|
16068
|
+
{
|
|
16069
|
+
type: "radio",
|
|
16070
|
+
value: "Wire",
|
|
16071
|
+
checked: transactionType === "Wire",
|
|
16072
|
+
onChange: (e) => setTransactionType(e.target.value),
|
|
16073
|
+
className: "w-4 h-4 text-primary"
|
|
16074
|
+
}
|
|
16075
|
+
),
|
|
16076
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: "Wire" })
|
|
16077
|
+
] })
|
|
16078
|
+
] })
|
|
16079
|
+
] }),
|
|
16080
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Button, { onClick: handleSearch, className: "gap-2", children: [
|
|
16081
|
+
/* @__PURE__ */ jsxRuntime.jsx(lucideReact.Search, { className: "h-4 w-4" }),
|
|
16082
|
+
"Search"
|
|
16083
|
+
] })
|
|
16084
|
+
] }) }) }),
|
|
16085
|
+
!dataLoaded ? /* @__PURE__ */ jsxRuntime.jsx(Card, { children: /* @__PURE__ */ jsxRuntime.jsx(CardContent, { className: "py-12 text-center text-muted-foreground", children: "Select date range and transaction type, then click Search to load data" }) }) : /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
16086
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-1 lg:grid-cols-2 gap-6", children: [
|
|
16087
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "flex flex-col", children: [
|
|
16088
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(CardTitle, { className: "text-lg", children: [
|
|
16089
|
+
"Braid Posted Transactions (",
|
|
16090
|
+
braidData.length,
|
|
16091
|
+
")"
|
|
16092
|
+
] }) }),
|
|
16093
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CardContent, { className: "flex flex-col flex-1", children: [
|
|
16094
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-md border flex-1 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsxs(Table, { children: [
|
|
16095
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(TableRow, { children: [
|
|
16096
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { className: "w-12" }),
|
|
16097
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Amount" }),
|
|
16098
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Post Date" }),
|
|
16099
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Sender Account" }),
|
|
16100
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Receiver Account" })
|
|
16101
|
+
] }) }),
|
|
16102
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableBody, { children: braidData.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(TableRow, { children: /* @__PURE__ */ jsxRuntime.jsx(TableCell, { colSpan: 5, className: "text-center text-muted-foreground", children: "No transactions found" }) }) : braidPaginatedData.map((txn) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16103
|
+
TableRow,
|
|
16104
|
+
{
|
|
16105
|
+
className: selectedBraid === txn.id ? "bg-muted" : "",
|
|
16106
|
+
children: [
|
|
16107
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16108
|
+
"input",
|
|
16109
|
+
{
|
|
16110
|
+
type: "radio",
|
|
16111
|
+
name: "braid-select",
|
|
16112
|
+
checked: selectedBraid === txn.id,
|
|
16113
|
+
onChange: () => setSelectedBraid(txn.id),
|
|
16114
|
+
className: "w-4 h-4 text-primary cursor-pointer"
|
|
16115
|
+
}
|
|
16116
|
+
) }),
|
|
16117
|
+
/* @__PURE__ */ jsxRuntime.jsxs(TableCell, { className: "font-medium", children: [
|
|
16118
|
+
"$",
|
|
16119
|
+
txn.amount.toLocaleString("en-US", { minimumFractionDigits: 2, maximumFractionDigits: 2 })
|
|
16120
|
+
] }),
|
|
16121
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { children: dateFns.format(new Date(txn.postDate), "MMM dd, yyyy") }),
|
|
16122
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { className: "font-mono text-sm", children: txn.senderAccount }),
|
|
16123
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { className: "font-mono text-sm", children: txn.receiverAccount })
|
|
16124
|
+
]
|
|
16125
|
+
},
|
|
16126
|
+
txn.id
|
|
16127
|
+
)) })
|
|
16128
|
+
] }) }),
|
|
16129
|
+
braidData.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between px-2 py-4", children: [
|
|
16130
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
16131
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: "Rows per page:" }),
|
|
16132
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
16133
|
+
"select",
|
|
16134
|
+
{
|
|
16135
|
+
value: braidRowsPerPage,
|
|
16136
|
+
onChange: (e) => {
|
|
16137
|
+
setBraidRowsPerPage(Number(e.target.value));
|
|
16138
|
+
setBraidPage(1);
|
|
16139
|
+
},
|
|
16140
|
+
className: "h-8 w-16 rounded-md border border-input bg-background px-2 text-sm",
|
|
16141
|
+
children: [
|
|
16142
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 10, children: "10" }),
|
|
16143
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 25, children: "25" }),
|
|
16144
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 50, children: "50" })
|
|
16145
|
+
]
|
|
16146
|
+
}
|
|
16147
|
+
)
|
|
16148
|
+
] }),
|
|
16149
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
16150
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-muted-foreground", children: [
|
|
16151
|
+
"Page ",
|
|
16152
|
+
braidPage,
|
|
16153
|
+
" of ",
|
|
16154
|
+
braidTotalPages
|
|
16155
|
+
] }),
|
|
16156
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-1", children: [
|
|
16157
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16158
|
+
Button,
|
|
16159
|
+
{
|
|
16160
|
+
variant: "outline",
|
|
16161
|
+
size: "sm",
|
|
16162
|
+
onClick: () => setBraidPage(Math.max(1, braidPage - 1)),
|
|
16163
|
+
disabled: braidPage === 1,
|
|
16164
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronLeft, { className: "h-4 w-4" })
|
|
16165
|
+
}
|
|
16166
|
+
),
|
|
16167
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16168
|
+
Button,
|
|
16169
|
+
{
|
|
16170
|
+
variant: "outline",
|
|
16171
|
+
size: "sm",
|
|
16172
|
+
onClick: () => setBraidPage(Math.min(braidTotalPages, braidPage + 1)),
|
|
16173
|
+
disabled: braidPage === braidTotalPages,
|
|
16174
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "h-4 w-4" })
|
|
16175
|
+
}
|
|
16176
|
+
)
|
|
16177
|
+
] })
|
|
16178
|
+
] })
|
|
16179
|
+
] })
|
|
16180
|
+
] })
|
|
16181
|
+
] }),
|
|
16182
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Card, { className: "flex flex-col", children: [
|
|
16183
|
+
/* @__PURE__ */ jsxRuntime.jsx(CardHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(CardTitle, { className: "text-lg", children: [
|
|
16184
|
+
"Fed Settlement Records (",
|
|
16185
|
+
fedData.length,
|
|
16186
|
+
")"
|
|
16187
|
+
] }) }),
|
|
16188
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CardContent, { className: "flex flex-col flex-1", children: [
|
|
16189
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "rounded-md border flex-1 overflow-auto", children: /* @__PURE__ */ jsxRuntime.jsxs(Table, { children: [
|
|
16190
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs(TableRow, { children: [
|
|
16191
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { className: "w-12" }),
|
|
16192
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Amount" }),
|
|
16193
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Settlement Date" }),
|
|
16194
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHead, { children: "Receiver Account" })
|
|
16195
|
+
] }) }),
|
|
16196
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableBody, { children: fedData.length === 0 ? /* @__PURE__ */ jsxRuntime.jsx(TableRow, { children: /* @__PURE__ */ jsxRuntime.jsx(TableCell, { colSpan: 4, className: "text-center text-muted-foreground", children: "No settlements found" }) }) : fedPaginatedData.map((settlement) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
16197
|
+
TableRow,
|
|
16198
|
+
{
|
|
16199
|
+
className: selectedFed === settlement.id ? "bg-muted" : "",
|
|
16200
|
+
children: [
|
|
16201
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16202
|
+
"input",
|
|
16203
|
+
{
|
|
16204
|
+
type: "radio",
|
|
16205
|
+
name: "fed-select",
|
|
16206
|
+
checked: selectedFed === settlement.id,
|
|
16207
|
+
onChange: () => setSelectedFed(settlement.id),
|
|
16208
|
+
className: "w-4 h-4 text-primary cursor-pointer"
|
|
16209
|
+
}
|
|
16210
|
+
) }),
|
|
16211
|
+
/* @__PURE__ */ jsxRuntime.jsxs(TableCell, { className: "font-medium", children: [
|
|
16212
|
+
"$",
|
|
16213
|
+
settlement.amount.toLocaleString("en-US", { minimumFractionDigits: 2, maximumFractionDigits: 2 })
|
|
16214
|
+
] }),
|
|
16215
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { children: dateFns.format(new Date(settlement.settlementDate), "MMM dd, yyyy") }),
|
|
16216
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { className: "font-mono text-sm", children: settlement.receiverAccount })
|
|
16217
|
+
]
|
|
16218
|
+
},
|
|
16219
|
+
settlement.id
|
|
16220
|
+
)) })
|
|
16221
|
+
] }) }),
|
|
16222
|
+
fedData.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between px-2 py-4", children: [
|
|
16223
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
16224
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-muted-foreground", children: "Rows per page:" }),
|
|
16225
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
16226
|
+
"select",
|
|
16227
|
+
{
|
|
16228
|
+
value: fedRowsPerPage,
|
|
16229
|
+
onChange: (e) => {
|
|
16230
|
+
setFedRowsPerPage(Number(e.target.value));
|
|
16231
|
+
setFedPage(1);
|
|
16232
|
+
},
|
|
16233
|
+
className: "h-8 w-16 rounded-md border border-input bg-background px-2 text-sm",
|
|
16234
|
+
children: [
|
|
16235
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 10, children: "10" }),
|
|
16236
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 25, children: "25" }),
|
|
16237
|
+
/* @__PURE__ */ jsxRuntime.jsx("option", { value: 50, children: "50" })
|
|
16238
|
+
]
|
|
16239
|
+
}
|
|
16240
|
+
)
|
|
16241
|
+
] }),
|
|
16242
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2", children: [
|
|
16243
|
+
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-muted-foreground", children: [
|
|
16244
|
+
"Page ",
|
|
16245
|
+
fedPage,
|
|
16246
|
+
" of ",
|
|
16247
|
+
fedTotalPages
|
|
16248
|
+
] }),
|
|
16249
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex gap-1", children: [
|
|
16250
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16251
|
+
Button,
|
|
16252
|
+
{
|
|
16253
|
+
variant: "outline",
|
|
16254
|
+
size: "sm",
|
|
16255
|
+
onClick: () => setFedPage(Math.max(1, fedPage - 1)),
|
|
16256
|
+
disabled: fedPage === 1,
|
|
16257
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronLeft, { className: "h-4 w-4" })
|
|
16258
|
+
}
|
|
16259
|
+
),
|
|
16260
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
16261
|
+
Button,
|
|
16262
|
+
{
|
|
16263
|
+
variant: "outline",
|
|
16264
|
+
size: "sm",
|
|
16265
|
+
onClick: () => setFedPage(Math.min(fedTotalPages, fedPage + 1)),
|
|
16266
|
+
disabled: fedPage === fedTotalPages,
|
|
16267
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(lucideReact.ChevronRight, { className: "h-4 w-4" })
|
|
16268
|
+
}
|
|
16269
|
+
)
|
|
16270
|
+
] })
|
|
16271
|
+
] })
|
|
16272
|
+
] })
|
|
16273
|
+
] })
|
|
16274
|
+
] })
|
|
16275
|
+
] }),
|
|
16276
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "flex justify-center", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
16277
|
+
Button,
|
|
16278
|
+
{
|
|
16279
|
+
size: "lg",
|
|
16280
|
+
onClick: handleMatch,
|
|
16281
|
+
disabled: !canMatch,
|
|
16282
|
+
className: "min-w-[200px]",
|
|
16283
|
+
children: "Match Selected"
|
|
16284
|
+
}
|
|
16285
|
+
) })
|
|
16286
|
+
] })
|
|
16287
|
+
] }) });
|
|
16288
|
+
}
|
|
14746
16289
|
|
|
14747
16290
|
exports.ACHBankCard = ACHBankCard;
|
|
14748
16291
|
exports.ACHBasicInfoCard = ACHBasicInfoCard;
|
|
@@ -14802,6 +16345,7 @@ exports.CreateBusiness = Create_default;
|
|
|
14802
16345
|
exports.CreateBusinessView = CreateBusinessView;
|
|
14803
16346
|
exports.CreateCounterparty = Create_default2;
|
|
14804
16347
|
exports.CreateIndividual = Create_default3;
|
|
16348
|
+
exports.CreateVelocityLimit = CreateVelocityLimit;
|
|
14805
16349
|
exports.Dashboard = Dashboard_default;
|
|
14806
16350
|
exports.DashboardDemo = DashboardDemo;
|
|
14807
16351
|
exports.DataGrid = DataGrid;
|
|
@@ -14848,7 +16392,6 @@ exports.MainLayout = MainLayout;
|
|
|
14848
16392
|
exports.MetricCard = MetricCard;
|
|
14849
16393
|
exports.NewTransaction = NewTransaction;
|
|
14850
16394
|
exports.NotFound = NotFound_default;
|
|
14851
|
-
exports.OFAC = OFAC;
|
|
14852
16395
|
exports.OFACAlertView = OFACAlertView;
|
|
14853
16396
|
exports.OriginatorCard = OriginatorCard;
|
|
14854
16397
|
exports.OriginatorFI = OriginatorFI;
|
|
@@ -14860,6 +16403,8 @@ exports.Popover = Popover;
|
|
|
14860
16403
|
exports.PopoverContent = PopoverContent;
|
|
14861
16404
|
exports.PopoverTrigger = PopoverTrigger;
|
|
14862
16405
|
exports.ReceiverCard = ReceiverCard;
|
|
16406
|
+
exports.ReconExceptions = ReconExceptions;
|
|
16407
|
+
exports.ReconUpload = ReconUpload;
|
|
14863
16408
|
exports.ResolveAlertDialog = ResolveAlertDialog;
|
|
14864
16409
|
exports.ResponsiveGrid = ResponsiveGrid;
|
|
14865
16410
|
exports.ScrollArea = ScrollArea;
|
|
@@ -14932,6 +16477,8 @@ exports.TransactionHistory = TransactionHistory_default;
|
|
|
14932
16477
|
exports.TransactionTypeBadge = TransactionTypeBadge;
|
|
14933
16478
|
exports.UIKit = UIKit;
|
|
14934
16479
|
exports.UIKitShowcase = UIKitShowcase;
|
|
16480
|
+
exports.VelocityLimitDetail = VelocityLimitDetail;
|
|
16481
|
+
exports.VelocityLimits = VelocityLimits;
|
|
14935
16482
|
exports.WireDetailsSection = WireDetailsSection;
|
|
14936
16483
|
exports.WireTransferSection = WireTransferSection;
|
|
14937
16484
|
exports.badgeVariants = badgeVariants;
|