@zeniai/client-epic-state 4.11.96 → 4.11.98

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.
@@ -1,6 +1,6 @@
1
1
  import { ZeniDate } from '../../zeniDayJS';
2
2
  import { Amount } from '../amount';
3
- import { ID } from '../common';
3
+ import { FetchStateAndError, ID } from '../common';
4
4
  import { AdditionalBalancesOptions } from './additionalBalances/getAdditionalBalances';
5
5
  import { COABalancesFilter, COABalancesSlice } from './coaBalancesFilter';
6
6
  import { COABalanceType } from './coaBalanceType';
@@ -29,6 +29,8 @@ export interface COABalanceWithPercent extends COABalance {
29
29
  export declare const toCOABalanceTimeframe: (v?: string | undefined) => "month" | "year" | "quarter" | "week" | "free_range" | undefined;
30
30
  export declare type COABalanceTimeFrame = NonNullable<ReturnType<typeof toCOABalanceTimeframe>>;
31
31
  export declare type COABalanceMonthQuarterTimeframe = Extract<COABalanceTimeFrame, 'month' | 'quarter'>;
32
+ export declare type COABalanceMonthQuarterYearTimeframe = Exclude<COABalanceTimeFrame, 'free_range' | 'week'>;
33
+ export declare type FetchStateByTimeframe = Record<COABalanceMonthQuarterYearTimeframe, FetchStateAndError>;
32
34
  export interface COABalanceGroupedByPeriod {
33
35
  weeks?: COABalance[];
34
36
  months?: COABalance[];
@@ -1,10 +1,10 @@
1
1
  import { FetchState, ID } from '../common';
2
- import { COABalanceTimeFrame } from '../coaBalance/coaBalance';
2
+ import { COABalanceMonthQuarterYearTimeframe } from '../coaBalance/coaBalance';
3
3
  import { COABalancesOrder, COABalancesRange, COABalancesRangeWithThisPeriod } from '../coaBalance/coaBalancesFilter';
4
4
  import { COABalanceType } from '../coaBalance/coaBalanceType';
5
5
  import { ReportFormat } from './viewAndReport';
6
6
  export interface ReportUIState {
7
- timeframe: Exclude<COABalanceTimeFrame, 'free_range' | 'week'>;
7
+ timeframe: COABalanceMonthQuarterYearTimeframe;
8
8
  isAdditionalBalancesShown: boolean;
9
9
  selectedAdditionalBalances: COABalanceType[];
10
10
  selectedCOABalancesRange: COABalancesRange;
package/lib/index.d.ts CHANGED
@@ -153,10 +153,10 @@ import { fetchDashboard } from './view/dashboard/dashboardReducer';
153
153
  import { getDashboard, DashboardReport } from './view/dashboard/dashboardSelector';
154
154
  export { fetchDashboard, getDashboard, DashboardReport };
155
155
  export { PandLWithForecastView, getPandLWithForecast, } from './view/profitAndLoss/pAndLWithForecast/pAndLWithForecastSelector';
156
- import { fetchProfitAndLoss, updateProfitAndLossUIState, resetProfitAndLossNodeCollapseState } from './view/profitAndLoss/profitAndLossReducer';
156
+ import { fetchProfitAndLoss, updateProfitAndLossUIState, resetProfitAndLossNodeCollapseState, fetchProfitAndLossForTimeframe } from './view/profitAndLoss/profitAndLossReducer';
157
157
  import { ProfitAndLossState, ProfitAndLossUIState } from './view/profitAndLoss/profitAndLossState';
158
158
  import { getProfitAndLossReport, ProfitAndLossReport, getPandLReportFetchState } from './view/profitAndLoss/profitAndLossSelector';
159
- export { fetchProfitAndLoss, resetProfitAndLossNodeCollapseState, updateProfitAndLossUIState, ProfitAndLossState, ProfitAndLossUIState, getProfitAndLossReport, ProfitAndLossReport, getPandLReportFetchState, };
159
+ export { fetchProfitAndLoss, resetProfitAndLossNodeCollapseState, updateProfitAndLossUIState, ProfitAndLossState, ProfitAndLossUIState, getProfitAndLossReport, ProfitAndLossReport, getPandLReportFetchState, fetchProfitAndLossForTimeframe, };
160
160
  import { fetchProfitAndLossClassesView, updateClassesToFilterOut as updateProfitAndLossClassesToFilterOut, updateProfitAndLossClassesViewUIState, resetProfitAndLossClassesNodeCollapseState, updateAccountViewMode as updateProfitAndLossAccountViewMode } from './view/profitAndLossClassesView/profitAndLossClassesViewReducer';
161
161
  import { ProfitAndLossClassesViewReport, PandLReportViewSectionID, PandLReportViewCalculatedSectionID, isPandLReportViewCalculatedSectionID, isPandLReportViewSectionID } from './view/profitAndLossClassesView/profitAndLossClassesViewSelectorTypes';
162
162
  import { getProfitAndLossClassesView } from './view/profitAndLossClassesView/profitAndLossClassesViewSelector';
@@ -178,16 +178,16 @@ import { isAccountingTabVisible, isApprovalRulesTabVisible, isBankConnectionsTab
178
178
  export { REMINDER_NOTIFICATION_TYPES, NOTIFICATION_MODES, clearSettingsView, fetchMyProfileView, fetchMyProfile, fetchBankConnectionsView, fetchBillingAccountsView, fetchNotificationSettings, saveNotificationSettings, updateNotificationSettingsLocalData, fetchNotificationSettingsView, resetNotificationSettingsLocalData, resetNotificationSettingsUpdateStatus, refreshQBOData, updateSettingsViewUIState, isMonthEndNotificationsSectionVisibleOnSettingsPage, getNotificationSettingsView, getNotificationSettings, getBillingAccountsViewDetails, getMyProfileView, getMyBankConnectionsDetails, isAccountingTabVisible, isApprovalRulesTabVisible, isBankConnectionsTabVisible, isBusinessVerificationTabVisible, isCompanyDetailsTabVisible, isIntegrationsTabVisible, isSettingsVisible, isMyBankConnectionsTabVisible, isNotificationsTabVisible, isRemindersSectionVisibleOnSettingsPage, MyProfileSelectorView, MyBankConnectionsView, BillingView, MyProfile, SettingsViewState, SettingsViewUIState, NotificationSettings, NotificationSettingsLocalData, ReminderNotificationSettingsLocalData, NotificationSettingsSelectorView, ReminderNotificationSettingsData, MonthEndInsightsNotificationSettingsData, MonthEndInsightsNotificationSettingsLocalData, ReminderTypeKey, NotificationModeKey, FrequencyTypeKey, RemindersLocalData, IntegrationsSettings, ProductWisePrimaryAccount, };
179
179
  import { PeopleViewSortKey } from './view/people/peopleTypes';
180
180
  export { PeopleViewSortKey };
181
- import { fetchBalanceSheet, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState } from './view/balanceSheet/balanceSheetReducer';
181
+ import { fetchBalanceSheet, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState, fetchBalanceSheetForTimeframe } from './view/balanceSheet/balanceSheetReducer';
182
182
  import { BalanceSheetState, BalanceSheetUIState } from './view/balanceSheet/balanceSheetState';
183
183
  import { getBalanceSheet, getBalanceSheetForFullDataAvailableRange, getBalanceSheetFetchState } from './view/balanceSheet/balanceSheetSelector';
184
184
  import { BalanceSheetReport, BalanceSheetReportViewID, SectionIdsWithSubSectionIds as BalanceSheetSectionIdsWithSubSectionIds, typeOfBalanceSheetRootSection, isBalanceSheetReportViewSectionID, isBalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewSectionID, BalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewRootSectionID } from './view/balanceSheet/balanceSheetSelectorTypes';
185
- export { fetchBalanceSheet, BalanceSheetReport, getBalanceSheet, getBalanceSheetFetchState, getBalanceSheetForFullDataAvailableRange, BalanceSheetState, BalanceSheetUIState, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState, BalanceSheetReportViewID, BalanceSheetSectionIdsWithSubSectionIds, BalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewSectionID, BalanceSheetReportViewRootSectionID, typeOfBalanceSheetRootSection, isBalanceSheetReportViewSectionID, isBalanceSheetReportViewCalculatedSectionID, };
186
- import { fetchCashFlow, resetCashFlowNodeCollapseState, updateCashFlowUIState } from './view/cashFlow/cashFlowReducer';
185
+ export { fetchBalanceSheet, BalanceSheetReport, getBalanceSheet, getBalanceSheetFetchState, getBalanceSheetForFullDataAvailableRange, BalanceSheetState, BalanceSheetUIState, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState, BalanceSheetReportViewID, BalanceSheetSectionIdsWithSubSectionIds, BalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewSectionID, BalanceSheetReportViewRootSectionID, typeOfBalanceSheetRootSection, isBalanceSheetReportViewSectionID, isBalanceSheetReportViewCalculatedSectionID, fetchBalanceSheetForTimeframe, };
186
+ import { fetchCashFlow, resetCashFlowNodeCollapseState, updateCashFlowUIState, fetchCashFlowForTimeframe } from './view/cashFlow/cashFlowReducer';
187
187
  import { CashFlowReport, CashFlowReportViewRootSectionID, SectionIdsWithSubSectionIds as CashFlowSectionIdsWithSubSectionIds, typeOfCashFlowRootSection } from './view/cashFlow/cashFlowSelectorTypes';
188
188
  import { CashFlowReportViewID, isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewSectionID, isCashFlowReportViewCalculatedSectionType1ID, CashFlowReportViewSectionID, CashFlowReportViewCalculatedSectionID } from './view/cashFlow/cashFlowPayload';
189
189
  import { getCashFlow, getCashFlowReportFetchState } from './view/cashFlow/cashFlowSelector';
190
- export { fetchCashFlow, CashFlowReport, getCashFlow, getCashFlowReportFetchState, CashFlowReportViewCalculatedSectionID, resetCashFlowNodeCollapseState, updateCashFlowUIState, CashFlowReportViewRootSectionID, CashFlowSectionIdsWithSubSectionIds, typeOfCashFlowRootSection, CashFlowReportViewID, isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewSectionID, isCashFlowReportViewCalculatedSectionType1ID, CashFlowReportViewSectionID, };
190
+ export { fetchCashFlow, CashFlowReport, getCashFlow, getCashFlowReportFetchState, CashFlowReportViewCalculatedSectionID, resetCashFlowNodeCollapseState, updateCashFlowUIState, CashFlowReportViewRootSectionID, CashFlowSectionIdsWithSubSectionIds, typeOfCashFlowRootSection, CashFlowReportViewID, isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewSectionID, isCashFlowReportViewCalculatedSectionType1ID, CashFlowReportViewSectionID, fetchCashFlowForTimeframe, };
191
191
  import { FinanceStatementReport, getFinanceStatement } from './view/financeStatement/financeStatementSelector';
192
192
  import { fetchFinanceStatement, updateCOABalancesRange, updateSelectedReportId, updateDownloadState, updateFinanceStatementAdditionalBalancesSelection, updateFinanceStatementDisplayOrder, updateFinanceStatementFormat } from './view/financeStatement/financeStatementReducer';
193
193
  export { FinanceStatementReport, getFinanceStatement, fetchFinanceStatement, updateCOABalancesRange, updateSelectedReportId, updateDownloadState, updateFinanceStatementAdditionalBalancesSelection, updateFinanceStatementDisplayOrder, updateFinanceStatementFormat, };
package/lib/index.js CHANGED
@@ -31,24 +31,24 @@ exports.hasAdminLevelAccess = exports.isFinOpsUserRoleType = exports.toUserRoleT
31
31
  exports.fetchOpExWithForecast = exports.getOperatingExpensesForHighlightedRange = exports.getOperatingExpensesForSelectedRange = exports.getOperatingExpensesUIState = exports.getOperatingExpensesReport = exports.getOperatingExpensesReportFetchState = exports.updateOpExUIState = exports.updateOpExDownloadState = exports.updateOpExCOABalancesRange = exports.fetchOpEx = exports.fetchReimbursementCard = exports.fetchBillPayCard = exports.fetchCashBalance = exports.getCashBalance = exports.updateStatementCloseDay = exports.fetchCardBalance = exports.getCardBalance = exports.hasReimbursementAccessible = exports.hasBillPayAccessible = exports.hasAnyFinOpRole = exports.hasAnyCompanyRole = exports.hasZeniAccountsAdminLevelAccess = exports.hasSpendManagementAdminLevelAccess = exports.hasSpendManagementAccess = exports.hasChargeCardAdminLevelAccess = exports.hasBillPayAdminLevelAccess = exports.hasReimbursementAdminLevelAccess = exports.hasReimbursementAccess = exports.hasBillPayAccess = exports.hasZeniAccountsAccess = exports.hasChargeCardAccess = exports.getUserRoleByUserIds = exports.getUserRoleByUserId = exports.isZeniSignedInUser = exports.hasOnlyZeniAccountsAccess = exports.hasOnlyChargeCardAccess = exports.hasOnlyReimbursementAccess = exports.hasRemiFallbackAdminLevelAccess = exports.hasBillPayFallbackAdminLevelAccess = exports.hasSuperAdminLevelAccess = exports.hasZeniRoleOrCompanyOfficerAccess = exports.hasOnlyBillPayAccess = exports.getUserRoleMap = exports.hasInvestorBankerLevelAccess = exports.isNonZeniRole = exports.hasBookKeepingUserLevelAccess = exports.hasBookKeepingAdminLevelAccess = exports.hasEmployeeLevelAccess = exports.hasReimbursementUserAccess = exports.hasFullOrAdminLevelAccess = void 0;
32
32
  exports.toAverageMonthsCount = exports.getNetBurnOrIncomeStoryCardReport = exports.updateNetBurnOrIncomeStoryCardSettings = exports.fetchNetBurnOrIncomeStoryCard = exports.isNetBurnOrIncomeReportViewSectionID = exports.isNetBurnOrIncomeReportViewCalculatedSectionID = exports.getNetBurnOrIncomeReportFetchState = exports.getNetBurnOrIncomeUIState = exports.getNetBurnOrIncomeForHighlightedRange = exports.getNetBurnOrIncomeForSelectedRange = exports.getNetBurnOrIncomeReport = exports.updateNetBurnOrIncomeDownloadState = exports.updateNetBurnOrIncomeCOABalancesRange = exports.fetchNetBurnOrIncomeWithForecast = exports.updateNetBurnOrIncomeUIState = exports.fetchNetBurnOrIncome = exports.isNetBurnOrIncomeClassesViewCalculatedSectionID = exports.isNetBurnOrIncomeClassesViewSectionID = exports.getNetBurnOrIncomeClassesViewForSelectedRange = exports.getNetBurnOrIncomeClassesViewForHighlightedRange = exports.getNetBurnOrIncomeClassesView = exports.updateNetBurnOrIncomeClassesViewUIState = exports.updateNetBurnOrIncomeClassesToFilterOut = exports.updateNetBurnOrIncomeAccountViewMode = exports.fetchNetBurnOrIncomeClassesView = exports.isOpExClassesViewCalculatedSectionID = exports.isOpExClassesViewSectionID = exports.getOpExClassesViewForSelectedRange = exports.getOpExClassesViewForHighlightedRange = exports.getOpExClassesView = exports.updateOpExClassesViewUIState = exports.updateOpExClassesToFilterOut = exports.updateOpExAccountViewMode = exports.fetchOpExClassesView = exports.isOpexByVendorIDNotSpecifiedVendor = exports.getOpexVendorTimeframeKey = exports.toOpexByVendorSortKeyType = exports.updateOpExByVendorPageLimit = exports.clearOpExByVendorSearch = exports.updateOpExByVendorDownloadState = exports.updateOpExByVendorSortOrSearchInProgress = exports.updateOpExByVendorPageFetchInProgress = exports.updateOpExByVendorSort = exports.updateOpExByVendorAdditionalBalancesSelection = exports.getOpExByVendorUIState = exports.getOpExByVendorReport = exports.updateOpExByVendorUIState = exports.updateOpExByVendorTimeFrame = exports.fetchOpExByVendorReportForTimeframe = exports.fetchOpExByVendor = void 0;
33
33
  exports.getProfitAndLossReport = exports.updateProfitAndLossUIState = exports.resetProfitAndLossNodeCollapseState = exports.fetchProfitAndLoss = exports.getPandLWithForecast = exports.getDashboard = exports.fetchDashboard = exports.getAllTopExpenses = exports.getTop6Expenses = exports.getTopExpenses = exports.updateTopExDownloadState = exports.updateTopExTimeFrame = exports.fetchTopEx = exports.updateCashInCashOutUIState = exports.updateCashInCashOutDownloadState = exports.updateCashInCashOutCOABalancesRange = exports.getCashInCashOutForHighlightedRange = exports.getCashInCashOutForSelectedRange = exports.getCashInCashOutUIState = exports.getCashInCashOut = exports.fetchCashInCashOut = exports.getCashPositionForHighlightedRange = exports.getCashPositionForSelectedRange = exports.getCashPositionUIState = exports.getCashPosition = exports.updateCashPositionUIState = exports.updateCashPositionDownloadState = exports.updateCashPositionCOABalancesRange = exports.fetchCashPosition = exports.isRevenueClassesViewCalculatedSectionID = exports.isRevenueClassesViewSectionID = exports.getRevenueClassesViewForSelectedRange = exports.getRevenueClassesViewForHighlightedRange = exports.getRevenueClassesView = exports.updateRevenueClassesViewUIState = exports.updateRevenueClassesToFilterOut = exports.updateRevenueAccountViewMode = exports.fetchRevenueClassesView = exports.isRevenueSectionID = exports.isRevenueCalculatedSectionID = exports.updateRevenueUIState = exports.updateRevenueDownloadState = exports.updateRevenueCOABalancesRange = exports.getRevenueForHighlightedRange = exports.getRevenueForSelectedRange = exports.getRevenueUIState = exports.getRevenueReportFetchState = exports.getRevenueReport = exports.fetchRevenueWithForecast = exports.fetchRevenue = void 0;
34
- exports.isApprovalRulesTabVisible = exports.isAccountingTabVisible = exports.getMyBankConnectionsDetails = exports.getMyProfileView = exports.getBillingAccountsViewDetails = exports.getNotificationSettings = exports.getNotificationSettingsView = exports.isMonthEndNotificationsSectionVisibleOnSettingsPage = exports.updateSettingsViewUIState = exports.refreshQBOData = exports.resetNotificationSettingsUpdateStatus = exports.resetNotificationSettingsLocalData = exports.fetchNotificationSettingsView = exports.updateNotificationSettingsLocalData = exports.saveNotificationSettings = exports.fetchNotificationSettings = exports.fetchBillingAccountsView = exports.fetchBankConnectionsView = exports.fetchMyProfile = exports.fetchMyProfileView = exports.clearSettingsView = exports.NOTIFICATION_MODES = exports.REMINDER_NOTIFICATION_TYPES = exports.initializeEditPerson = exports.getPeopleLocalData = exports.getPeople = exports.peopleClearDataInLocalStore = exports.peopleSaveDataInLocalStore = exports.resetUpdateErrorMessage = exports.peopleSaveUpdates = exports.updatePeopleUIState = exports.inviteZeniPeople = exports.invitePeople = exports.changeZeniPersonRoles = exports.resendInvite = exports.deletePerson = exports.fetchPeople = exports.fetchPeoplePage = exports.fetchAllPeopleRequiredViews = exports.getUserList = exports.fetchUserListByType = exports.isPandLReportViewSectionID = exports.isPandLReportViewCalculatedSectionID = exports.getProfitAndLossClassesView = exports.updateProfitAndLossAccountViewMode = exports.updateProfitAndLossClassesViewUIState = exports.resetProfitAndLossClassesNodeCollapseState = exports.updateProfitAndLossClassesToFilterOut = exports.fetchProfitAndLossClassesView = exports.getPandLReportFetchState = void 0;
35
- exports.clearTransactionList = exports.isTransferTransaction = exports.isVendorTransaction = exports.updateVendors = exports.defaultVendorCurrency = exports.toTransactionCategory = exports.toTransactionTypeStrict = exports.toTransactionType = exports.toPlatformLineDetailType = exports.toTransactionID = exports.isCustomerTransaction = exports.defaultCustomerCurrency = exports.toAttachment = exports.mapFileEntityToAttachment = exports.toContentType = exports.toContentTypeStrict = exports.updateFinanceStatementFormat = exports.updateFinanceStatementDisplayOrder = exports.updateFinanceStatementAdditionalBalancesSelection = exports.updateDownloadState = exports.updateSelectedReportId = exports.updateCOABalancesRange = exports.fetchFinanceStatement = exports.getFinanceStatement = exports.isCashFlowReportViewCalculatedSectionType1ID = exports.isCashFlowReportViewSectionID = exports.isCashFlowReportViewCalculatedSectionID = exports.typeOfCashFlowRootSection = exports.updateCashFlowUIState = exports.resetCashFlowNodeCollapseState = exports.getCashFlowReportFetchState = exports.getCashFlow = exports.fetchCashFlow = exports.isBalanceSheetReportViewCalculatedSectionID = exports.isBalanceSheetReportViewSectionID = exports.typeOfBalanceSheetRootSection = exports.updateBalanceSheetUIState = exports.resetBalanceSheetNodeCollapseState = exports.getBalanceSheetForFullDataAvailableRange = exports.getBalanceSheetFetchState = exports.getBalanceSheet = exports.fetchBalanceSheet = exports.isRemindersSectionVisibleOnSettingsPage = exports.isNotificationsTabVisible = exports.isMyBankConnectionsTabVisible = exports.isSettingsVisible = exports.isIntegrationsTabVisible = exports.isCompanyDetailsTabVisible = exports.isBusinessVerificationTabVisible = exports.isBankConnectionsTabVisible = void 0;
36
- exports.updateReportUIOptionTimeframe = exports.getForecastList = exports.fetchForecastList = exports.updateSelectedInsightIndex = exports.fetchInsightsCard = exports.getInsights = exports.getUpdatablePeriodsForTransactionRecommendations = exports.getTransactionDetailForTransaction = exports.getTransactionDetail = exports.getTransactionListByEntityForSinglePeriod = exports.getTransactionListUIStateByClassKey = exports.getTransactionListByClass = exports.getTransactionListByEntity = exports.getThirdPartyIdFromTransactionId = exports.uploadMissingReceiptSuccess = exports.updateTransactionDetail = exports.fetchTransactionDetail = exports.setIsVendorUpdateAllChecked = exports.updateVendorBulkRecommendationsFetchStatus = exports.updateLatestSelectedEntity = exports.resetAllLineItemsToVendor = exports.updateVendorToAllLineItems = exports.updateLocalDataWithTransactionsUpdateWithVendorCheckbox = exports.resetVendor = exports.updateSelectedVendor = exports.removeEntityRecommendationForLineIdForTransactionDetail = exports.initializeTransactionDetailLocalData = exports.setAllLineItemsLocalDataIsUpdateAllChecked = exports.saveTransactionDetail = exports.setAllLineItemsToCategoryClassInLocalData = exports.resetLineItemsCategoryClassInLocalData = exports.updateTransactionListByEntityFailure = exports.clearTransactionDetailSaveStatus = exports.saveTransactionDetailLocalData = exports.updateTransactionListByEntity = exports.fetchEntityTransactionList = exports.getTransactionListUIStateByAccountKey = exports.getTransactionListByAccount = exports.parallelFetchTransactionListByCategoryType = exports.updateTransactionListUIStateByCategoryType = exports.updateTransactionListByClass = exports.updateTransactionListByClassUIState = exports.parallelFetchClassTransactionList = exports.updateTransactionListByAccountUIState = exports.updateTransactionListByAccountFailure = exports.updateTransactionListByAccount = exports.fetchAccountTransactionList = exports.parallelFetchEntityTransactionList = exports.parallelFetchAccountTransactionList = exports.updateLatestTransactionId = void 0;
37
- exports.fetchSubscriptionView = exports.fetchPortfolioView = exports.fetchManagementView = exports.fetchOnboardingView = exports.fetchParentSubsidiaryManagementView = exports.updateCompanyManagementUIState = exports.updateCompanyPortfolioUIState = exports.fetchCompanyPortfolioView = exports.fetchCompanyManagementView = exports.fetchAllCockpitViews = exports.companyManagementSaveUpdates = exports.getParentSubsidiaryManagementView = exports.getAddonListZeniSku = exports.getPlanListZeniSku = exports.getCompanyManagementView = exports.getControllersName = exports.getFirstControllerId = exports.getFirstControllerEmail = exports.getCompanyInfoForAllCockpitCompaniesInState = exports.getControllersForCompany = exports.getCompanyByCompanyId = exports.ALL_ACCOUNTING_CONNECTION_CREATION_MODES = exports.getEntityByEntityIDs = exports.clearAllEntities = exports.updateEntities = exports.getEntityAutoCompleteResults = exports.fetchEntityAutoCompleteResults = exports.clearEntityAutoCompleteResults = exports.fetchEntityAutoCompleteEpic = exports.toEntityType = exports.VendorExpenseTrend = exports.CustomerIncomeTrend = exports.getTrendForEntity = exports.clearTrendData = exports.fetchExpenseTrend = exports.fetchIncomeTrend = exports.getEntityDetailUIStateByEntity = exports.getLatestTimeFrameWithTransactionsForEntity = exports.getTrendWithTransactions = exports.trendWithTransactionsUpdateSelectedTimeperiod = exports.clearTrendWithTransactions = exports.fetchTransactionsForEntity = exports.fetchTrendForEntity = exports.updateReportUIOptionCOABalancesRange = exports.updateReportUIOptionThisPeriod = exports.toggleReportUIOptionForecastMode = exports.updateReportUIOptionIsCompareModeOn = exports.updateReportUIOptionCompareMode = exports.updateReportUIOptionIsForecastVsActualOn = exports.updateReportUIOptionSelectedForecast = void 0;
38
- exports.saveCompanyPassportDetails = exports.updateCompanyPassportLocalStoreData = exports.companyPassportClearDataInLocalStore = exports.deleteCompanyOfficerInLocalStore = exports.saveIndustryAndIncDateInCompanyPassportLocalStore = exports.companyPassportSaveDataInLocalStore = exports.isCompanyPassportDataToBeSaved = exports.getCompanyPassportLocalStoreData = exports.getCompanyPassportView = exports.fetchCompanyPassportView = exports.isAllowedValueWithID = exports.isAllowedValueWithCode = exports.toCockpitTabsFileTypeStrict = exports.toCockpitTabsIDStrict = exports.ALL_COCKPIT_TABS_IDS = exports.ALL_COCKPIT_TABS_FILE_TYPES = exports.toTaskManagerSortKeyType = exports.toHealthSortKeyType = exports.toPortfolioSortKeyType = exports.toOnboardingSortKeyType = exports.toManagementSortKeyType = exports.clearAddressView = exports.fetchAddress = exports.getFormattedAddress = exports.getAllNewAddresses = exports.getNewAddress = exports.getAddress = exports.newAddressInLocalStore = exports.getCompanyMonthEndReportHistoricData = exports.fetchCompanyMonthEndReportTemplates = exports.fetchCompanyMonthEndReportHistoricData = exports.fetchCompanyMonthEndReportHistoricDates = exports.getCompanyMonthEndReportSelectorView = exports.resetCompanyMonthEndReportFetchStatus = exports.saveCompanyMonthEndReport = exports.sendCompanyMonthEndReport = exports.fetchCompanyMonthEndReportView = exports.fetchImproveUsingZeniGPT = exports.getAllCockpitTabsFilterView = exports.isInfiniteRunway = exports.getCompanyPortfolioView = exports.getAuditWarningsCount = exports.retryBankAccountConnection = exports.toReviewColumnKeyType = exports.getReviewCompanyListCount = exports.getReviewCompanySelectorView = exports.updateReviewCompanyListUIState = exports.fetchReviewCompanyView = exports.updateCompanyDownloadState = exports.fetchZeniUsers = void 0;
39
- exports.getFileUpdateNameStatusById = exports.getDeleteFileListWithStatus = exports.getFileListWithStatus = exports.clearFileViewList = exports.deleteFileSuccess = exports.deleteFileFailure = exports.deleteFile = exports.deleteFileListSuccess = exports.deleteFileListFailure = exports.deleteFileList = exports.updateFilesMetadata = exports.updateFileNameSuccess = exports.updateFileNameFailure = exports.updateFileName = exports.fetchFile = exports.fetchFileListSuccess = exports.fetchFileListFailure = exports.fetchFileList = exports.toSupportedAttachmentFileType = exports.toSupportedAttachmentFileFormatType = exports.toSupportedFileTypeStrict = exports.removeAttachmentFiles = exports.updateAttachmentFiles = exports.updateFiles = exports.SUPPORTED_ATTACHMENT_FILE_TYPES = exports.getSubscriptionEstimationData = exports.getSubscriptionLocalStoreDataView = exports.getSubscriptionsDetailView = exports.clearSubscriptionLocalData = exports.clearSubscriptionUpdateViewDataByTenantId = exports.saveSubscriptionLocalData = exports.initializeSubscriptionLocalData = exports.clearSubscriptionView = exports.fetchSubscriptionUpdateEstimate = exports.fetchSubscriptionCreateEstimate = exports.saveSubscriptionNotesUpdates = exports.saveSubscriptionUpdates = exports.fetchSubscriptionDetails = exports.fetchSubscriptionCoupons = exports.fetchSubscriptionAddOns = exports.fetchSubscriptionPlans = exports.fetchSubscriptionList = exports.updateCompanySubscriptionUIState = exports.getCompanySubscriptionView = exports.toSubscriptionSortKeyType = exports.getBankAccount = exports.getNestedAccountListHierarchy = exports.getUncategorizedAccounts = exports.toCompanyPassportLocalData = exports.clearCompanyView = void 0;
40
- exports.toRemiTabTypeStrict = exports.toRemiTabType = exports.toRemiSubTabTypeStrict = exports.toRemiSubTabType = exports.deleteUserBankAccount = exports.createUserBankAccount = exports.resetCreateBankAccountDetails = exports.createInternationalBankAccount = exports.createBankAccount = exports.deleteBankAccount = exports.fetchBankCountryNameByIban = exports.fetchBankNameBySwift = exports.fetchBankNameByRouting = exports.fetchVendorDetailPageView = exports.fetchVendorDetails = exports.updateStatusForCreateBankAccountFlow = exports.clearBankAccountView = exports.updateInternationalBankAccountViewLocalStoreData = exports.updateBankAccountViewLocalStoreData = exports.initializeVendorAddress = exports.updateSelectedVendorForCreateFlow = exports.removeBankAccountsInVendorView = exports.saveVendor = exports.fetchVendor = exports.updateScrollYOffset = exports.fetchVendorsList = exports.vendorsTabResetVendorDetailLocalData = exports.vendorsTabUpdateVendorDetailLocalData = exports.vendorsTabSaveVendorSuccessOrFailure = exports.vendorsTabSaveVendor = exports.getVendorsTabDetailPageView = exports.toVendorDetailTabsType = exports.getVendorAllTransactionsDefaultTimePeriod = exports.resetVendorsTabVendorAllTransactionsTabData = exports.resetSelectedTabType = exports.updateVendorsTabVendorAllTransactionsTabData = exports.updateVendorSpendTrendFilterTabValue = exports.updateSelectedTabType = exports.fetchVendorsTabVendorDetailPageView = exports.getVendorDetailPageView = exports.getVendorView = exports.getAnalyticsDataOnVendorSave = exports.fetchTasksCard = exports.downloadFile = exports.getAttachmentFileIdByFileName = exports.mapAttachmentFileToAttachmentFilePayload = exports.mapAttachmentFilePayloadToFile = exports.mapFilePayloadToFile = exports.uploadFile = exports.getFileDeleteStatusById = void 0;
41
- exports.fetchEditBillDetailPage = exports.fetchBillDetail = exports.getBillTransactionDetailKey = exports.checkApproveRejectBtnShowForBill = exports.getBillDetailView = exports.getBillDownloadList = exports.getBillList = exports.cancelAndDeleteBill = exports.deleteBill = exports.updateApprovalStatusOnSuccess = exports.approveOrRejectBill = exports.saveBillDetail = exports.discardBillUpdatesInLocalStore = exports.saveBillUpdatesToLocalStore = exports.fetchVendorByNameAndParseInvoice = exports.updateBillDetailSaveBillCode = exports.updateSelectedBillId = exports.updateSubTab = exports.updateTab = exports.fetchBillListPerTab = exports.fetchBillList = exports.getClassList = exports.isBillConditionallyValid = exports.clearBillPayBulkActionView = exports.getBillsBulkOperationProgress = exports.incrementBulkActionProcessedCount = exports.autoReviewPendingApprovalBills = exports.submitDraftBillsBulkAction = exports.cancelOrDeleteBillsBulkAction = exports.approveOrRejectBillsBulkAction = exports.reviewDraftBillsBulkAction = exports.getBillsBulkReviewView = exports.clearAllBillsFromBulkActionList = exports.removeBillFromBulkActionList = exports.updateBillsBulkActionList = exports.updateBillListDownloadUIState = exports.updateRemiListDownloadUIState = exports.REIMBURSEMENT_FILTER_CATEGORIES_RESTRICTED = exports.REIMBURSEMENT_FILTER_CATEGORIES = exports.updateRemiListFilterResult = exports.updateBillListFilterResult = exports.updateRemiListSearchResult = exports.updateRemiListUIState = exports.updateRemiDetailSaveRemiCode = exports.updateRemiListSubTab = exports.updateRemiListTab = exports.fetchRemiListPerTab = exports.fetchRemiList = exports.getRemiDownloadList = exports.getRemiList = void 0;
42
- exports.getBillPaySetupViewDetails = exports.verifyOtp = exports.resendOtp = exports.sendOtp = exports.clearZeniAccountSetupView = exports.clearBillPaySetupView = exports.clearSetupViewDataInLocalStore = exports.saveIndustryAndIncDateInLocalStore = exports.saveCompnayOfficerAdditionalDocumentsInLocalStore = exports.saveCompnayOfficerPhoneInLocalStore = exports.saveSetupViewDataInLocalStore = exports.acceptBillPayUpdatedTerms = exports.acceptZeniAccountTerms = exports.acceptBillPayTerms = exports.updatePrimaryFundingAccount = exports.updateMappedCashAccount = exports.establishPlaidConnection = exports.updatePaymentAccountStatus = exports.updatePaymentAccountLoginStatus = exports.updatePaymentAccount = exports.updateBusinessVerificationDetails = exports.updateSetupViewLocalStoreData = exports.updateSelectedCompanyOfficer = exports.getPlaidLinkToken = exports.getPaymentAccounts = exports.enableSetup = exports.fetchZeniAccountSetupView = exports.fetchBillPaySetupView = exports.hideCreatedByFilter = exports.fetchVendorAndUpdateBillLocalData = exports.convertAmountToHomeCurrency = exports.toPaymentToOption = exports.updateVendorContact = exports.verifyUser = exports.fetchUserDetails = exports.updateBillListSearchResult = exports.updateBillUploadFetchState = exports.updateContactsInVendorDetailLocalData = exports.resetVendorDetailLocalData = exports.updateVendorDetailLocalData = exports.BILL_PAY_FILTER_CATEGORIES = exports.updateBillListUIState = exports.saveVendorSuccessOrFailure = exports.updateShowAutofill = exports.fetchBillAndInitializeLocalStore = exports.getReviewPageBillDetail = exports.getEditBillDetail = exports.clearBillPayReview = exports.fetchDuplicateBill = exports.fetchAndUpdateVendorRecommendations = void 0;
43
- exports.deleteRemi = exports.updateIsEditModeRealTimeApprovals = exports.saveRealTimeApproval = exports.checkApproveRejectBtnShowForRemi = exports.getRemiDetailView = exports.clearRemiSetupApproverView = exports.clearRemiSetupApproverViewUpdateData = exports.initializeRemiSetupApproverViewUpdateData = exports.saveRemiSetupApproverViewUpdates = exports.saveRemiSetupApproverViewUpdateData = exports.deleteRemiApprovalRule = exports.fetchRemiApproversDetails = exports.fetchRemiApproversList = exports.fetchRemiSetupApproverView = exports.getRemiSetupApproverUpdateDataView = exports.getRemiSetupApproverView = exports.clearBillPaySetupApproverView = exports.clearBillPaySetupApproverViewUpdateData = exports.initializeBillPaySetupApproverViewUpdateData = exports.saveBillPaySetupApproverViewUpdates = exports.saveBillPaySetupApproverViewUpdateData = exports.deleteBillPayApprovalRule = exports.fetchBillPayApproversList = exports.fetchBillPayApproversDetails = exports.fetchBillPaySetupApproverView = exports.getBillPaySetupApproverUpdateDataView = exports.getBillPaySetupApproverView = exports.toRoleTypeStrict = exports.toAttributeOrRoleTypeStrict = exports.toAttributeTypeStrict = exports.isSuccessResponse = exports.getRemiBusinessVerificationDetails = exports.getRemiSetupViewDetails = exports.clearRemiSetupView = exports.acceptEmployeeRemiTerms = exports.acceptRemiTerms = exports.saveRemiSetupViewDataInLocalStore = exports.updateMileageDetails = exports.fetchRemiSetupView = exports.getUserFinancialAccount = exports.fetchUserFinancialAccount = exports.getIntegrationsView = exports.getBankConnectionsSetupViewDetails = exports.getApprovalRuleViewDetails = exports.getCommonSetupViewDetails = exports.getZeniAccountBusinessVerificationDetails = exports.getBillPayBusinessVerificationDetails = exports.getBusinessVerificationDetails = exports.getZeniAccountSetupViewDetails = exports.getPlaidAccountDetails = void 0;
44
- exports.initializeOnboardingCustomerViewUpdateData = exports.getOnboardingEmailGroup = exports.getNewOnboardingCustomerView = exports.getOnboardingCockpitView = exports.toProductTypeStrict = exports.toProductType = exports.saveOnboardingCustomerCompletedStatus = exports.fetchOnboardingCompletedCompanies = exports.fetchCompanyOnboardingView = exports.PAYMENT_BUSINESS_DAYS = exports.holidaysFormatted = exports.isHoliday = exports.getYearsList = exports.filterDays = exports.isHolidayToday = exports.getPreviousNthWorkingDay = exports.getNextNthWorkingDay = exports.toFileTypeStrict = exports.ALL_FILE_TYPES = exports.isAllFetchCompleted = exports.isAnyFetchInProgress = exports.reduceAnyCompletedFetchState = exports.reduceAllFetchState = exports.reduceAnyFetchState = exports.reduceFetchState = exports.clearAddRemiAutoFields = exports.clearTentativeMerchantName = exports.updateTentativeMerchantNames = exports.updateUploadFetchState = exports.updateAddRemiAutoFields = exports.clearEditRemiViewDetail = exports.parseReceiptsToRemi = exports.saveRemiSuccessOrFailure = exports.saveRemiDetail = exports.removeFileFromRemiUpdatesInLocalStore = exports.discardRemiUpdatesInLocalStore = exports.fetchCurrencyConversionValue = exports.saveRemiUpdatesToLocalStore = exports.initializeRemiToLocalStore = exports.fetchRemiAndInitializeLocalStore = exports.fetchRecommendationsAndUpdateMerchantRecommendations = exports.fetchEditRemiDetailPage = exports.getEditRemiDetail = exports.removeDuplicateReimbursementByLineId = exports.clearDuplicateReimbursementDetail = exports.fetchDuplicateReimbursement = exports.clearRemiDetailView = exports.approveOrRejectRemi = exports.cancelAndDeleteRemi = exports.fetchRemiDetail = void 0;
45
- exports.fetchPaymentAccountList = exports.createCheckingAccount = exports.updateZeniAccountListTab = exports.fetchZeniAccountList = exports.getZeniAccountList = exports.getZeniAccountsConfigDetail = exports.fetchOwnerList = exports.fetchRecommendationByEntityName = exports.fetchRecommendationByEntityId = exports.fetchEntityRecommendationsByTransactionId = exports.toVendorReportIDType = exports.isVendorsTabVisible = exports.isColumnYTDSpend = exports.updateYTDSelectionUIState = exports.updatePageToken = exports.updateSortUiState = exports.getVendorList = exports.LOCAL_CURRENCY_INTERNATIONAL_METHOD_SUBTEXT = exports.SWIFT_OUR_INTERNATIONAL_METHOD_SUBTEXT = exports.NEW_INTERNATIONAL_METHOD_SUBTEXT = exports.BILL_NEW_PAYMENT_METHODS = exports.getInternationalSubConfigCodeKey = exports.shouldEnableCalendarPickerForLastReportSent = exports.canSendMonthEndEmailReport = exports.getBillListUniqueType = exports.isBillProcessing = exports.isVerifiedStatusCode = exports.getActualPaymentDate = exports.showReimbursementPromoPage = exports.showBillPayPromoPage = exports.getSelectedCompanyOfficer = exports.getSpendManagementEffectiveListPeriod = exports.getSnackbar = exports.closeSnackbar = exports.openSnackbar = exports.getChangedLineItemCountFromLocalData = exports.getTransactionListUIStateByCategoryType = exports.getTransactionsListByCategoryType = exports.retryBankAccountConnectionForOnboarding = exports.sendOnboardingCustomerViewInvite = exports.resetNewOnboardedCustomerId = exports.updateOnboardingCustomerDataInLocalStore = exports.saveOnboardingCustomerDataInLocalStore = exports.saveOnboardingCustomerNotes = exports.saveOnboardingCustomerViewUpdates = exports.updateStatusAfterOnboardingCompleted = exports.updateCustomerCreationStatus = exports.updateOnboardingCustomerListUIState = exports.saveOnboardingCustomerViewUpdateData = exports.clearOnboardingCustomerViewUpdateData = void 0;
46
- exports.updateOnboardingCustomerViewUIState = exports.updateCurrentStep = exports.updateOnboardingCustomerViewLocalStoreData = exports.updateOnboardingCustomerView = exports.updateOnboardingPaymentAccountStatus = exports.updateOnboardingPaymentAccountLoginStatus = exports.updateOnboardingCustomerViewCompleteStatus = exports.updateOnboardingCustomerViewAccountDetails = exports.establishOnboardingPlaidConnection = exports.getOnboardingPlaidLinkToken = exports.fetchOnboardingCustomerSetupView = exports.fetchOnboardingCustomerView = exports.isZeniClearingAccount = exports.ZENI_CLEARING_ACCOUNT = exports.isZeniClearingAccountReport = exports.getCompanyConfig = exports.fetchCompanyConfig = exports.clearTransactionVendorSaveStatus = exports.resetTransactionVendorLocalData = exports.updateTransactionVendorLocalData = exports.saveTransactionVendorSuccessOrFailure = exports.saveTransactionVendor = exports.getTransactionVendorView = exports.getZeniAccStatements = exports.fetchZeniAccStatementPage = exports.getDepositAccountTransactionList = exports.fetchDepositAccountTransactionList = exports.fetchDepositAccountHistoryFailure = exports.fetchDepositAccountHistorySuccess = exports.updateDepositAccount = exports.getCheckDepositDetail = exports.clearCheckDeposit = exports.updateCheckDepositLocalData = exports.depositCheck = exports.ZENI_ACCOUNTS_TAB = exports.fetchDepositAccountDetail = exports.fetchReviewTransferDetail = exports.clearReviewTransferDetail = exports.clearTransferDetail = exports.getTransferDetail = exports.transferMoney = exports.updateDepositToLocalData = exports.updateTransferToLocalData = exports.updateTransferMoneyLocalData = exports.fetchZeniAccountsConfig = exports.fetchDepositAccount = exports.getDepositAccountDetailForPDF = exports.getAllDepostAccounts = exports.getDepositAccountDetail = exports.unlinkPaymentAccount = void 0;
47
- exports.getChargeCardBusinessVerificationDetails = exports.companyHealthMetricDropDownOptions = exports.hasCompanyHealthMetricFormFieldChanged = exports.getCompanyHealthMetricView = exports.isCompanyRunwayInfinite = exports.updateCompanyHealthViewUIState = exports.updateCompanyHealthMetricViewSuccessStatus = exports.updateCompanyHealthMetricViewErrorStatus = exports.updateCompanyHealthMetricLocalStore = exports.saveCompanyHealthMetricById = exports.removeSelectedCompanyId = exports.initializeCompanyHealthMetricViewLocalData = exports.fetchCompanyHealthMetricView = exports.clearCompanyHealthMetricView = exports.updateCompanyHealth = exports.updateCompaniesHealth = exports.getUserRoleConfig = exports.fetchUserRoleConfig = exports.clearInternationalWire = exports.deletePaymentInstrument = exports.createPaymentInstrumentUpdateStatus = exports.createPaymentInstrument = exports.fetchInternationalWireDynamicForm = exports.initializeDynamicForm = exports.updateInternationalWireLocalStoreData = exports.initializeInternationalWireLocalData = exports.getInternationalWireView = exports.fetchWiseRedirectStatus = exports.getWiseRedirect = exports.saveMagicLinkAddressInLocalStore = exports.fetchMagicLinkBankNameBySwift = exports.fetchMagicLinkBankNameByRouting = exports.updateMagicLinkInternationalBankAccountLocalStoreData = exports.updateMagicLinkBankAccountLocalStoreData = exports.saveBankAccount = exports.fetchBillAttachment = exports.fetchMagicLinkTenant = exports.getMagicLinkCurrentAddressState = exports.getMagicLinkBankAccountView = exports.getMagicLinkView = exports.initializeAccountMappingView = exports.getAccountMappingView = exports.clearAccountMappingLocalData = exports.saveAccountMappingLocalData = exports.saveAccountMapping = exports.getOnboardingCustomerView = exports.clearOnboardingCustomerViewDataInLocalStore = exports.clearOnboardingCustomerView = exports.saveOnboardingCustomerViewDataInLocalStore = exports.saveOnboardingCompnayOfficerPhoneInLocalStore = void 0;
48
- exports.updatedSelectedJELinkRowIndex = exports.updateScheduleListDownloadState = exports.updateScheduleDetailsLocalData = exports.createNewSchedules = exports.deleteScheduleDetail = exports.saveScheduleDetails = exports.fetchScheduleDetailsPage = exports.getScheduleDetailsView = exports.fetchScheduleDetails = exports.updateSelectedJEScheduleKey = exports.updateScheduleListSortState = exports.updateScheduleListScrollState = exports.updateScheduleListSearchText = exports.updateScheduleListSubTab = exports.toScheduleSubTabType = exports.toScheduleListTabsFileTypeStrict = exports.toScheduleTypesTypeStrict = exports.toScheduleTypesType = exports.getFetchStateForScheduleAccountList = exports.updateScheduleListLocalData = exports.fetchSchedulesAccount = exports.fetchDownloadSchedules = exports.fetchScheduleList = exports.getScheduleListReport = exports.ALL_SCHEDULES_TYPES = exports.updateApAgingDetailUIState = exports.getApAgingDetailForVendor = exports.fetchApAgingDetail = exports.updateApAgingUIState = exports.getApAgingReport = exports.fetchApAging = exports.updateChargeCardDetail = exports.updateCashbackDetailUIState = exports.updateChargeCardListUIState = exports.updateChargeCardListSearchText = exports.resetIssueChargeCardForm = exports.updateChargeCardLocalStore = exports.issueChargeCard = exports.acceptChargeCardTerms = exports.fetchChargeCardSetupView = exports.getChargeCardSetupViewDetails = exports.toCreditLimitFrequencyCodeType = exports.getCashbackDetail = exports.toChargeCardSortKeyType = exports.fetchCashbackDetail = exports.fetchChargeCardTransactionList = exports.getChargeCardDetailView = exports.fetchChargeCardDetailPage = exports.getChargeCardListView = exports.fetchChargeCardListPage = void 0;
49
- exports.fetchTaskListPage = exports.getAllTasks = exports.toRecurringBillFrequencyStrict = exports.toRecurringBillFrequency = exports.updateArAgingNodeCollapseState = exports.getArAgingDetailForCustomer = exports.getArAgingReport = exports.updateArAgingDetailUIState = exports.fetchArAgingDetail = exports.updateArAgingUIState = exports.fetchArAging = exports.toVendorGlobalReviewColumnSortKeyType = exports.getTenantMerchantByMerchantId = exports.getVendorGlobalReviewView = exports.updateVendorGlobalReviewViewUIState = exports.updateSelectedGlobalMerchant = exports.fetchVendorGlobalReviewView = exports.rejectVendorGlobalReview = exports.approveVendorGlobalReview = exports.getGlobalMerchantView = exports.clearGlobalMerchantView = exports.updateCreateGlobalMerchantLocalData = exports.createGlobalMerchant = exports.fetchGlobalMerchantRecommendation = exports.clearGlobalMerchantAutoCompleteResults = exports.fetchGlobalMerchantAutoCompleteView = exports.updateVendorFirstReviewSortUiState = exports.updateVendorFirstReviewViewLocalData = exports.saveVendorFirstReviewView = exports.clearRecentlySavedErroredVendorData = exports.updateVendorFirstReviewViewPageToken = exports.resetVendorFirstReviewLocalData = exports.updateVendorFirstReviewViewScrollYOffset = exports.fetchVendorFirstReviewAttachments = exports.fetchVendorFirstReviewView = exports.getVendorFirstReviewAttachmentView = exports.getVendorFirstReviewView = exports.getGlobalMerchantAutoCompleteResults = exports.toVendorFirstReviewViewColumnKeyType = exports.fetchVendorTabView = exports.resetMarkAsCompleteStatus = exports.markAsCompleteScheduleDetail = exports.getDefaultSelectedTimeframeForScheduleType = exports.getFetchStateForScheduleListByType = exports.updatedJELinkWithRecommendedLocalData = exports.resetJELinkInLocalData = exports.updateAmountsInScheduleDetail = exports.updatedJELinkInLocalData = exports.getThirdPartyIDFromQBOURL = exports.getQBOUrlForLink = void 0;
50
- exports.getAuthenticationView = exports.fetchCollaborationAuthToken = exports.clearAuditReportGroupViewByCompanyId = exports.saveReasonForAuditRule = exports.fetchAuditReportGroupView = exports.fetchAuditRuleGroupView = exports.getUserFromAllUsers = exports.getAuditRuleGroupViewSelectorView = exports.getAuditReportGroupViewSelectorView = exports.clearCardPaymentView = exports.resetCardPaymentErrorStatuses = exports.fetchPaymentSources = exports.addCardPaymentSource = exports.confirmCardSetupIntent = exports.createCardSetupIntent = exports.getAllCardsAndBankPaymentMethods = exports.deleteTag = exports.createTag = exports.fetchTagList = exports.getAllTags = exports.toDueDateGroupKeyType = exports.toTaskStatusCodeType = exports.toPriorityCodeType = exports.getDueDateValueFromDueDateGroupId = exports.initialTaskDetail = exports.fetchAllTaskGroups = exports.getTaskUpdates = exports.toTaskListGroupByKeyTypeStrict = exports.toTaskListGroupByKeyType = exports.updateTaskGroupName = exports.dragNDropTasks = exports.updateTaskListLocalData = exports.deleteTaskGroup = exports.initiateTaskListLocalData = exports.createNewTaskGroup = exports.bulkUpdateTaskList = exports.discardTaskUpdatesInLocalStore = exports.deleteTask = exports.TASK_LIST_GROUP_BY_CATEGORIES = exports.TASK_LIST_FILTER_CATEGORIES = exports.updateTaskFilters = exports.allTaskPriority = exports.allTaskStatus = exports.updateTaskListUIState = exports.updateTaskListSearchText = exports.archiveTask = exports.saveTaskDetail = exports.saveTaskUpdatesToLocalStore = exports.fetchTaskDetailPage = exports.getTaskDetail = void 0;
51
- exports.getCompanyTaskManagerView = exports.fetchCompanyTaskManagerView = exports.getMinAllowedEndDate = exports.toRecurringFrequency = exports.getRecurringEndDateFromCount = exports.updateReferViewed = exports.getRewardsPlanCard = exports.fetchRewardsPlan = exports.resendReferralInvite = exports.updateReferralListSortUiState = exports.saveReferralFormDataInLocalStore = exports.clearReferrals = exports.sendReferralInvite = exports.fetchReferrals = exports.AmountStatusTypes = exports.StatusTypes = exports.toReferralListViewSortKeyType = exports.getInviteFormView = exports.getReferralListView = exports.getNotifications = exports.getLastNotificationTime = exports.pushToastNotification = exports.getNotificationsForSelectedSubTab = exports.getExternalNotificationsForSelectedSubTab = exports.getNotificationView = exports.updateNotificationViewUIState = exports.updateNotificationViewSubTab = exports.updateNotificationViewCurrentTabAndSubTab = exports.updateNotificationViewTabState = exports.updateNotificationViewNotificationStatus = exports.updateNotificationViewAllNotificationsStatus = exports.fetchNotificationUnreadCountSuccess = exports.fetchNotificationUnreadCount = exports.fetchNotificationView = exports.toNotificationTabTypeStrict = exports.toNotificationSubTabTypeStrict = exports.updateCommentsNotificationsStatuses = exports.updateCommentsNotifications = exports.toNotificationModeStrict = exports.fetchZeniAccountsPromoCard = exports.getZeniAccountsPromoCard = void 0;
34
+ exports.isAccountingTabVisible = exports.getMyBankConnectionsDetails = exports.getMyProfileView = exports.getBillingAccountsViewDetails = exports.getNotificationSettings = exports.getNotificationSettingsView = exports.isMonthEndNotificationsSectionVisibleOnSettingsPage = exports.updateSettingsViewUIState = exports.refreshQBOData = exports.resetNotificationSettingsUpdateStatus = exports.resetNotificationSettingsLocalData = exports.fetchNotificationSettingsView = exports.updateNotificationSettingsLocalData = exports.saveNotificationSettings = exports.fetchNotificationSettings = exports.fetchBillingAccountsView = exports.fetchBankConnectionsView = exports.fetchMyProfile = exports.fetchMyProfileView = exports.clearSettingsView = exports.NOTIFICATION_MODES = exports.REMINDER_NOTIFICATION_TYPES = exports.initializeEditPerson = exports.getPeopleLocalData = exports.getPeople = exports.peopleClearDataInLocalStore = exports.peopleSaveDataInLocalStore = exports.resetUpdateErrorMessage = exports.peopleSaveUpdates = exports.updatePeopleUIState = exports.inviteZeniPeople = exports.invitePeople = exports.changeZeniPersonRoles = exports.resendInvite = exports.deletePerson = exports.fetchPeople = exports.fetchPeoplePage = exports.fetchAllPeopleRequiredViews = exports.getUserList = exports.fetchUserListByType = exports.isPandLReportViewSectionID = exports.isPandLReportViewCalculatedSectionID = exports.getProfitAndLossClassesView = exports.updateProfitAndLossAccountViewMode = exports.updateProfitAndLossClassesViewUIState = exports.resetProfitAndLossClassesNodeCollapseState = exports.updateProfitAndLossClassesToFilterOut = exports.fetchProfitAndLossClassesView = exports.fetchProfitAndLossForTimeframe = exports.getPandLReportFetchState = void 0;
35
+ exports.updateVendors = exports.defaultVendorCurrency = exports.toTransactionCategory = exports.toTransactionTypeStrict = exports.toTransactionType = exports.toPlatformLineDetailType = exports.toTransactionID = exports.isCustomerTransaction = exports.defaultCustomerCurrency = exports.toAttachment = exports.mapFileEntityToAttachment = exports.toContentType = exports.toContentTypeStrict = exports.updateFinanceStatementFormat = exports.updateFinanceStatementDisplayOrder = exports.updateFinanceStatementAdditionalBalancesSelection = exports.updateDownloadState = exports.updateSelectedReportId = exports.updateCOABalancesRange = exports.fetchFinanceStatement = exports.getFinanceStatement = exports.fetchCashFlowForTimeframe = exports.isCashFlowReportViewCalculatedSectionType1ID = exports.isCashFlowReportViewSectionID = exports.isCashFlowReportViewCalculatedSectionID = exports.typeOfCashFlowRootSection = exports.updateCashFlowUIState = exports.resetCashFlowNodeCollapseState = exports.getCashFlowReportFetchState = exports.getCashFlow = exports.fetchCashFlow = exports.fetchBalanceSheetForTimeframe = exports.isBalanceSheetReportViewCalculatedSectionID = exports.isBalanceSheetReportViewSectionID = exports.typeOfBalanceSheetRootSection = exports.updateBalanceSheetUIState = exports.resetBalanceSheetNodeCollapseState = exports.getBalanceSheetForFullDataAvailableRange = exports.getBalanceSheetFetchState = exports.getBalanceSheet = exports.fetchBalanceSheet = exports.isRemindersSectionVisibleOnSettingsPage = exports.isNotificationsTabVisible = exports.isMyBankConnectionsTabVisible = exports.isSettingsVisible = exports.isIntegrationsTabVisible = exports.isCompanyDetailsTabVisible = exports.isBusinessVerificationTabVisible = exports.isBankConnectionsTabVisible = exports.isApprovalRulesTabVisible = void 0;
36
+ exports.updateSelectedInsightIndex = exports.fetchInsightsCard = exports.getInsights = exports.getUpdatablePeriodsForTransactionRecommendations = exports.getTransactionDetailForTransaction = exports.getTransactionDetail = exports.getTransactionListByEntityForSinglePeriod = exports.getTransactionListUIStateByClassKey = exports.getTransactionListByClass = exports.getTransactionListByEntity = exports.getThirdPartyIdFromTransactionId = exports.uploadMissingReceiptSuccess = exports.updateTransactionDetail = exports.fetchTransactionDetail = exports.setIsVendorUpdateAllChecked = exports.updateVendorBulkRecommendationsFetchStatus = exports.updateLatestSelectedEntity = exports.resetAllLineItemsToVendor = exports.updateVendorToAllLineItems = exports.updateLocalDataWithTransactionsUpdateWithVendorCheckbox = exports.resetVendor = exports.updateSelectedVendor = exports.removeEntityRecommendationForLineIdForTransactionDetail = exports.initializeTransactionDetailLocalData = exports.setAllLineItemsLocalDataIsUpdateAllChecked = exports.saveTransactionDetail = exports.setAllLineItemsToCategoryClassInLocalData = exports.resetLineItemsCategoryClassInLocalData = exports.updateTransactionListByEntityFailure = exports.clearTransactionDetailSaveStatus = exports.saveTransactionDetailLocalData = exports.updateTransactionListByEntity = exports.fetchEntityTransactionList = exports.getTransactionListUIStateByAccountKey = exports.getTransactionListByAccount = exports.parallelFetchTransactionListByCategoryType = exports.updateTransactionListUIStateByCategoryType = exports.updateTransactionListByClass = exports.updateTransactionListByClassUIState = exports.parallelFetchClassTransactionList = exports.updateTransactionListByAccountUIState = exports.updateTransactionListByAccountFailure = exports.updateTransactionListByAccount = exports.fetchAccountTransactionList = exports.parallelFetchEntityTransactionList = exports.parallelFetchAccountTransactionList = exports.updateLatestTransactionId = exports.clearTransactionList = exports.isTransferTransaction = exports.isVendorTransaction = void 0;
37
+ exports.fetchOnboardingView = exports.fetchParentSubsidiaryManagementView = exports.updateCompanyManagementUIState = exports.updateCompanyPortfolioUIState = exports.fetchCompanyPortfolioView = exports.fetchCompanyManagementView = exports.fetchAllCockpitViews = exports.companyManagementSaveUpdates = exports.getParentSubsidiaryManagementView = exports.getAddonListZeniSku = exports.getPlanListZeniSku = exports.getCompanyManagementView = exports.getControllersName = exports.getFirstControllerId = exports.getFirstControllerEmail = exports.getCompanyInfoForAllCockpitCompaniesInState = exports.getControllersForCompany = exports.getCompanyByCompanyId = exports.ALL_ACCOUNTING_CONNECTION_CREATION_MODES = exports.getEntityByEntityIDs = exports.clearAllEntities = exports.updateEntities = exports.getEntityAutoCompleteResults = exports.fetchEntityAutoCompleteResults = exports.clearEntityAutoCompleteResults = exports.fetchEntityAutoCompleteEpic = exports.toEntityType = exports.VendorExpenseTrend = exports.CustomerIncomeTrend = exports.getTrendForEntity = exports.clearTrendData = exports.fetchExpenseTrend = exports.fetchIncomeTrend = exports.getEntityDetailUIStateByEntity = exports.getLatestTimeFrameWithTransactionsForEntity = exports.getTrendWithTransactions = exports.trendWithTransactionsUpdateSelectedTimeperiod = exports.clearTrendWithTransactions = exports.fetchTransactionsForEntity = exports.fetchTrendForEntity = exports.updateReportUIOptionCOABalancesRange = exports.updateReportUIOptionThisPeriod = exports.toggleReportUIOptionForecastMode = exports.updateReportUIOptionIsCompareModeOn = exports.updateReportUIOptionCompareMode = exports.updateReportUIOptionIsForecastVsActualOn = exports.updateReportUIOptionSelectedForecast = exports.updateReportUIOptionTimeframe = exports.getForecastList = exports.fetchForecastList = void 0;
38
+ exports.deleteCompanyOfficerInLocalStore = exports.saveIndustryAndIncDateInCompanyPassportLocalStore = exports.companyPassportSaveDataInLocalStore = exports.isCompanyPassportDataToBeSaved = exports.getCompanyPassportLocalStoreData = exports.getCompanyPassportView = exports.fetchCompanyPassportView = exports.isAllowedValueWithID = exports.isAllowedValueWithCode = exports.toCockpitTabsFileTypeStrict = exports.toCockpitTabsIDStrict = exports.ALL_COCKPIT_TABS_IDS = exports.ALL_COCKPIT_TABS_FILE_TYPES = exports.toTaskManagerSortKeyType = exports.toHealthSortKeyType = exports.toPortfolioSortKeyType = exports.toOnboardingSortKeyType = exports.toManagementSortKeyType = exports.clearAddressView = exports.fetchAddress = exports.getFormattedAddress = exports.getAllNewAddresses = exports.getNewAddress = exports.getAddress = exports.newAddressInLocalStore = exports.getCompanyMonthEndReportHistoricData = exports.fetchCompanyMonthEndReportTemplates = exports.fetchCompanyMonthEndReportHistoricData = exports.fetchCompanyMonthEndReportHistoricDates = exports.getCompanyMonthEndReportSelectorView = exports.resetCompanyMonthEndReportFetchStatus = exports.saveCompanyMonthEndReport = exports.sendCompanyMonthEndReport = exports.fetchCompanyMonthEndReportView = exports.fetchImproveUsingZeniGPT = exports.getAllCockpitTabsFilterView = exports.isInfiniteRunway = exports.getCompanyPortfolioView = exports.getAuditWarningsCount = exports.retryBankAccountConnection = exports.toReviewColumnKeyType = exports.getReviewCompanyListCount = exports.getReviewCompanySelectorView = exports.updateReviewCompanyListUIState = exports.fetchReviewCompanyView = exports.updateCompanyDownloadState = exports.fetchZeniUsers = exports.fetchSubscriptionView = exports.fetchPortfolioView = exports.fetchManagementView = void 0;
39
+ exports.clearFileViewList = exports.deleteFileSuccess = exports.deleteFileFailure = exports.deleteFile = exports.deleteFileListSuccess = exports.deleteFileListFailure = exports.deleteFileList = exports.updateFilesMetadata = exports.updateFileNameSuccess = exports.updateFileNameFailure = exports.updateFileName = exports.fetchFile = exports.fetchFileListSuccess = exports.fetchFileListFailure = exports.fetchFileList = exports.toSupportedAttachmentFileType = exports.toSupportedAttachmentFileFormatType = exports.toSupportedFileTypeStrict = exports.removeAttachmentFiles = exports.updateAttachmentFiles = exports.updateFiles = exports.SUPPORTED_ATTACHMENT_FILE_TYPES = exports.getSubscriptionEstimationData = exports.getSubscriptionLocalStoreDataView = exports.getSubscriptionsDetailView = exports.clearSubscriptionLocalData = exports.clearSubscriptionUpdateViewDataByTenantId = exports.saveSubscriptionLocalData = exports.initializeSubscriptionLocalData = exports.clearSubscriptionView = exports.fetchSubscriptionUpdateEstimate = exports.fetchSubscriptionCreateEstimate = exports.saveSubscriptionNotesUpdates = exports.saveSubscriptionUpdates = exports.fetchSubscriptionDetails = exports.fetchSubscriptionCoupons = exports.fetchSubscriptionAddOns = exports.fetchSubscriptionPlans = exports.fetchSubscriptionList = exports.updateCompanySubscriptionUIState = exports.getCompanySubscriptionView = exports.toSubscriptionSortKeyType = exports.getBankAccount = exports.getNestedAccountListHierarchy = exports.getUncategorizedAccounts = exports.toCompanyPassportLocalData = exports.clearCompanyView = exports.saveCompanyPassportDetails = exports.updateCompanyPassportLocalStoreData = exports.companyPassportClearDataInLocalStore = void 0;
40
+ exports.toRemiSubTabType = exports.deleteUserBankAccount = exports.createUserBankAccount = exports.resetCreateBankAccountDetails = exports.createInternationalBankAccount = exports.createBankAccount = exports.deleteBankAccount = exports.fetchBankCountryNameByIban = exports.fetchBankNameBySwift = exports.fetchBankNameByRouting = exports.fetchVendorDetailPageView = exports.fetchVendorDetails = exports.updateStatusForCreateBankAccountFlow = exports.clearBankAccountView = exports.updateInternationalBankAccountViewLocalStoreData = exports.updateBankAccountViewLocalStoreData = exports.initializeVendorAddress = exports.updateSelectedVendorForCreateFlow = exports.removeBankAccountsInVendorView = exports.saveVendor = exports.fetchVendor = exports.updateScrollYOffset = exports.fetchVendorsList = exports.vendorsTabResetVendorDetailLocalData = exports.vendorsTabUpdateVendorDetailLocalData = exports.vendorsTabSaveVendorSuccessOrFailure = exports.vendorsTabSaveVendor = exports.getVendorsTabDetailPageView = exports.toVendorDetailTabsType = exports.getVendorAllTransactionsDefaultTimePeriod = exports.resetVendorsTabVendorAllTransactionsTabData = exports.resetSelectedTabType = exports.updateVendorsTabVendorAllTransactionsTabData = exports.updateVendorSpendTrendFilterTabValue = exports.updateSelectedTabType = exports.fetchVendorsTabVendorDetailPageView = exports.getVendorDetailPageView = exports.getVendorView = exports.getAnalyticsDataOnVendorSave = exports.fetchTasksCard = exports.downloadFile = exports.getAttachmentFileIdByFileName = exports.mapAttachmentFileToAttachmentFilePayload = exports.mapAttachmentFilePayloadToFile = exports.mapFilePayloadToFile = exports.uploadFile = exports.getFileDeleteStatusById = exports.getFileUpdateNameStatusById = exports.getDeleteFileListWithStatus = exports.getFileListWithStatus = void 0;
41
+ exports.checkApproveRejectBtnShowForBill = exports.getBillDetailView = exports.getBillDownloadList = exports.getBillList = exports.cancelAndDeleteBill = exports.deleteBill = exports.updateApprovalStatusOnSuccess = exports.approveOrRejectBill = exports.saveBillDetail = exports.discardBillUpdatesInLocalStore = exports.saveBillUpdatesToLocalStore = exports.fetchVendorByNameAndParseInvoice = exports.updateBillDetailSaveBillCode = exports.updateSelectedBillId = exports.updateSubTab = exports.updateTab = exports.fetchBillListPerTab = exports.fetchBillList = exports.getClassList = exports.isBillConditionallyValid = exports.clearBillPayBulkActionView = exports.getBillsBulkOperationProgress = exports.incrementBulkActionProcessedCount = exports.autoReviewPendingApprovalBills = exports.submitDraftBillsBulkAction = exports.cancelOrDeleteBillsBulkAction = exports.approveOrRejectBillsBulkAction = exports.reviewDraftBillsBulkAction = exports.getBillsBulkReviewView = exports.clearAllBillsFromBulkActionList = exports.removeBillFromBulkActionList = exports.updateBillsBulkActionList = exports.updateBillListDownloadUIState = exports.updateRemiListDownloadUIState = exports.REIMBURSEMENT_FILTER_CATEGORIES_RESTRICTED = exports.REIMBURSEMENT_FILTER_CATEGORIES = exports.updateRemiListFilterResult = exports.updateBillListFilterResult = exports.updateRemiListSearchResult = exports.updateRemiListUIState = exports.updateRemiDetailSaveRemiCode = exports.updateRemiListSubTab = exports.updateRemiListTab = exports.fetchRemiListPerTab = exports.fetchRemiList = exports.getRemiDownloadList = exports.getRemiList = exports.toRemiTabTypeStrict = exports.toRemiTabType = exports.toRemiSubTabTypeStrict = void 0;
42
+ exports.sendOtp = exports.clearZeniAccountSetupView = exports.clearBillPaySetupView = exports.clearSetupViewDataInLocalStore = exports.saveIndustryAndIncDateInLocalStore = exports.saveCompnayOfficerAdditionalDocumentsInLocalStore = exports.saveCompnayOfficerPhoneInLocalStore = exports.saveSetupViewDataInLocalStore = exports.acceptBillPayUpdatedTerms = exports.acceptZeniAccountTerms = exports.acceptBillPayTerms = exports.updatePrimaryFundingAccount = exports.updateMappedCashAccount = exports.establishPlaidConnection = exports.updatePaymentAccountStatus = exports.updatePaymentAccountLoginStatus = exports.updatePaymentAccount = exports.updateBusinessVerificationDetails = exports.updateSetupViewLocalStoreData = exports.updateSelectedCompanyOfficer = exports.getPlaidLinkToken = exports.getPaymentAccounts = exports.enableSetup = exports.fetchZeniAccountSetupView = exports.fetchBillPaySetupView = exports.hideCreatedByFilter = exports.fetchVendorAndUpdateBillLocalData = exports.convertAmountToHomeCurrency = exports.toPaymentToOption = exports.updateVendorContact = exports.verifyUser = exports.fetchUserDetails = exports.updateBillListSearchResult = exports.updateBillUploadFetchState = exports.updateContactsInVendorDetailLocalData = exports.resetVendorDetailLocalData = exports.updateVendorDetailLocalData = exports.BILL_PAY_FILTER_CATEGORIES = exports.updateBillListUIState = exports.saveVendorSuccessOrFailure = exports.updateShowAutofill = exports.fetchBillAndInitializeLocalStore = exports.getReviewPageBillDetail = exports.getEditBillDetail = exports.clearBillPayReview = exports.fetchDuplicateBill = exports.fetchAndUpdateVendorRecommendations = exports.fetchEditBillDetailPage = exports.fetchBillDetail = exports.getBillTransactionDetailKey = void 0;
43
+ exports.checkApproveRejectBtnShowForRemi = exports.getRemiDetailView = exports.clearRemiSetupApproverView = exports.clearRemiSetupApproverViewUpdateData = exports.initializeRemiSetupApproverViewUpdateData = exports.saveRemiSetupApproverViewUpdates = exports.saveRemiSetupApproverViewUpdateData = exports.deleteRemiApprovalRule = exports.fetchRemiApproversDetails = exports.fetchRemiApproversList = exports.fetchRemiSetupApproverView = exports.getRemiSetupApproverUpdateDataView = exports.getRemiSetupApproverView = exports.clearBillPaySetupApproverView = exports.clearBillPaySetupApproverViewUpdateData = exports.initializeBillPaySetupApproverViewUpdateData = exports.saveBillPaySetupApproverViewUpdates = exports.saveBillPaySetupApproverViewUpdateData = exports.deleteBillPayApprovalRule = exports.fetchBillPayApproversList = exports.fetchBillPayApproversDetails = exports.fetchBillPaySetupApproverView = exports.getBillPaySetupApproverUpdateDataView = exports.getBillPaySetupApproverView = exports.toRoleTypeStrict = exports.toAttributeOrRoleTypeStrict = exports.toAttributeTypeStrict = exports.isSuccessResponse = exports.getRemiBusinessVerificationDetails = exports.getRemiSetupViewDetails = exports.clearRemiSetupView = exports.acceptEmployeeRemiTerms = exports.acceptRemiTerms = exports.saveRemiSetupViewDataInLocalStore = exports.updateMileageDetails = exports.fetchRemiSetupView = exports.getUserFinancialAccount = exports.fetchUserFinancialAccount = exports.getIntegrationsView = exports.getBankConnectionsSetupViewDetails = exports.getApprovalRuleViewDetails = exports.getCommonSetupViewDetails = exports.getZeniAccountBusinessVerificationDetails = exports.getBillPayBusinessVerificationDetails = exports.getBusinessVerificationDetails = exports.getZeniAccountSetupViewDetails = exports.getPlaidAccountDetails = exports.getBillPaySetupViewDetails = exports.verifyOtp = exports.resendOtp = void 0;
44
+ exports.getOnboardingCockpitView = exports.toProductTypeStrict = exports.toProductType = exports.saveOnboardingCustomerCompletedStatus = exports.fetchOnboardingCompletedCompanies = exports.fetchCompanyOnboardingView = exports.PAYMENT_BUSINESS_DAYS = exports.holidaysFormatted = exports.isHoliday = exports.getYearsList = exports.filterDays = exports.isHolidayToday = exports.getPreviousNthWorkingDay = exports.getNextNthWorkingDay = exports.toFileTypeStrict = exports.ALL_FILE_TYPES = exports.isAllFetchCompleted = exports.isAnyFetchInProgress = exports.reduceAnyCompletedFetchState = exports.reduceAllFetchState = exports.reduceAnyFetchState = exports.reduceFetchState = exports.clearAddRemiAutoFields = exports.clearTentativeMerchantName = exports.updateTentativeMerchantNames = exports.updateUploadFetchState = exports.updateAddRemiAutoFields = exports.clearEditRemiViewDetail = exports.parseReceiptsToRemi = exports.saveRemiSuccessOrFailure = exports.saveRemiDetail = exports.removeFileFromRemiUpdatesInLocalStore = exports.discardRemiUpdatesInLocalStore = exports.fetchCurrencyConversionValue = exports.saveRemiUpdatesToLocalStore = exports.initializeRemiToLocalStore = exports.fetchRemiAndInitializeLocalStore = exports.fetchRecommendationsAndUpdateMerchantRecommendations = exports.fetchEditRemiDetailPage = exports.getEditRemiDetail = exports.removeDuplicateReimbursementByLineId = exports.clearDuplicateReimbursementDetail = exports.fetchDuplicateReimbursement = exports.clearRemiDetailView = exports.approveOrRejectRemi = exports.cancelAndDeleteRemi = exports.fetchRemiDetail = exports.deleteRemi = exports.updateIsEditModeRealTimeApprovals = exports.saveRealTimeApproval = void 0;
45
+ exports.fetchZeniAccountList = exports.getZeniAccountList = exports.getZeniAccountsConfigDetail = exports.fetchOwnerList = exports.fetchRecommendationByEntityName = exports.fetchRecommendationByEntityId = exports.fetchEntityRecommendationsByTransactionId = exports.toVendorReportIDType = exports.isVendorsTabVisible = exports.isColumnYTDSpend = exports.updateYTDSelectionUIState = exports.updatePageToken = exports.updateSortUiState = exports.getVendorList = exports.LOCAL_CURRENCY_INTERNATIONAL_METHOD_SUBTEXT = exports.SWIFT_OUR_INTERNATIONAL_METHOD_SUBTEXT = exports.NEW_INTERNATIONAL_METHOD_SUBTEXT = exports.BILL_NEW_PAYMENT_METHODS = exports.getInternationalSubConfigCodeKey = exports.shouldEnableCalendarPickerForLastReportSent = exports.canSendMonthEndEmailReport = exports.getBillListUniqueType = exports.isBillProcessing = exports.isVerifiedStatusCode = exports.getActualPaymentDate = exports.showReimbursementPromoPage = exports.showBillPayPromoPage = exports.getSelectedCompanyOfficer = exports.getSpendManagementEffectiveListPeriod = exports.getSnackbar = exports.closeSnackbar = exports.openSnackbar = exports.getChangedLineItemCountFromLocalData = exports.getTransactionListUIStateByCategoryType = exports.getTransactionsListByCategoryType = exports.retryBankAccountConnectionForOnboarding = exports.sendOnboardingCustomerViewInvite = exports.resetNewOnboardedCustomerId = exports.updateOnboardingCustomerDataInLocalStore = exports.saveOnboardingCustomerDataInLocalStore = exports.saveOnboardingCustomerNotes = exports.saveOnboardingCustomerViewUpdates = exports.updateStatusAfterOnboardingCompleted = exports.updateCustomerCreationStatus = exports.updateOnboardingCustomerListUIState = exports.saveOnboardingCustomerViewUpdateData = exports.clearOnboardingCustomerViewUpdateData = exports.initializeOnboardingCustomerViewUpdateData = exports.getOnboardingEmailGroup = exports.getNewOnboardingCustomerView = void 0;
46
+ exports.updateOnboardingCustomerView = exports.updateOnboardingPaymentAccountStatus = exports.updateOnboardingPaymentAccountLoginStatus = exports.updateOnboardingCustomerViewCompleteStatus = exports.updateOnboardingCustomerViewAccountDetails = exports.establishOnboardingPlaidConnection = exports.getOnboardingPlaidLinkToken = exports.fetchOnboardingCustomerSetupView = exports.fetchOnboardingCustomerView = exports.isZeniClearingAccount = exports.ZENI_CLEARING_ACCOUNT = exports.isZeniClearingAccountReport = exports.getCompanyConfig = exports.fetchCompanyConfig = exports.clearTransactionVendorSaveStatus = exports.resetTransactionVendorLocalData = exports.updateTransactionVendorLocalData = exports.saveTransactionVendorSuccessOrFailure = exports.saveTransactionVendor = exports.getTransactionVendorView = exports.getZeniAccStatements = exports.fetchZeniAccStatementPage = exports.getDepositAccountTransactionList = exports.fetchDepositAccountTransactionList = exports.fetchDepositAccountHistoryFailure = exports.fetchDepositAccountHistorySuccess = exports.updateDepositAccount = exports.getCheckDepositDetail = exports.clearCheckDeposit = exports.updateCheckDepositLocalData = exports.depositCheck = exports.ZENI_ACCOUNTS_TAB = exports.fetchDepositAccountDetail = exports.fetchReviewTransferDetail = exports.clearReviewTransferDetail = exports.clearTransferDetail = exports.getTransferDetail = exports.transferMoney = exports.updateDepositToLocalData = exports.updateTransferToLocalData = exports.updateTransferMoneyLocalData = exports.fetchZeniAccountsConfig = exports.fetchDepositAccount = exports.getDepositAccountDetailForPDF = exports.getAllDepostAccounts = exports.getDepositAccountDetail = exports.unlinkPaymentAccount = exports.fetchPaymentAccountList = exports.createCheckingAccount = exports.updateZeniAccountListTab = void 0;
47
+ exports.getCompanyHealthMetricView = exports.isCompanyRunwayInfinite = exports.updateCompanyHealthViewUIState = exports.updateCompanyHealthMetricViewSuccessStatus = exports.updateCompanyHealthMetricViewErrorStatus = exports.updateCompanyHealthMetricLocalStore = exports.saveCompanyHealthMetricById = exports.removeSelectedCompanyId = exports.initializeCompanyHealthMetricViewLocalData = exports.fetchCompanyHealthMetricView = exports.clearCompanyHealthMetricView = exports.updateCompanyHealth = exports.updateCompaniesHealth = exports.getUserRoleConfig = exports.fetchUserRoleConfig = exports.clearInternationalWire = exports.deletePaymentInstrument = exports.createPaymentInstrumentUpdateStatus = exports.createPaymentInstrument = exports.fetchInternationalWireDynamicForm = exports.initializeDynamicForm = exports.updateInternationalWireLocalStoreData = exports.initializeInternationalWireLocalData = exports.getInternationalWireView = exports.fetchWiseRedirectStatus = exports.getWiseRedirect = exports.saveMagicLinkAddressInLocalStore = exports.fetchMagicLinkBankNameBySwift = exports.fetchMagicLinkBankNameByRouting = exports.updateMagicLinkInternationalBankAccountLocalStoreData = exports.updateMagicLinkBankAccountLocalStoreData = exports.saveBankAccount = exports.fetchBillAttachment = exports.fetchMagicLinkTenant = exports.getMagicLinkCurrentAddressState = exports.getMagicLinkBankAccountView = exports.getMagicLinkView = exports.initializeAccountMappingView = exports.getAccountMappingView = exports.clearAccountMappingLocalData = exports.saveAccountMappingLocalData = exports.saveAccountMapping = exports.getOnboardingCustomerView = exports.clearOnboardingCustomerViewDataInLocalStore = exports.clearOnboardingCustomerView = exports.saveOnboardingCustomerViewDataInLocalStore = exports.saveOnboardingCompnayOfficerPhoneInLocalStore = exports.updateOnboardingCustomerViewUIState = exports.updateCurrentStep = exports.updateOnboardingCustomerViewLocalStoreData = void 0;
48
+ exports.createNewSchedules = exports.deleteScheduleDetail = exports.saveScheduleDetails = exports.fetchScheduleDetailsPage = exports.getScheduleDetailsView = exports.fetchScheduleDetails = exports.updateSelectedJEScheduleKey = exports.updateScheduleListSortState = exports.updateScheduleListScrollState = exports.updateScheduleListSearchText = exports.updateScheduleListSubTab = exports.toScheduleSubTabType = exports.toScheduleListTabsFileTypeStrict = exports.toScheduleTypesTypeStrict = exports.toScheduleTypesType = exports.getFetchStateForScheduleAccountList = exports.updateScheduleListLocalData = exports.fetchSchedulesAccount = exports.fetchDownloadSchedules = exports.fetchScheduleList = exports.getScheduleListReport = exports.ALL_SCHEDULES_TYPES = exports.updateApAgingDetailUIState = exports.getApAgingDetailForVendor = exports.fetchApAgingDetail = exports.updateApAgingUIState = exports.getApAgingReport = exports.fetchApAging = exports.updateChargeCardDetail = exports.updateCashbackDetailUIState = exports.updateChargeCardListUIState = exports.updateChargeCardListSearchText = exports.resetIssueChargeCardForm = exports.updateChargeCardLocalStore = exports.issueChargeCard = exports.acceptChargeCardTerms = exports.fetchChargeCardSetupView = exports.getChargeCardSetupViewDetails = exports.toCreditLimitFrequencyCodeType = exports.getCashbackDetail = exports.toChargeCardSortKeyType = exports.fetchCashbackDetail = exports.fetchChargeCardTransactionList = exports.getChargeCardDetailView = exports.fetchChargeCardDetailPage = exports.getChargeCardListView = exports.fetchChargeCardListPage = exports.getChargeCardBusinessVerificationDetails = exports.companyHealthMetricDropDownOptions = exports.hasCompanyHealthMetricFormFieldChanged = void 0;
49
+ exports.toRecurringBillFrequency = exports.updateArAgingNodeCollapseState = exports.getArAgingDetailForCustomer = exports.getArAgingReport = exports.updateArAgingDetailUIState = exports.fetchArAgingDetail = exports.updateArAgingUIState = exports.fetchArAging = exports.toVendorGlobalReviewColumnSortKeyType = exports.getTenantMerchantByMerchantId = exports.getVendorGlobalReviewView = exports.updateVendorGlobalReviewViewUIState = exports.updateSelectedGlobalMerchant = exports.fetchVendorGlobalReviewView = exports.rejectVendorGlobalReview = exports.approveVendorGlobalReview = exports.getGlobalMerchantView = exports.clearGlobalMerchantView = exports.updateCreateGlobalMerchantLocalData = exports.createGlobalMerchant = exports.fetchGlobalMerchantRecommendation = exports.clearGlobalMerchantAutoCompleteResults = exports.fetchGlobalMerchantAutoCompleteView = exports.updateVendorFirstReviewSortUiState = exports.updateVendorFirstReviewViewLocalData = exports.saveVendorFirstReviewView = exports.clearRecentlySavedErroredVendorData = exports.updateVendorFirstReviewViewPageToken = exports.resetVendorFirstReviewLocalData = exports.updateVendorFirstReviewViewScrollYOffset = exports.fetchVendorFirstReviewAttachments = exports.fetchVendorFirstReviewView = exports.getVendorFirstReviewAttachmentView = exports.getVendorFirstReviewView = exports.getGlobalMerchantAutoCompleteResults = exports.toVendorFirstReviewViewColumnKeyType = exports.fetchVendorTabView = exports.resetMarkAsCompleteStatus = exports.markAsCompleteScheduleDetail = exports.getDefaultSelectedTimeframeForScheduleType = exports.getFetchStateForScheduleListByType = exports.updatedJELinkWithRecommendedLocalData = exports.resetJELinkInLocalData = exports.updateAmountsInScheduleDetail = exports.updatedJELinkInLocalData = exports.getThirdPartyIDFromQBOURL = exports.getQBOUrlForLink = exports.updatedSelectedJELinkRowIndex = exports.updateScheduleListDownloadState = exports.updateScheduleDetailsLocalData = void 0;
50
+ exports.saveReasonForAuditRule = exports.fetchAuditReportGroupView = exports.fetchAuditRuleGroupView = exports.getUserFromAllUsers = exports.getAuditRuleGroupViewSelectorView = exports.getAuditReportGroupViewSelectorView = exports.clearCardPaymentView = exports.resetCardPaymentErrorStatuses = exports.fetchPaymentSources = exports.addCardPaymentSource = exports.confirmCardSetupIntent = exports.createCardSetupIntent = exports.getAllCardsAndBankPaymentMethods = exports.deleteTag = exports.createTag = exports.fetchTagList = exports.getAllTags = exports.toDueDateGroupKeyType = exports.toTaskStatusCodeType = exports.toPriorityCodeType = exports.getDueDateValueFromDueDateGroupId = exports.initialTaskDetail = exports.fetchAllTaskGroups = exports.getTaskUpdates = exports.toTaskListGroupByKeyTypeStrict = exports.toTaskListGroupByKeyType = exports.updateTaskGroupName = exports.dragNDropTasks = exports.updateTaskListLocalData = exports.deleteTaskGroup = exports.initiateTaskListLocalData = exports.createNewTaskGroup = exports.bulkUpdateTaskList = exports.discardTaskUpdatesInLocalStore = exports.deleteTask = exports.TASK_LIST_GROUP_BY_CATEGORIES = exports.TASK_LIST_FILTER_CATEGORIES = exports.updateTaskFilters = exports.allTaskPriority = exports.allTaskStatus = exports.updateTaskListUIState = exports.updateTaskListSearchText = exports.archiveTask = exports.saveTaskDetail = exports.saveTaskUpdatesToLocalStore = exports.fetchTaskDetailPage = exports.getTaskDetail = exports.fetchTaskListPage = exports.getAllTasks = exports.toRecurringBillFrequencyStrict = void 0;
51
+ exports.getCompanyTaskManagerView = exports.fetchCompanyTaskManagerView = exports.getMinAllowedEndDate = exports.toRecurringFrequency = exports.getRecurringEndDateFromCount = exports.updateReferViewed = exports.getRewardsPlanCard = exports.fetchRewardsPlan = exports.resendReferralInvite = exports.updateReferralListSortUiState = exports.saveReferralFormDataInLocalStore = exports.clearReferrals = exports.sendReferralInvite = exports.fetchReferrals = exports.AmountStatusTypes = exports.StatusTypes = exports.toReferralListViewSortKeyType = exports.getInviteFormView = exports.getReferralListView = exports.getNotifications = exports.getLastNotificationTime = exports.pushToastNotification = exports.getNotificationsForSelectedSubTab = exports.getExternalNotificationsForSelectedSubTab = exports.getNotificationView = exports.updateNotificationViewUIState = exports.updateNotificationViewSubTab = exports.updateNotificationViewCurrentTabAndSubTab = exports.updateNotificationViewTabState = exports.updateNotificationViewNotificationStatus = exports.updateNotificationViewAllNotificationsStatus = exports.fetchNotificationUnreadCountSuccess = exports.fetchNotificationUnreadCount = exports.fetchNotificationView = exports.toNotificationTabTypeStrict = exports.toNotificationSubTabTypeStrict = exports.updateCommentsNotificationsStatuses = exports.updateCommentsNotifications = exports.toNotificationModeStrict = exports.fetchZeniAccountsPromoCard = exports.getZeniAccountsPromoCard = exports.getAuthenticationView = exports.fetchCollaborationAuthToken = exports.clearAuditReportGroupViewByCompanyId = void 0;
52
52
  const zeniDayJS_1 = require("./zeniDayJS");
53
53
  Object.defineProperty(exports, "Dayjs", { enumerable: true, get: function () { return zeniDayJS_1.Dayjs; } });
54
54
  Object.defineProperty(exports, "updateZeniDateLocaleID", { enumerable: true, get: function () { return zeniDayJS_1.updateZeniDateLocaleID; } });
@@ -370,6 +370,7 @@ const profitAndLossReducer_1 = require("./view/profitAndLoss/profitAndLossReduce
370
370
  Object.defineProperty(exports, "fetchProfitAndLoss", { enumerable: true, get: function () { return profitAndLossReducer_1.fetchProfitAndLoss; } });
371
371
  Object.defineProperty(exports, "updateProfitAndLossUIState", { enumerable: true, get: function () { return profitAndLossReducer_1.updateProfitAndLossUIState; } });
372
372
  Object.defineProperty(exports, "resetProfitAndLossNodeCollapseState", { enumerable: true, get: function () { return profitAndLossReducer_1.resetProfitAndLossNodeCollapseState; } });
373
+ Object.defineProperty(exports, "fetchProfitAndLossForTimeframe", { enumerable: true, get: function () { return profitAndLossReducer_1.fetchProfitAndLossForTimeframe; } });
373
374
  const profitAndLossSelector_1 = require("./view/profitAndLoss/profitAndLossSelector");
374
375
  Object.defineProperty(exports, "getProfitAndLossReport", { enumerable: true, get: function () { return profitAndLossSelector_1.getProfitAndLossReport; } });
375
376
  Object.defineProperty(exports, "getPandLReportFetchState", { enumerable: true, get: function () { return profitAndLossSelector_1.getPandLReportFetchState; } });
@@ -448,6 +449,7 @@ const balanceSheetReducer_1 = require("./view/balanceSheet/balanceSheetReducer")
448
449
  Object.defineProperty(exports, "fetchBalanceSheet", { enumerable: true, get: function () { return balanceSheetReducer_1.fetchBalanceSheet; } });
449
450
  Object.defineProperty(exports, "resetBalanceSheetNodeCollapseState", { enumerable: true, get: function () { return balanceSheetReducer_1.resetBalanceSheetNodeCollapseState; } });
450
451
  Object.defineProperty(exports, "updateBalanceSheetUIState", { enumerable: true, get: function () { return balanceSheetReducer_1.updateBalanceSheetUIState; } });
452
+ Object.defineProperty(exports, "fetchBalanceSheetForTimeframe", { enumerable: true, get: function () { return balanceSheetReducer_1.fetchBalanceSheetForTimeframe; } });
451
453
  const balanceSheetSelector_1 = require("./view/balanceSheet/balanceSheetSelector");
452
454
  Object.defineProperty(exports, "getBalanceSheet", { enumerable: true, get: function () { return balanceSheetSelector_1.getBalanceSheet; } });
453
455
  Object.defineProperty(exports, "getBalanceSheetForFullDataAvailableRange", { enumerable: true, get: function () { return balanceSheetSelector_1.getBalanceSheetForFullDataAvailableRange; } });
@@ -460,6 +462,7 @@ const cashFlowReducer_1 = require("./view/cashFlow/cashFlowReducer");
460
462
  Object.defineProperty(exports, "fetchCashFlow", { enumerable: true, get: function () { return cashFlowReducer_1.fetchCashFlow; } });
461
463
  Object.defineProperty(exports, "resetCashFlowNodeCollapseState", { enumerable: true, get: function () { return cashFlowReducer_1.resetCashFlowNodeCollapseState; } });
462
464
  Object.defineProperty(exports, "updateCashFlowUIState", { enumerable: true, get: function () { return cashFlowReducer_1.updateCashFlowUIState; } });
465
+ Object.defineProperty(exports, "fetchCashFlowForTimeframe", { enumerable: true, get: function () { return cashFlowReducer_1.fetchCashFlowForTimeframe; } });
463
466
  const cashFlowSelectorTypes_1 = require("./view/cashFlow/cashFlowSelectorTypes");
464
467
  Object.defineProperty(exports, "typeOfCashFlowRootSection", { enumerable: true, get: function () { return cashFlowSelectorTypes_1.typeOfCashFlowRootSection; } });
465
468
  const cashFlowPayload_1 = require("./view/cashFlow/cashFlowPayload");
@@ -6,6 +6,7 @@ import { BalanceSheetState } from './balanceSheetState';
6
6
  import { AccountState } from '../../entity/account/accountState';
7
7
  import { AccountGroupState } from '../../entity/accountGroup/accountGroupState';
8
8
  import { SectionAccountsViewState } from '../../entity/sectionAccountsView/sectionAccountsViewState';
9
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
9
10
  export declare const getBalanceSheet: (filter: COABalancesFilter, accountState: AccountState, accountGroupState: AccountGroupState, sectionAccountsViewState: SectionAccountsViewState, balanceSheetState: BalanceSheetState) => BalanceSheetReport;
10
11
  /**
11
12
  * Get FULL balance sheet report for given data available range,
@@ -14,4 +15,8 @@ export declare const getBalanceSheet: (filter: COABalancesFilter, accountState:
14
15
  * @param state
15
16
  */
16
17
  export declare function getBalanceSheetForFullDataAvailableRange(timeframe: 'month' | 'quarter' | 'year', state: RootState): BalanceSheetReport;
17
- export declare const getBalanceSheetFetchState: (balanceSheetState: BalanceSheetState) => FetchStateAndError;
18
+ export declare const getBalanceSheetFetchState: (balanceSheetState: BalanceSheetState) => {
19
+ reducedAnyFetchState: FetchStateAndError;
20
+ reducedAllFetchState: FetchStateAndError;
21
+ fetchStateByTimeframe: FetchStateByTimeframe;
22
+ };
@@ -9,11 +9,15 @@ const sectionAccountsViewSelector_1 = require("../../entity/sectionAccountsView/
9
9
  const balanceSheetSelectorTypes_1 = require("./balanceSheetSelectorTypes");
10
10
  const balanceSheetForTimeframeEpic_1 = require("./balanceSheetForTimeframeEpic");
11
11
  const getBalanceSheet = (filter, accountState, accountGroupState, sectionAccountsViewState, balanceSheetState) => {
12
- const fetchState = (0, exports.getBalanceSheetFetchState)(balanceSheetState);
13
12
  const reportId = (0, balanceSheetForTimeframeEpic_1.reportIdUniqueKey)();
14
13
  const sections = {};
15
14
  const calculatedSections = {};
16
- if (fetchState.fetchState === 'Completed') {
15
+ if (filter.timeframe === 'week' || filter.timeframe === 'free_range') {
16
+ throw Error('free_range or week period is invalid');
17
+ }
18
+ const { reducedAllFetchState, reducedAnyFetchState, fetchStateByTimeframe } = (0, exports.getBalanceSheetFetchState)(balanceSheetState);
19
+ const selectedTimeframeFetchState = fetchStateByTimeframe[filter.timeframe];
20
+ if (selectedTimeframeFetchState.fetchState === 'Completed') {
17
21
  balanceSheetSelectorTypes_1.ALL_BALANCE_SHEET_REPORT_VIEW_SECTION_IDS.forEach((sectionId) => {
18
22
  sections[`${sectionId}`] = (0, sectionAccountsViewSelector_1.getSectionAccountsViewReport)(accountState, accountGroupState, sectionAccountsViewState, {
19
23
  reportId,
@@ -38,8 +42,11 @@ const getBalanceSheet = (filter, accountState, accountGroupState, sectionAccount
38
42
  bookCloseDate: balanceSheetState.bookCloseDate,
39
43
  version: balanceSheetState.version,
40
44
  status: balanceSheetState.status,
41
- fetchState: fetchState.fetchState,
42
- error: fetchState.error,
45
+ fetchState: selectedTimeframeFetchState.fetchState,
46
+ error: selectedTimeframeFetchState.error,
47
+ reducedAllFetchState,
48
+ reducedAnyFetchState,
49
+ fetchStateByTimeframe,
43
50
  filter: filter,
44
51
  uiState: balanceSheetState.uiState,
45
52
  idsInOrder: balanceSheetSelectorTypes_1.balanceSheetSectionIdsInOrder,
@@ -68,10 +75,22 @@ function getBalanceSheetForFullDataAvailableRange(timeframe, state) {
68
75
  }
69
76
  exports.getBalanceSheetForFullDataAvailableRange = getBalanceSheetForFullDataAvailableRange;
70
77
  const getBalanceSheetFetchState = (balanceSheetState) => {
71
- return (0, reduceFetchState_1.reduceAnyFetchState)([
72
- balanceSheetState.fetchState.month,
73
- balanceSheetState.fetchState.quarter,
74
- balanceSheetState.fetchState.year,
75
- ]);
78
+ return {
79
+ reducedAnyFetchState: (0, reduceFetchState_1.reduceAnyCompletedFetchState)([
80
+ balanceSheetState.fetchState.month,
81
+ balanceSheetState.fetchState.quarter,
82
+ balanceSheetState.fetchState.year,
83
+ ]),
84
+ reducedAllFetchState: (0, reduceFetchState_1.reduceAllFetchState)([
85
+ balanceSheetState.fetchState.month,
86
+ balanceSheetState.fetchState.quarter,
87
+ balanceSheetState.fetchState.year,
88
+ ]),
89
+ fetchStateByTimeframe: {
90
+ month: balanceSheetState.fetchState.month,
91
+ quarter: balanceSheetState.fetchState.quarter,
92
+ year: balanceSheetState.fetchState.year,
93
+ },
94
+ };
76
95
  };
77
96
  exports.getBalanceSheetFetchState = getBalanceSheetFetchState;
@@ -1,5 +1,7 @@
1
1
  import { AccountsViewSelectorReport } from '../../commonStateTypes/selectorTypes/accountsViewSelectorReport';
2
2
  import { BalanceSheetUIState } from './balanceSheetState';
3
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
4
+ import { FetchStateAndError } from '../../commonStateTypes/common';
3
5
  export declare const ALL_BALANCE_SHEET_REPORT_VIEW_ROOT_SECTION_IDS: readonly ["equity", "assets", "liabilities"];
4
6
  export declare const toBalanceSheetReportViewRootSectionID: (v: string) => "equity" | "assets" | "liabilities";
5
7
  export declare type BalanceSheetReportViewRootSectionID = ReturnType<typeof toBalanceSheetReportViewRootSectionID>;
@@ -46,4 +48,7 @@ export declare const balanceSheetSectionIdsInOrder: BalanceSheetReportViewID[];
46
48
  export interface BalanceSheetReport extends AccountsViewSelectorReport<BalanceSheetReportViewSectionID, BalanceSheetReportViewCalculatedSectionID> {
47
49
  rootSectionsWithSubSectionIds: SectionIdsWithSubSectionIds;
48
50
  uiState: BalanceSheetUIState;
51
+ fetchStateByTimeframe: FetchStateByTimeframe;
52
+ reducedAnyFetchState: FetchStateAndError;
53
+ reducedAllFetchState: FetchStateAndError;
49
54
  }
@@ -5,5 +5,10 @@ import { AccountGroupState } from '../../entity/accountGroup/accountGroupState';
5
5
  import { SectionAccountsViewState } from '../../entity/sectionAccountsView/sectionAccountsViewState';
6
6
  import { CashFlowReport } from './cashFlowSelectorTypes';
7
7
  import { CashFlowState } from './cashFlowState';
8
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
8
9
  export declare function getCashFlow(filter: COABalancesFilter, accountState: AccountState, accountGroupState: AccountGroupState, sectionsState: SectionAccountsViewState, cashFlowState: CashFlowState): CashFlowReport;
9
- export declare const getCashFlowReportFetchState: (cashFlowState: CashFlowState) => FetchStateAndError;
10
+ export declare const getCashFlowReportFetchState: (cashFlowState: CashFlowState) => {
11
+ reducedAnyFetchState: FetchStateAndError;
12
+ reducedAllFetchState: FetchStateAndError;
13
+ fetchStateByTimeframe: FetchStateByTimeframe;
14
+ };
@@ -9,11 +9,11 @@ const cashFlowForTimeframeEpic_1 = require("./cashFlowForTimeframeEpic");
9
9
  const cashFlowPayload_1 = require("./cashFlowPayload");
10
10
  const cashFlowSelectorTypes_1 = require("./cashFlowSelectorTypes");
11
11
  function getCashFlow(filter, accountState, accountGroupState, sectionsState, cashFlowState) {
12
- const fetchState = (0, reduceFetchState_1.reduceAnyFetchState)([
13
- cashFlowState.fetchState.month,
14
- cashFlowState.fetchState.quarter,
15
- cashFlowState.fetchState.year,
16
- ]);
12
+ if (filter.timeframe === 'week' || filter.timeframe === 'free_range') {
13
+ throw Error('free_range or week period is invalid');
14
+ }
15
+ const { reducedAllFetchState, reducedAnyFetchState, fetchStateByTimeframe } = (0, exports.getCashFlowReportFetchState)(cashFlowState);
16
+ const selectedTimeframeFetchState = fetchStateByTimeframe[filter.timeframe];
17
17
  const reportId = (0, cashFlowForTimeframeEpic_1.reportIdUniqueKey)();
18
18
  const sections = {};
19
19
  const calculatedSections = {};
@@ -25,7 +25,7 @@ function getCashFlow(filter, accountState, accountGroupState, sectionsState, cas
25
25
  reportId,
26
26
  sectionId: 'cashAndEquivalentsClosingBalance',
27
27
  });
28
- if (fetchState.fetchState === 'Completed') {
28
+ if (selectedTimeframeFetchState.fetchState === 'Completed') {
29
29
  cashFlowPayload_1.ALL_CASHFLOW_REPORT_VIEW_SECTION_IDS.forEach((sectionId) => {
30
30
  sections[`${sectionId}`] = (0, sectionAccountsViewSelector_1.getSectionAccountsViewReport)(accountState, accountGroupState, sectionsState, {
31
31
  reportId,
@@ -64,6 +64,9 @@ function getCashFlow(filter, accountState, accountGroupState, sectionsState, cas
64
64
  calculatedSections,
65
65
  firstMonthOfFY,
66
66
  dataAvailable,
67
+ reducedAllFetchState,
68
+ reducedAnyFetchState,
69
+ fetchStateByTimeframe,
67
70
  bookCloseDate: cashFlowState.bookCloseDate,
68
71
  availableNumberOfPeriods: (0, dataAvailable_1.getNumberOfPeriods)(firstMonthOfFY, filter.timeframe, dataAvailable),
69
72
  idsInOrder: cashFlowSelectorTypes_1.cashFlowSectionIdsInOrder,
@@ -79,16 +82,28 @@ function getCashFlow(filter, accountState, accountGroupState, sectionsState, cas
79
82
  reportTitle: cashFlowState.reportTitle,
80
83
  version: cashFlowState.version,
81
84
  uiState,
82
- fetchState: fetchState.fetchState,
83
- error: fetchState.error,
85
+ fetchState: selectedTimeframeFetchState.fetchState,
86
+ error: selectedTimeframeFetchState.error,
84
87
  };
85
88
  }
86
89
  exports.getCashFlow = getCashFlow;
87
90
  const getCashFlowReportFetchState = (cashFlowState) => {
88
- return (0, reduceFetchState_1.reduceAnyFetchState)([
89
- cashFlowState.fetchState.month,
90
- cashFlowState.fetchState.quarter,
91
- cashFlowState.fetchState.year,
92
- ]);
91
+ return {
92
+ reducedAnyFetchState: (0, reduceFetchState_1.reduceAnyCompletedFetchState)([
93
+ cashFlowState.fetchState.month,
94
+ cashFlowState.fetchState.quarter,
95
+ cashFlowState.fetchState.year,
96
+ ]),
97
+ reducedAllFetchState: (0, reduceFetchState_1.reduceAllFetchState)([
98
+ cashFlowState.fetchState.month,
99
+ cashFlowState.fetchState.quarter,
100
+ cashFlowState.fetchState.year,
101
+ ]),
102
+ fetchStateByTimeframe: {
103
+ month: cashFlowState.fetchState.month,
104
+ quarter: cashFlowState.fetchState.quarter,
105
+ year: cashFlowState.fetchState.year,
106
+ },
107
+ };
93
108
  };
94
109
  exports.getCashFlowReportFetchState = getCashFlowReportFetchState;
@@ -1,6 +1,8 @@
1
1
  import { CashFlowUIState } from './cashFlowState';
2
2
  import { CashFlowReportViewCalculatedSectionID, CashFlowReportViewID, CashFlowReportViewSectionID } from './cashFlowPayload';
3
3
  import { AccountsViewSelectorReport } from '../../commonStateTypes/selectorTypes/accountsViewSelectorReport';
4
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
5
+ import { FetchStateAndError } from '../../commonStateTypes/common';
4
6
  export declare const ALL_CASH_FLOW_REPORT_VIEW_ROOT_SECTION_IDS: readonly ["operatingActivities", "financingActivities", "investingActivities"];
5
7
  export declare const toCashFlowReportViewRootSectionID: (v: string) => "operatingActivities" | "investingActivities" | "financingActivities";
6
8
  export declare type CashFlowReportViewRootSectionID = ReturnType<typeof toCashFlowReportViewRootSectionID>;
@@ -38,4 +40,7 @@ export interface SectionIdsWithSubSectionIds {
38
40
  export interface CashFlowReport extends AccountsViewSelectorReport<CashFlowReportViewSectionID, CashFlowReportViewCalculatedSectionID> {
39
41
  rootSectionsWithSubSectionIds: SectionIdsWithSubSectionIds;
40
42
  uiState: CashFlowUIState;
43
+ fetchStateByTimeframe: FetchStateByTimeframe;
44
+ reducedAnyFetchState: FetchStateAndError;
45
+ reducedAllFetchState: FetchStateAndError;
41
46
  }
@@ -8,24 +8,18 @@ import { fetchCashFlow } from '../cashFlow/cashFlowReducer';
8
8
  export declare type ActionType = ReturnType<typeof fetchFinanceStatement> | ReturnType<typeof fetchAllTenants> | ReturnType<typeof fetchProfitAndLoss> | ReturnType<typeof fetchBalanceSheet> | ReturnType<typeof fetchCashFlow>;
9
9
  export declare const fetchFinanceStatementEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>) => import("rxjs").Observable<{
10
10
  payload: {
11
- userId: string;
12
- zeniSessionId: string | undefined;
13
- };
14
- type: string;
15
- } | {
16
- payload: {
17
- forecastId: string | undefined;
18
- cacheOverride: boolean;
11
+ timeframe: "month" | "year" | "quarter";
12
+ fetchFullReport: boolean;
19
13
  };
20
14
  type: string;
21
15
  } | {
22
16
  payload: {
23
- cacheOverride: boolean;
17
+ userId: string;
18
+ zeniSessionId: string | undefined;
24
19
  };
25
20
  type: string;
26
21
  } | {
27
22
  payload: {
28
- fetchFullReport: boolean;
29
23
  cacheOverride: boolean;
30
24
  };
31
25
  type: string;
@@ -12,31 +12,62 @@ const cashFlowSelector_1 = require("../cashFlow/cashFlowSelector");
12
12
  const cashFlowReducer_1 = require("../cashFlow/cashFlowReducer");
13
13
  const balanceSheetSelector_1 = require("../balanceSheet/balanceSheetSelector");
14
14
  const fetchFinanceStatementEpic = (actions$, state$) => actions$.pipe((0, operators_1.filter)(financeStatementReducer_1.fetchFinanceStatement.match), (0, operators_1.switchMap)((action) => {
15
- const { userId, fetchFullReport, cacheOverride } = action.payload;
15
+ const { userId, fetchSelectedTab, fetchFullReport, cacheOverride } = action.payload;
16
+ const state = state$.value;
16
17
  if (cacheOverride === true) {
17
18
  return (0, rxjs_1.of)((0, tenantReducer_1.fetchAllTenants)(userId), (0, profitAndLossReducer_1.fetchProfitAndLoss)(), (0, balanceSheetReducer_1.fetchBalanceSheet)(), (0, cashFlowReducer_1.fetchCashFlow)());
18
19
  }
19
20
  else {
20
- const state = state$.value;
21
+ const { tenantState, financeStatementState } = state;
21
22
  const fetchActions = [];
22
- if (state.tenantState.fetchState !== 'In-Progress' &&
23
- !state.tenantState.hasValidState()) {
23
+ if (tenantState.fetchState !== 'In-Progress' &&
24
+ !tenantState.hasValidState()) {
24
25
  fetchActions.push((0, tenantReducer_1.fetchAllTenants)(userId));
25
26
  }
26
- const pandLFetchState = (0, profitAndLossSelector_1.getPandLReportFetchState)(undefined, state.profitAndLossState).fetchState;
27
- if (pandLFetchState !== 'In-Progress' &&
28
- pandLFetchState !== 'Completed') {
29
- fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLoss)());
27
+ const pandLFetchState = (0, profitAndLossSelector_1.getPandLReportFetchState)(undefined, state.profitAndLossState);
28
+ const balanceSheetFetchState = (0, balanceSheetSelector_1.getBalanceSheetFetchState)(state.balanceSheetState);
29
+ const cashFlowFetchState = (0, cashFlowSelector_1.getCashFlowReportFetchState)(state.cashFlowState);
30
+ if (fetchSelectedTab) {
31
+ switch (financeStatementState.selectedReportId) {
32
+ case 'profit_and_loss':
33
+ case 'profit_and_loss_by_classes':
34
+ if (pandLFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
35
+ pandLFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
36
+ fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLossForTimeframe)(financeStatementState.timeframe));
37
+ }
38
+ break;
39
+ case 'balance_sheet':
40
+ if (balanceSheetFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
41
+ balanceSheetFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
42
+ fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheetForTimeframe)(financeStatementState.timeframe));
43
+ }
44
+ break;
45
+ case 'cash_flow':
46
+ if (cashFlowFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
47
+ cashFlowFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
48
+ fetchActions.push((0, cashFlowReducer_1.fetchCashFlowForTimeframe)(financeStatementState.timeframe, fetchFullReport));
49
+ }
50
+ break;
51
+ default:
52
+ break;
53
+ }
30
54
  }
31
- const balanceSheetFetchState = (0, balanceSheetSelector_1.getBalanceSheetFetchState)(state.balanceSheetState).fetchState;
32
- if (balanceSheetFetchState !== 'In-Progress' &&
33
- balanceSheetFetchState !== 'Completed') {
34
- fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheet)(fetchFullReport));
35
- }
36
- const cashFlowFetchState = (0, cashFlowSelector_1.getCashFlowReportFetchState)(state.cashFlowState).fetchState;
37
- if (cashFlowFetchState !== 'In-Progress' &&
38
- cashFlowFetchState !== 'Completed') {
39
- fetchActions.push((0, cashFlowReducer_1.fetchCashFlow)(fetchFullReport));
55
+ else {
56
+ if (pandLFetchState.reducedAllFetchState.fetchState !== 'In-Progress' &&
57
+ pandLFetchState.reducedAllFetchState.fetchState !== 'Completed') {
58
+ fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLoss)());
59
+ }
60
+ if (balanceSheetFetchState.reducedAllFetchState.fetchState !==
61
+ 'In-Progress' &&
62
+ balanceSheetFetchState.reducedAllFetchState.fetchState !==
63
+ 'Completed') {
64
+ fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheet)(fetchFullReport));
65
+ }
66
+ if (cashFlowFetchState.reducedAllFetchState.fetchState !==
67
+ 'In-Progress' &&
68
+ cashFlowFetchState.reducedAllFetchState.fetchState !== 'Completed') {
69
+ fetchActions.push((0, cashFlowReducer_1.fetchCashFlow)(fetchFullReport));
70
+ }
40
71
  }
41
72
  return (0, rxjs_1.from)(fetchActions);
42
73
  }
@@ -7,8 +7,9 @@ import { COABalanceType } from '../../commonStateTypes/coaBalance/coaBalanceType
7
7
  import { FinanceStatementState } from './financeStatementState';
8
8
  import { Month } from '../../commonStateTypes/timePeriod';
9
9
  export declare const initialFinanceStatementState: FinanceStatementState;
10
- export declare const fetchFinanceStatement: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, fetchFullReport?: boolean | undefined, cacheOverride?: boolean | undefined], {
10
+ export declare const fetchFinanceStatement: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, fetchSelectedTab?: boolean | undefined, fetchFullReport?: boolean | undefined, cacheOverride?: boolean | undefined], {
11
11
  userId: string;
12
+ fetchSelectedTab: boolean;
12
13
  fetchFullReport: boolean;
13
14
  cacheOverride: boolean;
14
15
  }, string, never, never>, updateFinanceStatementTimeframe: import("@reduxjs/toolkit").ActionCreatorWithPayload<"month" | "year" | "quarter", string>, updateFinanceStatementThisPeriod: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
@@ -29,10 +29,13 @@ const financeStatement = (0, toolkit_1.createSlice)({
29
29
  reducer(draft) {
30
30
  draft.lastFetchRequestTime = (0, zeniDayJS_1.dateNow)();
31
31
  },
32
- prepare(userId, fetchFullReport = false, // eslint-disable-line @typescript-eslint/no-inferrable-types,
32
+ prepare(userId, fetchSelectedTab = true, // eslint-disable-line @typescript-eslint/no-inferrable-types,
33
+ fetchFullReport = false, // eslint-disable-line @typescript-eslint/no-inferrable-types,
33
34
  cacheOverride = false // eslint-disable-line @typescript-eslint/no-inferrable-types
34
35
  ) {
35
- return { payload: { userId, fetchFullReport, cacheOverride } };
36
+ return {
37
+ payload: { userId, fetchSelectedTab, fetchFullReport, cacheOverride },
38
+ };
36
39
  },
37
40
  },
38
41
  updateFinanceStatementTimeframe(draft, action) {
@@ -1,5 +1,5 @@
1
1
  import { RootState } from '../../reducer';
2
- import { FetchState } from '../../commonStateTypes/common';
2
+ import { FetchState, FetchStateAndError } from '../../commonStateTypes/common';
3
3
  import { SelectorReport, ReportID, ReportFormat } from '../../commonStateTypes/viewAndReport/viewAndReport';
4
4
  import { TimeframeTickWithMetaData } from '../../commonStateTypes/timeframeTick';
5
5
  import { COABalancesFilter, COABalancesOrder } from '../../commonStateTypes/coaBalance/coaBalancesFilter';
@@ -13,6 +13,7 @@ export interface FinanceStatementReport extends SelectorReport {
13
13
  allTimeframeTicks: TimeframeTickWithMetaData[];
14
14
  balancesInTimeframe: COABalance[];
15
15
  dataAvailable?: DataAvailable;
16
+ selectedReportAndTimeframeFetchState: FetchStateAndError;
16
17
  profitAndLossReport: ProfitAndLossReport;
17
18
  profitAndLossByClassReport: ProfitAndLossClassesViewReport;
18
19
  balanceSheetReport: BalanceSheetReport;
@@ -66,11 +66,35 @@ exports.getFinanceStatement = (0, toolkit_1.createSelector)((state) => state.acc
66
66
  const balanceSheetReport = (0, balanceSheetSelector_1.getBalanceSheet)(filter, accountState, accountGroupState, sectionAccountsViewState, balanceSheetState);
67
67
  const cashFlowReport = (0, cashFlowSelector_1.getCashFlow)(filter, accountState, accountGroupState, sectionAccountsViewState, cashFlowState);
68
68
  const allReports = [
69
- profitAndLossReport,
70
- balanceSheetReport,
71
- cashFlowReport,
69
+ profitAndLossReport.reducedAnyFetchState,
70
+ balanceSheetReport.reducedAnyFetchState,
71
+ cashFlowReport.reducedAnyFetchState,
72
72
  ];
73
- const fetchState = (0, reduceFetchState_1.reduceFetchState)(allReports);
73
+ const fetchState = (0, reduceFetchState_1.reduceAnyCompletedFetchState)(allReports);
74
+ let selectedReportAndTimeframeFetchState = fetchState;
75
+ switch (financeStatementState.selectedReportId) {
76
+ case 'profit_and_loss':
77
+ case 'profit_and_loss_by_classes':
78
+ selectedReportAndTimeframeFetchState = {
79
+ fetchState: profitAndLossReport.fetchState,
80
+ error: profitAndLossReport.error,
81
+ };
82
+ break;
83
+ case 'balance_sheet':
84
+ selectedReportAndTimeframeFetchState = {
85
+ fetchState: balanceSheetReport.fetchState,
86
+ error: balanceSheetReport.error,
87
+ };
88
+ break;
89
+ case 'cash_flow':
90
+ selectedReportAndTimeframeFetchState = {
91
+ fetchState: cashFlowReport.fetchState,
92
+ error: cashFlowReport.error,
93
+ };
94
+ break;
95
+ default:
96
+ break;
97
+ }
74
98
  return {
75
99
  reportId: 'finance_statement',
76
100
  reportTitle: '',
@@ -79,6 +103,7 @@ exports.getFinanceStatement = (0, toolkit_1.createSelector)((state) => state.acc
79
103
  error: fetchState.error,
80
104
  allTimeframeTicks,
81
105
  balancesInTimeframe,
106
+ selectedReportAndTimeframeFetchState,
82
107
  displayOrder: financeStatementState.displayOrder,
83
108
  reportFormat: financeStatementState.reportFormat,
84
109
  firstMonthOfFY,
@@ -7,8 +7,12 @@ import { ForecastState } from '../../entity/forecast/forecastState';
7
7
  import { SectionAccountsViewState } from '../../entity/sectionAccountsView/sectionAccountsViewState';
8
8
  import { PandLReportViewCalculatedSectionID, PandLReportViewSectionID } from '../profitAndLossClassesView/profitAndLossClassesViewSelectorTypes';
9
9
  import { ProfitAndLossUIState, ProfitAndLossWithForecastState } from './profitAndLossState';
10
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
10
11
  export interface ProfitAndLossReport extends AccountsViewSelectorReport<PandLReportViewSectionID, PandLReportViewCalculatedSectionID> {
11
12
  uiState: ProfitAndLossUIState;
13
+ fetchStateByTimeframe: FetchStateByTimeframe;
14
+ reducedAnyFetchState: FetchStateAndError;
15
+ reducedAllFetchState: FetchStateAndError;
12
16
  }
13
17
  /**
14
18
  * Get P&L with forecast data overlaid on actuals.
@@ -37,4 +41,8 @@ export declare const getProfitAndLossReport: (filter: COABalancesFilter, forecas
37
41
  * @param state
38
42
  */
39
43
  export declare function getProfitAndLossForFullDataAvailableRange(timeframe: 'month' | 'quarter' | 'year', forecastId: ID | undefined, accountState: AccountState, accountGroupState: AccountGroupState, sectionsState: SectionAccountsViewState, forecastState: ForecastState, state: ProfitAndLossWithForecastState): ProfitAndLossReport;
40
- export declare const getPandLReportFetchState: (forecastId: ID | undefined, profitAndLossState: ProfitAndLossWithForecastState) => FetchStateAndError;
44
+ export declare const getPandLReportFetchState: (forecastId: ID | undefined, profitAndLossState: ProfitAndLossWithForecastState) => {
45
+ reducedAnyFetchState: FetchStateAndError;
46
+ reducedAllFetchState: FetchStateAndError;
47
+ fetchStateByTimeframe: FetchStateByTimeframe;
48
+ };
@@ -30,16 +30,16 @@ function getProfitAndLossWithForecastOnDataAvailableDateRange(filter, forecastId
30
30
  }
31
31
  exports.getProfitAndLossWithForecastOnDataAvailableDateRange = getProfitAndLossWithForecastOnDataAvailableDateRange;
32
32
  const getProfitAndLossReport = (filter, forecastId, accountState, accountGroupState, sectionsState, profitAndLossState, forecastState) => {
33
+ if (filter.timeframe === 'week' || filter.timeframe === 'free_range') {
34
+ throw Error('free_range or week period is invalid');
35
+ }
33
36
  const pandLState = (0, profitAndLossReducer_1.getState)(profitAndLossState, forecastId);
34
- const fetchState = (0, reduceFetchState_1.reduceAnyFetchState)([
35
- pandLState.fetchState.month,
36
- pandLState.fetchState.quarter,
37
- pandLState.fetchState.year,
38
- ]);
37
+ const { reducedAllFetchState, reducedAnyFetchState, fetchStateByTimeframe } = (0, exports.getPandLReportFetchState)(forecastId, profitAndLossState);
39
38
  const reportId = (0, profitAndLossForTimeframeEpic_1.reportIdUniqueKey)(forecastId);
40
39
  const sections = {};
41
40
  const calculatedSections = {};
42
- if (fetchState.fetchState === 'Completed') {
41
+ const selectedTimeframeFetchState = fetchStateByTimeframe[filter.timeframe];
42
+ if (selectedTimeframeFetchState.fetchState === 'Completed') {
43
43
  profitAndLossClassesViewSelectorTypes_1.ALL_PANDL_REPORT_VIEW_SECTION_IDS.forEach((sectionId) => {
44
44
  sections[`${sectionId}`] = (0, sectionAccountsViewSelector_1.getSectionAccountsViewReport)(accountState, accountGroupState, sectionsState, {
45
45
  reportId,
@@ -67,8 +67,11 @@ const getProfitAndLossReport = (filter, forecastId, accountState, accountGroupSt
67
67
  bookCloseDate: pandLState.bookCloseDate,
68
68
  version: pandLState.version,
69
69
  status: pandLState.status,
70
- fetchState: fetchState.fetchState,
71
- error: fetchState.error,
70
+ reducedAllFetchState,
71
+ reducedAnyFetchState,
72
+ fetchStateByTimeframe,
73
+ fetchState: selectedTimeframeFetchState.fetchState,
74
+ error: selectedTimeframeFetchState.error,
72
75
  filter: filter,
73
76
  uiState: pandLState.uiState,
74
77
  idsInOrder: profitAndLossClassesViewSelector_1.profitAndLossIdsInOrder,
@@ -95,10 +98,22 @@ function getProfitAndLossForFullDataAvailableRange(timeframe, forecastId, accoun
95
98
  exports.getProfitAndLossForFullDataAvailableRange = getProfitAndLossForFullDataAvailableRange;
96
99
  const getPandLReportFetchState = (forecastId, profitAndLossState) => {
97
100
  const pandLState = (0, profitAndLossReducer_1.getState)(profitAndLossState, forecastId);
98
- return (0, reduceFetchState_1.reduceAnyFetchState)([
99
- pandLState.fetchState.month,
100
- pandLState.fetchState.quarter,
101
- pandLState.fetchState.year,
102
- ]);
101
+ return {
102
+ reducedAnyFetchState: (0, reduceFetchState_1.reduceAnyCompletedFetchState)([
103
+ pandLState.fetchState.month,
104
+ pandLState.fetchState.quarter,
105
+ pandLState.fetchState.year,
106
+ ]),
107
+ reducedAllFetchState: (0, reduceFetchState_1.reduceAllFetchState)([
108
+ pandLState.fetchState.month,
109
+ pandLState.fetchState.quarter,
110
+ pandLState.fetchState.year,
111
+ ]),
112
+ fetchStateByTimeframe: {
113
+ month: pandLState.fetchState.month,
114
+ quarter: pandLState.fetchState.quarter,
115
+ year: pandLState.fetchState.year,
116
+ },
117
+ };
103
118
  };
104
119
  exports.getPandLReportFetchState = getPandLReportFetchState;
@@ -1,4 +1,5 @@
1
- import { FetchStateAndError, ID } from '../../commonStateTypes/common';
1
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
2
+ import { ID } from '../../commonStateTypes/common';
2
3
  import { Report } from '../../commonStateTypes/viewAndReport/viewAndReport';
3
4
  export interface ProfitAndLossUIState {
4
5
  nodeCollapseState: Record<ID, boolean>;
@@ -10,11 +11,7 @@ export interface ProfitAndLossUIState {
10
11
  export interface ProfitAndLossState extends Report {
11
12
  uiState: ProfitAndLossUIState;
12
13
  forecastId?: ID;
13
- fetchState: {
14
- month: FetchStateAndError;
15
- quarter: FetchStateAndError;
16
- year: FetchStateAndError;
17
- };
14
+ fetchState: FetchStateByTimeframe;
18
15
  }
19
16
  export interface ProfitAndLossWithForecastState {
20
17
  pandL: ProfitAndLossState;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeniai/client-epic-state",
3
- "version": "4.11.96",
3
+ "version": "4.11.98",
4
4
  "description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",