@tesouro/embedded-components-react 0.5.65 → 0.5.68
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/data-access/dist/index17.js +35 -34
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index6.js +9 -8
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index49.js +4 -2
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index53.js +185 -188
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index56.js +30 -20
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index61.js +356 -351
- package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index82.js +89 -88
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/labels.js +2 -2
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/feature/dist/lib/useCounterpartForm.js +71 -37
- package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/ui/dist/index2.js +1 -1
- 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/data-access/dist/index17.js
CHANGED
|
@@ -8,40 +8,41 @@ import { getPayables as n } from "../../../shared/data-access/dist/lib/rest/sdk.
|
|
|
8
8
|
import { getPayablesAnalyticsOptions as r, getPayablesIdOptions as i, getPayablesOptions as a, getPayablesQueryKey as o } from "../../../shared/data-access/dist/lib/rest/@tanstack/react-query.gen.js";
|
|
9
9
|
import { withAuthEpoch as s } from "../../../shared/data-access/dist/lib/withAuthEpoch.js";
|
|
10
10
|
import "../../../shared/data-access/dist/index.js";
|
|
11
|
-
import {
|
|
12
|
-
import { payablePolicyAssignmentQueryOptions as
|
|
13
|
-
import { queryOptions as
|
|
11
|
+
import { OCR_POLL_INTERVAL_MS as c, payableOcrQueryOptions as l } from "./index4.js";
|
|
12
|
+
import { payablePolicyAssignmentQueryOptions as u } from "./index16.js";
|
|
13
|
+
import { queryOptions as d, useQuery as f } from "@tanstack/react-query";
|
|
14
14
|
//#region ../../libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index17.js
|
|
15
|
-
function
|
|
16
|
-
let { client:
|
|
17
|
-
client:
|
|
18
|
-
headers: t(
|
|
19
|
-
query:
|
|
15
|
+
function p({ enabled: n, pollWhileOcrProcessing: r = !1, ...i } = {}) {
|
|
16
|
+
let { client: o, organizationId: l, widgetToken: u, authEpoch: d } = e(), p = !!(l && u) && (n === !0 || n === void 0), m = a({
|
|
17
|
+
client: o,
|
|
18
|
+
headers: t(l),
|
|
19
|
+
query: i
|
|
20
20
|
});
|
|
21
|
-
return
|
|
22
|
-
...s(
|
|
23
|
-
enabled:
|
|
21
|
+
return f({
|
|
22
|
+
...s(m, d),
|
|
23
|
+
enabled: p,
|
|
24
|
+
...r ? { refetchInterval: (e) => (e.state.data?.data ?? []).some((e) => e.ocr_status === "processing") ? c : !1 } : {}
|
|
24
25
|
});
|
|
25
26
|
}
|
|
26
|
-
var
|
|
27
|
-
function
|
|
28
|
-
let { client: i, organizationId: a, widgetToken: c, authEpoch: l } = e(),
|
|
27
|
+
var m = 100;
|
|
28
|
+
function h({ enabled: r } = {}) {
|
|
29
|
+
let { client: i, organizationId: a, widgetToken: c, authEpoch: l } = e(), u = t(a), p = {
|
|
29
30
|
duplicate_match_status: "suspected",
|
|
30
|
-
limit:
|
|
31
|
-
}, h =
|
|
31
|
+
limit: m
|
|
32
|
+
}, h = d({
|
|
32
33
|
queryKey: [...o({
|
|
33
34
|
client: i,
|
|
34
|
-
headers:
|
|
35
|
-
query:
|
|
35
|
+
headers: u,
|
|
36
|
+
query: p
|
|
36
37
|
}), "all"],
|
|
37
38
|
queryFn: async ({ signal: e }) => {
|
|
38
39
|
let t = [], r = /* @__PURE__ */ new Set(), a;
|
|
39
40
|
do {
|
|
40
41
|
let { data: o } = await n({
|
|
41
42
|
client: i,
|
|
42
|
-
headers:
|
|
43
|
+
headers: u,
|
|
43
44
|
query: {
|
|
44
|
-
...
|
|
45
|
+
...p,
|
|
45
46
|
pagination_token: a
|
|
46
47
|
},
|
|
47
48
|
signal: e,
|
|
@@ -54,33 +55,33 @@ function m({ enabled: r } = {}) {
|
|
|
54
55
|
return { data: t };
|
|
55
56
|
}
|
|
56
57
|
});
|
|
57
|
-
return
|
|
58
|
+
return f({
|
|
58
59
|
...s(h, l),
|
|
59
60
|
enabled: !!(a && c) && r !== !1
|
|
60
61
|
});
|
|
61
62
|
}
|
|
62
|
-
function
|
|
63
|
+
function g({ enabled: n } = {}) {
|
|
63
64
|
let { client: i, organizationId: a, widgetToken: o, authEpoch: c } = e(), l = !!(a && o) && (n === !0 || n === void 0), u = r({
|
|
64
65
|
client: i,
|
|
65
66
|
headers: t(a)
|
|
66
67
|
});
|
|
67
|
-
return
|
|
68
|
+
return f({
|
|
68
69
|
...s(u, c),
|
|
69
70
|
enabled: l
|
|
70
71
|
});
|
|
71
72
|
}
|
|
72
|
-
function
|
|
73
|
-
let { client:
|
|
74
|
-
client:
|
|
75
|
-
organizationId:
|
|
73
|
+
function _(n, { enabled: r = !0, pollWhileOcrProcessing: a = !1, pollWhilePolicyAssignmentUnsettled: o = !1 } = {}) {
|
|
74
|
+
let { client: c, organizationId: d, widgetToken: p, authEpoch: m } = e(), h = !!(d && p && n) && r, g = a ? l({
|
|
75
|
+
client: c,
|
|
76
|
+
organizationId: d,
|
|
76
77
|
payableId: n ?? ""
|
|
77
|
-
}) : void 0, _ = o ?
|
|
78
|
-
client:
|
|
79
|
-
organizationId:
|
|
78
|
+
}) : void 0, _ = o ? u({
|
|
79
|
+
client: c,
|
|
80
|
+
organizationId: d,
|
|
80
81
|
payableId: n ?? ""
|
|
81
82
|
}) : void 0, v = g ?? _ ?? i({
|
|
82
|
-
client:
|
|
83
|
-
headers: t(
|
|
83
|
+
client: c,
|
|
84
|
+
headers: t(d),
|
|
84
85
|
path: { payable_id: n ?? "" }
|
|
85
86
|
}), y = g && _ ? {
|
|
86
87
|
...v,
|
|
@@ -89,10 +90,10 @@ function g(n, { enabled: r = !0, pollWhileOcrProcessing: a = !1, pollWhilePolicy
|
|
|
89
90
|
return t.length ? Math.min(...t) : !1;
|
|
90
91
|
}
|
|
91
92
|
} : v;
|
|
92
|
-
return
|
|
93
|
+
return f({
|
|
93
94
|
...s(y, m),
|
|
94
95
|
enabled: h
|
|
95
96
|
});
|
|
96
97
|
}
|
|
97
98
|
//#endregion
|
|
98
|
-
export {
|
|
99
|
+
export { h as useAllSuspectedDuplicatePayablesQuery, _ as usePayableQuery, p as usePayablesQuery, g as usePayablesTotalCountQuery };
|
package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index6.js
CHANGED
|
@@ -245,19 +245,20 @@ async function K({ client: e, organizationId: t, payableId: n }) {
|
|
|
245
245
|
payableId: n
|
|
246
246
|
}), o;
|
|
247
247
|
}
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
248
|
+
var q = 9e4;
|
|
249
|
+
async function J({ client: e, organizationId: t, payableId: n }) {
|
|
250
|
+
let i = Date.now() + q, o = v, s = !1;
|
|
251
|
+
for (; !s && Date.now() < i;) {
|
|
251
252
|
await new Promise((e) => {
|
|
252
|
-
setTimeout(e,
|
|
253
|
-
});
|
|
253
|
+
setTimeout(e, o);
|
|
254
|
+
}), o = E(o);
|
|
254
255
|
try {
|
|
255
256
|
let { data: i } = await a({
|
|
256
257
|
client: e,
|
|
257
258
|
headers: r(t),
|
|
258
259
|
path: { payable_id: n }
|
|
259
260
|
});
|
|
260
|
-
|
|
261
|
+
s = i?.ocr_status !== "processing";
|
|
261
262
|
} catch {}
|
|
262
263
|
}
|
|
263
264
|
return await y({
|
|
@@ -265,7 +266,7 @@ async function q({ client: e, organizationId: t, payableId: n }) {
|
|
|
265
266
|
organizationId: t,
|
|
266
267
|
payableId: n,
|
|
267
268
|
includeLineItems: !0
|
|
268
|
-
}),
|
|
269
|
+
}), s;
|
|
269
270
|
}
|
|
270
271
|
//#endregion
|
|
271
|
-
export { R as beginApprovalRequestWatch, k as invalidateApprovalDecisionQueries, x as invalidateDeletedPayableQueries, y as invalidatePayableQueries, z as reconcileApprovalDecisionQueries, K as reconcileCancelledPaymentQueries, W as reconcileScheduledPaymentQueries, H as reconcileSubmittedForApprovalQueries,
|
|
272
|
+
export { R as beginApprovalRequestWatch, k as invalidateApprovalDecisionQueries, x as invalidateDeletedPayableQueries, y as invalidatePayableQueries, z as reconcileApprovalDecisionQueries, K as reconcileCancelledPaymentQueries, W as reconcileScheduledPaymentQueries, H as reconcileSubmittedForApprovalQueries, J as reconcileUploadedPayableOcr };
|
|
@@ -30,7 +30,9 @@ var v = {
|
|
|
30
30
|
unreadableTax: "Enter a valid tax amount.",
|
|
31
31
|
unreadableTotal: "Enter a valid total amount.",
|
|
32
32
|
totalNotGreaterThanZero: "Total amount must be greater than $0.",
|
|
33
|
-
poNumberTooLong: "PO number must be 255 characters or fewer."
|
|
33
|
+
poNumberTooLong: "PO number must be 255 characters or fewer.",
|
|
34
|
+
implausibleDate: "Enter a date within the last 10 years and next year.",
|
|
35
|
+
dueBeforeInvoiceDate: "Due date must be on or after the invoice date."
|
|
34
36
|
}, y = {
|
|
35
37
|
paymentInstructionsValue: (e) => `Account ending in ${e}`,
|
|
36
38
|
noMethod: "No payment method on file",
|
|
@@ -157,7 +159,7 @@ var w = {
|
|
|
157
159
|
createTitle: "New vendor",
|
|
158
160
|
editTitle: "Edit vendor",
|
|
159
161
|
switchVendorFieldLabel: "Switch to a different vendor",
|
|
160
|
-
nameLabel: "
|
|
162
|
+
nameLabel: "Business name",
|
|
161
163
|
addAddress: "Add address (optional)",
|
|
162
164
|
cancel: "Cancel",
|
|
163
165
|
save: "Save",
|