@zeniai/client-epic-state 5.2.22-betaAM5 → 5.2.22-betaMM2

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 (42) hide show
  1. package/lib/entity/actualMatching/actualMatchingPayload.js +4 -3
  2. package/lib/entity/actualMatching/actualMatchingReducer.js +1 -1
  3. package/lib/entity/actualMatching/actualMatchingSelector.d.ts +1 -1
  4. package/lib/entity/actualMatching/actualMatchingSelector.js +1 -1
  5. package/lib/entity/jeSchedules/jeSchedulesPayload.d.ts +2 -0
  6. package/lib/entity/jeSchedules/jeSchedulesPayload.js +2 -0
  7. package/lib/entity/jeSchedules/jeSchedulesState.d.ts +2 -0
  8. package/lib/epic.d.ts +2 -1
  9. package/lib/epic.js +2 -0
  10. package/lib/esm/entity/actualMatching/actualMatchingPayload.js +5 -4
  11. package/lib/esm/entity/actualMatching/actualMatchingReducer.js +1 -1
  12. package/lib/esm/entity/actualMatching/actualMatchingSelector.js +1 -1
  13. package/lib/esm/entity/jeSchedules/jeSchedulesPayload.js +2 -0
  14. package/lib/esm/epic.js +2 -0
  15. package/lib/esm/index.js +4 -4
  16. package/lib/esm/view/expenseAutomationView/epics/actualMatching/fetchActualMatchingEpic.js +4 -4
  17. package/lib/esm/view/expenseAutomationView/epics/actualMatching/matchAndReverseAccrualsEpic.js +5 -3
  18. package/lib/esm/view/expenseAutomationView/epics/actualMatching/searchMatchAccrualsEpic.js +1 -1
  19. package/lib/esm/view/expenseAutomationView/epics/actualMatching/searchMatchTransactionsEpic.js +2 -2
  20. package/lib/esm/view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic.js +52 -0
  21. package/lib/esm/view/expenseAutomationView/payload/actualMatchingPayload.js +9 -1
  22. package/lib/esm/view/expenseAutomationView/reducers/actualMatchingViewReducer.js +26 -1
  23. package/lib/esm/view/expenseAutomationView/selectors/actualMatchingViewSelector.js +9 -9
  24. package/lib/esm/view/expenseAutomationView/types/actualMatchingViewState.js +6 -0
  25. package/lib/index.d.ts +4 -4
  26. package/lib/index.js +50 -48
  27. package/lib/view/expenseAutomationView/epics/actualMatching/fetchActualMatchingEpic.js +3 -3
  28. package/lib/view/expenseAutomationView/epics/actualMatching/matchAndReverseAccrualsEpic.js +5 -3
  29. package/lib/view/expenseAutomationView/epics/actualMatching/searchMatchAccrualsEpic.js +1 -1
  30. package/lib/view/expenseAutomationView/epics/actualMatching/searchMatchTransactionsEpic.js +2 -2
  31. package/lib/view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic.d.ts +8 -0
  32. package/lib/view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic.js +56 -0
  33. package/lib/view/expenseAutomationView/payload/actualMatchingPayload.d.ts +17 -1
  34. package/lib/view/expenseAutomationView/payload/actualMatchingPayload.js +9 -0
  35. package/lib/view/expenseAutomationView/reducers/actualMatchingViewReducer.d.ts +6 -2
  36. package/lib/view/expenseAutomationView/reducers/actualMatchingViewReducer.js +27 -2
  37. package/lib/view/expenseAutomationView/selectorTypes/actualMatchingViewSelectorTypes.d.ts +1 -0
  38. package/lib/view/expenseAutomationView/selectors/actualMatchingViewSelector.d.ts +5 -1
  39. package/lib/view/expenseAutomationView/selectors/actualMatchingViewSelector.js +9 -9
  40. package/lib/view/expenseAutomationView/types/actualMatchingViewState.d.ts +13 -0
  41. package/lib/view/expenseAutomationView/types/actualMatchingViewState.js +8 -1
  42. package/package.json +1 -1
@@ -14,6 +14,7 @@ function toMatchKind(raw) {
14
14
  if (MATCH_KINDS.includes(raw)) {
15
15
  return raw;
16
16
  }
17
+ console.error(`Unknown ActualMatchingMatchKind: ${raw}`);
17
18
  return 'auto_reversed';
18
19
  }
19
20
  function toActualMatchingMatch(payload) {
@@ -35,8 +36,8 @@ function toActualMatchingMatch(payload) {
35
36
  kind: toMatchKind(payload.kind),
36
37
  matchTier: payload.match_tier ?? undefined,
37
38
  matchShape: payload.match_shape ?? undefined,
38
- accruedAmount: (0, amount_1.toAmount)(payload.accrued_amount ?? 0, currencyCode, currencySymbol),
39
- actualAmount: (0, amount_1.toAmount)(payload.actual_amount ?? 0, currencyCode, currencySymbol),
40
- members: (payload.members ?? []).map(jeSchedulesPayload_1.toJEOneTimeAccrual),
39
+ accruedAmount: (0, amount_1.toAmount)(payload.accrued_amount, currencyCode, currencySymbol),
40
+ actualAmount: (0, amount_1.toAmount)(payload.actual_amount, currencyCode, currencySymbol),
41
+ members: payload.members.map(jeSchedulesPayload_1.toJEOneTimeAccrual),
41
42
  };
42
43
  }
@@ -25,7 +25,7 @@ const actualMatching = (0, toolkit_1.createSlice)({
25
25
  },
26
26
  extraReducers: (builder) => {
27
27
  builder.addCase(rootActions_1.clearAll, (draft) => {
28
- draft.byMatchId = {};
28
+ Object.assign(draft, exports.initialState);
29
29
  });
30
30
  },
31
31
  });
@@ -1,3 +1,3 @@
1
1
  import { ActualMatchingMatch, ActualMatchingState } from './actualMatchingState';
2
2
  import { ActualMatchingMatchId } from './actualMatchingTypes';
3
- export declare function getActualMatchingMatchById(matchId: ActualMatchingMatchId, actualMatchingState: ActualMatchingState): ActualMatchingMatch | undefined;
3
+ export declare function getActualMatchingMatchById(actualMatchingState: ActualMatchingState, matchId: ActualMatchingMatchId): ActualMatchingMatch | undefined;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getActualMatchingMatchById = getActualMatchingMatchById;
4
- function getActualMatchingMatchById(matchId, actualMatchingState) {
4
+ function getActualMatchingMatchById(actualMatchingState, matchId) {
5
5
  return actualMatchingState.byMatchId[matchId];
6
6
  }
@@ -138,6 +138,7 @@ export interface JEOneTimeAccrualClearedPayload {
138
138
  matched_transaction_date?: string | null;
139
139
  matched_transaction_id?: string | null;
140
140
  matched_transaction_integration_id?: string | null;
141
+ matched_transaction_sync_token?: string | null;
141
142
  matched_transaction_type?: string | null;
142
143
  reversed_at?: string | null;
143
144
  }
@@ -148,6 +149,7 @@ export interface JEOneTimeAccrualMatchSuggestionPayload {
148
149
  matched_transaction_date?: string | null;
149
150
  matched_transaction_id?: string | null;
150
151
  matched_transaction_integration_id?: string | null;
152
+ matched_transaction_sync_token?: string | null;
151
153
  matched_transaction_type?: string | null;
152
154
  resolution?: string | null;
153
155
  }
@@ -478,6 +478,7 @@ function toJEOneTimeAccrualCleared(payload, currencyCode) {
478
478
  : undefined,
479
479
  matchTier: payload.match_tier ?? undefined,
480
480
  matchShape: payload.match_shape ?? undefined,
481
+ matchedTransactionSyncToken: payload.matched_transaction_sync_token ?? undefined,
481
482
  };
482
483
  }
483
484
  function toJEOneTimeAccrualMatchSuggestion(payload, currencyCode) {
@@ -497,6 +498,7 @@ function toJEOneTimeAccrualMatchSuggestion(payload, currencyCode) {
497
498
  matchedTransactionDate: payload.matched_transaction_date != null
498
499
  ? (0, zeniDayJS_1.date)(payload.matched_transaction_date)
499
500
  : undefined,
501
+ matchedTransactionSyncToken: payload.matched_transaction_sync_token ?? undefined,
500
502
  };
501
503
  }
502
504
  function toJEOneTimeAccrual(payload) {
@@ -207,6 +207,7 @@ export interface JEOneTimeAccrualCleared {
207
207
  matchedTransactionDate?: ZeniDate;
208
208
  matchedTransactionId?: string;
209
209
  matchedTransactionIntegrationId?: string;
210
+ matchedTransactionSyncToken?: string;
210
211
  matchedTransactionType?: string;
211
212
  matchShape?: string;
212
213
  matchTier?: string;
@@ -219,6 +220,7 @@ export interface JEOneTimeAccrualMatchSuggestion {
219
220
  matchedTransactionDate?: ZeniDate;
220
221
  matchedTransactionId?: string;
221
222
  matchedTransactionIntegrationId?: string;
223
+ matchedTransactionSyncToken?: string;
222
224
  matchedTransactionType?: string;
223
225
  matchTier?: string;
224
226
  resolution?: string;
package/lib/epic.d.ts CHANGED
@@ -178,6 +178,7 @@ import { ActionType as FetchExpenseAutomationActualMatchingPageActionType } from
178
178
  import { ActionType as MatchAndReverseAccrualsActionType } from './view/expenseAutomationView/epics/actualMatching/matchAndReverseAccrualsEpic';
179
179
  import { ActionType as SearchMatchAccrualsActionType } from './view/expenseAutomationView/epics/actualMatching/searchMatchAccrualsEpic';
180
180
  import { ActionType as SearchMatchTransactionsActionType } from './view/expenseAutomationView/epics/actualMatching/searchMatchTransactionsEpic';
181
+ import { ActionType as UndoReversalAccrualsActionType } from './view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic';
181
182
  import { ActionType as FetchAllExpenseAutomationTabsActionType } from './view/expenseAutomationView/epics/common/fetchAllExpenseAutomationTabsEpic';
182
183
  import { ActionType as RefreshExpenseAutomationCurrentTabActionType } from './view/expenseAutomationView/epics/common/refreshExpenseAutomationCurrentTabEpic';
183
184
  import { ActionType as FetchExpenseAutomationFluxAnalysisActionType } from './view/expenseAutomationView/epics/fluxAnalysis/fetchFluxAnalysisViewEpic';
@@ -682,5 +683,5 @@ import { ActionType as FetchDepositAccStatementListActionType } from './view/zen
682
683
  import { ActionType as FetchZeniAccStatePageActionType } from './view/zeniAccStatementList/fetchZeniAccStatementPageEpic';
683
684
  import { ActionType as ApproveOAuthConsentActionType } from './view/zeniOAuthView/epics/approveOAuthConsentEpic';
684
685
  /** Root action type is union of all the epic action type */
685
- export type RootActionType = AcceptBillPayTermsActionType | AcceptBillPayUpdatedTermsActionType | AcceptChargeCardTermsActionType | AcceptEmployeeRemiTermsActionType | AcceptMasterTOSEpicActionType | AcceptRemiTermsActionType | AcceptTreasuryTermsActionType | AcceptZeniAccountTermsActionType | AcknowledgeOnboardingAiActivationViewedActionType | AcknowledgeOnboardingAiFinanceTeamActionType | AddCardPaymentSourceActionType | ApplyExtractedPolicyToDraftActionType | ApproveOAuthConsentActionType | ApproveOrRejectBillActionType | ApproveOrRejectBillsBulkActionActionType | ApproveOrRejectRemiActionType | ApproveOrRejectRemisBulkActionActionType | ApproveVendorGlobalReviewActionType | ArchiveCardPolicyActionType | ArchiveTaskActionType | BackgroundRefetchReviewTabActionType | BalanceSheetActionType | BalanceSheetClassesViewActionType | BalanceSheetForTimeframeActionType | BalanceSheetForTimeframeClassesViewActionType | BalanceSheetForTimeframeProjectViewActionType | BalanceSheetProjectViewActionType | BulkUpdateTasksListActionType | BulkUploadMatchResultToastActionType | BulkUploadReceiptsActionType | CancelAiAccountantOnboardingActionType | CancelAndDeleteBillActionType | CancelAndDeleteRemiActionType | CancelOrDeleteBillsBulkActionActionType | CancelOrDeleteRemisBulkActionActionType | CancelScheduleAccruedJournalEntryActionType | CardBalanceActionType | CashBalanceActionType | CashFlowActionType | CashFlowForTimeframeActionType | CashInCashOutActionType | CashPositionActionType | ChangeZeniPersonRolesActionType | CheckDepositActionType | CloseChargeCardActionType | CloseChargeCardsActionType | CombinedStatementActionType | CompanyManagementSavePendingUpdatesActionType | CompanyManagementSaveUpdatesActionType | ConfirmBulkUploadMatchActionType | ConfirmCardSetupIntentActionType | ConfirmStatementMappingActionType | CreateAddressActionType | CreateAutoTransferRuleActionType | CreateBankAccountActionType | CreateCardPolicyTemplateActionType | CreateCardSetupIntentActionType | CreateCheckingAccountActionType | CreateCompanyAddressActionType | CreateCompanyOfficersActionType | CreateCompanyUserAddressActionType | CreateGlobalMerchantActionType | CreateInternationalBankAccountActionType | CreateInvoiceActionType | CreateNewSchedulesAccruedActionType | CreateNewSchedulesActionType | CreateNewTaskGroupActionType | CreateOneTimeAccrualActionType | CreatePaymentInstrumentActionType | CreateSessionActionType | CreateSessionAndSubmitActionType | CreateSubTaskActionType | CreateTagActionType | CreateTaskFromTaskGroupTemplateActionType | CreateTransferEntryActionType | CreateUserBankAccountActionType | CurrencyConversionActionType | DeleteAccountStatementActionType | DeleteAutoTransferRuleActionType | DeleteBankAccountActionType | DeleteBillActionType | DeleteBillPayApprovalRuleActionType | DeleteCannedResponseActionType | DeleteChatSessionActionType | DeleteCombinedStatementActionType | DeleteFileActionType | DeleteFileListActionType | DeleteInternationalBankAccountActionType | DeletePaymentInstrumentActionType | DeletePersonActionType | DeleteRemiActionType | DeleteRemiApprovalRuleActionType | DeleteScheduleAccruedDetailActionType | DeleteScheduleDetailActionType | DeleteTagActionType | DeleteTaskActionType | DeleteTaskGroupActionType | DeleteTransactionAttachmentActionType | DeleteUserBankAccountActionType | DepositAccountTransactionListActionType | DisableAccountingProjectsActionType | DismissCapitalizationOnboardingActionType | DoMagicLinkSignInActionType | DownloadAccountingProviderAttachmentActionType | DragNDropTasksActionType | EditInvoicingCatalogItemDetailViewActionType | EditInvoicingCouponDetailViewActionType | EditInvoicingCustomerDetailViewActionType | EditInvoicingSubscriptionDetailViewActionType | EnableAccountingProjectsActionType | EnableChargeCardAutoPayActionType | EnableSetupActionType | EstablishOnboardingPlaidConnectionActionType | EstablishPlaidConnectionActionType | ExcludeAccountFromReconciliationActionType | ExpressInterestChargeCardActionType | ExpressPayActionType | ExtractPolicyDocumentActionType | FetchAccountHistoryActionType | FetchAccountListActionType | FetchAccountListForAccountTypesActionType | FetchAccountSettingsListForAccountTypesActionType | FetchAccruedScheduleListActionType | FetchActiveTenantActionType | FetchAddressActionType | FetchAggregatedReportActionType | FetchAiAccountantCustomersActionType | FetchAiAccountantJobsActionType | FetchAiAgentsActivationStatusActionType | FetchAllCockpitViewsActionType | FetchAllExpenseAutomationTabsActionType | FetchAllPeopleRequiredActionType | FetchAllTagsActionType | FetchAllTaskGroupsActionType | FetchAllTenantsActionType | FetchApAgingActionType | FetchApAgingDetailActionType | FetchArAgingActionType | FetchArAgingDetailActionType | FetchAuditReportGroupViewActionType | FetchAuditRuleGroupViewActionType | FetchAutoTransferReviewDetailActionType | FetchAutoTransferRuleHistoryActionType | FetchAutoTransferRulesActionType | FetchBankAccountsListActionType | FetchBankConnectionsViewActionType | FetchBankCountryNameByIbanActionType | FetchBankNameByRoutingActionType | FetchBankNameBySwiftActionType | FetchBillAndInitializeLocalStoreActionType | FetchBillDetailActionType | FetchBillingAccountsListActionType | FetchBillListActionType | FetchBillListPerTabActionType | FetchBillPayApproversDetailsActionType | FetchBillPayApproversListActionType | FetchBillPayCardActionType | FetchBillPayConfigActionType | FetchBillPaySetupApproverViewActionType | FetchBillPaySetupViewActionType | FetchBulkUploadBatchDetailsActionType | FetchBulkUploadBatchesActionType | FetchCannedResponsesActionType | FetchCardPolicyDetailActionType | FetchCardPolicyListActionType | FetchCardPolicyMccCategoriesActionType | FetchCardPolicyVendorOptionsActionType | FetchCardProfilesActionType | FetchCashbackDetailActionType | FetchChargeCardConfigActionType | FetchChargeCardDetailActionType | FetchChargeCardDetailPageActionType | FetchChargeCardListActionType | FetchChargeCardListPageActionType | FetchChargeCardPaymentHistoryActionType | FetchChargeCardPaymentPageActionType | FetchChargeCardRepaymentDetailActionType | FetchChargeCardSetupViewActionType | FetchChargeCardsRecurringExpensesActionType | FetchChargeCardStatementListActionType | FetchChargeCardTransactionAttachmentsActionType | FetchChargeCardTransactionListActionType | FetchChargeCardTransactionStatisticsActionType | FetchChatHistoryActionType | FetchChatSessionsForUserActionType | FetchClassListActionType | FetchCockpitContextActionType | FetchCollaborationAuthTokenActionType | FetchCompanyBillingAddressActionType | FetchCompanyConfigActionType | FetchCompanyHealthMetricConfigViewEpicActionType | FetchCompanyHealthMetricViewEpicActionType | FetchCompanyManagementActionType | FetchCompanyMetaDataActionType | FetchCompanyMonthEndReportHistoricDataActionType | FetchCompanyMonthEndReportHistoricDatesActionType | FetchCompanyMonthEndReportTemplatesActionType | FetchCompanyMonthEndReportViewActionType | FetchCompanyOnboardingViewActionType | FetchCompanyPassportViewActionType | FetchCompanyPortfolioActionType | FetchCompanyTaskManagerViewActionType | FetchCompletedTransactionsActionType | FetchCreateInvoiceFormPageActionType | FetchCreditAccountActionType | FetchCreditAccountRepaymentActionType | FetchCreditAgentMacroActionType | FetchCurrencyConversionValueActionType | FetchDashboardActionType | FetchDashboardLayoutActionType | FetchDebitCardSummaryActionType | FetchDepositAccountActionType | FetchDepositAccountDetailActionType | FetchDepositAccountLimitActionType | FetchDepositAccountListActionType | FetchDepositAccountListForCardsActionType | FetchDepositAccStatementListActionType | FetchDownloadSchedulesActionType | FetchDuplicateBillActionType | FetchDuplicateReimbursementEpicActionType | FetchEditBillDetailPageActionType | FetchEditRemiDetailPageActionType | FetchEligibleActionsForBillActionType | FetchEntityAutoCompleteActionType | FetchEntityHistoryActionType | FetchEntityRecommendationsByTransactionIdActionType | FetchEntityRecommendationsForLineUpdateActionType | FetchExcludedResourcesActionType | FetchExpenseAutomationActualMatchingActionType | FetchExpenseAutomationActualMatchingMatchActionType | FetchExpenseAutomationActualMatchingPageActionType | FetchExpenseAutomationFluxAnalysisActionType | FetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataActionType | FetchExpenseAutomationJEScheduleActionType | FetchExpenseAutomationJESchedulePageActionType | FetchExpenseAutomationMarkTransactionAsNotMiscategorizedActionType | FetchExpenseAutomationMissingReceiptsActionType | FetchExpenseAutomationReconciliationsViewActionType | FetchExpenseAutomationSaveTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationViewActionType | FetchExpenseAutomationUpdateTransactionCategorizationEpicActionType | FetchExpenseTrendActionType | FetchExternalConnectionsActionType | FetchFileActionType | FetchFileListActionType | FetchForecastListActionType | FetchGlobalMerchantAutoCompleteActionType | FetchGlobalMerchantRecommendationActionType | FetchIncomeTrendActionType | FetchInternationalWireDynamicFormActionType | FetchIntlVerificationFormActionType | FetchInvoiceCountsActionType | FetchInvoiceDetailActionType | FetchInvoiceKPIsActionType | FetchInvoiceListActionType | FetchInvoiceListPageActionType | FetchIssueCardPageActionType | FetchMagicLinkBankNameByRoutingActionType | FetchMagicLinkBankNameBySwiftActionType | FetchMagicLinkBillActionType | FetchMagicLinkTenantActionType | FetchManagementActionType | FetchMerchantListActionType | FetchMonthClosePerformanceTrendActionType | FetchMonthEndCloseChecksActionType | FetchMoreBatchDetailsActionType | FetchMultipleBatchDetailsActionType | FetchMyProfileActionType | FetchMyProfileViewActionType | FetchNetBurnOrIncomeStoryCardActionType | FetchNetBurnOrIncomeWithForecastActionType | FetchNotificationSettingsActionType | FetchNotificationSettingsViewActionType | FetchNotificationUnreadCountActionType | FetchNotificationViewActionType | FetchOnboardingActionType | FetchOnboardingCompletedCompaniesActionType | FetchOnboardingCustomerSetupViewActionType | FetchOnboardingCustomerViewActionType | FetchOneTimeAccrualActionType | FetchOpExWithForecastActionType | FetchOwnerListActionType | FetchParentSubsidiaryManagementActionType | FetchPaymentAccountBalanceActionType | FetchPaymentAccountListActionType | FetchPaymentSourcesActionType | FetchPortfolioActionType | FetchPortfolioAllocationActionType | FetchPreviousBillsActionType | FetchProjectListActionType | FetchQBOConnectionPoolActionType | FetchRecommendationByEntityIdActionType | FetchRecommendationByEntityNameActionType | FetchRecommendationsAndUpdateMerchantRecommendationsActionType | FetchRecommendationsAndUpdateVendorRecommendationsActionType | FetchRecommendedBillExpenseActionType | FetchReferralsActionType | FetchRegisteredInterestsActionType | FetchReimbursementCardActionType | FetchReimbursementConfigActionType | FetchRemiAndInitializeLocalStoreActionType | FetchRemiApproversDetailsActionType | FetchRemiApproversListActionType | FetchRemiDetailActionType | FetchRemiListActionType | FetchRemiListPerTabActionType | FetchRemiSetupApproverViewActionType | FetchRemiSetupViewActionType | FetchRevenueWithForecastActionType | FetchReviewCompanyActionType | FetchReviewTransferDetailActionType | FetchRewardsPlanActionType | FetchScheduleAccruedDetailsActionType | FetchScheduleAccruedDetailsPageActionType | FetchScheduleDetailsActionType | FetchScheduleDetailsPageActionType | FetchScheduleListActionType | FetchSchedulesListActionType | FetchSkillsActionType | FetchSubscriptionActionType | FetchSubscriptionAddOnsActionType | FetchSubscriptionCouponsActionType | FetchSubscriptionCreateEstimateActionType | FetchSubscriptionDetailsActionType | FetchSubscriptionListActionType | FetchSubscriptionPlansActionType | FetchSubscriptionSummaryForTenantActionType | FetchSubscriptionUpdateEstimateActionType | FetchSubTasksActionType | FetchSuggestedQuestionsActionType | FetchTaskDetailActionType | FetchTaskDetailPageActionType | FetchTaskGroupTemplatesActionType | FetchTaskHistoryActionType | FetchTaskListActionType | FetchTaskListPageActionType | FetchTaskManagerMetricsActionType | FetchTasksCardActionType | FetchTransactionActivityLogActionType | FetchTransactionDetailActionType | FetchTransactionListByAccountActionType | FetchTransactionListByClassActionType | FetchTransactionListByEntityActionType | FetchTransactionListByProjectActionType | FetchTransactionsForEntityActionType | FetchTransactionsListByCategoryTypeActionType | FetchTransferAccountsActionType | FetchTreasuryDetailActionType | FetchTreasuryFundsActionType | FetchTreasuryHistoryActionType | FetchTreasurySetupViewActionType | FetchTreasuryStatementListActionType | FetchTreasuryTaxLetterListActionType | FetchTreasuryTransactionListActionType | FetchTrendForEntityActionType | FetchUserDetailActionType | FetchUserFinancialAccountActionType | FetchUserListByTypeActionType | FetchUserRoleConfigActionType | FetchVendor1099TypeListActionType | FetchVendorActionType | FetchVendorAndUpdateBillLocalDataActionType | FetchVendorByNameAndParseInvoiceActionType | FetchVendorDetailsActionType | FetchVendorFirstReviewAttachmentsActionType | FetchVendorFirstReviewViewActionType | FetchVendorGlobalReviewViewActionType | FetchVendorsActionType | FetchVendorsFiling1099ActionType | FetchVendorsFiling1099AllActionType | FetchVendorsFiling1099DownloadActionType | FetchVendorTabViewActionType | FetchVendorTypeListActionType | FetchZeniAccountListPageActionType | FetchZeniAccountsConfigActionType | FetchZeniAccountSetupViewActionType | FetchZeniAccStatePageActionType | FetchZeniUsersActionType | GetOnboardingEmailGroupActionType | GetOnboardingPlaidLinkTokenActionType | GetPaymentAccountsActionType | GetPlaidLinkTokenActionType | IgnoreExpenseAutomationJEScheduleActionType | ImproveUsingZeniGPTActionType | IncludeAccountInReconciliationActionType | InitialiseExpenseAutomationLocalDataForSelectedAccountIdActionType | InitializeAccountMappingViewActionType | InitializeAccountSettingsViewEpicActionType | InitializeBillPaySetupApproverViewUpdateDataActionType | InitializeBillToLocalStoreActionType | InitializeCardUserOnboardingLocalDataActionType | InitializeCompanyHealthMetricViewLocalDataEpicActionType | InitializeEditPersonActionType | InitializeExpenseAutomationJeScheduleLocalDataActionType | InitializeInternationalWireLocalDataActionType | InitializeIntlVerificationFormEpicActionType | InitializeMyProfileLocalDataActionType | InitializeNewScheduleActionType | InitializeOnboardingCustomerViewUpdateDataActionType | InitializeRemiSetupApproverViewUpdateDataActionType | InitializeRemiToLocalStoreActionType | InitializeScheduleAccruedDetailLocalDataActionType | InitializeScheduleDetailLocalDataActionType | InitializeSubscriptionLocalDataActionType | InitializeTaskToLocalStoreActionType | InitializeTransactionDetailLocalDataActionType | InitializeVendorAddressActionType | InitiateChargeCardRepaymentActionType | InitiateReportsClassViewRefetchingActionType | InitiateReportsProjectViewRefetchingActionType | InsightsCardActionType | InvitePeopleActionType | InviteZeniPeopleActionType | InvoicingAuditViewActionType | InvoicingCatalogActionActionType | InvoicingCatalogItemDetailViewActionType | InvoicingCatalogListViewActionType | InvoicingCatalogSubFamilyActionType | InvoicingConfigViewActionType | InvoicingCouponDetailViewActionType | InvoicingCouponViewActionType | InvoicingCreditNoteDetailViewActionType | InvoicingCreditNoteListViewActionType | InvoicingCustomerDetailPageActionType | InvoicingCustomerDetailViewActionType | InvoicingCustomerListViewActionType | InvoicingCustomerPaymentMethodActionType | InvoicingDataImportViewActionType | InvoicingDiscountActionActionType | InvoicingDunningActionActionType | InvoicingDunningCaseDetailViewActionType | InvoicingDunningCaseListViewActionType | InvoicingInvoiceActionActionType | InvoicingOverviewActionType | InvoicingPaymentActionActionType | InvoicingPromotionalCreditActionActionType | InvoicingQboViewActionType | InvoicingSettingsViewActionType | InvoicingSubscriptionActionActionType | InvoicingSubscriptionDetailViewActionType | InvoicingSubscriptionFormPageActionType | InvoicingSubscriptionListViewActionType | InvoicingTransactionDetailViewActionType | InvoicingTransactionListViewActionType | IssueChargeCardActionType | LockChargeCardActionType | LockChargeCardsActionType | MarkAsCompleteScheduleDetailActionType | MarkTransactionAsNotMiscategorizedActionType | MatchAndReverseAccrualsActionType | NetBurnOrIncomeActionType | NetBurnOrIncomeClassesViewActionType | NetBurnOrIncomeForTimeframeActionType | NetBurnOrIncomeForTimeframeClassesViewActionType | NetBurnOrIncomeForTimeframeProjectViewActionType | NetBurnOrIncomeProjectViewActionType | NotifyMeForFeatureActionType | OneTimeAccrualActionsActionType | OpExActionType | OpExByVendorReportActionType | OpExByVendorReportForTimeframeActionType | OpExByVendorReportSummaryActionType | OpExClassesViewActionType | OpExForTimeframeClassesViewActionType | OpExForTimeframeProjectViewActionType | OpExForTimeframeViewActionType | OpExProjectViewActionType | ParallelFetchAccountTransactionListActionType | ParallelFetchClassTransactionListActionType | ParallelFetchEntityTransactionListActionType | ParallelFetchProjectTransactionListActionType | ParallelFetchTransactionListByCategoryTypeActionType | ParseCombinedStatementActionType | ParseInvoiceToBillActionType | ParseReceiptsToRemiActionType | ParseStatementActionType | ParseUploadedKybDocumentActionType | ParseUploadedKycDocumentActionType | PeopleActionType | PeoplePageActionType | PeopleSaveUpdatesActionType | PolicyDocumentExtractionToRecommendationBridgeActionType | PolicyRecommendationFromUploadActionType | ProfitAndLossActionType | ProfitAndLossClassesViewActionType | ProfitAndLossForTimeframeActionType | ProfitAndLossForTimeframeClassesViewActionType | ProfitAndLossForTimeframeProjectViewActionType | ProfitAndLossProjectViewActionType | PushToastNotificationActionType | RecommendationForAccountSettingsActionType | RecommendationForAccountTypeActionType | RecordPaymentActionType | RefetchCompletedTransactionsOnBulkUploadSortActionType | RefreshBatchDetailsForBatchIdActionType | RefreshExpenseAutomationCurrentTabActionType | RefreshIntegrationsDataActionType | RefreshOpExByVendorReportActionType | RejectVendorGlobalReviewActionType | ReorderBillPayApprovalRulesActionType | ReorderRemiApprovalRulesActionType | ReparseStatementActionType | ReportsResyncActionType | ResendCardInviteActionType | ResendInviteActionType | ResendOtpActionType | ResendReferralInviteActionType | ResendVerifyDeviceOTPActionType | ResetTransactionVendorLocalDataActionType | ResetVendorDetailLocalDataActionType | RestoreAutomatchingActionType | ResumeEnableAccountingProjectsActionType | RetryBankAccountConnectionActionType | RetryBankAccountConnectionForOnboardingActionType | RetryExpenseAutomationJEScheduleActionType | RetryOrRefundBillActionType | RevenueActionType | RevenueClassesViewActionType | RevenueForTimeframeClassesViewActionType | RevenueForTimeframeProjectViewActionType | RevenueForTimeframeViewActionType | RevenueProjectViewActionType | RevertJeScheduleActionType | ReviewDraftRemisBulkActionActionTye | ReviewExpenseAutomationFluxAnalysisActionType | RevokeCardInviteActionType | RevokeChargeCardsInviteActionType | SaveAccountMappingViewActionType | SaveAccountSettingsViewEpicActionType | SaveAddressActionType | SaveBillDetailActionType | SaveBillPaySetupApproverViewUpdatesActionType | SaveCannedResponseActionType | saveCardOnboardingUserDetailsActionType | SaveCompanyBillingAddressActionType | SaveCompanyHealthMetricByIdEpicActionType | SaveCompanyMonthEndReportActionType | SaveCompanyPassportDetailsActionType | SaveCreditAgentMacroActionType | SaveExpenseAutomationReconciliationDetailActionType | SaveExternalConnectionActionType | SaveMagicLinkBankAccountActionType | SaveNewScheduleActionType | SaveNotificationPreferencesActionType | SaveNotificationSettingsEpicActionType | SaveOnboardingCustomerCompletedStatusActionType | SaveOnboardingCustomerNotesActionType | SaveOnboardingCustomerViewUpdatesActionType | SaveRealTimeApprovalActionType | SaveReasonForAuditRuleActionType | SaveReconciliationReviewActionType | SaveRemiDetailActionType | SaveRemiSetupApproverViewUpdatesActionType | SaveScheduleAccruedDetailsActionType | SaveScheduleDetailsActionType | SaveSubscriptionNotesUpdatesActionType | SaveSubscriptionUpdatesActionType | SaveTaskDetailActionType | SaveTranactionVendorActionType | SaveTransactionDetailActionType | SaveVendorActionType | SaveVendorDetailsViewActionType | SaveVendorFirstReviewViewActionType | ScheduleTenantCreditScoreCronActionType | SearchMatchAccrualsActionType | SearchMatchTransactionsActionType | SearchTransactionsForManualMatchActionType | SearchTransactionsForNewScheduleActionType | SeedAiCardCreationFormDraftActionType | SeedAiCardPolicyFormDraftActionType | SendCompanyMonthEndReportActionType | SendEmailMagicLinkToUserActionType | SendOnboardingCustomerViewInviteActionType | SendOtpActionType | SendReferralInviteActionType | SessionHeartbeatActionType | SignInActionType | SignOutActionType | SnoozeTaskActionType | StatementCloseDayActionType | StopSubmitActionType | StopSubmitQuestionActionType | SubmitDraftBillsBulkActionActionType | SubmitDraftRemisBulkActionActionType | SubmitExpressPayActionType | SubmitFeedbackActionType | SubmitIntlVerificationActionType | SubmitQuestionActionType | SubmitRecommendationFeedbackActionType | SwitchExpenseAutomationJESchedulesTabActionType | SyncInvoicingSubscriptionCouponsActionType | SyncTabsAfterAutomatchActionType | ToggleReportUIOptionForecastModeActionType | TopExActionType | TransferMoneyActionType | TreasuryTransferMoneyActionType | TriggerAiAccountantJobActionType | TriggerReviewTabRefetchActionType | UnlinkPaymentAccountActionType | UnlockChargeCardActionType | UnlockChargeCardsActionType | UnsnoozeTaskActionType | UpdateAccountingClassesEnabledActionType | UpdateAccruedJESchedulesActionType | UpdateAddressActionType | UpdateAmountsInScheduleAccruedDetailActionType | UpdateAmountsInScheduleDetailActionType | UpdateAutoTransferRuleActionType | UpdateBusinessVerificationDetailsActionType | UpdateCapitalizationAccountThresholdActionType | UpdateCardPolicyActionType | UpdateCardProfileActionType | UpdateChargeCardDetailActionType | UpdateChargeCardLimitActionType | UpdateChargeCardNameActionType | UpdateChargeCardsLimitActionType | UpdateCombinedStatementInfoActionType | UpdateCompanyDetailsActionType | UpdateCompanyOfficerActionType | UpdateCompanyPassportLocalStoreDataActionType | UpdateCompanyProductServicesActionType | UpdateCompanyQboRealmIdActionType | UpdateCompanyTaskManagerViewFiltersActionType | UpdateDashboardLayoutActionType | UpdateDebitCardPinAttemptActionType | UpdateDepositAccountActionType | UpdateDynamicFormActionType | UpdateExpenseAutomationReconciliationBalanceLocalDataActionType | UpdateFileNameActionType | UpdateFilesMetadataActionType | UpdateJESchedulesActionType | UpdateMappedCashAccountActionType | UpdateMileageDetailsActionType | UpdateMyProfileActionType | UpdateNetBurnOrIncomeStoryCardSettingsActionType | UpdateNotificationViewAllNotificationsStatusActionType | UpdateNotificationViewNotificationStatusActionType | UpdateOnboardingCustomerViewActionType | UpdateOnboardingCustomerViewCompleteStatusActionType | UpdateOnboardingCustomerViewDashboardLoadedActionType | UpdateOnboardingCustomerViewLocalStoreDataActionType | UpdateOnboardingPaymentAccountLoginStatusActionType | UpdateOnboardingPaymentAccountStatusActionType | UpdatePaymentAccountActionType | UpdatePaymentAccountLoginStatusActionType | UpdatePaymentAccountStatusActionType | UpdatePhysicalChargeCardAttemptActionType | UpdatePortfolioAllocationActionType | UpdatePrimaryContactActionType | UpdatePrimaryFundingAccountActionType | UpdateQBOConnectionPoolExternalConnectionActionType | UpdateReferViewedActionType | UpdateRemiSetupViewLocalStoreDataActionType | UpdateReportUIOptionCOABalancesRangeActionType | UpdateReportUIOptionIsCompareModeActionType | UpdateReportUIOptionIsCompareModeOnActionType | UpdateReportUIOptionThisPeriodActionType | UpdateReportUIOptionTimeFrameActionType | UpdateSectionAccountsViewActionType | UpdateSectionClassesViewV2ActionType | UpdateSectionProjectViewActionType | UpdateSelectedVendorForCreateFlowActionType | UpdateSetupViewLocalStoreDataActionType | UpdateStatementInfoActionType | UpdateTaskFromListViewActionType | UpdateTaskGroupNameActionType | UpdateTransactionDetailActionType | UpdateTransactionOnUploadSuccessActionType | UpdateVendorContactActionType | UploadAccountStatementActionType | UploadMissingReceiptSuccessEpicActionType | UploadTransactionReceiptSuccessEpicActionType | ValidateBillsBulkActionActionType | VendorFiling1099UploadDetailsSaveActionType | VendorsTabFetchVendorActionType | VendorsTabFetchVendorDetailPageViewActionType | VendorsTabFetchVendorDetailsActionType | VendorsTabResetVendorDetailLocalDataActionType | VendorsTabSaveVendorActionType | VerifyDeviceWithTwoFAActionType | VerifyOtpActionType | VerifyUserActionType | WatchBulkUploadBatchStatusActionType | WiseRedirectActionType;
686
+ export type RootActionType = AcceptBillPayTermsActionType | AcceptBillPayUpdatedTermsActionType | AcceptChargeCardTermsActionType | AcceptEmployeeRemiTermsActionType | AcceptMasterTOSEpicActionType | AcceptRemiTermsActionType | AcceptTreasuryTermsActionType | AcceptZeniAccountTermsActionType | AcknowledgeOnboardingAiActivationViewedActionType | AcknowledgeOnboardingAiFinanceTeamActionType | AddCardPaymentSourceActionType | ApplyExtractedPolicyToDraftActionType | ApproveOAuthConsentActionType | ApproveOrRejectBillActionType | ApproveOrRejectBillsBulkActionActionType | ApproveOrRejectRemiActionType | ApproveOrRejectRemisBulkActionActionType | ApproveVendorGlobalReviewActionType | ArchiveCardPolicyActionType | ArchiveTaskActionType | BackgroundRefetchReviewTabActionType | BalanceSheetActionType | BalanceSheetClassesViewActionType | BalanceSheetForTimeframeActionType | BalanceSheetForTimeframeClassesViewActionType | BalanceSheetForTimeframeProjectViewActionType | BalanceSheetProjectViewActionType | BulkUpdateTasksListActionType | BulkUploadMatchResultToastActionType | BulkUploadReceiptsActionType | CancelAiAccountantOnboardingActionType | CancelAndDeleteBillActionType | CancelAndDeleteRemiActionType | CancelOrDeleteBillsBulkActionActionType | CancelOrDeleteRemisBulkActionActionType | CancelScheduleAccruedJournalEntryActionType | CardBalanceActionType | CashBalanceActionType | CashFlowActionType | CashFlowForTimeframeActionType | CashInCashOutActionType | CashPositionActionType | ChangeZeniPersonRolesActionType | CheckDepositActionType | CloseChargeCardActionType | CloseChargeCardsActionType | CombinedStatementActionType | CompanyManagementSavePendingUpdatesActionType | CompanyManagementSaveUpdatesActionType | ConfirmBulkUploadMatchActionType | ConfirmCardSetupIntentActionType | ConfirmStatementMappingActionType | CreateAddressActionType | CreateAutoTransferRuleActionType | CreateBankAccountActionType | CreateCardPolicyTemplateActionType | CreateCardSetupIntentActionType | CreateCheckingAccountActionType | CreateCompanyAddressActionType | CreateCompanyOfficersActionType | CreateCompanyUserAddressActionType | CreateGlobalMerchantActionType | CreateInternationalBankAccountActionType | CreateInvoiceActionType | CreateNewSchedulesAccruedActionType | CreateNewSchedulesActionType | CreateNewTaskGroupActionType | CreateOneTimeAccrualActionType | CreatePaymentInstrumentActionType | CreateSessionActionType | CreateSessionAndSubmitActionType | CreateSubTaskActionType | CreateTagActionType | CreateTaskFromTaskGroupTemplateActionType | CreateTransferEntryActionType | CreateUserBankAccountActionType | CurrencyConversionActionType | DeleteAccountStatementActionType | DeleteAutoTransferRuleActionType | DeleteBankAccountActionType | DeleteBillActionType | DeleteBillPayApprovalRuleActionType | DeleteCannedResponseActionType | DeleteChatSessionActionType | DeleteCombinedStatementActionType | DeleteFileActionType | DeleteFileListActionType | DeleteInternationalBankAccountActionType | DeletePaymentInstrumentActionType | DeletePersonActionType | DeleteRemiActionType | DeleteRemiApprovalRuleActionType | DeleteScheduleAccruedDetailActionType | DeleteScheduleDetailActionType | DeleteTagActionType | DeleteTaskActionType | DeleteTaskGroupActionType | DeleteTransactionAttachmentActionType | DeleteUserBankAccountActionType | DepositAccountTransactionListActionType | DisableAccountingProjectsActionType | DismissCapitalizationOnboardingActionType | DoMagicLinkSignInActionType | DownloadAccountingProviderAttachmentActionType | DragNDropTasksActionType | EditInvoicingCatalogItemDetailViewActionType | EditInvoicingCouponDetailViewActionType | EditInvoicingCustomerDetailViewActionType | EditInvoicingSubscriptionDetailViewActionType | EnableAccountingProjectsActionType | EnableChargeCardAutoPayActionType | EnableSetupActionType | EstablishOnboardingPlaidConnectionActionType | EstablishPlaidConnectionActionType | ExcludeAccountFromReconciliationActionType | ExpressInterestChargeCardActionType | ExpressPayActionType | ExtractPolicyDocumentActionType | FetchAccountHistoryActionType | FetchAccountListActionType | FetchAccountListForAccountTypesActionType | FetchAccountSettingsListForAccountTypesActionType | FetchAccruedScheduleListActionType | FetchActiveTenantActionType | FetchAddressActionType | FetchAggregatedReportActionType | FetchAiAccountantCustomersActionType | FetchAiAccountantJobsActionType | FetchAiAgentsActivationStatusActionType | FetchAllCockpitViewsActionType | FetchAllExpenseAutomationTabsActionType | FetchAllPeopleRequiredActionType | FetchAllTagsActionType | FetchAllTaskGroupsActionType | FetchAllTenantsActionType | FetchApAgingActionType | FetchApAgingDetailActionType | FetchArAgingActionType | FetchArAgingDetailActionType | FetchAuditReportGroupViewActionType | FetchAuditRuleGroupViewActionType | FetchAutoTransferReviewDetailActionType | FetchAutoTransferRuleHistoryActionType | FetchAutoTransferRulesActionType | FetchBankAccountsListActionType | FetchBankConnectionsViewActionType | FetchBankCountryNameByIbanActionType | FetchBankNameByRoutingActionType | FetchBankNameBySwiftActionType | FetchBillAndInitializeLocalStoreActionType | FetchBillDetailActionType | FetchBillingAccountsListActionType | FetchBillListActionType | FetchBillListPerTabActionType | FetchBillPayApproversDetailsActionType | FetchBillPayApproversListActionType | FetchBillPayCardActionType | FetchBillPayConfigActionType | FetchBillPaySetupApproverViewActionType | FetchBillPaySetupViewActionType | FetchBulkUploadBatchDetailsActionType | FetchBulkUploadBatchesActionType | FetchCannedResponsesActionType | FetchCardPolicyDetailActionType | FetchCardPolicyListActionType | FetchCardPolicyMccCategoriesActionType | FetchCardPolicyVendorOptionsActionType | FetchCardProfilesActionType | FetchCashbackDetailActionType | FetchChargeCardConfigActionType | FetchChargeCardDetailActionType | FetchChargeCardDetailPageActionType | FetchChargeCardListActionType | FetchChargeCardListPageActionType | FetchChargeCardPaymentHistoryActionType | FetchChargeCardPaymentPageActionType | FetchChargeCardRepaymentDetailActionType | FetchChargeCardSetupViewActionType | FetchChargeCardsRecurringExpensesActionType | FetchChargeCardStatementListActionType | FetchChargeCardTransactionAttachmentsActionType | FetchChargeCardTransactionListActionType | FetchChargeCardTransactionStatisticsActionType | FetchChatHistoryActionType | FetchChatSessionsForUserActionType | FetchClassListActionType | FetchCockpitContextActionType | FetchCollaborationAuthTokenActionType | FetchCompanyBillingAddressActionType | FetchCompanyConfigActionType | FetchCompanyHealthMetricConfigViewEpicActionType | FetchCompanyHealthMetricViewEpicActionType | FetchCompanyManagementActionType | FetchCompanyMetaDataActionType | FetchCompanyMonthEndReportHistoricDataActionType | FetchCompanyMonthEndReportHistoricDatesActionType | FetchCompanyMonthEndReportTemplatesActionType | FetchCompanyMonthEndReportViewActionType | FetchCompanyOnboardingViewActionType | FetchCompanyPassportViewActionType | FetchCompanyPortfolioActionType | FetchCompanyTaskManagerViewActionType | FetchCompletedTransactionsActionType | FetchCreateInvoiceFormPageActionType | FetchCreditAccountActionType | FetchCreditAccountRepaymentActionType | FetchCreditAgentMacroActionType | FetchCurrencyConversionValueActionType | FetchDashboardActionType | FetchDashboardLayoutActionType | FetchDebitCardSummaryActionType | FetchDepositAccountActionType | FetchDepositAccountDetailActionType | FetchDepositAccountLimitActionType | FetchDepositAccountListActionType | FetchDepositAccountListForCardsActionType | FetchDepositAccStatementListActionType | FetchDownloadSchedulesActionType | FetchDuplicateBillActionType | FetchDuplicateReimbursementEpicActionType | FetchEditBillDetailPageActionType | FetchEditRemiDetailPageActionType | FetchEligibleActionsForBillActionType | FetchEntityAutoCompleteActionType | FetchEntityHistoryActionType | FetchEntityRecommendationsByTransactionIdActionType | FetchEntityRecommendationsForLineUpdateActionType | FetchExcludedResourcesActionType | FetchExpenseAutomationActualMatchingActionType | FetchExpenseAutomationActualMatchingMatchActionType | FetchExpenseAutomationActualMatchingPageActionType | FetchExpenseAutomationFluxAnalysisActionType | FetchExpenseAutomationInitializeTransactionCategorizationViewLocalDataActionType | FetchExpenseAutomationJEScheduleActionType | FetchExpenseAutomationJESchedulePageActionType | FetchExpenseAutomationMarkTransactionAsNotMiscategorizedActionType | FetchExpenseAutomationMissingReceiptsActionType | FetchExpenseAutomationReconciliationsViewActionType | FetchExpenseAutomationSaveTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationActionType | FetchExpenseAutomationTransactionCategorizationViewActionType | FetchExpenseAutomationUpdateTransactionCategorizationEpicActionType | FetchExpenseTrendActionType | FetchExternalConnectionsActionType | FetchFileActionType | FetchFileListActionType | FetchForecastListActionType | FetchGlobalMerchantAutoCompleteActionType | FetchGlobalMerchantRecommendationActionType | FetchIncomeTrendActionType | FetchInternationalWireDynamicFormActionType | FetchIntlVerificationFormActionType | FetchInvoiceCountsActionType | FetchInvoiceDetailActionType | FetchInvoiceKPIsActionType | FetchInvoiceListActionType | FetchInvoiceListPageActionType | FetchIssueCardPageActionType | FetchMagicLinkBankNameByRoutingActionType | FetchMagicLinkBankNameBySwiftActionType | FetchMagicLinkBillActionType | FetchMagicLinkTenantActionType | FetchManagementActionType | FetchMerchantListActionType | FetchMonthClosePerformanceTrendActionType | FetchMonthEndCloseChecksActionType | FetchMoreBatchDetailsActionType | FetchMultipleBatchDetailsActionType | FetchMyProfileActionType | FetchMyProfileViewActionType | FetchNetBurnOrIncomeStoryCardActionType | FetchNetBurnOrIncomeWithForecastActionType | FetchNotificationSettingsActionType | FetchNotificationSettingsViewActionType | FetchNotificationUnreadCountActionType | FetchNotificationViewActionType | FetchOnboardingActionType | FetchOnboardingCompletedCompaniesActionType | FetchOnboardingCustomerSetupViewActionType | FetchOnboardingCustomerViewActionType | FetchOneTimeAccrualActionType | FetchOpExWithForecastActionType | FetchOwnerListActionType | FetchParentSubsidiaryManagementActionType | FetchPaymentAccountBalanceActionType | FetchPaymentAccountListActionType | FetchPaymentSourcesActionType | FetchPortfolioActionType | FetchPortfolioAllocationActionType | FetchPreviousBillsActionType | FetchProjectListActionType | FetchQBOConnectionPoolActionType | FetchRecommendationByEntityIdActionType | FetchRecommendationByEntityNameActionType | FetchRecommendationsAndUpdateMerchantRecommendationsActionType | FetchRecommendationsAndUpdateVendorRecommendationsActionType | FetchRecommendedBillExpenseActionType | FetchReferralsActionType | FetchRegisteredInterestsActionType | FetchReimbursementCardActionType | FetchReimbursementConfigActionType | FetchRemiAndInitializeLocalStoreActionType | FetchRemiApproversDetailsActionType | FetchRemiApproversListActionType | FetchRemiDetailActionType | FetchRemiListActionType | FetchRemiListPerTabActionType | FetchRemiSetupApproverViewActionType | FetchRemiSetupViewActionType | FetchRevenueWithForecastActionType | FetchReviewCompanyActionType | FetchReviewTransferDetailActionType | FetchRewardsPlanActionType | FetchScheduleAccruedDetailsActionType | FetchScheduleAccruedDetailsPageActionType | FetchScheduleDetailsActionType | FetchScheduleDetailsPageActionType | FetchScheduleListActionType | FetchSchedulesListActionType | FetchSkillsActionType | FetchSubscriptionActionType | FetchSubscriptionAddOnsActionType | FetchSubscriptionCouponsActionType | FetchSubscriptionCreateEstimateActionType | FetchSubscriptionDetailsActionType | FetchSubscriptionListActionType | FetchSubscriptionPlansActionType | FetchSubscriptionSummaryForTenantActionType | FetchSubscriptionUpdateEstimateActionType | FetchSubTasksActionType | FetchSuggestedQuestionsActionType | FetchTaskDetailActionType | FetchTaskDetailPageActionType | FetchTaskGroupTemplatesActionType | FetchTaskHistoryActionType | FetchTaskListActionType | FetchTaskListPageActionType | FetchTaskManagerMetricsActionType | FetchTasksCardActionType | FetchTransactionActivityLogActionType | FetchTransactionDetailActionType | FetchTransactionListByAccountActionType | FetchTransactionListByClassActionType | FetchTransactionListByEntityActionType | FetchTransactionListByProjectActionType | FetchTransactionsForEntityActionType | FetchTransactionsListByCategoryTypeActionType | FetchTransferAccountsActionType | FetchTreasuryDetailActionType | FetchTreasuryFundsActionType | FetchTreasuryHistoryActionType | FetchTreasurySetupViewActionType | FetchTreasuryStatementListActionType | FetchTreasuryTaxLetterListActionType | FetchTreasuryTransactionListActionType | FetchTrendForEntityActionType | FetchUserDetailActionType | FetchUserFinancialAccountActionType | FetchUserListByTypeActionType | FetchUserRoleConfigActionType | FetchVendor1099TypeListActionType | FetchVendorActionType | FetchVendorAndUpdateBillLocalDataActionType | FetchVendorByNameAndParseInvoiceActionType | FetchVendorDetailsActionType | FetchVendorFirstReviewAttachmentsActionType | FetchVendorFirstReviewViewActionType | FetchVendorGlobalReviewViewActionType | FetchVendorsActionType | FetchVendorsFiling1099ActionType | FetchVendorsFiling1099AllActionType | FetchVendorsFiling1099DownloadActionType | FetchVendorTabViewActionType | FetchVendorTypeListActionType | FetchZeniAccountListPageActionType | FetchZeniAccountsConfigActionType | FetchZeniAccountSetupViewActionType | FetchZeniAccStatePageActionType | FetchZeniUsersActionType | GetOnboardingEmailGroupActionType | GetOnboardingPlaidLinkTokenActionType | GetPaymentAccountsActionType | GetPlaidLinkTokenActionType | IgnoreExpenseAutomationJEScheduleActionType | ImproveUsingZeniGPTActionType | IncludeAccountInReconciliationActionType | InitialiseExpenseAutomationLocalDataForSelectedAccountIdActionType | InitializeAccountMappingViewActionType | InitializeAccountSettingsViewEpicActionType | InitializeBillPaySetupApproverViewUpdateDataActionType | InitializeBillToLocalStoreActionType | InitializeCardUserOnboardingLocalDataActionType | InitializeCompanyHealthMetricViewLocalDataEpicActionType | InitializeEditPersonActionType | InitializeExpenseAutomationJeScheduleLocalDataActionType | InitializeInternationalWireLocalDataActionType | InitializeIntlVerificationFormEpicActionType | InitializeMyProfileLocalDataActionType | InitializeNewScheduleActionType | InitializeOnboardingCustomerViewUpdateDataActionType | InitializeRemiSetupApproverViewUpdateDataActionType | InitializeRemiToLocalStoreActionType | InitializeScheduleAccruedDetailLocalDataActionType | InitializeScheduleDetailLocalDataActionType | InitializeSubscriptionLocalDataActionType | InitializeTaskToLocalStoreActionType | InitializeTransactionDetailLocalDataActionType | InitializeVendorAddressActionType | InitiateChargeCardRepaymentActionType | InitiateReportsClassViewRefetchingActionType | InitiateReportsProjectViewRefetchingActionType | InsightsCardActionType | InvitePeopleActionType | InviteZeniPeopleActionType | InvoicingAuditViewActionType | InvoicingCatalogActionActionType | InvoicingCatalogItemDetailViewActionType | InvoicingCatalogListViewActionType | InvoicingCatalogSubFamilyActionType | InvoicingConfigViewActionType | InvoicingCouponDetailViewActionType | InvoicingCouponViewActionType | InvoicingCreditNoteDetailViewActionType | InvoicingCreditNoteListViewActionType | InvoicingCustomerDetailPageActionType | InvoicingCustomerDetailViewActionType | InvoicingCustomerListViewActionType | InvoicingCustomerPaymentMethodActionType | InvoicingDataImportViewActionType | InvoicingDiscountActionActionType | InvoicingDunningActionActionType | InvoicingDunningCaseDetailViewActionType | InvoicingDunningCaseListViewActionType | InvoicingInvoiceActionActionType | InvoicingOverviewActionType | InvoicingPaymentActionActionType | InvoicingPromotionalCreditActionActionType | InvoicingQboViewActionType | InvoicingSettingsViewActionType | InvoicingSubscriptionActionActionType | InvoicingSubscriptionDetailViewActionType | InvoicingSubscriptionFormPageActionType | InvoicingSubscriptionListViewActionType | InvoicingTransactionDetailViewActionType | InvoicingTransactionListViewActionType | IssueChargeCardActionType | LockChargeCardActionType | LockChargeCardsActionType | MarkAsCompleteScheduleDetailActionType | MarkTransactionAsNotMiscategorizedActionType | MatchAndReverseAccrualsActionType | NetBurnOrIncomeActionType | NetBurnOrIncomeClassesViewActionType | NetBurnOrIncomeForTimeframeActionType | NetBurnOrIncomeForTimeframeClassesViewActionType | NetBurnOrIncomeForTimeframeProjectViewActionType | NetBurnOrIncomeProjectViewActionType | NotifyMeForFeatureActionType | OneTimeAccrualActionsActionType | OpExActionType | OpExByVendorReportActionType | OpExByVendorReportForTimeframeActionType | OpExByVendorReportSummaryActionType | OpExClassesViewActionType | OpExForTimeframeClassesViewActionType | OpExForTimeframeProjectViewActionType | OpExForTimeframeViewActionType | OpExProjectViewActionType | ParallelFetchAccountTransactionListActionType | ParallelFetchClassTransactionListActionType | ParallelFetchEntityTransactionListActionType | ParallelFetchProjectTransactionListActionType | ParallelFetchTransactionListByCategoryTypeActionType | ParseCombinedStatementActionType | ParseInvoiceToBillActionType | ParseReceiptsToRemiActionType | ParseStatementActionType | ParseUploadedKybDocumentActionType | ParseUploadedKycDocumentActionType | PeopleActionType | PeoplePageActionType | PeopleSaveUpdatesActionType | PolicyDocumentExtractionToRecommendationBridgeActionType | PolicyRecommendationFromUploadActionType | ProfitAndLossActionType | ProfitAndLossClassesViewActionType | ProfitAndLossForTimeframeActionType | ProfitAndLossForTimeframeClassesViewActionType | ProfitAndLossForTimeframeProjectViewActionType | ProfitAndLossProjectViewActionType | PushToastNotificationActionType | RecommendationForAccountSettingsActionType | RecommendationForAccountTypeActionType | RecordPaymentActionType | RefetchCompletedTransactionsOnBulkUploadSortActionType | RefreshBatchDetailsForBatchIdActionType | RefreshExpenseAutomationCurrentTabActionType | RefreshIntegrationsDataActionType | RefreshOpExByVendorReportActionType | RejectVendorGlobalReviewActionType | ReorderBillPayApprovalRulesActionType | ReorderRemiApprovalRulesActionType | ReparseStatementActionType | ReportsResyncActionType | ResendCardInviteActionType | ResendInviteActionType | ResendOtpActionType | ResendReferralInviteActionType | ResendVerifyDeviceOTPActionType | ResetTransactionVendorLocalDataActionType | ResetVendorDetailLocalDataActionType | RestoreAutomatchingActionType | ResumeEnableAccountingProjectsActionType | RetryBankAccountConnectionActionType | RetryBankAccountConnectionForOnboardingActionType | RetryExpenseAutomationJEScheduleActionType | RetryOrRefundBillActionType | RevenueActionType | RevenueClassesViewActionType | RevenueForTimeframeClassesViewActionType | RevenueForTimeframeProjectViewActionType | RevenueForTimeframeViewActionType | RevenueProjectViewActionType | RevertJeScheduleActionType | ReviewDraftRemisBulkActionActionTye | ReviewExpenseAutomationFluxAnalysisActionType | RevokeCardInviteActionType | RevokeChargeCardsInviteActionType | SaveAccountMappingViewActionType | SaveAccountSettingsViewEpicActionType | SaveAddressActionType | SaveBillDetailActionType | SaveBillPaySetupApproverViewUpdatesActionType | SaveCannedResponseActionType | saveCardOnboardingUserDetailsActionType | SaveCompanyBillingAddressActionType | SaveCompanyHealthMetricByIdEpicActionType | SaveCompanyMonthEndReportActionType | SaveCompanyPassportDetailsActionType | SaveCreditAgentMacroActionType | SaveExpenseAutomationReconciliationDetailActionType | SaveExternalConnectionActionType | SaveMagicLinkBankAccountActionType | SaveNewScheduleActionType | SaveNotificationPreferencesActionType | SaveNotificationSettingsEpicActionType | SaveOnboardingCustomerCompletedStatusActionType | SaveOnboardingCustomerNotesActionType | SaveOnboardingCustomerViewUpdatesActionType | SaveRealTimeApprovalActionType | SaveReasonForAuditRuleActionType | SaveReconciliationReviewActionType | SaveRemiDetailActionType | SaveRemiSetupApproverViewUpdatesActionType | SaveScheduleAccruedDetailsActionType | SaveScheduleDetailsActionType | SaveSubscriptionNotesUpdatesActionType | SaveSubscriptionUpdatesActionType | SaveTaskDetailActionType | SaveTranactionVendorActionType | SaveTransactionDetailActionType | SaveVendorActionType | SaveVendorDetailsViewActionType | SaveVendorFirstReviewViewActionType | ScheduleTenantCreditScoreCronActionType | SearchMatchAccrualsActionType | SearchMatchTransactionsActionType | SearchTransactionsForManualMatchActionType | SearchTransactionsForNewScheduleActionType | SeedAiCardCreationFormDraftActionType | SeedAiCardPolicyFormDraftActionType | SendCompanyMonthEndReportActionType | SendEmailMagicLinkToUserActionType | SendOnboardingCustomerViewInviteActionType | SendOtpActionType | SendReferralInviteActionType | SessionHeartbeatActionType | SignInActionType | SignOutActionType | SnoozeTaskActionType | StatementCloseDayActionType | StopSubmitActionType | StopSubmitQuestionActionType | SubmitDraftBillsBulkActionActionType | SubmitDraftRemisBulkActionActionType | SubmitExpressPayActionType | SubmitFeedbackActionType | SubmitIntlVerificationActionType | SubmitQuestionActionType | SubmitRecommendationFeedbackActionType | SwitchExpenseAutomationJESchedulesTabActionType | SyncInvoicingSubscriptionCouponsActionType | SyncTabsAfterAutomatchActionType | ToggleReportUIOptionForecastModeActionType | TopExActionType | TransferMoneyActionType | TreasuryTransferMoneyActionType | TriggerAiAccountantJobActionType | TriggerReviewTabRefetchActionType | UndoReversalAccrualsActionType | UnlinkPaymentAccountActionType | UnlockChargeCardActionType | UnlockChargeCardsActionType | UnsnoozeTaskActionType | UpdateAccountingClassesEnabledActionType | UpdateAccruedJESchedulesActionType | UpdateAddressActionType | UpdateAmountsInScheduleAccruedDetailActionType | UpdateAmountsInScheduleDetailActionType | UpdateAutoTransferRuleActionType | UpdateBusinessVerificationDetailsActionType | UpdateCapitalizationAccountThresholdActionType | UpdateCardPolicyActionType | UpdateCardProfileActionType | UpdateChargeCardDetailActionType | UpdateChargeCardLimitActionType | UpdateChargeCardNameActionType | UpdateChargeCardsLimitActionType | UpdateCombinedStatementInfoActionType | UpdateCompanyDetailsActionType | UpdateCompanyOfficerActionType | UpdateCompanyPassportLocalStoreDataActionType | UpdateCompanyProductServicesActionType | UpdateCompanyQboRealmIdActionType | UpdateCompanyTaskManagerViewFiltersActionType | UpdateDashboardLayoutActionType | UpdateDebitCardPinAttemptActionType | UpdateDepositAccountActionType | UpdateDynamicFormActionType | UpdateExpenseAutomationReconciliationBalanceLocalDataActionType | UpdateFileNameActionType | UpdateFilesMetadataActionType | UpdateJESchedulesActionType | UpdateMappedCashAccountActionType | UpdateMileageDetailsActionType | UpdateMyProfileActionType | UpdateNetBurnOrIncomeStoryCardSettingsActionType | UpdateNotificationViewAllNotificationsStatusActionType | UpdateNotificationViewNotificationStatusActionType | UpdateOnboardingCustomerViewActionType | UpdateOnboardingCustomerViewCompleteStatusActionType | UpdateOnboardingCustomerViewDashboardLoadedActionType | UpdateOnboardingCustomerViewLocalStoreDataActionType | UpdateOnboardingPaymentAccountLoginStatusActionType | UpdateOnboardingPaymentAccountStatusActionType | UpdatePaymentAccountActionType | UpdatePaymentAccountLoginStatusActionType | UpdatePaymentAccountStatusActionType | UpdatePhysicalChargeCardAttemptActionType | UpdatePortfolioAllocationActionType | UpdatePrimaryContactActionType | UpdatePrimaryFundingAccountActionType | UpdateQBOConnectionPoolExternalConnectionActionType | UpdateReferViewedActionType | UpdateRemiSetupViewLocalStoreDataActionType | UpdateReportUIOptionCOABalancesRangeActionType | UpdateReportUIOptionIsCompareModeActionType | UpdateReportUIOptionIsCompareModeOnActionType | UpdateReportUIOptionThisPeriodActionType | UpdateReportUIOptionTimeFrameActionType | UpdateSectionAccountsViewActionType | UpdateSectionClassesViewV2ActionType | UpdateSectionProjectViewActionType | UpdateSelectedVendorForCreateFlowActionType | UpdateSetupViewLocalStoreDataActionType | UpdateStatementInfoActionType | UpdateTaskFromListViewActionType | UpdateTaskGroupNameActionType | UpdateTransactionDetailActionType | UpdateTransactionOnUploadSuccessActionType | UpdateVendorContactActionType | UploadAccountStatementActionType | UploadMissingReceiptSuccessEpicActionType | UploadTransactionReceiptSuccessEpicActionType | ValidateBillsBulkActionActionType | VendorFiling1099UploadDetailsSaveActionType | VendorsTabFetchVendorActionType | VendorsTabFetchVendorDetailPageViewActionType | VendorsTabFetchVendorDetailsActionType | VendorsTabResetVendorDetailLocalDataActionType | VendorsTabSaveVendorActionType | VerifyDeviceWithTwoFAActionType | VerifyOtpActionType | VerifyUserActionType | WatchBulkUploadBatchStatusActionType | WiseRedirectActionType;
686
687
  export declare const featureRootEpic: Epic<RootActionType>;
package/lib/epic.js CHANGED
@@ -195,6 +195,7 @@ const fetchActualMatchingPageEpic_1 = require("./view/expenseAutomationView/epic
195
195
  const matchAndReverseAccrualsEpic_1 = require("./view/expenseAutomationView/epics/actualMatching/matchAndReverseAccrualsEpic");
196
196
  const searchMatchAccrualsEpic_1 = require("./view/expenseAutomationView/epics/actualMatching/searchMatchAccrualsEpic");
197
197
  const searchMatchTransactionsEpic_1 = require("./view/expenseAutomationView/epics/actualMatching/searchMatchTransactionsEpic");
198
+ const undoReversalAccrualsEpic_1 = require("./view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic");
198
199
  const fetchAllExpenseAutomationTabsEpic_1 = require("./view/expenseAutomationView/epics/common/fetchAllExpenseAutomationTabsEpic");
199
200
  const refreshExpenseAutomationCurrentTabEpic_1 = require("./view/expenseAutomationView/epics/common/refreshExpenseAutomationCurrentTabEpic");
200
201
  const fetchFluxAnalysisViewEpic_1 = require("./view/expenseAutomationView/epics/fluxAnalysis/fetchFluxAnalysisViewEpic");
@@ -1405,6 +1406,7 @@ const ALL_EPICS = [
1405
1406
  treasuryTransferMoneyEpic_1.treasuryTransferMoneyEpic,
1406
1407
  triggerAiAccountantJobEpic_1.triggerAiAccountantJobEpic,
1407
1408
  triggerReviewTabRefetchEpic_1.triggerReviewTabRefetchEpic,
1409
+ undoReversalAccrualsEpic_1.undoReversalAccrualsEpic,
1408
1410
  unlinkPaymentAccountEpic_1.unlinkPaymentAccountEpic,
1409
1411
  unlockChargeCardEpic_1.unlockChargeCardEpic,
1410
1412
  unlockChargeCardsEpic_1.unlockChargeCardsEpic,
@@ -1,5 +1,5 @@
1
1
  import { toAmount } from '../../commonStateTypes/amount';
2
- import { toJEOneTimeAccrual } from '../jeSchedules/jeSchedulesPayload';
2
+ import { toJEOneTimeAccrual, } from '../jeSchedules/jeSchedulesPayload';
3
3
  const USD_CURRENCY_CODE = 'USD';
4
4
  const USD_CURRENCY_SYMBOL = '$';
5
5
  const MATCH_KINDS = [
@@ -11,6 +11,7 @@ function toMatchKind(raw) {
11
11
  if (MATCH_KINDS.includes(raw)) {
12
12
  return raw;
13
13
  }
14
+ console.error(`Unknown ActualMatchingMatchKind: ${raw}`);
14
15
  return 'auto_reversed';
15
16
  }
16
17
  export function toActualMatchingMatch(payload) {
@@ -32,8 +33,8 @@ export function toActualMatchingMatch(payload) {
32
33
  kind: toMatchKind(payload.kind),
33
34
  matchTier: payload.match_tier ?? undefined,
34
35
  matchShape: payload.match_shape ?? undefined,
35
- accruedAmount: toAmount(payload.accrued_amount ?? 0, currencyCode, currencySymbol),
36
- actualAmount: toAmount(payload.actual_amount ?? 0, currencyCode, currencySymbol),
37
- members: (payload.members ?? []).map(toJEOneTimeAccrual),
36
+ accruedAmount: toAmount(payload.accrued_amount, currencyCode, currencySymbol),
37
+ actualAmount: toAmount(payload.actual_amount, currencyCode, currencySymbol),
38
+ members: payload.members.map(toJEOneTimeAccrual),
38
39
  };
39
40
  }
@@ -22,7 +22,7 @@ const actualMatching = createSlice({
22
22
  },
23
23
  extraReducers: (builder) => {
24
24
  builder.addCase(clearAll, (draft) => {
25
- draft.byMatchId = {};
25
+ Object.assign(draft, initialState);
26
26
  });
27
27
  },
28
28
  });
@@ -1,3 +1,3 @@
1
- export function getActualMatchingMatchById(matchId, actualMatchingState) {
1
+ export function getActualMatchingMatchById(actualMatchingState, matchId) {
2
2
  return actualMatchingState.byMatchId[matchId];
3
3
  }
@@ -467,6 +467,7 @@ function toJEOneTimeAccrualCleared(payload, currencyCode) {
467
467
  : undefined,
468
468
  matchTier: payload.match_tier ?? undefined,
469
469
  matchShape: payload.match_shape ?? undefined,
470
+ matchedTransactionSyncToken: payload.matched_transaction_sync_token ?? undefined,
470
471
  };
471
472
  }
472
473
  function toJEOneTimeAccrualMatchSuggestion(payload, currencyCode) {
@@ -486,6 +487,7 @@ function toJEOneTimeAccrualMatchSuggestion(payload, currencyCode) {
486
487
  matchedTransactionDate: payload.matched_transaction_date != null
487
488
  ? date(payload.matched_transaction_date)
488
489
  : undefined,
490
+ matchedTransactionSyncToken: payload.matched_transaction_sync_token ?? undefined,
489
491
  };
490
492
  }
491
493
  export function toJEOneTimeAccrual(payload) {
package/lib/esm/epic.js CHANGED
@@ -192,6 +192,7 @@ import { fetchActualMatchingPageEpic as fetchExpenseAutomationActualMatchingPage
192
192
  import { matchAndReverseAccrualsEpic, } from './view/expenseAutomationView/epics/actualMatching/matchAndReverseAccrualsEpic';
193
193
  import { searchMatchAccrualsEpic, } from './view/expenseAutomationView/epics/actualMatching/searchMatchAccrualsEpic';
194
194
  import { searchMatchTransactionsEpic, } from './view/expenseAutomationView/epics/actualMatching/searchMatchTransactionsEpic';
195
+ import { undoReversalAccrualsEpic, } from './view/expenseAutomationView/epics/actualMatching/undoReversalAccrualsEpic';
195
196
  import { fetchAllExpenseAutomationTabsEpic, } from './view/expenseAutomationView/epics/common/fetchAllExpenseAutomationTabsEpic';
196
197
  import { refreshExpenseAutomationCurrentTabEpic, } from './view/expenseAutomationView/epics/common/refreshExpenseAutomationCurrentTabEpic';
197
198
  import { fetchFluxAnalysisViewEpic as fetchExpenseAutomationFluxAnalysisViewEpic, } from './view/expenseAutomationView/epics/fluxAnalysis/fetchFluxAnalysisViewEpic';
@@ -1402,6 +1403,7 @@ const ALL_EPICS = [
1402
1403
  treasuryTransferMoneyEpic,
1403
1404
  triggerAiAccountantJobEpic,
1404
1405
  triggerReviewTabRefetchEpic,
1406
+ undoReversalAccrualsEpic,
1405
1407
  unlinkPaymentAccountEpic,
1406
1408
  unlockChargeCardEpic,
1407
1409
  unlockChargeCardsEpic,
package/lib/esm/index.js CHANGED
@@ -184,7 +184,7 @@ import { toExpenseAutomationViewType, } from './view/expenseAutomationView/expen
184
184
  import { computeNewScheduleJeDetails } from './view/expenseAutomationView/helpers/newScheduleLocalDataHelper';
185
185
  import { isReviewTransactionBankTransferType, isReviewTransactionBillPaymentType, isReviewTransactionCreditCardCreditType, isReviewTransactionCreditCardPaymentType, isReviewTransactionDepositType, isReviewTransactionExpenseType, } from './view/expenseAutomationView/helpers/reconciliationHelpers';
186
186
  import { MAX_SELECTION_LIMIT, checkIfAllLineItemsAreCategoryClassFilled, getLineItemsByTransactionIdsFromLocalData, isAnyItemWithUncategorizedExpenseAccount, } from './view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper';
187
- import { clearActualMatchingView as clearExpenseAutomationActualMatchingView, clearMatchNewModal, closeMatchNewModal, fetchActualMatching as fetchExpenseAutomationActualMatching, fetchActualMatchingMatch, fetchActualMatchingPage as fetchExpenseAutomationActualMatchingPage, matchAndReverseAccruals, openMatchNewModal, searchMatchAccruals, searchMatchTransactions, updateActualMatchingUIState as updateExpenseAutomationActualMatchingUIState, } from './view/expenseAutomationView/reducers/actualMatchingViewReducer';
187
+ import { clearActualMatchingView as clearExpenseAutomationActualMatchingView, clearMatchNewModal, closeMatchNewModal, fetchActualMatching as fetchExpenseAutomationActualMatching, fetchActualMatchingMatch, fetchActualMatchingPage as fetchExpenseAutomationActualMatchingPage, matchAndReverseAccruals, openMatchNewModal, searchMatchAccruals, searchMatchTransactions, undoReversalAccruals, updateActualMatchingUIState as updateExpenseAutomationActualMatchingUIState, } from './view/expenseAutomationView/reducers/actualMatchingViewReducer';
188
188
  import { clearExpenseAutomationFluxAnalysisView, fetchFluxAnalysisView, reviewFluxAnalysisView, updateFluxAnalysisViewPageMetaData, updateFluxAnalysisViewUIState, updateOperatingExpensesIdsForReview, updateSelectedSectionIdsForReview, } from './view/expenseAutomationView/reducers/fluxAnalysisViewReducer';
189
189
  import { clearJeScheduleLocalData as clearExpenseAutomationJEScheduleLocalData, clearExpenseAutomationJESchedulesView, clearSearchTransactionsForNewSchedule as clearJeSearchTransactionsForNewSchedule, createOneTimeAccrual, createOneTimeAccrualFailure, createOneTimeAccrualSuccess, fetchJeSchedulesPage as fetchExpenseAutomationJESchedulesPage, fetchOneTimeAccrual, ignoreRecommendedJeSchedule as ignoreExpenseAutomationJESchedule, ignoreOneTimeAccrual, initializeAccountSettingsView as initializeJeAccountSettingsView, initializeNewSchedule as initializeJeNewSchedule, initializeJeScheduleLocalData, promoteOneTimeAccrual, removeJeScheduleTransactionKey, resetNewScheduleLocalData as resetJeNewScheduleLocalData, retryJeSchedule as retryExpenseAutomationJESchedule, revertJeSchedule, revertOneTimeAccrual, saveAccountSettings as saveJeAccountSettings, saveAccountSettingsLocalData as saveJeAccountSettingsLocalData, saveNewSchedule as saveJeNewSchedule, saveNewScheduleFailure as saveJeNewScheduleFailure, saveNewScheduleSuccess as saveJeNewScheduleSuccess, searchTransactionsForNewSchedule as searchJeTransactionsForNewSchedule, searchTransactionsForNewScheduleFailure as searchJeTransactionsForNewScheduleFailure, searchTransactionsForNewScheduleSuccess as searchJeTransactionsForNewScheduleSuccess, toggleJECreatedGroupCollapsed, toggleJEPendingGroupCollapsed, updateJESchedulesUIState as updateExpenseAutomationJESchedulesUIState, updateJEScheduleTypeFilter, updateNewScheduleLocalData as updateJeNewScheduleLocalData, updateJeScheduleLocalDataById, updateJeScheduleTransactionKeys, } from './view/expenseAutomationView/reducers/jeSchedulesViewReducer';
190
190
  import { acknowledgeBulkUploadConfirmMatchComplete, bulkUploadAutomatchingTimedOut, bulkUploadReceipts, bulkUploadReceiptsFailure, bulkUploadReceiptsSuccess, clearBulkUpload, clearBulkUploadBatchDetailsForScopeChange, clearManualSearchResults, clearMissingReceiptsTabNavigation, confirmBulkUploadMatch, confirmBulkUploadMatchFailure, confirmBulkUploadMatchSuccess, fetchBulkUploadBatchDetails, fetchBulkUploadBatchDetailsFailure, fetchBulkUploadBatchDetailsSuccess, fetchBulkUploadBatches, fetchBulkUploadBatchesFailure, fetchBulkUploadBatchesSuccess, fetchCompletedTransactions, fetchCompletedTransactionsFailure, fetchCompletedTransactionsSuccess, fetchMissingReceipts as fetchExpenseAutomationMissingReceipts, fetchMoreBatchDetails, fetchMoreBatchDetailsComplete, fetchMoreBatchDetailsFailure, markBatchDetailRefreshAttempted, markMissingReceiptAsDone as markExpenseAutomationMissingReceiptAsDone, pusherBatchStatusUpdate, refreshBatchDetailsForBatchId, requestMissingReceiptsTabNavigation, restoreBulkUploadAutomatchingOnMount, restoreBulkUploadMatchingState, searchTransactionsForManualMatch, searchTransactionsForManualMatchFailure, searchTransactionsForManualMatchSuccess, setBulkUploadCompletedSubTab, setBulkUploadResultsTab, setBulkUploadSortConfig, setBulkUploadUploadedFileCount, storeBatchDetails, updateBulkUploadProgress, updateMissingReceiptUploadState as updateExpenseAutomationMissingReceiptUploadState, updateMissingReceiptsUIState as updateExpenseAutomationMissingReceiptsUIState, uploadMissingReceiptSuccess as uploadExpenseAutomationMissingReceiptSuccess, } from './view/expenseAutomationView/reducers/missingReceiptsViewReducer';
@@ -196,7 +196,7 @@ import { getExpenseAutomationReconciliationView, getLedgerAccountIdsWithStatemen
196
196
  import { getExpenseAutomationTransactionView, getLastTransferEntryReplacement, } from './view/expenseAutomationView/selectors/transactionCategorizationSelector';
197
197
  import { applyTransactionFilters } from './view/expenseAutomationView/transactionFilterHelpers';
198
198
  import { TRANSACTION_FILTER_CATEGORIES, } from './view/expenseAutomationView/transactionFilterTypes';
199
- import { MATCH_ACCRUAL_SEARCH_LIMIT, MATCH_SEARCH_DEBOUNCE_MS, MATCH_TRANSACTION_SEARCH_PAGE_SIZE, toActualMatchingSortKey as toExpenseAutomationActualMatchingSortKey, toMatchAndReverseResultStatus, } from './view/expenseAutomationView/types/actualMatchingViewState';
199
+ import { MATCH_ACCRUAL_SEARCH_LIMIT, MATCH_SEARCH_DEBOUNCE_MS, MATCH_TRANSACTION_SEARCH_PAGE_SIZE, toActualMatchingSortKey as toExpenseAutomationActualMatchingSortKey, toMatchAndReverseResultStatus, toUndoReversalResultStatus, } from './view/expenseAutomationView/types/actualMatchingViewState';
200
200
  import { DEFAULT_COMPLETED_SUB_TAB, toCompletedSubTab, } from './view/expenseAutomationView/types/completedSubTab';
201
201
  import { ALL_JE_PAGE_TABS, toJEScheduleSortKey as toExpenseAutomationJEScheduleSortKey, toJEPageTab, } from './view/expenseAutomationView/types/jeSchedulesViewState';
202
202
  import { BATCH_FILE_STATUSES, isUnmatchedTabFileStatus, toBatchFileStatus, toBatchStatusValue, toBulkUploadPhase, toBulkUploadResultsTab, toBulkUploadSortKey, toMatchSource, toMissingReceiptsTab, } from './view/expenseAutomationView/types/missingReceiptsViewState';
@@ -487,7 +487,7 @@ export { stringToUnion, stringToUnionStrict };
487
487
  export { fetchMonthEndCloseChecks, fetchMonthClosePerformanceTrend, getMonthEndCloseChecksViewByTenantId, ALL_MONTH_END_CLOSE_CHECKS_FREQUENCY, };
488
488
  export {
489
489
  // Bulk Upload Types
490
- BATCH_FILE_STATUSES, isUnmatchedTabFileStatus, DEFAULT_COMPLETED_SUB_TAB, DEFAULT_TRANSACTION_GROUP, TRANSACTION_GROUPS, toTransactionGroup, toBatchFileStatus, toBatchStatusValue, toBulkUploadPhase, toBulkUploadResultsTab, toBulkUploadSortKey, toCompletedSubTab, toMatchSource, toMissingReceiptsTab, ALL_JE_PAGE_TABS, MATCH_ACCRUAL_SEARCH_LIMIT, MATCH_SEARCH_DEBOUNCE_MS, MATCH_TRANSACTION_SEARCH_PAGE_SIZE, toExpenseAutomationJEScheduleSortKey, toExpenseAutomationActualMatchingSortKey, toJEPageTab, toMatchAndReverseResultStatus, toggleJECreatedGroupCollapsed, toggleJEPendingGroupCollapsed, updateJEScheduleTypeFilter, getExpenseAutomationView, toExpenseAutomationMissingReceiptsSortKey, toExpenseAutomationTransactionsTabKey, toExpenseAutomationViewType, uploadExpenseAutomationMissingReceiptSuccess, markExpenseAutomationMissingReceiptAsDone, fetchAllExpenseAutomationTabs, refreshExpenseAutomationCurrentTab, updateCurrentSelectedTransactionCategorizationTab, updateTransactionCategorizationCompletedSubTab, updateTransactionGroup, fetchExpenseAutomationMissingReceipts,
490
+ BATCH_FILE_STATUSES, isUnmatchedTabFileStatus, DEFAULT_COMPLETED_SUB_TAB, DEFAULT_TRANSACTION_GROUP, TRANSACTION_GROUPS, toTransactionGroup, toBatchFileStatus, toBatchStatusValue, toBulkUploadPhase, toBulkUploadResultsTab, toBulkUploadSortKey, toCompletedSubTab, toMatchSource, toMissingReceiptsTab, ALL_JE_PAGE_TABS, MATCH_ACCRUAL_SEARCH_LIMIT, MATCH_SEARCH_DEBOUNCE_MS, MATCH_TRANSACTION_SEARCH_PAGE_SIZE, toExpenseAutomationJEScheduleSortKey, toExpenseAutomationActualMatchingSortKey, toJEPageTab, toMatchAndReverseResultStatus, toUndoReversalResultStatus, toggleJECreatedGroupCollapsed, toggleJEPendingGroupCollapsed, updateJEScheduleTypeFilter, getExpenseAutomationView, toExpenseAutomationMissingReceiptsSortKey, toExpenseAutomationTransactionsTabKey, toExpenseAutomationViewType, uploadExpenseAutomationMissingReceiptSuccess, markExpenseAutomationMissingReceiptAsDone, fetchAllExpenseAutomationTabs, refreshExpenseAutomationCurrentTab, updateCurrentSelectedTransactionCategorizationTab, updateTransactionCategorizationCompletedSubTab, updateTransactionGroup, fetchExpenseAutomationMissingReceipts,
491
491
  // Bulk Upload Actions
492
492
  bulkUploadReceipts, bulkUploadAutomatchingTimedOut, bulkUploadReceiptsSuccess, bulkUploadReceiptsFailure, restoreBulkUploadAutomatchingOnMount, restoreBulkUploadMatchingState, updateBulkUploadProgress, pusherBatchStatusUpdate, requestMissingReceiptsTabNavigation, clearMissingReceiptsTabNavigation, fetchBulkUploadBatchDetails, fetchBulkUploadBatchDetailsSuccess, fetchBulkUploadBatchDetailsFailure, storeBatchDetails, fetchMoreBatchDetails, fetchMoreBatchDetailsComplete, fetchMoreBatchDetailsFailure, fetchBulkUploadBatches, fetchBulkUploadBatchesSuccess, fetchBulkUploadBatchesFailure, clearBulkUploadBatchDetailsForScopeChange, markBatchDetailRefreshAttempted, refreshBatchDetailsForBatchId, confirmBulkUploadMatch, confirmBulkUploadMatchSuccess, confirmBulkUploadMatchFailure, setBulkUploadResultsTab, setBulkUploadCompletedSubTab, setBulkUploadSortConfig, setBulkUploadUploadedFileCount, clearBulkUpload, searchTransactionsForManualMatch, searchTransactionsForManualMatchSuccess, searchTransactionsForManualMatchFailure, clearManualSearchResults, acknowledgeBulkUploadConfirmMatchComplete, fetchCompletedTransactions, fetchCompletedTransactionsSuccess, fetchCompletedTransactionsFailure, fetchFluxAnalysisView, clearExpenseAutomationFluxAnalysisView, updateOperatingExpensesIdsForReview as updateFluxOperatingExpensesIdsForReview, updateSelectedSectionIdsForReview as updateFluxAnalysisSelectedSectionIdsForReview, reviewFluxAnalysisView, updateExpenseAutomationMissingReceiptUploadState, updateExpenseAutomationMissingReceiptsUIState, updateTransactionCategorizationUploadReceiptState, uploadTransactionCategorizationReceiptSuccess, getExpenseAutomationFluxAnalysisView, updateCurrentSelectedView, updateCurrentSelectedPeriod, getExpenseAutomationTransactionView, getLastTransferEntryReplacement, updateFluxAnalysisViewUIState, updateFluxAnalysisViewPageMetaData, MAX_SELECTION_LIMIT, checkIfAllLineItemsAreCategoryClassFilled, getLineItemsByTransactionIdsFromLocalData, isAnyItemWithUncategorizedExpenseAccount, excludeAccountFromReconciliation, includeAccountInReconciliation, saveExpenseAutomationReconciliationDetail, updateExpenseAutomationReconcileTabListScrollState, updateExpenseAutomationReconReviewTabListSortState, updateExpenseAutomationReconcileTabListSortState, updateExpenseAutomationReconcileTabLocalData, updateExpenseAutomationAccountReconciliationSelectedTab, updateExpenseAutomationAccountReconciliationSelectedAccountId, getExpenseAutomationReconciliationView, getLedgerAccountIdsWithStatementOverrideWarning, getLedgerAccountsForCombinedStatementMapping, getReparseStatementStatusByAccountId, getUnavailableLedgerAccountIds, fetchReconciliationView, uploadAccountStatementIntoDocumentAI, updateExpenseAutomationReconListScrollPosition, setConnectionInProgressForAccountReconciliation, getAccountReconByAccountIdAndSelectedPeriod, toReconciliationTabsType, isAccountReconReport, updateExpenseAutomationReconReviewTabLocalData, updateExpenseAutomationSelectedDrawerAccountId, updateStatementProcessingFailed, saveExpenseAutomationReconciliationReview, updateExpenseAutomationAccountReconciliationLocalData, toReconciliationAccountSource, deleteAccountStatement, deleteCombinedStatement, uploadAccountStatement, parseCombinedStatement, parseStatement, parseStatementSuccess, parseStatementFailure, reparseStatement, reparseStatementSuccess, reparseStatementFailure, resetReparseStatementStatus, updateParsedStatementData, updateNodeCollapseState, updateStatementUploadChosen, submitCombinedStatementUpdate, submitStatementUpdate, clearStatementDateConflict, confirmStatementMapping, updateStatementUpdateLocalData, isReviewTransactionBankTransferType, isReviewTransactionBillPaymentType, isReviewTransactionCreditCardPaymentType, isReviewTransactionDepositType, isReviewTransactionExpenseType, isReviewTransactionCreditCardCreditType, setStatementParseInProgress, setStatementProcessingDismissedToBackground, updateStatementProcessingBackgroundCompletedSteps, };
493
493
  export { computeNewScheduleJeDetails, createOneTimeAccrual, createOneTimeAccrualFailure, createOneTimeAccrualSuccess, fetchOneTimeAccrual, getJeNewAccrualAccountsView, ignoreOneTimeAccrual, promoteOneTimeAccrual, revertJeSchedule, revertOneTimeAccrual, getJeNewScheduleSearchTransactionsView, getJeNewScheduleView, };
@@ -658,7 +658,7 @@ export { TIME_SERIES_DURATIONS, convertToTimeSeriesSelectionRange, toTimeSeriesD
658
658
  export { fetchApAging, getApAgingReport, updateApAgingUIState, };
659
659
  export { fetchApAgingDetail, getApAgingDetailForVendor, updateApAgingDetailUIState, };
660
660
  export { clearExpenseAutomationJEScheduleLocalData, clearExpenseAutomationJESchedulesView, clearJeSearchTransactionsForNewSchedule, fetchExpenseAutomationJESchedulesPage, ignoreExpenseAutomationJESchedule, initializeJeAccountSettingsView, initializeJeNewSchedule, initializeJeScheduleLocalData, removeJeScheduleTransactionKey, resetJeNewScheduleLocalData, retryExpenseAutomationJESchedule, saveJeNewSchedule, saveJeNewScheduleFailure, saveJeNewScheduleSuccess, searchJeTransactionsForNewSchedule, searchJeTransactionsForNewScheduleFailure, searchJeTransactionsForNewScheduleSuccess, updateExpenseAutomationJESchedulesUIState, updateJeNewScheduleLocalData, updateJeScheduleLocalDataById, updateJeScheduleTransactionKeys, };
661
- export { clearExpenseAutomationActualMatchingView, closeMatchNewModal, clearMatchNewModal, fetchExpenseAutomationActualMatching, fetchActualMatchingMatch, fetchExpenseAutomationActualMatchingPage, matchAndReverseAccruals, openMatchNewModal, searchMatchAccruals, searchMatchTransactions, updateExpenseAutomationActualMatchingUIState, };
661
+ export { clearExpenseAutomationActualMatchingView, closeMatchNewModal, clearMatchNewModal, fetchExpenseAutomationActualMatching, fetchActualMatchingMatch, fetchExpenseAutomationActualMatchingPage, matchAndReverseAccruals, openMatchNewModal, searchMatchAccruals, searchMatchTransactions, undoReversalAccruals, updateExpenseAutomationActualMatchingUIState, };
662
662
  export { createNewSchedulesAccrued, deleteScheduleAccruedDetail, cancelScheduleAccruedJournalEntry, fetchScheduleAccruedDetails, fetchScheduleAccruedDetailsPage, resetJEAccruedLinkInLocalData, saveScheduleAccruedDetails, updateAmountsInScheduleAccruedDetail, updatedJEAccruedLinkWithRecommendedLocalData, updatedJELinkInLocalDataAccruedExpenses, fetchRecommendedTransactionRowIndex, clearSelectedJELinkRowIndex, updateLinkBillExpenseLocalData, updateScheduleAccruedDetailsLocalData, updateSelectedJEAccruedScheduleKey, resetSelectedJEAccruedScheduleKey, resetAccruedDetailNewScheduleState, };
663
663
  export { getJEScheduleTransactionKey, ALL_JE_SCHEDULE_IGNORE_REASONS, ALL_JE_SCHEDULE_REVERT_REASONS, ALL_ONE_TIME_ACCRUAL_IGNORE_REASONS, ALL_ONE_TIME_ACCRUAL_REVERT_REASONS, ALL_SCHEDULES_TYPES, getScheduleListReport, getAccruedScheduleListReport, fetchScheduleList, fetchAccruedScheduleList, fetchDownloadSchedules, fetchSchedulesAccount, updateScheduleListLocalData, getFetchStateForScheduleAccountList, toScheduleTypesType, toScheduleTypesTypeStrict, toScheduleListTabsFileTypeStrict, toScheduleSubTabType, updateScheduleListSubTab, updateScheduleListSearchText, updateScheduleListScrollState, updateScheduleListSortState, updateSelectedJEScheduleKey, fetchScheduleDetails, getScheduleDetailsView, getAccruedScheduleDetailsView, fetchScheduleDetailsPage, saveScheduleDetails, deleteScheduleDetail, createNewSchedules, updateScheduleDetailsLocalData, updateScheduleListDownloadState, updateAccruedJEScheduleAccruedByListKey, updatedSelectedJELinkRowIndex, getQBOUrlForLink, getThirdPartyIDFromQBOURL, updatedJELinkInLocalData, updateAmountsInScheduleDetail, resetJELinkInLocalData, updatedJELinkWithRecommendedLocalData, getFetchStateForScheduleListByType, getDefaultSelectedTimeframeForScheduleType, markAsCompleteScheduleDetail, resetMarkAsCompleteStatus, fetchVendorTabView, updateVendorTabViewTab, getVendorTabView, };
664
664
  export { toVendorFirstReviewViewColumnKeyType, getGlobalMerchantAutoCompleteResults, getVendorFirstReviewView, getVendorFirstReviewAttachmentView, fetchVendorFirstReviewView, fetchVendorFirstReviewAttachments, updateVendorFirstReviewViewScrollYOffset, resetVendorFirstReviewLocalData, updateVendorFirstReviewViewPageToken, clearRecentlySavedErroredVendorData, saveVendorFirstReviewView, updateVendorFirstReviewViewLocalData, updateVendorFirstReviewSortUiState, fetchGlobalMerchantAutoCompleteView, clearGlobalMerchantAutoCompleteResults, updateReviewVendorDetailLocalData, saveVendorDetailsView, getVendorDetailSelectorView, };
@@ -1,17 +1,17 @@
1
1
  import { from, of } from 'rxjs';
2
- import { catchError, filter, mergeMap, takeUntil } from 'rxjs/operators';
2
+ import { catchError, filter, mergeMap, switchMap, takeUntil, } from 'rxjs/operators';
3
3
  import { updateActualMatchingMatches } from '../../../../entity/actualMatching/actualMatchingReducer';
4
4
  import { getCurrentTenant } from '../../../../entity/tenant/tenantSelector';
5
5
  import { createZeniAPIStatus, isSuccessResponse, } from '../../../../responsePayload';
6
6
  import { clearAll } from '../../../../rootActions';
7
7
  import { toServiceMonthFromPeriod, } from '../../payload/actualMatchingPayload';
8
8
  import { fetchActualMatching, fetchActualMatchingFailure, fetchActualMatchingSuccess, } from '../../reducers/actualMatchingViewReducer';
9
- export const fetchActualMatchingEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(fetchActualMatching.match), mergeMap((action) => {
9
+ export const fetchActualMatchingEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(fetchActualMatching.match), switchMap((action) => {
10
10
  const state = state$.value;
11
11
  const { period, refreshViewInBackground } = action.payload;
12
12
  const currentTenant = getCurrentTenant(state);
13
13
  const selectedPeriod = state.expenseAutomationViewState
14
- .selectedPeriodByTenantId[currentTenant.tenantId] ?? {
14
+ .selectedPeriodByTenantId[currentTenant?.tenantId ?? ''] ?? {
15
15
  month: period.start.month,
16
16
  year: period.start.year,
17
17
  };
@@ -20,7 +20,7 @@ export const fetchActualMatchingEpic = (actions$, state$, zeniAPI) => actions$.p
20
20
  .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/accruals/actual-matching?service_month=${encodeURIComponent(serviceMonth)}`)
21
21
  .pipe(mergeMap((response) => {
22
22
  if (isSuccessResponse(response) && response.data != null) {
23
- const matches = response.data.matches ?? [];
23
+ const matches = response.data.matches;
24
24
  const updateActions = [];
25
25
  if (matches.length > 0) {
26
26
  updateActions.push(updateActualMatchingMatches(matches));
@@ -7,7 +7,8 @@ import { clearAll } from '../../../../rootActions';
7
7
  import { toMatchAndReverseResult, } from '../../payload/actualMatchingPayload';
8
8
  import { clearMatchNewModal, fetchActualMatching, matchAndReverseAccruals, matchAndReverseAccrualsFailure, matchAndReverseAccrualsSuccess, } from '../../reducers/actualMatchingViewReducer';
9
9
  function refreshActualMatchingList(state) {
10
- const selectedMonthYear = state.expenseAutomationViewState.selectedPeriodByTenantId[getCurrentTenant(state).tenantId];
10
+ const currentTenant = getCurrentTenant(state);
11
+ const selectedMonthYear = state.expenseAutomationViewState.selectedPeriodByTenantId[currentTenant?.tenantId ?? ''];
11
12
  if (selectedMonthYear == null) {
12
13
  return [];
13
14
  }
@@ -20,19 +21,20 @@ function refreshActualMatchingList(state) {
20
21
  return [fetchActualMatching({ start, end }, true)];
21
22
  }
22
23
  export const matchAndReverseAccrualsEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(matchAndReverseAccruals.match), mergeMap((action) => {
23
- const { transactionId, transactionIntegrationId, transactionType, lineId, accrualIds, } = action.payload;
24
+ const { transactionId, transactionIntegrationId, transactionType, lineId, accrualIds, transactionSyncToken, } = action.payload;
24
25
  const body = {
25
26
  transaction_id: transactionId,
26
27
  transaction_integration_id: transactionIntegrationId,
27
28
  transaction_type: transactionType,
28
29
  line_id: lineId,
30
+ transaction_sync_token: transactionSyncToken,
29
31
  accrual_ids: accrualIds,
30
32
  };
31
33
  return zeniAPI
32
34
  .postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/accruals/match-and-reverse`, body)
33
35
  .pipe(mergeMap((response) => {
34
36
  if (isSuccessResponse(response) && response.data != null) {
35
- const results = (response.data.results ?? []).map(toMatchAndReverseResult);
37
+ const results = response.data.results.map(toMatchAndReverseResult);
36
38
  const successActions = [
37
39
  matchAndReverseAccrualsSuccess({ results }),
38
40
  ];
@@ -17,7 +17,7 @@ export const searchMatchAccrualsEpic = (actions$, _state$, zeniAPI) => {
17
17
  .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/accruals?status=posted&reversal_policy=on_bill_match&search_text=${searchText}&limit=${limit}&offset=${offset}`)
18
18
  .pipe(mergeMap((response) => {
19
19
  if (isSuccessResponse(response) && response.data != null) {
20
- const accruals = response.data.accruals ?? [];
20
+ const accruals = response.data.accruals;
21
21
  const append = pageToken != null;
22
22
  const nextOffset = offset + accruals.length;
23
23
  const total = response.data.total ?? nextOffset;
@@ -15,7 +15,7 @@ export const searchMatchTransactionsEpic = (actions$, state$, zeniAPI) => {
15
15
  searchMatchAccruals({ query: '' }),
16
16
  ]);
17
17
  }
18
- const match = getActualMatchingMatchById(matchId, state$.value.actualMatchingState);
18
+ const match = getActualMatchingMatchById(state$.value.actualMatchingState, matchId);
19
19
  const parsed = parseActualMatchingMatchId(matchId);
20
20
  const transactionType = match?.transactionType != null && match.transactionType !== ''
21
21
  ? match.transactionType
@@ -54,7 +54,7 @@ export const searchMatchTransactionsEpic = (actions$, state$, zeniAPI) => {
54
54
  if (isSuccessResponse(response) && response.data != null) {
55
55
  const { transactions, next_page_token } = response.data;
56
56
  const append = pageToken != null;
57
- const results = (transactions ?? []).map(toActualMatchingTransactionSearchResult);
57
+ const results = transactions.map(toActualMatchingTransactionSearchResult);
58
58
  return of(searchMatchTransactionsSuccess({
59
59
  append,
60
60
  nextPageToken: next_page_token ?? null,
@@ -0,0 +1,52 @@
1
+ import { from, of } from 'rxjs';
2
+ import { catchError, filter, mergeMap, takeUntil } from 'rxjs/operators';
3
+ import { convertToPeriod, toAbsoluteDay, } from '../../../../commonStateTypes/timePeriod';
4
+ import { getCurrentTenant } from '../../../../entity/tenant/tenantSelector';
5
+ import { createZeniAPIStatus, isSuccessResponse, } from '../../../../responsePayload';
6
+ import { clearAll } from '../../../../rootActions';
7
+ import { toUndoReversalResult, } from '../../payload/actualMatchingPayload';
8
+ import { fetchActualMatching, fetchActualMatchingMatch, undoReversalAccruals, undoReversalAccrualsFailure, undoReversalAccrualsSuccess, } from '../../reducers/actualMatchingViewReducer';
9
+ function refreshActualMatchingList(state) {
10
+ const currentTenant = getCurrentTenant(state);
11
+ const selectedMonthYear = state.expenseAutomationViewState.selectedPeriodByTenantId[currentTenant?.tenantId ?? ''];
12
+ if (selectedMonthYear == null) {
13
+ return [];
14
+ }
15
+ const period = convertToPeriod(selectedMonthYear);
16
+ const start = toAbsoluteDay(period.start);
17
+ const end = toAbsoluteDay(period.end);
18
+ if (start == null || end == null) {
19
+ return [];
20
+ }
21
+ return [fetchActualMatching({ start, end }, true)];
22
+ }
23
+ function refreshOpenMatchDetails(state) {
24
+ const detailState = state.expenseAutomationActualMatchingViewState.detailFetchStateByMatchId;
25
+ return Object.keys(detailState)
26
+ .filter((matchId) => detailState[matchId]?.fetchState !== 'Not-Started')
27
+ .map((matchId) => fetchActualMatchingMatch(matchId, true));
28
+ }
29
+ export const undoReversalAccrualsEpic = (actions$, state$, zeniAPI) => actions$.pipe(filter(undoReversalAccruals.match), mergeMap((action) => {
30
+ const body = {
31
+ accrual_ids: action.payload.accrualIds,
32
+ };
33
+ return zeniAPI
34
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/accruals/undo-reversal`, body)
35
+ .pipe(mergeMap((response) => {
36
+ if (isSuccessResponse(response) && response.data != null) {
37
+ const results = response.data.results.map(toUndoReversalResult);
38
+ const successActions = [
39
+ undoReversalAccrualsSuccess({ results }),
40
+ ];
41
+ const anyUndone = results.some((result) => result.status === 'undone');
42
+ if (anyUndone) {
43
+ successActions.push(...refreshActualMatchingList(state$.value), ...refreshOpenMatchDetails(state$.value));
44
+ }
45
+ return from(successActions);
46
+ }
47
+ return of(undoReversalAccrualsFailure({ status: response.status }));
48
+ }), catchError((error) => of(undoReversalAccrualsFailure({
49
+ status: createZeniAPIStatus('Unexpected Error', 'Undo reversal accruals REST API call errored out' +
50
+ JSON.stringify(error)),
51
+ }))), takeUntil(actions$.pipe(filter(clearAll.match))));
52
+ }));
@@ -1,5 +1,5 @@
1
1
  import { toString } from '../../../commonStateTypes/timePeriod';
2
- import { toMatchAndReverseResultStatus, } from '../types/actualMatchingViewState';
2
+ import { toMatchAndReverseResultStatus, toUndoReversalResultStatus, } from '../types/actualMatchingViewState';
3
3
  export function toServiceMonthFromPeriod(period) {
4
4
  return toString(period.start).slice(0, 7);
5
5
  }
@@ -49,6 +49,7 @@ export function toActualMatchingTransactionSearchResult(payload) {
49
49
  transactionMemo: payload.transaction_memo ?? undefined,
50
50
  transactionDescription: payload.transaction_description ?? undefined,
51
51
  transactionTypeName: payload.transaction_type_name ?? undefined,
52
+ syncToken: payload.sync_token == null ? '' : String(payload.sync_token),
52
53
  };
53
54
  }
54
55
  export function toMatchAndReverseResult(payload) {
@@ -58,3 +59,10 @@ export function toMatchAndReverseResult(payload) {
58
59
  reason: payload.reason ?? undefined,
59
60
  };
60
61
  }
62
+ export function toUndoReversalResult(payload) {
63
+ return {
64
+ accrualId: payload.accrual_id,
65
+ status: toUndoReversalResultStatus(payload.status),
66
+ reason: payload.reason ?? undefined,
67
+ };
68
+ }
@@ -43,6 +43,7 @@ export const initialState = {
43
43
  scrollPosition: { scrollTop: 0, scrollLeft: undefined },
44
44
  },
45
45
  matchModal: initialMatchModalState,
46
+ undoReversalStatus: { fetchState: 'Not-Started', error: undefined },
46
47
  hasValidState() {
47
48
  return this.fetchState == 'Completed';
48
49
  },
@@ -325,6 +326,30 @@ const expenseAutomationActualMatchingView = createSlice({
325
326
  error: action.payload.status,
326
327
  };
327
328
  },
329
+ undoReversalAccruals: {
330
+ reducer(draft) {
331
+ draft.undoReversalStatus = {
332
+ fetchState: 'In-Progress',
333
+ error: undefined,
334
+ };
335
+ },
336
+ prepare(params) {
337
+ return { payload: params };
338
+ },
339
+ },
340
+ undoReversalAccrualsSuccess(draft, action) {
341
+ draft.undoReversalStatus = {
342
+ fetchState: 'Completed',
343
+ error: undefined,
344
+ };
345
+ void action;
346
+ },
347
+ undoReversalAccrualsFailure(draft, action) {
348
+ draft.undoReversalStatus = {
349
+ fetchState: 'Error',
350
+ error: action.payload.status,
351
+ };
352
+ },
328
353
  clearActualMatchingView(draft) {
329
354
  Object.assign(draft, initialState);
330
355
  },
@@ -335,5 +360,5 @@ const expenseAutomationActualMatchingView = createSlice({
335
360
  });
336
361
  },
337
362
  });
338
- export const { clearActualMatchingView, clearMatchNewModal, closeMatchNewModal, fetchActualMatching, fetchActualMatchingFailure, fetchActualMatchingMatch, fetchActualMatchingMatchFailure, fetchActualMatchingMatchSuccess, fetchActualMatchingPage, fetchActualMatchingSuccess, matchAndReverseAccruals, matchAndReverseAccrualsFailure, matchAndReverseAccrualsSuccess, openMatchNewModal, searchMatchAccruals, searchMatchAccrualsFailure, searchMatchAccrualsSuccess, searchMatchTransactions, searchMatchTransactionsFailure, searchMatchTransactionsSuccess, updateActualMatchingUIState, } = expenseAutomationActualMatchingView.actions;
363
+ export const { clearActualMatchingView, clearMatchNewModal, closeMatchNewModal, fetchActualMatching, fetchActualMatchingFailure, fetchActualMatchingMatch, fetchActualMatchingMatchFailure, fetchActualMatchingMatchSuccess, fetchActualMatchingPage, fetchActualMatchingSuccess, matchAndReverseAccruals, matchAndReverseAccrualsFailure, matchAndReverseAccrualsSuccess, openMatchNewModal, searchMatchAccruals, searchMatchAccrualsFailure, searchMatchAccrualsSuccess, searchMatchTransactions, searchMatchTransactionsFailure, searchMatchTransactionsSuccess, undoReversalAccruals, undoReversalAccrualsFailure, undoReversalAccrualsSuccess, updateActualMatchingUIState, } = expenseAutomationActualMatchingView.actions;
339
364
  export default expenseAutomationActualMatchingView.reducer;