@zeniai/client-epic-state 4.11.89 → 4.11.91
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/view/spendManagement/billPay/billPayConfig/billPayConfigPayload.d.ts +0 -4
- package/lib/view/spendManagement/billPay/billPayConfig/billPayConfigReducer.js +0 -9
- package/lib/view/spendManagement/billPay/billPayConfig/billPayConfigState.d.ts +0 -4
- package/lib/view/spendManagement/billPay/editBillView/editBillViewSelector.d.ts +4 -10
- package/lib/view/spendManagement/billPay/editBillView/editBillViewSelector.js +29 -82
- package/lib/view/spendManagement/billPay/editBillView/epics/initializeBillToLocalStoreEpic.js +2 -2
- package/lib/view/spendManagement/billPay/editBillView/epics/parseInvoiceToBillEpic.js +1 -1
- package/lib/view/spendManagement/plaidAccount/epic/paymentAccounts/updateMappedCashAccountEpic.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/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 -1
- package/package.json +1 -1
|
@@ -21,10 +21,6 @@ export interface BillPayConfigPayload {
|
|
|
21
21
|
supported_countries: CountryPayload[];
|
|
22
22
|
local_currency_supported_countries: CountryPayload[];
|
|
23
23
|
};
|
|
24
|
-
last_selected_from_account: {
|
|
25
|
-
account_id: string | null;
|
|
26
|
-
account_type: string | null;
|
|
27
|
-
};
|
|
28
24
|
}
|
|
29
25
|
export interface SupportedCurrencyPayload {
|
|
30
26
|
ach: Record<PaymentAchSubConfigCodeType, CurrencyPayload[]>;
|
|
@@ -20,7 +20,6 @@ exports.initialState = {
|
|
|
20
20
|
return this.fetchState == 'Completed';
|
|
21
21
|
},
|
|
22
22
|
billBulkSubmissionLimit: 10,
|
|
23
|
-
lastSelectedFromAccount: undefined,
|
|
24
23
|
};
|
|
25
24
|
const billPayConfig = (0, toolkit_1.createSlice)({
|
|
26
25
|
name: 'billPayConfig',
|
|
@@ -99,14 +98,6 @@ const billPayConfig = (0, toolkit_1.createSlice)({
|
|
|
99
98
|
draft.vendor.currencyListByCountryId[countryCode] =
|
|
100
99
|
currencyPayload.currencies.map((currency) => (0, billPayConfigPayload_1.toVendorCurrency)(currency));
|
|
101
100
|
});
|
|
102
|
-
draft.lastSelectedFromAccount =
|
|
103
|
-
payload.last_selected_from_account.account_id != null &&
|
|
104
|
-
payload.last_selected_from_account.account_type != null
|
|
105
|
-
? {
|
|
106
|
-
accountId: payload.last_selected_from_account.account_id,
|
|
107
|
-
accountType: (0, billPayConfigPayload_1.getAccountTypeSubConfigCodeKey)((0, billPayConfigState_1.toAccType)(payload.last_selected_from_account.account_type)),
|
|
108
|
-
}
|
|
109
|
-
: undefined;
|
|
110
101
|
},
|
|
111
102
|
updateBillPayConfigFailure(draft, action) {
|
|
112
103
|
draft.fetchState = 'Error';
|
|
@@ -19,10 +19,6 @@ export interface BillPayConfigState extends FetchedState {
|
|
|
19
19
|
};
|
|
20
20
|
billPayBotEmail: string;
|
|
21
21
|
billBulkSubmissionLimit: number;
|
|
22
|
-
lastSelectedFromAccount?: {
|
|
23
|
-
accountId: ID;
|
|
24
|
-
accountType: AccountTypeSubConfigCodeKeyType;
|
|
25
|
-
};
|
|
26
22
|
}
|
|
27
23
|
export interface VendorCurrency extends Currency {
|
|
28
24
|
currencyName: string;
|
|
@@ -3,6 +3,7 @@ import { RootState } from '../../../../reducer';
|
|
|
3
3
|
import { SelectorView } from '../../../../commonStateTypes/viewAndReport/viewAndReport';
|
|
4
4
|
import { Amount } from '../../../../commonStateTypes/amount';
|
|
5
5
|
import { BillPayInfo, BillPaymentMethod, BillStageCodeType, BillTransaction, InternationalTransferFeeBearerPaymentMethod } from '../../../../entity/billPay/billTransaction/billTransactionState';
|
|
6
|
+
import { PaymentAccountState } from '../../../../entity/paymentAccount/paymentAccountState';
|
|
6
7
|
import { Attachment } from '../../../../entity/transaction/stateTypes/attachment';
|
|
7
8
|
import { TransactionWithAccountAndClassLine } from '../../../../entity/transaction/stateTypes/transactionLine';
|
|
8
9
|
import { Vendor } from '../../../../entity/vendor/vendorState';
|
|
@@ -25,6 +26,7 @@ import { VendorDetailLocalData } from '../../../commonVendorView/vendorView/vend
|
|
|
25
26
|
import { AccountBase, RecommendedAccountBase } from '../../../../entity/account/accountState';
|
|
26
27
|
import { ClassBase, RecommendedClassBase } from '../../../../entity/class/classState';
|
|
27
28
|
import { RecurringBillState } from '../../../../entity/billPay/recurringBills/recurringBillsState';
|
|
29
|
+
import { DepositAccountState } from '../../../../entity/depositAccount/depositAccount';
|
|
28
30
|
import { FundingAccount } from '../../commonSetup/setupViewSelector';
|
|
29
31
|
export declare type PaymentToOption = {
|
|
30
32
|
id: ID;
|
|
@@ -119,7 +121,7 @@ export declare const getEditBillDetail: (state: RootState, isVendorRecommendatio
|
|
|
119
121
|
export declare const getBillPayConfigList: (billPayConfigState: BillPayConfigState) => BillPayConfig[];
|
|
120
122
|
export declare const getPaymentMethodType: (billPayConfigState: BillPayConfigState, accType: AccountTypeSubConfigCodeKeyType, paymentMethod?: BillPaymentMethod | undefined, internationalTransferFeeBearerPaymentMethod?: "swift_our" | "swift_sha" | undefined) => BillPayConfig | undefined;
|
|
121
123
|
export declare function getWhatForSection(updatedWhatForSection: WhatForSection | undefined): WhatForSection;
|
|
122
|
-
export declare function getPaymentSection(state: RootState, withdrawFromList: FundingAccount[], updatedPaymentSection: PaymentDetailsSection
|
|
124
|
+
export declare function getPaymentSection(state: RootState, withdrawFromList: FundingAccount[], updatedPaymentSection: PaymentDetailsSection): PaymentDetailsSectionView;
|
|
123
125
|
export declare const getActualPaymentTypeBasedOnAccType: (availablePaymentOptions: BillPayConfig[], withdrawFromAccType: AccountTypeSubConfigCodeKeyType, currentPaymentType?: BillPayConfig | undefined) => BillPayConfig | undefined;
|
|
124
126
|
export declare function toPaymentToOption(paymentMode: PaymentMode): PaymentToOption;
|
|
125
127
|
export declare function getCurrentPaymentToOption(state: RootState, id: ID): PaymentToOption | undefined;
|
|
@@ -131,7 +133,6 @@ export interface PaymentDetailsSectionView {
|
|
|
131
133
|
paymentTo?: PaymentToOption;
|
|
132
134
|
internationalTransferFeeBearerPaymentMethod?: InternationalTransferFeeBearerPaymentMethod;
|
|
133
135
|
conversionRate?: number;
|
|
134
|
-
defaultSelectedAccount?: FundingAccount;
|
|
135
136
|
}
|
|
136
137
|
export declare const getRecurringBillLocalData: (recurringBillState: RecurringBillState, transaction: BillTransaction) => {
|
|
137
138
|
recurringBillInstancesLocalData: RecurringBillInstance[];
|
|
@@ -139,11 +140,4 @@ export declare const getRecurringBillLocalData: (recurringBillState: RecurringBi
|
|
|
139
140
|
};
|
|
140
141
|
export declare const getInvoiceDate: (billStageCode: BillStageCodeType, invoiceDate: ZeniDate, bookCloseDate?: import("dayjs").Dayjs | undefined) => import("dayjs").Dayjs;
|
|
141
142
|
export declare const getDueDate: (billStageCode: BillStageCodeType, dueDate: ZeniDate, invoiceDate?: import("dayjs").Dayjs | undefined, bookCloseDate?: import("dayjs").Dayjs | undefined) => import("dayjs").Dayjs;
|
|
142
|
-
export declare const getWithdrawFrom: (
|
|
143
|
-
accountId: ID;
|
|
144
|
-
accountType: AccountTypeSubConfigCodeKeyType;
|
|
145
|
-
} | undefined) => FundingAccount | undefined;
|
|
146
|
-
export declare const getDefaultWithdrawFromAccount: (state: RootState, depositAccounts: ID[], companyId: ID, lastSelectedFromAccount?: {
|
|
147
|
-
accountId: ID;
|
|
148
|
-
accountType: AccountTypeSubConfigCodeKeyType;
|
|
149
|
-
} | undefined) => FundingAccount | undefined;
|
|
143
|
+
export declare const getWithdrawFrom: (paymentAccountState: PaymentAccountState, depositAccountState: DepositAccountState, fromAccountId: ID, fromAccountType: string) => FundingAccount | undefined;
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.
|
|
6
|
+
exports.getWithdrawFrom = exports.getDueDate = exports.getInvoiceDate = exports.getRecurringBillLocalData = exports.getCurrentPaymentToOption = exports.toPaymentToOption = exports.getActualPaymentTypeBasedOnAccType = exports.getPaymentSection = exports.getWhatForSection = exports.getPaymentMethodType = exports.getBillPayConfigList = exports.getEditBillDetail = void 0;
|
|
7
7
|
const get_1 = __importDefault(require("lodash/get"));
|
|
8
8
|
const has_1 = __importDefault(require("lodash/has"));
|
|
9
9
|
const reduceFetchState_1 = require("../../../../commonStateTypes/reduceFetchState");
|
|
@@ -30,9 +30,8 @@ const billPayConfigPayload_1 = require("../billPayConfig/billPayConfigPayload");
|
|
|
30
30
|
const depositAccountListSelector_1 = require("../../zeniAccounts/depositAccountList/depositAccountListSelector");
|
|
31
31
|
const depositAccountSelector_1 = require("../../../../entity/depositAccount/depositAccountSelector");
|
|
32
32
|
const setupViewSelector_1 = require("../../commonSetup/setupViewSelector");
|
|
33
|
-
const getCompanyView_1 = require("../../../companyView/selectorHelpers/getCompanyView");
|
|
34
33
|
const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAccountsEnabled, billId) => {
|
|
35
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5;
|
|
34
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7;
|
|
36
35
|
const { accountListState, accountState, bankAccountState, billDetailViewState, paymentAccountListState, billTransactionState, billPayConfigState, classListState, classState, editBillDetailViewState, paymentAccountState, vendorState, tenantState, companyState, userState, commonHistoryState, contactState, paymentInstrumentState, recurringBillState, depositAccountListState, depositAccountState, } = state;
|
|
37
36
|
const transaction = (0, get_1.default)(billTransactionState.transactionById, billId !== null && billId !== void 0 ? billId : '', undefined);
|
|
38
37
|
let recommendations = {};
|
|
@@ -113,7 +112,7 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
113
112
|
let editBillInitialDetails = {
|
|
114
113
|
lineDetailSection: {},
|
|
115
114
|
whatForSection: getWhatForSection(undefined),
|
|
116
|
-
paymentDetailsSection: getPaymentSection(state, withdrawFromList, {}
|
|
115
|
+
paymentDetailsSection: getPaymentSection(state, withdrawFromList, {}),
|
|
117
116
|
totalAmount: sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.billDetailLocalData.totalAmount,
|
|
118
117
|
recipientTotalAmount: sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.billDetailLocalData.recipientTotalAmount,
|
|
119
118
|
};
|
|
@@ -155,14 +154,14 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
155
154
|
const initialPaymentDetailsSection = {
|
|
156
155
|
paymentType: (0, exports.getPaymentMethodType)(billPayConfigState, (_q = billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.fromAccount.billAccountType) !== null && _q !== void 0 ? _q : 'depositAccount', billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.billPaymentMethodType, billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.internationalTransferFeeBearerPaymentMethod),
|
|
157
156
|
paymentDate: billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.paymentDate,
|
|
158
|
-
withdrawFrom: (0, exports.getWithdrawFrom)(
|
|
159
|
-
paymentTo: ((
|
|
157
|
+
withdrawFrom: (0, exports.getWithdrawFrom)(paymentAccountState, depositAccountState, (_r = billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.fromAccount.billAccountId) !== null && _r !== void 0 ? _r : '', (_s = billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.fromAccount.billAccountType) !== null && _s !== void 0 ? _s : ''),
|
|
158
|
+
paymentTo: ((_t = billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.toAccount.billAccountId) === null || _t === void 0 ? void 0 : _t.length) != null &&
|
|
160
159
|
(billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.toAccount.billAccountId.length) > 0
|
|
161
160
|
? billPayInfo.toAccount.billAccountId
|
|
162
161
|
: undefined,
|
|
163
162
|
internationalTransferFeeBearerPaymentMethod: billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.internationalTransferFeeBearerPaymentMethod,
|
|
164
163
|
};
|
|
165
|
-
const initialPaymentDetailsSectionView = getPaymentSection(state, withdrawFromList, initialPaymentDetailsSection
|
|
164
|
+
const initialPaymentDetailsSectionView = getPaymentSection(state, withdrawFromList, initialPaymentDetailsSection);
|
|
166
165
|
editBillInitialDetails = {
|
|
167
166
|
vendor: initialVendor,
|
|
168
167
|
whatForSection: initialWhatForSection,
|
|
@@ -174,7 +173,7 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
174
173
|
if (sourceBillDetail != null) {
|
|
175
174
|
const billViewState = billDetailViewState.billDetailById[key];
|
|
176
175
|
isCancelled = sourceBillDetail.billDetailLocalData.isCancelled;
|
|
177
|
-
billStage = (
|
|
176
|
+
billStage = (_u = billPayInfo === null || billPayInfo === void 0 ? void 0 : billPayInfo.stage.code) !== null && _u !== void 0 ? _u : 'draft';
|
|
178
177
|
if (billViewState != null) {
|
|
179
178
|
fetchState = (0, reduceFetchState_1.reduceFetchState)([
|
|
180
179
|
sourceBillDetail.fetchStatus,
|
|
@@ -186,7 +185,7 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
186
185
|
}
|
|
187
186
|
}
|
|
188
187
|
//recurringBill Details
|
|
189
|
-
isRecurring = (
|
|
188
|
+
isRecurring = (_v = transaction === null || transaction === void 0 ? void 0 : transaction.isRecurring) !== null && _v !== void 0 ? _v : false;
|
|
190
189
|
if (isRecurring && transaction != null) {
|
|
191
190
|
const { recurringConfigLocalData, recurringBillInstancesLocalData } = (0, exports.getRecurringBillLocalData)(recurringBillState, transaction);
|
|
192
191
|
recurringConfig = recurringConfigLocalData;
|
|
@@ -209,16 +208,16 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
209
208
|
lastRecommendedVendorName = updatedRecord.lastRecommendedVendorName;
|
|
210
209
|
paymentDetailsSection =
|
|
211
210
|
updatedRecord.paymentDetailsSection != null
|
|
212
|
-
? getPaymentSection(state, withdrawFromList, updatedRecord.paymentDetailsSection
|
|
211
|
+
? getPaymentSection(state, withdrawFromList, updatedRecord.paymentDetailsSection)
|
|
213
212
|
: undefined;
|
|
214
213
|
vendorDetails =
|
|
215
214
|
updatedRecord.vendor != null
|
|
216
215
|
? (0, vendorSelector_1.getVendorByVendorId)(vendorState, updatedRecord.vendor.id)
|
|
217
216
|
: undefined;
|
|
218
217
|
file = updatedRecord.file;
|
|
219
|
-
const bankAccInBill = (0, bankAccountSelector_1.getBankAccountByBankAccountId)(bankAccountState, (
|
|
220
|
-
const vendorBankAccounts = (0, bankAccountSelector_1.getBankAccountsByBankAccountIds)(bankAccountState, (
|
|
221
|
-
const vendorPaymentInstruments = (0, paymentInstrumentSelector_1.getPaymentInstrumentsByIds)(paymentInstrumentState, (
|
|
218
|
+
const bankAccInBill = (0, bankAccountSelector_1.getBankAccountByBankAccountId)(bankAccountState, (_x = (_w = updatedRecord.paymentDetailsSection) === null || _w === void 0 ? void 0 : _w.paymentTo) !== null && _x !== void 0 ? _x : '');
|
|
219
|
+
const vendorBankAccounts = (0, bankAccountSelector_1.getBankAccountsByBankAccountIds)(bankAccountState, (_y = vendorDetails === null || vendorDetails === void 0 ? void 0 : vendorDetails.bankAccountIds) !== null && _y !== void 0 ? _y : []);
|
|
220
|
+
const vendorPaymentInstruments = (0, paymentInstrumentSelector_1.getPaymentInstrumentsByIds)(paymentInstrumentState, (_z = vendorDetails === null || vendorDetails === void 0 ? void 0 : vendorDetails.paymentInstrumentIds) !== null && _z !== void 0 ? _z : []);
|
|
222
221
|
const isBankAccInBillExistInVendor = bankAccInBill != null
|
|
223
222
|
? vendorBankAccounts
|
|
224
223
|
.map((bankAc) => bankAc.bankAccountId)
|
|
@@ -271,7 +270,7 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
271
270
|
whatForSection.recipientCurrencyCode =
|
|
272
271
|
recommendedVendor.vendorCurrencyCode;
|
|
273
272
|
}
|
|
274
|
-
isRecurring = (
|
|
273
|
+
isRecurring = (_0 = sourceBillDetail.billDetailLocalData.isRecurring) !== null && _0 !== void 0 ? _0 : false;
|
|
275
274
|
recurringConfig = sourceBillDetail.billDetailLocalData.recurringConfig;
|
|
276
275
|
recurringBillInstances =
|
|
277
276
|
sourceBillDetail.billDetailLocalData.recurringBillInstances;
|
|
@@ -291,7 +290,7 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
291
290
|
}
|
|
292
291
|
const vendorContactSaveStatus = editBillDetailViewState.updateVendorContactState;
|
|
293
292
|
const lineDetailSection = {};
|
|
294
|
-
const lineDetailSectionUpdatesByLineId = (
|
|
293
|
+
const lineDetailSectionUpdatesByLineId = (_2 = (_1 = sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.billDetailLocalData) === null || _1 === void 0 ? void 0 : _1.updatesByLineId) !== null && _2 !== void 0 ? _2 : {};
|
|
295
294
|
const classList = (0, classListSelector_1.getClassList)(classState, classListState);
|
|
296
295
|
if (accountList.fetchState === 'Completed') {
|
|
297
296
|
Object.keys(lineDetailSectionUpdatesByLineId).forEach((lineId) => {
|
|
@@ -312,16 +311,16 @@ const getEditBillDetail = (state, isVendorRecommendationFeatureEnabled, isZeniAc
|
|
|
312
311
|
const accountsHierarchyList = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'billPayAccountList');
|
|
313
312
|
const classHierarchyList = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
|
|
314
313
|
const duplicateBills = (0, billPayReviewSelector_1.getDuplicateBills)(state, billId);
|
|
315
|
-
const isProcessing = (0, helpers_1.isBillProcessing)((
|
|
314
|
+
const isProcessing = (0, helpers_1.isBillProcessing)((_3 = transaction === null || transaction === void 0 ? void 0 : transaction.bulkProcessingDetail) === null || _3 === void 0 ? void 0 : _3.type);
|
|
316
315
|
return {
|
|
317
316
|
showVendorGptRecommendationText,
|
|
318
317
|
recommendedVendor,
|
|
319
318
|
lastRecommendedVendorName,
|
|
320
319
|
duplicateBills,
|
|
321
320
|
fetchState: fetchState,
|
|
322
|
-
saveStatus: (
|
|
323
|
-
error: (
|
|
324
|
-
uploadStatus: (
|
|
321
|
+
saveStatus: (_4 = sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.saveStatus) !== null && _4 !== void 0 ? _4 : undefined,
|
|
322
|
+
error: (_6 = (_5 = sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.fetchStatus) === null || _5 === void 0 ? void 0 : _5.error) !== null && _6 !== void 0 ? _6 : undefined,
|
|
323
|
+
uploadStatus: (_7 = sourceBillDetail === null || sourceBillDetail === void 0 ? void 0 : sourceBillDetail.uploadFetchState) !== null && _7 !== void 0 ? _7 : undefined,
|
|
325
324
|
version: 0,
|
|
326
325
|
createdBy,
|
|
327
326
|
createTime,
|
|
@@ -440,13 +439,13 @@ function getWhatForSection(updatedWhatForSection) {
|
|
|
440
439
|
};
|
|
441
440
|
}
|
|
442
441
|
exports.getWhatForSection = getWhatForSection;
|
|
443
|
-
function getPaymentSection(state, withdrawFromList, updatedPaymentSection
|
|
442
|
+
function getPaymentSection(state, withdrawFromList, updatedPaymentSection) {
|
|
444
443
|
var _a, _b;
|
|
445
444
|
const withdrawFrom = (updatedPaymentSection === null || updatedPaymentSection === void 0 ? void 0 : updatedPaymentSection.withdrawFrom) != null
|
|
446
445
|
? updatedPaymentSection === null || updatedPaymentSection === void 0 ? void 0 : updatedPaymentSection.withdrawFrom
|
|
447
446
|
: withdrawFromList.length === 1
|
|
448
447
|
? withdrawFromList[0]
|
|
449
|
-
:
|
|
448
|
+
: undefined;
|
|
450
449
|
const withdrawFromAccountingName = undefined;
|
|
451
450
|
const availablePaymentOptions = state.billPayConfigState.fetchState === 'Completed'
|
|
452
451
|
? (0, exports.getBillPayConfigList)(state.billPayConfigState).filter((option) => { var _a; return option.method.includes((_a = withdrawFrom === null || withdrawFrom === void 0 ? void 0 : withdrawFrom.accType) !== null && _a !== void 0 ? _a : ''); })
|
|
@@ -594,69 +593,17 @@ const getDueDate = (billStageCode, dueDate, invoiceDate, bookCloseDate) => {
|
|
|
594
593
|
}
|
|
595
594
|
};
|
|
596
595
|
exports.getDueDate = getDueDate;
|
|
597
|
-
const getWithdrawFrom = (
|
|
598
|
-
const
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
withdrawFromAsDepositAcc != null) {
|
|
604
|
-
return (0, setupViewSelector_1.mapDepositAccToFundingAccount)(withdrawFromAsDepositAcc);
|
|
605
|
-
}
|
|
606
|
-
if (fromAccountType === 'paymentAccount' &&
|
|
607
|
-
withdrawFromAsPaymentAcc != null) {
|
|
608
|
-
return (0, setupViewSelector_1.mapPaymentAccToFundingAccount)(withdrawFromAsPaymentAcc);
|
|
609
|
-
}
|
|
596
|
+
const getWithdrawFrom = (paymentAccountState, depositAccountState, fromAccountId, fromAccountType) => {
|
|
597
|
+
const withdrawFromAsDepositAcc = (0, depositAccountSelector_1.getDepositAccountByDepositAccountId)(depositAccountState, fromAccountId);
|
|
598
|
+
const withdrawFromAsPaymentAcc = (0, paymentAccountSelector_1.getPaymentAccountByPaymentAccountId)(paymentAccountState, fromAccountId);
|
|
599
|
+
if (fromAccountType === 'depositAccount' &&
|
|
600
|
+
withdrawFromAsDepositAcc != null) {
|
|
601
|
+
return (0, setupViewSelector_1.mapDepositAccToFundingAccount)(withdrawFromAsDepositAcc);
|
|
610
602
|
}
|
|
611
|
-
|
|
612
|
-
|
|
603
|
+
if (fromAccountType === 'paymentAccount' &&
|
|
604
|
+
withdrawFromAsPaymentAcc != null) {
|
|
605
|
+
return (0, setupViewSelector_1.mapPaymentAccToFundingAccount)(withdrawFromAsPaymentAcc);
|
|
613
606
|
}
|
|
614
607
|
return undefined;
|
|
615
608
|
};
|
|
616
609
|
exports.getWithdrawFrom = getWithdrawFrom;
|
|
617
|
-
const getDefaultWithdrawFromAccount = (state, depositAccounts, companyId, lastSelectedFromAccount) => {
|
|
618
|
-
const { depositAccountState, paymentAccountState } = state;
|
|
619
|
-
const companyView = (0, getCompanyView_1.getCompanyView)(state, companyId, []);
|
|
620
|
-
const primaryAccount = companyView === null || companyView === void 0 ? void 0 : companyView.company.company.companyBillPayInfo.primaryFundingAccount;
|
|
621
|
-
let defaultAccount = undefined;
|
|
622
|
-
// User paying bill for first time or previously paid with external account
|
|
623
|
-
if (lastSelectedFromAccount == null ||
|
|
624
|
-
(lastSelectedFromAccount === null || lastSelectedFromAccount === void 0 ? void 0 : lastSelectedFromAccount.accountType) === 'paymentAccount') {
|
|
625
|
-
if (depositAccounts.length === 0) {
|
|
626
|
-
defaultAccount = primaryAccount;
|
|
627
|
-
}
|
|
628
|
-
else {
|
|
629
|
-
if ((primaryAccount === null || primaryAccount === void 0 ? void 0 : primaryAccount.accountType) === 'depositAccount') {
|
|
630
|
-
defaultAccount = primaryAccount;
|
|
631
|
-
}
|
|
632
|
-
}
|
|
633
|
-
}
|
|
634
|
-
else {
|
|
635
|
-
// User paid with Zeni account previously
|
|
636
|
-
if (depositAccounts.length === 1) {
|
|
637
|
-
defaultAccount = primaryAccount;
|
|
638
|
-
}
|
|
639
|
-
else {
|
|
640
|
-
if ((primaryAccount === null || primaryAccount === void 0 ? void 0 : primaryAccount.accountType) === 'depositAccount') {
|
|
641
|
-
defaultAccount = primaryAccount;
|
|
642
|
-
}
|
|
643
|
-
else {
|
|
644
|
-
defaultAccount = lastSelectedFromAccount;
|
|
645
|
-
}
|
|
646
|
-
}
|
|
647
|
-
}
|
|
648
|
-
if (defaultAccount != null) {
|
|
649
|
-
const defaultAccAsDepositAcc = (0, depositAccountSelector_1.getDepositAccountByDepositAccountId)(depositAccountState, defaultAccount === null || defaultAccount === void 0 ? void 0 : defaultAccount.accountId);
|
|
650
|
-
const defaultAccAsPaymentAcc = (0, paymentAccountSelector_1.getPaymentAccountByPaymentAccountId)(paymentAccountState, defaultAccount === null || defaultAccount === void 0 ? void 0 : defaultAccount.accountId);
|
|
651
|
-
if (defaultAccount.accountType === 'depositAccount' &&
|
|
652
|
-
defaultAccAsDepositAcc != null) {
|
|
653
|
-
return (0, setupViewSelector_1.mapDepositAccToFundingAccount)(defaultAccAsDepositAcc);
|
|
654
|
-
}
|
|
655
|
-
if (defaultAccount.accountType === 'paymentAccount' &&
|
|
656
|
-
defaultAccAsPaymentAcc != null) {
|
|
657
|
-
return (0, setupViewSelector_1.mapPaymentAccToFundingAccount)(defaultAccAsPaymentAcc);
|
|
658
|
-
}
|
|
659
|
-
}
|
|
660
|
-
return undefined;
|
|
661
|
-
};
|
|
662
|
-
exports.getDefaultWithdrawFromAccount = getDefaultWithdrawFromAccount;
|
package/lib/view/spendManagement/billPay/editBillView/epics/initializeBillToLocalStoreEpic.js
CHANGED
|
@@ -97,7 +97,7 @@ const initializeBillToLocalStoreEpic = (actions$, state$) => actions$.pipe((0, o
|
|
|
97
97
|
const editBillState = (0, get_1.default)(state.editBillDetailViewState.editBillStateById, detailKey, undefined);
|
|
98
98
|
const billDetail = (0, get_1.default)(state.billDetailViewState.billDetailById, detailKey, undefined);
|
|
99
99
|
const transaction = (0, get_1.default)(state.billTransactionState.transactionById, billId, undefined);
|
|
100
|
-
const { accountListState, accountState, classListState, classState, recurringBillState, } = state;
|
|
100
|
+
const { accountListState, accountState, classListState, classState, recurringBillState, depositAccountState, paymentAccountState, } = state;
|
|
101
101
|
const accountList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'billPayAccountList');
|
|
102
102
|
const classList = (0, classListSelector_1.getClassList)(classState, classListState);
|
|
103
103
|
const recommendations = transaction === null || transaction === void 0 ? void 0 : transaction.recommendations;
|
|
@@ -161,7 +161,7 @@ const initializeBillToLocalStoreEpic = (actions$, state$) => actions$.pipe((0, o
|
|
|
161
161
|
const paymentDetailsSection = {
|
|
162
162
|
paymentType: (0, editBillViewSelector_1.getPaymentMethodType)(state.billPayConfigState, (_h = transaction.billPayInfo.fromAccount.billAccountType) !== null && _h !== void 0 ? _h : 'depositAccount', transaction.billPayInfo.billPaymentMethodType, transaction.billPayInfo.internationalTransferFeeBearerPaymentMethod),
|
|
163
163
|
paymentDate: (_j = transaction.billPayInfo.paymentDate) !== null && _j !== void 0 ? _j : (0, zeniDayJS_1.date)((0, workingDayHelper_1.getNextNthWorkingDay)((0, zeniDayJS_1.dateNow)().toDate(), [0, 6], isPayNowEnabled ? 0 : 1).toISOString()),
|
|
164
|
-
withdrawFrom: (0, editBillViewSelector_1.getWithdrawFrom)(
|
|
164
|
+
withdrawFrom: (0, editBillViewSelector_1.getWithdrawFrom)(paymentAccountState, depositAccountState, (_k = transaction.billPayInfo.fromAccount.billAccountId) !== null && _k !== void 0 ? _k : '', (_l = transaction.billPayInfo.fromAccount.billAccountType) !== null && _l !== void 0 ? _l : ''),
|
|
165
165
|
paymentTo: transaction.billPayInfo.toAccount.billAccountId != null &&
|
|
166
166
|
transaction.billPayInfo.toAccount.billAccountId.length > 0
|
|
167
167
|
? transaction.billPayInfo.toAccount.billAccountId
|
|
@@ -248,7 +248,7 @@ const toBillDetailLocalData = (state, showVendorGptRecommendationText, billPaylo
|
|
|
248
248
|
paymentDate: ((_o = billPayload.bill_pay_info) === null || _o === void 0 ? void 0 : _o.payment_date) != null
|
|
249
249
|
? (0, zeniDayJS_1.date)((_p = billPayload.bill_pay_info) === null || _p === void 0 ? void 0 : _p.payment_date)
|
|
250
250
|
: (0, zeniDayJS_1.date)((0, workingDayHelper_1.getNextNthWorkingDay)((0, zeniDayJS_1.dateNow)().toDate(), [0, 6], isPayNowEnabled ? 0 : 1).toISOString()),
|
|
251
|
-
withdrawFrom: (0, editBillViewSelector_1.getWithdrawFrom)(state, (_r = (_q = billPayload.bill_pay_info) === null || _q === void 0 ? void 0 : _q.from_account.account_id) !== null && _r !== void 0 ? _r : '', (_t = (_s = billPayload.bill_pay_info) === null || _s === void 0 ? void 0 : _s.from_account.account_type) !== null && _t !== void 0 ? _t : ''),
|
|
251
|
+
withdrawFrom: (0, editBillViewSelector_1.getWithdrawFrom)(state.paymentAccountState, state.depositAccountState, (_r = (_q = billPayload.bill_pay_info) === null || _q === void 0 ? void 0 : _q.from_account.account_id) !== null && _r !== void 0 ? _r : '', (_t = (_s = billPayload.bill_pay_info) === null || _s === void 0 ? void 0 : _s.from_account.account_type) !== null && _t !== void 0 ? _t : ''),
|
|
252
252
|
internationalTransferFeeBearerPaymentMethod: ((_u = billPayload.bill_pay_info) === null || _u === void 0 ? void 0 : _u.international_transfer_fee_bearer_payment_method) != null
|
|
253
253
|
? (0, billTransactionState_1.toInternationalTransferFeeBearerPaymentMethod)((_v = billPayload.bill_pay_info) === null || _v === void 0 ? void 0 : _v.international_transfer_fee_bearer_payment_method)
|
|
254
254
|
: undefined,
|
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) => {
|
|
@@ -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)) {
|
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
|
@@ -10,7 +10,6 @@ export interface RESTAPIEndpoints {
|
|
|
10
10
|
readonly insightsMicroServiceBaseUrl: string;
|
|
11
11
|
readonly searchMicroServiceBaseUrl: string;
|
|
12
12
|
readonly payMicroServiceBaseUrl: string;
|
|
13
|
-
readonly bankingMicroServiceBaseUrl: string;
|
|
14
13
|
readonly fileMicroServiceBaseUrl: string;
|
|
15
14
|
readonly documentAIMicroServiceBaseUrl: string;
|
|
16
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.91",
|
|
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",
|