@tesouro/embedded-components-react 0.4.12 → 0.4.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +1 -1
- package/dist/lib/BillPayWidget.js +1 -1
- package/dist/lib/monite-sdk.d.ts +204 -468
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index.js +14 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index10.js +37 -78
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index11.js +98 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js +81 -15
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index13.js +7 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index14.js +16 -61
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index15.js +26 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index16.js +63 -65
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index17.js +2 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index18.js +66 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index19.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index2.js +6 -24
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index20.js +4 -32
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js +3 -41
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index22.js +28 -166
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index23.js +40 -44
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index24.js +173 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index25.js +45 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index26.js +1 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index27.js +45 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index28.js +4 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index29.js +13 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index3.js +55 -22
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index30.js +8 -66
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index31.js +7 -19
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index32.js +58 -126
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index33.js +15 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index34.js +134 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index35.js +14 -31
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index36.js +4 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index37.js +39 -87
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index38.js +78 -67
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index39.js +78 -48
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index4.js +24 -57
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index40.js +47 -91
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index41.js +119 -33
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index42.js +33 -168
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index43.js +170 -75
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index44.js +75 -21
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index45.js +23 -210
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index46.js +199 -203
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index47.js +198 -89
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index48.js +105 -13
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index49.js +12 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index5.js +23 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index50.js +47 -31
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index51.js +27 -198
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index52.js +198 -30
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index53.js +30 -234
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index54.js +240 -19
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index55.js +19 -342
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index56.js +364 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index57.js +4 -34
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index58.js +32 -167
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index59.js +186 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index6.js +56 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index60.js +3 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index61.js +2 -44
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index62.js +46 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index63.js +1 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index64.js +6 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index65.js +9 -92
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index66.js +94 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index67.js +3 -128
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index68.js +125 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index69.js +8 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index7.js +5 -69
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index70.js +8 -46
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index71.js +43 -18
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index72.js +20 -28
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index73.js +27 -82
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index74.js +83 -47
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index75.js +47 -250
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index76.js +239 -101
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index77.js +107 -202
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index78.js +209 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index79.js +4 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index8.js +5 -43
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index80.js +6 -113
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index81.js +115 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index82.js +0 -24
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index83.js +25 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index9.js +64 -89
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +40 -37
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index100.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index101.js +52 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index102.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index15.js +2 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index16.js +12 -62
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index17.js +12 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index18.js +16 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index19.js +2 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index20.js +2 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index21.js +30 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index22.js +2 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index23.js +28 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +0 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +6 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index26.js +161 -154
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index31.js +16 -21
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index32.js +47 -337
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index34.js +20 -13
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index35.js +327 -107
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index37.js +13 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index38.js +113 -92
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +9 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index41.js +95 -55
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +9 -51
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index44.js +56 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index45.js +2 -160
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index46.js +54 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index47.js +11 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index48.js +178 -37
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index49.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index50.js +2 -5
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index51.js +37 -88
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index53.js +5 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index54.js +88 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index56.js +2 -84
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index57.js +11 -282
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index58.js +2 -13
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index59.js +87 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index60.js +294 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index61.js +9 -35
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index62.js +0 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index63.js +5 -36
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index64.js +37 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index65.js +2 -201
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index66.js +39 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index67.js +3 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index68.js +187 -333
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index69.js +3 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index70.js +13 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index71.js +335 -81
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index72.js +10 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index73.js +8 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index74.js +87 -121
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index76.js +2 -89
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index77.js +127 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index78.js +25 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index79.js +85 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index81.js +3 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index82.js +26 -30
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index84.js +4 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index85.js +30 -102
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index87.js +9 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index88.js +85 -104
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index90.js +10 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index91.js +123 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index92.js +2 -170
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index93.js +18 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index94.js +7 -11
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index95.js +158 -96
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index96.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index97.js +11 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index98.js +100 -44
- package/dist/libs/tesouro-embedded-components-react/monite-sdk/dist/index618.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/widget-suite/feature/dist/index8.js +1 -1
- package/package.json +7 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index75.js +0 -28
|
@@ -1,4 +1,364 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
"use client";
|
|
3
|
+
"use client";
|
|
4
|
+
"use client";
|
|
5
|
+
import { hasAnyScope as e } from "../../../shared/data-access/dist/lib/hasAnyScope.js";
|
|
6
|
+
import { Scope as t } from "../../../shared/data-access/dist/lib/scopes.js";
|
|
7
|
+
import { useAllLedgerAccountsQuery as ee } from "../../../shared/data-access/dist/lib/reference-data/useLedgerAccountsQuery.js";
|
|
8
|
+
import { useAllOrganizationUsersQuery as te } from "../../../shared/data-access/dist/lib/user/useAllOrganizationUsersQuery.js";
|
|
9
|
+
import "../../../shared/data-access/dist/index.js";
|
|
10
|
+
import { formatCalendarDate as ne } from "../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
11
|
+
import { useWidgetConfig as re } from "../../../shared/feature/dist/lib/WidgetProvider/hooks.js";
|
|
12
|
+
import "../../../shared/feature/dist/index.js";
|
|
13
|
+
import { usePayableHistoryQuery as ie } from "../../data-access/dist/index9.js";
|
|
14
|
+
import { useAllPayableLineItemsQuery as ae } from "../../data-access/dist/index10.js";
|
|
15
|
+
import { usePayableQuery as oe } from "../../data-access/dist/index15.js";
|
|
16
|
+
import "../../data-access/dist/index.js";
|
|
17
|
+
import { resolveVendor as se } from "./index7.js";
|
|
18
|
+
import { BillCreateScreen as ce } from "../../ui/dist/index48.js";
|
|
19
|
+
import { BillDecisionDialog as n } from "../../ui/dist/index54.js";
|
|
20
|
+
import { BillDuplicateNotice as le } from "../../ui/dist/index64.js";
|
|
21
|
+
import { ExtractionNotice as ue } from "../../ui/dist/index82.js";
|
|
22
|
+
import { MarkAsPaidDialog as de } from "../../ui/dist/index91.js";
|
|
23
|
+
import { UnsavedBillDialog as fe } from "../../ui/dist/index101.js";
|
|
24
|
+
import "../../ui/dist/index.js";
|
|
25
|
+
import { usePayableDuplicateReview as pe } from "./index12.js";
|
|
26
|
+
import "./index13.js";
|
|
27
|
+
import { resolveAmountDueMinorUnits as me } from "./index19.js";
|
|
28
|
+
import { PayBillFlow as he } from "./index25.js";
|
|
29
|
+
import "./index26.js";
|
|
30
|
+
import { useMarkAsPaidFlow as ge } from "./index16.js";
|
|
31
|
+
import "./index17.js";
|
|
32
|
+
import { BILL_CREATE_MESSAGE_LABELS_EN as _e, mergeBillCreateScreenCopy as ve } from "./index43.js";
|
|
33
|
+
import { useBillCreateController as ye } from "./index52.js";
|
|
34
|
+
import { useBillForm as be } from "./index54.js";
|
|
35
|
+
import { buildPaymentHistory as xe } from "./index3.js";
|
|
36
|
+
import { useApprovalPolicyCardView as Se } from "./index32.js";
|
|
37
|
+
import { useCurrentApprovalRequestId as Ce } from "./index33.js";
|
|
38
|
+
import { usePayableDetailActions as we } from "./index34.js";
|
|
39
|
+
import { useScheduledPayment as Te } from "./index35.js";
|
|
40
|
+
import { isEditablePayableStatus as Ee } from "./index36.js";
|
|
41
|
+
import { useDraftDelete as De } from "./index37.js";
|
|
42
|
+
import { buildBillDetailView as Oe } from "./index39.js";
|
|
43
|
+
import { buildBillHistory as ke } from "./index40.js";
|
|
44
|
+
import { SourceDocumentContainer as Ae } from "./index44.js";
|
|
45
|
+
import { useVendorSectionProps as je } from "./index47.js";
|
|
46
|
+
import { usePaymentInstructionsForm as Me } from "./index48.js";
|
|
47
|
+
import { billCreateTestIds as r } from "./index55.js";
|
|
48
|
+
import { useCallback as i, useEffect as Ne, useMemo as a, useRef as Pe, useState as o } from "react";
|
|
49
|
+
import { Fragment as Fe, jsx as s, jsxs as Ie } from "react/jsx-runtime";
|
|
50
|
+
import { Trash2Icon as Le } from "lucide-react";
|
|
51
|
+
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index56.js
|
|
52
|
+
function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f, onCollapse: Re, poweredByBankName: ze }) {
|
|
53
|
+
let p = a(() => ve(f), [f]), [m, h] = o(), [g, _] = o(!1), [Be, Ve] = o(!1), [He, v] = o(!1), [Ue, y] = o(), b = u ?? Ue, x = oe(b, { pollWhileOcrProcessing: !0 }), S = ae(b), { initResponse: C } = re(), w = !!C, T = e(C?.scopes, [t.AccountingConfigReadOrg]), E = ee({ enabled: T }), D = x.data, O = !b || !!D, k = !d && O && !!b && D?.status !== "draft", We = !d && !!D && !Ee(D?.status), A = d || We, j = be({
|
|
54
|
+
payable: D,
|
|
55
|
+
lineItems: S.lineItems
|
|
56
|
+
}), M = D?.counterpart_id;
|
|
57
|
+
Ne(() => {
|
|
58
|
+
g || M && (h(M), _(!0));
|
|
59
|
+
}, [g, M]);
|
|
60
|
+
let Ge = i((e) => {
|
|
61
|
+
_(!0), h(e);
|
|
62
|
+
}, []), N = je({
|
|
63
|
+
payableId: d ? void 0 : b,
|
|
64
|
+
counterpartId: d ? void 0 : m,
|
|
65
|
+
payableCounterpartId: M,
|
|
66
|
+
onCounterpartChange: Ge,
|
|
67
|
+
requiredError: j.errors?.vendor,
|
|
68
|
+
payableCounterpartBankAccountId: D?.counterpart_bank_account_id ?? void 0,
|
|
69
|
+
extractedVendor: D?.counterpart_raw_data ?? void 0
|
|
70
|
+
}), Ke = !!(b && g) && !m, qe = a(() => k ? { saveDraftButton: p.submittedSaveButton } : void 0, [p.submittedSaveButton, k]), Je = a(() => k ? { draftSaved: _e.submittedSaved } : void 0, [k]), P = x.refetch, Ye = i(async () => {
|
|
71
|
+
let { data: e } = await P();
|
|
72
|
+
return e?.status ?? void 0;
|
|
73
|
+
}, [P]), F = ye({
|
|
74
|
+
payableId: u,
|
|
75
|
+
form: j,
|
|
76
|
+
labels: Je,
|
|
77
|
+
counterpartId: m,
|
|
78
|
+
clearCounterpart: Ke,
|
|
79
|
+
prepareVendorForSave: N.savePaymentInstructions,
|
|
80
|
+
onPayableCreated: y,
|
|
81
|
+
onSaved: y,
|
|
82
|
+
onDraftSaved: () => l(!1),
|
|
83
|
+
onFinalized: () => l(!1),
|
|
84
|
+
readSavedStatus: k ? Ye : void 0
|
|
85
|
+
}), Xe = !!(F.isSavingDraft || F.isFinalizing), I = d ? b : void 0, L = Ce({
|
|
86
|
+
payableId: I,
|
|
87
|
+
status: D?.status
|
|
88
|
+
}), Ze = Pe(null), R = Te({
|
|
89
|
+
payableId: b,
|
|
90
|
+
scheduledPaymentDate: D?.scheduled_payment_date,
|
|
91
|
+
enabled: d || k
|
|
92
|
+
}), Qe = se(D), z = Me({
|
|
93
|
+
payableId: I,
|
|
94
|
+
counterpartId: d ? M : void 0,
|
|
95
|
+
saveErrorMessage: p.detail.paymentInstructionsSaveError,
|
|
96
|
+
linkErrorMessage: p.detail.paymentInstructionsLinkError
|
|
97
|
+
}), $e = e(C?.scopes, [t.PayableWriteOrg]), et = e(C?.scopes, [t.CounterpartWriteOrg]) && $e, B = ge({
|
|
98
|
+
payableId: I,
|
|
99
|
+
amountDueMinorUnits: me(D) ?? 0,
|
|
100
|
+
amountToPayMinorUnits: D?.amount_to_pay ?? void 0,
|
|
101
|
+
currencyCode: D?.currency ?? void 0,
|
|
102
|
+
dueDate: D?.due_date,
|
|
103
|
+
hasScheduledPayment: R.hasScheduledPayment,
|
|
104
|
+
labels: p.markAsPaid
|
|
105
|
+
}), V = Se({
|
|
106
|
+
payableId: I,
|
|
107
|
+
approvalPolicyId: D?.approval_policy_id,
|
|
108
|
+
enabled: d,
|
|
109
|
+
copy: p.approvalPolicyCopy
|
|
110
|
+
}), { actions: H, decisionDialog: tt, isActionPending: nt } = we({
|
|
111
|
+
payableId: d || k ? b : void 0,
|
|
112
|
+
status: D?.status,
|
|
113
|
+
currentApprovalRequestId: L.id,
|
|
114
|
+
isPolicyApprover: L.isPolicyApprover,
|
|
115
|
+
hasWaitingRequest: L.hasWaitingRequest,
|
|
116
|
+
arePendingApproversUnknown: V.isLoading,
|
|
117
|
+
hasScheduledPayment: R.hasScheduledPayment,
|
|
118
|
+
scheduledPaymentIntentId: R.scheduledPaymentIntentId,
|
|
119
|
+
isScheduledPaymentUnknown: R.isResolving,
|
|
120
|
+
pendingApprovers: V.pendingApprovers,
|
|
121
|
+
labels: p.actions,
|
|
122
|
+
isMarkAsPaidPending: B.isPending,
|
|
123
|
+
onMarkAsPaidSelect: B.open,
|
|
124
|
+
onPayBillSelect: () => Ze.current?.open(),
|
|
125
|
+
onActionSucceeded: k ? () => l(!1) : void 0
|
|
126
|
+
}), U = De({
|
|
127
|
+
payableId: b,
|
|
128
|
+
status: D?.status,
|
|
129
|
+
enabled: !d,
|
|
130
|
+
labels: p.deleteDraft,
|
|
131
|
+
onDeleted: () => l(!1)
|
|
132
|
+
}), W = Xe || nt, G = x.isLoading || S.isResolving || E.isResolving, K = x.isError || S.isError || E.isError, rt = a(() => [...U.menuItems, ...k || d && !G && !K ? H.menu.map((e) => ({
|
|
133
|
+
id: e.id,
|
|
134
|
+
label: e.label,
|
|
135
|
+
onSelect: e.onSelect,
|
|
136
|
+
disabled: e.disabled,
|
|
137
|
+
icon: e.icon,
|
|
138
|
+
sectionHeading: e.sectionHeading
|
|
139
|
+
})) : []], [
|
|
140
|
+
H.menu,
|
|
141
|
+
U.menuItems,
|
|
142
|
+
k,
|
|
143
|
+
d,
|
|
144
|
+
G,
|
|
145
|
+
K
|
|
146
|
+
]), q = a(() => (E.data?.data ?? []).map((e) => ({
|
|
147
|
+
value: e.id,
|
|
148
|
+
label: [e.nominal_code, e.name].filter(Boolean).join(" — ")
|
|
149
|
+
})), [E.data]), J;
|
|
150
|
+
w && (T ? E.isError ? J = p.lineItemsGlCodeUnavailable.loadError : !E.isResolving && q.length === 0 && (J = p.lineItemsGlCodeUnavailable.empty) : J = p.lineItemsGlCodeUnavailable.noAccess);
|
|
151
|
+
let it = !w || !!J || E.isResolving, at = T && !E.isResolving && !E.isError, Y = ie(I), ot = e(C?.scopes, [t.UserReadOrg]), st = te({ enabled: d && ot }), ct = a(() => ke(Y.data?.data ?? [], st.data?.data ?? [], p.history), [
|
|
152
|
+
Y.data,
|
|
153
|
+
st.data,
|
|
154
|
+
p.history
|
|
155
|
+
]), lt = a(() => xe({
|
|
156
|
+
records: R.paymentRecords,
|
|
157
|
+
events: Y.data?.data ?? [],
|
|
158
|
+
currencyCode: D?.currency,
|
|
159
|
+
labels: p.detail
|
|
160
|
+
}), [
|
|
161
|
+
R.paymentRecords,
|
|
162
|
+
Y.data,
|
|
163
|
+
D?.currency,
|
|
164
|
+
p.detail
|
|
165
|
+
]), ut = a(() => d && D ? Oe({
|
|
166
|
+
payable: D,
|
|
167
|
+
lineItems: S.lineItems,
|
|
168
|
+
glCodeOptions: q,
|
|
169
|
+
glCodeRosterAvailable: at,
|
|
170
|
+
history: ct,
|
|
171
|
+
paymentHistory: lt,
|
|
172
|
+
approvalPolicy: V.view,
|
|
173
|
+
labels: p.detail,
|
|
174
|
+
hasScheduledPayment: R.hasScheduledPayment
|
|
175
|
+
}) : void 0, [
|
|
176
|
+
R.hasScheduledPayment,
|
|
177
|
+
V.view,
|
|
178
|
+
p.detail,
|
|
179
|
+
q,
|
|
180
|
+
at,
|
|
181
|
+
ct,
|
|
182
|
+
S.lineItems,
|
|
183
|
+
D,
|
|
184
|
+
lt,
|
|
185
|
+
d
|
|
186
|
+
]), dt = D?.source_of_payable_data === "ocr", X = Qe?.name, ft = d ? X ? p.viewTitle(X) : p.readOnlyTitle : X && (dt || k) ? p.extractedTitle(X) : p.newTitle, pt = d && D?.created_at ? p.addedOn(ne(D.created_at.slice(0, 10))) : void 0, Z = i(() => {
|
|
187
|
+
let e = j.isDirty || N.hasUnsavedVendorChanges || !!F.stagedFile || F.isFileDeletionPending;
|
|
188
|
+
if (!A && e) {
|
|
189
|
+
v(!0);
|
|
190
|
+
return;
|
|
191
|
+
}
|
|
192
|
+
l(!1);
|
|
193
|
+
}, [
|
|
194
|
+
F.isFileDeletionPending,
|
|
195
|
+
F.stagedFile,
|
|
196
|
+
j.isDirty,
|
|
197
|
+
A,
|
|
198
|
+
l,
|
|
199
|
+
N.hasUnsavedVendorChanges
|
|
200
|
+
]), mt = i(() => {
|
|
201
|
+
v(!1), l(!1);
|
|
202
|
+
}, [l]), Q = S.isResolving || N.mode === "creating", ht = i(async () => {
|
|
203
|
+
if (Q) return;
|
|
204
|
+
let e = await F.saveDraft();
|
|
205
|
+
v(!1), e && l(!1);
|
|
206
|
+
}, [
|
|
207
|
+
F,
|
|
208
|
+
Q,
|
|
209
|
+
l
|
|
210
|
+
]), $ = pe({
|
|
211
|
+
payable: D,
|
|
212
|
+
onRemoved: () => l(!1),
|
|
213
|
+
canManage: $e
|
|
214
|
+
}), gt = i((e) => {
|
|
215
|
+
if (!(W || $.isBusy)) return e ? l(!0) : Z();
|
|
216
|
+
}, [
|
|
217
|
+
$.isBusy,
|
|
218
|
+
W,
|
|
219
|
+
Z,
|
|
220
|
+
l
|
|
221
|
+
]), _t = $.isPossibleDuplicate, vt = !d && dt && !Be, yt = _t || vt ? /* @__PURE__ */ Ie(Fe, { children: [_t ? /* @__PURE__ */ s(le, {
|
|
222
|
+
onNotADuplicate: $.onNotADuplicate,
|
|
223
|
+
onRemoveBill: $.onRemoveBill,
|
|
224
|
+
isActionDisabled: $.isBusy,
|
|
225
|
+
labels: $.removeBillLabel ? { removeBillButton: $.removeBillLabel } : void 0,
|
|
226
|
+
testId: r.duplicateNotice
|
|
227
|
+
}) : null, vt ? /* @__PURE__ */ s(ue, { onDismiss: () => Ve(!0) }) : null] }) : void 0;
|
|
228
|
+
return /* @__PURE__ */ Ie(Fe, { children: [
|
|
229
|
+
/* @__PURE__ */ s(ce, {
|
|
230
|
+
open: c,
|
|
231
|
+
onOpenChange: gt,
|
|
232
|
+
title: ft,
|
|
233
|
+
subtitle: pt,
|
|
234
|
+
notice: yt,
|
|
235
|
+
vendor: {
|
|
236
|
+
...N,
|
|
237
|
+
testId: r.vendorSection
|
|
238
|
+
},
|
|
239
|
+
values: j.values,
|
|
240
|
+
errors: j.errors,
|
|
241
|
+
onChange: j.onChange,
|
|
242
|
+
lineItems: {
|
|
243
|
+
items: j.lineItemRows,
|
|
244
|
+
glCodeOptions: q,
|
|
245
|
+
glCodeDisabled: it,
|
|
246
|
+
glCodeUnavailableMessage: J,
|
|
247
|
+
discount: j.discount,
|
|
248
|
+
onDiscountChange: j.onDiscountChange,
|
|
249
|
+
tax: j.tax,
|
|
250
|
+
onTaxChange: j.onTaxChange,
|
|
251
|
+
total: j.total,
|
|
252
|
+
onTotalChange: j.onTotalChange,
|
|
253
|
+
onAddLineItem: j.onAddLineItem,
|
|
254
|
+
errors: j.lineItemErrors,
|
|
255
|
+
totalsErrors: j.totalsErrors,
|
|
256
|
+
testId: r.lineItems
|
|
257
|
+
},
|
|
258
|
+
documentPanel: /* @__PURE__ */ s(Ae, {
|
|
259
|
+
payableId: b,
|
|
260
|
+
readOnly: A,
|
|
261
|
+
isDocumentPending: !!b && !D?.file && (x.isLoading || D?.ocr_status === "processing"),
|
|
262
|
+
file: D?.file ? {
|
|
263
|
+
id: D.file.id,
|
|
264
|
+
name: D.file.name,
|
|
265
|
+
url: D.file.url,
|
|
266
|
+
mimetype: D.file.mimetype
|
|
267
|
+
} : void 0,
|
|
268
|
+
staging: {
|
|
269
|
+
stagedFile: F.stagedFile,
|
|
270
|
+
onFileStaged: F.stageFile,
|
|
271
|
+
onClearStagedFile: F.clearStagedFile,
|
|
272
|
+
isSaving: Xe
|
|
273
|
+
},
|
|
274
|
+
deletion: {
|
|
275
|
+
isPending: F.isFileDeletionPending,
|
|
276
|
+
onRequest: F.requestFileDeletion,
|
|
277
|
+
onDetachNow: F.detachFileNow,
|
|
278
|
+
isDeleting: F.isDeletingFile,
|
|
279
|
+
hasFailed: F.hasFileDeletionFailed
|
|
280
|
+
}
|
|
281
|
+
}),
|
|
282
|
+
menuItems: rt,
|
|
283
|
+
readOnly: A,
|
|
284
|
+
detail: d ? {
|
|
285
|
+
view: ut,
|
|
286
|
+
actions: H,
|
|
287
|
+
scheduledSummary: R.hasScheduledPayment && R.scheduledDateLabel ? p.scheduledSummary(R.scheduledDateLabel) : void 0,
|
|
288
|
+
paymentInstructionsForm: M && et ? {
|
|
289
|
+
isOpen: z.isOpen,
|
|
290
|
+
values: z.values,
|
|
291
|
+
errors: z.errors,
|
|
292
|
+
isSaving: z.isSaving,
|
|
293
|
+
onOpen: z.open,
|
|
294
|
+
onCancel: z.close,
|
|
295
|
+
onChange: z.onChange,
|
|
296
|
+
onSave: z.save
|
|
297
|
+
} : void 0,
|
|
298
|
+
isLoading: G,
|
|
299
|
+
isError: K,
|
|
300
|
+
paymentHistoryError: R.isError || Y.isError,
|
|
301
|
+
paymentHistoryLoading: R.isResolving || Y.isLoading
|
|
302
|
+
} : void 0,
|
|
303
|
+
isLineItemsLoading: S.isResolving,
|
|
304
|
+
isSaving: W,
|
|
305
|
+
isSavingDraft: F.isSavingDraft,
|
|
306
|
+
isFinalizing: F.isFinalizing,
|
|
307
|
+
onCancel: Z,
|
|
308
|
+
onCollapse: d ? Re : void 0,
|
|
309
|
+
onSaveDraft: F.saveDraft,
|
|
310
|
+
onFinalize: F.finalize,
|
|
311
|
+
scrollToErrorToken: F.scrollToErrorToken,
|
|
312
|
+
showFinalize: !k && O,
|
|
313
|
+
labels: qe,
|
|
314
|
+
testId: r.dialog
|
|
315
|
+
}),
|
|
316
|
+
/* @__PURE__ */ s(fe, {
|
|
317
|
+
open: He,
|
|
318
|
+
onSaveDraft: ht,
|
|
319
|
+
onDiscard: mt,
|
|
320
|
+
onCancel: () => v(!1),
|
|
321
|
+
isSaving: F.isSavingDraft,
|
|
322
|
+
isSaveDraftDisabled: Q,
|
|
323
|
+
labels: p.unsavedChanges,
|
|
324
|
+
testId: r.unsavedDialog,
|
|
325
|
+
saveDraftTestId: r.unsavedSaveDraft,
|
|
326
|
+
discardTestId: r.unsavedDiscard,
|
|
327
|
+
closeTestId: r.unsavedClose
|
|
328
|
+
}),
|
|
329
|
+
/* @__PURE__ */ s(n, {
|
|
330
|
+
...tt,
|
|
331
|
+
labels: { cancelButton: p.actions.decisionDialog.cancelButton },
|
|
332
|
+
testId: r.decisionDialog,
|
|
333
|
+
confirmTestId: r.decisionConfirm,
|
|
334
|
+
reasonTestId: r.decisionReason
|
|
335
|
+
}),
|
|
336
|
+
/* @__PURE__ */ s(n, {
|
|
337
|
+
...U.dialog,
|
|
338
|
+
labels: { cancelButton: p.actions.decisionDialog.cancelButton },
|
|
339
|
+
testId: r.deleteDraftDialog,
|
|
340
|
+
confirmTestId: r.deleteDraftConfirm
|
|
341
|
+
}),
|
|
342
|
+
/* @__PURE__ */ s(n, {
|
|
343
|
+
open: $.removeConfirmation.open,
|
|
344
|
+
copy: $.removeConfirmation.copy,
|
|
345
|
+
onConfirm: $.removeConfirmation.onConfirm,
|
|
346
|
+
onCancel: $.removeConfirmation.onCancel,
|
|
347
|
+
isPending: $.removeConfirmation.isPending,
|
|
348
|
+
confirmIcon: /* @__PURE__ */ s(Le, {}),
|
|
349
|
+
labels: { cancelButton: $.removeConfirmation.cancelButtonLabel },
|
|
350
|
+
testId: r.duplicateRemoveDialog,
|
|
351
|
+
confirmTestId: r.duplicateRemoveConfirm
|
|
352
|
+
}),
|
|
353
|
+
/* @__PURE__ */ s(de, { ...B.dialogProps }),
|
|
354
|
+
d && D ? /* @__PURE__ */ s(he, {
|
|
355
|
+
ref: Ze,
|
|
356
|
+
payable: D,
|
|
357
|
+
onMissingAchInstructions: et ? z.open : void 0,
|
|
358
|
+
poweredByBankName: ze,
|
|
359
|
+
labels: p.payBill
|
|
360
|
+
}) : null
|
|
361
|
+
] });
|
|
362
|
+
}
|
|
363
|
+
//#endregion
|
|
364
|
+
export { c as BillCreateDialog, c as default };
|
|
@@ -1,34 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "
|
|
3
|
-
import
|
|
4
|
-
import "./
|
|
5
|
-
import { APPROVAL_POLICY_RULE_COPY_EN as n } from "./index25.js";
|
|
6
|
-
import { BILL_DETAIL_ACTIONS_LABELS_EN as r, SCHEDULED_SUMMARY_LABEL_EN as i } from "./index40.js";
|
|
7
|
-
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index57.js
|
|
8
|
-
var a = {
|
|
9
|
-
subtitle: "Accounts payable",
|
|
10
|
-
vendorRow: "Vendor",
|
|
11
|
-
bankAccountRow: "ACH bank account",
|
|
12
|
-
bankAccountValue: (e) => `Account ending in ${e}`,
|
|
13
|
-
invoiceNumberRow: "Number",
|
|
14
|
-
issueDateRow: "Issue date",
|
|
15
|
-
dueDateRow: "Due date",
|
|
16
|
-
poNumberRow: "PO number",
|
|
17
|
-
notProvided: "Not provided",
|
|
18
|
-
glCodeMissing: "GL code not specified",
|
|
19
|
-
quantityValue: (e, t) => `${e} x ${t}`,
|
|
20
|
-
subtotalRow: "Subtotal",
|
|
21
|
-
discountsRow: "Discounts",
|
|
22
|
-
taxRow: "Tax",
|
|
23
|
-
totalRow: "Total",
|
|
24
|
-
actionError: r.actionError,
|
|
25
|
-
actionSuccess: r.actionSuccess,
|
|
26
|
-
scheduledSummary: i,
|
|
27
|
-
paidOnLabel: (e) => `Paid on ${e}`,
|
|
28
|
-
sheet: e,
|
|
29
|
-
decisionDialog: r.decisionDialog,
|
|
30
|
-
approvalPolicyCopy: n,
|
|
31
|
-
markAsPaid: t
|
|
32
|
-
};
|
|
33
|
-
//#endregion
|
|
34
|
-
export { a as BILL_DETAILS_LABELS_EN };
|
|
1
|
+
import "./index43.js";
|
|
2
|
+
import "./index52.js";
|
|
3
|
+
import "./index54.js";
|
|
4
|
+
import "./index56.js";
|
|
@@ -1,170 +1,35 @@
|
|
|
1
|
-
|
|
2
|
-
"use client";
|
|
3
|
-
"use client";
|
|
4
|
-
"use client";
|
|
5
|
-
import { hasAnyScope as e } from "../../../shared/data-access/dist/lib/hasAnyScope.js";
|
|
6
|
-
import { Scope as t } from "../../../shared/data-access/dist/lib/scopes.js";
|
|
7
|
-
import { useAllLedgerAccountsQuery as n } from "../../../shared/data-access/dist/lib/reference-data/useLedgerAccountsQuery.js";
|
|
8
|
-
import "../../../shared/data-access/dist/index.js";
|
|
9
|
-
import { useWidgetConfig as r } from "../../../shared/feature/dist/lib/WidgetProvider/hooks.js";
|
|
10
|
-
import "../../../shared/feature/dist/index.js";
|
|
11
|
-
import { useAllPayableLineItemsQuery as i } from "../../data-access/dist/index10.js";
|
|
12
|
-
import { usePayableQuery as a } from "../../data-access/dist/index15.js";
|
|
13
|
-
import "../../data-access/dist/index.js";
|
|
14
|
-
import { BillDecisionDialog as o } from "../../ui/dist/index51.js";
|
|
15
|
-
import { BillDetailsSheet as s } from "../../ui/dist/index57.js";
|
|
16
|
-
import { BillDuplicateNotice as c } from "../../ui/dist/index61.js";
|
|
17
|
-
import { MarkAsPaidDialog as l } from "../../ui/dist/index88.js";
|
|
1
|
+
import { BILL_DETAILS_SHEET_LABELS_EN as e } from "../../ui/dist/index59.js";
|
|
18
2
|
import "../../ui/dist/index.js";
|
|
19
|
-
import {
|
|
20
|
-
import "./
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import "./index24.js";
|
|
24
|
-
import { mapPayableToBillDetails as p } from "./index37.js";
|
|
25
|
-
import { mergeMarkAsPaidFlowLabels as m } from "./index12.js";
|
|
26
|
-
import { useMarkAsPaidFlow as h } from "./index14.js";
|
|
27
|
-
import "./index15.js";
|
|
28
|
-
import { mergeDecisionDialogCopy as g } from "./index40.js";
|
|
29
|
-
import { useApprovalPolicyCardView as _ } from "./index30.js";
|
|
30
|
-
import { useCurrentApprovalRequestId as v } from "./index31.js";
|
|
31
|
-
import { usePayableDetailActions as y } from "./index32.js";
|
|
32
|
-
import { useScheduledPayment as b } from "./index33.js";
|
|
33
|
-
import { BILL_DETAILS_LABELS_EN as x } from "./index57.js";
|
|
34
|
-
import { useMemo as S, useRef as C } from "react";
|
|
35
|
-
import { Fragment as w, jsx as T, jsxs as E } from "react/jsx-runtime";
|
|
3
|
+
import { MARK_AS_PAID_FLOW_LABELS_EN as t } from "./index14.js";
|
|
4
|
+
import "./index17.js";
|
|
5
|
+
import { APPROVAL_POLICY_RULE_COPY_EN as n } from "./index27.js";
|
|
6
|
+
import { BILL_DETAIL_ACTIONS_LABELS_EN as r, PAYMENT_HISTORY_LABELS_EN as i, SCHEDULED_SUMMARY_LABEL_EN as a } from "./index41.js";
|
|
36
7
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index58.js
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
actionSuccess: {
|
|
64
|
-
...x.actionSuccess,
|
|
65
|
-
...N?.actionSuccess
|
|
66
|
-
}
|
|
67
|
-
}), [N]), I = a(k), L = i(k), R = n(), z = I.data, B = C(null), V = v({
|
|
68
|
-
payableId: k,
|
|
69
|
-
status: z?.status
|
|
70
|
-
}), H = _({
|
|
71
|
-
payableId: k,
|
|
72
|
-
approvalPolicyId: z?.approval_policy_id,
|
|
73
|
-
copy: F.approvalPolicyCopy
|
|
74
|
-
}), U = b({
|
|
75
|
-
payableId: k,
|
|
76
|
-
scheduledPaymentDate: z?.scheduled_payment_date
|
|
77
|
-
}), W = h({
|
|
78
|
-
payableId: k,
|
|
79
|
-
amountDueMinorUnits: d(z) ?? 0,
|
|
80
|
-
amountToPayMinorUnits: z?.amount_to_pay ?? void 0,
|
|
81
|
-
currencyCode: z?.currency ?? void 0,
|
|
82
|
-
dueDate: z?.due_date,
|
|
83
|
-
hasScheduledPayment: U.hasScheduledPayment,
|
|
84
|
-
testId: M,
|
|
85
|
-
labels: F.markAsPaid
|
|
86
|
-
}), { actions: G, decisionDialog: K } = y({
|
|
87
|
-
payableId: z ? k : void 0,
|
|
88
|
-
status: z?.status,
|
|
89
|
-
currentApprovalRequestId: V.id,
|
|
90
|
-
isPolicyApprover: V.isPolicyApprover,
|
|
91
|
-
hasWaitingRequest: V.hasWaitingRequest,
|
|
92
|
-
hasScheduledPayment: U.hasScheduledPayment,
|
|
93
|
-
scheduledPaymentIntentId: U.scheduledPaymentIntentId,
|
|
94
|
-
isScheduledPaymentUnknown: U.isResolving,
|
|
95
|
-
pendingApprovers: H.pendingApprovers,
|
|
96
|
-
arePendingApproversUnknown: H.isLoading,
|
|
97
|
-
labels: {
|
|
98
|
-
payBill: F.sheet.payButton,
|
|
99
|
-
markAsPaid: F.sheet.markAsPaidButton,
|
|
100
|
-
reject: F.sheet.rejectButton,
|
|
101
|
-
approve: F.sheet.approveButton,
|
|
102
|
-
cancel: F.sheet.cancelButton,
|
|
103
|
-
cancelScheduledPayment: F.sheet.cancelScheduledPaymentButton,
|
|
104
|
-
reopen: F.sheet.reopenButton,
|
|
105
|
-
forceApprove: F.sheet.forceApproveButton,
|
|
106
|
-
forceReject: F.sheet.forceRejectButton,
|
|
107
|
-
policyOverridesHeading: F.sheet.policyOverridesGroup,
|
|
108
|
-
decisionDialog: F.decisionDialog,
|
|
109
|
-
actionError: F.actionError,
|
|
110
|
-
actionSuccess: F.actionSuccess
|
|
111
|
-
},
|
|
112
|
-
isMarkAsPaidPending: W.isPending,
|
|
113
|
-
onMarkAsPaidSelect: W.open,
|
|
114
|
-
onPayBillSelect: () => B.current?.open()
|
|
115
|
-
}), q = U.hasScheduledPayment && U.scheduledDateLabel ? /* @__PURE__ */ T("p", {
|
|
116
|
-
className: "ttw:text-sm ttw:text-muted-foreground",
|
|
117
|
-
children: F.scheduledSummary(U.scheduledDateLabel)
|
|
118
|
-
}) : void 0, { initResponse: J } = r(), Y = u({
|
|
119
|
-
payable: z,
|
|
120
|
-
canManage: e(J?.scopes, [t.PayableWriteOrg])
|
|
121
|
-
}), X = Y.isPossibleDuplicate ? /* @__PURE__ */ T(c, {
|
|
122
|
-
onNotADuplicate: Y.onNotADuplicate,
|
|
123
|
-
isActionDisabled: Y.isBusy
|
|
124
|
-
}) : void 0, Z = X || q ? /* @__PURE__ */ E(w, { children: [X, q] }) : void 0, Q = S(() => z ? p({
|
|
125
|
-
payable: z,
|
|
126
|
-
lineItems: L.lineItems,
|
|
127
|
-
ledgerAccounts: R.data?.data ?? [],
|
|
128
|
-
labels: F,
|
|
129
|
-
hasScheduledPayment: U.hasScheduledPayment
|
|
130
|
-
}) : void 0, [
|
|
131
|
-
z,
|
|
132
|
-
L.lineItems,
|
|
133
|
-
R.data,
|
|
134
|
-
F,
|
|
135
|
-
U.hasScheduledPayment
|
|
136
|
-
]), $ = I.isLoading || L.isResolving || R.isResolving, ee = I.isError || L.isError || R.isError;
|
|
137
|
-
return /* @__PURE__ */ E(w, { children: [
|
|
138
|
-
/* @__PURE__ */ T(s, {
|
|
139
|
-
open: D,
|
|
140
|
-
onOpenChange: O,
|
|
141
|
-
details: Q,
|
|
142
|
-
actions: G,
|
|
143
|
-
approvalPolicy: H.view,
|
|
144
|
-
isLoading: $,
|
|
145
|
-
isError: ee,
|
|
146
|
-
notice: Z,
|
|
147
|
-
onClose: A,
|
|
148
|
-
onExpand: j,
|
|
149
|
-
testId: M,
|
|
150
|
-
labels: F.sheet
|
|
151
|
-
}),
|
|
152
|
-
/* @__PURE__ */ T(o, {
|
|
153
|
-
...K,
|
|
154
|
-
labels: { cancelButton: F.decisionDialog.cancelButton },
|
|
155
|
-
testId: M ? `${M}-decision-dialog` : void 0,
|
|
156
|
-
confirmTestId: M ? `${M}-decision-confirm` : void 0,
|
|
157
|
-
reasonTestId: M ? `${M}-decision-reason` : void 0,
|
|
158
|
-
reasonFieldId: M ? `${M}-decision-reason-field` : void 0
|
|
159
|
-
}),
|
|
160
|
-
/* @__PURE__ */ T(l, { ...W.dialogProps }),
|
|
161
|
-
z ? /* @__PURE__ */ T(f, {
|
|
162
|
-
ref: B,
|
|
163
|
-
payable: z,
|
|
164
|
-
onMissingAchInstructions: j,
|
|
165
|
-
poweredByBankName: P
|
|
166
|
-
}) : null
|
|
167
|
-
] });
|
|
168
|
-
}
|
|
8
|
+
var o = {
|
|
9
|
+
subtitle: "Accounts payable",
|
|
10
|
+
vendorRow: "Vendor",
|
|
11
|
+
bankAccountRow: "ACH bank account",
|
|
12
|
+
bankAccountValue: (e) => `Account ending in ${e}`,
|
|
13
|
+
...i,
|
|
14
|
+
invoiceNumberRow: "Number",
|
|
15
|
+
issueDateRow: "Issue date",
|
|
16
|
+
dueDateRow: "Due date",
|
|
17
|
+
poNumberRow: "PO number",
|
|
18
|
+
notProvided: "Not provided",
|
|
19
|
+
glCodeMissing: "GL code not specified",
|
|
20
|
+
quantityValue: (e, t) => `${e} x ${t}`,
|
|
21
|
+
subtotalRow: "Subtotal",
|
|
22
|
+
discountsRow: "Discounts",
|
|
23
|
+
taxRow: "Tax",
|
|
24
|
+
totalRow: "Total",
|
|
25
|
+
actionError: r.actionError,
|
|
26
|
+
actionSuccess: r.actionSuccess,
|
|
27
|
+
scheduledSummary: a,
|
|
28
|
+
paidOnLabel: (e) => `Paid on ${e}`,
|
|
29
|
+
sheet: e,
|
|
30
|
+
decisionDialog: r.decisionDialog,
|
|
31
|
+
approvalPolicyCopy: n,
|
|
32
|
+
markAsPaid: t
|
|
33
|
+
};
|
|
169
34
|
//#endregion
|
|
170
|
-
export {
|
|
35
|
+
export { o as BILL_DETAILS_LABELS_EN };
|