@tesouro/embedded-components-react 0.4.11 → 0.4.13
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/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index23.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index39.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index42.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index43.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index55.js +127 -122
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index57.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index58.js +4 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index67.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index71.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index75.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index77.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index80.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index9.js +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index.js +42 -41
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index100.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 +46 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index24.js +296 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index25.js +1 -50
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index26.js +7 -300
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index27.js +49 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index28.js +2 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index29.js +14 -45
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index30.js +50 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index31.js +2 -23
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index32.js +21 -338
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index33.js +340 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index34.js +2 -16
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index35.js +13 -117
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index36.js +120 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index37.js +2 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index38.js +10 -97
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index39.js +99 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index40.js +1 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index41.js +11 -57
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index42.js +58 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index43.js +1 -54
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index44.js +52 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index45.js +10 -157
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index46.js +181 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index47.js +2 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index48.js +2 -39
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index49.js +41 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index50.js +2 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index51.js +5 -90
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index52.js +92 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index53.js +2 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index54.js +2 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index55.js +16 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index56.js +1 -85
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index57.js +83 -284
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index58.js +283 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index59.js +13 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index60.js +1 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index61.js +6 -37
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index62.js +39 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index63.js +2 -39
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index64.js +36 -9
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index65.js +10 -199
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index66.js +201 -3
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index67.js +3 -17
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index68.js +15 -345
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index69.js +345 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index70.js +6 -4
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index71.js +6 -91
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index72.js +93 -0
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index74.js +2 -127
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index75.js +125 -26
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index76.js +26 -87
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index77.js +89 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index78.js +2 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index79.js +5 -28
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index80.js +30 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index81.js +2 -7
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index82.js +5 -32
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index83.js +34 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index84.js +2 -12
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index85.js +10 -104
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index86.js +105 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index87.js +2 -17
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index88.js +15 -123
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index89.js +125 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index90.js +2 -18
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index91.js +14 -6
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index92.js +7 -167
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index93.js +170 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index94.js +2 -14
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index95.js +11 -105
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index96.js +108 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index97.js +2 -10
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index98.js +8 -50
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index99.js +52 -2
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/zod.gen.js +871 -862
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/package.json +1 -1
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/ui/dist/index73.js +0 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MARK_AS_PAID_DIALOG_LABELS_EN as e } from "../../ui/dist/
|
|
1
|
+
import { MARK_AS_PAID_DIALOG_LABELS_EN as e } from "../../ui/dist/index88.js";
|
|
2
2
|
import "../../ui/dist/index.js";
|
|
3
3
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index12.js
|
|
4
4
|
var t = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as e } from "../../ui/dist/
|
|
2
|
-
import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as t } from "../../ui/dist/
|
|
1
|
+
import { REVIEW_TRANSACTION_DIALOG_LABELS_EN as e } from "../../ui/dist/index85.js";
|
|
2
|
+
import { SCHEDULE_PAYMENT_DIALOG_LABELS_EN as t } from "../../ui/dist/index91.js";
|
|
3
3
|
import "../../ui/dist/index.js";
|
|
4
4
|
import { SOURCE_ACCOUNT_LABELS_EN as n } from "./index20.js";
|
|
5
5
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index21.js
|
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
import { useWidgetConfig as e } from "../../../shared/feature/dist/lib/WidgetProvider/hooks.js";
|
|
6
6
|
import "../../../shared/feature/dist/index.js";
|
|
7
7
|
import { resolveVendor as t } from "./index5.js";
|
|
8
|
-
import { ReviewTransactionDialog as n } from "../../ui/dist/
|
|
9
|
-
import { SchedulePaymentDialog as r } from "../../ui/dist/
|
|
8
|
+
import { ReviewTransactionDialog as n } from "../../ui/dist/index86.js";
|
|
9
|
+
import { SchedulePaymentDialog as r } from "../../ui/dist/index93.js";
|
|
10
10
|
import "../../ui/dist/index.js";
|
|
11
11
|
import { canReadCounterpartBankAccounts as i } from "./index16.js";
|
|
12
12
|
import { resolveAmountDueMinorUnits as a } from "./index17.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { derivePayableStatus as e } from "./index4.js";
|
|
2
|
-
import { BILL_STATUS_BADGE_LABELS_EN as t } from "../../ui/dist/
|
|
2
|
+
import { BILL_STATUS_BADGE_LABELS_EN as t } from "../../ui/dist/index16.js";
|
|
3
3
|
import "../../ui/dist/index.js";
|
|
4
4
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index39.js
|
|
5
5
|
var n = /* @__PURE__ */ new Set([
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { UNSAVED_BILL_DIALOG_LABELS_EN as e } from "../../ui/dist/
|
|
1
|
+
import { UNSAVED_BILL_DIALOG_LABELS_EN as e } from "../../ui/dist/index98.js";
|
|
2
2
|
import "../../ui/dist/index.js";
|
|
3
3
|
import { PAY_BILL_FLOW_LABELS_EN as t, mergePayBillFlowLabels as n } from "./index21.js";
|
|
4
4
|
import { MARK_AS_PAID_FLOW_LABELS_EN as r, mergeMarkAsPaidFlowLabels as i } from "./index12.js";
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"use client";
|
|
5
5
|
import { useAttachPayableFileMutation as e } from "../../data-access/dist/index13.js";
|
|
6
6
|
import "../../data-access/dist/index.js";
|
|
7
|
-
import { SourceDocumentPanel as t } from "../../ui/dist/
|
|
7
|
+
import { SourceDocumentPanel as t } from "../../ui/dist/index96.js";
|
|
8
8
|
import "../../ui/dist/index.js";
|
|
9
9
|
import { createSourceDocumentPreview as n } from "./index41.js";
|
|
10
10
|
import { SOURCE_DOCUMENT_CONTAINER_LABELS_EN as r } from "./index42.js";
|
|
@@ -15,12 +15,12 @@ import { useAllPayableLineItemsQuery as ae } from "../../data-access/dist/index1
|
|
|
15
15
|
import { usePayableQuery as oe } from "../../data-access/dist/index15.js";
|
|
16
16
|
import "../../data-access/dist/index.js";
|
|
17
17
|
import { resolveVendor as se } from "./index5.js";
|
|
18
|
-
import { BillCreateScreen as ce } from "../../ui/dist/
|
|
19
|
-
import { BillDecisionDialog as n } from "../../ui/dist/
|
|
20
|
-
import { BillDuplicateNotice as le } from "../../ui/dist/
|
|
21
|
-
import { ExtractionNotice as ue } from "../../ui/dist/
|
|
22
|
-
import { MarkAsPaidDialog as de } from "../../ui/dist/
|
|
23
|
-
import { UnsavedBillDialog as fe } from "../../ui/dist/
|
|
18
|
+
import { BillCreateScreen as ce } from "../../ui/dist/index46.js";
|
|
19
|
+
import { BillDecisionDialog as n } from "../../ui/dist/index52.js";
|
|
20
|
+
import { BillDuplicateNotice as le } from "../../ui/dist/index62.js";
|
|
21
|
+
import { ExtractionNotice as ue } from "../../ui/dist/index80.js";
|
|
22
|
+
import { MarkAsPaidDialog as de } from "../../ui/dist/index89.js";
|
|
23
|
+
import { UnsavedBillDialog as fe } from "../../ui/dist/index99.js";
|
|
24
24
|
import "../../ui/dist/index.js";
|
|
25
25
|
import { usePayableDuplicateReview as pe } from "./index10.js";
|
|
26
26
|
import "./index11.js";
|
|
@@ -45,175 +45,180 @@ import { useVendorSectionProps as Ae } from "./index46.js";
|
|
|
45
45
|
import { usePaymentInstructionsForm as je } from "./index47.js";
|
|
46
46
|
import { billCreateTestIds as r } from "./index54.js";
|
|
47
47
|
import { useCallback as i, useEffect as Me, useMemo as a, useRef as Ne, useState as o } from "react";
|
|
48
|
-
import { Fragment as
|
|
49
|
-
import { Trash2Icon as
|
|
48
|
+
import { Fragment as s, jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
49
|
+
import { Trash2Icon as Pe } from "lucide-react";
|
|
50
50
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index55.js
|
|
51
|
-
function
|
|
52
|
-
let
|
|
51
|
+
function u({ open: u, onOpenChange: d, payableId: Fe, readOnly: f = !1, copy: p, onCollapse: Ie, poweredByBankName: Le }) {
|
|
52
|
+
let m = a(() => ve(p), [p]), [h, Re] = o(), [g, _] = o(!1), [ze, Be] = o(!1), [Ve, v] = o(!1), [He, y] = o(), b = Fe ?? He, 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 = !f && O && !!b && D?.status !== "draft", Ue = !f && !!D && !Te(D?.status), A = f || Ue, j = be({
|
|
53
53
|
payable: D,
|
|
54
54
|
lineItems: S.lineItems
|
|
55
55
|
}), M = D?.counterpart_id;
|
|
56
56
|
Me(() => {
|
|
57
|
-
g || M && (
|
|
57
|
+
g || M && (Re(M), _(!0));
|
|
58
58
|
}, [g, M]);
|
|
59
59
|
let We = i((e) => {
|
|
60
|
-
_(!0),
|
|
60
|
+
_(!0), Re(e);
|
|
61
61
|
}, []), N = Ae({
|
|
62
|
-
payableId:
|
|
63
|
-
counterpartId:
|
|
62
|
+
payableId: f ? void 0 : b,
|
|
63
|
+
counterpartId: f ? void 0 : h,
|
|
64
64
|
payableCounterpartId: M,
|
|
65
65
|
onCounterpartChange: We,
|
|
66
66
|
requiredError: j.errors?.vendor,
|
|
67
67
|
payableCounterpartBankAccountId: D?.counterpart_bank_account_id ?? void 0,
|
|
68
68
|
extractedVendor: D?.counterpart_raw_data ?? void 0
|
|
69
|
-
}), Ge = !!(b && g) && !
|
|
69
|
+
}), Ge = !!(b && g) && !h, Ke = a(() => k ? { saveDraftButton: m.submittedSaveButton } : void 0, [m.submittedSaveButton, k]), qe = a(() => k ? { draftSaved: _e.submittedSaved } : void 0, [k]), P = x.refetch, Je = i(async () => {
|
|
70
70
|
let { data: e } = await P();
|
|
71
71
|
return e?.status ?? void 0;
|
|
72
72
|
}, [P]), F = ye({
|
|
73
|
-
payableId:
|
|
73
|
+
payableId: Fe,
|
|
74
74
|
form: j,
|
|
75
75
|
labels: qe,
|
|
76
|
-
counterpartId:
|
|
76
|
+
counterpartId: h,
|
|
77
77
|
clearCounterpart: Ge,
|
|
78
78
|
prepareVendorForSave: N.savePaymentInstructions,
|
|
79
79
|
onPayableCreated: y,
|
|
80
80
|
onSaved: y,
|
|
81
|
-
onDraftSaved: () =>
|
|
82
|
-
onFinalized: () =>
|
|
81
|
+
onDraftSaved: () => d(!1),
|
|
82
|
+
onFinalized: () => d(!1),
|
|
83
83
|
readSavedStatus: k ? Je : void 0
|
|
84
|
-
}),
|
|
85
|
-
payableId:
|
|
84
|
+
}), Ye = !!(F.isSavingDraft || F.isFinalizing), I = f ? b : void 0, L = Se({
|
|
85
|
+
payableId: I,
|
|
86
86
|
status: D?.status
|
|
87
|
-
}),
|
|
87
|
+
}), R = Ne(null), z = we({
|
|
88
88
|
payableId: b,
|
|
89
89
|
scheduledPaymentDate: D?.scheduled_payment_date,
|
|
90
|
-
enabled:
|
|
90
|
+
enabled: f || k
|
|
91
91
|
}), Xe = se(D), B = je({
|
|
92
|
-
payableId:
|
|
93
|
-
counterpartId:
|
|
94
|
-
saveErrorMessage:
|
|
95
|
-
linkErrorMessage:
|
|
92
|
+
payableId: I,
|
|
93
|
+
counterpartId: f ? M : void 0,
|
|
94
|
+
saveErrorMessage: m.detail.paymentInstructionsSaveError,
|
|
95
|
+
linkErrorMessage: m.detail.paymentInstructionsLinkError
|
|
96
96
|
}), Ze = e(C?.scopes, [t.PayableWriteOrg]), Qe = e(C?.scopes, [t.CounterpartWriteOrg]) && Ze, V = ge({
|
|
97
|
-
payableId:
|
|
97
|
+
payableId: I,
|
|
98
98
|
amountDueMinorUnits: me(D) ?? 0,
|
|
99
99
|
amountToPayMinorUnits: D?.amount_to_pay ?? void 0,
|
|
100
100
|
currencyCode: D?.currency ?? void 0,
|
|
101
101
|
dueDate: D?.due_date,
|
|
102
102
|
hasScheduledPayment: z.hasScheduledPayment,
|
|
103
|
-
labels:
|
|
103
|
+
labels: m.markAsPaid
|
|
104
104
|
}), H = xe({
|
|
105
|
-
payableId:
|
|
105
|
+
payableId: I,
|
|
106
106
|
approvalPolicyId: D?.approval_policy_id,
|
|
107
|
-
enabled:
|
|
108
|
-
copy:
|
|
107
|
+
enabled: f,
|
|
108
|
+
copy: m.approvalPolicyCopy
|
|
109
109
|
}), { actions: U, decisionDialog: $e, isActionPending: et } = Ce({
|
|
110
|
-
payableId:
|
|
110
|
+
payableId: f || k ? b : void 0,
|
|
111
111
|
status: D?.status,
|
|
112
|
-
currentApprovalRequestId:
|
|
113
|
-
isPolicyApprover:
|
|
114
|
-
hasWaitingRequest:
|
|
112
|
+
currentApprovalRequestId: L.id,
|
|
113
|
+
isPolicyApprover: L.isPolicyApprover,
|
|
114
|
+
hasWaitingRequest: L.hasWaitingRequest,
|
|
115
115
|
arePendingApproversUnknown: H.isLoading,
|
|
116
116
|
hasScheduledPayment: z.hasScheduledPayment,
|
|
117
117
|
scheduledPaymentIntentId: z.scheduledPaymentIntentId,
|
|
118
118
|
isScheduledPaymentUnknown: z.isResolving,
|
|
119
119
|
pendingApprovers: H.pendingApprovers,
|
|
120
|
-
labels:
|
|
120
|
+
labels: m.actions,
|
|
121
121
|
isMarkAsPaidPending: V.isPending,
|
|
122
122
|
onMarkAsPaidSelect: V.open,
|
|
123
|
-
onPayBillSelect: () =>
|
|
124
|
-
onActionSucceeded: k ? () =>
|
|
123
|
+
onPayBillSelect: () => R.current?.open(),
|
|
124
|
+
onActionSucceeded: k ? () => d(!1) : void 0
|
|
125
125
|
}), W = Ee({
|
|
126
126
|
payableId: b,
|
|
127
127
|
status: D?.status,
|
|
128
|
-
enabled: !
|
|
129
|
-
labels:
|
|
130
|
-
onDeleted: () =>
|
|
131
|
-
}), G =
|
|
128
|
+
enabled: !f,
|
|
129
|
+
labels: m.deleteDraft,
|
|
130
|
+
onDeleted: () => d(!1)
|
|
131
|
+
}), G = Ye || et, K = x.isLoading || S.isResolving || E.isResolving, q = x.isError || S.isError || E.isError, tt = a(() => [...W.menuItems, ...k || f && !K && !q ? U.menu.map((e) => ({
|
|
132
132
|
id: e.id,
|
|
133
133
|
label: e.label,
|
|
134
134
|
onSelect: e.onSelect,
|
|
135
|
-
disabled: e.disabled
|
|
135
|
+
disabled: e.disabled,
|
|
136
|
+
icon: e.icon,
|
|
137
|
+
sectionHeading: e.sectionHeading
|
|
136
138
|
})) : []], [
|
|
137
139
|
U.menu,
|
|
138
140
|
W.menuItems,
|
|
139
|
-
k
|
|
140
|
-
|
|
141
|
+
k,
|
|
142
|
+
f,
|
|
143
|
+
K,
|
|
144
|
+
q
|
|
145
|
+
]), J = a(() => (E.data?.data ?? []).map((e) => ({
|
|
141
146
|
value: e.id,
|
|
142
147
|
label: [e.nominal_code, e.name].filter(Boolean).join(" — ")
|
|
143
|
-
})), [E.data]),
|
|
144
|
-
w && (T ? E.isError ?
|
|
145
|
-
let nt = !w || !!
|
|
148
|
+
})), [E.data]), Y;
|
|
149
|
+
w && (T ? E.isError ? Y = m.lineItemsGlCodeUnavailable.loadError : !E.isResolving && J.length === 0 && (Y = m.lineItemsGlCodeUnavailable.empty) : Y = m.lineItemsGlCodeUnavailable.noAccess);
|
|
150
|
+
let nt = !w || !!Y || E.isResolving, rt = T && !E.isResolving && !E.isError, it = ie(I), at = e(C?.scopes, [t.UserReadOrg]), ot = te({ enabled: f && at }), st = a(() => Oe(it.data?.data ?? [], ot.data?.data ?? [], m.history), [
|
|
146
151
|
it.data,
|
|
147
152
|
ot.data,
|
|
148
|
-
|
|
149
|
-
]),
|
|
153
|
+
m.history
|
|
154
|
+
]), ct = a(() => f && D ? De({
|
|
150
155
|
payable: D,
|
|
151
156
|
lineItems: S.lineItems,
|
|
152
|
-
glCodeOptions:
|
|
157
|
+
glCodeOptions: J,
|
|
153
158
|
glCodeRosterAvailable: rt,
|
|
154
|
-
history:
|
|
159
|
+
history: st,
|
|
155
160
|
approvalPolicy: H.view,
|
|
156
|
-
labels:
|
|
161
|
+
labels: m.detail,
|
|
157
162
|
hasScheduledPayment: z.hasScheduledPayment
|
|
158
163
|
}) : void 0, [
|
|
159
164
|
z.hasScheduledPayment,
|
|
160
165
|
H.view,
|
|
161
|
-
|
|
162
|
-
K,
|
|
163
|
-
rt,
|
|
166
|
+
m.detail,
|
|
164
167
|
J,
|
|
168
|
+
rt,
|
|
169
|
+
st,
|
|
165
170
|
S.lineItems,
|
|
166
171
|
D,
|
|
167
|
-
|
|
168
|
-
]),
|
|
172
|
+
f
|
|
173
|
+
]), lt = D?.source_of_payable_data === "ocr", X = Xe?.name, ut = f ? X ? m.viewTitle(X) : m.readOnlyTitle : X && (lt || k) ? m.extractedTitle(X) : m.newTitle, dt = f && D?.created_at ? m.addedOn(ne(D.created_at.slice(0, 10))) : void 0, Z = i(() => {
|
|
169
174
|
let e = j.isDirty || N.hasUnsavedVendorChanges || !!F.stagedFile || F.isFileDeletionPending;
|
|
170
175
|
if (!A && e) {
|
|
171
176
|
v(!0);
|
|
172
177
|
return;
|
|
173
178
|
}
|
|
174
|
-
|
|
179
|
+
d(!1);
|
|
175
180
|
}, [
|
|
176
181
|
F.isFileDeletionPending,
|
|
177
182
|
F.stagedFile,
|
|
178
183
|
j.isDirty,
|
|
179
184
|
A,
|
|
180
|
-
|
|
185
|
+
d,
|
|
181
186
|
N.hasUnsavedVendorChanges
|
|
182
|
-
]),
|
|
183
|
-
v(!1),
|
|
184
|
-
}, [
|
|
185
|
-
if (
|
|
187
|
+
]), ft = i(() => {
|
|
188
|
+
v(!1), d(!1);
|
|
189
|
+
}, [d]), Q = S.isResolving || N.mode === "creating", pt = i(async () => {
|
|
190
|
+
if (Q) return;
|
|
186
191
|
let e = await F.saveDraft();
|
|
187
|
-
v(!1), e &&
|
|
192
|
+
v(!1), e && d(!1);
|
|
188
193
|
}, [
|
|
189
194
|
F,
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
]),
|
|
195
|
+
Q,
|
|
196
|
+
d
|
|
197
|
+
]), $ = pe({
|
|
193
198
|
payable: D,
|
|
194
|
-
onRemoved: () =>
|
|
199
|
+
onRemoved: () => d(!1),
|
|
195
200
|
canManage: Ze
|
|
196
|
-
}),
|
|
197
|
-
if (!(G ||
|
|
201
|
+
}), mt = i((e) => {
|
|
202
|
+
if (!(G || $.isBusy)) return e ? d(!0) : Z();
|
|
198
203
|
}, [
|
|
199
|
-
|
|
204
|
+
$.isBusy,
|
|
200
205
|
G,
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
]),
|
|
204
|
-
onNotADuplicate:
|
|
205
|
-
onRemoveBill:
|
|
206
|
-
isActionDisabled:
|
|
207
|
-
labels:
|
|
206
|
+
Z,
|
|
207
|
+
d
|
|
208
|
+
]), ht = $.isPossibleDuplicate, gt = !f && lt && !ze, _t = ht || gt ? /* @__PURE__ */ l(s, { children: [ht ? /* @__PURE__ */ c(le, {
|
|
209
|
+
onNotADuplicate: $.onNotADuplicate,
|
|
210
|
+
onRemoveBill: $.onRemoveBill,
|
|
211
|
+
isActionDisabled: $.isBusy,
|
|
212
|
+
labels: $.removeBillLabel ? { removeBillButton: $.removeBillLabel } : void 0,
|
|
208
213
|
testId: r.duplicateNotice
|
|
209
|
-
}) : null,
|
|
210
|
-
return /* @__PURE__ */
|
|
211
|
-
/* @__PURE__ */
|
|
212
|
-
open:
|
|
213
|
-
onOpenChange:
|
|
214
|
-
title:
|
|
215
|
-
subtitle:
|
|
216
|
-
notice:
|
|
214
|
+
}) : null, gt ? /* @__PURE__ */ c(ue, { onDismiss: () => Be(!0) }) : null] }) : void 0;
|
|
215
|
+
return /* @__PURE__ */ l(s, { children: [
|
|
216
|
+
/* @__PURE__ */ c(ce, {
|
|
217
|
+
open: u,
|
|
218
|
+
onOpenChange: mt,
|
|
219
|
+
title: ut,
|
|
220
|
+
subtitle: dt,
|
|
221
|
+
notice: _t,
|
|
217
222
|
vendor: {
|
|
218
223
|
...N,
|
|
219
224
|
testId: r.vendorSection
|
|
@@ -223,9 +228,9 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
223
228
|
onChange: j.onChange,
|
|
224
229
|
lineItems: {
|
|
225
230
|
items: j.lineItemRows,
|
|
226
|
-
glCodeOptions:
|
|
231
|
+
glCodeOptions: J,
|
|
227
232
|
glCodeDisabled: nt,
|
|
228
|
-
glCodeUnavailableMessage:
|
|
233
|
+
glCodeUnavailableMessage: Y,
|
|
229
234
|
discount: j.discount,
|
|
230
235
|
onDiscountChange: j.onDiscountChange,
|
|
231
236
|
tax: j.tax,
|
|
@@ -237,7 +242,7 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
237
242
|
totalsErrors: j.totalsErrors,
|
|
238
243
|
testId: r.lineItems
|
|
239
244
|
},
|
|
240
|
-
documentPanel: /* @__PURE__ */
|
|
245
|
+
documentPanel: /* @__PURE__ */ c(ke, {
|
|
241
246
|
payableId: b,
|
|
242
247
|
readOnly: A,
|
|
243
248
|
isDocumentPending: !!b && !D?.file && (x.isLoading || D?.ocr_status === "processing"),
|
|
@@ -251,7 +256,7 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
251
256
|
stagedFile: F.stagedFile,
|
|
252
257
|
onFileStaged: F.stageFile,
|
|
253
258
|
onClearStagedFile: F.clearStagedFile,
|
|
254
|
-
isSaving:
|
|
259
|
+
isSaving: Ye
|
|
255
260
|
},
|
|
256
261
|
deletion: {
|
|
257
262
|
isPending: F.isFileDeletionPending,
|
|
@@ -263,10 +268,10 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
263
268
|
}),
|
|
264
269
|
menuItems: tt,
|
|
265
270
|
readOnly: A,
|
|
266
|
-
detail:
|
|
267
|
-
view:
|
|
271
|
+
detail: f ? {
|
|
272
|
+
view: ct,
|
|
268
273
|
actions: U,
|
|
269
|
-
scheduledSummary: z.hasScheduledPayment && z.scheduledDateLabel ?
|
|
274
|
+
scheduledSummary: z.hasScheduledPayment && z.scheduledDateLabel ? m.scheduledSummary(z.scheduledDateLabel) : void 0,
|
|
270
275
|
paymentInstructionsForm: M && Qe ? {
|
|
271
276
|
isOpen: B.isOpen,
|
|
272
277
|
values: B.values,
|
|
@@ -277,15 +282,15 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
277
282
|
onChange: B.onChange,
|
|
278
283
|
onSave: B.save
|
|
279
284
|
} : void 0,
|
|
280
|
-
isLoading:
|
|
281
|
-
isError:
|
|
285
|
+
isLoading: K,
|
|
286
|
+
isError: q
|
|
282
287
|
} : void 0,
|
|
283
288
|
isLineItemsLoading: S.isResolving,
|
|
284
289
|
isSaving: G,
|
|
285
290
|
isSavingDraft: F.isSavingDraft,
|
|
286
291
|
isFinalizing: F.isFinalizing,
|
|
287
|
-
onCancel:
|
|
288
|
-
onCollapse:
|
|
292
|
+
onCancel: Z,
|
|
293
|
+
onCollapse: f ? Ie : void 0,
|
|
289
294
|
onSaveDraft: F.saveDraft,
|
|
290
295
|
onFinalize: F.finalize,
|
|
291
296
|
scrollToErrorToken: F.scrollToErrorToken,
|
|
@@ -293,52 +298,52 @@ function c({ open: c, onOpenChange: l, payableId: u, readOnly: d = !1, copy: f,
|
|
|
293
298
|
labels: Ke,
|
|
294
299
|
testId: r.dialog
|
|
295
300
|
}),
|
|
296
|
-
/* @__PURE__ */
|
|
301
|
+
/* @__PURE__ */ c(fe, {
|
|
297
302
|
open: Ve,
|
|
298
|
-
onSaveDraft:
|
|
299
|
-
onDiscard:
|
|
303
|
+
onSaveDraft: pt,
|
|
304
|
+
onDiscard: ft,
|
|
300
305
|
onCancel: () => v(!1),
|
|
301
306
|
isSaving: F.isSavingDraft,
|
|
302
|
-
isSaveDraftDisabled:
|
|
303
|
-
labels:
|
|
307
|
+
isSaveDraftDisabled: Q,
|
|
308
|
+
labels: m.unsavedChanges,
|
|
304
309
|
testId: r.unsavedDialog,
|
|
305
310
|
saveDraftTestId: r.unsavedSaveDraft,
|
|
306
311
|
discardTestId: r.unsavedDiscard,
|
|
307
312
|
closeTestId: r.unsavedClose
|
|
308
313
|
}),
|
|
309
|
-
/* @__PURE__ */
|
|
314
|
+
/* @__PURE__ */ c(n, {
|
|
310
315
|
...$e,
|
|
311
|
-
labels: { cancelButton:
|
|
316
|
+
labels: { cancelButton: m.actions.decisionDialog.cancelButton },
|
|
312
317
|
testId: r.decisionDialog,
|
|
313
318
|
confirmTestId: r.decisionConfirm,
|
|
314
319
|
reasonTestId: r.decisionReason
|
|
315
320
|
}),
|
|
316
|
-
/* @__PURE__ */
|
|
321
|
+
/* @__PURE__ */ c(n, {
|
|
317
322
|
...W.dialog,
|
|
318
|
-
labels: { cancelButton:
|
|
323
|
+
labels: { cancelButton: m.actions.decisionDialog.cancelButton },
|
|
319
324
|
testId: r.deleteDraftDialog,
|
|
320
325
|
confirmTestId: r.deleteDraftConfirm
|
|
321
326
|
}),
|
|
322
|
-
/* @__PURE__ */
|
|
323
|
-
open:
|
|
324
|
-
copy:
|
|
325
|
-
onConfirm:
|
|
326
|
-
onCancel:
|
|
327
|
-
isPending:
|
|
328
|
-
confirmIcon: /* @__PURE__ */
|
|
329
|
-
labels: { cancelButton:
|
|
327
|
+
/* @__PURE__ */ c(n, {
|
|
328
|
+
open: $.removeConfirmation.open,
|
|
329
|
+
copy: $.removeConfirmation.copy,
|
|
330
|
+
onConfirm: $.removeConfirmation.onConfirm,
|
|
331
|
+
onCancel: $.removeConfirmation.onCancel,
|
|
332
|
+
isPending: $.removeConfirmation.isPending,
|
|
333
|
+
confirmIcon: /* @__PURE__ */ c(Pe, {}),
|
|
334
|
+
labels: { cancelButton: $.removeConfirmation.cancelButtonLabel },
|
|
330
335
|
testId: r.duplicateRemoveDialog,
|
|
331
336
|
confirmTestId: r.duplicateRemoveConfirm
|
|
332
337
|
}),
|
|
333
|
-
/* @__PURE__ */
|
|
334
|
-
|
|
335
|
-
ref:
|
|
338
|
+
/* @__PURE__ */ c(de, { ...V.dialogProps }),
|
|
339
|
+
f && D ? /* @__PURE__ */ c(he, {
|
|
340
|
+
ref: R,
|
|
336
341
|
payable: D,
|
|
337
342
|
onMissingAchInstructions: Qe ? B.open : void 0,
|
|
338
|
-
poweredByBankName:
|
|
339
|
-
labels:
|
|
343
|
+
poweredByBankName: Le,
|
|
344
|
+
labels: m.payBill
|
|
340
345
|
}) : null
|
|
341
346
|
] });
|
|
342
347
|
}
|
|
343
348
|
//#endregion
|
|
344
|
-
export {
|
|
349
|
+
export { u as BillCreateDialog, u as default };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BILL_DETAILS_SHEET_LABELS_EN as e } from "../../ui/dist/
|
|
1
|
+
import { BILL_DETAILS_SHEET_LABELS_EN as e } from "../../ui/dist/index57.js";
|
|
2
2
|
import "../../ui/dist/index.js";
|
|
3
3
|
import { MARK_AS_PAID_FLOW_LABELS_EN as t } from "./index12.js";
|
|
4
4
|
import "./index15.js";
|
|
@@ -11,10 +11,10 @@ import "../../../shared/feature/dist/index.js";
|
|
|
11
11
|
import { useAllPayableLineItemsQuery as i } from "../../data-access/dist/index10.js";
|
|
12
12
|
import { usePayableQuery as a } from "../../data-access/dist/index15.js";
|
|
13
13
|
import "../../data-access/dist/index.js";
|
|
14
|
-
import { BillDecisionDialog as o } from "../../ui/dist/
|
|
15
|
-
import { BillDetailsSheet as s } from "../../ui/dist/
|
|
16
|
-
import { BillDuplicateNotice as c } from "../../ui/dist/
|
|
17
|
-
import { MarkAsPaidDialog as l } from "../../ui/dist/
|
|
14
|
+
import { BillDecisionDialog as o } from "../../ui/dist/index52.js";
|
|
15
|
+
import { BillDetailsSheet as s } from "../../ui/dist/index58.js";
|
|
16
|
+
import { BillDuplicateNotice as c } from "../../ui/dist/index62.js";
|
|
17
|
+
import { MarkAsPaidDialog as l } from "../../ui/dist/index89.js";
|
|
18
18
|
import "../../ui/dist/index.js";
|
|
19
19
|
import { usePayableDuplicateReview as u } from "./index10.js";
|
|
20
20
|
import "./index11.js";
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"use client";
|
|
5
5
|
import { formatMoneyExact as e } from "../../../shared/util/dist/lib/formatMoneyExact.js";
|
|
6
6
|
import "../../data-access/dist/index.js";
|
|
7
|
-
import { BillsFilterField as t } from "../../ui/dist/
|
|
7
|
+
import { BillsFilterField as t } from "../../ui/dist/index65.js";
|
|
8
8
|
import "../../ui/dist/index.js";
|
|
9
9
|
import { getCounterpartName as n } from "../../../shared/counterpart-management/feature/dist/lib/helpers.js";
|
|
10
10
|
import { useCounterpartsQuery as r } from "../../../shared/counterpart-management/data-access/dist/index3.js";
|
|
@@ -11,7 +11,7 @@ import { useWidgetConfig as ee, useWidgetInitStaleForToken as r } from "../../..
|
|
|
11
11
|
import "../../../shared/feature/dist/index.js";
|
|
12
12
|
import { useDuplicateBillsCount as i } from "./index7.js";
|
|
13
13
|
import { AddBillDialog as a } from "../../ui/dist/index10.js";
|
|
14
|
-
import { BillsScreen as o } from "../../ui/dist/
|
|
14
|
+
import { BillsScreen as o } from "../../ui/dist/index69.js";
|
|
15
15
|
import "../../ui/dist/index.js";
|
|
16
16
|
import { DuplicateBillsContainer as te } from "./index9.js";
|
|
17
17
|
import "./index11.js";
|
|
@@ -11,8 +11,8 @@ import { useAnalyticsTrack as r } from "../../../shared/feature/dist/lib/analyti
|
|
|
11
11
|
import { WidgetProvider as i } from "../../../shared/feature/dist/lib/WidgetProvider/WidgetProvider.js";
|
|
12
12
|
import { useWidgetConfig as a } from "../../../shared/feature/dist/lib/WidgetProvider/hooks.js";
|
|
13
13
|
import "../../../shared/feature/dist/index.js";
|
|
14
|
-
import { BillPayWidgetUi as o } from "../../ui/dist/
|
|
15
|
-
import { BillUploadStatusTray as s } from "../../ui/dist/
|
|
14
|
+
import { BillPayWidgetUi as o } from "../../ui/dist/index49.js";
|
|
15
|
+
import { BillUploadStatusTray as s } from "../../ui/dist/index72.js";
|
|
16
16
|
import "../../ui/dist/index.js";
|
|
17
17
|
import { ApprovalPoliciesSettings as c } from "../../../shared/approval-policy/feature/dist/lib/ApprovalPoliciesSettings.js";
|
|
18
18
|
import "../../../shared/approval-policy/feature/dist/index.js";
|
|
@@ -9,7 +9,7 @@ import { DuplicateVerdict as n, useApplyDuplicateVerdictsMutation as r } from ".
|
|
|
9
9
|
import "../../data-access/dist/index.js";
|
|
10
10
|
import { useDuplicateBills as i } from "./index7.js";
|
|
11
11
|
import { useDuplicateBillsSelection as a } from "./index8.js";
|
|
12
|
-
import { DuplicateBillsDialog as o } from "../../ui/dist/
|
|
12
|
+
import { DuplicateBillsDialog as o } from "../../ui/dist/index77.js";
|
|
13
13
|
import "../../ui/dist/index.js";
|
|
14
14
|
import { useMemo as s, useState as c } from "react";
|
|
15
15
|
import { jsx as l } from "react/jsx-runtime";
|