@zeniai/client-epic-state 4.7.77 → 4.7.79

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.
Files changed (101) hide show
  1. package/lib/entity/account/accountPayload.d.ts +1 -1
  2. package/lib/entity/chargeCard/chargeCard.d.ts +0 -1
  3. package/lib/entity/chargeCard/chargeCardPayload.d.ts +14 -4
  4. package/lib/entity/chargeCard/chargeCardPayload.js +0 -1
  5. package/lib/entity/depositAccount/depositAccountPayload.d.ts +5 -2
  6. package/lib/entity/paymentAccount/paymentAccountPayload.d.ts +0 -1
  7. package/lib/entity/paymentAccount/paymentAccountPayload.js +1 -2
  8. package/lib/entity/paymentAccount/paymentAccountSelector.d.ts +0 -2
  9. package/lib/entity/paymentAccount/paymentAccountSelector.js +1 -14
  10. package/lib/entity/paymentAccount/paymentAccountState.d.ts +0 -1
  11. package/lib/entity/snackbar/snackbarTypes.d.ts +1 -1
  12. package/lib/entity/snackbar/snackbarTypes.js +0 -1
  13. package/lib/entity/tenant/clearAllEpic.d.ts +1 -3
  14. package/lib/entity/tenant/clearAllEpic.js +0 -4
  15. package/lib/entity/transaction/payloadTypes/transactionLinePayload.d.ts +2 -2
  16. package/lib/entity/transaction/payloadTypes/transactionLinePayload.js +2 -2
  17. package/lib/epic.d.ts +10 -9
  18. package/lib/epic.js +10 -9
  19. package/lib/index.d.ts +11 -21
  20. package/lib/index.js +22 -31
  21. package/lib/reducer.d.ts +0 -6
  22. package/lib/reducer.js +0 -6
  23. package/lib/view/accountList/fetchAccountListEpic.js +7 -16
  24. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewResendOtpEpic.d.ts +7 -0
  25. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewResendOtpEpic.js +24 -0
  26. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewSendOtpEpic.d.ts +7 -0
  27. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewSendOtpEpic.js +26 -0
  28. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewVerifyOtpEpic.d.ts +7 -0
  29. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/vendorViewVerifyOtpEpic.js +28 -0
  30. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/verifyUserEpic.d.ts +2 -2
  31. package/lib/view/commonVendorView/vendorView/epics/twoFactorAuth/verifyUserEpic.js +2 -2
  32. package/lib/view/commonVendorView/vendorView/vendorViewReducer.d.ts +9 -4
  33. package/lib/view/commonVendorView/vendorView/vendorViewReducer.js +70 -41
  34. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/resendOnboardingOfficerOtpEpic.d.ts +7 -0
  35. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/resendOnboardingOfficerOtpEpic.js +24 -0
  36. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/sendOnboardingOfficerOtpEpic.d.ts +7 -0
  37. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/sendOnboardingOfficerOtpEpic.js +27 -0
  38. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/verifyOnboardingOfficerOtpEpic.d.ts +7 -0
  39. package/lib/view/onboardingView/customerView/epic/twoFactorAuthentication/verifyOnboardingOfficerOtpEpic.js +30 -0
  40. package/lib/view/onboardingView/customerView/onboardingCustomerViewReducer.d.ts +9 -2
  41. package/lib/view/onboardingView/customerView/onboardingCustomerViewReducer.js +102 -70
  42. package/lib/view/people/changeZeniPersonRolesEpic.d.ts +1 -1
  43. package/lib/view/people/deletePersonEpic.d.ts +1 -1
  44. package/lib/view/people/invitePeopleEpic.d.ts +1 -1
  45. package/lib/view/people/inviteZeniPeopleEpic.d.ts +1 -1
  46. package/lib/view/people/resendInviteEpic.d.ts +1 -1
  47. package/lib/view/spendManagement/billPay/billPayConfig/billPayConfigPayload.d.ts +1 -0
  48. package/lib/view/spendManagement/billPay/billPayConfig/billPayConfigReducer.js +8 -0
  49. package/lib/view/spendManagement/billPay/billPayConfig/billPayConfigState.d.ts +1 -0
  50. package/lib/view/spendManagement/billPay/internationalWire/internationalWireSelector.js +1 -1
  51. package/lib/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigPayload.d.ts +1 -2
  52. package/lib/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigReducer.js +1 -4
  53. package/lib/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigState.d.ts +2 -2
  54. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetail.d.ts +0 -1
  55. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetail.js +0 -4
  56. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailReducer.d.ts +0 -7
  57. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailReducer.js +2 -25
  58. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailSelector.d.ts +0 -3
  59. package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailSelector.js +1 -6
  60. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/resendOtpEpic.d.ts +7 -0
  61. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/resendOtpEpic.js +23 -0
  62. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/sendOtpEpic.d.ts +7 -0
  63. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/sendOtpEpic.js +26 -0
  64. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/verifyOtpEpic.d.ts +7 -0
  65. package/lib/view/spendManagement/commonSetup/epic/twoFactorAuthentication/verifyOtpEpic.js +27 -0
  66. package/lib/view/spendManagement/commonSetup/setupViewReducer.d.ts +9 -2
  67. package/lib/view/spendManagement/commonSetup/setupViewReducer.js +104 -72
  68. package/lib/view/spendManagement/commonSetup/types/twoFactorAuthentication.d.ts +10 -0
  69. package/package.json +1 -1
  70. package/lib/view/settingsView/epic/fetchBankAccountsListEpic.d.ts +0 -22
  71. package/lib/view/settingsView/epic/fetchBankAccountsListEpic.js +0 -30
  72. package/lib/view/settingsView/epic/fetchBankConnectionsViewEpic.d.ts +0 -6
  73. package/lib/view/settingsView/epic/fetchBankConnectionsViewEpic.js +0 -14
  74. package/lib/view/settingsView/epic/fetchMyProfileEpic.d.ts +0 -43
  75. package/lib/view/settingsView/epic/fetchMyProfileEpic.js +0 -50
  76. package/lib/view/settingsView/epic/fetchMyProfileViewEpic.d.ts +0 -7
  77. package/lib/view/settingsView/epic/fetchMyProfileViewEpic.js +0 -17
  78. package/lib/view/settingsView/settingsViewPayload.d.ts +0 -8
  79. package/lib/view/settingsView/settingsViewPayload.js +0 -2
  80. package/lib/view/settingsView/settingsViewReducer.d.ts +0 -13
  81. package/lib/view/settingsView/settingsViewReducer.js +0 -71
  82. package/lib/view/settingsView/settingsViewSelector.d.ts +0 -14
  83. package/lib/view/settingsView/settingsViewSelector.js +0 -119
  84. package/lib/view/settingsView/settingsViewState.d.ts +0 -12
  85. package/lib/view/settingsView/settingsViewState.js +0 -2
  86. package/lib/view/settingsView/types/settingsViewSelectorTypes.d.ts +0 -29
  87. package/lib/view/settingsView/types/settingsViewSelectorTypes.js +0 -2
  88. package/lib/view/spendManagement/chargeCards/chargeCardDetail/updateChargeCardDetailEpic.d.ts +0 -11
  89. package/lib/view/spendManagement/chargeCards/chargeCardDetail/updateChargeCardDetailEpic.js +0 -60
  90. package/lib/view/twoFactorAuthentication/resendOtpEpic.d.ts +0 -10
  91. package/lib/view/twoFactorAuthentication/resendOtpEpic.js +0 -90
  92. package/lib/view/twoFactorAuthentication/sendOtpEpic.d.ts +0 -10
  93. package/lib/view/twoFactorAuthentication/sendOtpEpic.js +0 -93
  94. package/lib/view/twoFactorAuthentication/twoFactorAuthentication.d.ts +0 -16
  95. package/lib/view/twoFactorAuthentication/twoFactorAuthenticationPayload.d.ts +0 -19
  96. package/lib/view/twoFactorAuthentication/twoFactorAuthenticationPayload.js +0 -11
  97. package/lib/view/twoFactorAuthentication/twoFactorAuthenticationReducer.d.ts +0 -21
  98. package/lib/view/twoFactorAuthentication/twoFactorAuthenticationReducer.js +0 -101
  99. package/lib/view/twoFactorAuthentication/verifyOtpEpic.d.ts +0 -10
  100. package/lib/view/twoFactorAuthentication/verifyOtpEpic.js +0 -90
  101. /package/lib/view/{twoFactorAuthentication → spendManagement/commonSetup/types}/twoFactorAuthentication.js +0 -0
@@ -24,8 +24,8 @@ const verifyUserEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operato
24
24
  return (0, rxjs_1.from)(actions);
25
25
  }
26
26
  else {
27
- return (0, rxjs_1.of)((0, vendorViewReducer_1.verifyOtpVendorViewFailure)(response.status));
27
+ return (0, rxjs_1.of)((0, vendorViewReducer_1.verifyOtpFailure)(response.status));
28
28
  }
29
- }), (0, operators_1.catchError)((error) => (0, rxjs_1.of)((0, vendorViewReducer_1.verifyOtpVendorViewFailure)((0, responsePayload_1.createZeniAPIStatus)('Unexpected Error', 'Verify user api errored out' + JSON.stringify(error))))));
29
+ }), (0, operators_1.catchError)((error) => (0, rxjs_1.of)((0, vendorViewReducer_1.verifyOtpFailure)((0, responsePayload_1.createZeniAPIStatus)('Unexpected Error', 'Verify user api errored out' + JSON.stringify(error))))));
30
30
  }));
31
31
  exports.verifyUserEpic = verifyUserEpic;
@@ -61,15 +61,20 @@ export declare const fetchVendorDetails: import("@reduxjs/toolkit").ActionCreato
61
61
  cacheOverride: boolean | undefined;
62
62
  }, string, never, never>, fetchUserDetails: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
63
63
  userId: ID;
64
- }, string>, fetchUserDetailsSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, fetchUserDetailsFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, sendOtpVendorView: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
64
+ }, string>, fetchUserDetailsSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, fetchUserDetailsFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, sendOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[phoneNumber: string], {
65
65
  phoneNumber: string;
66
- }, string>, sendOtpVendorViewSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
66
+ }, string, never, never>, sendOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpChallenge: string], {
67
67
  otpChallenge: string;
68
- }, string>, sendOtpVendorViewFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, string>, resendOtpVendorView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOtpVendorView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOtpVendorViewSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOtpVendorViewFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, string>, verifyUser: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, phone: string, otpChallenge: string], {
68
+ }, string, never, never>, sendOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, resendOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpChallenge: string], {
69
+ otpChallenge: string;
70
+ }, string, never, never>, verifyOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpCode: string, otpChallenge: string], {
71
+ otpCode: string;
72
+ otpChallenge: string;
73
+ }, string, never, never>, verifyOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, verifyUser: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, phone: string, otpChallenge: string], {
69
74
  userId: string;
70
75
  phone: string;
71
76
  otpChallenge: string;
72
- }, string, never, never>, verifyUserSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyUserFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, string>, clearVendorView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, fetchAndUpdateVendorRecommendations: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[vendorName: string, cacheOverride?: any], {
77
+ }, string, never, never>, verifyUserSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, clearVendorView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, fetchAndUpdateVendorRecommendations: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[vendorName: string, cacheOverride?: any], {
73
78
  vendorName: string;
74
79
  cacheOverride: any;
75
80
  }, string, never, never>, updateRecommendationsInVendorDetailLocalData: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  var _a;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.waitForVendorRecommendationAndUpdatedRecommendationByLineId = exports.updateRecommendationsInVendorDetailLocalData = exports.fetchAndUpdateVendorRecommendations = exports.clearVendorView = exports.verifyUserFailure = exports.verifyUserSuccess = exports.verifyUser = exports.verifyOtpVendorViewFailure = exports.verifyOtpVendorViewSuccess = exports.verifyOtpVendorView = exports.resendOtpVendorView = exports.sendOtpVendorViewFailure = exports.sendOtpVendorViewSuccess = exports.sendOtpVendorView = exports.fetchUserDetailsFailure = exports.fetchUserDetailsSuccess = exports.fetchUserDetails = exports.fetchVendorDetailPageView = exports.updateContactsInVendorDetailLocalData = exports.resetVendorDetailLocalData = exports.updateVendorDetailLocalData = exports.initializeVendorAddress = exports.updateSelectedVendorForCreateFlow = exports.saveVendorSuccessOrFailure = exports.saveVendor = exports.updateCountryCurrencyInVendorView = exports.removePaymentInstrumentsInVendorView = exports.updatePaymentInstrumentsInVendorView = exports.removeBankAccountsInVendorView = exports.updateBankAccountsInVendorView = exports.updateVendorSaveStatus = exports.updateVendorFetchStatus = exports.fetchVendor = exports.fetchVendorDetails = exports.initialState = exports.initialVendorDetailLocalData = void 0;
4
+ exports.waitForVendorRecommendationAndUpdatedRecommendationByLineId = exports.updateRecommendationsInVendorDetailLocalData = exports.fetchAndUpdateVendorRecommendations = exports.clearVendorView = exports.verifyUserSuccess = exports.verifyUser = exports.verifyOtpFailure = exports.verifyOtpSuccess = exports.verifyOtp = exports.resendOtp = exports.sendOtpFailure = exports.sendOtpSuccess = exports.sendOtp = exports.fetchUserDetailsFailure = exports.fetchUserDetailsSuccess = exports.fetchUserDetails = exports.fetchVendorDetailPageView = exports.updateContactsInVendorDetailLocalData = exports.resetVendorDetailLocalData = exports.updateVendorDetailLocalData = exports.initializeVendorAddress = exports.updateSelectedVendorForCreateFlow = exports.saveVendorSuccessOrFailure = exports.saveVendor = exports.updateCountryCurrencyInVendorView = exports.removePaymentInstrumentsInVendorView = exports.updatePaymentInstrumentsInVendorView = exports.removeBankAccountsInVendorView = exports.updateBankAccountsInVendorView = exports.updateVendorSaveStatus = exports.updateVendorFetchStatus = exports.fetchVendor = exports.fetchVendorDetails = exports.initialState = exports.initialVendorDetailLocalData = void 0;
5
5
  const toolkit_1 = require("@reduxjs/toolkit");
6
6
  exports.initialVendorDetailLocalData = {
7
7
  contacts: [],
@@ -416,49 +416,84 @@ const vendorView = (0, toolkit_1.createSlice)({
416
416
  };
417
417
  },
418
418
  },
419
- sendOtpVendorView(draft, action) {
420
- draft.loggedInUserVerification.sendOtpStatus = {
421
- fetchState: 'In-Progress',
422
- error: undefined,
423
- };
424
- draft.loggedInUserVerification.phone = action.payload.phoneNumber;
419
+ sendOtp: {
420
+ reducer(draft, action) {
421
+ draft.loggedInUserVerification.sendOtpStatus = {
422
+ fetchState: 'In-Progress',
423
+ error: undefined,
424
+ };
425
+ draft.loggedInUserVerification.phone = action.payload.phoneNumber;
426
+ },
427
+ prepare(phoneNumber) {
428
+ return { payload: { phoneNumber } };
429
+ },
425
430
  },
426
- resendOtpVendorView(draft) {
427
- draft.loggedInUserVerification.sendOtpStatus = {
428
- fetchState: 'In-Progress',
429
- error: undefined,
430
- };
431
+ resendOtp: {
432
+ reducer(draft) {
433
+ draft.loggedInUserVerification.sendOtpStatus = {
434
+ fetchState: 'In-Progress',
435
+ error: undefined,
436
+ };
437
+ },
438
+ prepare(otpChallenge) {
439
+ return { payload: { otpChallenge } };
440
+ },
431
441
  },
432
- sendOtpVendorViewSuccess(draft, action) {
433
- draft.loggedInUserVerification.sendOtpStatus = {
434
- fetchState: 'Completed',
435
- error: undefined,
436
- };
437
- draft.loggedInUserVerification.otpChallenge = action.payload.otpChallenge;
442
+ sendOtpSuccess: {
443
+ reducer(draft, action) {
444
+ draft.loggedInUserVerification.sendOtpStatus = {
445
+ fetchState: 'Completed',
446
+ error: undefined,
447
+ };
448
+ draft.loggedInUserVerification.otpChallenge =
449
+ action.payload.otpChallenge;
450
+ },
451
+ prepare(otpChallenge) {
452
+ return { payload: { otpChallenge } };
453
+ },
438
454
  },
439
- sendOtpVendorViewFailure(draft, action) {
440
- draft.loggedInUserVerification.sendOtpStatus = {
441
- fetchState: 'Error',
442
- error: action.payload,
443
- };
455
+ sendOtpFailure: {
456
+ reducer(draft, action) {
457
+ draft.loggedInUserVerification.sendOtpStatus = {
458
+ fetchState: 'Error',
459
+ error: action.payload,
460
+ };
461
+ },
462
+ prepare(error) {
463
+ return {
464
+ payload: error,
465
+ };
466
+ },
444
467
  },
445
- verifyOtpVendorView(draft) {
446
- draft.loggedInUserVerification.otpVerificationStatus = {
447
- fetchState: 'In-Progress',
448
- error: undefined,
449
- };
468
+ verifyOtp: {
469
+ reducer(draft) {
470
+ draft.loggedInUserVerification.otpVerificationStatus = {
471
+ fetchState: 'In-Progress',
472
+ error: undefined,
473
+ };
474
+ },
475
+ prepare(otpCode, otpChallenge) {
476
+ return { payload: { otpCode, otpChallenge } };
477
+ },
450
478
  },
451
- verifyOtpVendorViewSuccess(draft) {
479
+ verifyOtpSuccess(draft) {
452
480
  draft.loggedInUserVerification.otpVerificationStatus = {
453
481
  fetchState: 'Completed',
454
482
  error: undefined,
455
483
  };
456
484
  },
457
- verifyOtpVendorViewFailure(draft, action) {
458
- draft.loggedInUserVerification.otpVerificationStatus = {
459
- fetchState: 'Error',
460
- error: action.payload,
461
- };
485
+ verifyOtpFailure: {
486
+ reducer(draft, action) {
487
+ draft.loggedInUserVerification.otpVerificationStatus = {
488
+ fetchState: 'Error',
489
+ error: action.payload,
490
+ };
491
+ },
492
+ prepare(error) {
493
+ return {
494
+ payload: error,
495
+ };
496
+ },
462
497
  },
463
498
  verifyUser: {
464
499
  reducer(draft) {
@@ -478,16 +513,10 @@ const vendorView = (0, toolkit_1.createSlice)({
478
513
  };
479
514
  draft.loggedInUserVerification.initiateVerification = false;
480
515
  },
481
- verifyUserFailure(draft, action) {
482
- draft.loggedInUserVerification.userVerificationStatus = {
483
- fetchState: 'Error',
484
- error: action.payload,
485
- };
486
- },
487
516
  clearVendorView(draft) {
488
517
  Object.assign(draft, exports.initialState);
489
518
  },
490
519
  },
491
520
  });
492
- _a = vendorView.actions, exports.fetchVendorDetails = _a.fetchVendorDetails, exports.fetchVendor = _a.fetchVendor, exports.updateVendorFetchStatus = _a.updateVendorFetchStatus, exports.updateVendorSaveStatus = _a.updateVendorSaveStatus, exports.updateBankAccountsInVendorView = _a.updateBankAccountsInVendorView, exports.removeBankAccountsInVendorView = _a.removeBankAccountsInVendorView, exports.updatePaymentInstrumentsInVendorView = _a.updatePaymentInstrumentsInVendorView, exports.removePaymentInstrumentsInVendorView = _a.removePaymentInstrumentsInVendorView, exports.updateCountryCurrencyInVendorView = _a.updateCountryCurrencyInVendorView, exports.saveVendor = _a.saveVendor, exports.saveVendorSuccessOrFailure = _a.saveVendorSuccessOrFailure, exports.updateSelectedVendorForCreateFlow = _a.updateSelectedVendorForCreateFlow, exports.initializeVendorAddress = _a.initializeVendorAddress, exports.updateVendorDetailLocalData = _a.updateVendorDetailLocalData, exports.resetVendorDetailLocalData = _a.resetVendorDetailLocalData, exports.updateContactsInVendorDetailLocalData = _a.updateContactsInVendorDetailLocalData, exports.fetchVendorDetailPageView = _a.fetchVendorDetailPageView, exports.fetchUserDetails = _a.fetchUserDetails, exports.fetchUserDetailsSuccess = _a.fetchUserDetailsSuccess, exports.fetchUserDetailsFailure = _a.fetchUserDetailsFailure, exports.sendOtpVendorView = _a.sendOtpVendorView, exports.sendOtpVendorViewSuccess = _a.sendOtpVendorViewSuccess, exports.sendOtpVendorViewFailure = _a.sendOtpVendorViewFailure, exports.resendOtpVendorView = _a.resendOtpVendorView, exports.verifyOtpVendorView = _a.verifyOtpVendorView, exports.verifyOtpVendorViewSuccess = _a.verifyOtpVendorViewSuccess, exports.verifyOtpVendorViewFailure = _a.verifyOtpVendorViewFailure, exports.verifyUser = _a.verifyUser, exports.verifyUserSuccess = _a.verifyUserSuccess, exports.verifyUserFailure = _a.verifyUserFailure, exports.clearVendorView = _a.clearVendorView, exports.fetchAndUpdateVendorRecommendations = _a.fetchAndUpdateVendorRecommendations, exports.updateRecommendationsInVendorDetailLocalData = _a.updateRecommendationsInVendorDetailLocalData, exports.waitForVendorRecommendationAndUpdatedRecommendationByLineId = _a.waitForVendorRecommendationAndUpdatedRecommendationByLineId;
521
+ _a = vendorView.actions, exports.fetchVendorDetails = _a.fetchVendorDetails, exports.fetchVendor = _a.fetchVendor, exports.updateVendorFetchStatus = _a.updateVendorFetchStatus, exports.updateVendorSaveStatus = _a.updateVendorSaveStatus, exports.updateBankAccountsInVendorView = _a.updateBankAccountsInVendorView, exports.removeBankAccountsInVendorView = _a.removeBankAccountsInVendorView, exports.updatePaymentInstrumentsInVendorView = _a.updatePaymentInstrumentsInVendorView, exports.removePaymentInstrumentsInVendorView = _a.removePaymentInstrumentsInVendorView, exports.updateCountryCurrencyInVendorView = _a.updateCountryCurrencyInVendorView, exports.saveVendor = _a.saveVendor, exports.saveVendorSuccessOrFailure = _a.saveVendorSuccessOrFailure, exports.updateSelectedVendorForCreateFlow = _a.updateSelectedVendorForCreateFlow, exports.initializeVendorAddress = _a.initializeVendorAddress, exports.updateVendorDetailLocalData = _a.updateVendorDetailLocalData, exports.resetVendorDetailLocalData = _a.resetVendorDetailLocalData, exports.updateContactsInVendorDetailLocalData = _a.updateContactsInVendorDetailLocalData, exports.fetchVendorDetailPageView = _a.fetchVendorDetailPageView, exports.fetchUserDetails = _a.fetchUserDetails, exports.fetchUserDetailsSuccess = _a.fetchUserDetailsSuccess, exports.fetchUserDetailsFailure = _a.fetchUserDetailsFailure, exports.sendOtp = _a.sendOtp, exports.sendOtpSuccess = _a.sendOtpSuccess, exports.sendOtpFailure = _a.sendOtpFailure, exports.resendOtp = _a.resendOtp, exports.verifyOtp = _a.verifyOtp, exports.verifyOtpSuccess = _a.verifyOtpSuccess, exports.verifyOtpFailure = _a.verifyOtpFailure, exports.verifyUser = _a.verifyUser, exports.verifyUserSuccess = _a.verifyUserSuccess, exports.clearVendorView = _a.clearVendorView, exports.fetchAndUpdateVendorRecommendations = _a.fetchAndUpdateVendorRecommendations, exports.updateRecommendationsInVendorDetailLocalData = _a.updateRecommendationsInVendorDetailLocalData, exports.waitForVendorRecommendationAndUpdatedRecommendationByLineId = _a.waitForVendorRecommendationAndUpdatedRecommendationByLineId;
493
522
  exports.default = vendorView.reducer;
@@ -0,0 +1,7 @@
1
+ import { ActionsObservable, StateObservable } from 'redux-observable';
2
+ import { Observable } from 'rxjs';
3
+ import { RootState } from '../../../../../reducer';
4
+ import { ZeniAPI } from '../../../../../zeniAPI';
5
+ import { resendOnboardingOfficerOtp, sendOnboardingOfficerOtpSuccess, sendOnboardingOfficerOtpFailure } from '../../onboardingCustomerViewReducer';
6
+ export declare type ActionType = ReturnType<typeof resendOnboardingOfficerOtp> | ReturnType<typeof sendOnboardingOfficerOtpSuccess> | ReturnType<typeof sendOnboardingOfficerOtpFailure>;
7
+ export declare const resendOnboardingOfficerOtpEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => Observable<ActionType>;
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.resendOnboardingOfficerOtpEpic = void 0;
4
+ const rxjs_1 = require("rxjs");
5
+ const operators_1 = require("rxjs/operators");
6
+ const responsePayload_1 = require("../../../../../responsePayload");
7
+ const onboardingCustomerViewReducer_1 = require("../../onboardingCustomerViewReducer");
8
+ const resendOnboardingOfficerOtpEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(onboardingCustomerViewReducer_1.resendOnboardingOfficerOtp.match), (0, operators_1.mergeMap)((action) => {
9
+ const payload = {
10
+ otp_challenge: action.payload.otpChallenge,
11
+ };
12
+ return zeniAPI
13
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.authMicroServiceBaseUrl}/1.0/otp/resend`, payload)
14
+ .pipe((0, operators_1.mergeMap)((response) => {
15
+ if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
16
+ return (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpSuccess)(response.data.otp_challenge));
17
+ }
18
+ else {
19
+ return (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpFailure)(response.status));
20
+ }
21
+ }), (0, operators_1.catchError)((error) => (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpFailure)((0, responsePayload_1.createZeniAPIStatus)('Unexpected Error', 'Resend onboarding officer otp api errored out' +
22
+ JSON.stringify(error))))));
23
+ }));
24
+ exports.resendOnboardingOfficerOtpEpic = resendOnboardingOfficerOtpEpic;
@@ -0,0 +1,7 @@
1
+ import { ActionsObservable, StateObservable } from 'redux-observable';
2
+ import { Observable } from 'rxjs';
3
+ import { RootState } from '../../../../../reducer';
4
+ import { ZeniAPI } from '../../../../../zeniAPI';
5
+ import { sendOnboardingOfficerOtp, sendOnboardingOfficerOtpSuccess, sendOnboardingOfficerOtpFailure } from '../../onboardingCustomerViewReducer';
6
+ export declare type ActionType = ReturnType<typeof sendOnboardingOfficerOtp> | ReturnType<typeof sendOnboardingOfficerOtpSuccess> | ReturnType<typeof sendOnboardingOfficerOtpFailure>;
7
+ export declare const sendOnboardingOfficerOtpEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => Observable<ActionType>;
@@ -0,0 +1,27 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.sendOnboardingOfficerOtpEpic = void 0;
4
+ const rxjs_1 = require("rxjs");
5
+ const operators_1 = require("rxjs/operators");
6
+ const responsePayload_1 = require("../../../../../responsePayload");
7
+ const onboardingCustomerViewReducer_1 = require("../../onboardingCustomerViewReducer");
8
+ const sendOnboardingOfficerOtpEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(onboardingCustomerViewReducer_1.sendOnboardingOfficerOtp.match), (0, operators_1.mergeMap)((action) => {
9
+ const payload = {
10
+ channel_type: 'phone',
11
+ channel_info: {
12
+ phone_number: action.payload.phoneNumber,
13
+ },
14
+ };
15
+ return zeniAPI
16
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.authMicroServiceBaseUrl}/1.0/otp/send`, payload)
17
+ .pipe((0, operators_1.mergeMap)((response) => {
18
+ if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
19
+ return (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpSuccess)(response.data.otp_challenge));
20
+ }
21
+ else {
22
+ return (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpFailure)(response.status));
23
+ }
24
+ }), (0, operators_1.catchError)((error) => (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.sendOnboardingOfficerOtpFailure)((0, responsePayload_1.createZeniAPIStatus)('Unexpected Error', 'Send onboarding officer otp api errored out' +
25
+ JSON.stringify(error))))));
26
+ }));
27
+ exports.sendOnboardingOfficerOtpEpic = sendOnboardingOfficerOtpEpic;
@@ -0,0 +1,7 @@
1
+ import { ActionsObservable, StateObservable } from 'redux-observable';
2
+ import { Observable } from 'rxjs';
3
+ import { RootState } from '../../../../../reducer';
4
+ import { ZeniAPI } from '../../../../../zeniAPI';
5
+ import { verifyOnboardingOfficerOtp, verifyOnboardingOfficerOtpSuccess, verifyOnboardingOfficerOtpFailure } from '../../onboardingCustomerViewReducer';
6
+ export declare type ActionType = ReturnType<typeof verifyOnboardingOfficerOtp> | ReturnType<typeof verifyOnboardingOfficerOtpSuccess> | ReturnType<typeof verifyOnboardingOfficerOtpFailure>;
7
+ export declare const verifyOnboardingOfficerOtpEpic: (actions$: ActionsObservable<ActionType>, _state$: StateObservable<RootState>, zeniAPI: ZeniAPI) => Observable<ActionType>;
@@ -0,0 +1,30 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.verifyOnboardingOfficerOtpEpic = void 0;
4
+ const rxjs_1 = require("rxjs");
5
+ const operators_1 = require("rxjs/operators");
6
+ const responsePayload_1 = require("../../../../../responsePayload");
7
+ const onboardingCustomerViewReducer_1 = require("../../onboardingCustomerViewReducer");
8
+ const verifyOnboardingOfficerOtpEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(onboardingCustomerViewReducer_1.verifyOnboardingOfficerOtp.match), (0, operators_1.mergeMap)((action) => {
9
+ const payload = {
10
+ otp_code: action.payload.otpCode,
11
+ otp_challenge: action.payload.otpChallenge,
12
+ };
13
+ return zeniAPI
14
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.authMicroServiceBaseUrl}/1.0/otp/verify`, payload)
15
+ .pipe((0, operators_1.mergeMap)((response) => {
16
+ if ((0, responsePayload_1.isSuccessResponse)(response) &&
17
+ response.data != null &&
18
+ response.data.is_verified === true) {
19
+ const actions = [
20
+ (0, onboardingCustomerViewReducer_1.verifyOnboardingOfficerOtpSuccess)(),
21
+ ];
22
+ return (0, rxjs_1.from)(actions);
23
+ }
24
+ else {
25
+ return (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.verifyOnboardingOfficerOtpFailure)(response.status));
26
+ }
27
+ }), (0, operators_1.catchError)((error) => (0, rxjs_1.of)((0, onboardingCustomerViewReducer_1.verifyOnboardingOfficerOtpFailure)((0, responsePayload_1.createZeniAPIStatus)('Unexpected Error', 'Verify onboarding officer otp api errored out' +
28
+ JSON.stringify(error))))));
29
+ }));
30
+ exports.verifyOnboardingOfficerOtpEpic = verifyOnboardingOfficerOtpEpic;
@@ -70,8 +70,15 @@ export declare const fetchOnboardingCustomerView: import("@reduxjs/toolkit").Act
70
70
  }, string>, saveOnboardingCustomerViewDataInLocalStore: import("@reduxjs/toolkit").ActionCreatorWithPayload<Partial<import("../../spendManagement/commonSetup/setupViewState").SetupViewLocalData>, string>, saveOnboardingCompnayOfficerPhoneInLocalStore: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
71
71
  officerType: CompanyOfficerType;
72
72
  phone: string | number;
73
- }, string>, updateOnboardingCustomerViewUIState: import("@reduxjs/toolkit").ActionCreatorWithPayload<Partial<OnboardingCustomerViewUIState>, string>, sendOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, sendOnboardingOfficerOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
73
+ }, string>, updateOnboardingCustomerViewUIState: import("@reduxjs/toolkit").ActionCreatorWithPayload<Partial<OnboardingCustomerViewUIState>, string>, sendOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[phoneNumber: string], {
74
+ phoneNumber: string;
75
+ }, string, never, never>, sendOnboardingOfficerOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpChallenge: string], {
74
76
  otpChallenge: string;
75
- }, string>, sendOnboardingOfficerOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, string>, resendOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOnboardingOfficerOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOnboardingOfficerOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, string>, clearOnboardingCustomerViewDataInLocalStore: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, clearOnboardingCustomerView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>;
77
+ }, string, never, never>, sendOnboardingOfficerOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, resendOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpChallenge: string], {
78
+ otpChallenge: string;
79
+ }, string, never, never>, verifyOnboardingOfficerOtp: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[otpCode: string, otpChallenge: string], {
80
+ otpCode: string;
81
+ otpChallenge: string;
82
+ }, string, never, never>, verifyOnboardingOfficerOtpSuccess: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, verifyOnboardingOfficerOtpFailure: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[error: ZeniAPIStatus<Record<string, unknown>>], ZeniAPIStatus<Record<string, unknown>>, string, never, never>, clearOnboardingCustomerViewDataInLocalStore: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>, clearOnboardingCustomerView: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>;
76
83
  declare const _default: import("@reduxjs/toolkit").Reducer<OnboardingCustomerViewState, import("@reduxjs/toolkit").AnyAction>;
77
84
  export default _default;
@@ -457,74 +457,100 @@ const onboardingCustomerView = (0, toolkit_1.createSlice)({
457
457
  const updatedUiState = action.payload;
458
458
  draft.uiState = Object.assign(Object.assign({}, draft.uiState), updatedUiState);
459
459
  },
460
- sendOnboardingOfficerOtp(draft) {
461
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
462
- var _a;
463
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
464
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
465
- draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
466
- fetchState: 'In-Progress',
467
- error: undefined,
468
- };
469
- draft.companyOfficerUpdateStatus[officerType].localData =
470
- Object.assign({}, draft.companyOfficerUpdateStatus[officerType].localData, {
471
- isPhoneVerified: false,
472
- });
473
- }
474
- });
460
+ sendOnboardingOfficerOtp: {
461
+ reducer(draft) {
462
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
463
+ var _a;
464
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
465
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
466
+ draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
467
+ fetchState: 'In-Progress',
468
+ error: undefined,
469
+ };
470
+ draft.companyOfficerUpdateStatus[officerType].localData =
471
+ Object.assign({}, draft.companyOfficerUpdateStatus[officerType].localData, {
472
+ isPhoneVerified: false,
473
+ });
474
+ }
475
+ });
476
+ },
477
+ prepare(phoneNumber) {
478
+ return { payload: { phoneNumber } };
479
+ },
475
480
  },
476
- resendOnboardingOfficerOtp(draft) {
477
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
478
- var _a;
479
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
480
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
481
- draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
482
- fetchState: 'In-Progress',
483
- error: undefined,
484
- };
485
- }
486
- });
481
+ resendOnboardingOfficerOtp: {
482
+ reducer(draft) {
483
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
484
+ var _a;
485
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
486
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
487
+ draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
488
+ fetchState: 'In-Progress',
489
+ error: undefined,
490
+ };
491
+ }
492
+ });
493
+ },
494
+ prepare(otpChallenge) {
495
+ return { payload: { otpChallenge } };
496
+ },
487
497
  },
488
- sendOnboardingOfficerOtpSuccess(draft, action) {
489
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
490
- var _a;
491
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
492
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
493
- draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
494
- fetchState: 'Completed',
495
- error: undefined,
496
- };
497
- draft.companyOfficerUpdateStatus[officerType].localData =
498
- Object.assign({}, draft.companyOfficerUpdateStatus[officerType].localData, {
499
- otpChallenge: action.payload.otpChallenge,
500
- });
501
- }
502
- });
498
+ sendOnboardingOfficerOtpSuccess: {
499
+ reducer(draft, action) {
500
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
501
+ var _a;
502
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
503
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
504
+ draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
505
+ fetchState: 'Completed',
506
+ error: undefined,
507
+ };
508
+ draft.companyOfficerUpdateStatus[officerType].localData =
509
+ Object.assign({}, draft.companyOfficerUpdateStatus[officerType].localData, {
510
+ otpChallenge: action.payload.otpChallenge,
511
+ });
512
+ }
513
+ });
514
+ },
515
+ prepare(otpChallenge) {
516
+ return { payload: { otpChallenge } };
517
+ },
503
518
  },
504
- sendOnboardingOfficerOtpFailure(draft, action) {
505
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
506
- var _a;
507
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
508
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
509
- draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
510
- fetchState: 'Error',
511
- error: action.payload,
512
- };
513
- }
514
- });
519
+ sendOnboardingOfficerOtpFailure: {
520
+ reducer(draft, action) {
521
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
522
+ var _a;
523
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
524
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
525
+ draft.companyOfficerUpdateStatus[officerType].sendOtpStatus = {
526
+ fetchState: 'Error',
527
+ error: action.payload,
528
+ };
529
+ }
530
+ });
531
+ },
532
+ prepare(error) {
533
+ return {
534
+ payload: error,
535
+ };
536
+ },
515
537
  },
516
- verifyOnboardingOfficerOtp(draft) {
517
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
518
- var _a;
519
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
520
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
521
- draft.companyOfficerUpdateStatus[officerType].otpverificationStatus =
522
- {
538
+ verifyOnboardingOfficerOtp: {
539
+ reducer(draft) {
540
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
541
+ var _a;
542
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
543
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
544
+ draft.companyOfficerUpdateStatus[officerType].otpverificationStatus = {
523
545
  fetchState: 'In-Progress',
524
546
  error: undefined,
525
547
  };
526
- }
527
- });
548
+ }
549
+ });
550
+ },
551
+ prepare(otpCode, otpChallenge) {
552
+ return { payload: { otpCode, otpChallenge } };
553
+ },
528
554
  },
529
555
  verifyOnboardingOfficerOtpSuccess(draft) {
530
556
  Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
@@ -543,18 +569,24 @@ const onboardingCustomerView = (0, toolkit_1.createSlice)({
543
569
  }
544
570
  });
545
571
  },
546
- verifyOnboardingOfficerOtpFailure(draft, action) {
547
- Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
548
- var _a;
549
- if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
550
- ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
551
- draft.companyOfficerUpdateStatus[officerType].otpverificationStatus =
552
- {
572
+ verifyOnboardingOfficerOtpFailure: {
573
+ reducer(draft, action) {
574
+ Object.keys(draft.companyOfficerUpdateStatus).forEach((officerType) => {
575
+ var _a;
576
+ if (draft.companyOfficerUpdateStatus[officerType].localData != null &&
577
+ ((_a = draft.companyOfficerUpdateStatus[officerType].localData) === null || _a === void 0 ? void 0 : _a.isSelectedForVerification) === true) {
578
+ draft.companyOfficerUpdateStatus[officerType].otpverificationStatus = {
553
579
  fetchState: 'Error',
554
580
  error: action.payload,
555
581
  };
556
- }
557
- });
582
+ }
583
+ });
584
+ },
585
+ prepare(error) {
586
+ return {
587
+ payload: error,
588
+ };
589
+ },
558
590
  },
559
591
  clearOnboardingCustomerViewDataInLocalStore(draft) {
560
592
  draft.companyOfficerUpdateStatus =
@@ -26,7 +26,7 @@ export declare const changeZeniPersonRolesEpic: (actions$: ActionsObservable<Act
26
26
  type: string;
27
27
  } | {
28
28
  payload: {
29
- messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term" | "update_charge_card";
29
+ messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term";
30
30
  messageText: "failed" | "success";
31
31
  type: import("../..").SnackbarMessageType;
32
32
  showStatusIcon?: boolean | undefined;
@@ -18,7 +18,7 @@ export declare const deletePersonEpic: (actions$: ActionsObservable<ActionType>,
18
18
  type: string;
19
19
  } | {
20
20
  payload: {
21
- messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term" | "update_charge_card";
21
+ messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term";
22
22
  messageText: "failed" | "success";
23
23
  type: import("../..").SnackbarMessageType;
24
24
  showStatusIcon?: boolean | undefined;
@@ -35,7 +35,7 @@ export declare const invitePeopleEpic: (actions$: ActionsObservable<ActionType>,
35
35
  type: string;
36
36
  } | {
37
37
  payload: {
38
- messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term" | "update_charge_card";
38
+ messageSection: "common" | "transactionDetails_updatingPastTransactions" | "transactionDetails_transactionUpdated" | "cockpit_monthEndEmailSent" | "cockpit_monthEndEmailSave" | "people_invite_people" | "people_invite_multiple_people" | "people_delete_person" | "people_update_person" | "reimbursement_updated" | "reimbursement_deleted" | "reimbursement_cancelled_deleted" | "reimbursement_cancelled" | "reimbursement_approved" | "reimbursement_rejected" | "reimbursement_sent_for_approval" | "account_added" | "business_verification_save" | "business_verification_submit" | "business_verification_from_bills_submit" | "plaid_connection" | "unlink_deposit_account" | "reimbursement_setup" | "reimbursement_approval_create" | "reimbursement_duplicate_approval_create" | "reimbursement_approval_update" | "reimbursement_duplicate_approval_update" | "reimbursement_approval_delete" | "reimbursement_create_mileage" | "reimbursement_update_mileage" | "reimbursement_accept_term" | "reimbursement_accept_employee_term" | "bill_pay_setup" | "zeni_accounts_setup" | "bill_pay_approval_create" | "bill_pay_duplicate_approval_create" | "bill_pay_approval_update" | "bill_pay_duplicate_approval_update" | "bill_pay_approval_delete" | "bill_pay_updated" | "bill_pay_deleted" | "bill_pay_cancelled_deleted" | "bill_pay_cancelled" | "bill_pay_approved" | "real_time_approver_added" | "bill_pay_rejected" | "bill_pay_sent_for_approval" | "bill_pay_accept_term" | "zeni_account_accept_term" | "update_vendor" | "delete_bank_account" | "create_bank_account" | "create_bank_account_ach" | "create_bank_account_wire" | "create_bank_account_international" | "transfer_money" | "update_zeni_account_nickname" | "create_checking_account" | "deposit_check" | "create_vendor" | "onboarding_customer_view" | "onboarding_customer_view_complete" | "onboarding_customer_identity_verification_save" | "onboarding_customer_identity_verification_submit" | "onboarding_customer_business_verification_save" | "onboarding_customer_business_verification_submit" | "retry_bank_account_connection" | "dashboard_invite_sent" | "onboarding_info_saved" | "approve_original_merchant" | "approve_global_merchant" | "create_global_merchant" | "fetch_global_merchant_no_recommendation" | "save_vendor_renamed" | "save_vendor_sent_for_review" | "charge_card_setup" | "charge_card_accept_term";
39
39
  messageText: "failed" | "success";
40
40
  type: import("../..").SnackbarMessageType;
41
41
  showStatusIcon?: boolean | undefined;