@zeniai/client-epic-state 4.11.95 → 4.11.96
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/lib/entity/company/companyPayload.d.ts +8 -0
- package/lib/entity/company/companyPayload.js +2 -0
- package/lib/entity/company/companyStateTypes.d.ts +2 -0
- package/lib/index.d.ts +0 -2
- package/lib/view/billPayCard/fetchBillPayCardEpic.js +1 -1
- package/lib/view/reimbursementCard/fetchReimbursementCardEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billDetailView/epics/approveOrRejectBillEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billDetailView/epics/cancelAndDeleteBillEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billDetailView/epics/deleteBillEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billDetailView/epics/fetchBillDetailEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billList/fetchBillListPerTabEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billPayConfig/fetchBillPayConfigEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billsBulkActionView/epics/approveOrRejectBillsBulkActionEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billsBulkActionView/epics/cancelOrDeleteBillsBulkActionEpic.js +1 -1
- package/lib/view/spendManagement/billPay/billsBulkActionView/epics/reviewDraftBillsBulkActionEpic.ts.js +1 -1
- package/lib/view/spendManagement/billPay/billsBulkActionView/epics/submitDraftBillsBulkActionEpic.js +1 -1
- package/lib/view/spendManagement/billPay/editBillView/epics/convertAmountToHomeCurrencyEpic.js +1 -1
- package/lib/view/spendManagement/billPay/editBillView/epics/saveBillDetailEpic.js +1 -1
- package/lib/view/spendManagement/billPay/magicLinkView/epics/fetchMagicLinkBillEpic.js +1 -1
- package/lib/view/spendManagement/billPay/previousBills/fetchPreviousBillsEpic.js +1 -1
- package/lib/view/spendManagement/commonHistoryView/fetchEntityHistoryEpic.js +1 -1
- package/lib/view/spendManagement/plaidAccount/epic/paymentAccounts/updateMappedCashAccountEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/editRemiView/epics/fetchCurrencyConversionValueEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/editRemiView/epics/saveRemiDetailEpic.js +2 -2
- package/lib/view/spendManagement/reimbursement/reimbursementConfig/fetchReimbursementConfigEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiDetailView/epics/approveOrRejectRemiEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiDetailView/epics/cancelAndDeleteRemiEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiDetailView/epics/deleteRemiEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiDetailView/epics/fetchDuplicateReimbursementEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiDetailView/epics/fetchRemiDetailEpic.js +1 -1
- package/lib/view/spendManagement/reimbursement/remiListView/fetchRemiListPerTabEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/checkDeposit/checkDepositEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountHistoryEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/updateDepositAccountEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/depositAccountList/fetchDepositAccountListEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/depositAccountTransactionList/fetchDepositAccountTransactionListEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/transferDetail/fetchReviewTransferDetailEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/transferDetail/transferMoneyEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/zeniAccountList/createCheckingAccountEpic.js +1 -1
- package/lib/view/spendManagement/zeniAccounts/zeniAccountList/zeniAccountListSelector.d.ts +4 -1
- package/lib/view/spendManagement/zeniAccounts/zeniAccountList/zeniAccountListSelector.js +5 -1
- package/lib/view/spendManagement/zeniAccounts/zeniAccountsConfig/fetchZeniAccountsConfigEpic.js +1 -1
- package/lib/view/zeniAccStatementList/fetchZeniAccStatementListEpic.js +2 -2
- package/lib/view/zeniAccountsPromoCard/zeniAccountsPromoCardEpic.js +1 -1
- package/lib/zeniAPI.d.ts +0 -2
- package/package.json +1 -1
- package/lib/commonStateTypes/animations.d.ts +0 -2
- package/lib/commonStateTypes/animations.js +0 -32
|
@@ -89,6 +89,14 @@ export interface CompanyBillPayInfoDataPayload {
|
|
|
89
89
|
code: string | null;
|
|
90
90
|
name: string | null;
|
|
91
91
|
};
|
|
92
|
+
bill_payment_account_setup_status: {
|
|
93
|
+
code: string | null;
|
|
94
|
+
name: string | null;
|
|
95
|
+
};
|
|
96
|
+
bill_payment_method_type: {
|
|
97
|
+
code: string | null;
|
|
98
|
+
name: string | null;
|
|
99
|
+
};
|
|
92
100
|
schedule_pay_now_cutoff_time_by_payment_method: BillPayNowCutOffByMethodPayload;
|
|
93
101
|
primary_funding_account: {
|
|
94
102
|
account_id: string | null;
|
|
@@ -143,6 +143,8 @@ const toCompanyBillPayInfo = (payload) => {
|
|
|
143
143
|
usersSelectedForVerification: payload.users_for_verification,
|
|
144
144
|
businessVerificationStatus: (0, exports.toAllowedValueWithCode)(payload.business_verification_status),
|
|
145
145
|
companyVerificationStatus: (0, exports.toAllowedValueWithCode)(payload.company_verification_status),
|
|
146
|
+
billPaymentAccountSetupStatus: (0, exports.toAllowedValueWithCode)(payload.bill_payment_account_setup_status),
|
|
147
|
+
billPaymentMethodType: (0, exports.toAllowedValueWithCode)(payload.bill_payment_method_type),
|
|
146
148
|
payNowCutOffTimeByMethod: (0, exports.toPayNowCutOffByMethod)(payload.schedule_pay_now_cutoff_time_by_payment_method),
|
|
147
149
|
primaryFundingAccount: payload.primary_funding_account.account_id != null &&
|
|
148
150
|
payload.primary_funding_account.account_type != null
|
|
@@ -164,6 +164,8 @@ export interface CompanyBillPayInfo {
|
|
|
164
164
|
isInternationalWireEnabled: boolean;
|
|
165
165
|
businessVerificationStatus?: AllowedValueWithCode;
|
|
166
166
|
companyVerificationStatus?: AllowedValueWithCode;
|
|
167
|
+
billPaymentAccountSetupStatus?: AllowedValueWithCode;
|
|
168
|
+
billPaymentMethodType?: AllowedValueWithCode;
|
|
167
169
|
payNowCutOffTimeByMethod: BillPayNowCutOffByMethod;
|
|
168
170
|
primaryFundingAccount?: {
|
|
169
171
|
accountId: ID;
|
package/lib/index.d.ts
CHANGED
|
@@ -471,8 +471,6 @@ import { OnboardingCustomerListUIState } from './view/onboardingView/cockpitView
|
|
|
471
471
|
import { reduceFetchState, reduceAnyFetchState, reduceAllFetchState, reduceAnyCompletedFetchState, isAnyFetchInProgress, isAllFetchCompleted } from './commonStateTypes/reduceFetchState';
|
|
472
472
|
import { SortOrder } from './commonStateTypes/selectorTypes/sortOrderTypes';
|
|
473
473
|
import { ALL_FILE_TYPES, FileType, toFileTypeStrict } from './commonStateTypes/fileType';
|
|
474
|
-
import { AnimationFileName } from './commonStateTypes/animations';
|
|
475
|
-
export { AnimationFileName };
|
|
476
474
|
import { getNextNthWorkingDay, getPreviousNthWorkingDay, isHolidayToday, filterDays, getYearsList, holidaysFormatted, isHoliday, PAYMENT_BUSINESS_DAYS } from './commonStateTypes/workingDayHelper';
|
|
477
475
|
export { reduceFetchState, reduceAnyFetchState, reduceAllFetchState, reduceAnyCompletedFetchState, isAnyFetchInProgress, isAllFetchCompleted, SortOrder, ALL_FILE_TYPES, FileType, toFileTypeStrict, };
|
|
478
476
|
export { getNextNthWorkingDay, getPreviousNthWorkingDay, isHolidayToday, filterDays, getYearsList, isHoliday, holidaysFormatted, PAYMENT_BUSINESS_DAYS, };
|
|
@@ -33,7 +33,7 @@ const fetchBillPayCardEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, o
|
|
|
33
33
|
is_include_pending_approval_transaction_ids_for_user: true,
|
|
34
34
|
};
|
|
35
35
|
return zeniAPI
|
|
36
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
36
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bill-pay-card?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
37
37
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
38
38
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
39
39
|
return (0, rxjs_1.of)((0, billPayCardReducer_1.updateBillPayCard)({
|
|
@@ -28,7 +28,7 @@ const fetchReimbursementCardEpic = (actions$, _state$, zeniAPI) => actions$.pipe
|
|
|
28
28
|
get_count_only: true,
|
|
29
29
|
};
|
|
30
30
|
return zeniAPI
|
|
31
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
31
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursement-card?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
32
32
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
33
33
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
34
34
|
return (0, rxjs_1.of)((0, reimbursementCardReducer_1.updateReimbursementCard)({
|
|
@@ -16,7 +16,7 @@ const approveOrRejectBillEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
|
|
|
16
16
|
description,
|
|
17
17
|
};
|
|
18
18
|
return zeniAPI
|
|
19
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
19
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}/approval-status`, payload)
|
|
20
20
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
21
21
|
var _a, _b;
|
|
22
22
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
@@ -20,7 +20,7 @@ const cancelAndDeleteBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
|
|
|
20
20
|
const transaction = billTransactionState.transactionById[action.payload.billId];
|
|
21
21
|
const isRecurring = (_a = transaction === null || transaction === void 0 ? void 0 : transaction.isRecurring) !== null && _a !== void 0 ? _a : false;
|
|
22
22
|
const recurringConfigId = transaction === null || transaction === void 0 ? void 0 : transaction.recurringBillConfigId;
|
|
23
|
-
let cancelApiUrl = `${zeniAPI.apiEndPoints.
|
|
23
|
+
let cancelApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
|
|
24
24
|
if (isRecurring === true) {
|
|
25
25
|
cancelApiUrl = `${cancelApiUrl}/recurring/cancel-payment`;
|
|
26
26
|
}
|
|
@@ -20,7 +20,7 @@ const deleteBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operator
|
|
|
20
20
|
const transaction = billTransactionState.transactionById[action.payload.billId];
|
|
21
21
|
const isRecurring = (_a = transaction === null || transaction === void 0 ? void 0 : transaction.isRecurring) !== null && _a !== void 0 ? _a : false;
|
|
22
22
|
const recurringConfigId = transaction === null || transaction === void 0 ? void 0 : transaction.recurringBillConfigId;
|
|
23
|
-
let deleteApiUrl = `${zeniAPI.apiEndPoints.
|
|
23
|
+
let deleteApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
|
|
24
24
|
if (isRecurring === true) {
|
|
25
25
|
deleteApiUrl = `${deleteApiUrl}/recurring`;
|
|
26
26
|
}
|
|
@@ -53,7 +53,7 @@ const fetchBillDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, ope
|
|
|
53
53
|
is_include_deleted: isShowDeletedBillsEnabled,
|
|
54
54
|
};
|
|
55
55
|
const getTransactionDetail$ = zeniAPI
|
|
56
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
56
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}?query=${encodeURIComponent(JSON.stringify(query))}`)
|
|
57
57
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
58
58
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
|
|
59
59
|
if ((0, responsePayload_1.isSuccessResponse)(response) &&
|
|
@@ -25,7 +25,7 @@ const fetchBillListPerTabEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
|
|
|
25
25
|
is_include_deleted: isShowDeletedBillsEnabled ? tab !== 'draft' : false,
|
|
26
26
|
};
|
|
27
27
|
return zeniAPI
|
|
28
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
28
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
29
29
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
30
30
|
var _a, _b;
|
|
31
31
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
@@ -13,7 +13,7 @@ const fetchBillPayConfigEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0,
|
|
|
13
13
|
is_include_payment_accounts_info: true,
|
|
14
14
|
};
|
|
15
15
|
return zeniAPI
|
|
16
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
16
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bill-pay/config?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
17
17
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
18
18
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
19
19
|
const updateActions = [];
|
|
@@ -13,7 +13,7 @@ const approveOrRejectBillsBulkActionEpic = (actions$, state$, zeniAPI) => action
|
|
|
13
13
|
const transactionIds = billsBulkActionViewState.billsSelectedForBulkAction;
|
|
14
14
|
const payload = prepareBulkApproveOrRejectPayload(transactionIds, approvalType, description);
|
|
15
15
|
return zeniAPI
|
|
16
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
16
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`, payload)
|
|
17
17
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
18
18
|
var _a, _b, _c, _d, _e, _f;
|
|
19
19
|
if ((0, responsePayload_1.isSuccessStatus)(response)) {
|
|
@@ -12,7 +12,7 @@ const cancelOrDeleteBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions
|
|
|
12
12
|
const { billsBulkActionViewState } = state$.value;
|
|
13
13
|
const transactionIds = billsBulkActionViewState.billsSelectedForBulkAction;
|
|
14
14
|
const payload = prepareBulkCancelOrDeletePayload(transactionIds, operationType, description);
|
|
15
|
-
const bulkApiUrl = `${zeniAPI.apiEndPoints.
|
|
15
|
+
const bulkApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
|
|
16
16
|
const api = operationType === 'cancel'
|
|
17
17
|
? zeniAPI.putAndGetJSON(bulkApiUrl, payload)
|
|
18
18
|
: zeniAPI.deleteAndGetJSON(bulkApiUrl, payload);
|
|
@@ -12,7 +12,7 @@ const reviewDraftBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions$.p
|
|
|
12
12
|
entity_ids: transactionIds,
|
|
13
13
|
};
|
|
14
14
|
return zeniAPI
|
|
15
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
15
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills//transactions/validate?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
16
16
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
17
17
|
var _a, _b;
|
|
18
18
|
if ((0, responsePayload_1.isSuccessStatus)(response)) {
|
package/lib/view/spendManagement/billPay/billsBulkActionView/epics/submitDraftBillsBulkActionEpic.js
CHANGED
|
@@ -11,7 +11,7 @@ const editBillViewSelector_1 = require("../../editBillView/editBillViewSelector"
|
|
|
11
11
|
const submitDraftBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(billsBulkActionViewReducer_1.submitDraftBillsBulkAction.match), (0, operators_1.mergeMap)(() => {
|
|
12
12
|
const { billsBulkActionViewState, billTransactionState } = state$.value;
|
|
13
13
|
const payload = prepareBulkSubmitPayload(billsBulkActionViewState, billTransactionState);
|
|
14
|
-
const bulkApiUrl = `${zeniAPI.apiEndPoints.
|
|
14
|
+
const bulkApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
|
|
15
15
|
return zeniAPI
|
|
16
16
|
.putAndGetJSON(bulkApiUrl, payload)
|
|
17
17
|
.pipe((0, operators_1.mergeMap)((response) => {
|
package/lib/view/spendManagement/billPay/editBillView/epics/convertAmountToHomeCurrencyEpic.js
CHANGED
|
@@ -27,7 +27,7 @@ const convertAmountToHomeCurrencyEpic = (actions$, state$, zeniAPI) => actions$.
|
|
|
27
27
|
home_currency_code: conversionCurrencyCode,
|
|
28
28
|
};
|
|
29
29
|
return zeniAPI
|
|
30
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
30
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/currencies/conversion`, payload)
|
|
31
31
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
32
32
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
33
33
|
const updateActions = [];
|
|
@@ -32,7 +32,7 @@ const saveBillDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
|
|
|
32
32
|
: state.editBillDetailViewState.newBillState;
|
|
33
33
|
const payload = prepareSaveBillPayload(state.accountState, state.billTransactionState, state.paymentAccountState, state.recurringBillState, billDetail, billStageCode);
|
|
34
34
|
const isRecurringBill = billDetail.billDetailLocalData.isRecurring;
|
|
35
|
-
const saveBillBaseURL = `${zeniAPI.apiEndPoints.
|
|
35
|
+
const saveBillBaseURL = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions`;
|
|
36
36
|
const saveBillApi = billId != null
|
|
37
37
|
? zeniAPI.putAndGetJSON(getSaveBillApiURL(saveBillBaseURL, isRecurringBill, billId, state.billTransactionState), payload)
|
|
38
38
|
: zeniAPI.postAndGetJSON(getSaveBillApiURL(saveBillBaseURL, isRecurringBill), payload);
|
|
@@ -8,7 +8,7 @@ const responsePayload_1 = require("../../../../../responsePayload");
|
|
|
8
8
|
const attachmentPayload_1 = require("../../../../../entity/transaction/payloadTypes/attachmentPayload");
|
|
9
9
|
const fetchMagicLinkBillEpic = (actions$, _, zeniAPI) => actions$.pipe((0, operators_1.filter)(magicLinkViewReducer_1.fetchBillAttachment.match), (0, operators_1.mergeMap)((action) => {
|
|
10
10
|
const { billId } = action.payload;
|
|
11
|
-
let apiUrl = `${zeniAPI.apiEndPoints.
|
|
11
|
+
let apiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}`;
|
|
12
12
|
const queryParam = {
|
|
13
13
|
transaction_type: 'bill',
|
|
14
14
|
bill_pay_provider: 'zeni',
|
|
@@ -34,7 +34,7 @@ const fetchPreviousBillsEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
|
|
|
34
34
|
limit: 3,
|
|
35
35
|
};
|
|
36
36
|
return zeniAPI
|
|
37
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
37
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
38
38
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
39
39
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
40
40
|
const updateActions = [];
|
|
@@ -26,7 +26,7 @@ const fetchEntityHistoryEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
|
|
|
26
26
|
}));
|
|
27
27
|
const entityTypeInUrl = entityType === 'bill_pay' ? 'bill' : entityType;
|
|
28
28
|
const getHistoryDetail$ = zeniAPI
|
|
29
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
29
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/${entityTypeInUrl}s/transactions/${entityId}/history`)
|
|
30
30
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
31
31
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
32
32
|
return (0, rxjs_1.of)((0, commonHistoryReducer_1.updateCommonHistory)({
|
package/lib/view/spendManagement/plaidAccount/epic/paymentAccounts/updateMappedCashAccountEpic.js
CHANGED
|
@@ -9,7 +9,7 @@ const depositAccountReducer_1 = require("../../../../../entity/depositAccount/de
|
|
|
9
9
|
const updateMappedCashAccountEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(plaidAccountViewReducer_1.updateMappedCashAccount.match), (0, operators_1.mergeMap)((action) => {
|
|
10
10
|
const { plaidAccountKeyType, accountId, depositAccountId } = action.payload;
|
|
11
11
|
return zeniAPI
|
|
12
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
12
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}`, {
|
|
13
13
|
zeni_mapped_account_id: accountId,
|
|
14
14
|
})
|
|
15
15
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
@@ -25,7 +25,7 @@ const fetchCurrencyConversionValueEpic = (actions$, state$, zeniAPI) => actions$
|
|
|
25
25
|
home_currency_code: conversionCurrencyCode,
|
|
26
26
|
};
|
|
27
27
|
return zeniAPI
|
|
28
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
28
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/currencies/conversion`, payload)
|
|
29
29
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
30
30
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
31
31
|
const updateActions = [];
|
|
@@ -29,8 +29,8 @@ const saveRemiDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
|
|
|
29
29
|
: state.editRemiDetailViewState.newRemiState;
|
|
30
30
|
const payload = prepareSaveRemiPayload(state.reimbursementState, state.tenantState, remiDetail, remiStageCode, isSubmitted);
|
|
31
31
|
const saveVendorApi = reimbursementId != null
|
|
32
|
-
? zeniAPI.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
33
|
-
: zeniAPI.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
32
|
+
? zeniAPI.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}`, payload)
|
|
33
|
+
: zeniAPI.postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions`, payload);
|
|
34
34
|
return saveVendorApi.pipe((0, operators_1.mergeMap)((response) => {
|
|
35
35
|
var _a, _b, _c;
|
|
36
36
|
if ((0, responsePayload_1.isSuccessResponse)(response) &&
|
package/lib/view/spendManagement/reimbursement/reimbursementConfig/fetchReimbursementConfigEpic.js
CHANGED
|
@@ -8,7 +8,7 @@ const responsePayload_1 = require("../../../../responsePayload");
|
|
|
8
8
|
const currencyReducer_1 = require("../../../../entity/currency/currencyReducer");
|
|
9
9
|
const fetchReimbursementConfigEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(reimbursementConfigReducer_1.fetchReimbursementConfig.match), (0, operators_1.mergeMap)(() => {
|
|
10
10
|
return zeniAPI
|
|
11
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
11
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/config`)
|
|
12
12
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
13
13
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
14
14
|
const updateActions = [];
|
package/lib/view/spendManagement/reimbursement/remiDetailView/epics/approveOrRejectRemiEpic.js
CHANGED
|
@@ -16,7 +16,7 @@ const approveOrRejectRemiEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
|
|
|
16
16
|
description,
|
|
17
17
|
};
|
|
18
18
|
return zeniAPI
|
|
19
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
19
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}/approval-status`, payload)
|
|
20
20
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
21
21
|
var _a, _b;
|
|
22
22
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
package/lib/view/spendManagement/reimbursement/remiDetailView/epics/cancelAndDeleteRemiEpic.js
CHANGED
|
@@ -16,7 +16,7 @@ const cancelAndDeleteRemiEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
|
|
|
16
16
|
const { reimbursementState } = state$.value;
|
|
17
17
|
const transaction = reimbursementState.reimbursementById[action.payload.reimbursementId];
|
|
18
18
|
return zeniAPI
|
|
19
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
19
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}/cancel-payment`, query)
|
|
20
20
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
21
21
|
var _a, _b;
|
|
22
22
|
if (action.payload.isDeleteRemi === true &&
|
|
@@ -16,7 +16,7 @@ const deleteRemiEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operator
|
|
|
16
16
|
const { reimbursementState } = state$.value;
|
|
17
17
|
const transaction = reimbursementState.reimbursementById[action.payload.reimbursementId];
|
|
18
18
|
return zeniAPI
|
|
19
|
-
.deleteAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
19
|
+
.deleteAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
|
|
20
20
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
21
21
|
if ((0, responsePayload_1.isSuccessStatus)(response)) {
|
|
22
22
|
const actions = [
|
|
@@ -49,7 +49,7 @@ const fetchDuplicateReimbursementEpic = (actions$, state$, zeniAPI) => actions$.
|
|
|
49
49
|
lines: lines.map(reimbursementPayload_1.toReimbursementLinePayload),
|
|
50
50
|
};
|
|
51
51
|
return zeniAPI
|
|
52
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
52
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/duplicates`, payload)
|
|
53
53
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
54
54
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
55
55
|
const updateActions = [];
|
|
@@ -44,7 +44,7 @@ const fetchRemiDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, ope
|
|
|
44
44
|
is_include_deleted: isShowDeletedReimbursementEnabled,
|
|
45
45
|
};
|
|
46
46
|
const getTransactionDetail$ = zeniAPI
|
|
47
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
47
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
|
|
48
48
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
49
49
|
var _a, _b, _c, _d;
|
|
50
50
|
if ((0, responsePayload_1.isSuccessResponse)(response) &&
|
|
@@ -28,7 +28,7 @@ const fetchRemiListPerTabEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
|
|
|
28
28
|
is_include_line_items: isIncludeLineItems ? tab !== 'draft' : false,
|
|
29
29
|
};
|
|
30
30
|
return zeniAPI
|
|
31
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
31
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
32
32
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
33
33
|
var _a;
|
|
34
34
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
@@ -23,7 +23,7 @@ const checkDepositEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operat
|
|
|
23
23
|
check_back_file_id: checkBack === null || checkBack === void 0 ? void 0 : checkBack.fileId,
|
|
24
24
|
};
|
|
25
25
|
return zeniAPI
|
|
26
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
26
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${(_a = localData.depositTo) === null || _a === void 0 ? void 0 : _a.id}/check-deposits`, payload)
|
|
27
27
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
28
28
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
29
29
|
return (0, rxjs_1.of)((0, snackbarReducer_1.openSnackbar)({
|
package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountEpic.js
CHANGED
|
@@ -9,7 +9,7 @@ const depositAccountReducer_1 = require("../../../../entity/depositAccount/depos
|
|
|
9
9
|
const fetchDepositAccountEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(depositAccountDetailReducer_1.fetchDepositAccount.match), (0, operators_1.switchMap)((action) => {
|
|
10
10
|
const { depositAccountId } = action.payload;
|
|
11
11
|
return zeniAPI
|
|
12
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
12
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}?query=${encodeURIComponent(`{"is_include_deposit_accounts_summary":true}`)}`)
|
|
13
13
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
14
14
|
var _a, _b;
|
|
15
15
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountHistoryEpic.js
CHANGED
|
@@ -11,7 +11,7 @@ const fetchDepositAccountHistoryEpic = (actions$, _state$, zeniAPI) => actions$.
|
|
|
11
11
|
const today = (0, zeniDayJS_1.dateNow)().format('YYYY-MM-DD');
|
|
12
12
|
const payload = { start_date: '2022-01-01', end_date: today };
|
|
13
13
|
return zeniAPI
|
|
14
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
14
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}/balances/time-series?query=${encodeURIComponent(JSON.stringify(payload))}`)
|
|
15
15
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
16
16
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
17
17
|
return (0, rxjs_1.of)((0, depositAccountDetailReducer_1.fetchDepositAccountHistorySuccess)({
|
package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/updateDepositAccountEpic.js
CHANGED
|
@@ -13,7 +13,7 @@ const updateDepositAccountEpic = (actions$, _state$, zeniAPI) => actions$.pipe((
|
|
|
13
13
|
? { is_close_account: true }
|
|
14
14
|
: { account_name: nickname };
|
|
15
15
|
return zeniAPI
|
|
16
|
-
.putAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
16
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}`, payload)
|
|
17
17
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
18
18
|
var _a, _b;
|
|
19
19
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
package/lib/view/spendManagement/zeniAccounts/depositAccountList/fetchDepositAccountListEpic.js
CHANGED
|
@@ -9,7 +9,7 @@ const depositAccountReducer_1 = require("../../../../entity/depositAccount/depos
|
|
|
9
9
|
const zeniAccountListReducer_1 = require("../zeniAccountList/zeniAccountListReducer");
|
|
10
10
|
const fetchDepositAccountListEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(depositAccountListReducer_1.fetchDepositAccountList.match), (0, operators_1.switchMap)(() => {
|
|
11
11
|
return zeniAPI
|
|
12
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
12
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts?query=${encodeURIComponent(`{"is_include_deposit_accounts_summary":true}`)}`)
|
|
13
13
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
14
14
|
var _a, _b, _c, _d, _e;
|
|
15
15
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
@@ -27,7 +27,7 @@ const fetchDepositAccountTransactionListEpic = (actions$, state$, zeniAPI) => ac
|
|
|
27
27
|
queryParam = Object.assign(Object.assign({}, queryParam), { limit: count });
|
|
28
28
|
}
|
|
29
29
|
return zeniAPI
|
|
30
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
30
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
|
|
31
31
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
32
32
|
var _a, _b, _c, _d, _e, _f;
|
|
33
33
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
package/lib/view/spendManagement/zeniAccounts/transferDetail/fetchReviewTransferDetailEpic.js
CHANGED
|
@@ -24,7 +24,7 @@ const fetchReviewTransferDetailEpic = (actions$, state$, zeniAPI) => actions$.pi
|
|
|
24
24
|
currency_symbol: localData.amount.currencySymbol,
|
|
25
25
|
};
|
|
26
26
|
return zeniAPI
|
|
27
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
27
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/transfers/review`, payload)
|
|
28
28
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
29
29
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
30
30
|
return (0, rxjs_1.of)((0, transferDetailReducer_1.updateReviewTransferDetail)(response.data));
|
|
@@ -31,7 +31,7 @@ const transferMoneyEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, opera
|
|
|
31
31
|
},
|
|
32
32
|
};
|
|
33
33
|
return zeniAPI
|
|
34
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
34
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts-transfers`, payload)
|
|
35
35
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
36
36
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
37
37
|
const actions = [];
|
|
@@ -14,7 +14,7 @@ const createCheckingAccountEpic = (actions$, _state$, zeniAPI) => actions$.pipe(
|
|
|
14
14
|
account_name: action.payload.nickname,
|
|
15
15
|
};
|
|
16
16
|
return zeniAPI
|
|
17
|
-
.postAndGetJSON(`${zeniAPI.apiEndPoints.
|
|
17
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts`, payload)
|
|
18
18
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
19
19
|
var _a, _b, _c, _d, _e;
|
|
20
20
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import { AllowedValueWithCode } from '../../../../commonStateTypes/allowedValue';
|
|
2
|
+
import { ID } from '../../../../commonStateTypes/common';
|
|
1
3
|
import { SelectorView } from '../../../../commonStateTypes/viewAndReport/viewAndReport';
|
|
2
4
|
import { PaymentAccount } from '../../../../entity/paymentAccount/paymentAccountState';
|
|
3
5
|
import { RootState } from '../../../../reducer';
|
|
@@ -13,7 +15,8 @@ export interface ZeniAccountListSelectorView extends SelectorView {
|
|
|
13
15
|
plaidConnectionDetails: PlaidConnectionDetails;
|
|
14
16
|
newCheckingAccount: NewCheckingAccount;
|
|
15
17
|
zeniAccountsConfig: ZeniAccountsConfigSelectorView;
|
|
18
|
+
companyBillPayAccountSetupStatus?: AllowedValueWithCode;
|
|
16
19
|
paymentAccount?: PaymentAccount;
|
|
17
20
|
summary?: ZeniAccountSummaryWithBalance;
|
|
18
21
|
}
|
|
19
|
-
export declare const getZeniAccountList: (state: RootState) => ZeniAccountListSelectorView;
|
|
22
|
+
export declare const getZeniAccountList: (state: RootState, companyId: ID) => ZeniAccountListSelectorView;
|
|
@@ -3,14 +3,17 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.getZeniAccountList = void 0;
|
|
4
4
|
const depositAccountPayload_1 = require("../../../../entity/depositAccount/depositAccountPayload");
|
|
5
5
|
const paymentAccountSelector_1 = require("../../../../entity/paymentAccount/paymentAccountSelector");
|
|
6
|
+
const getCompanyView_1 = require("../../../companyView/selectorHelpers/getCompanyView");
|
|
6
7
|
const depositAccountListSelector_1 = require("../depositAccountList/depositAccountListSelector");
|
|
7
8
|
const paymentAccountListSelector_1 = require("../paymentAccountList/paymentAccountListSelector");
|
|
8
9
|
const zeniAccountsConfigSelector_1 = require("../zeniAccountsConfig/zeniAccountsConfigSelector");
|
|
9
|
-
const getZeniAccountList = (state) => {
|
|
10
|
+
const getZeniAccountList = (state, companyId) => {
|
|
10
11
|
const { zeniAccountListState, depositAccountState, paymentAccountState, plaidAccountViewState, depositAccountListState, paymentAccountListState, } = state;
|
|
11
12
|
const { plaidConnectionDetails } = plaidAccountViewState['external_account'];
|
|
12
13
|
const depositAccountsSelectorView = (0, depositAccountListSelector_1.getAllDepostAccounts)(depositAccountState, depositAccountListState);
|
|
13
14
|
const zeniAccountsConfig = (0, zeniAccountsConfigSelector_1.getZeniAccountsConfigDetail)(state);
|
|
15
|
+
const companyView = (0, getCompanyView_1.getCompanyView)(state, companyId, []);
|
|
16
|
+
const companyBillPayInfo = companyView === null || companyView === void 0 ? void 0 : companyView.company.company.companyBillPayInfo;
|
|
14
17
|
const { paymentAccountIds } = paymentAccountListState;
|
|
15
18
|
const externalAccountsSelectorView = (0, paymentAccountListSelector_1.getAllPaymentAccounts)(paymentAccountState, paymentAccountListState);
|
|
16
19
|
let summary = undefined;
|
|
@@ -46,6 +49,7 @@ const getZeniAccountList = (state) => {
|
|
|
46
49
|
zeniAccountsConfig,
|
|
47
50
|
plaidConnectionDetails,
|
|
48
51
|
externalAccountsSelectorView,
|
|
52
|
+
companyBillPayAccountSetupStatus: companyBillPayInfo === null || companyBillPayInfo === void 0 ? void 0 : companyBillPayInfo.billPaymentAccountSetupStatus,
|
|
49
53
|
newCheckingAccount: zeniAccountListState.newCheckingAccount,
|
|
50
54
|
fetchState: zeniAccountListState.currentTab.id === 'zeniAccounts'
|
|
51
55
|
? depositAccountsSelectorView.fetchState
|
package/lib/view/spendManagement/zeniAccounts/zeniAccountsConfig/fetchZeniAccountsConfigEpic.js
CHANGED
|
@@ -7,7 +7,7 @@ const zeniAccountsConfigReducer_1 = require("./zeniAccountsConfigReducer");
|
|
|
7
7
|
const addressReducer_1 = require("../../../../entity/address/addressReducer");
|
|
8
8
|
const responsePayload_1 = require("../../../../responsePayload");
|
|
9
9
|
const fetchZeniAccountsConfigEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(zeniAccountsConfigReducer_1.fetchZeniAccountsConfig.match), (0, operators_1.switchMap)(() => zeniAPI
|
|
10
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
10
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/baas/config`)
|
|
11
11
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
12
12
|
if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
|
|
13
13
|
const actions = [
|
|
@@ -8,8 +8,8 @@ const zeniAccStatementListReducer_1 = require("./zeniAccStatementListReducer");
|
|
|
8
8
|
const fetchZeniAccStatementListEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(zeniAccStatementListReducer_1.fetchZeniAccStatementList.match), (0, operators_1.mergeMap)((action) => {
|
|
9
9
|
const { depositAccountId } = action.payload;
|
|
10
10
|
const apiEndpoint = depositAccountId === 'zeni-clearing-account'
|
|
11
|
-
? `${zeniAPI.apiEndPoints.
|
|
12
|
-
: `${zeniAPI.apiEndPoints.
|
|
11
|
+
? `${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/zeni-clearing-account/statements`
|
|
12
|
+
: `${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}/statements`;
|
|
13
13
|
return zeniAPI.getJSON(apiEndpoint).pipe((0, operators_1.mergeMap)((response) => {
|
|
14
14
|
var _a, _b;
|
|
15
15
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
@@ -6,7 +6,7 @@ const operators_1 = require("rxjs/operators");
|
|
|
6
6
|
const zeniAccountsPromoCardReducer_1 = require("./zeniAccountsPromoCardReducer");
|
|
7
7
|
const responsePayload_1 = require("../../responsePayload");
|
|
8
8
|
const fetchZeniAccountsPromoCardEpic = (actions$, _, zeniAPI) => actions$.pipe((0, operators_1.filter)(zeniAccountsPromoCardReducer_1.fetchZeniAccountsPromoCard.match), (0, operators_1.switchMap)(() => zeniAPI
|
|
9
|
-
.getJSON(`${zeniAPI.apiEndPoints.
|
|
9
|
+
.getJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/promo-card`)
|
|
10
10
|
.pipe((0, operators_1.mergeMap)((response) => {
|
|
11
11
|
if ((0, responsePayload_1.isSuccessResponse)(response)) {
|
|
12
12
|
return (0, rxjs_1.of)((0, zeniAccountsPromoCardReducer_1.updateZeniAccountsPromoCard)(response.data) // eslint-disable-line @typescript-eslint/no-non-null-assertion
|
package/lib/zeniAPI.d.ts
CHANGED
|
@@ -7,11 +7,9 @@ export interface RESTAPIEndpoints {
|
|
|
7
7
|
readonly noAuthMicroServiceBaseUrl: string;
|
|
8
8
|
readonly tenantMicroServiceBaseUrl: string;
|
|
9
9
|
readonly accountMicroServiceBaseUrl: string;
|
|
10
|
-
readonly spendManagementMicroServiceBaseUrl: string;
|
|
11
10
|
readonly insightsMicroServiceBaseUrl: string;
|
|
12
11
|
readonly searchMicroServiceBaseUrl: string;
|
|
13
12
|
readonly payMicroServiceBaseUrl: string;
|
|
14
|
-
readonly bankingMicroServiceBaseUrl: string;
|
|
15
13
|
readonly fileMicroServiceBaseUrl: string;
|
|
16
14
|
readonly documentAIMicroServiceBaseUrl: string;
|
|
17
15
|
readonly approvalMicroServiceBaseUrl: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeniai/client-epic-state",
|
|
3
|
-
"version": "4.11.
|
|
3
|
+
"version": "4.11.96",
|
|
4
4
|
"description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"types": "lib/index.d.ts",
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
export declare const toAnimationsFileName: (v: string) => "AIPoweredInvoiceDark" | "AIPoweredInvoiceLight" | "Angry" | "Confetti" | "ConfettiExplosion" | "FastestWayDark" | "FastestWayLight" | "FinanceTeamDark" | "FinanceTeamLight" | "Happy" | "MoneyTransferSuccess" | "MultiLevelApprovalDark" | "MultiLevelApprovalLight" | "NotHappy" | "ReceiptDark" | "ReceiptLight" | "ReimburseDark" | "ReimburseLight" | "RewardsDark" | "RewardsDarkHover" | "RewardsLight" | "RewardsLightHover" | "Success" | "VeryHappy";
|
|
2
|
-
export declare type AnimationFileName = ReturnType<typeof toAnimationsFileName>;
|
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.toAnimationsFileName = void 0;
|
|
4
|
-
const stringToUnion_1 = require("./stringToUnion");
|
|
5
|
-
const ALL_ANIMATIONS_FILE_NAMES = [
|
|
6
|
-
'AIPoweredInvoiceDark',
|
|
7
|
-
'AIPoweredInvoiceLight',
|
|
8
|
-
'Angry',
|
|
9
|
-
'Confetti',
|
|
10
|
-
'ConfettiExplosion',
|
|
11
|
-
'FastestWayDark',
|
|
12
|
-
'FastestWayLight',
|
|
13
|
-
'FinanceTeamDark',
|
|
14
|
-
'FinanceTeamLight',
|
|
15
|
-
'Happy',
|
|
16
|
-
'MoneyTransferSuccess',
|
|
17
|
-
'MultiLevelApprovalDark',
|
|
18
|
-
'MultiLevelApprovalLight',
|
|
19
|
-
'NotHappy',
|
|
20
|
-
'ReceiptDark',
|
|
21
|
-
'ReceiptLight',
|
|
22
|
-
'ReimburseDark',
|
|
23
|
-
'ReimburseLight',
|
|
24
|
-
'RewardsDark',
|
|
25
|
-
'RewardsDarkHover',
|
|
26
|
-
'RewardsLight',
|
|
27
|
-
'RewardsLightHover',
|
|
28
|
-
'Success',
|
|
29
|
-
'VeryHappy',
|
|
30
|
-
];
|
|
31
|
-
const toAnimationsFileName = (v) => (0, stringToUnion_1.stringToUnion)(v, ALL_ANIMATIONS_FILE_NAMES);
|
|
32
|
-
exports.toAnimationsFileName = toAnimationsFileName;
|