@mikemo-coposit/am-accounting-shared 0.0.14 → 0.0.16
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/cjs/index.js +126 -93
- package/dist/cjs/schemas/cma/cma-search.rest.schemal.d.ts +477 -459
- package/dist/cjs/schemas/cma/cma-search.rest.schemal.d.ts.map +1 -1
- package/dist/cjs/schemas/cma/create-cma.schema.d.ts +1 -1
- package/dist/cjs/schemas/cma-account-period/cma-account-period-closing-summary.rest.schema.d.ts +1 -1
- package/dist/cjs/schemas/cma-account-period/cma-account-period-closing-summary.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/cma-reconciliation/create-cma-reconciliation.rest.schema.d.ts +3 -2
- package/dist/cjs/schemas/cma-reconciliation/create-cma-reconciliation.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/cma-transaction/cma-transaction-search.rest.schema.d.ts +746 -708
- package/dist/cjs/schemas/cma-transaction/cma-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/common/date/index.d.ts +1 -0
- package/dist/cjs/schemas/common/date/index.d.ts.map +1 -1
- package/dist/cjs/schemas/common/date/string-to-bool.schema.d.ts +4 -0
- package/dist/cjs/schemas/common/date/string-to-bool.schema.d.ts.map +1 -0
- package/dist/cjs/schemas/common/date/string-to-end-of-day.schema.d.ts +1 -1
- package/dist/cjs/schemas/common/date/string-to-end-of-day.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/common/date/string-to-start-of-day.schema.d.ts +1 -1
- package/dist/cjs/schemas/common/date/string-to-start-of-day.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/common/search/bool-filter.schema.d.ts +9 -2
- package/dist/cjs/schemas/common/search/bool-filter.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/common/search/pagination-req.schema.d.ts +2 -2
- package/dist/cjs/schemas/common/search/string-filter.schema.d.ts +28 -5
- package/dist/cjs/schemas/common/search/string-filter.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/mta-account-period/mta-account-period-close.rest.schema.d.ts +2 -1
- package/dist/cjs/schemas/mta-account-period/mta-account-period-close.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/mta-account-period/mta-account-period-closing-summary.rest.schema.d.ts +1 -1
- package/dist/cjs/schemas/mta-account-period/mta-account-period-closing-summary.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/mta-reconciliation/create-mta-reconciliation.rest.schema.d.ts +3 -2
- package/dist/cjs/schemas/mta-reconciliation/create-mta-reconciliation.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/mta-transaction/create-mta-transactionrest.schema.d.ts +1 -1
- package/dist/cjs/schemas/mta-transaction/create-mta-transactionrest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/mta-transaction/mta-transaction-search.rest.schema.d.ts +491 -463
- package/dist/cjs/schemas/mta-transaction/mta-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/payout/payout-search.rest.schema.d.ts +140 -135
- package/dist/cjs/schemas/payout/payout-search.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/payout-transaction/payout-transaction-search.rest.schema.d.ts +168 -162
- package/dist/cjs/schemas/payout-transaction/payout-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/project-mta-allocation/approve-mta-allocation.schema.d.ts +1 -1
- package/dist/cjs/schemas/property/property-search.rest.schema.d.ts +252 -243
- package/dist/cjs/schemas/property/property-search.rest.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/report/bank-reconciliation-summary.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/common-report-with-cma-selection.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/common-report.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/customer-ledger.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/payment-list.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/project-ledger.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/receipt-list.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/reconciled-items-list.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/trust-trial.rest.schema.d.ts +2 -2
- package/dist/cjs/schemas/report/unknown-receipt-ledger.schema.d.ts +4 -3
- package/dist/cjs/schemas/report/unknown-receipt-ledger.schema.d.ts.map +1 -1
- package/dist/cjs/schemas/report/unreconciled-items-list.rest.schema.d.ts +2 -2
- package/dist/cjs/utils/date.util.d.ts +13 -4
- package/dist/cjs/utils/date.util.d.ts.map +1 -1
- package/dist/esm/index.mjs +102 -78
- package/dist/esm/schemas/cma/cma-search.rest.schemal.d.ts +477 -459
- package/dist/esm/schemas/cma/cma-search.rest.schemal.d.ts.map +1 -1
- package/dist/esm/schemas/cma/create-cma.schema.d.ts +1 -1
- package/dist/esm/schemas/cma-account-period/cma-account-period-closing-summary.rest.schema.d.ts +1 -1
- package/dist/esm/schemas/cma-account-period/cma-account-period-closing-summary.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/cma-reconciliation/create-cma-reconciliation.rest.schema.d.ts +3 -2
- package/dist/esm/schemas/cma-reconciliation/create-cma-reconciliation.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/cma-transaction/cma-transaction-search.rest.schema.d.ts +746 -708
- package/dist/esm/schemas/cma-transaction/cma-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/common/date/index.d.ts +1 -0
- package/dist/esm/schemas/common/date/index.d.ts.map +1 -1
- package/dist/esm/schemas/common/date/string-to-bool.schema.d.ts +4 -0
- package/dist/esm/schemas/common/date/string-to-bool.schema.d.ts.map +1 -0
- package/dist/esm/schemas/common/date/string-to-end-of-day.schema.d.ts +1 -1
- package/dist/esm/schemas/common/date/string-to-end-of-day.schema.d.ts.map +1 -1
- package/dist/esm/schemas/common/date/string-to-start-of-day.schema.d.ts +1 -1
- package/dist/esm/schemas/common/date/string-to-start-of-day.schema.d.ts.map +1 -1
- package/dist/esm/schemas/common/search/bool-filter.schema.d.ts +9 -2
- package/dist/esm/schemas/common/search/bool-filter.schema.d.ts.map +1 -1
- package/dist/esm/schemas/common/search/pagination-req.schema.d.ts +2 -2
- package/dist/esm/schemas/common/search/string-filter.schema.d.ts +28 -5
- package/dist/esm/schemas/common/search/string-filter.schema.d.ts.map +1 -1
- package/dist/esm/schemas/mta-account-period/mta-account-period-close.rest.schema.d.ts +2 -1
- package/dist/esm/schemas/mta-account-period/mta-account-period-close.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/mta-account-period/mta-account-period-closing-summary.rest.schema.d.ts +1 -1
- package/dist/esm/schemas/mta-account-period/mta-account-period-closing-summary.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/mta-reconciliation/create-mta-reconciliation.rest.schema.d.ts +3 -2
- package/dist/esm/schemas/mta-reconciliation/create-mta-reconciliation.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/mta-transaction/create-mta-transactionrest.schema.d.ts +1 -1
- package/dist/esm/schemas/mta-transaction/create-mta-transactionrest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/mta-transaction/mta-transaction-search.rest.schema.d.ts +491 -463
- package/dist/esm/schemas/mta-transaction/mta-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/payout/payout-search.rest.schema.d.ts +140 -135
- package/dist/esm/schemas/payout/payout-search.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/payout-transaction/payout-transaction-search.rest.schema.d.ts +168 -162
- package/dist/esm/schemas/payout-transaction/payout-transaction-search.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/project-mta-allocation/approve-mta-allocation.schema.d.ts +1 -1
- package/dist/esm/schemas/property/property-search.rest.schema.d.ts +252 -243
- package/dist/esm/schemas/property/property-search.rest.schema.d.ts.map +1 -1
- package/dist/esm/schemas/report/bank-reconciliation-summary.schema.d.ts +2 -2
- package/dist/esm/schemas/report/common-report-with-cma-selection.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/common-report.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/customer-ledger.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/payment-list.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/project-ledger.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/receipt-list.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/reconciled-items-list.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/trust-trial.rest.schema.d.ts +2 -2
- package/dist/esm/schemas/report/unknown-receipt-ledger.schema.d.ts +4 -3
- package/dist/esm/schemas/report/unknown-receipt-ledger.schema.d.ts.map +1 -1
- package/dist/esm/schemas/report/unreconciled-items-list.rest.schema.d.ts +2 -2
- package/dist/esm/utils/date.util.d.ts +13 -4
- package/dist/esm/utils/date.util.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const reconciledItemsListReportRestReqSchema: z.ZodIntersection<z.ZodObject<{
|
|
3
3
|
reportDataRangeType: z.ZodEnum<typeof import("../..").ReportDataRangeType>;
|
|
4
|
-
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
5
|
-
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
4
|
+
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
5
|
+
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
6
6
|
}, z.core.$strip>, z.ZodObject<{
|
|
7
7
|
cmaIds: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodUUID>>>;
|
|
8
8
|
mtaId: z.ZodOptional<z.ZodNullable<z.ZodUUID>>;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const trustTrialBalanceReportRestReqSchema: z.ZodIntersection<z.ZodObject<{
|
|
3
3
|
reportDataRangeType: z.ZodEnum<typeof import("../..").ReportDataRangeType>;
|
|
4
|
-
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
5
|
-
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
4
|
+
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
5
|
+
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
6
6
|
}, z.core.$strip>, z.ZodObject<{
|
|
7
7
|
cmaIds: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodUUID>>>;
|
|
8
8
|
mtaId: z.ZodOptional<z.ZodNullable<z.ZodUUID>>;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const unknownReceiptLedgerRestReqSchema: z.ZodIntersection<z.ZodObject<{
|
|
3
3
|
reportDataRangeType: z.ZodEnum<typeof import("../..").ReportDataRangeType>;
|
|
4
|
-
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
5
|
-
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
4
|
+
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
5
|
+
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
6
6
|
}, z.core.$strip>, z.ZodObject<{
|
|
7
7
|
mtaId: z.ZodUUID;
|
|
8
8
|
}, z.core.$strip>>;
|
|
9
|
-
export type UnknownReceiptLedgerRestReq = z.
|
|
9
|
+
export type UnknownReceiptLedgerRestReq = z.input<typeof unknownReceiptLedgerRestReqSchema>;
|
|
10
|
+
export type UnknownReceiptLedgerRes = z.output<typeof unknownReceiptLedgerRestReqSchema>;
|
|
10
11
|
//# sourceMappingURL=unknown-receipt-ledger.schema.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"unknown-receipt-ledger.schema.d.ts","sourceRoot":"","sources":["../../../../packages/schemas/report/unknown-receipt-ledger.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,iCAAiC;;;;;;kBAE3C,CAAC;AAEJ,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iCAAiC,CAAC,CAAC"}
|
|
1
|
+
{"version":3,"file":"unknown-receipt-ledger.schema.d.ts","sourceRoot":"","sources":["../../../../packages/schemas/report/unknown-receipt-ledger.schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,eAAO,MAAM,iCAAiC;;;;;;kBAE3C,CAAC;AAEJ,MAAM,MAAM,2BAA2B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iCAAiC,CAAC,CAAC;AAC5F,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,iCAAiC,CAAC,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
export declare const unreconciledItemsListReportRestReqSchema: z.ZodIntersection<z.ZodObject<{
|
|
3
3
|
reportDataRangeType: z.ZodEnum<typeof import("../..").ReportDataRangeType>;
|
|
4
|
-
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
5
|
-
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date
|
|
4
|
+
endDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
5
|
+
startDate: z.ZodPipe<z.ZodOptional<z.ZodNullable<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodDate, z.ZodISODateTime]>, z.ZodTransform<number | Date, string | Date>>, z.ZodDate>>>, z.ZodDate>;
|
|
6
6
|
}, z.core.$strip>, z.ZodObject<{
|
|
7
7
|
cmaIds: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodUUID>>>;
|
|
8
8
|
mtaId: z.ZodOptional<z.ZodNullable<z.ZodUUID>>;
|
|
@@ -7,7 +7,7 @@ export declare const DATE_FORMATS: {
|
|
|
7
7
|
export declare const DEFAULT_DATE_FORMAT: "DD/MM/YYYY";
|
|
8
8
|
export declare const DEFAULT_DATE_FORMAT_WITH_TIME = "DD/MM/YYYY HH:mm:ss";
|
|
9
9
|
export declare const DEFAULT_DATE_TIME_ZONE = "Australia/Sydney";
|
|
10
|
-
declare const safeParseDateFromStr: (dateStr?: string | null | Dayjs | Date, options?: {
|
|
10
|
+
export declare const safeParseDateFromStr: (dateStr?: string | null | Dayjs | Date, options?: {
|
|
11
11
|
format?: string | string[];
|
|
12
12
|
timeZone?: string;
|
|
13
13
|
strict?: boolean;
|
|
@@ -20,8 +20,17 @@ declare const safeParseDateFromStr: (dateStr?: string | null | Dayjs | Date, opt
|
|
|
20
20
|
isValid: false;
|
|
21
21
|
date: null;
|
|
22
22
|
dayjs: null;
|
|
23
|
-
reason
|
|
23
|
+
reason: string;
|
|
24
24
|
};
|
|
25
|
-
declare const
|
|
26
|
-
|
|
25
|
+
export declare const parseToDate: (input?: string | Date | Dayjs | null | undefined, options?: {
|
|
26
|
+
format?: string | string[];
|
|
27
|
+
timeZone?: string;
|
|
28
|
+
strict?: boolean;
|
|
29
|
+
}) => Date;
|
|
30
|
+
export declare const parseToDayjs: (input?: string | Date | Dayjs | null | undefined, options?: {
|
|
31
|
+
format?: string | string[];
|
|
32
|
+
timeZone?: string;
|
|
33
|
+
strict?: boolean;
|
|
34
|
+
}) => dayjs.Dayjs;
|
|
35
|
+
export declare const extendDayjs: (input?: string | Date | Dayjs | null | undefined) => dayjs.Dayjs;
|
|
27
36
|
//# sourceMappingURL=date.util.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"date.util.d.ts","sourceRoot":"","sources":["../../../packages/utils/date.util.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,KAAK,EAAW,MAAM,OAAO,CAAC;AAM9C,eAAO,MAAM,YAAY;;;;CAIf,CAAC;AAEX,eAAO,MAAM,mBAAmB,cAA0B,CAAC;AAE3D,eAAO,MAAM,6BAA6B,wBAAwB,CAAC;AAEnE,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAOzD,
|
|
1
|
+
{"version":3,"file":"date.util.d.ts","sourceRoot":"","sources":["../../../packages/utils/date.util.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,KAAK,EAAW,MAAM,OAAO,CAAC;AAM9C,eAAO,MAAM,YAAY;;;;CAIf,CAAC;AAEX,eAAO,MAAM,mBAAmB,cAA0B,CAAC;AAE3D,eAAO,MAAM,6BAA6B,wBAAwB,CAAC;AAEnE,eAAO,MAAM,sBAAsB,qBAAqB,CAAC;AAOzD,eAAO,MAAM,oBAAoB,GAAI,UAAU,MAAM,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,EAAE,UAAU;IACrF,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,KAAG;IACF,OAAO,EAAE,IAAI,CAAC;IACd,IAAI,EAAE,IAAI,CAAC;IACX,KAAK,EAAE,KAAK,CAAC;IACb,MAAM,CAAC,EAAE,KAAK,CAAC;CAChB,GAAG;IACF,OAAO,EAAE,KAAK,CAAC;IACf,IAAI,EAAE,IAAI,CAAC;IACX,KAAK,EAAE,IAAI,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;CA6ChB,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,QAAQ,MAAM,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,EAAE,UAAU;IACtF,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,SAOA,CAAC;AAEF,eAAO,MAAM,YAAY,GAAI,QAAQ,MAAM,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,EAAE,UAAU;IACvF,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB,gBAOA,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,QAAQ,MAAM,GAAG,IAAI,GAAG,KAAK,GAAG,IAAI,GAAG,SAAS,gBAI3E,CAAC"}
|
package/dist/esm/index.mjs
CHANGED
|
@@ -1250,7 +1250,7 @@ const safeParseDateFromStr = (dateStr, options)=>{
|
|
|
1250
1250
|
isValid: false,
|
|
1251
1251
|
date: null,
|
|
1252
1252
|
dayjs: null,
|
|
1253
|
-
reason: `invalid date string format, only support ${'string' == typeof format ? format : format.join(', ')}`
|
|
1253
|
+
reason: `invalid date string format, only support ${'string' == typeof format ? format : format.join(', ')}, but received ${dateStr}`
|
|
1254
1254
|
};
|
|
1255
1255
|
return {
|
|
1256
1256
|
isValid: true,
|
|
@@ -1258,7 +1258,17 @@ const safeParseDateFromStr = (dateStr, options)=>{
|
|
|
1258
1258
|
dayjs: parsedDate
|
|
1259
1259
|
};
|
|
1260
1260
|
};
|
|
1261
|
-
const
|
|
1261
|
+
const parseToDate = (input, options)=>{
|
|
1262
|
+
const { date, isValid, reason } = safeParseDateFromStr(input, options);
|
|
1263
|
+
if (!isValid) throw new Error(reason);
|
|
1264
|
+
return date;
|
|
1265
|
+
};
|
|
1266
|
+
const parseToDayjs = (input, options)=>{
|
|
1267
|
+
const { dayjs, isValid, reason } = safeParseDateFromStr(input, options);
|
|
1268
|
+
if (!isValid) throw new Error(reason);
|
|
1269
|
+
return dayjs;
|
|
1270
|
+
};
|
|
1271
|
+
const extendDayjs = (input)=>{
|
|
1262
1272
|
const date = dayjs_0(input).tz(DEFAULT_DATE_TIME_ZONE);
|
|
1263
1273
|
return date;
|
|
1264
1274
|
};
|
|
@@ -1284,12 +1294,25 @@ const cmaAccountPeriodCloseRestReqSchema = z.object({
|
|
|
1284
1294
|
endDate: stringToDateSchema,
|
|
1285
1295
|
closingDescription: z.string().optional()
|
|
1286
1296
|
});
|
|
1297
|
+
const stringToEndOfDaySchema = z.union([
|
|
1298
|
+
z.string(),
|
|
1299
|
+
z.date(),
|
|
1300
|
+
z.iso.datetime()
|
|
1301
|
+
]).transform((val, ctx)=>{
|
|
1302
|
+
const { dayjs, isValid, reason } = safeParseDateFromStr(val);
|
|
1303
|
+
if (!isValid) return ctx.issues.push({
|
|
1304
|
+
code: 'invalid_value',
|
|
1305
|
+
message: reason ?? 'Invalid date',
|
|
1306
|
+
input: val.toString(),
|
|
1307
|
+
values: [
|
|
1308
|
+
val.toString()
|
|
1309
|
+
]
|
|
1310
|
+
});
|
|
1311
|
+
return dayjs.endOf('day').toDate();
|
|
1312
|
+
}).pipe(z.date());
|
|
1287
1313
|
const cmaAccountPeriodClosingSummaryRestReqSchema = z.object({
|
|
1288
1314
|
cmaAccountPeriodId: z.uuid(),
|
|
1289
|
-
endDate:
|
|
1290
|
-
z.string(),
|
|
1291
|
-
z.date()
|
|
1292
|
-
]).transform((arg)=>dayjs_0(arg).endOf('day').toDate()).pipe(z.date())
|
|
1315
|
+
endDate: stringToEndOfDaySchema
|
|
1293
1316
|
});
|
|
1294
1317
|
const cmaAccountPeriodClosingSummaryRestResSchema = z.object({
|
|
1295
1318
|
startDate: z.date(),
|
|
@@ -1367,7 +1390,7 @@ const dollarsToCentsSchema = z.codec(z.union([
|
|
|
1367
1390
|
});
|
|
1368
1391
|
const createCmaReconciliationRestReqSchema = z.object({
|
|
1369
1392
|
bankStatementBalanceCents: dollarsToCentsSchema,
|
|
1370
|
-
reconciledTo:
|
|
1393
|
+
reconciledTo: stringToEndOfDaySchema,
|
|
1371
1394
|
cmaAccountPeriodId: z.uuid()
|
|
1372
1395
|
});
|
|
1373
1396
|
const updateCmaOpenReconciliationCurrentBankStatementBalanceRestReqSchema = z.object({
|
|
@@ -1406,15 +1429,39 @@ const dateTimeFilterSchema = z.strictObject({
|
|
|
1406
1429
|
]).optional()
|
|
1407
1430
|
});
|
|
1408
1431
|
const paginationReqSchema = z.object({
|
|
1409
|
-
page: z.coerce.number().prefault(1).pipe(z.int().positive()),
|
|
1410
|
-
pageSize: z.coerce.number().pipe(z.int().positive())
|
|
1432
|
+
page: z.coerce.number().prefault(1).pipe(z.int().positive()).optional(),
|
|
1433
|
+
pageSize: z.coerce.number().pipe(z.int().positive()).optional()
|
|
1434
|
+
});
|
|
1435
|
+
const stringToBoolSchema = z.union([
|
|
1436
|
+
z.boolean(),
|
|
1437
|
+
z.string()
|
|
1438
|
+
]).transform((input, ctx)=>{
|
|
1439
|
+
if ('string' == typeof input) {
|
|
1440
|
+
const result = z.stringbool().safeParse(input);
|
|
1441
|
+
if (result.success) return result.data;
|
|
1442
|
+
ctx.issues.push({
|
|
1443
|
+
code: 'invalid_value',
|
|
1444
|
+
message: result.error.message,
|
|
1445
|
+
input,
|
|
1446
|
+
values: [
|
|
1447
|
+
input
|
|
1448
|
+
]
|
|
1449
|
+
});
|
|
1450
|
+
return z.NEVER;
|
|
1451
|
+
}
|
|
1452
|
+
if ('boolean' == typeof input) return input;
|
|
1453
|
+
ctx.issues.push({
|
|
1454
|
+
code: 'invalid_value',
|
|
1455
|
+
message: 'Invalid boolean',
|
|
1456
|
+
input: JSON.stringify(input),
|
|
1457
|
+
values: [
|
|
1458
|
+
JSON.stringify(input)
|
|
1459
|
+
]
|
|
1460
|
+
});
|
|
1461
|
+
return z.NEVER;
|
|
1411
1462
|
});
|
|
1412
1463
|
const boolFilterBaseSchema = z.strictObject({
|
|
1413
|
-
equals:
|
|
1414
|
-
not: z.union([
|
|
1415
|
-
z.boolean(),
|
|
1416
|
-
z.lazy(()=>boolFilterBaseSchema)
|
|
1417
|
-
]).optional()
|
|
1464
|
+
equals: stringToBoolSchema
|
|
1418
1465
|
});
|
|
1419
1466
|
const boolFilterSchema = boolFilterBaseSchema.extend({
|
|
1420
1467
|
not: z.union([
|
|
@@ -1469,11 +1516,11 @@ const cmaTransactionSearchRestReqSchema = z.object({
|
|
|
1469
1516
|
]).optional(),
|
|
1470
1517
|
isCanceled: z.union([
|
|
1471
1518
|
z.lazy(()=>boolFilterSchema),
|
|
1472
|
-
z.
|
|
1519
|
+
z.boolean()
|
|
1473
1520
|
]).optional(),
|
|
1474
1521
|
isRefunded: z.union([
|
|
1475
1522
|
z.lazy(()=>boolFilterSchema),
|
|
1476
|
-
z.
|
|
1523
|
+
z.boolean()
|
|
1477
1524
|
]).optional(),
|
|
1478
1525
|
status: z.union([
|
|
1479
1526
|
z.lazy(()=>stringFilterSchema),
|
|
@@ -1490,9 +1537,8 @@ const cmaTransactionSearchRestReqSchema = z.object({
|
|
|
1490
1537
|
debitAmountCents: z.union([
|
|
1491
1538
|
z.lazy(()=>bigIntFilterSchema),
|
|
1492
1539
|
z.bigint()
|
|
1493
|
-
]).optional()
|
|
1494
|
-
|
|
1495
|
-
});
|
|
1540
|
+
]).optional()
|
|
1541
|
+
}).and(paginationReqSchema.optional());
|
|
1496
1542
|
const createCmaTransactionRestReqSchema = z.object({
|
|
1497
1543
|
amount: z.number().positive().transform(fromDollarsToCents).pipe(z.bigint()),
|
|
1498
1544
|
clearedAt: stringToDateSchema,
|
|
@@ -1520,22 +1566,6 @@ const accountNumberMaskedSchema = z.string().transform(maskBankAccountNumber);
|
|
|
1520
1566
|
const accountNumberValidationSchema = z.coerce.string().min(1, 'Account Number is required').max(9, 'Account Number must be less than 9 digits').regex(/^\d+$/, {
|
|
1521
1567
|
error: 'Account number must be all digits'
|
|
1522
1568
|
});
|
|
1523
|
-
const stringToEndOfDaySchema = z.union([
|
|
1524
|
-
z.string(),
|
|
1525
|
-
z.date(),
|
|
1526
|
-
z.iso.datetime()
|
|
1527
|
-
]).transform((val, ctx)=>{
|
|
1528
|
-
const { dayjs, isValid, reason } = safeParseDateFromStr(val);
|
|
1529
|
-
if (!isValid) return ctx.issues.push({
|
|
1530
|
-
code: 'invalid_value',
|
|
1531
|
-
message: reason ?? 'Invalid date',
|
|
1532
|
-
input: val.toString(),
|
|
1533
|
-
values: [
|
|
1534
|
-
val.toString()
|
|
1535
|
-
]
|
|
1536
|
-
});
|
|
1537
|
-
return dayjs.endOf('day').toDate();
|
|
1538
|
-
});
|
|
1539
1569
|
const stringToStartOfDaySchema = z.union([
|
|
1540
1570
|
z.string(),
|
|
1541
1571
|
z.date(),
|
|
@@ -1551,7 +1581,7 @@ const stringToStartOfDaySchema = z.union([
|
|
|
1551
1581
|
]
|
|
1552
1582
|
});
|
|
1553
1583
|
return dayjs.startOf('day').toDate();
|
|
1554
|
-
});
|
|
1584
|
+
}).pipe(z.date());
|
|
1555
1585
|
const InputJsonValueSchema = z.lazy(()=>z.union([
|
|
1556
1586
|
z.string(),
|
|
1557
1587
|
z.number(),
|
|
@@ -1835,10 +1865,7 @@ const mtaTransactionRestResSchema = mtaTransactionRestResBaseSchema.extend({
|
|
|
1835
1865
|
});
|
|
1836
1866
|
const mtaAccountPeriodClosingSummaryRestReqSchema = z.object({
|
|
1837
1867
|
mtaAccountPeriodId: z.uuid(),
|
|
1838
|
-
endDate:
|
|
1839
|
-
z.string(),
|
|
1840
|
-
z.date()
|
|
1841
|
-
]).transform((arg)=>dayjs_0(arg).endOf('day').toDate()).pipe(z.date())
|
|
1868
|
+
endDate: stringToEndOfDaySchema
|
|
1842
1869
|
});
|
|
1843
1870
|
const mtaAccountPeriodClosingSummaryRestResSchema = z.object({
|
|
1844
1871
|
startDate: z.date(),
|
|
@@ -1908,10 +1935,7 @@ const mtaAccountPeriodClosingSummaryRestResSchema = z.object({
|
|
|
1908
1935
|
});
|
|
1909
1936
|
const createMtaReconciliationRestReqSchema = z.object({
|
|
1910
1937
|
bankStatementBalanceCents: dollarsToCentsSchema,
|
|
1911
|
-
reconciledTo:
|
|
1912
|
-
z.string(),
|
|
1913
|
-
z.date()
|
|
1914
|
-
]).transform((arg)=>dayjs_0(arg).endOf('day').toDate()).pipe(z.coerce.date()),
|
|
1938
|
+
reconciledTo: stringToEndOfDaySchema,
|
|
1915
1939
|
mtaAccountPeriodId: z.uuid()
|
|
1916
1940
|
});
|
|
1917
1941
|
const updateOpenReconciliationCurrentBankStatementBalanceRestReqSchema = z.object({
|
|
@@ -1935,7 +1959,7 @@ const cancelMtaTransactionRestReqSchema = z.object({
|
|
|
1935
1959
|
});
|
|
1936
1960
|
const createMtaTransactionRestReqSchema = z.object({
|
|
1937
1961
|
amount: z.number().positive().transform(fromDollarsToCents).pipe(z.bigint()),
|
|
1938
|
-
clearedAt:
|
|
1962
|
+
clearedAt: stringToDateSchema,
|
|
1939
1963
|
description: z.string().transform((val)=>val.trim()),
|
|
1940
1964
|
inputType: z["enum"](mta_input_type_constant_MtaTransactionInputType),
|
|
1941
1965
|
transactionType: z["enum"](MtaTransactionType),
|
|
@@ -1987,11 +2011,11 @@ const mtaTransactionSearchRestReqSchema = z.object({
|
|
|
1987
2011
|
]).optional(),
|
|
1988
2012
|
isCanceled: z.union([
|
|
1989
2013
|
z.lazy(()=>boolFilterSchema),
|
|
1990
|
-
z.
|
|
2014
|
+
z.boolean()
|
|
1991
2015
|
]).optional(),
|
|
1992
2016
|
isRefunded: z.union([
|
|
1993
2017
|
z.lazy(()=>boolFilterSchema),
|
|
1994
|
-
z.
|
|
2018
|
+
z.boolean()
|
|
1995
2019
|
]).optional(),
|
|
1996
2020
|
mtaId: z.union([
|
|
1997
2021
|
z.lazy(()=>stringFilterSchema),
|
|
@@ -2888,7 +2912,7 @@ const utils = {
|
|
|
2888
2912
|
asap,
|
|
2889
2913
|
isIterable
|
|
2890
2914
|
};
|
|
2891
|
-
function
|
|
2915
|
+
function AxiosError(message, code, config, request, response) {
|
|
2892
2916
|
Error.call(this);
|
|
2893
2917
|
if (Error.captureStackTrace) Error.captureStackTrace(this, this.constructor);
|
|
2894
2918
|
else this.stack = new Error().stack;
|
|
@@ -2902,7 +2926,7 @@ function AxiosError_AxiosError(message, code, config, request, response) {
|
|
|
2902
2926
|
this.status = response.status ? response.status : null;
|
|
2903
2927
|
}
|
|
2904
2928
|
}
|
|
2905
|
-
utils.inherits(
|
|
2929
|
+
utils.inherits(AxiosError, Error, {
|
|
2906
2930
|
toJSON: function() {
|
|
2907
2931
|
return {
|
|
2908
2932
|
message: this.message,
|
|
@@ -2919,7 +2943,7 @@ utils.inherits(AxiosError_AxiosError, Error, {
|
|
|
2919
2943
|
};
|
|
2920
2944
|
}
|
|
2921
2945
|
});
|
|
2922
|
-
const AxiosError_prototype =
|
|
2946
|
+
const AxiosError_prototype = AxiosError.prototype;
|
|
2923
2947
|
const AxiosError_descriptors = {};
|
|
2924
2948
|
[
|
|
2925
2949
|
'ERR_BAD_OPTION_VALUE',
|
|
@@ -2939,22 +2963,22 @@ const AxiosError_descriptors = {};
|
|
|
2939
2963
|
value: code
|
|
2940
2964
|
};
|
|
2941
2965
|
});
|
|
2942
|
-
Object.defineProperties(
|
|
2966
|
+
Object.defineProperties(AxiosError, AxiosError_descriptors);
|
|
2943
2967
|
Object.defineProperty(AxiosError_prototype, 'isAxiosError', {
|
|
2944
2968
|
value: true
|
|
2945
2969
|
});
|
|
2946
|
-
|
|
2970
|
+
AxiosError.from = (error, code, config, request, response, customProps)=>{
|
|
2947
2971
|
const axiosError = Object.create(AxiosError_prototype);
|
|
2948
2972
|
utils.toFlatObject(error, axiosError, function(obj) {
|
|
2949
2973
|
return obj !== Error.prototype;
|
|
2950
2974
|
}, (prop)=>'isAxiosError' !== prop);
|
|
2951
|
-
|
|
2975
|
+
AxiosError.call(axiosError, error.message, code, config, request, response);
|
|
2952
2976
|
axiosError.cause = error;
|
|
2953
2977
|
axiosError.name = error.name;
|
|
2954
2978
|
customProps && Object.assign(axiosError, customProps);
|
|
2955
2979
|
return axiosError;
|
|
2956
2980
|
};
|
|
2957
|
-
const
|
|
2981
|
+
const core_AxiosError = AxiosError;
|
|
2958
2982
|
const helpers_null = null;
|
|
2959
2983
|
function isVisitable(thing) {
|
|
2960
2984
|
return utils.isPlainObject(thing) || utils.isArray(thing);
|
|
@@ -2996,7 +3020,7 @@ function toFormData(obj, formData, options) {
|
|
|
2996
3020
|
if (null === value) return '';
|
|
2997
3021
|
if (utils.isDate(value)) return value.toISOString();
|
|
2998
3022
|
if (utils.isBoolean(value)) return value.toString();
|
|
2999
|
-
if (!useBlob && utils.isBlob(value)) throw new
|
|
3023
|
+
if (!useBlob && utils.isBlob(value)) throw new core_AxiosError('Blob is not supported. Use a Buffer instead.');
|
|
3000
3024
|
if (utils.isArrayBuffer(value) || utils.isTypedArray(value)) return useBlob && 'function' == typeof Blob ? new Blob([
|
|
3001
3025
|
value
|
|
3002
3026
|
]) : Buffer.from(value);
|
|
@@ -3278,7 +3302,7 @@ const defaults = {
|
|
|
3278
3302
|
return JSON.parse(data);
|
|
3279
3303
|
} catch (e) {
|
|
3280
3304
|
if (strictJSONParsing) {
|
|
3281
|
-
if ('SyntaxError' === e.name) throw
|
|
3305
|
+
if ('SyntaxError' === e.name) throw core_AxiosError.from(e, core_AxiosError.ERR_BAD_RESPONSE, this, null, this.response);
|
|
3282
3306
|
throw e;
|
|
3283
3307
|
}
|
|
3284
3308
|
}
|
|
@@ -3575,19 +3599,19 @@ function isCancel(value) {
|
|
|
3575
3599
|
return !!(value && value.__CANCEL__);
|
|
3576
3600
|
}
|
|
3577
3601
|
function CanceledError(message, config, request) {
|
|
3578
|
-
|
|
3602
|
+
core_AxiosError.call(this, null == message ? 'canceled' : message, core_AxiosError.ERR_CANCELED, config, request);
|
|
3579
3603
|
this.name = 'CanceledError';
|
|
3580
3604
|
}
|
|
3581
|
-
utils.inherits(CanceledError,
|
|
3605
|
+
utils.inherits(CanceledError, core_AxiosError, {
|
|
3582
3606
|
__CANCEL__: true
|
|
3583
3607
|
});
|
|
3584
3608
|
const cancel_CanceledError = CanceledError;
|
|
3585
3609
|
function settle(resolve, reject, response) {
|
|
3586
3610
|
const validateStatus = response.config.validateStatus;
|
|
3587
3611
|
if (!response.status || !validateStatus || validateStatus(response.status)) resolve(response);
|
|
3588
|
-
else reject(new
|
|
3589
|
-
|
|
3590
|
-
|
|
3612
|
+
else reject(new core_AxiosError('Request failed with status code ' + response.status, [
|
|
3613
|
+
core_AxiosError.ERR_BAD_REQUEST,
|
|
3614
|
+
core_AxiosError.ERR_BAD_RESPONSE
|
|
3591
3615
|
][Math.floor(response.status / 100) - 4], response.config, response.request, response));
|
|
3592
3616
|
}
|
|
3593
3617
|
function parseProtocol(url) {
|
|
@@ -3875,18 +3899,18 @@ const xhr = isXHRAdapterSupported && function(config) {
|
|
|
3875
3899
|
};
|
|
3876
3900
|
request.onabort = function() {
|
|
3877
3901
|
if (!request) return;
|
|
3878
|
-
reject(new
|
|
3902
|
+
reject(new core_AxiosError('Request aborted', core_AxiosError.ECONNABORTED, config, request));
|
|
3879
3903
|
request = null;
|
|
3880
3904
|
};
|
|
3881
3905
|
request.onerror = function() {
|
|
3882
|
-
reject(new
|
|
3906
|
+
reject(new core_AxiosError('Network Error', core_AxiosError.ERR_NETWORK, config, request));
|
|
3883
3907
|
request = null;
|
|
3884
3908
|
};
|
|
3885
3909
|
request.ontimeout = function() {
|
|
3886
3910
|
let timeoutErrorMessage = _config.timeout ? 'timeout of ' + _config.timeout + 'ms exceeded' : 'timeout exceeded';
|
|
3887
3911
|
const transitional = _config.transitional || defaults_transitional;
|
|
3888
3912
|
if (_config.timeoutErrorMessage) timeoutErrorMessage = _config.timeoutErrorMessage;
|
|
3889
|
-
reject(new
|
|
3913
|
+
reject(new core_AxiosError(timeoutErrorMessage, transitional.clarifyTimeoutError ? core_AxiosError.ETIMEDOUT : core_AxiosError.ECONNABORTED, config, request));
|
|
3890
3914
|
request = null;
|
|
3891
3915
|
};
|
|
3892
3916
|
void 0 === requestData && requestHeaders.setContentType(null);
|
|
@@ -3915,7 +3939,7 @@ const xhr = isXHRAdapterSupported && function(config) {
|
|
|
3915
3939
|
if (_config.signal) _config.signal.aborted ? onCanceled() : _config.signal.addEventListener('abort', onCanceled);
|
|
3916
3940
|
}
|
|
3917
3941
|
const protocol = parseProtocol(_config.url);
|
|
3918
|
-
if (protocol && -1 === platform.protocols.indexOf(protocol)) return void reject(new
|
|
3942
|
+
if (protocol && -1 === platform.protocols.indexOf(protocol)) return void reject(new core_AxiosError('Unsupported protocol ' + protocol + ':', core_AxiosError.ERR_BAD_REQUEST, config));
|
|
3919
3943
|
request.send(requestData || null);
|
|
3920
3944
|
});
|
|
3921
3945
|
};
|
|
@@ -3929,12 +3953,12 @@ const composeSignals = (signals, timeout)=>{
|
|
|
3929
3953
|
aborted = true;
|
|
3930
3954
|
unsubscribe();
|
|
3931
3955
|
const err = reason instanceof Error ? reason : this.reason;
|
|
3932
|
-
controller.abort(err instanceof
|
|
3956
|
+
controller.abort(err instanceof core_AxiosError ? err : new cancel_CanceledError(err instanceof Error ? err.message : err));
|
|
3933
3957
|
}
|
|
3934
3958
|
};
|
|
3935
3959
|
let timer = timeout && setTimeout(()=>{
|
|
3936
3960
|
timer = null;
|
|
3937
|
-
onabort(new
|
|
3961
|
+
onabort(new core_AxiosError(`timeout ${timeout} of ms exceeded`, core_AxiosError.ETIMEDOUT));
|
|
3938
3962
|
}, timeout);
|
|
3939
3963
|
const unsubscribe = ()=>{
|
|
3940
3964
|
if (signals) {
|
|
@@ -4054,7 +4078,7 @@ isFetchSupported && ((res)=>{
|
|
|
4054
4078
|
'stream'
|
|
4055
4079
|
].forEach((type)=>{
|
|
4056
4080
|
resolvers[type] || (resolvers[type] = utils.isFunction(res[type]) ? (res)=>res[type]() : (_, config)=>{
|
|
4057
|
-
throw new
|
|
4081
|
+
throw new core_AxiosError(`Response type '${type}' is not supported`, core_AxiosError.ERR_NOT_SUPPORT, config);
|
|
4058
4082
|
});
|
|
4059
4083
|
});
|
|
4060
4084
|
})(new Response);
|
|
@@ -4146,10 +4170,10 @@ const adapters_fetch = isFetchSupported && (async (config)=>{
|
|
|
4146
4170
|
});
|
|
4147
4171
|
} catch (err) {
|
|
4148
4172
|
unsubscribe && unsubscribe();
|
|
4149
|
-
if (err && 'TypeError' === err.name && /Load failed|fetch/i.test(err.message)) throw Object.assign(new
|
|
4173
|
+
if (err && 'TypeError' === err.name && /Load failed|fetch/i.test(err.message)) throw Object.assign(new core_AxiosError('Network Error', core_AxiosError.ERR_NETWORK, config, request), {
|
|
4150
4174
|
cause: err.cause || err
|
|
4151
4175
|
});
|
|
4152
|
-
throw
|
|
4176
|
+
throw core_AxiosError.from(err, err && err.code, config, request);
|
|
4153
4177
|
}
|
|
4154
4178
|
});
|
|
4155
4179
|
const knownAdapters = {
|
|
@@ -4186,7 +4210,7 @@ const adapters_adapters = {
|
|
|
4186
4210
|
adapter = nameOrAdapter;
|
|
4187
4211
|
if (!isResolvedHandle(nameOrAdapter)) {
|
|
4188
4212
|
adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
|
|
4189
|
-
if (void 0 === adapter) throw new
|
|
4213
|
+
if (void 0 === adapter) throw new core_AxiosError(`Unknown adapter '${id}'`);
|
|
4190
4214
|
}
|
|
4191
4215
|
if (adapter) break;
|
|
4192
4216
|
rejectedReasons[id || '#' + i] = adapter;
|
|
@@ -4194,7 +4218,7 @@ const adapters_adapters = {
|
|
|
4194
4218
|
if (!adapter) {
|
|
4195
4219
|
const reasons = Object.entries(rejectedReasons).map(([id, state])=>`adapter ${id} ` + (false === state ? 'is not supported by the environment' : 'is not available in the build'));
|
|
4196
4220
|
let s = length ? reasons.length > 1 ? 'since :\n' + reasons.map(renderReason).join('\n') : ' ' + renderReason(reasons[0]) : 'as no adapter specified';
|
|
4197
|
-
throw new
|
|
4221
|
+
throw new core_AxiosError("There is no suitable adapter to dispatch the request " + s, 'ERR_NOT_SUPPORT');
|
|
4198
4222
|
}
|
|
4199
4223
|
return adapter;
|
|
4200
4224
|
},
|
|
@@ -4250,7 +4274,7 @@ validators.transitional = function(validator, version, message) {
|
|
|
4250
4274
|
return '[Axios v' + VERSION + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
|
|
4251
4275
|
}
|
|
4252
4276
|
return (value, opt, opts)=>{
|
|
4253
|
-
if (false === validator) throw new
|
|
4277
|
+
if (false === validator) throw new core_AxiosError(formatMessage(opt, ' has been removed' + (version ? ' in ' + version : '')), core_AxiosError.ERR_DEPRECATED);
|
|
4254
4278
|
if (version && !deprecatedWarnings[opt]) {
|
|
4255
4279
|
deprecatedWarnings[opt] = true;
|
|
4256
4280
|
console.warn(formatMessage(opt, ' has been deprecated since v' + version + ' and will be removed in the near future'));
|
|
@@ -4265,7 +4289,7 @@ validators.spelling = function(correctSpelling) {
|
|
|
4265
4289
|
};
|
|
4266
4290
|
};
|
|
4267
4291
|
function assertOptions(options, schema, allowUnknown) {
|
|
4268
|
-
if ('object' != typeof options) throw new
|
|
4292
|
+
if ('object' != typeof options) throw new core_AxiosError('options must be an object', core_AxiosError.ERR_BAD_OPTION_VALUE);
|
|
4269
4293
|
const keys = Object.keys(options);
|
|
4270
4294
|
let i = keys.length;
|
|
4271
4295
|
while(i-- > 0){
|
|
@@ -4274,10 +4298,10 @@ function assertOptions(options, schema, allowUnknown) {
|
|
|
4274
4298
|
if (validator) {
|
|
4275
4299
|
const value = options[opt];
|
|
4276
4300
|
const result = void 0 === value || validator(value, opt, options);
|
|
4277
|
-
if (true !== result) throw new
|
|
4301
|
+
if (true !== result) throw new core_AxiosError('option ' + opt + ' must be ' + result, core_AxiosError.ERR_BAD_OPTION_VALUE);
|
|
4278
4302
|
continue;
|
|
4279
4303
|
}
|
|
4280
|
-
if (true !== allowUnknown) throw new
|
|
4304
|
+
if (true !== allowUnknown) throw new core_AxiosError('Unknown option ' + opt, core_AxiosError.ERR_BAD_OPTION);
|
|
4281
4305
|
}
|
|
4282
4306
|
}
|
|
4283
4307
|
const helpers_validator = {
|
|
@@ -4605,7 +4629,7 @@ axios.CancelToken = CancelToken;
|
|
|
4605
4629
|
axios.isCancel = isCancel;
|
|
4606
4630
|
axios.VERSION = VERSION;
|
|
4607
4631
|
axios.toFormData = helpers_toFormData;
|
|
4608
|
-
axios.AxiosError =
|
|
4632
|
+
axios.AxiosError = core_AxiosError;
|
|
4609
4633
|
axios.Cancel = axios.CanceledError;
|
|
4610
4634
|
axios.all = function(promises) {
|
|
4611
4635
|
return Promise.all(promises);
|
|
@@ -4711,4 +4735,4 @@ const getPropertyName = (property, options)=>{
|
|
|
4711
4735
|
names = names.filter(Boolean);
|
|
4712
4736
|
return names.length > 0 ? names.join(' ') : 'Nill';
|
|
4713
4737
|
};
|
|
4714
|
-
export { ASSIGN_UNKNOWN_TO_CUSTOMER, account_period_constant_AccountPeriodStatus as AccountPeriodStatus, account_type_constant_AccountType as AccountType, common_status_constant_AccountingCommonStatus as AccountingCommonStatus, AccountingCommonSyncStatus, AmmoZeptoBankAccounts, AmmoZeptoClient, CmaPayoutTransactionType, CmaReceiptTransactionType, CmaStatus, cma_input_type_constant_CmaTransactionCreateType as CmaTransactionCreateType, CmaTransactionCreateTypeToDisplayText, cma_input_type_constant_CmaTransactionInputType as CmaTransactionInputType, CmaTransactionInputTypeToDisplayText, cma_payment_method_constant_CmaTransactionPaymentMethod as CmaTransactionPaymentMethod, CmaTransactionStatus, CmaTransactionStatusToDisplayTextMapper, CmaTransactionType, CmaTransactionTypeToDisplayTextMapper, DATE_FORMATS, DEFAULT_DATE_FORMAT, DEFAULT_DATE_FORMAT_WITH_TIME, DEFAULT_DATE_TIME_ZONE, DEFAULT_PAYOUT_SOURCE_BANK_REF, DEFAULT_PAYOUT_SOURCE_DESCRIPTION, DEFAULT_PAYOUT_TARGET_BANK_REF, DEFAULT_PAYOUT_TARGET_DESCRIPTION, InputJsonValueSchema, JsonNullableFilterSchema, MenuStatus, MenuType, MtaCustomerTransactionType, MtaPayoutTransactionType, MtaReceiptTransactionType, mta_MtaStatus as MtaStatus, MtaTransactionExtendedStatus, MtaTransactionExtendedStatusToDisplayTextMapper, mta_input_type_constant_MtaTransactionInputType as MtaTransactionInputType, MtaTransactionInputTypeToDisplayText, mta_payment_method_constant_MtaTransactionPaymentMethod as MtaTransactionPaymentMethod, MtaTransactionStatus, MtaTransactionStatusToDisplayTextMapper, MtaTransactionType, MtaTransactionTypeToDisplayTextMapper, MtaUnknownTransactionType, payment_method_constant_PaymentMethod as PaymentMethod, PayoutBankFileStatus, payout_constant_PayoutSourceAccountType as PayoutSourceAccountType, PayoutStatus, payout_constant_PayoutTargetAccountType as PayoutTargetAccountType, PayoutType, ProjectApplyStatusRestRes, ProjectMtaAllocationStatus, PropertyRestResStatus, PropertyStage, QueryMode, reconcile_transaction_action_constant_ReconcileTransactionAction as ReconcileTransactionAction, reconciliation_constant_ReconciliationStatus as ReconciliationStatus, report_data_range_type_constant_ReportDataRangeType as ReportDataRangeType, report_group_type_constant_ReportGroupType as ReportGroupType, sort_order_constant_SortOrder as SortOrder, StringFilterBaseSchema, TRANSACTION_CANCEL, accountBsbFormattedSchema, accountBsbMaskedSchema, accountBsbValidationSchema, accountNumberMaskedSchema, accountNumberValidationSchema, allocateMtaToProjectRestReqSchema, approveMtaAllocationRestReqSchema, assignUnknownReceiptToPropertyRestReqSchema, balanceRestResSchema, bankCodeSchema, bankReconciliationSummaryRestReqSchema, bigIntFilterSchema, bigIntNullableFilterSchema, boolFilterBaseSchema, boolFilterSchema, cancelCmaTransactionRestReqSchema, cancelMtaTransactionRestReqSchema, cancelPayoutPaymentRestReqSchema, cancelPayoutRestReqSchema, centsToDollarsSchema, cmaAccountPeriodCloseRestReqSchema, cmaAccountPeriodClosingSummaryRestReqSchema, cmaAccountPeriodClosingSummaryRestResSchema, cmaAccountPeriodEntitySchema, cmaAccountPeriodRestResBaseSchema, cmaAccountPeriodRestResSchema, cmaClosedAccountPeriodRestResSchema, cmaEntitySchema, cmaReconciledTransactionEntitySchema, cmaReconciledTransactionRestResSchema, cmaReconciliationEntitySchema, cmaReconciliationRestResSchema, cmaRestResBaseSchema, cmaRestResSchema, cmaSearchRestReqSchema, cmaSettlementPayoutRestResSchema, cmaTransactionEntitySchema, cmaTransactionRestResBaseSchema, cmaTransactionRestResSchema, cmaTransactionSearchRestReqSchema, commonPayoutSourceDetailEntitySchema, commonPayoutTargetDetailEntitySchema, commonReportRestReqSchema, commonReportWithCmaSelectionRestReqSchema, commonUpdatePayoutRestReqSchema, commonUpdatePayoutTargetDetailRestReqSchema, confirmPayoutBankFileProcessedRestReqSchema, createCmaReconciliationRestReqSchema, createCmaRestReqSchema, createCmaTransactionRestReqSchema, createMenuRestReqSchema, createMtaReconciliationRestReqSchema, createMtaRestReqSchema, createMtaToCmaPayoutRestReqSchema, createMtaTransactionRestReqSchema, createSettlementPayoutRestReqSchema, createSettlementPayoutSourceAccountSchema, createSettlementPayoutTargetAccountSchema, createUnknownPayoutRestReqSchema, customerEntitySchema, customerLedgerRestReqSchema, dateTimeFilterBaseSchema, dateTimeFilterSchema, developerEntitySchema, displayBankAccount, dollarsToCentsSchema,
|
|
4738
|
+
export { ASSIGN_UNKNOWN_TO_CUSTOMER, account_period_constant_AccountPeriodStatus as AccountPeriodStatus, account_type_constant_AccountType as AccountType, common_status_constant_AccountingCommonStatus as AccountingCommonStatus, AccountingCommonSyncStatus, AmmoZeptoBankAccounts, AmmoZeptoClient, CmaPayoutTransactionType, CmaReceiptTransactionType, CmaStatus, cma_input_type_constant_CmaTransactionCreateType as CmaTransactionCreateType, CmaTransactionCreateTypeToDisplayText, cma_input_type_constant_CmaTransactionInputType as CmaTransactionInputType, CmaTransactionInputTypeToDisplayText, cma_payment_method_constant_CmaTransactionPaymentMethod as CmaTransactionPaymentMethod, CmaTransactionStatus, CmaTransactionStatusToDisplayTextMapper, CmaTransactionType, CmaTransactionTypeToDisplayTextMapper, DATE_FORMATS, DEFAULT_DATE_FORMAT, DEFAULT_DATE_FORMAT_WITH_TIME, DEFAULT_DATE_TIME_ZONE, DEFAULT_PAYOUT_SOURCE_BANK_REF, DEFAULT_PAYOUT_SOURCE_DESCRIPTION, DEFAULT_PAYOUT_TARGET_BANK_REF, DEFAULT_PAYOUT_TARGET_DESCRIPTION, InputJsonValueSchema, JsonNullableFilterSchema, MenuStatus, MenuType, MtaCustomerTransactionType, MtaPayoutTransactionType, MtaReceiptTransactionType, mta_MtaStatus as MtaStatus, MtaTransactionExtendedStatus, MtaTransactionExtendedStatusToDisplayTextMapper, mta_input_type_constant_MtaTransactionInputType as MtaTransactionInputType, MtaTransactionInputTypeToDisplayText, mta_payment_method_constant_MtaTransactionPaymentMethod as MtaTransactionPaymentMethod, MtaTransactionStatus, MtaTransactionStatusToDisplayTextMapper, MtaTransactionType, MtaTransactionTypeToDisplayTextMapper, MtaUnknownTransactionType, payment_method_constant_PaymentMethod as PaymentMethod, PayoutBankFileStatus, payout_constant_PayoutSourceAccountType as PayoutSourceAccountType, PayoutStatus, payout_constant_PayoutTargetAccountType as PayoutTargetAccountType, PayoutType, ProjectApplyStatusRestRes, ProjectMtaAllocationStatus, PropertyRestResStatus, PropertyStage, QueryMode, reconcile_transaction_action_constant_ReconcileTransactionAction as ReconcileTransactionAction, reconciliation_constant_ReconciliationStatus as ReconciliationStatus, report_data_range_type_constant_ReportDataRangeType as ReportDataRangeType, report_group_type_constant_ReportGroupType as ReportGroupType, sort_order_constant_SortOrder as SortOrder, StringFilterBaseSchema, TRANSACTION_CANCEL, accountBsbFormattedSchema, accountBsbMaskedSchema, accountBsbValidationSchema, accountNumberMaskedSchema, accountNumberValidationSchema, allocateMtaToProjectRestReqSchema, approveMtaAllocationRestReqSchema, assignUnknownReceiptToPropertyRestReqSchema, balanceRestResSchema, bankCodeSchema, bankReconciliationSummaryRestReqSchema, bigIntFilterSchema, bigIntNullableFilterSchema, boolFilterBaseSchema, boolFilterSchema, cancelCmaTransactionRestReqSchema, cancelMtaTransactionRestReqSchema, cancelPayoutPaymentRestReqSchema, cancelPayoutRestReqSchema, centsToDollarsSchema, cmaAccountPeriodCloseRestReqSchema, cmaAccountPeriodClosingSummaryRestReqSchema, cmaAccountPeriodClosingSummaryRestResSchema, cmaAccountPeriodEntitySchema, cmaAccountPeriodRestResBaseSchema, cmaAccountPeriodRestResSchema, cmaClosedAccountPeriodRestResSchema, cmaEntitySchema, cmaReconciledTransactionEntitySchema, cmaReconciledTransactionRestResSchema, cmaReconciliationEntitySchema, cmaReconciliationRestResSchema, cmaRestResBaseSchema, cmaRestResSchema, cmaSearchRestReqSchema, cmaSettlementPayoutRestResSchema, cmaTransactionEntitySchema, cmaTransactionRestResBaseSchema, cmaTransactionRestResSchema, cmaTransactionSearchRestReqSchema, commonPayoutSourceDetailEntitySchema, commonPayoutTargetDetailEntitySchema, commonReportRestReqSchema, commonReportWithCmaSelectionRestReqSchema, commonUpdatePayoutRestReqSchema, commonUpdatePayoutTargetDetailRestReqSchema, confirmPayoutBankFileProcessedRestReqSchema, createCmaReconciliationRestReqSchema, createCmaRestReqSchema, createCmaTransactionRestReqSchema, createMenuRestReqSchema, createMtaReconciliationRestReqSchema, createMtaRestReqSchema, createMtaToCmaPayoutRestReqSchema, createMtaTransactionRestReqSchema, createSettlementPayoutRestReqSchema, createSettlementPayoutSourceAccountSchema, createSettlementPayoutTargetAccountSchema, createUnknownPayoutRestReqSchema, customerEntitySchema, customerLedgerRestReqSchema, dateTimeFilterBaseSchema, dateTimeFilterSchema, developerEntitySchema, displayBankAccount, dollarsToCentsSchema, extendDayjs, formatBankBsb, formatCurrency, fromCentsToDollars, fromDollarsToCents, generateMtaPaymentMethodAccountConfigForZepto, generateMtaPaymentMethodFloatAccountConfigForZepto, getPropertyName, getTransactionAmountStr, getTransactionNumber, getTransactionStatus, intFilterSchema, intNullableFilterSchema, isInterestTransaction, isPaymentTransaction, isReceiptTransaction, isTransactionAssignable, isTransactionCancelable, isUnknownReceiptAssignedToProperty, isUnknownTransaction, markCmaTransactionAsClearedRestReqSchema, maskBankAccount, maskBankAccountNumber, maskBankBsb, maskString, menuRestResSchema, menuSchema, mtaAccountPeriodCloseRestReqSchema, mtaAccountPeriodClosingSummaryRestReqSchema, mtaAccountPeriodClosingSummaryRestResSchema, mtaAccountPeriodEntitySchema, mtaAccountPeriodRestResSchema, mtaClosedAccountPeriodRestResSchema, mtaEntitySchema, mtaListItemRestResSchema, mtaPaymentMethodAccountConfigSchema, mtaPaymentMethodEntitySchema, mtaPaymentMethodFloatAccountConfigSchema, mtaPaymentMethodRestResSchema, mtaReconciledTransactionEntitySchema, mtaReconciledTransactionRestResSchema, mtaReconciliationEntitySchema, mtaReconciliationRestResSchema, mtaRestResBaseSchema, mtaRestResSchema, mtaSettlementPayoutRestResSchema, mtaToCmaPayoutPaymentEntitySchema, mtaToCmaPayoutPaymentRestSchema, mtaToCmaPayoutProvisionDataEntitySchema, mtaToCmaPayoutProvisionDataRestSchema, mtaToCmaPayoutRestResSchema, mtaToCmaPayoutSourceDetailEntitySchema, mtaToCmaPayoutSourceDetailRestSchema, mtaToCmaPayoutTargetDetailEntitySchema, mtaToCmaPayoutTargetDetailRestSchema, mtaTransactionEntitySchema, mtaTransactionNestedSchema, mtaTransactionRestResBaseSchema, mtaTransactionRestResSchema, mtaTransactionSearchRestReqSchema, mtaTransactionStatusSummaryRestResSchema, paginatedResSchema, paginationReqSchema, parseToDate, parseToDayjs, paymentListReportRestReqSchema, paymentProviderEntitySchema, payoutBankFileDownloadHistoryEntitySchema, payoutBankFileEntitySchema, payoutBankFileRestResSchema, payoutEntitySchema, payoutProvisionDataEntitySchema, payoutRestResBaseSchema, payoutRestResSchema, payoutSearchRestReqSchema, payoutStatusSummaryRestResSchema, payoutTransactionEntitySchema, payoutTransactionRestResSchema, payoutTransactionSearchRestReqSchema, payoutUpdateRestReqSchema, projectEntitySchema, projectLedgerRestReqSchema, projectMtaAllocationEntitySchema, projectMtaAllocationRestResSchema, projectNestedEntitySchema, projectRestResSchema, propertyAccountsBalanceRestResSchema, propertyEntitySchema, propertyNestedEntitySchema, propertyRestResBaseSchema, propertyRestResSchema, propertySearchRestReqSchema, queryModeSchema, receiptListReportRestReqSchema, reconcileCmaTransactionRestReqSchema, reconcileMtaTransactionRestReqSchema, reconciledItemsListReportRestReqSchema, safeParseDateFromStr, settlementPayoutPaymentEntitySchema, settlementPayoutProvisionDataEntitySchema, settlementPayoutRestResSchema, settlementPayoutSourceDetailEntitySchema, settlementPayoutTargetDetailEntitySchema, simpleStringFilterSchema, sortReqSchema, stateCodeSchema, stringFilterSchema, stringToBoolSchema, stringToDateSchema, stringToEndOfDaySchema, stringToStartOfDaySchema, trustTrialBalanceReportRestReqSchema, unknownPayoutPaymentEntitySchema, unknownPayoutProvisionDataEntitySchema, unknownPayoutRestResSchema, unknownPayoutSourceDetailEntitySchema, unknownPayoutTargetDetailEntitySchema, unknownReceiptLedgerRestReqSchema, unreconciledItemsListReportRestReqSchema, updateCmaOpenReconciliationCurrentBankStatementBalanceRestReqSchema, updateCmaSettlementPayoutRestReqSchema, updateMenuRestReqSchema, updateMtaRestReqSchema, updateMtaSettlementPayoutRestReqSchema, updateMtaToCmaPayoutRestReqSchema, updateOpenReconciliationCurrentBankStatementBalanceRestReqSchema, updateSettlementPayoutRestReqSchema, updateUnknownPayoutRestReqSchema, updateUnknownPayoutTargetDetailRestReqSchema, userEntitySchema, userRestResSchema };
|