@zeniai/client-epic-state 5.0.36 → 5.0.38-betaNB1
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/commonStateTypes/viewAndReport/agingReportStateTypes.d.ts +1 -1
- package/lib/entity/accountRecon/accountReconPayload.d.ts +19 -1
- package/lib/entity/accountRecon/accountReconPayload.js +21 -0
- package/lib/entity/accountRecon/accountReconSelector.d.ts +5 -1
- package/lib/entity/accountRecon/accountReconSelector.js +4 -0
- package/lib/entity/accountRecon/accountReconState.d.ts +18 -0
- package/lib/entity/tenant/clearAllEpic.d.ts +2 -1
- package/lib/entity/tenant/clearAllEpic.js +2 -0
- package/lib/entity/tenant/epic/deleteConnectionEpic.d.ts +19 -0
- package/lib/entity/tenant/epic/deleteConnectionEpic.js +29 -0
- package/lib/entity/tenant/epic/saveAPIKeyConnectionEpic.d.ts +19 -0
- package/lib/entity/tenant/epic/saveAPIKeyConnectionEpic.js +31 -0
- package/lib/entity/tenant/epic/saveOAuthConnectionEpic.d.ts +19 -0
- package/lib/entity/tenant/epic/saveOAuthConnectionEpic.js +33 -0
- package/lib/entity/tenant/tenantPayload.d.ts +1 -0
- package/lib/entity/tenant/tenantReducer.d.ts +59 -1
- package/lib/entity/tenant/tenantReducer.js +139 -4
- package/lib/entity/tenant/tenantState.d.ts +7 -0
- package/lib/epic.d.ts +3 -1
- package/lib/epic.js +6 -1
- package/lib/esm/entity/accountRecon/accountReconPayload.js +21 -0
- package/lib/esm/entity/accountRecon/accountReconSelector.js +4 -0
- package/lib/esm/entity/tenant/clearAllEpic.js +2 -0
- package/lib/esm/entity/tenant/epic/deleteConnectionEpic.js +25 -0
- package/lib/esm/entity/tenant/epic/saveAPIKeyConnectionEpic.js +27 -0
- package/lib/esm/entity/tenant/epic/saveOAuthConnectionEpic.js +29 -0
- package/lib/esm/entity/tenant/tenantReducer.js +135 -2
- package/lib/esm/epic.js +6 -1
- package/lib/esm/index.js +5 -2
- package/lib/esm/reducer.js +3 -0
- package/lib/esm/view/expenseAutomationView/reducers/reconciliationViewReducer.js +7 -2
- package/lib/esm/view/expenseAutomationView/selectors/reconciliationViewSelector.js +2 -0
- package/lib/esm/view/expenseAutomationView/types/reconciliationViewState.js +20 -0
- package/lib/esm/view/featureNotificationView/epics/fetchRegisteredInterestsEpic.js +23 -0
- package/lib/esm/view/featureNotificationView/epics/notifyMeForFeatureEpic.js +25 -0
- package/lib/esm/view/featureNotificationView/featureNotificationViewPayload.js +11 -0
- package/lib/esm/view/featureNotificationView/featureNotificationViewReducer.js +106 -0
- package/lib/esm/view/featureNotificationView/featureNotificationViewSelector.js +4 -0
- package/lib/esm/view/featureNotificationView/featureNotificationViewState.js +1 -0
- package/lib/index.d.ts +6 -2
- package/lib/index.js +45 -31
- package/lib/reducer.d.ts +3 -0
- package/lib/reducer.js +3 -0
- package/lib/view/expenseAutomationView/payload/reconciliationPayload.d.ts +19 -0
- package/lib/view/expenseAutomationView/reducers/reconciliationViewReducer.js +7 -2
- package/lib/view/expenseAutomationView/selectorTypes/reconciliationViewSelectorTypes.d.ts +2 -1
- package/lib/view/expenseAutomationView/selectors/reconciliationViewSelector.js +2 -0
- package/lib/view/expenseAutomationView/types/reconciliationViewState.d.ts +24 -0
- package/lib/view/expenseAutomationView/types/reconciliationViewState.js +21 -0
- package/lib/view/featureNotificationView/epics/fetchRegisteredInterestsEpic.d.ts +16 -0
- package/lib/view/featureNotificationView/epics/fetchRegisteredInterestsEpic.js +27 -0
- package/lib/view/featureNotificationView/epics/notifyMeForFeatureEpic.d.ts +14 -0
- package/lib/view/featureNotificationView/epics/notifyMeForFeatureEpic.js +29 -0
- package/lib/view/featureNotificationView/featureNotificationViewPayload.d.ts +23 -0
- package/lib/view/featureNotificationView/featureNotificationViewPayload.js +15 -0
- package/lib/view/featureNotificationView/featureNotificationViewReducer.d.ts +19 -0
- package/lib/view/featureNotificationView/featureNotificationViewReducer.js +110 -0
- package/lib/view/featureNotificationView/featureNotificationViewSelector.d.ts +6 -0
- package/lib/view/featureNotificationView/featureNotificationViewSelector.js +11 -0
- package/lib/view/featureNotificationView/featureNotificationViewState.d.ts +26 -0
- package/lib/view/featureNotificationView/featureNotificationViewState.js +2 -0
- package/lib/view/vendorFiling1099/vendorFiling1099List/vendorFiling1099ListState.d.ts +1 -1
- package/package.json +1 -1
- package/lib/tsconfig.typecheck.tsbuildinfo +0 -1
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { createZeniAPIStatus, isSuccessStatus, } from '../../../responsePayload';
|
|
4
|
+
import { deleteConnection, deleteConnectionFailure, deleteConnectionSuccess, } from '../tenantReducer';
|
|
5
|
+
export const deleteConnectionEpic = (actions$, _, zeniAPI) => actions$.pipe(filter(deleteConnection.match), switchMap((action) => zeniAPI
|
|
6
|
+
.deleteAndGetJSON(`${zeniAPI.apiEndPoints.tenantMicroServiceBaseUrl}/1.0/connections/${action.payload.connectionId}`, undefined, Object.assign({ 'zeni-tenant-id': action.payload.tenantId }))
|
|
7
|
+
.pipe(mergeMap((response) => {
|
|
8
|
+
if (isSuccessStatus(response)) {
|
|
9
|
+
return from([
|
|
10
|
+
deleteConnectionSuccess(action.payload.tenantId, action.payload.connectionId, action.payload.connectionType),
|
|
11
|
+
]);
|
|
12
|
+
}
|
|
13
|
+
const status = response.status ??
|
|
14
|
+
createZeniAPIStatus('Failed to delete connection. Please try again.');
|
|
15
|
+
return from([
|
|
16
|
+
deleteConnectionFailure(action.payload.tenantId, status),
|
|
17
|
+
]);
|
|
18
|
+
}), catchError((error) => {
|
|
19
|
+
const message = error instanceof Error
|
|
20
|
+
? error.message
|
|
21
|
+
: 'Unexpected error deleting connection.';
|
|
22
|
+
return from([
|
|
23
|
+
deleteConnectionFailure(action.payload.tenantId, createZeniAPIStatus(message)),
|
|
24
|
+
]);
|
|
25
|
+
}))));
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../../responsePayload';
|
|
4
|
+
import { saveAPIKeyConnection, saveAPIKeyConnectionFailure, saveAPIKeyConnectionSuccess, } from '../tenantReducer';
|
|
5
|
+
export const saveAPIKeyConnectionEpic = (actions$, _, zeniAPI) => actions$.pipe(filter(saveAPIKeyConnection.match), switchMap((action) => zeniAPI
|
|
6
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.tenantMicroServiceBaseUrl}/1.0/connections/${action.payload.connectionId}`, {
|
|
7
|
+
api_key: action.payload.credentials.api_key,
|
|
8
|
+
connection_name: action.payload.connectionName,
|
|
9
|
+
connection_type: action.payload.connectionType,
|
|
10
|
+
site: action.payload.credentials.site,
|
|
11
|
+
}, Object.assign({ 'zeni-tenant-id': action.payload.tenantId }))
|
|
12
|
+
.pipe(mergeMap((response) => {
|
|
13
|
+
if (isSuccessResponse(response)) {
|
|
14
|
+
return from([
|
|
15
|
+
saveAPIKeyConnectionSuccess(action.payload.tenantId, action.payload.connectionType, response.data // eslint-disable-line @typescript-eslint/no-non-null-assertion
|
|
16
|
+
),
|
|
17
|
+
]);
|
|
18
|
+
}
|
|
19
|
+
const status = response.status ??
|
|
20
|
+
createZeniAPIStatus('Failed to save connection. Please try again.');
|
|
21
|
+
return from([saveAPIKeyConnectionFailure(action.payload.tenantId, status)]);
|
|
22
|
+
}), catchError((error) => {
|
|
23
|
+
const message = error instanceof Error ? error.message : 'Unexpected error saving connection.';
|
|
24
|
+
return from([
|
|
25
|
+
saveAPIKeyConnectionFailure(action.payload.tenantId, createZeniAPIStatus(message)),
|
|
26
|
+
]);
|
|
27
|
+
}))));
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../../responsePayload';
|
|
4
|
+
import { saveOAuthConnection, saveOAuthConnectionFailure, saveOAuthConnectionSuccess, } from '../tenantReducer';
|
|
5
|
+
export const saveOAuthConnectionEpic = (actions$, _, zeniAPI) => actions$.pipe(filter(saveOAuthConnection.match), switchMap((action) => zeniAPI
|
|
6
|
+
.putAndGetJSON(`${zeniAPI.apiEndPoints.tenantMicroServiceBaseUrl}/1.0/connections/${action.payload.connectionId}`, {
|
|
7
|
+
authorization_code: action.payload.credentials.authorization_code,
|
|
8
|
+
client_id: action.payload.credentials.client_id,
|
|
9
|
+
client_secret: action.payload.credentials.client_secret,
|
|
10
|
+
connection_name: action.payload.connectionName,
|
|
11
|
+
connection_type: action.payload.connectionType,
|
|
12
|
+
redirect_uri: action.payload.credentials.redirect_uri,
|
|
13
|
+
}, Object.assign({ 'zeni-tenant-id': action.payload.tenantId }))
|
|
14
|
+
.pipe(mergeMap((response) => {
|
|
15
|
+
if (isSuccessResponse(response)) {
|
|
16
|
+
return from([
|
|
17
|
+
saveOAuthConnectionSuccess(action.payload.tenantId, action.payload.connectionType, response.data // eslint-disable-line @typescript-eslint/no-non-null-assertion
|
|
18
|
+
),
|
|
19
|
+
]);
|
|
20
|
+
}
|
|
21
|
+
const status = response.status ??
|
|
22
|
+
createZeniAPIStatus('Failed to save connection. Please try again.');
|
|
23
|
+
return from([saveOAuthConnectionFailure(action.payload.tenantId, status)]);
|
|
24
|
+
}), catchError((error) => {
|
|
25
|
+
const message = error instanceof Error ? error.message : 'Unexpected error saving connection.';
|
|
26
|
+
return from([
|
|
27
|
+
saveOAuthConnectionFailure(action.payload.tenantId, createZeniAPIStatus(message)),
|
|
28
|
+
]);
|
|
29
|
+
}))));
|
|
@@ -2,12 +2,17 @@ import { createSlice } from '@reduxjs/toolkit';
|
|
|
2
2
|
import { fromBase64 } from 'js-base64';
|
|
3
3
|
import assignWith from 'lodash/assignWith';
|
|
4
4
|
import { toURL } from '../../commonPayloadTypes/urlPayload';
|
|
5
|
+
import { stringToUnion } from '../../commonStateTypes/stringToUnion';
|
|
5
6
|
import { toMonthYearPeriod } from '../../commonStateTypes/timePeriod';
|
|
6
7
|
import { toAccountingMethod } from '../../view/netBurnOrIncomeStoryCard/netBurnOrIncomeStoryCardSelectorTypes';
|
|
7
8
|
import { toNumberOfMonthForAverage, toTimeSpanIdForAverage, } from '../../view/netBurnOrIncomeStoryCard/netBurnOrIncomeStoryCardState';
|
|
8
9
|
import { date, dateNow } from '../../zeniDayJS';
|
|
9
10
|
import { toSubscriptionSummary } from '../subscription/subscriptionSummary/subscriptionSummaryReducer';
|
|
10
11
|
import { getInvitationStatus, getUserRoles, toMasterTOSInfo, toUserReimbursementInfo, } from '../userRole/userRolePayload';
|
|
12
|
+
const EXTERNAL_INTEGRATION_TYPES = ['revenue'];
|
|
13
|
+
export const toExternalIntegrationType = (v) => stringToUnion(v, EXTERNAL_INTEGRATION_TYPES);
|
|
14
|
+
const EXTERNAL_SUPPORTED_TOOLS = ['chargebee', 'hubspot'];
|
|
15
|
+
export const toExternalSupportedTool = (v) => stringToUnion(v, EXTERNAL_SUPPORTED_TOOLS);
|
|
11
16
|
export const initialState = {
|
|
12
17
|
fetchState: 'Not-Started',
|
|
13
18
|
error: undefined,
|
|
@@ -332,7 +337,11 @@ const tenant = createSlice({
|
|
|
332
337
|
fetchState: 'In-Progress',
|
|
333
338
|
accounting: [],
|
|
334
339
|
payments: [],
|
|
340
|
+
revenue: [],
|
|
335
341
|
saveConnectionState: 'Not-Started',
|
|
342
|
+
saveAPIKeyConnectionState: 'Not-Started',
|
|
343
|
+
saveOAuthConnectionState: 'Not-Started',
|
|
344
|
+
deleteConnectionState: 'Not-Started',
|
|
336
345
|
error: undefined,
|
|
337
346
|
};
|
|
338
347
|
},
|
|
@@ -342,12 +351,16 @@ const tenant = createSlice({
|
|
|
342
351
|
return { payload: { tenantId, externalConnections } };
|
|
343
352
|
},
|
|
344
353
|
reducer(draft, action) {
|
|
345
|
-
const { accounting, payments } = mapConnectionsPayloadToState(action.payload.externalConnections);
|
|
354
|
+
const { accounting, payments, revenue } = mapConnectionsPayloadToState(action.payload.externalConnections);
|
|
346
355
|
draft.externalConnectionsByTenant[action.payload.tenantId] = {
|
|
347
356
|
fetchState: 'Completed',
|
|
348
357
|
accounting,
|
|
349
358
|
payments,
|
|
359
|
+
revenue,
|
|
350
360
|
saveConnectionState: 'Completed',
|
|
361
|
+
saveAPIKeyConnectionState: 'Not-Started',
|
|
362
|
+
saveOAuthConnectionState: 'Not-Started',
|
|
363
|
+
deleteConnectionState: 'Not-Started',
|
|
351
364
|
error: undefined,
|
|
352
365
|
};
|
|
353
366
|
},
|
|
@@ -362,7 +375,11 @@ const tenant = createSlice({
|
|
|
362
375
|
fetchState: 'Error',
|
|
363
376
|
accounting: [],
|
|
364
377
|
payments: [],
|
|
378
|
+
revenue: [],
|
|
365
379
|
saveConnectionState: 'Error',
|
|
380
|
+
saveAPIKeyConnectionState: 'Not-Started',
|
|
381
|
+
saveOAuthConnectionState: 'Not-Started',
|
|
382
|
+
deleteConnectionState: 'Not-Started',
|
|
366
383
|
error: status,
|
|
367
384
|
};
|
|
368
385
|
},
|
|
@@ -408,6 +425,121 @@ const tenant = createSlice({
|
|
|
408
425
|
});
|
|
409
426
|
},
|
|
410
427
|
},
|
|
428
|
+
saveAPIKeyConnection: {
|
|
429
|
+
prepare(tenantId, connectionId, connectionType, connectionName, credentials) {
|
|
430
|
+
return { payload: { tenantId, connectionId, connectionType, connectionName, credentials } };
|
|
431
|
+
},
|
|
432
|
+
reducer(draft, action) {
|
|
433
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
434
|
+
if (existing != null) {
|
|
435
|
+
existing.saveAPIKeyConnectionState = 'In-Progress';
|
|
436
|
+
existing.saveAPIKeyConnectionError = undefined;
|
|
437
|
+
}
|
|
438
|
+
},
|
|
439
|
+
},
|
|
440
|
+
saveAPIKeyConnectionSuccess: {
|
|
441
|
+
prepare(tenantId, connectionType, connectionPayload) {
|
|
442
|
+
return { payload: { tenantId, connectionType, connectionPayload } };
|
|
443
|
+
},
|
|
444
|
+
reducer(draft, action) {
|
|
445
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
446
|
+
if (existing != null) {
|
|
447
|
+
existing.saveAPIKeyConnectionState = 'Completed';
|
|
448
|
+
existing[action.payload.connectionType] = [toConnection(action.payload.connectionPayload)];
|
|
449
|
+
existing.saveAPIKeyConnectionError = undefined;
|
|
450
|
+
}
|
|
451
|
+
},
|
|
452
|
+
},
|
|
453
|
+
saveAPIKeyConnectionFailure: {
|
|
454
|
+
prepare(tenantId, status) {
|
|
455
|
+
return { payload: { tenantId, status } };
|
|
456
|
+
},
|
|
457
|
+
reducer(draft, action) {
|
|
458
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
459
|
+
if (existing != null) {
|
|
460
|
+
existing.saveAPIKeyConnectionState = 'Error';
|
|
461
|
+
existing.saveAPIKeyConnectionError = action.payload.status;
|
|
462
|
+
}
|
|
463
|
+
},
|
|
464
|
+
},
|
|
465
|
+
saveOAuthConnection: {
|
|
466
|
+
prepare(tenantId, connectionId, connectionType, connectionName, credentials) {
|
|
467
|
+
return { payload: { tenantId, connectionId, connectionType, connectionName, credentials } };
|
|
468
|
+
},
|
|
469
|
+
reducer(draft, action) {
|
|
470
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
471
|
+
if (existing != null) {
|
|
472
|
+
existing.saveOAuthConnectionState = 'In-Progress';
|
|
473
|
+
existing.saveOAuthConnectionError = undefined;
|
|
474
|
+
}
|
|
475
|
+
},
|
|
476
|
+
},
|
|
477
|
+
saveOAuthConnectionSuccess: {
|
|
478
|
+
prepare(tenantId, connectionType, connectionPayload) {
|
|
479
|
+
return { payload: { tenantId, connectionType, connectionPayload } };
|
|
480
|
+
},
|
|
481
|
+
reducer(draft, action) {
|
|
482
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
483
|
+
if (existing != null) {
|
|
484
|
+
existing.saveOAuthConnectionState = 'Completed';
|
|
485
|
+
existing[action.payload.connectionType] = [toConnection(action.payload.connectionPayload)];
|
|
486
|
+
existing.saveOAuthConnectionError = undefined;
|
|
487
|
+
}
|
|
488
|
+
},
|
|
489
|
+
},
|
|
490
|
+
saveOAuthConnectionFailure: {
|
|
491
|
+
prepare(tenantId, status) {
|
|
492
|
+
return { payload: { tenantId, status } };
|
|
493
|
+
},
|
|
494
|
+
reducer(draft, action) {
|
|
495
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
496
|
+
if (existing != null) {
|
|
497
|
+
existing.saveOAuthConnectionState = 'Error';
|
|
498
|
+
existing.saveOAuthConnectionError = action.payload.status;
|
|
499
|
+
}
|
|
500
|
+
},
|
|
501
|
+
},
|
|
502
|
+
deleteConnection: {
|
|
503
|
+
prepare(tenantId, connectionId, connectionType) {
|
|
504
|
+
return { payload: { tenantId, connectionId, connectionType } };
|
|
505
|
+
},
|
|
506
|
+
reducer(draft, action) {
|
|
507
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
508
|
+
if (existing != null) {
|
|
509
|
+
existing.deleteConnectionState = 'In-Progress';
|
|
510
|
+
existing.deleteConnectionError = undefined;
|
|
511
|
+
}
|
|
512
|
+
},
|
|
513
|
+
},
|
|
514
|
+
deleteConnectionSuccess: {
|
|
515
|
+
prepare(tenantId, connectionId, connectionType) {
|
|
516
|
+
return { payload: { tenantId, connectionId, connectionType } };
|
|
517
|
+
},
|
|
518
|
+
reducer(draft, action) {
|
|
519
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
520
|
+
if (existing != null) {
|
|
521
|
+
existing.deleteConnectionState = 'Completed';
|
|
522
|
+
existing.deleteConnectionError = undefined;
|
|
523
|
+
const arr = existing[action.payload.connectionType];
|
|
524
|
+
const idx = arr.findIndex((c) => c.connectionId === action.payload.connectionId);
|
|
525
|
+
if (idx !== -1) {
|
|
526
|
+
arr[idx] = { ...arr[idx], isValid: false };
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
},
|
|
530
|
+
},
|
|
531
|
+
deleteConnectionFailure: {
|
|
532
|
+
prepare(tenantId, status) {
|
|
533
|
+
return { payload: { tenantId, status } };
|
|
534
|
+
},
|
|
535
|
+
reducer(draft, action) {
|
|
536
|
+
const existing = draft.externalConnectionsByTenant[action.payload.tenantId];
|
|
537
|
+
if (existing != null) {
|
|
538
|
+
existing.deleteConnectionState = 'Error';
|
|
539
|
+
existing.deleteConnectionError = action.payload.status;
|
|
540
|
+
}
|
|
541
|
+
},
|
|
542
|
+
},
|
|
411
543
|
doSignOut(draft) {
|
|
412
544
|
draft.fetchState = 'Not-Started';
|
|
413
545
|
draft.signInState = 'Not-Started';
|
|
@@ -555,7 +687,7 @@ const tenant = createSlice({
|
|
|
555
687
|
},
|
|
556
688
|
},
|
|
557
689
|
});
|
|
558
|
-
export const { updateTenants, fetchAllTenants, updateTenantsSuccess, updateTenantsFailure, fetchActiveTenant, updateTenantSuccess, updateTenantFailure, updateCurrentTenant, fetchExcludedResources, updateExcludedResourcesSuccess, updateExcludedResourcesFailure, doSignIn, doMagicLinkSignIn, magicLinkSignInSuccess, magicLinkSignInFailure, sendEmailMagicLinkToUser, sendEmailMagicLinkToUserSuccess, sendEmailMagicLinkToUserFailure, updateSignInState, doSignOut, signOutSuccess, sendSessionHeartbeat, sessionHeartbeatSuccess, sessionHeartbeatFailure, updateLoggedInUser, fetchExternalConnections, saveExternalConnection, saveExternalConnectionSuccess, saveExternalConnectionFailure, fetchExternalConnectionsFailure, fetchExternalConnectionsSuccess, clearAll, fetchSubscriptionSummaryForTenant, updateSubscriptionSummaryForTenantSuccess, updateSubscriptionSummaryForTenantFailure, updateOnboardingTenants, removeOnboardingTenant, updateTenantReimbursementInfo, updateReferViewedForLoggedInUser, updateTreasuryVideoViewedForLoggedInUser, resetSignInState, trigger2FA, updateTenantAccountingClassesEnabled, updateTenantMasterTOSInfo, verifyDeviceWithTwoFA, verifyDeviceWithTwoFASuccess, verifyDeviceWithTwoFAFailure, resendVerifyDeviceOTP, resendVerifyDeviceOTPSuccess, resendVerifyDeviceOTPFailure, } = tenant.actions;
|
|
690
|
+
export const { updateTenants, fetchAllTenants, updateTenantsSuccess, updateTenantsFailure, fetchActiveTenant, updateTenantSuccess, updateTenantFailure, updateCurrentTenant, fetchExcludedResources, updateExcludedResourcesSuccess, updateExcludedResourcesFailure, doSignIn, doMagicLinkSignIn, magicLinkSignInSuccess, magicLinkSignInFailure, sendEmailMagicLinkToUser, sendEmailMagicLinkToUserSuccess, sendEmailMagicLinkToUserFailure, updateSignInState, doSignOut, signOutSuccess, sendSessionHeartbeat, sessionHeartbeatSuccess, sessionHeartbeatFailure, updateLoggedInUser, fetchExternalConnections, saveExternalConnection, saveExternalConnectionSuccess, saveExternalConnectionFailure, fetchExternalConnectionsFailure, fetchExternalConnectionsSuccess, saveAPIKeyConnection, saveAPIKeyConnectionSuccess, saveAPIKeyConnectionFailure, saveOAuthConnection, saveOAuthConnectionSuccess, saveOAuthConnectionFailure, deleteConnection, deleteConnectionSuccess, deleteConnectionFailure, clearAll, fetchSubscriptionSummaryForTenant, updateSubscriptionSummaryForTenantSuccess, updateSubscriptionSummaryForTenantFailure, updateOnboardingTenants, removeOnboardingTenant, updateTenantReimbursementInfo, updateReferViewedForLoggedInUser, updateTreasuryVideoViewedForLoggedInUser, resetSignInState, trigger2FA, updateTenantAccountingClassesEnabled, updateTenantMasterTOSInfo, verifyDeviceWithTwoFA, verifyDeviceWithTwoFASuccess, verifyDeviceWithTwoFAFailure, resendVerifyDeviceOTP, resendVerifyDeviceOTPSuccess, resendVerifyDeviceOTPFailure, } = tenant.actions;
|
|
559
691
|
export default tenant.reducer;
|
|
560
692
|
/**
|
|
561
693
|
* Converts tenants payload to Tenant and User State
|
|
@@ -683,6 +815,7 @@ export function mapConnectionsPayloadToState(connectionsPayload) {
|
|
|
683
815
|
return {
|
|
684
816
|
accounting: connections.accounting.map((payload) => toConnection(payload)),
|
|
685
817
|
payments: connections.payments.map((payload) => toConnection(payload)),
|
|
818
|
+
revenue: (connections.revenue ?? []).map((payload) => toConnection(payload)),
|
|
686
819
|
};
|
|
687
820
|
}
|
|
688
821
|
export const toConnection = (payload) => ({
|
package/lib/esm/epic.js
CHANGED
|
@@ -14,7 +14,10 @@ import { fetchExcludedResourcesEpic, } from './entity/tenant/epic/fetchExcludedR
|
|
|
14
14
|
import { fetchExternalConnectionsEpic, } from './entity/tenant/epic/fetchExternalConnectionsEpic';
|
|
15
15
|
import { fetchSubscriptionSummaryForTenantEpic, } from './entity/tenant/epic/fetchSubscriptionSummaryForTenantEpic';
|
|
16
16
|
import { resendVerifyDeviceOTPEpic, } from './entity/tenant/epic/resendVerifyDeviceOTPEpic';
|
|
17
|
+
import { deleteConnectionEpic } from './entity/tenant/epic/deleteConnectionEpic';
|
|
18
|
+
import { saveAPIKeyConnectionEpic } from './entity/tenant/epic/saveAPIKeyConnectionEpic';
|
|
17
19
|
import { saveExternalConnectionEpic, } from './entity/tenant/epic/saveExternalConnectionEpic';
|
|
20
|
+
import { saveOAuthConnectionEpic } from './entity/tenant/epic/saveOAuthConnectionEpic';
|
|
18
21
|
import { sendEmailMagicLinkToUserEpic, } from './entity/tenant/epic/sendEmailMagicLinkToUserEpic';
|
|
19
22
|
import { sessionHeartbeatEpic, } from './entity/tenant/epic/sessionHeartbeatEpic';
|
|
20
23
|
import { doSignInEpic, } from './entity/tenant/epic/signInUserEpic';
|
|
@@ -203,6 +206,8 @@ import { fetchNotificationUnreadCountEpic, } from './view/notificationView/epics
|
|
|
203
206
|
import { fetchNotificationViewEpic, } from './view/notificationView/epics/fetchNotificationViewEpic';
|
|
204
207
|
import { updateNotificationViewAllNotificationsStatusEpic, } from './view/notificationView/epics/updateNotificationViewAllNotificationsStatusEpic';
|
|
205
208
|
import { updateNotificationViewNotificationStatusEpic, } from './view/notificationView/epics/updateNotificationViewNotificationStatusEpic';
|
|
209
|
+
import { fetchRegisteredInterestsEpic, } from './view/featureNotificationView/epics/fetchRegisteredInterestsEpic';
|
|
210
|
+
import { notifyMeForFeatureEpic, } from './view/featureNotificationView/epics/notifyMeForFeatureEpic';
|
|
206
211
|
import { fetchCompanyOnboardingViewEpic, } from './view/onboardingView/cockpitView/epic/fetchCompanyOnboardingViewEpic';
|
|
207
212
|
import { fetchOnboardingCompletedCompaniesEpic, } from './view/onboardingView/cockpitView/epic/fetchOnboardingCompletedCompaniesEpic';
|
|
208
213
|
import { fetchQBOConnectionPoolEpic, } from './view/onboardingView/cockpitView/epic/fetchQBOConnectionPoolEpic';
|
|
@@ -563,7 +568,7 @@ import { fetchZeniAccStatementPageEpic, } from './view/zeniAccStatementList/fetc
|
|
|
563
568
|
import { fetchZeniAccountsPromoCardEpic, } from './view/zeniAccountsPromoCard/zeniAccountsPromoCardEpic';
|
|
564
569
|
import { approveOAuthConsentEpic, } from './view/zeniOAuthView/epics/approveOAuthConsentEpic';
|
|
565
570
|
// Note: Please maintain strict alphabetical order
|
|
566
|
-
const combinedEpics = combineEpics(acceptBillPayTermsEpic, acceptBillPayUpdatedTermsEpic, acceptChargeCardTermsEpic, acceptEmployeeRemiTermsEpic, acceptMasterTOSEpic, acceptRemiTermsEpic, acceptTreasuryTermsEpic, acceptZeniAccountTermsEpic, addCardPaymentSourceEpic, approveOAuthConsentEpic, approveOrRejectBillEpic, approveOrRejectBillsBulkActionEpic, approveOrRejectRemiEpic, approveOrRejectRemisBulkActionEpic, approveVendorGlobalReviewEpic, archiveTaskEpic, backgroundRefetchReviewTabEpic, bulkUpdateTaskListEpic, cancelAiAccountantOnboardingEpic, cancelAndDeleteBillEpic, cancelAndDeleteRemiEpic, cancelOrDeleteBillsBulkActionEpic, cancelOrDeleteRemisBulkActionEpic, cancelScheduleAccruedJournalEntryEpic, changeZeniPersonRolesEpic, checkDepositEpic, clearAllEpic, closeChargeCardEpic, closeChargeCardsEpic, companyManagementSavePendingUpdatesEpic, companyManagementSaveUpdatesEpic, confirmCardSetupIntentEpic, convertAmountToHomeCurrencyEpic, createAddressEpic, createAutoTransferRuleEpic, createBankAccountEpic, createCardSetupIntentEpic, createCheckingAccountEpic, createCompanyAddressEpic, createCompanyOfficersEpic, createCompanyUserAddressEpic, createGlobalMerchantEpic, createInternationalBankAccountEpic, createNewSchedulesAccruedEpic, createNewSchedulesEpic, createNewTaskGroupEpic, createPaymentInstrumentEpic, createSessionAndSubmitEpic, createSessionEpic, createTagEpic, createTaskFromTaskGroupTemplateEpic, createUserBankAccountEpic, deleteAccountStatementEpic, deleteAutoTransferRuleEpic, excludeAccountFromReconciliationEpic, includeAccountInReconciliationEpic, deleteBankAccountEpic, deleteBillEpic, deleteChatSessionEpic, deleteBillPayApprovalRuleEpic, deleteFileEpic, deleteFileListEpic, deleteInternationalBankAccountEpic, deletePaymentInstrumentEpic, deletePersonEpic, deleteRemiApprovalRuleEpic, deleteRemiEpic, deleteScheduleAccruedDetailEpic, deleteScheduleDetailEpic, deleteTagEpic, deleteTaskEpic, snoozeTaskEpic, unsnoozeTaskEpic, deleteTaskGroupEpic, deleteTransactionAttachmentEpic, deleteUserBankAccountEpic, doMagicLinkSignInEpic, doSignInEpic, doSignOutEpic, sendEmailMagicLinkToUserEpic, sessionHeartbeatEpic, verifyDeviceWithTwoFAEpic, downloadAccountingProviderAttachmentEpic, dragNDropTasksEpic, enableChargeCardAutoPayEpic, enableSetupEpic, establishOnboardingPlaidConnectionEpic, establishPlaidConnectionEpic, expressInterestChargeCardEpic, fetchAccountListEpic, fetchAccountListForAccountTypesEpic, fetchAccountSettingsListForAccountTypesEpic, fetchAccruedScheduleListEpic, fetchActiveTenantEpic, fetchAddressEpic, fetchAiAccountantCustomersEpic, fetchAiAccountantJobsEpic, fetchAllCockpitViewsEpic, fetchAllExpenseAutomationTabsEpic, fetchAllPeopleRequiredViewsEpic, fetchAllTagsEpic, fetchAllTaskGroupsEpic, fetchAllTenantsEpic, fetchAndUpdateVendorRecommendationsEpic, fetchAggregatedReportEpic, fetchApAgingDetailEpic, fetchApAgingEpic, fetchArAgingDetailEpic, fetchArAgingEpic, fetchAuditReportGroupViewEpic, fetchAuditRuleGroupViewEpic, fetchAutoTransferReviewDetailEpic, fetchAutoTransferRuleHistoryEpic, fetchAutoTransferRulesEpic, fetchBalanceSheetEpic, fetchBalanceSheetForTimeframeEpic, fetchBankAccountsListEpic, fetchBankConnectionsViewEpic, fetchBankCountryNameByIbanEpic, fetchBankNameByRoutingEpic, fetchBankNameBySwiftEpic, fetchBillAndInitializeLocalStoreEpic, fetchBillDetailEpic, fetchBillingAccountsListEpic, fetchBillListEpic, fetchBillListPerTabEpic, fetchBillPayApproversDetailsEpic, fetchBillPayApproversListEpic, fetchBillPayCardEpic, fetchBillPayConfigEpic, fetchBillPaySetupApproverViewEpic, fetchBillPaySetupViewEpic, fetchCardBalanceEpic, fetchCashbackDetailEpic, fetchCashBalanceEpic, fetchCashFlowEpic, fetchCashFlowForTimeframeEpic, fetchCashInCashOutEpic, fetchCashPositionEpic, fetchChargeCardConfigEpic, fetchChargeCardDetailEpic, fetchChargeCardDetailPageEpic, fetchChargeCardListEpic, fetchChargeCardListPageEpic, fetchChargeCardPaymentPageEpic, fetchChargeCardRepaymentDetailEpic, fetchChargeCardPaymentHistoryEpic, fetchChargeCardSetupViewEpic, fetchChargeCardStatementListEpic, fetchChargeCardTransactionAttachmentsEpic, fetchChargeCardTransactionListEpic, fetchChargeCardTransactionStatisticsEpic, fetchChargeCardsRecurringExpensesEpic, fetchChatHistoryEpic, fetchChatSessionsForUserEpic, fetchClassListEpic, fetchCollaborationAuthTokenEpic, fetchCompanyBillingAddressEpic, fetchCompanyConfigEpic, fetchCompanyHealthMetricConfigEpic, fetchCompanyHealthMetricViewEpic, fetchCompanyManagementViewEpic, fetchCompanyMetaDataEpic, fetchCompanyMonthEndReportHistoricDataEpic, fetchCompanyMonthEndReportHistoricDatesEpic, fetchCompanyMonthEndReportTemplatesEpic, fetchCompanyMonthEndReportViewEpic, fetchCompanyOnboardingViewEpic, fetchCompanyPassportViewEpic, fetchCompanyPortfolioViewEpic, fetchCompanyTaskManagerViewEpic, fetchTaskManagerMetricsEpic, fetchCreditAccountEpic, fetchCreditAccountRepaymentEpic, fetchCurrencyConversionValueEpic, fetchDashboardEpic, fetchDashboardLayoutEpic, fetchDebitCardSummaryEpic, fetchDepositAccountDetailEpic, fetchDepositAccountEpic, fetchDepositAccountHistoryEpic, fetchDepositAccountLimitEpic, fetchDepositAccountListEpic, fetchDepositAccountListForCardsEpic, fetchDepositAccountTransactionListEpic, fetchDownloadSchedulesEpic, fetchDuplicateBillPayReviewEpic, fetchDuplicateReimbursementEpic, fetchEditBillDetailPageEpic, fetchEditRemiDetailPageEpic, fetchEligibleActionsForBillEpic, fetchEntityAutoCompleteEpic, fetchEntityHistoryEpic, fetchEntityRecommendationsByTransactionIdEpic, fetchExcludedResourcesEpic, fetchExpenseAutomationFluxAnalysisViewEpic, fetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataEpic, fetchExpenseAutomationJeSchedulesEpic, fetchExpenseAutomationJESchedulesPageEpic, fetchExpenseAutomationMarkTransactionAsNotMiscategorizedEpic, fetchExpenseAutomationMissingReceiptsEpic, bulkUploadReceiptsEpic, confirmBulkUploadMatchEpic, fetchBulkUploadBatchDetailsEpic, fetchMultipleBatchDetailsEpic, fetchMoreBatchDetailsEpic, fetchBulkUploadBatchesEpic, fetchCompletedTransactionsEpic, refetchCompletedTransactionsOnBulkUploadSortEpic, bulkUploadAutomatchingTimeoutEpic, bulkUploadMatchResultToastEpic, pollBulkUploadBatchStatusEpic, pusherBatchStatusCompletionEpic, restoreBulkUploadAutomatchingOnMountEpic, searchTransactionsForManualMatchEpic, fetchExpenseAutomationReconciliationsViewEpic, fetchExpenseAutomationSaveTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationViewEpic, fetchExpenseAutomationUpdateTransactionCategorizationEpic, fetchExpenseTrendEpic, fetchExpressPayInitialDetailsEpic, fetchExternalConnectionsEpic, fetchFileEpic, fetchFileListEpic, fetchFinanceStatementEpic, fetchForecastListEpic, initiateReportsClassViewRefetchingEpic, reportsResyncEpic, fetchGlobalMerchantAutoCompleteViewEpic, fetchGlobalMerchantRecommendationEpic, fetchIncomeTrendEpic, fetchInsightsCardEpic, fetchInternationalWireDynamicFormEpic, fetchIntlVerificationFormEpic, fetchIssueCardPageEpic, fetchMagicLinkBankNameByRoutingEpic, fetchMagicLinkBankNameBySwiftEpic, fetchMagicLinkBillEpic, fetchMagicLinkTenantEpic, fetchManagementViewEpic, fetchMerchantListEpic, fetchMonthClosePerformanceTrendEpic, fetchMonthEndCloseChecksEpic, fetchMyProfileEpic, fetchMyProfileViewEpic, fetchNetBurnOrIncomeClassesViewEpic, fetchNetBurnOrIncomeEpic, fetchNetBurnOrIncomeForTimeframeClassesViewEpic, fetchNetBurnOrIncomeForTimeframeEpic, fetchNetBurnOrIncomeStoryCardEpic, fetchNetBurnOrIncomeWithForecastEpic, fetchNotificationSettingsEpic, fetchNotificationSettingsViewEpic, fetchNotificationUnreadCountEpic, fetchNotificationViewEpic, fetchOnboardingCompletedCompaniesEpic, fetchOnboardingCustomerSetupViewEpic, fetchOnboardingCustomerViewEpic, fetchOnboardingViewEpic, fetchOpExByVendorEpic, fetchOpExByVendorReportForTimeframeEpic, fetchOpExByVendorReportSummaryEpic, fetchOpExClassesViewEpic, fetchOpExEpic, fetchOpExForTimeframeClassesViewEpic, fetchOpExReportForTimeframeEpic, fetchOpExWithForecastEpic, fetchOwnerListEpic, fetchParentSubsidiaryManagementViewEpic, fetchPaymentAccountBalanceEpic, fetchPaymentAccountListEpic, fetchPaymentSourcesEpic, fetchPeopleEpic, fetchPeoplePageEpic, fetchPortfolioViewEpic, fetchPreviousBillsEpic, fetchProfitAndLossClassesViewEpic, fetchProfitAndLossEpic, fetchProfitAndLossForTimeframeClassesViewEpic, fetchProfitAndLossForTimeframeProjectViewEpic, fetchProfitAndLossForTimeframeEpic, fetchProfitAndLossProjectViewEpic, fetchQBOConnectionPoolEpic, fetchRecommendationByEntityIdEpic, fetchRecommendationByEntityNameEpic, fetchRecommendationForAccountSettingsEpic, fetchRecommendationForAccountTypeEpic, fetchRecommendationsAndUpdateMerchantRecommendationsEpic, fetchRecommendedTransactionRowIndexEpic, fetchReferralsEpic, fetchReimbursementCardEpic, fetchReimbursementConfigEpic, fetchRemiAndInitializeLocalStoreEpic, fetchRemiApproversDetailsEpic, fetchRemiApproversListEpic, fetchRemiDetailEpic, fetchRemiListEpic, fetchRemiListPerTabEpic, fetchRemiSetupApproverViewEpic, fetchRemiSetupViewEpic, fetchRevenueClassesViewEpic, fetchRevenueEpic, fetchRevenueForTimeframeClassesViewEpic, fetchRevenueForTimeframeEpic, fetchRevenueWithForecastEpic, fetchReviewCompanyViewEpic, fetchReviewTransferDetailEpic, fetchRewardsPlanEpic, fetchScheduleAccruedDetailsEpic, fetchScheduleAccruedDetailsPageEpic, fetchScheduleDetailsEpic, fetchScheduleDetailsPageEpic, fetchScheduleListEpic, fetchSchedulesAccountEpic, fetchSubscriptionAddOnsEpic, fetchSubscriptionCouponsEpic, fetchSubscriptionCreateEstimateEpic, fetchSubscriptionDetailsEpic, fetchSubscriptionListEpic, fetchSubscriptionPlansEpic, fetchSubscriptionSummaryForTenantEpic, fetchSubscriptionUpdateEstimateEpic, fetchSubscriptionViewEpic, fetchSuggestedQuestionsEpic, fetchTaskDetailEpic, fetchTaskDetailPageEpic, fetchTaskGroupTemplatesEpic, fetchTaskHistoryEpic, fetchTaskListEpic, fetchTaskListPageEpic, fetchTasksCardEpic, fetchTopExEpic, fetchTransactionActivityLogEpic, fetchTransactionDetailEpic, fetchTransactionListByAccountEpic, fetchTransactionListByClassEpic, fetchTransactionListByEntityEpic, fetchTransactionsForEntityEpic, fetchTransactionsListByCategoryTypeEpic, fetchTreasuryDetailEpic, fetchTreasuryFundsEpic, fetchTreasuryHistoryEpic, fetchTreasurySetupViewEpic, fetchTreasuryStatementListEpic, fetchTreasuryTaxLetterListEpic, fetchTreasuryTransactionListEpic, updatePortfolioAllocationEpic, fetchPortfolioAllocationEpic, fetchTrendForEntityEpic, fetchUserDetailEpic, fetchUserFinancialAccountEpic, fetchUserListByTypeEpic, fetchUserRoleConfigEpic, fetchVendor1099TypeListEpic, fetchVendorAndUpdateBillLocalDataEpic, fetchVendorByNameAndParseInvoiceEpic, fetchVendorDetailsEpic, fetchVendorEpic, fetchVendorFirstReviewAttachmentsEpic, fetchVendorFirstReviewViewEpic, fetchVendorGlobalReviewViewEpic, fetchVendorsFiling1099AllEpic, fetchVendorsFiling1099DownloadEpic, fetchVendorsFiling1099ListEpic, fetchVendorsListEpic, fetchVendorsTabVendorDetailPageViewEpic, fetchVendorsTabVendorDetailsEpic, fetchVendorsTabVendorEpic, fetchVendorTabViewEpic, fetchVendorTypeListEpic, fetchZeniAccountListEpic, fetchZeniAccountsConfigEpic, fetchZeniAccountSetupViewEpic, fetchZeniAccountsPromoCardEpic, fetchZeniAccStatementListEpic, fetchZeniAccStatementPageEpic, fetchZeniUsersEpic, getOnboardingEmailGroupEpic, getOnboardingPlaidLinkTokenEpic, getPaymentAccountsEpic, getPlaidLinkTokenEpic, ignoreExpenseAutomationJEScheduleEpic, improveUsingZeniGPTEpic, initialiseExpenseAutomationReconciliationLocalDataForSelectedAccountIdEpic, initializeAccountMappingViewEpic, initializeAccountSettingsViewEpic, initializeBillPaySetupApproverViewUpdateDataEpic, initializeBillToLocalStoreEpic, initializeCardUserOnboardingLocalDataEpic, initializeCompanyHealthMetricViewLocalDataEpic, initializeDynamicFormEpic, initializeEditPersonEpic, initializeExpenseAutomationJeScheduleLocalDataEpic, initializeInternationalWireLocalDataEpic, initializeIntlVerificationFormEpic, initializeMyProfileLocalDataEpic, initializeOnboardingCustomerViewUpdateDataEpic, initializeRemiSetupApproverViewUpdateDataEpic, initializeRemiToLocalStoreEpic, initializeScheduleAccruedDetailLocalDataEpic, initializeScheduleDetailLocalDataEpic, initializeSubscriptionLocalDataEpic, initializeTaskToLocalStoreEpic, initializeTransactionDetailLocalDataEpic, initializeVendorAddressEpic, initiateChargeCardRepaymentEpic, invitePeopleEpic, inviteZeniPeopleEpic, issueChargeCardEpic, lockChargeCardEpic, lockChargeCardsEpic, markAsCompleteScheduleDetailEpic, markTransactionAsNotMiscategorizedEpic, parallelFetchAccountTransactionListEpic, parallelFetchClassTransactionListEpic, parallelFetchEntityTransactionListEpic, parallelFetchTransactionListByCategoryTypeEpic, parseInvoiceToBillEpic, parseReceiptsToRemiEpic, peopleSaveUpdatesEpic, pushToastNotificationEpic, refreshExpenseAutomationCurrentTabEpic, refreshIntegrationsDataEpic, rejectVendorGlobalReviewEpic, resendCardInviteEpic, resendInviteEpic, resendOtpEpic, resendVerifyDeviceOTPEpic, resendReferralInviteEpic, resetTransactionVendorLocalDataEpic, resetVendorDetailLocalDataEpic, resetVendorsTabVendorDetailLocalDataEpic, retryBankAccountConnectionEpic, retryBankAccountConnectionForOnboardingEpic, retryExpenseAutomationJEScheduleEpic, retryOrRefundBillEpic, validateBillsBulkActionEpic, reviewDraftRemisBulkActionEpic, reviewExpenseAutomationFluxAnalysisViewEpic, revokeCardInviteEpic, revokeChargeCardsInviteEpic, saveAccountMappingViewEpic, saveAccountSettingsViewEpic, saveBillDetailEpic, saveBillPaySetupApproverViewUpdatesEpic, saveCardOnboardingUserDetailsEpic, saveCompanyBillingAddressEpic, saveCompanyHealthMetricByIdEpic, saveCompanyMonthEndReportEpic, saveCompanyPassportDetailsEpic, saveExpenseAutomationReconciliationDetailsEpic, saveExpenseAutomationReconciliationReviewEpic, saveExternalConnectionEpic, saveMagicLinkBankAccountEpic, saveNewAddressEpic, saveNotificationSettingsEpic, saveOnboardingCustomerCompletedStatusEpic, saveOnboardingCustomerNotesEpic, saveOnboardingCustomerViewUpdatesEpic, saveRealTimeApprovalEpic, saveReasonForAuditRuleEpic, saveRemiDetailEpic, saveRemiSetupApproverViewUpdatesEpic, saveScheduleAccruedDetailsEpic, saveScheduleDetailsEpic, saveSubscriptionNotesUpdatesEpic, saveSubscriptionUpdatesEpic, saveTaskDetailEpic, saveTransactionDetailEpic, saveTransactionVendorEpic, saveVendorDetailsViewEpic, saveVendorEpic, saveVendorFirstReviewViewEpic, saveVendorsTabVendorEpic, sendCompanyMonthEndReportEpic, sendOnboardingCustomerViewInviteEpic, sendOtpEpic, sendReferralInviteEpic, statementCloseDayEpic, stopSubmitEpic, stopSubmitQuestionEpic, submitDraftBillsBulkActionEpic, submitDraftRemisBulkActionEpic, submitExpressPayEpic, submitIntlVerificationEpic, submitQuestionEpic, toggleReportUIOptionForecastModeEpic, transferMoneyEpic, treasuryTransferMoneyEpic, triggerAiAccountantJobEpic, triggerReviewTabRefetchEpic, unlinkPaymentAccountEpic, unlockChargeCardEpic, unlockChargeCardsEpic, updateAccruedJESchedulesEpic, updateAddressEpic, updateAutoTransferRuleEpic, updateAmountsInScheduleAccruedDetailEpic, updateAmountsInScheduleDetailEpic, updateBusinessVerificationDetailsEpic, updateChargeCardDetailEpic, updateChargeCardLimitEpic, updateChargeCardNameEpic, updateChargeCardsLimitEpic, updateAccountingClassesEnabledEpic, updateCompanyDetailsEpic, updateCompanyOfficerEpic, updateCompanyPassportLocalStoreDataEpic, updateDashboardLayoutEpic, updateDebitCardPinAttemptEpic, updateDepositAccountEpic, updateExpenseAutomationReconciliationBalanceLocalDataEpic, updateFileNameEpic, updateFilesMetadataEpic, updateJESchedulesEpic, updateMappedCashAccountEpic, updateMileageDetailsEpic, updateMyProfileEpic, updateNetBurnOrIncomeStoryCardSettingsEpic, updateNotificationViewAllNotificationsStatusEpic, updateNotificationViewNotificationStatusEpic, updateOnboardingCustomerViewCompleteStatusEpic, updateOnboardingCustomerViewDashboardLoadedEpic, updateOnboardingCustomerViewEpic, updateOnboardingCustomerViewLocalStoreDataEpic, updateOnboardingPaymentAccountLoginStatusEpic, updateOnboardingPaymentAccountStatusEpic, updatePaymentAccountEpic, updatePaymentAccountLoginStatusEpic, updatePaymentAccountStatusEpic, updatePhysicalChargeCardAttemptEpic, updatePrimaryContactEpic, updatePrimaryFundingAccountEpic, updateQBOConnectionPoolExternalConnectionEpic, updateReferViewedEpic, updateRemiSetupViewLocalStoreDataEpic, updateReportUIOptionCOABalancesRangeEpic, updateReportUIOptionIsCompareModeEpic, updateReportUIOptionIsCompareModeOnEpic, updateReportUIOptionThisPeriodEpic, updateReportUIOptionTimeFrameEpic, updateSectionAccountsViewEpic, updateSectionClassesViewEpicV2, updateSectionProjectViewEpic, updateSelectedVendorForCreateFlowEpic, updateSetupViewLocalStoreDataEpic, updateTaskFromListViewEpic, updateTaskGroupNameEpic, fetchCannedResponsesEpic, saveCannedResponseEpic, deleteCannedResponseEpic, updateTransactionDetailEpic, updateTreasuryVideoViewedEpic, updateVendorContactEpic, uploadAccountStatementEpic, uploadMissingAttachmentSuccessEpic, uploadMissingReceiptSuccessEpic, uploadTransactionReceiptSuccessEpic, vendorFiling1099UploadDetailsSaveEpic, verifyOtpEpic, verifyUserEpic, waitForBillDetailThenInitializeLocalStoreEpic, waitForForecastListThenFetchNetBurnOrIncomeWithForecastEpic, waitForForecastListThenFetchOpExWithForecastEpic, waitForForecastListThenFetchRevenueWithForecastEpic, waitForMerchantRecommendationFetchThenUpdateRecommendationInMerchantEpic, waitForVendorByIdThenSaveBillUpdatetoLocalStoreEpic, waitForVendorByNameThenParsetoLocalStoreEpic, waitForVendorByNameThenUpdateBillDetailEpic, waitForVendorRecommendationFetchThenUpdateRecommendationInBillEpic, wiseRedirectEpic);
|
|
571
|
+
const combinedEpics = combineEpics(acceptBillPayTermsEpic, acceptBillPayUpdatedTermsEpic, acceptChargeCardTermsEpic, acceptEmployeeRemiTermsEpic, acceptMasterTOSEpic, acceptRemiTermsEpic, acceptTreasuryTermsEpic, acceptZeniAccountTermsEpic, addCardPaymentSourceEpic, approveOAuthConsentEpic, approveOrRejectBillEpic, approveOrRejectBillsBulkActionEpic, approveOrRejectRemiEpic, approveOrRejectRemisBulkActionEpic, approveVendorGlobalReviewEpic, archiveTaskEpic, backgroundRefetchReviewTabEpic, bulkUpdateTaskListEpic, cancelAiAccountantOnboardingEpic, cancelAndDeleteBillEpic, cancelAndDeleteRemiEpic, cancelOrDeleteBillsBulkActionEpic, cancelOrDeleteRemisBulkActionEpic, cancelScheduleAccruedJournalEntryEpic, changeZeniPersonRolesEpic, checkDepositEpic, clearAllEpic, closeChargeCardEpic, closeChargeCardsEpic, companyManagementSavePendingUpdatesEpic, companyManagementSaveUpdatesEpic, confirmCardSetupIntentEpic, convertAmountToHomeCurrencyEpic, createAddressEpic, createAutoTransferRuleEpic, createBankAccountEpic, createCardSetupIntentEpic, createCheckingAccountEpic, createCompanyAddressEpic, createCompanyOfficersEpic, createCompanyUserAddressEpic, createGlobalMerchantEpic, createInternationalBankAccountEpic, createNewSchedulesAccruedEpic, createNewSchedulesEpic, createNewTaskGroupEpic, createPaymentInstrumentEpic, createSessionAndSubmitEpic, createSessionEpic, createTagEpic, createTaskFromTaskGroupTemplateEpic, createUserBankAccountEpic, deleteAccountStatementEpic, deleteAutoTransferRuleEpic, excludeAccountFromReconciliationEpic, includeAccountInReconciliationEpic, deleteBankAccountEpic, deleteBillEpic, deleteChatSessionEpic, deleteConnectionEpic, deleteBillPayApprovalRuleEpic, deleteFileEpic, deleteFileListEpic, deleteInternationalBankAccountEpic, deletePaymentInstrumentEpic, deletePersonEpic, deleteRemiApprovalRuleEpic, deleteRemiEpic, deleteScheduleAccruedDetailEpic, deleteScheduleDetailEpic, deleteTagEpic, deleteTaskEpic, snoozeTaskEpic, unsnoozeTaskEpic, deleteTaskGroupEpic, deleteTransactionAttachmentEpic, deleteUserBankAccountEpic, doMagicLinkSignInEpic, doSignInEpic, doSignOutEpic, sendEmailMagicLinkToUserEpic, sessionHeartbeatEpic, verifyDeviceWithTwoFAEpic, downloadAccountingProviderAttachmentEpic, dragNDropTasksEpic, enableChargeCardAutoPayEpic, enableSetupEpic, establishOnboardingPlaidConnectionEpic, establishPlaidConnectionEpic, expressInterestChargeCardEpic, fetchAccountListEpic, fetchAccountListForAccountTypesEpic, fetchAccountSettingsListForAccountTypesEpic, fetchAccruedScheduleListEpic, fetchActiveTenantEpic, fetchAddressEpic, fetchAiAccountantCustomersEpic, fetchAiAccountantJobsEpic, fetchAllCockpitViewsEpic, fetchAllExpenseAutomationTabsEpic, fetchAllPeopleRequiredViewsEpic, fetchAllTagsEpic, fetchAllTaskGroupsEpic, fetchAllTenantsEpic, fetchAndUpdateVendorRecommendationsEpic, fetchAggregatedReportEpic, fetchApAgingDetailEpic, fetchApAgingEpic, fetchArAgingDetailEpic, fetchArAgingEpic, fetchAuditReportGroupViewEpic, fetchAuditRuleGroupViewEpic, fetchAutoTransferReviewDetailEpic, fetchAutoTransferRuleHistoryEpic, fetchAutoTransferRulesEpic, fetchBalanceSheetEpic, fetchBalanceSheetForTimeframeEpic, fetchBankAccountsListEpic, fetchBankConnectionsViewEpic, fetchBankCountryNameByIbanEpic, fetchBankNameByRoutingEpic, fetchBankNameBySwiftEpic, fetchBillAndInitializeLocalStoreEpic, fetchBillDetailEpic, fetchBillingAccountsListEpic, fetchBillListEpic, fetchBillListPerTabEpic, fetchBillPayApproversDetailsEpic, fetchBillPayApproversListEpic, fetchBillPayCardEpic, fetchBillPayConfigEpic, fetchBillPaySetupApproverViewEpic, fetchBillPaySetupViewEpic, fetchCardBalanceEpic, fetchCashbackDetailEpic, fetchCashBalanceEpic, fetchCashFlowEpic, fetchCashFlowForTimeframeEpic, fetchCashInCashOutEpic, fetchCashPositionEpic, fetchChargeCardConfigEpic, fetchChargeCardDetailEpic, fetchChargeCardDetailPageEpic, fetchChargeCardListEpic, fetchChargeCardListPageEpic, fetchChargeCardPaymentPageEpic, fetchChargeCardRepaymentDetailEpic, fetchChargeCardPaymentHistoryEpic, fetchChargeCardSetupViewEpic, fetchChargeCardStatementListEpic, fetchChargeCardTransactionAttachmentsEpic, fetchChargeCardTransactionListEpic, fetchChargeCardTransactionStatisticsEpic, fetchChargeCardsRecurringExpensesEpic, fetchChatHistoryEpic, fetchChatSessionsForUserEpic, fetchClassListEpic, fetchCollaborationAuthTokenEpic, fetchCompanyBillingAddressEpic, fetchCompanyConfigEpic, fetchCompanyHealthMetricConfigEpic, fetchCompanyHealthMetricViewEpic, fetchCompanyManagementViewEpic, fetchCompanyMetaDataEpic, fetchCompanyMonthEndReportHistoricDataEpic, fetchCompanyMonthEndReportHistoricDatesEpic, fetchCompanyMonthEndReportTemplatesEpic, fetchCompanyMonthEndReportViewEpic, fetchCompanyOnboardingViewEpic, fetchCompanyPassportViewEpic, fetchCompanyPortfolioViewEpic, fetchCompanyTaskManagerViewEpic, fetchTaskManagerMetricsEpic, fetchCreditAccountEpic, fetchCreditAccountRepaymentEpic, fetchCurrencyConversionValueEpic, fetchDashboardEpic, fetchDashboardLayoutEpic, fetchDebitCardSummaryEpic, fetchDepositAccountDetailEpic, fetchDepositAccountEpic, fetchDepositAccountHistoryEpic, fetchDepositAccountLimitEpic, fetchDepositAccountListEpic, fetchDepositAccountListForCardsEpic, fetchDepositAccountTransactionListEpic, fetchDownloadSchedulesEpic, fetchDuplicateBillPayReviewEpic, fetchDuplicateReimbursementEpic, fetchEditBillDetailPageEpic, fetchEditRemiDetailPageEpic, fetchEligibleActionsForBillEpic, fetchEntityAutoCompleteEpic, fetchEntityHistoryEpic, fetchEntityRecommendationsByTransactionIdEpic, fetchExcludedResourcesEpic, fetchExpenseAutomationFluxAnalysisViewEpic, fetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataEpic, fetchExpenseAutomationJeSchedulesEpic, fetchExpenseAutomationJESchedulesPageEpic, fetchExpenseAutomationMarkTransactionAsNotMiscategorizedEpic, fetchExpenseAutomationMissingReceiptsEpic, bulkUploadReceiptsEpic, confirmBulkUploadMatchEpic, fetchBulkUploadBatchDetailsEpic, fetchMultipleBatchDetailsEpic, fetchMoreBatchDetailsEpic, fetchBulkUploadBatchesEpic, fetchCompletedTransactionsEpic, refetchCompletedTransactionsOnBulkUploadSortEpic, bulkUploadAutomatchingTimeoutEpic, bulkUploadMatchResultToastEpic, pollBulkUploadBatchStatusEpic, pusherBatchStatusCompletionEpic, restoreBulkUploadAutomatchingOnMountEpic, searchTransactionsForManualMatchEpic, fetchExpenseAutomationReconciliationsViewEpic, fetchExpenseAutomationSaveTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationEpic, fetchExpenseAutomationTransactionCategorizationViewEpic, fetchExpenseAutomationUpdateTransactionCategorizationEpic, fetchExpenseTrendEpic, fetchExpressPayInitialDetailsEpic, fetchExternalConnectionsEpic, fetchFileEpic, fetchFileListEpic, fetchFinanceStatementEpic, fetchForecastListEpic, initiateReportsClassViewRefetchingEpic, reportsResyncEpic, fetchGlobalMerchantAutoCompleteViewEpic, fetchGlobalMerchantRecommendationEpic, fetchIncomeTrendEpic, fetchInsightsCardEpic, fetchInternationalWireDynamicFormEpic, fetchIntlVerificationFormEpic, fetchIssueCardPageEpic, fetchMagicLinkBankNameByRoutingEpic, fetchMagicLinkBankNameBySwiftEpic, fetchMagicLinkBillEpic, fetchMagicLinkTenantEpic, fetchManagementViewEpic, fetchMerchantListEpic, fetchMonthClosePerformanceTrendEpic, fetchMonthEndCloseChecksEpic, fetchMyProfileEpic, fetchMyProfileViewEpic, fetchNetBurnOrIncomeClassesViewEpic, fetchNetBurnOrIncomeEpic, fetchNetBurnOrIncomeForTimeframeClassesViewEpic, fetchNetBurnOrIncomeForTimeframeEpic, fetchNetBurnOrIncomeStoryCardEpic, fetchNetBurnOrIncomeWithForecastEpic, fetchNotificationSettingsEpic, fetchNotificationSettingsViewEpic, fetchNotificationUnreadCountEpic, fetchNotificationViewEpic, fetchRegisteredInterestsEpic, fetchOnboardingCompletedCompaniesEpic, fetchOnboardingCustomerSetupViewEpic, fetchOnboardingCustomerViewEpic, fetchOnboardingViewEpic, fetchOpExByVendorEpic, fetchOpExByVendorReportForTimeframeEpic, fetchOpExByVendorReportSummaryEpic, fetchOpExClassesViewEpic, fetchOpExEpic, fetchOpExForTimeframeClassesViewEpic, fetchOpExReportForTimeframeEpic, fetchOpExWithForecastEpic, fetchOwnerListEpic, fetchParentSubsidiaryManagementViewEpic, fetchPaymentAccountBalanceEpic, fetchPaymentAccountListEpic, fetchPaymentSourcesEpic, fetchPeopleEpic, fetchPeoplePageEpic, fetchPortfolioViewEpic, fetchPreviousBillsEpic, fetchProfitAndLossClassesViewEpic, fetchProfitAndLossEpic, fetchProfitAndLossForTimeframeClassesViewEpic, fetchProfitAndLossForTimeframeProjectViewEpic, fetchProfitAndLossForTimeframeEpic, fetchProfitAndLossProjectViewEpic, fetchQBOConnectionPoolEpic, fetchRecommendationByEntityIdEpic, fetchRecommendationByEntityNameEpic, fetchRecommendationForAccountSettingsEpic, fetchRecommendationForAccountTypeEpic, fetchRecommendationsAndUpdateMerchantRecommendationsEpic, fetchRecommendedTransactionRowIndexEpic, fetchReferralsEpic, fetchReimbursementCardEpic, fetchReimbursementConfigEpic, fetchRemiAndInitializeLocalStoreEpic, fetchRemiApproversDetailsEpic, fetchRemiApproversListEpic, fetchRemiDetailEpic, fetchRemiListEpic, fetchRemiListPerTabEpic, fetchRemiSetupApproverViewEpic, fetchRemiSetupViewEpic, fetchRevenueClassesViewEpic, fetchRevenueEpic, fetchRevenueForTimeframeClassesViewEpic, fetchRevenueForTimeframeEpic, fetchRevenueWithForecastEpic, fetchReviewCompanyViewEpic, fetchReviewTransferDetailEpic, fetchRewardsPlanEpic, fetchScheduleAccruedDetailsEpic, fetchScheduleAccruedDetailsPageEpic, fetchScheduleDetailsEpic, fetchScheduleDetailsPageEpic, fetchScheduleListEpic, fetchSchedulesAccountEpic, fetchSubscriptionAddOnsEpic, fetchSubscriptionCouponsEpic, fetchSubscriptionCreateEstimateEpic, fetchSubscriptionDetailsEpic, fetchSubscriptionListEpic, fetchSubscriptionPlansEpic, fetchSubscriptionSummaryForTenantEpic, fetchSubscriptionUpdateEstimateEpic, fetchSubscriptionViewEpic, fetchSuggestedQuestionsEpic, fetchTaskDetailEpic, fetchTaskDetailPageEpic, fetchTaskGroupTemplatesEpic, fetchTaskHistoryEpic, fetchTaskListEpic, fetchTaskListPageEpic, fetchTasksCardEpic, fetchTopExEpic, fetchTransactionActivityLogEpic, fetchTransactionDetailEpic, fetchTransactionListByAccountEpic, fetchTransactionListByClassEpic, fetchTransactionListByEntityEpic, fetchTransactionsForEntityEpic, fetchTransactionsListByCategoryTypeEpic, fetchTreasuryDetailEpic, fetchTreasuryFundsEpic, fetchTreasuryHistoryEpic, fetchTreasurySetupViewEpic, fetchTreasuryStatementListEpic, fetchTreasuryTaxLetterListEpic, fetchTreasuryTransactionListEpic, updatePortfolioAllocationEpic, fetchPortfolioAllocationEpic, fetchTrendForEntityEpic, fetchUserDetailEpic, fetchUserFinancialAccountEpic, fetchUserListByTypeEpic, fetchUserRoleConfigEpic, fetchVendor1099TypeListEpic, fetchVendorAndUpdateBillLocalDataEpic, fetchVendorByNameAndParseInvoiceEpic, fetchVendorDetailsEpic, fetchVendorEpic, fetchVendorFirstReviewAttachmentsEpic, fetchVendorFirstReviewViewEpic, fetchVendorGlobalReviewViewEpic, fetchVendorsFiling1099AllEpic, fetchVendorsFiling1099DownloadEpic, fetchVendorsFiling1099ListEpic, fetchVendorsListEpic, fetchVendorsTabVendorDetailPageViewEpic, fetchVendorsTabVendorDetailsEpic, fetchVendorsTabVendorEpic, fetchVendorTabViewEpic, fetchVendorTypeListEpic, fetchZeniAccountListEpic, fetchZeniAccountsConfigEpic, fetchZeniAccountSetupViewEpic, fetchZeniAccountsPromoCardEpic, fetchZeniAccStatementListEpic, fetchZeniAccStatementPageEpic, fetchZeniUsersEpic, getOnboardingEmailGroupEpic, getOnboardingPlaidLinkTokenEpic, getPaymentAccountsEpic, getPlaidLinkTokenEpic, ignoreExpenseAutomationJEScheduleEpic, improveUsingZeniGPTEpic, initialiseExpenseAutomationReconciliationLocalDataForSelectedAccountIdEpic, initializeAccountMappingViewEpic, initializeAccountSettingsViewEpic, initializeBillPaySetupApproverViewUpdateDataEpic, initializeBillToLocalStoreEpic, initializeCardUserOnboardingLocalDataEpic, initializeCompanyHealthMetricViewLocalDataEpic, initializeDynamicFormEpic, initializeEditPersonEpic, initializeExpenseAutomationJeScheduleLocalDataEpic, initializeInternationalWireLocalDataEpic, initializeIntlVerificationFormEpic, initializeMyProfileLocalDataEpic, initializeOnboardingCustomerViewUpdateDataEpic, initializeRemiSetupApproverViewUpdateDataEpic, initializeRemiToLocalStoreEpic, initializeScheduleAccruedDetailLocalDataEpic, initializeScheduleDetailLocalDataEpic, initializeSubscriptionLocalDataEpic, initializeTaskToLocalStoreEpic, initializeTransactionDetailLocalDataEpic, initializeVendorAddressEpic, initiateChargeCardRepaymentEpic, invitePeopleEpic, inviteZeniPeopleEpic, issueChargeCardEpic, lockChargeCardEpic, lockChargeCardsEpic, markAsCompleteScheduleDetailEpic, markTransactionAsNotMiscategorizedEpic, notifyMeForFeatureEpic, parallelFetchAccountTransactionListEpic, parallelFetchClassTransactionListEpic, parallelFetchEntityTransactionListEpic, parallelFetchTransactionListByCategoryTypeEpic, parseInvoiceToBillEpic, parseReceiptsToRemiEpic, peopleSaveUpdatesEpic, pushToastNotificationEpic, refreshExpenseAutomationCurrentTabEpic, refreshIntegrationsDataEpic, rejectVendorGlobalReviewEpic, resendCardInviteEpic, resendInviteEpic, resendOtpEpic, resendVerifyDeviceOTPEpic, resendReferralInviteEpic, resetTransactionVendorLocalDataEpic, resetVendorDetailLocalDataEpic, resetVendorsTabVendorDetailLocalDataEpic, retryBankAccountConnectionEpic, retryBankAccountConnectionForOnboardingEpic, retryExpenseAutomationJEScheduleEpic, retryOrRefundBillEpic, validateBillsBulkActionEpic, reviewDraftRemisBulkActionEpic, reviewExpenseAutomationFluxAnalysisViewEpic, revokeCardInviteEpic, revokeChargeCardsInviteEpic, saveAccountMappingViewEpic, saveAccountSettingsViewEpic, saveAPIKeyConnectionEpic, saveBillDetailEpic, saveBillPaySetupApproverViewUpdatesEpic, saveCardOnboardingUserDetailsEpic, saveCompanyBillingAddressEpic, saveCompanyHealthMetricByIdEpic, saveCompanyMonthEndReportEpic, saveCompanyPassportDetailsEpic, saveExpenseAutomationReconciliationDetailsEpic, saveExpenseAutomationReconciliationReviewEpic, saveExternalConnectionEpic, saveMagicLinkBankAccountEpic, saveNewAddressEpic, saveNotificationSettingsEpic, saveOAuthConnectionEpic, saveOnboardingCustomerCompletedStatusEpic, saveOnboardingCustomerNotesEpic, saveOnboardingCustomerViewUpdatesEpic, saveRealTimeApprovalEpic, saveReasonForAuditRuleEpic, saveRemiDetailEpic, saveRemiSetupApproverViewUpdatesEpic, saveScheduleAccruedDetailsEpic, saveScheduleDetailsEpic, saveSubscriptionNotesUpdatesEpic, saveSubscriptionUpdatesEpic, saveTaskDetailEpic, saveTransactionDetailEpic, saveTransactionVendorEpic, saveVendorDetailsViewEpic, saveVendorEpic, saveVendorFirstReviewViewEpic, saveVendorsTabVendorEpic, sendCompanyMonthEndReportEpic, sendOnboardingCustomerViewInviteEpic, sendOtpEpic, sendReferralInviteEpic, statementCloseDayEpic, stopSubmitEpic, stopSubmitQuestionEpic, submitDraftBillsBulkActionEpic, submitDraftRemisBulkActionEpic, submitExpressPayEpic, submitIntlVerificationEpic, submitQuestionEpic, toggleReportUIOptionForecastModeEpic, transferMoneyEpic, treasuryTransferMoneyEpic, triggerAiAccountantJobEpic, triggerReviewTabRefetchEpic, unlinkPaymentAccountEpic, unlockChargeCardEpic, unlockChargeCardsEpic, updateAccruedJESchedulesEpic, updateAddressEpic, updateAutoTransferRuleEpic, updateAmountsInScheduleAccruedDetailEpic, updateAmountsInScheduleDetailEpic, updateBusinessVerificationDetailsEpic, updateChargeCardDetailEpic, updateChargeCardLimitEpic, updateChargeCardNameEpic, updateChargeCardsLimitEpic, updateAccountingClassesEnabledEpic, updateCompanyDetailsEpic, updateCompanyOfficerEpic, updateCompanyPassportLocalStoreDataEpic, updateDashboardLayoutEpic, updateDebitCardPinAttemptEpic, updateDepositAccountEpic, updateExpenseAutomationReconciliationBalanceLocalDataEpic, updateFileNameEpic, updateFilesMetadataEpic, updateJESchedulesEpic, updateMappedCashAccountEpic, updateMileageDetailsEpic, updateMyProfileEpic, updateNetBurnOrIncomeStoryCardSettingsEpic, updateNotificationViewAllNotificationsStatusEpic, updateNotificationViewNotificationStatusEpic, updateOnboardingCustomerViewCompleteStatusEpic, updateOnboardingCustomerViewDashboardLoadedEpic, updateOnboardingCustomerViewEpic, updateOnboardingCustomerViewLocalStoreDataEpic, updateOnboardingPaymentAccountLoginStatusEpic, updateOnboardingPaymentAccountStatusEpic, updatePaymentAccountEpic, updatePaymentAccountLoginStatusEpic, updatePaymentAccountStatusEpic, updatePhysicalChargeCardAttemptEpic, updatePrimaryContactEpic, updatePrimaryFundingAccountEpic, updateQBOConnectionPoolExternalConnectionEpic, updateReferViewedEpic, updateRemiSetupViewLocalStoreDataEpic, updateReportUIOptionCOABalancesRangeEpic, updateReportUIOptionIsCompareModeEpic, updateReportUIOptionIsCompareModeOnEpic, updateReportUIOptionThisPeriodEpic, updateReportUIOptionTimeFrameEpic, updateSectionAccountsViewEpic, updateSectionClassesViewEpicV2, updateSectionProjectViewEpic, updateSelectedVendorForCreateFlowEpic, updateSetupViewLocalStoreDataEpic, updateTaskFromListViewEpic, updateTaskGroupNameEpic, fetchCannedResponsesEpic, saveCannedResponseEpic, deleteCannedResponseEpic, updateTransactionDetailEpic, updateTreasuryVideoViewedEpic, updateVendorContactEpic, uploadAccountStatementEpic, uploadMissingAttachmentSuccessEpic, uploadMissingReceiptSuccessEpic, uploadTransactionReceiptSuccessEpic, vendorFiling1099UploadDetailsSaveEpic, verifyOtpEpic, verifyUserEpic, waitForBillDetailThenInitializeLocalStoreEpic, waitForForecastListThenFetchNetBurnOrIncomeWithForecastEpic, waitForForecastListThenFetchOpExWithForecastEpic, waitForForecastListThenFetchRevenueWithForecastEpic, waitForMerchantRecommendationFetchThenUpdateRecommendationInMerchantEpic, waitForVendorByIdThenSaveBillUpdatetoLocalStoreEpic, waitForVendorByNameThenParsetoLocalStoreEpic, waitForVendorByNameThenUpdateBillDetailEpic, waitForVendorRecommendationFetchThenUpdateRecommendationInBillEpic, wiseRedirectEpic);
|
|
567
572
|
const rootEpic = (action$, store$, dependencies) => combinedEpics(action$, store$, dependencies).pipe(map(identity), catchError((error, source) => {
|
|
568
573
|
console.error(error);
|
|
569
574
|
return source;
|
package/lib/esm/index.js
CHANGED
|
@@ -59,7 +59,7 @@ import { closeSnackbar, openSnackbar } from './entity/snackbar/snackbarReducer';
|
|
|
59
59
|
import { getSnackbar } from './entity/snackbar/snackbarSelector';
|
|
60
60
|
import { toPriorityCodeType, toTaskStatusCodeType, } from './entity/task/taskState';
|
|
61
61
|
import { getTaskGroupById } from './entity/taskGroup/taskGroupSelector';
|
|
62
|
-
import { clearAll, doMagicLinkSignIn, doSignIn, doSignOut, sendSessionHeartbeat, fetchActiveTenant, fetchAllTenants, fetchExcludedResources as fetchExcludedResourcesForTenant, fetchExternalConnections as fetchExternalConnectionsForTenant, fetchSubscriptionSummaryForTenant, resendVerifyDeviceOTP, resetSignInState, saveExternalConnection as saveExternalConnectionForTenant, sendEmailMagicLinkToUser, updateCurrentTenant, updateSignInState, verifyDeviceWithTwoFA, } from './entity/tenant/tenantReducer';
|
|
62
|
+
import { clearAll, doMagicLinkSignIn, doSignIn, doSignOut, sendSessionHeartbeat, fetchActiveTenant, fetchAllTenants, fetchExcludedResources as fetchExcludedResourcesForTenant, fetchExternalConnections as fetchExternalConnectionsForTenant, fetchSubscriptionSummaryForTenant, resendVerifyDeviceOTP, resetSignInState, deleteConnection, saveAPIKeyConnection, saveExternalConnection as saveExternalConnectionForTenant, saveOAuthConnection, sendEmailMagicLinkToUser, toExternalIntegrationType, toExternalSupportedTool, updateCurrentTenant, updateSignInState, verifyDeviceWithTwoFA, } from './entity/tenant/tenantReducer';
|
|
63
63
|
import { getCurrentTenant, getIsAccountingClassesEnabled, getIsAccountingProjectsEnabled, getTenantBaseById, getTenantBaseViewForTenantId, getTenantBaseViewForTenantView, getTenantsBaseByCheckInDateSelector, getTenantsByCheckInDateSelector, getTenantsCoreDetailsByCheckInDateSelector, isOtherProductsEnabledForTenant, isTenantBankingOnly, isTenantBookkeepingEnabled, isTenantCardsOnly, isTenantUsingZeniCOA, isZeniDomainTenant, toTenantCoreDetailsView, } from './entity/tenant/tenantSelector';
|
|
64
64
|
import { pushToastNotification } from './entity/toastNotification/toastNotificationReducer';
|
|
65
65
|
import { getLastNotificationTime, getNotifications, } from './entity/toastNotification/toastNotificationSelector';
|
|
@@ -200,6 +200,8 @@ import { getNetBurnOrIncomeStoryCardReport } from './view/netBurnOrIncomeStoryCa
|
|
|
200
200
|
import { fetchNotificationUnreadCount, fetchNotificationUnreadCountSuccess, fetchNotificationView, updateNotificationViewAllNotificationsStatus, updateNotificationViewCurrentTabAndSubTab, updateNotificationViewNotificationStatus, updateNotificationViewSubTab, updateNotificationViewTabState, updateNotificationViewUIState, } from './view/notificationView/notificationViewReducer';
|
|
201
201
|
import { getExternalNotificationsForSelectedSubTab, getNotificationView, getNotificationsForSelectedSubTab, } from './view/notificationView/notificationViewSelector';
|
|
202
202
|
import { toNotificationSubTabTypeStrict, toNotificationTabTypeStrict, } from './view/notificationView/notificationViewState';
|
|
203
|
+
import { clearFeatureNotificationView, fetchRegisteredInterests, notifyMeForFeature, } from './view/featureNotificationView/featureNotificationViewReducer';
|
|
204
|
+
import { getFeatureNotificationView, getRegisteredInterests, getRegisteredInterestsByFeature, isFeatureInterestRegistered, } from './view/featureNotificationView/featureNotificationViewSelector';
|
|
203
205
|
import { clearOnboardingCustomerViewUpdateData, fetchCompanyOnboardingView, fetchOnboardingCompletedCompanies, fetchQBOConnectionPool, getOnboardingEmailGroup, initializeOnboardingCustomerViewUpdateData, resetNewOnboardedCustomerId, retryBankAccountConnectionForOnboarding, saveOnboardingCustomerCompletedStatus, saveOnboardingCustomerDataInLocalStore, saveOnboardingCustomerNotes, saveOnboardingCustomerViewUpdateData, saveOnboardingCustomerViewUpdates, sendOnboardingCustomerViewInvite, updateCustomerCreationStatus, updateOnboardingCustomerDataInLocalStore, updateOnboardingCustomerListUIState, updateQBOConnectionPoolExternalConnection, updateStatusAfterOnboardingCompleted, } from './view/onboardingView/cockpitView/onboardingCockpitViewReducer';
|
|
204
206
|
import { getNewOnboardingCustomerView, getOnboardingCockpitView, } from './view/onboardingView/cockpitView/onboardingCockpitViewSelector';
|
|
205
207
|
import { toProductType, toProductTypeStrict, } from './view/onboardingView/cockpitView/types/onboardingCockpitViewTypes';
|
|
@@ -438,7 +440,7 @@ export { toTimeframeTick, mapTimePeriodtoTimeframeTick, toTimePeriod, toAbsolute
|
|
|
438
440
|
export { toVendorSpendTrendFilterTabsTypeStrict, } from './entity/vendorExpense/vendorExpenseSelector';
|
|
439
441
|
export { getNumberOfPeriods };
|
|
440
442
|
export { SCHEDULE_DAYS_OF_MONTH, toScheduleDaysOfMonth, toMonth, toMonthStrict, toQuarter, toQuarterStrict, };
|
|
441
|
-
export { getTenantBaseById, getCurrentTenant, getIsAccountingClassesEnabled, getIsAccountingProjectsEnabled, getTenantsByCheckInDateSelector, getTenantsBaseByCheckInDateSelector, getTenantsCoreDetailsByCheckInDateSelector, toTenantCoreDetailsView, getTenantBaseViewForTenantView, getTenantBaseViewForTenantId, isZeniDomainTenant, isTenantUsingZeniCOA, fetchActiveTenant, fetchAllTenants, updateCurrentTenant, clearAll, doMagicLinkSignIn, verifyDeviceWithTwoFA, resendVerifyDeviceOTP, sendEmailMagicLinkToUser, doSignIn, updateSignInState, doSignOut, sendSessionHeartbeat, resetSignInState, fetchExcludedResourcesForTenant, fetchExternalConnectionsForTenant, saveExternalConnectionForTenant, fetchSubscriptionSummaryForTenant, isTenantBankingOnly, isTenantCardsOnly, isTenantBookkeepingEnabled, isOtherProductsEnabledForTenant, };
|
|
443
|
+
export { getTenantBaseById, getCurrentTenant, getIsAccountingClassesEnabled, getIsAccountingProjectsEnabled, getTenantsByCheckInDateSelector, getTenantsBaseByCheckInDateSelector, getTenantsCoreDetailsByCheckInDateSelector, toTenantCoreDetailsView, getTenantBaseViewForTenantView, getTenantBaseViewForTenantId, isZeniDomainTenant, isTenantUsingZeniCOA, fetchActiveTenant, fetchAllTenants, updateCurrentTenant, clearAll, doMagicLinkSignIn, verifyDeviceWithTwoFA, resendVerifyDeviceOTP, sendEmailMagicLinkToUser, doSignIn, updateSignInState, doSignOut, sendSessionHeartbeat, resetSignInState, fetchExcludedResourcesForTenant, fetchExternalConnectionsForTenant, saveExternalConnectionForTenant, deleteConnection, saveAPIKeyConnection, saveOAuthConnection, toExternalIntegrationType, toExternalSupportedTool, fetchSubscriptionSummaryForTenant, isTenantBankingOnly, isTenantCardsOnly, isTenantBookkeepingEnabled, isOtherProductsEnabledForTenant, };
|
|
442
444
|
export { toAccountType, toAccountGroupType, getAccountGroupKey, };
|
|
443
445
|
export { getClassById } from './entity/class/classSelector';
|
|
444
446
|
export { getForecast };
|
|
@@ -605,6 +607,7 @@ export { getZeniAccountsPromoCard, fetchZeniAccountsPromoCard, };
|
|
|
605
607
|
export { approveOAuthConsent, approveOAuthConsentFailure, approveOAuthConsentSuccess, clearZeniOAuthView, getZeniOAuthApproveError, getZeniOAuthApproveFetchState, getZeniOAuthApproveRedirectUrl, parseOAuthParams, };
|
|
606
608
|
export { toNotificationModeStrict, updateCommentsNotifications, updateCommentsNotificationsStatuses, };
|
|
607
609
|
export { toNotificationSubTabTypeStrict, toNotificationTabTypeStrict, fetchNotificationView, fetchNotificationUnreadCount, fetchNotificationUnreadCountSuccess, updateNotificationViewAllNotificationsStatus, updateNotificationViewNotificationStatus, updateNotificationViewTabState, updateNotificationViewCurrentTabAndSubTab, updateNotificationViewSubTab, updateNotificationViewUIState, getNotificationView, getExternalNotificationsForSelectedSubTab, getNotificationsForSelectedSubTab, };
|
|
610
|
+
export { clearFeatureNotificationView, fetchRegisteredInterests, notifyMeForFeature, getFeatureNotificationView, getRegisteredInterests, getRegisteredInterestsByFeature, isFeatureInterestRegistered, };
|
|
608
611
|
export { pushToastNotification, getLastNotificationTime, getNotifications, };
|
|
609
612
|
export { getReferralListView, getInviteFormView, toReferralListViewSortKeyType, StatusTypes, AmountStatusTypes, fetchReferrals, sendReferralInvite, clearReferrals, saveReferralFormDataInLocalStore, updateReferralListSortUiState, resendReferralInvite, fetchRewardsPlan, getRewardsPlanCard, updateReferViewed, };
|
|
610
613
|
export { getRecurringEndDateFromCount, toRecurringFrequency, getMinAllowedEndDate, };
|
package/lib/esm/reducer.js
CHANGED
|
@@ -107,6 +107,7 @@ import expenseAutomationReconciliationView, { initialState as initialExpenseAuto
|
|
|
107
107
|
import expenseAutomationTransactionsView, { initialState as initialExpenseAutomationTransactionsViewState, } from './view/expenseAutomationView/reducers/transactionsViewReducer';
|
|
108
108
|
import fileView from './view/fileView/fileViewReducer';
|
|
109
109
|
import { initialFileViewState, } from './view/fileView/fileViewState';
|
|
110
|
+
import featureNotificationView, { initialState as initialFeatureNotificationViewState, } from './view/featureNotificationView/featureNotificationViewReducer';
|
|
110
111
|
import financeStatement, { initialFinanceStatementState, } from './view/financeStatement/financeStatementReducer';
|
|
111
112
|
import forecastList, { initialState as initialForecastListState, } from './view/forecastList/forecastListReducer';
|
|
112
113
|
import globalMerchantAutoComplete, { initialState as initialGlobalMerchantAutoCompleteState, } from './view/globalMerchantView/globalMerchantAutoCompleteView/globalMerchantAutoCompleteViewReducer';
|
|
@@ -355,6 +356,7 @@ const initialViewsState = {
|
|
|
355
356
|
expenseAutomationTransactionsViewState: initialExpenseAutomationTransactionsViewState,
|
|
356
357
|
expenseAutomationViewState: initialExpenseAutomationViewState,
|
|
357
358
|
expressPayState: initialExpressPayState,
|
|
359
|
+
featureNotificationViewState: initialFeatureNotificationViewState,
|
|
358
360
|
fileViewState: initialFileViewState,
|
|
359
361
|
financeStatementState: initialFinanceStatementState,
|
|
360
362
|
forecastListState: initialForecastListState,
|
|
@@ -586,6 +588,7 @@ const viewReducers = {
|
|
|
586
588
|
expenseAutomationTransactionsViewState: expenseAutomationTransactionsView,
|
|
587
589
|
expenseAutomationViewState: expenseAutomationView,
|
|
588
590
|
expressPayState: expressPay,
|
|
591
|
+
featureNotificationViewState: featureNotificationView,
|
|
589
592
|
fileViewState: fileView,
|
|
590
593
|
financeStatementState: financeStatement,
|
|
591
594
|
forecastListState: forecastList,
|
|
@@ -2,6 +2,7 @@ import { createSlice } from '@reduxjs/toolkit';
|
|
|
2
2
|
import { toMonthYearPeriodId, } from '../../../commonStateTypes/timePeriod';
|
|
3
3
|
import { toReconciliationAccountSource } from '../../../entity/account/accountState';
|
|
4
4
|
import { toBankStatusCodeType } from '../../../entity/accountRecon/accountReconState';
|
|
5
|
+
import { toReconciliationViewSummary, } from '../types/reconciliationViewState';
|
|
5
6
|
// Initial state
|
|
6
7
|
export const initialReconciliationTabsState = {
|
|
7
8
|
balances: {
|
|
@@ -75,6 +76,7 @@ export const initialState = {
|
|
|
75
76
|
},
|
|
76
77
|
},
|
|
77
78
|
excludedAccountIDs: [],
|
|
79
|
+
summary: undefined,
|
|
78
80
|
};
|
|
79
81
|
// Create slice with reducers
|
|
80
82
|
const expenseAutomationReconciliationView = createSlice({
|
|
@@ -143,7 +145,7 @@ const expenseAutomationReconciliationView = createSlice({
|
|
|
143
145
|
fetchReconciliationSuccess: {
|
|
144
146
|
reducer(draft, action) {
|
|
145
147
|
if (action.payload.accountId == null) {
|
|
146
|
-
updateAllReconciliation(draft, action.payload.reconciliation.accounts, action.payload.selectedPeriod, action.payload.reconciliation.reconciliation, action.payload.refreshViewInBackground, action.payload.reconciliation.excluded_accounts ?? []);
|
|
148
|
+
updateAllReconciliation(draft, action.payload.reconciliation.accounts, action.payload.selectedPeriod, action.payload.reconciliation.reconciliation, action.payload.refreshViewInBackground, action.payload.reconciliation.excluded_accounts ?? [], action.payload.reconciliation.summary);
|
|
147
149
|
}
|
|
148
150
|
else if (action.payload.reconciliation.reconciliation.length > 0 &&
|
|
149
151
|
action.payload.reconciliation.accounts.length > 0) {
|
|
@@ -527,7 +529,7 @@ const expenseAutomationReconciliationView = createSlice({
|
|
|
527
529
|
export const { fetchReconciliation, fetchReconciliationFailure, fetchReconciliationSuccess, saveReconciliationDetail, saveReconciliationDetailFailure, updateSelectedAccountId, setConnectionInProgressForAccount, setStatementParseInProgress, updateReconcileTabLocalData, updateReconcileTabListSortState, updateReconcileTabListScrollState, saveReconciliationDetailSuccess, updateSelectedTab, updateBalancesLocalData, initialiseLocalDataForSelectedAccountId, clearExpenseAutomationReconciliationView, updateSelectedDrawerAccountId, updateReviewTabSortState, initializeReconciliationReviewTabLocalData, updateReviewTabLocalData, saveReconciliationReview, updateSaveReconciliationReviewFetchStatus, updateReconListScrollPosition, updateAccountReconciliationLocalData, deleteAccountStatement, deleteAccountStatementSuccess, deleteAccountStatementFailure, excludeAccountFromReconciliation, excludeAccountFromReconciliationSuccess, excludeAccountFromReconciliationFailure, includeAccountInReconciliation, includeAccountInReconciliationSuccess, includeAccountInReconciliationFailure, uploadAccountStatement, uploadAccountStatementSuccess, uploadAccountStatementFailure, updateStatementUploadChosen, updateNodeCollapseState, } = expenseAutomationReconciliationView.actions;
|
|
528
530
|
// Export reducer
|
|
529
531
|
export default expenseAutomationReconciliationView.reducer;
|
|
530
|
-
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground, excludedAccounts) {
|
|
532
|
+
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground, excludedAccounts, summary) {
|
|
531
533
|
draft.excludedAccountIDs = excludedAccounts.map((ea) => ea.account_id);
|
|
532
534
|
draft.excludedAccountExclusionInfo = {};
|
|
533
535
|
excludedAccounts.forEach((ea) => {
|
|
@@ -609,6 +611,9 @@ function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliation
|
|
|
609
611
|
draft.fetchState = 'Completed';
|
|
610
612
|
draft.error = undefined;
|
|
611
613
|
}
|
|
614
|
+
if (summary !== undefined) {
|
|
615
|
+
draft.summary = toReconciliationViewSummary(summary);
|
|
616
|
+
}
|
|
612
617
|
}
|
|
613
618
|
function updateReconciliationByAccountID(draft, accounts, selectedPeriod, accountId, reconciliationData, refreshViewInBackground) {
|
|
614
619
|
const oldRecord = draft.accountReconciliationRecordsBySelectedPeriod[toMonthYearPeriodId(selectedPeriod)].reconciliationByAccountID[accountId];
|
|
@@ -115,6 +115,7 @@ export const getExpenseAutomationReconciliationView = createSelector((state) =>
|
|
|
115
115
|
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
116
116
|
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
117
117
|
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
118
|
+
summary: reconciliationViewState.summary,
|
|
118
119
|
};
|
|
119
120
|
}
|
|
120
121
|
const allAccountIDs = accountReconForMonthYearPeriod.accountIDs;
|
|
@@ -423,6 +424,7 @@ export const getExpenseAutomationReconciliationView = createSelector((state) =>
|
|
|
423
424
|
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
424
425
|
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
425
426
|
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
427
|
+
summary: reconciliationViewState.summary,
|
|
426
428
|
};
|
|
427
429
|
});
|
|
428
430
|
export const isAccountReconReport = (reportId) => {
|
|
@@ -1,4 +1,24 @@
|
|
|
1
1
|
import { stringToUnion } from '../../../commonStateTypes/stringToUnion';
|
|
2
|
+
export function toReconciliationViewSummary(payload) {
|
|
3
|
+
return {
|
|
4
|
+
accounts: {
|
|
5
|
+
done: payload.accounts.done,
|
|
6
|
+
failed: payload.accounts.failed,
|
|
7
|
+
inProgress: payload.accounts.in_progress,
|
|
8
|
+
total: payload.accounts.total,
|
|
9
|
+
},
|
|
10
|
+
accountsToConnectCount: payload.accounts_to_connect_count,
|
|
11
|
+
autoMatched: {
|
|
12
|
+
matchedTxns: payload.auto_matched.matched_txns,
|
|
13
|
+
totalTxns: payload.auto_matched.total_txns,
|
|
14
|
+
},
|
|
15
|
+
needsReview: {
|
|
16
|
+
accountCount: payload.needs_review.account_count,
|
|
17
|
+
txnCount: payload.needs_review.txn_count,
|
|
18
|
+
},
|
|
19
|
+
timeSavedPercentage: payload.time_saved_percentage,
|
|
20
|
+
};
|
|
21
|
+
}
|
|
2
22
|
export const RECONCILE_ACTIONS = [
|
|
3
23
|
'reconcile',
|
|
4
24
|
'save_reconcile_for_later',
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../../responsePayload';
|
|
4
|
+
import { toFeatureInterest, } from '../featureNotificationViewPayload';
|
|
5
|
+
import { fetchRegisteredInterests, fetchRegisteredInterestsFailure, fetchRegisteredInterestsSuccess, } from '../featureNotificationViewReducer';
|
|
6
|
+
export const fetchRegisteredInterestsEpic = (actions$, _state$, zeniAPI) => actions$.pipe(filter(fetchRegisteredInterests.match), switchMap((action) => zeniAPI
|
|
7
|
+
.getJSON(`${zeniAPI.apiEndPoints.notificationMicroServiceBaseUrl}/1.0/feature-interests?feature=${encodeURIComponent(action.payload.feature)}`)
|
|
8
|
+
.pipe(mergeMap((response) => {
|
|
9
|
+
if (isSuccessResponse(response) && response.data != null) {
|
|
10
|
+
const interests = response.data.feature_interests.map(toFeatureInterest);
|
|
11
|
+
return from([fetchRegisteredInterestsSuccess(interests)]);
|
|
12
|
+
}
|
|
13
|
+
const status = response.status ??
|
|
14
|
+
createZeniAPIStatus('Failed to fetch registered interests. Please try again.');
|
|
15
|
+
return from([fetchRegisteredInterestsFailure(status)]);
|
|
16
|
+
}), catchError((error) => {
|
|
17
|
+
const message = error instanceof Error
|
|
18
|
+
? error.message
|
|
19
|
+
: 'Unexpected error fetching registered interests.';
|
|
20
|
+
return from([
|
|
21
|
+
fetchRegisteredInterestsFailure(createZeniAPIStatus(message)),
|
|
22
|
+
]);
|
|
23
|
+
}))));
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../../responsePayload';
|
|
4
|
+
import { notifyMeForFeature, notifyMeForFeatureFailure, notifyMeForFeatureSuccess, } from '../featureNotificationViewReducer';
|
|
5
|
+
export const notifyMeForFeatureEpic = (actions$, _state$, zeniAPI) => actions$.pipe(filter(notifyMeForFeature.match), switchMap((action) => zeniAPI
|
|
6
|
+
.postAndGetJSON(`${zeniAPI.apiEndPoints.notificationMicroServiceBaseUrl}/1.0/feature-interests`, {
|
|
7
|
+
additional_info: action.payload.additionalInfo,
|
|
8
|
+
email: action.payload.email,
|
|
9
|
+
feature: action.payload.feature,
|
|
10
|
+
})
|
|
11
|
+
.pipe(mergeMap((response) => {
|
|
12
|
+
if (isSuccessResponse(response) && response.data != null) {
|
|
13
|
+
return from([notifyMeForFeatureSuccess(response.data)]);
|
|
14
|
+
}
|
|
15
|
+
const status = response.status ??
|
|
16
|
+
createZeniAPIStatus('Failed to register interest. Please try again.');
|
|
17
|
+
return from([notifyMeForFeatureFailure(status)]);
|
|
18
|
+
}), catchError((error) => {
|
|
19
|
+
const message = error instanceof Error
|
|
20
|
+
? error.message
|
|
21
|
+
: 'Unexpected error registering interest.';
|
|
22
|
+
return from([
|
|
23
|
+
notifyMeForFeatureFailure(createZeniAPIStatus(message)),
|
|
24
|
+
]);
|
|
25
|
+
}))));
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { date } from '../../zeniDayJS';
|
|
2
|
+
export const toFeatureInterest = (payload) => ({
|
|
3
|
+
interestId: payload.interest_id,
|
|
4
|
+
feature: payload.feature,
|
|
5
|
+
notified: payload.notified,
|
|
6
|
+
createTime: date(payload.create_time),
|
|
7
|
+
updateTime: date(payload.update_time),
|
|
8
|
+
additionalInfo: payload.additional_info ?? undefined,
|
|
9
|
+
email: payload.email ?? undefined,
|
|
10
|
+
notifiedTime: payload.notified_time != null ? date(payload.notified_time) : undefined,
|
|
11
|
+
});
|