@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,81 +1,92 @@
|
|
|
1
1
|
import { formatCalendarDate as e } from "../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
2
|
-
import { derivePayableStatus as t } from "./
|
|
3
|
-
import { resolveVendor as n } from "./
|
|
4
|
-
import {
|
|
5
|
-
import { formatBillMoney as i } from "./index36.js";
|
|
6
|
-
import { getPaidAtLabel as a } from "./index37.js";
|
|
2
|
+
import { derivePayableStatus as t } from "./index6.js";
|
|
3
|
+
import { resolveVendor as n, resolveVendorName as r } from "./index7.js";
|
|
4
|
+
import { formatBillMoney as i } from "./index2.js";
|
|
7
5
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index38.js
|
|
8
|
-
function
|
|
9
|
-
let
|
|
10
|
-
apiStatus:
|
|
11
|
-
dueDate:
|
|
12
|
-
scheduledPaymentDate:
|
|
13
|
-
hasScheduledPayment:
|
|
14
|
-
|
|
6
|
+
function a({ payable: a, lineItems: s, ledgerAccounts: c, labels: l, hasScheduledPayment: u, now: d }) {
|
|
7
|
+
let f = a.currency, p = (e) => i(e, f), m = t({
|
|
8
|
+
apiStatus: a.status,
|
|
9
|
+
dueDate: a.due_date,
|
|
10
|
+
scheduledPaymentDate: a.scheduled_payment_date,
|
|
11
|
+
hasScheduledPayment: u,
|
|
12
|
+
now: d
|
|
13
|
+
}), h = n(a), g = r(a), _ = e(a.issued_at) || l.notProvided, v = e(a.due_date) || l.notProvided, y = [{
|
|
14
|
+
label: l.vendorRow,
|
|
15
|
+
value: g || l.notProvided,
|
|
16
|
+
secondaryValue: h?.email ?? void 0
|
|
17
|
+
}], b = h?.bank_account?.account_number;
|
|
18
|
+
b && y.push({
|
|
19
|
+
label: l.bankAccountRow,
|
|
20
|
+
value: l.bankAccountValue(b.slice(-4))
|
|
21
|
+
});
|
|
22
|
+
let x = [
|
|
23
|
+
{
|
|
24
|
+
label: l.invoiceNumberRow,
|
|
25
|
+
value: a.document_id || l.notProvided
|
|
26
|
+
},
|
|
15
27
|
{
|
|
16
|
-
label:
|
|
17
|
-
|
|
28
|
+
label: l.issueDateRow,
|
|
29
|
+
value: _
|
|
18
30
|
},
|
|
19
31
|
{
|
|
20
|
-
label:
|
|
21
|
-
|
|
32
|
+
label: l.dueDateRow,
|
|
33
|
+
value: v
|
|
22
34
|
},
|
|
23
35
|
{
|
|
24
|
-
label:
|
|
25
|
-
|
|
36
|
+
label: l.poNumberRow,
|
|
37
|
+
value: l.notProvided
|
|
26
38
|
}
|
|
27
|
-
].map((e) => ({
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
39
|
+
], S = new Map(c.map((e) => [e.id, [e.nominal_code, e.name].filter(Boolean).join(" — ")])), C = s.map((e) => {
|
|
40
|
+
let t = p(e.unit_price);
|
|
41
|
+
return {
|
|
42
|
+
id: e.id,
|
|
43
|
+
description: e.name ?? e.description ?? "",
|
|
44
|
+
glCodeLabel: (e.ledger_account_id ? S.get(e.ledger_account_id) : void 0) || l.glCodeMissing,
|
|
45
|
+
quantityLabel: e.quantity != null && t ? l.quantityValue(String(e.quantity), t) : "",
|
|
46
|
+
amountLabel: p(e.subtotal) ?? ""
|
|
47
|
+
};
|
|
48
|
+
}), w = [
|
|
49
|
+
{
|
|
50
|
+
label: l.subtotalRow,
|
|
51
|
+
value: a.subtotal
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
label: l.discountsRow,
|
|
55
|
+
value: a.discount
|
|
56
|
+
},
|
|
57
|
+
{
|
|
58
|
+
label: l.taxRow,
|
|
59
|
+
value: a.tax_amount
|
|
60
|
+
}
|
|
61
|
+
].map(({ label: e, value: t }) => ({
|
|
62
|
+
label: e,
|
|
63
|
+
value: p(t)
|
|
64
|
+
})).filter((e) => !!e.value), T = p(a.total_amount);
|
|
65
|
+
T && w.push({
|
|
66
|
+
label: l.totalRow,
|
|
67
|
+
value: T,
|
|
34
68
|
emphasis: !0
|
|
35
69
|
});
|
|
36
|
-
let
|
|
70
|
+
let E = o(a);
|
|
37
71
|
return {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
{
|
|
53
|
-
label: f.invoiceDateRow,
|
|
54
|
-
value: v
|
|
55
|
-
},
|
|
56
|
-
{
|
|
57
|
-
label: f.dueDateRow,
|
|
58
|
-
value: y
|
|
59
|
-
},
|
|
60
|
-
{
|
|
61
|
-
label: f.invoiceNumberRow,
|
|
62
|
-
value: o.document_id || f.notProvided
|
|
63
|
-
}
|
|
64
|
-
],
|
|
65
|
-
lineItems: s.map((e) => {
|
|
66
|
-
let t = i(e.unit_price, m);
|
|
67
|
-
return {
|
|
68
|
-
id: e.id,
|
|
69
|
-
description: e.name ?? e.description ?? "",
|
|
70
|
-
glCodeLabel: e.ledger_account_id ? b.get(e.ledger_account_id) ?? (l ? f.glCodeMissing : f.glCodeUnavailable) : f.glCodeMissing,
|
|
71
|
-
qtyPriceLabel: e.quantity != null && t ? f.qtyPriceValue(String(e.quantity), t) : "",
|
|
72
|
-
amount: i(e.subtotal, m) ?? ""
|
|
73
|
-
};
|
|
74
|
-
}),
|
|
75
|
-
amountRows: x,
|
|
76
|
-
approvalPolicy: d,
|
|
77
|
-
history: u
|
|
72
|
+
title: g,
|
|
73
|
+
subtitle: l.subtitle,
|
|
74
|
+
status: m.status,
|
|
75
|
+
statusTone: m.tone,
|
|
76
|
+
amountDueLabel: p(a.amount_due) ?? p(a.total_amount) ?? "",
|
|
77
|
+
amountPaidLabel: E ? p(a.amount_paid) : void 0,
|
|
78
|
+
paidOnLabel: E ? l.paidOnLabel(E) : void 0,
|
|
79
|
+
invoiceDateLabel: _,
|
|
80
|
+
dueDateLabel: v,
|
|
81
|
+
dueDateTone: m.isOverdue ? "danger" : "default",
|
|
82
|
+
payToItems: y,
|
|
83
|
+
invoiceItems: x,
|
|
84
|
+
lineItems: C,
|
|
85
|
+
totals: w
|
|
78
86
|
};
|
|
79
87
|
}
|
|
88
|
+
function o(t) {
|
|
89
|
+
return t.status === "paid" && t.paid_at ? e(t.paid_at.slice(0, 10)) : void 0;
|
|
90
|
+
}
|
|
80
91
|
//#endregion
|
|
81
|
-
export { o as
|
|
92
|
+
export { o as getPaidAtLabel, a as mapPayableToBillDetails };
|
|
@@ -1,52 +1,82 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import "
|
|
1
|
+
import { formatCalendarDate as e } from "../../../shared/util/dist/lib/formatCalendarDate.js";
|
|
2
|
+
import { derivePayableStatus as t } from "./index6.js";
|
|
3
|
+
import { resolveVendor as n } from "./index7.js";
|
|
4
|
+
import { resolveAmountDueMinorUnits as r } from "./index19.js";
|
|
5
|
+
import { formatBillMoney as i } from "./index2.js";
|
|
6
|
+
import { getPaidAtLabel as a } from "./index38.js";
|
|
4
7
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index39.js
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
8
|
+
function o({ payable: o, lineItems: s, glCodeOptions: c, glCodeRosterAvailable: l = !0, history: u, paymentHistory: d, approvalPolicy: f, labels: p, hasScheduledPayment: m }) {
|
|
9
|
+
let h = o.currency, g = t({
|
|
10
|
+
apiStatus: o.status,
|
|
11
|
+
dueDate: o.due_date,
|
|
12
|
+
scheduledPaymentDate: o.scheduled_payment_date,
|
|
13
|
+
hasScheduledPayment: m
|
|
14
|
+
}), _ = n(o), v = _?.bank_account?.account_number, y = e(o.issued_at) || p.notProvided, b = e(o.due_date) || p.notProvided, x = new Map(c.map((e) => [e.value, e.label])), S = [
|
|
15
|
+
{
|
|
16
|
+
label: p.subtotalRow,
|
|
17
|
+
minorUnits: o.subtotal
|
|
18
|
+
},
|
|
19
|
+
{
|
|
20
|
+
label: p.discountRow,
|
|
21
|
+
minorUnits: o.discount
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
label: p.taxRow,
|
|
25
|
+
minorUnits: o.tax_amount
|
|
23
26
|
}
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
27
|
+
].map((e) => ({
|
|
28
|
+
label: e.label,
|
|
29
|
+
value: i(e.minorUnits, h)
|
|
30
|
+
})).filter((e) => !!e.value), C = i(o.total_amount, h);
|
|
31
|
+
C && S.push({
|
|
32
|
+
label: p.totalRow,
|
|
33
|
+
value: C,
|
|
34
|
+
emphasis: !0
|
|
35
|
+
});
|
|
36
|
+
let w = a(o);
|
|
37
|
+
return {
|
|
38
|
+
amountDue: i(r(o), h) ?? "",
|
|
39
|
+
amountPaid: w ? i(o.amount_paid, h) : void 0,
|
|
40
|
+
paidOnLabel: w ? p.paidOnLabel(w) : void 0,
|
|
41
|
+
invoiceDateLabel: y,
|
|
42
|
+
dueDateLabel: b,
|
|
43
|
+
dueDateTone: g.isOverdue ? "danger" : "default",
|
|
44
|
+
status: g.status,
|
|
45
|
+
statusTone: g.tone,
|
|
46
|
+
payTo: {
|
|
47
|
+
name: _?.name || p.notProvided,
|
|
48
|
+
email: _?.email ?? void 0,
|
|
49
|
+
paymentInstructionsLabel: v ? p.paymentInstructionsValue(v.slice(-4)) : void 0
|
|
50
|
+
},
|
|
51
|
+
invoiceFields: [
|
|
52
|
+
{
|
|
53
|
+
label: p.invoiceDateRow,
|
|
54
|
+
value: y
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
label: p.dueDateRow,
|
|
58
|
+
value: b
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
label: p.invoiceNumberRow,
|
|
62
|
+
value: o.document_id || p.notProvided
|
|
63
|
+
}
|
|
64
|
+
],
|
|
65
|
+
lineItems: s.map((e) => {
|
|
66
|
+
let t = i(e.unit_price, h);
|
|
67
|
+
return {
|
|
68
|
+
id: e.id,
|
|
69
|
+
description: e.name ?? e.description ?? "",
|
|
70
|
+
glCodeLabel: e.ledger_account_id ? x.get(e.ledger_account_id) ?? (l ? p.glCodeMissing : p.glCodeUnavailable) : p.glCodeMissing,
|
|
71
|
+
qtyPriceLabel: e.quantity != null && t ? p.qtyPriceValue(String(e.quantity), t) : "",
|
|
72
|
+
amount: i(e.subtotal, h) ?? ""
|
|
73
|
+
};
|
|
74
|
+
}),
|
|
75
|
+
amountRows: S,
|
|
76
|
+
approvalPolicy: f,
|
|
77
|
+
paymentHistory: d,
|
|
78
|
+
history: u
|
|
79
|
+
};
|
|
50
80
|
}
|
|
51
81
|
//#endregion
|
|
52
|
-
export {
|
|
82
|
+
export { o as buildBillDetailView };
|
|
@@ -1,59 +1,26 @@
|
|
|
1
1
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index4.js
|
|
2
|
-
var e =
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
};
|
|
26
|
-
case "approve_in_progress": return {
|
|
27
|
-
status: "pending_approval",
|
|
28
|
-
tone: "warning",
|
|
29
|
-
isOverdue: s
|
|
30
|
-
};
|
|
31
|
-
case "waiting_to_be_paid": return {
|
|
32
|
-
status: "ready_to_pay",
|
|
33
|
-
tone: "info",
|
|
34
|
-
isOverdue: s
|
|
35
|
-
};
|
|
36
|
-
case "partially_paid": return {
|
|
37
|
-
status: "partially_paid",
|
|
38
|
-
tone: "success",
|
|
39
|
-
isOverdue: s
|
|
40
|
-
};
|
|
41
|
-
case "paid": return {
|
|
42
|
-
status: "paid",
|
|
43
|
-
tone: "success",
|
|
44
|
-
isOverdue: s
|
|
45
|
-
};
|
|
46
|
-
case "canceled": return {
|
|
47
|
-
status: "canceled",
|
|
48
|
-
tone: "muted",
|
|
49
|
-
isOverdue: s
|
|
50
|
-
};
|
|
51
|
-
case "rejected": return {
|
|
52
|
-
status: "rejected",
|
|
53
|
-
tone: "danger",
|
|
54
|
-
isOverdue: s
|
|
55
|
-
};
|
|
56
|
-
}
|
|
57
|
-
}
|
|
2
|
+
var e = {
|
|
3
|
+
selectRow: ({ vendorLabel: e, invoiceNumberLabel: t, addedOnLabel: n }) => `Select bill — ${e}, invoice ${t}, added ${n}`,
|
|
4
|
+
openRow: ({ vendorLabel: e, invoiceNumberLabel: t, addedOnLabel: n }) => `View bill — ${e}, invoice ${t}, added ${n}`,
|
|
5
|
+
reviewGroup: ({ vendorLabel: e, count: t }) => `${e} — ${t} possible duplicate bills`,
|
|
6
|
+
selectGroup: ({ vendorLabel: e }) => `Select every bill from ${e}`,
|
|
7
|
+
deleteBillButton: "Remove this bill",
|
|
8
|
+
deleteConfirmTitle: "Remove duplicate bill?",
|
|
9
|
+
deleteConfirmDescription: "You can't undo this action.",
|
|
10
|
+
deleteConfirmButton: "Remove duplicate bill",
|
|
11
|
+
deleteConfirmBackButton: "Cancel",
|
|
12
|
+
cancelBillButton: "Cancel this bill",
|
|
13
|
+
confirmBillButton: "Confirm duplicate",
|
|
14
|
+
cancelConfirmTitle: "Cancel duplicate bill?",
|
|
15
|
+
cancelConfirmDescription: "You can't undo this action.",
|
|
16
|
+
cancelConfirmButton: "Cancel this bill",
|
|
17
|
+
cancelConfirmBackButton: "Back",
|
|
18
|
+
deletedToast: "Duplicate removed",
|
|
19
|
+
cancelledToast: "Duplicate cancelled",
|
|
20
|
+
confirmedToast: "Duplicate confirmed",
|
|
21
|
+
dismissedToast: "Marked as “not a duplicate”.",
|
|
22
|
+
removedToast: "Duplicate removed",
|
|
23
|
+
verdictFailedToast: "Couldn't update this duplicate. Try again."
|
|
24
|
+
};
|
|
58
25
|
//#endregion
|
|
59
|
-
export {
|
|
26
|
+
export { e as DUPLICATE_BILLS_LABELS_EN };
|
|
@@ -1,96 +1,52 @@
|
|
|
1
|
+
import { derivePayableStatus as e } from "./index6.js";
|
|
2
|
+
import { BILL_STATUS_BADGE_LABELS_EN as t } from "../../ui/dist/index16.js";
|
|
3
|
+
import "../../ui/dist/index.js";
|
|
1
4
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index40.js
|
|
2
|
-
var
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
},
|
|
34
|
-
forceApprove: {
|
|
35
|
-
title: "Override approval policy?",
|
|
36
|
-
description: "The below people haven't approved this bill yet. Approving now will bypass their required review. This will be recorded in the audit history and can't be undone.",
|
|
37
|
-
confirmButton: "Override and approve"
|
|
38
|
-
},
|
|
39
|
-
forceReject: {
|
|
40
|
-
title: "Override approval policy?",
|
|
41
|
-
description: "The below people haven't approved this bill yet. Rejecting now will bypass their required review. This will be recorded in the audit history and can't be undone.",
|
|
42
|
-
confirmButton: "Override and reject"
|
|
43
|
-
},
|
|
44
|
-
cancelButton: "Cancel"
|
|
45
|
-
},
|
|
46
|
-
actionError: "Couldn't update this bill. Try again.",
|
|
47
|
-
actionSuccess: {
|
|
48
|
-
approve: "Bill approved.",
|
|
49
|
-
reject: "Bill rejected.",
|
|
50
|
-
markAsPaid: "Bill marked as paid.",
|
|
51
|
-
cancel: "Bill canceled.",
|
|
52
|
-
cancelScheduledPayment: "Scheduled payment canceled.",
|
|
53
|
-
reopen: "Bill reopened.",
|
|
54
|
-
forceApprove: "Bill approved, overriding the approval policy.",
|
|
55
|
-
forceReject: "Bill rejected, overriding the approval policy."
|
|
5
|
+
var n = /* @__PURE__ */ new Set([
|
|
6
|
+
"credit_note_linked",
|
|
7
|
+
"credit_note_unlinked",
|
|
8
|
+
"line_item_added",
|
|
9
|
+
"line_item_updated",
|
|
10
|
+
"line_item_removed",
|
|
11
|
+
"deleted"
|
|
12
|
+
]);
|
|
13
|
+
function r(n, r, i) {
|
|
14
|
+
switch (n) {
|
|
15
|
+
case "payable_created": return r?.source_of_payable_data === "ocr" ? i.billUploaded : i.billAdded;
|
|
16
|
+
case "payable_updated": return i.billUpdated;
|
|
17
|
+
case "file_attached": return i.attachmentAdded;
|
|
18
|
+
case "submitted_for_approval": return i.submittedForApproval;
|
|
19
|
+
case "approval_requested": return i.approvalRequested;
|
|
20
|
+
case "approval_action": {
|
|
21
|
+
let e = r?.action, t = r?.reject_reason;
|
|
22
|
+
return e === "approve" ? i.approved : e === "reject" ? typeof t == "string" && t ? i.rejectedWithReason(t) : i.rejected : void 0;
|
|
23
|
+
}
|
|
24
|
+
case "auto_approved": return i.autoApproved;
|
|
25
|
+
case "reopened": return i.reopened;
|
|
26
|
+
case "marked_as_paid": return i.markedAsPaid;
|
|
27
|
+
case "marked_as_partially_paid": return i.markedAsPartiallyPaid;
|
|
28
|
+
case "payment_reverted": return i.paymentReverted;
|
|
29
|
+
case "status_changed": {
|
|
30
|
+
let n = r?.new_status;
|
|
31
|
+
if (typeof n != "string") return;
|
|
32
|
+
let a = e({ apiStatus: n }).status;
|
|
33
|
+
return i.statusChanged(t[a] ?? t.unknown);
|
|
34
|
+
}
|
|
35
|
+
default: return;
|
|
56
36
|
}
|
|
57
|
-
}, t = (e) => `Payment scheduled for ${e}`, n = [
|
|
58
|
-
"reject",
|
|
59
|
-
"cancel",
|
|
60
|
-
"cancelScheduledPayment",
|
|
61
|
-
"forceApprove",
|
|
62
|
-
"forceReject"
|
|
63
|
-
];
|
|
64
|
-
function r(e, t) {
|
|
65
|
-
let n = e.reason ? {
|
|
66
|
-
...e.reason,
|
|
67
|
-
...t?.reason
|
|
68
|
-
} : void 0, r = {
|
|
69
|
-
...e,
|
|
70
|
-
...t,
|
|
71
|
-
reason: n
|
|
72
|
-
};
|
|
73
|
-
return n || delete r.reason, r;
|
|
74
37
|
}
|
|
75
|
-
function i(e, t) {
|
|
76
|
-
let
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
...t,
|
|
88
|
-
decisionDialog: i(n.decisionDialog, t?.decisionDialog),
|
|
89
|
-
actionSuccess: {
|
|
90
|
-
...n.actionSuccess,
|
|
91
|
-
...t?.actionSuccess
|
|
92
|
-
}
|
|
93
|
-
};
|
|
38
|
+
function i(e, t, i) {
|
|
39
|
+
let a = new Map(t.map((e) => [e.id, e.name]));
|
|
40
|
+
return e.filter((e) => !n.has(e.event_type)).map((e) => {
|
|
41
|
+
let t = r(e.event_type, e.event_data, i);
|
|
42
|
+
if (!t) return;
|
|
43
|
+
let n = e.entity_user_id ? a.get(e.entity_user_id) : void 0;
|
|
44
|
+
return {
|
|
45
|
+
id: e.id,
|
|
46
|
+
dateLabel: i.dateLabel(e.timestamp),
|
|
47
|
+
description: n ? i.byActor(t, n) : t
|
|
48
|
+
};
|
|
49
|
+
}).filter((e) => !!e);
|
|
94
50
|
}
|
|
95
51
|
//#endregion
|
|
96
|
-
export {
|
|
52
|
+
export { i as buildBillHistory };
|