@zeniai/client-epic-state 5.2.30 → 5.2.32-betaAK0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonStateTypes/coaBalance/classBalances/getSumOfBalancesGroupedByPeriod.js +16 -3
- package/lib/commonStateTypes/viewAndReport/reportIDHelper.d.ts +6 -0
- package/lib/commonStateTypes/viewAndReport/reportIDHelper.js +12 -1
- package/lib/commonStateTypes/viewAndReport/viewAndReport.d.ts +2 -2
- package/lib/commonStateTypes/viewAndReport/viewAndReport.js +2 -0
- package/lib/entity/accountGroup/accountGroupState.d.ts +1 -1
- package/lib/entity/class/classReducer.d.ts +4 -4
- package/lib/entity/class/classState.d.ts +1 -1
- package/lib/entity/forecast/forecastState.d.ts +1 -1
- package/lib/entity/sectionAccountsView/sectionAccountsView.d.ts +1 -1
- package/lib/entity/sectionClassesViewV2/sectionClassesView.d.ts +1 -1
- package/lib/entity/sectionClassesViewV2/sectionClassesViewEpic.js +2 -1
- package/lib/entity/sectionClassesViewV2/sectionClassesViewReducer.d.ts +2 -2
- package/lib/entity/sectionProjectView/sectionProjectView.d.ts +1 -1
- package/lib/entity/sectionProjectView/sectionProjectViewReducer.d.ts +2 -2
- package/lib/epic.d.ts +10 -6
- package/lib/epic.js +15 -8
- package/lib/esm/commonStateTypes/coaBalance/classBalances/getSumOfBalancesGroupedByPeriod.js +16 -3
- package/lib/esm/commonStateTypes/viewAndReport/reportIDHelper.js +7 -0
- package/lib/esm/commonStateTypes/viewAndReport/viewAndReport.js +2 -0
- package/lib/esm/entity/sectionClassesViewV2/sectionClassesViewEpic.js +2 -1
- package/lib/esm/epic.js +14 -7
- package/lib/esm/index.js +16 -13
- package/lib/esm/reducer.js +18 -12
- package/lib/esm/view/cashFlow/cashFlowGroupedSectionOrder.js +47 -0
- package/lib/esm/view/cashFlowClassesView/cashFlowClassesViewEpic.js +30 -0
- package/lib/esm/view/cashFlowClassesView/cashFlowClassesViewReducer.js +129 -0
- package/lib/esm/view/cashFlowClassesView/cashFlowClassesViewSelector.js +53 -0
- package/lib/esm/view/cashFlowClassesView/cashFlowForTimeframeClassesViewEpic.js +55 -0
- package/lib/esm/view/cashFlowProjectView/cashFlowForTimeframeProjectViewEpic.js +57 -0
- package/lib/esm/view/cashFlowProjectView/cashFlowProjectViewEpic.js +30 -0
- package/lib/esm/view/cashFlowProjectView/cashFlowProjectViewReducer.js +125 -0
- package/lib/esm/view/cashFlowProjectView/cashFlowProjectViewSelector.js +54 -0
- package/lib/esm/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +29 -11
- package/lib/esm/view/financeStatement/financeStatementSelector.js +21 -1
- package/lib/esm/view/invoicing/customerPaymentMethod/customerPaymentMethodEpic.js +1 -1
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewPayload.js +1 -1
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer.js +1 -24
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewSelector.js +10 -36
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/invoicingCatalogSubFamilyEpics.js +2 -21
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/saveInvoicingCatalogItemEpic.js +11 -33
- package/lib/esm/view/invoicing/editInvoicingCouponDetailView/editInvoicingCouponDetailViewSelector.js +9 -1
- package/lib/esm/view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector.js +2 -0
- package/lib/esm/view/invoicing/editInvoicingCustomerDetailView/initializeInvoicingCustomerAddressEpic.js +1 -1
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.js +15 -0
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic.js +1 -1
- package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/initializeInvoicingSubscriptionAddressEpic.js +1 -1
- package/lib/esm/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewEpics.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewEpics.js} +1 -1
- package/lib/esm/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewReducer.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewReducer.js} +4 -4
- package/lib/esm/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewSelector.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewSelector.js} +2 -4
- package/lib/esm/view/invoicing/{invoicingCouponDetailView → invoicingCouponRecordView}/fetchInvoicingCouponDetailEpic.js +1 -1
- package/lib/esm/view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewPayload.js +1 -0
- package/lib/esm/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewReducer.js → invoicingCouponRecordView/invoicingCouponRecordViewReducer.js} +4 -4
- package/lib/esm/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewSelector.js → invoicingCouponRecordView/invoicingCouponRecordViewSelector.js} +2 -2
- package/lib/esm/view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewState.js +1 -0
- package/lib/esm/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailEpic.js +1 -1
- package/lib/esm/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailPageEpic.js +2 -2
- package/lib/esm/view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewPayload.js +1 -0
- package/lib/esm/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewReducer.js → invoicingCustomerRecordView/invoicingCustomerRecordViewReducer.js} +4 -4
- package/lib/esm/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewSelector.js → invoicingCustomerRecordView/invoicingCustomerRecordViewSelector.js} +3 -3
- package/lib/esm/view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewState.js +1 -0
- package/lib/esm/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewEpics.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewEpics.js} +1 -1
- package/lib/esm/view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewPayload.js +1 -0
- package/lib/esm/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewReducer.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewReducer.js} +4 -4
- package/lib/esm/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewSelector.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewSelector.js} +2 -2
- package/lib/esm/view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewState.js +1 -0
- package/lib/esm/view/invoicing/promotionalCreditAction/promotionalCreditActionEpic.js +1 -1
- package/lib/index.d.ts +26 -20
- package/lib/index.js +88 -74
- package/lib/reducer.d.ts +6 -4
- package/lib/reducer.js +18 -12
- package/lib/rootStateTypes.d.ts +12 -8
- package/lib/view/auditReportView/auditReportViewState.d.ts +1 -1
- package/lib/view/billPayCard/billPayCardSelector.d.ts +1 -1
- package/lib/view/cardBalance/cardBalanceSelector.d.ts +1 -1
- package/lib/view/cashBalance/cashBalanceSelector.d.ts +1 -1
- package/lib/view/cashFlow/cashFlowGroupedSectionOrder.d.ts +15 -0
- package/lib/view/cashFlow/cashFlowGroupedSectionOrder.js +50 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewEpic.d.ts +6 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewEpic.js +34 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewPayload.d.ts +14 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewReducer.d.ts +34 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewReducer.js +133 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewSelector.d.ts +7 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewSelector.js +57 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewSelectorTypes.d.ts +15 -0
- package/lib/view/cashFlowClassesView/cashFlowClassesViewState.d.ts +23 -0
- package/lib/view/cashFlowClassesView/cashFlowForTimeframeClassesViewEpic.d.ts +9 -0
- package/lib/view/cashFlowClassesView/cashFlowForTimeframeClassesViewEpic.js +60 -0
- package/lib/view/cashFlowProjectView/cashFlowForTimeframeProjectViewEpic.d.ts +10 -0
- package/lib/view/cashFlowProjectView/cashFlowForTimeframeProjectViewEpic.js +62 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewEpic.d.ts +6 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewEpic.js +34 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewPayload.d.ts +14 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewReducer.d.ts +33 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewReducer.js +129 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewSelector.d.ts +7 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewSelector.js +58 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewSelectorTypes.d.ts +19 -0
- package/lib/view/cashFlowProjectView/cashFlowProjectViewState.d.ts +22 -0
- package/lib/view/cashInCashOut/cashInCashOutSelector.d.ts +1 -1
- package/lib/view/cashPosition/cashPositionSelector.d.ts +1 -1
- package/lib/view/dashboard/dashboardReducer.d.ts +2 -2
- package/lib/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +29 -11
- package/lib/view/financeStatement/financeStatementReducer.d.ts +1 -1
- package/lib/view/financeStatement/financeStatementSelector.d.ts +4 -0
- package/lib/view/financeStatement/financeStatementSelector.js +21 -1
- package/lib/view/globalMerchantView/globalMerchantViewReducer.d.ts +2 -2
- package/lib/view/invoicing/createInvoice/createInvoiceSelector.d.ts +2 -2
- package/lib/view/invoicing/customerPaymentMethod/customerPaymentMethodEpic.d.ts +1 -1
- package/lib/view/invoicing/customerPaymentMethod/customerPaymentMethodEpic.js +2 -2
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewPayload.d.ts +1 -1
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewPayload.js +1 -1
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer.d.ts +3 -19
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer.js +2 -25
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewSelector.d.ts +11 -11
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewSelector.js +11 -38
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewState.d.ts +4 -27
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/invoicingCatalogSubFamilyEpics.d.ts +2 -3
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/invoicingCatalogSubFamilyEpics.js +2 -22
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/saveInvoicingCatalogItemEpic.d.ts +2 -2
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/saveInvoicingCatalogItemEpic.js +9 -31
- package/lib/view/invoicing/editInvoicingCouponDetailView/editInvoicingCouponDetailViewSelector.d.ts +12 -1
- package/lib/view/invoicing/editInvoicingCouponDetailView/editInvoicingCouponDetailViewSelector.js +9 -1
- package/lib/view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector.d.ts +8 -0
- package/lib/view/invoicing/editInvoicingCustomerDetailView/editInvoicingCustomerDetailViewSelector.js +2 -0
- package/lib/view/invoicing/editInvoicingCustomerDetailView/initializeInvoicingCustomerAddressEpic.d.ts +1 -1
- package/lib/view/invoicing/editInvoicingCustomerDetailView/initializeInvoicingCustomerAddressEpic.js +2 -2
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.d.ts +11 -2
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector.js +15 -0
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic.d.ts +1 -1
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/fetchInvoicingSubscriptionFormPageEpic.js +2 -2
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/initializeInvoicingSubscriptionAddressEpic.d.ts +1 -1
- package/lib/view/invoicing/editInvoicingSubscriptionDetailView/initializeInvoicingSubscriptionAddressEpic.js +2 -2
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewEpics.d.ts → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewEpics.d.ts} +1 -1
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewEpics.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewEpics.js} +5 -5
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewReducer.d.ts → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewReducer.d.ts} +5 -5
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewReducer.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewReducer.js} +4 -4
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewSelector.d.ts → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewSelector.d.ts} +3 -5
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewSelector.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewSelector.js} +4 -6
- package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewState.d.ts → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewState.d.ts} +1 -1
- package/lib/view/invoicing/{invoicingCouponDetailView → invoicingCouponRecordView}/fetchInvoicingCouponDetailEpic.d.ts +1 -1
- package/lib/view/invoicing/{invoicingCouponDetailView → invoicingCouponRecordView}/fetchInvoicingCouponDetailEpic.js +5 -5
- package/lib/view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewPayload.js +2 -0
- package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewReducer.d.ts → invoicingCouponRecordView/invoicingCouponRecordViewReducer.d.ts} +6 -6
- package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewReducer.js → invoicingCouponRecordView/invoicingCouponRecordViewReducer.js} +4 -4
- package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewSelector.d.ts → invoicingCouponRecordView/invoicingCouponRecordViewSelector.d.ts} +2 -2
- package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewSelector.js → invoicingCouponRecordView/invoicingCouponRecordViewSelector.js} +4 -4
- package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewState.d.ts → invoicingCouponRecordView/invoicingCouponRecordViewState.d.ts} +1 -1
- package/lib/view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewState.js +2 -0
- package/lib/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailEpic.d.ts +1 -1
- package/lib/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailEpic.js +5 -5
- package/lib/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailPageEpic.d.ts +1 -1
- package/lib/view/invoicing/{invoicingCustomerDetailView → invoicingCustomerRecordView}/fetchInvoicingCustomerDetailPageEpic.js +4 -4
- package/lib/view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewPayload.js +2 -0
- package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewReducer.d.ts → invoicingCustomerRecordView/invoicingCustomerRecordViewReducer.d.ts} +7 -7
- package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewReducer.js → invoicingCustomerRecordView/invoicingCustomerRecordViewReducer.js} +4 -4
- package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewSelector.d.ts → invoicingCustomerRecordView/invoicingCustomerRecordViewSelector.d.ts} +2 -2
- package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewSelector.js → invoicingCustomerRecordView/invoicingCustomerRecordViewSelector.js} +5 -5
- package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewState.d.ts → invoicingCustomerRecordView/invoicingCustomerRecordViewState.d.ts} +1 -1
- package/lib/view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewState.js +2 -0
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewEpics.d.ts → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewEpics.d.ts} +1 -1
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewEpics.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewEpics.js} +5 -5
- package/lib/view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewPayload.js +2 -0
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewReducer.d.ts → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewReducer.d.ts} +5 -5
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewReducer.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewReducer.js} +4 -4
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewSelector.d.ts → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewSelector.d.ts} +2 -2
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewSelector.js → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewSelector.js} +4 -4
- package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewState.d.ts → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewState.d.ts} +1 -1
- package/lib/view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewState.js +2 -0
- package/lib/view/invoicing/promotionalCreditAction/promotionalCreditActionEpic.d.ts +1 -1
- package/lib/view/invoicing/promotionalCreditAction/promotionalCreditActionEpic.js +2 -2
- package/lib/view/reimbursementCard/reimbursementCardSelector.d.ts +1 -1
- package/lib/view/reportsResync/reportsResyncReducer.d.ts +2 -2
- package/lib/view/tasksCard/tasksCardSelector.d.ts +1 -1
- package/lib/view/topEx/topExSelector.d.ts +1 -1
- package/package.json +71 -38
- package/lib/esm/view/invoicing/editInvoicingCatalogItemDetailView/catalogDetailEditPayload.js +0 -191
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/catalogDetailEditPayload.d.ts +0 -46
- package/lib/view/invoicing/editInvoicingCatalogItemDetailView/catalogDetailEditPayload.js +0 -198
- /package/lib/esm/view/{invoicing/invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewPayload.js → cashFlowClassesView/cashFlowClassesViewPayload.js} +0 -0
- /package/lib/esm/view/{invoicing/invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewState.js → cashFlowClassesView/cashFlowClassesViewSelectorTypes.js} +0 -0
- /package/lib/esm/view/{invoicing/invoicingCouponDetailView/invoicingCouponDetailViewPayload.js → cashFlowClassesView/cashFlowClassesViewState.js} +0 -0
- /package/lib/esm/view/{invoicing/invoicingCouponDetailView/invoicingCouponDetailViewState.js → cashFlowProjectView/cashFlowProjectViewPayload.js} +0 -0
- /package/lib/esm/view/{invoicing/invoicingCustomerDetailView/invoicingCustomerDetailViewPayload.js → cashFlowProjectView/cashFlowProjectViewSelectorTypes.js} +0 -0
- /package/lib/esm/view/{invoicing/invoicingCustomerDetailView/invoicingCustomerDetailViewState.js → cashFlowProjectView/cashFlowProjectViewState.js} +0 -0
- /package/lib/esm/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewPayload.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewPayload.js} +0 -0
- /package/lib/esm/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewState.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewState.js} +0 -0
- /package/lib/view/{invoicing/invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewPayload.js → cashFlowClassesView/cashFlowClassesViewPayload.js} +0 -0
- /package/lib/view/{invoicing/invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewState.js → cashFlowClassesView/cashFlowClassesViewSelectorTypes.js} +0 -0
- /package/lib/view/{invoicing/invoicingCouponDetailView/invoicingCouponDetailViewPayload.js → cashFlowClassesView/cashFlowClassesViewState.js} +0 -0
- /package/lib/view/{invoicing/invoicingCouponDetailView/invoicingCouponDetailViewState.js → cashFlowProjectView/cashFlowProjectViewPayload.js} +0 -0
- /package/lib/view/{invoicing/invoicingCustomerDetailView/invoicingCustomerDetailViewPayload.js → cashFlowProjectView/cashFlowProjectViewSelectorTypes.js} +0 -0
- /package/lib/view/{invoicing/invoicingCustomerDetailView/invoicingCustomerDetailViewState.js → cashFlowProjectView/cashFlowProjectViewState.js} +0 -0
- /package/lib/view/invoicing/{invoicingCatalogItemDetailView/invoicingCatalogItemDetailViewPayload.d.ts → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewPayload.d.ts} +0 -0
- /package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewPayload.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewPayload.js} +0 -0
- /package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewState.js → invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewState.js} +0 -0
- /package/lib/view/invoicing/{invoicingCouponDetailView/invoicingCouponDetailViewPayload.d.ts → invoicingCouponRecordView/invoicingCouponRecordViewPayload.d.ts} +0 -0
- /package/lib/view/invoicing/{invoicingCustomerDetailView/invoicingCustomerDetailViewPayload.d.ts → invoicingCustomerRecordView/invoicingCustomerRecordViewPayload.d.ts} +0 -0
- /package/lib/view/invoicing/{invoicingSubscriptionDetailView/invoicingSubscriptionDetailViewPayload.d.ts → invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewPayload.d.ts} +0 -0
package/lib/esm/index.js
CHANGED
|
@@ -23,7 +23,7 @@ import { toReimbursementTypeCode } from './commonStateTypes/reimbursementTypeCod
|
|
|
23
23
|
import { stringToUnion, stringToUnionStrict, } from './commonStateTypes/stringToUnion';
|
|
24
24
|
import { SCHEDULE_DAYS_OF_MONTH, convertToPeriod, toAbsoluteDay, toMonth, toMonthStrict, toMonthYearPeriodId, toQuarter, toQuarterStrict, toScheduleDaysOfMonth, } from './commonStateTypes/timePeriod';
|
|
25
25
|
import { mapTimePeriodtoTimeframeTick, toTimePeriod, toTimeframeTick, } from './commonStateTypes/timeframeTick';
|
|
26
|
-
import { isAgingReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isBalanceSheetReport, isCashFlowOrBalanceSheetReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isDashboardReport, isFluxAnalysisOpExReport, isGroupedBalanceSheetReport, isOpExByVendorReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isPAndLReport, } from './commonStateTypes/viewAndReport/reportIDHelper';
|
|
26
|
+
import { isAgingReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isBalanceSheetReport, isCashFlowClassesViewReport, isCashFlowOrBalanceSheetReport, isCashFlowProjectViewReport, isCashFlowReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isDashboardReport, isFluxAnalysisOpExReport, isGroupedBalanceSheetReport, isGroupedCashFlowReport, isOpExByVendorReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isPAndLReport, } from './commonStateTypes/viewAndReport/reportIDHelper';
|
|
27
27
|
import { toReportFormatStrict, toReportID, } from './commonStateTypes/viewAndReport/viewAndReport';
|
|
28
28
|
import { PAYMENT_BUSINESS_DAYS, filterDays, getNextNthWorkingDay, getNextTransferDate, getPreviousNthWorkingDay, getYearsList, holidaysFormatted, isHoliday, isHolidayToday, } from './commonStateTypes/workingDayHelper';
|
|
29
29
|
import { getAllAccounts, getTransactionFilterAccountOptions, } from './entity/account/accountSelector';
|
|
@@ -137,6 +137,10 @@ import { isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewCalculated
|
|
|
137
137
|
import { fetchCashFlow, fetchCashFlowForTimeframe, resetCashFlowNodeCollapseState, updateCashFlowUIState, } from './view/cashFlow/cashFlowReducer';
|
|
138
138
|
import { getCashFlow, getCashFlowReportFetchState, } from './view/cashFlow/cashFlowSelector';
|
|
139
139
|
import { typeOfCashFlowRootSection, } from './view/cashFlow/cashFlowSelectorTypes';
|
|
140
|
+
import { fetchCashFlowClassesView, fetchCashFlowForTimeframeClassesView, resetCashFlowClassesNodeCollapseState, updateCashFlowClassesToFilterOut, updateCashFlowClassesViewAccountViewMode, updateCashFlowClassesViewUIState, } from './view/cashFlowClassesView/cashFlowClassesViewReducer';
|
|
141
|
+
import { getCashFlowClassesView } from './view/cashFlowClassesView/cashFlowClassesViewSelector';
|
|
142
|
+
import { fetchCashFlowForTimeframeProjectView, fetchCashFlowProjectView, resetCashFlowProjectNodeCollapseState, updateCashFlowProjectViewAccountViewMode, updateCashFlowProjectViewUIState, updateCashFlowProjectsToFilterOut, } from './view/cashFlowProjectView/cashFlowProjectViewReducer';
|
|
143
|
+
import { getCashFlowProjectView } from './view/cashFlowProjectView/cashFlowProjectViewSelector';
|
|
140
144
|
import { fetchCashInCashOut, updateCashInCashOutCOABalancesRange, updateCashInCashOutDownloadState, updateCashInCashOutUIState, } from './view/cashInCashOut/cashInCashOutReducer';
|
|
141
145
|
import { getCashInCashOut, getCashInCashOutForHighlightedRange, getCashInCashOutForSelectedRange, getCashInCashOutUIState, } from './view/cashInCashOut/cashInCashOutSelector';
|
|
142
146
|
import { fetchCashPosition, updateCashPositionCOABalancesRange, updateCashPositionDownloadState, updateCashPositionUIState, } from './view/cashPosition/cashPositionReducer';
|
|
@@ -475,7 +479,7 @@ export { saveJeAccountSettings, saveJeAccountSettingsLocalData };
|
|
|
475
479
|
export default initialize;
|
|
476
480
|
export { initializePusher, disconnectPusher, Dayjs, dateInLocal as zeniDateInLocal, date as zeniDate, dateLocal, dateNow, getBusinessDayOfDate, formatZeniDateFY as formatZeniDate, getFYMonths, getFYQuarterAndYear, getStartOfAndEndOfTimeframeForFY, getActualPeriodOfFYQtr, getActualPeriodOfFY, getLocalTimezone, addPeriod, subtractPeriod, setLocalTimezone, updateZeniDateLocaleID, toZeniUrl, toZeniUrlWithoutBaseURL, updateZeniAPIClientConfig, zeniAPIClientConfig, injectFeatureEpics, injectFeatureModules, initializeWithNewStore, getTimeframeTickTag, isIncompleteMonthPresentInTimeframeTick, getLastMonthOfFYQuarter, getLastMonthOfFYYear, getMonthIndex, dateFromYearMonthDate, getMinDate, };
|
|
477
481
|
export { toAmount };
|
|
478
|
-
export { toReportID, toReportFormatStrict, isCashFlowOrBalanceSheetReport, isBalanceSheetReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isGroupedBalanceSheetReport, isDashboardReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isPAndLReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isAgingReport, isOpExByVendorReport, isFluxAnalysisOpExReport, };
|
|
482
|
+
export { toReportID, toReportFormatStrict, isCashFlowOrBalanceSheetReport, isBalanceSheetReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isCashFlowClassesViewReport, isCashFlowProjectViewReport, isCashFlowReport, isGroupedCashFlowReport, isGroupedBalanceSheetReport, isDashboardReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isPAndLReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isAgingReport, isOpExByVendorReport, isFluxAnalysisOpExReport, };
|
|
479
483
|
export { toCOABalanceTimeframe, };
|
|
480
484
|
export { toCOABalancesOrderStrict, newBalancesFilter, newBalancesFilterForDateRange, };
|
|
481
485
|
export { newBalancesFilterClassesView };
|
|
@@ -529,7 +533,7 @@ export { fetchUserListByType, getUserList };
|
|
|
529
533
|
export { fetchAllPeopleRequiredViews, fetchPeoplePage, fetchPeople, deletePerson, resendInvite, changeZeniPersonRoles, invitePeople, inviteZeniPeople, updatePeopleUIState, peopleSaveUpdates, resetUpdateErrorMessage, peopleSaveDataInLocalStore, peopleClearDataInLocalStore, getPeople, getPeopleLocalData, initializeEditPerson, };
|
|
530
534
|
export { REMINDER_NOTIFICATION_TYPES, NOTIFICATION_MODES, clearSettingsView, fetchMyProfileView, fetchMyProfile, fetchBankConnectionsView, fetchBillingAccountsView, fetchCompanyBillingAddress, saveCompanyBillingAddress, fetchNotificationSettings, saveNotificationSettings, updateNotificationSettingsLocalData, fetchNotificationSettingsView, resetNotificationSettingsLocalData, resetNotificationSettingsUpdateStatus, refreshQBOData, updateSettingsViewUIState, isMonthEndNotificationsSectionVisibleOnSettingsPage, getNotificationSettingsView, getNotificationSettings, getBillingAccountsViewDetails, getMyProfileView, getMyBankConnectionsDetails, isAccountingTabVisible, isApprovalRulesTabVisible, isBankConnectionsTabVisible, isBillingTabVisible, isBusinessVerificationTabVisible, isCompanyDetailsTabVisible, isIntegrationsTabVisible, isSettingsVisible, isMyBankConnectionsTabVisible, isNotificationsTabVisible, isPerformanceTabVisible, isRemindersSectionVisibleOnSettingsPage, updateMyProfile, updateMyProfileLocalData, initializeMyProfileLocalData, };
|
|
531
535
|
export { fetchBalanceSheet, getBalanceSheet, getBalanceSheetFetchState, getBalanceSheetForFullDataAvailableRange, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState, typeOfBalanceSheetRootSection, isBalanceSheetReportViewSectionID, isBalanceSheetReportViewCalculatedSectionID, fetchBalanceSheetForTimeframe, };
|
|
532
|
-
export { fetchBalanceSheetClassesView, fetchBalanceSheetForTimeframeClassesView, resetBalanceSheetClassesNodeCollapseState, updateBalanceSheetClassesToFilterOut, updateBalanceSheetClassesViewAccountViewMode, updateBalanceSheetClassesViewUIState, getBalanceSheetClassesView, };
|
|
536
|
+
export { fetchCashFlowClassesView, fetchCashFlowForTimeframeClassesView, fetchCashFlowForTimeframeProjectView, fetchCashFlowProjectView, getCashFlowClassesView, getCashFlowProjectView, resetCashFlowClassesNodeCollapseState, resetCashFlowProjectNodeCollapseState, updateCashFlowClassesToFilterOut, updateCashFlowClassesViewAccountViewMode, updateCashFlowClassesViewUIState, updateCashFlowProjectViewAccountViewMode, updateCashFlowProjectViewUIState, updateCashFlowProjectsToFilterOut, fetchBalanceSheetClassesView, fetchBalanceSheetForTimeframeClassesView, resetBalanceSheetClassesNodeCollapseState, updateBalanceSheetClassesToFilterOut, updateBalanceSheetClassesViewAccountViewMode, updateBalanceSheetClassesViewUIState, getBalanceSheetClassesView, };
|
|
533
537
|
export { fetchBalanceSheetForTimeframeProjectView, fetchBalanceSheetProjectView, resetBalanceSheetProjectNodeCollapseState, updateBalanceSheetProjectViewAccountViewMode, updateBalanceSheetProjectViewUIState, updateBalanceSheetProjectsToFilterOut, getBalanceSheetProjectView, };
|
|
534
538
|
export { fetchCashFlow, getCashFlow, getCashFlowReportFetchState, resetCashFlowNodeCollapseState, updateCashFlowUIState, typeOfCashFlowRootSection, isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewSectionID, isCashFlowReportViewCalculatedSectionType1ID, fetchCashFlowForTimeframe, };
|
|
535
539
|
export { getFinanceStatement, getReportsResyncView, fetchFinanceStatement, updateCOABalancesRange, updateSelectedReportId, updateDownloadState, updateFinanceStatementAdditionalBalancesSelection, updateFinanceStatementDisplayOrder, updateFinanceStatementFormat, };
|
|
@@ -769,8 +773,7 @@ export { getInvoicingCustomerFormView } from './view/invoicing/editInvoicingCust
|
|
|
769
773
|
export { fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
|
|
770
774
|
export { INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE, entityToInvoicingSubscriptionFormLocalData, initialInvoicingSubscriptionFormLocalData, invoicingSubscriptionTodayIso, toInvoicingSubscriptionQuantity, } from './view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig';
|
|
771
775
|
export { getEditInvoicingSubscriptionDetailViewState, getInvoicingSubscriptionFormView, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
|
|
772
|
-
export { archiveInvoicingCatalogSubFamily,
|
|
773
|
-
export { catalogDetailEditValuesToSavePayload, createSubFamilyFormToPayload, planToCatalogDetailEditValues, productToCreateSubFamilyFormValues, } from './view/invoicing/editInvoicingCatalogItemDetailView/catalogDetailEditPayload';
|
|
776
|
+
export { archiveInvoicingCatalogSubFamily, resetEditInvoicingCatalogItemDetailView, submitInvoicingCatalogItemForm, updateInvoicingCatalogItemFormDraft, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer';
|
|
774
777
|
export { INVOICING_CATALOG_APPLICABILITY_VALUES, INVOICING_CATALOG_PRICING_MODEL_VALUES, INVOICING_CATALOG_PRORATION_VALUES, INVOICING_CATALOG_TIER_TYPE_VALUES, blankInvoicingCatalogSubFamily, blankInvoicingCatalogTier, entityToInvoicingCatalogItemFormLocalData, invoicingProductToCatalogItemFormSubFamily, initialInvoicingCatalogItemFormLocalData, isTieredCatalogPricingModel, } from './view/invoicing/editInvoicingCatalogItemDetailView/invoicingCatalogItemFormConfig';
|
|
775
778
|
export { getEditInvoicingCatalogItemDetailViewState, getInvoicingApplicableCatalogItemOptions, getInvoicingCatalogItemFormView, getSavedInvoicingCatalogItemId, getSavedInvoicingCatalogItemKind, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewSelector';
|
|
776
779
|
export { resetEditInvoicingCouponDetailView, saveInvoicingCoupon, submitInvoicingCouponForm, updateInvoicingCouponFormDraft, } from './view/invoicing/editInvoicingCouponDetailView/editInvoicingCouponDetailViewReducer';
|
|
@@ -798,8 +801,8 @@ export { removeInvoicingCustomer, updateInvoicingCustomers, } from './entity/inv
|
|
|
798
801
|
export { fetchInvoicingCustomerCounts, fetchInvoicingCustomerList, fetchInvoicingCustomerListPage, setInvoicingCustomerActiveTab, updateInvoicingCustomerFilters, } from './view/invoicing/invoicingCustomerListView/invoicingCustomerListViewReducer';
|
|
799
802
|
export { ALL_INVOICING_CUSTOMER_SORT_KEYS, ALL_INVOICING_CUSTOMER_TAB_IDS, INVOICING_CUSTOMER_COLUMNS, } from './view/invoicing/invoicingCustomerListView/invoicingCustomerListViewState';
|
|
800
803
|
export { getInvoicingCustomerListView } from './view/invoicing/invoicingCustomerListView/invoicingCustomerListViewSelector';
|
|
801
|
-
export { fetchInvoicingCustomerDetail, fetchInvoicingCustomerDetailPage, } from './view/invoicing/
|
|
802
|
-
export {
|
|
804
|
+
export { fetchInvoicingCustomerDetail, fetchInvoicingCustomerDetailPage, } from './view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewReducer';
|
|
805
|
+
export { getInvoicingCustomerRecord } from './view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewSelector';
|
|
803
806
|
// ── Invoicing: customer payment methods ───────────────────────────────────────
|
|
804
807
|
export { createInvoicingSetupIntent, fetchInvoicingPlaidLinkToken, resetInvoicingCustomerPaymentMethod, saveInvoicingPaymentMethod, sendInvoicingPaymentLink, } from './view/invoicing/customerPaymentMethod/customerPaymentMethodReducer';
|
|
805
808
|
export { getInvoicingPaymentLinkSendState, getInvoicingPaymentMethodSaveState, getInvoicingPlaidLinkToken, getInvoicingPlaidLinkTokenFetchState, getInvoicingSentPaymentLinkEmail, getInvoicingSentPaymentLinkMagicUrl, getInvoicingSetupIntent, getInvoicingSetupIntentFetchState, } from './view/invoicing/customerPaymentMethod/customerPaymentMethodSelector';
|
|
@@ -810,8 +813,8 @@ export { removeInvoicingSubscription, updateInvoicingSubscriptions, } from './en
|
|
|
810
813
|
export { fetchInvoicingSubscriptionCounts, fetchInvoicingSubscriptionList, fetchInvoicingSubscriptionListPage, setInvoicingSubscriptionActiveTab, updateInvoicingSubscriptionFilters, } from './view/invoicing/invoicingSubscriptionListView/invoicingSubscriptionListViewReducer';
|
|
811
814
|
export { ALL_INVOICING_SUBSCRIPTION_SORT_KEYS, ALL_INVOICING_SUBSCRIPTION_TAB_IDS, INVOICING_SUBSCRIPTION_COLUMNS, } from './view/invoicing/invoicingSubscriptionListView/invoicingSubscriptionListViewState';
|
|
812
815
|
export { getInvoicingSubscriptionListView } from './view/invoicing/invoicingSubscriptionListView/invoicingSubscriptionListViewSelector';
|
|
813
|
-
export { fetchInvoicingSubscriptionDetail } from './view/invoicing/
|
|
814
|
-
export { getInvoicingSubscriptionById,
|
|
816
|
+
export { fetchInvoicingSubscriptionDetail } from './view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewReducer';
|
|
817
|
+
export { getInvoicingSubscriptionById, getInvoicingSubscriptionRecord, } from './view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewSelector';
|
|
815
818
|
// ── Invoicing: payments (transactions) ────────────────────────────────────────
|
|
816
819
|
export { removeInvoicingTransaction, updateInvoicingTransactions, } from './entity/invoicing/invoicingTransaction/invoicingTransactionReducer';
|
|
817
820
|
export { fetchInvoicingTransactionList, fetchInvoicingTransactionListPage, setInvoicingTransactionActiveTab, updateInvoicingTransactionFilters, } from './view/invoicing/invoicingTransactionListView/invoicingTransactionListViewReducer';
|
|
@@ -832,8 +835,8 @@ export { fetchInvoicingCouponCounts, fetchInvoicingCouponList, fetchInvoicingCou
|
|
|
832
835
|
export { ALL_INVOICING_COUPON_SORT_KEYS, ALL_INVOICING_COUPON_TAB_IDS, INVOICING_COUPON_COLUMNS, } from './view/invoicing/couponView/couponViewState';
|
|
833
836
|
export { getInvoicingCouponCounts, getInvoicingCouponListFetchState, getInvoicingCouponListFilters, getInvoicingCouponListHasMore, getInvoicingCouponListItems, getInvoicingCouponListNextCursor, getInvoicingCouponListView, } from './view/invoicing/couponView/couponViewSelector';
|
|
834
837
|
export { getInvoicingCouponById } from './entity/invoicing/coupon/couponSelector';
|
|
835
|
-
export { fetchInvoicingCouponDetail } from './view/invoicing/
|
|
836
|
-
export {
|
|
838
|
+
export { fetchInvoicingCouponDetail } from './view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewReducer';
|
|
839
|
+
export { getInvoicingCouponRecord } from './view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewSelector';
|
|
837
840
|
// ── Invoicing: dunning ────────────────────────────────────────────────────────
|
|
838
841
|
export { removeInvoicingDunningCase, updateInvoicingDunningCases, } from './entity/invoicing/dunningCase/dunningCaseReducer';
|
|
839
842
|
export { fetchInvoicingDunningCaseCounts, fetchInvoicingDunningCaseList, fetchInvoicingDunningCaseListPage, setInvoicingDunningCaseActiveTab, updateInvoicingDunningCaseFilters, } from './view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewReducer';
|
|
@@ -847,8 +850,8 @@ export { removeInvoicingProduct, updateInvoicingProducts, } from './entity/invoi
|
|
|
847
850
|
export { fetchInvoicingCatalogCounts, fetchInvoicingCatalogListPage, fetchInvoicingCatalogPlanList, fetchInvoicingCatalogProductList, updateInvoicingCatalogPlanFilters, updateInvoicingCatalogProductFilters, } from './view/invoicing/invoicingCatalogListView/invoicingCatalogListViewReducer';
|
|
848
851
|
export { ALL_INVOICING_PRODUCT_SORT_KEYS, INVOICING_PRODUCT_COLUMNS, } from './view/invoicing/invoicingCatalogListView/invoicingCatalogListViewState';
|
|
849
852
|
export { getInvoicingCatalogListView } from './view/invoicing/invoicingCatalogListView/invoicingCatalogListViewSelector';
|
|
850
|
-
export { fetchInvoicingCatalogItemDetail } from './view/invoicing/
|
|
851
|
-
export {
|
|
853
|
+
export { fetchInvoicingCatalogItemDetail } from './view/invoicing/invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewReducer';
|
|
854
|
+
export { getInvoicingCatalogItemRecord } from './view/invoicing/invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewSelector';
|
|
852
855
|
export { getInvoicingPlanById } from './entity/invoicing/plan/planSelector';
|
|
853
856
|
export { getInvoicingProductById } from './entity/invoicing/product/productSelector';
|
|
854
857
|
// ── Invoicing: settings ───────────────────────────────────────────────────────
|
package/lib/esm/reducer.js
CHANGED
|
@@ -99,6 +99,8 @@ import cardBalance, { initialState as initialCardBalanceState, } from './view/ca
|
|
|
99
99
|
import cardPaymentView, { initialState as initialCardPaymentViewState, } from './view/cardPayment/cardPaymentViewReducer';
|
|
100
100
|
import cashBalance, { initialState as initialCashBalanceState, } from './view/cashBalance/cashBalanceReducer';
|
|
101
101
|
import cashFlow, { initialState as initialCashFlowState, } from './view/cashFlow/cashFlowReducer';
|
|
102
|
+
import cashFlowClassesView, { initialState as initialCashFlowClassesViewState, } from './view/cashFlowClassesView/cashFlowClassesViewReducer';
|
|
103
|
+
import cashFlowProjectView, { initialState as initialCashFlowProjectViewState, } from './view/cashFlowProjectView/cashFlowProjectViewReducer';
|
|
102
104
|
import cashInCashOut, { initialState as initialCashInCashOutState, } from './view/cashInCashOut/cashInCashOutReducer';
|
|
103
105
|
import cashPosition, { initialState as initialCashPositionState, } from './view/cashPosition/cashPositionReducer';
|
|
104
106
|
import classList, { initialState as initialClassListState, } from './view/classList/classListReducer';
|
|
@@ -146,19 +148,19 @@ import editInvoicingSubscriptionDetailView, { initialState as initialEditInvoici
|
|
|
146
148
|
import invoicingInvoiceAction, { initialState as initialInvoicingInvoiceActionState, } from './view/invoicing/invoiceAction/invoiceActionReducer';
|
|
147
149
|
import invoicingInvoiceDetail, { initialState as initialInvoicingInvoiceDetailState, } from './view/invoicing/invoiceDetail/invoiceDetailReducer';
|
|
148
150
|
import invoicingInvoiceList, { initialState as initialInvoicingInvoiceListState, } from './view/invoicing/invoiceList/invoiceListReducer';
|
|
149
|
-
import
|
|
151
|
+
import invoicingCatalogItemRecordView, { initialState as initialInvoicingCatalogItemRecordViewState, } from './view/invoicing/invoicingCatalogItemRecordView/invoicingCatalogItemRecordViewReducer';
|
|
150
152
|
import invoicingCatalogListView, { initialState as initialInvoicingCatalogListViewState, } from './view/invoicing/invoicingCatalogListView/invoicingCatalogListViewReducer';
|
|
151
153
|
import invoicingConfigView, { initialState as initialInvoicingConfigViewState, } from './view/invoicing/invoicingConfigView/invoicingConfigViewReducer';
|
|
152
|
-
import
|
|
154
|
+
import invoicingCouponRecordView, { initialState as initialInvoicingCouponRecordViewState, } from './view/invoicing/invoicingCouponRecordView/invoicingCouponRecordViewReducer';
|
|
153
155
|
import invoicingCreditNoteDetailView, { initialState as initialInvoicingCreditNoteDetailViewState, } from './view/invoicing/invoicingCreditNoteDetailView/invoicingCreditNoteDetailViewReducer';
|
|
154
156
|
import invoicingCreditNoteListView, { initialState as initialInvoicingCreditNoteListViewState, } from './view/invoicing/invoicingCreditNoteListView/invoicingCreditNoteListViewReducer';
|
|
155
|
-
import
|
|
157
|
+
import invoicingCustomerRecordView, { initialState as initialInvoicingCustomerRecordViewState, } from './view/invoicing/invoicingCustomerRecordView/invoicingCustomerRecordViewReducer';
|
|
156
158
|
import invoicingCustomerListView, { initialState as initialInvoicingCustomerListViewState, } from './view/invoicing/invoicingCustomerListView/invoicingCustomerListViewReducer';
|
|
157
159
|
import invoicingDunningCaseDetailView, { initialState as initialInvoicingDunningCaseDetailViewState, } from './view/invoicing/invoicingDunningCaseDetailView/invoicingDunningCaseDetailViewReducer';
|
|
158
160
|
import invoicingDunningCaseListView, { initialState as initialInvoicingDunningCaseListViewState, } from './view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewReducer';
|
|
159
161
|
import invoicingOverview, { initialState as initialInvoicingOverviewState, } from './view/invoicing/invoicingOverview/invoicingOverviewReducer';
|
|
160
162
|
import invoicingQboView, { initialState as initialInvoicingQboViewState, } from './view/invoicing/invoicingQboView/invoicingQboViewReducer';
|
|
161
|
-
import
|
|
163
|
+
import invoicingSubscriptionRecordView, { initialState as initialInvoicingSubscriptionRecordViewState, } from './view/invoicing/invoicingSubscriptionRecordView/invoicingSubscriptionRecordViewReducer';
|
|
162
164
|
import invoicingSubscriptionListView, { initialState as initialInvoicingSubscriptionListViewState, } from './view/invoicing/invoicingSubscriptionListView/invoicingSubscriptionListViewReducer';
|
|
163
165
|
import invoicingTransactionDetailView, { initialState as initialInvoicingTransactionDetailViewState, } from './view/invoicing/invoicingTransactionDetailView/invoicingTransactionDetailViewReducer';
|
|
164
166
|
import invoicingTransactionListView, { initialState as initialInvoicingTransactionListViewState, } from './view/invoicing/invoicingTransactionListView/invoicingTransactionListViewReducer';
|
|
@@ -397,6 +399,8 @@ const initialViewsState = {
|
|
|
397
399
|
cardUserOnboardingState: initialCardUserOnboardingState,
|
|
398
400
|
cashbackDetailState: initialCashbackDetailState,
|
|
399
401
|
cashBalanceState: initialCashBalanceState,
|
|
402
|
+
cashFlowClassesViewState: initialCashFlowClassesViewState,
|
|
403
|
+
cashFlowProjectViewState: initialCashFlowProjectViewState,
|
|
400
404
|
cashFlowState: initialCashFlowState,
|
|
401
405
|
cashInCashOutState: initialCashInCashOutState,
|
|
402
406
|
cashPositionState: initialCashPositionState,
|
|
@@ -446,10 +450,10 @@ const initialViewsState = {
|
|
|
446
450
|
invoicingOverviewState: initialInvoicingOverviewState,
|
|
447
451
|
invoicingAuditViewState: initialInvoicingAuditViewState,
|
|
448
452
|
editInvoicingCatalogItemDetailViewState: initialEditInvoicingCatalogItemDetailViewState,
|
|
449
|
-
|
|
453
|
+
invoicingCatalogItemRecordViewState: initialInvoicingCatalogItemRecordViewState,
|
|
450
454
|
invoicingCatalogListViewState: initialInvoicingCatalogListViewState,
|
|
451
455
|
editInvoicingCouponDetailViewState: initialEditInvoicingCouponDetailViewState,
|
|
452
|
-
|
|
456
|
+
invoicingCouponRecordViewState: initialInvoicingCouponRecordViewState,
|
|
453
457
|
invoicingCouponViewState: initialInvoicingCouponViewState,
|
|
454
458
|
invoicingCreditNoteDetailViewState: initialInvoicingCreditNoteDetailViewState,
|
|
455
459
|
invoicingCreditNoteListViewState: initialInvoicingCreditNoteListViewState,
|
|
@@ -457,7 +461,7 @@ const initialViewsState = {
|
|
|
457
461
|
invoicingRecordPaymentState: initialInvoicingRecordPaymentState,
|
|
458
462
|
invoicingIssueCreditNoteState: initialInvoicingIssueCreditNoteState,
|
|
459
463
|
invoicingCreateCreditNoteState: initialInvoicingCreateCreditNoteState,
|
|
460
|
-
|
|
464
|
+
invoicingCustomerRecordViewState: initialInvoicingCustomerRecordViewState,
|
|
461
465
|
invoicingCustomerListViewState: initialInvoicingCustomerListViewState,
|
|
462
466
|
invoicingCustomerPaymentMethodState: initialInvoicingCustomerPaymentMethodState,
|
|
463
467
|
invoicingPromotionalCreditActionState: initialInvoicingPromotionalCreditActionState,
|
|
@@ -477,7 +481,7 @@ const initialViewsState = {
|
|
|
477
481
|
invoicingCatalogActionState: initialInvoicingCatalogActionState,
|
|
478
482
|
invoicingDiscountActionState: initialInvoicingDiscountActionState,
|
|
479
483
|
invoicingSubscriptionActionState: initialInvoicingSubscriptionActionState,
|
|
480
|
-
|
|
484
|
+
invoicingSubscriptionRecordViewState: initialInvoicingSubscriptionRecordViewState,
|
|
481
485
|
invoicingSubscriptionListViewState: initialInvoicingSubscriptionListViewState,
|
|
482
486
|
editInvoicingSubscriptionDetailViewState: initialEditInvoicingSubscriptionDetailViewState,
|
|
483
487
|
invoicingTransactionDetailViewState: initialInvoicingTransactionDetailViewState,
|
|
@@ -691,6 +695,8 @@ const viewReducers = {
|
|
|
691
695
|
cardUserOnboardingState: cardUserOnboarding,
|
|
692
696
|
cashbackDetailState: cashbackDetail,
|
|
693
697
|
cashBalanceState: cashBalance,
|
|
698
|
+
cashFlowClassesViewState: cashFlowClassesView,
|
|
699
|
+
cashFlowProjectViewState: cashFlowProjectView,
|
|
694
700
|
cashFlowState: cashFlow,
|
|
695
701
|
cashInCashOutState: cashInCashOut,
|
|
696
702
|
cashPositionState: cashPosition,
|
|
@@ -740,10 +746,10 @@ const viewReducers = {
|
|
|
740
746
|
invoicingOverviewState: invoicingOverview,
|
|
741
747
|
invoicingAuditViewState: invoicingAuditView,
|
|
742
748
|
editInvoicingCatalogItemDetailViewState: editInvoicingCatalogItemDetailView,
|
|
743
|
-
|
|
749
|
+
invoicingCatalogItemRecordViewState: invoicingCatalogItemRecordView,
|
|
744
750
|
invoicingCatalogListViewState: invoicingCatalogListView,
|
|
745
751
|
editInvoicingCouponDetailViewState: editInvoicingCouponDetailView,
|
|
746
|
-
|
|
752
|
+
invoicingCouponRecordViewState: invoicingCouponRecordView,
|
|
747
753
|
invoicingCouponViewState: invoicingCouponView,
|
|
748
754
|
invoicingCreditNoteDetailViewState: invoicingCreditNoteDetailView,
|
|
749
755
|
invoicingCreditNoteListViewState: invoicingCreditNoteListView,
|
|
@@ -751,7 +757,7 @@ const viewReducers = {
|
|
|
751
757
|
invoicingRecordPaymentState: invoicingRecordPayment,
|
|
752
758
|
invoicingIssueCreditNoteState: invoicingIssueCreditNote,
|
|
753
759
|
invoicingCreateCreditNoteState: invoicingCreateCreditNote,
|
|
754
|
-
|
|
760
|
+
invoicingCustomerRecordViewState: invoicingCustomerRecordView,
|
|
755
761
|
invoicingCustomerListViewState: invoicingCustomerListView,
|
|
756
762
|
invoicingCustomerPaymentMethodState: invoicingCustomerPaymentMethod,
|
|
757
763
|
invoicingPromotionalCreditActionState: invoicingPromotionalCreditAction,
|
|
@@ -771,7 +777,7 @@ const viewReducers = {
|
|
|
771
777
|
invoicingCatalogActionState: invoicingCatalogAction,
|
|
772
778
|
invoicingDiscountActionState: invoicingDiscountAction,
|
|
773
779
|
invoicingSubscriptionActionState: invoicingSubscriptionAction,
|
|
774
|
-
|
|
780
|
+
invoicingSubscriptionRecordViewState: invoicingSubscriptionRecordView,
|
|
775
781
|
invoicingSubscriptionListViewState: invoicingSubscriptionListView,
|
|
776
782
|
editInvoicingSubscriptionDetailViewState: editInvoicingSubscriptionDetailView,
|
|
777
783
|
invoicingTransactionDetailViewState: invoicingTransactionDetailView,
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { ALL_CASHFLOW_FINANCING_ACTIVITIES_IDS, ALL_CASHFLOW_INVESTING_ACTIVITIES_IDS, ALL_CASHFLOW_OPERATING_ACTIVITIES_IDS, cashFlowSectionIdsInOrder, } from './cashFlowSelectorTypes';
|
|
2
|
+
// Opening and closing cash balances are omitted from the grouped views: the
|
|
3
|
+
// backend cannot attribute a bank balance to a class or project (see
|
|
4
|
+
// cash_flow_group_by_class_report_v2), so the response does not carry them.
|
|
5
|
+
export const CASH_FLOW_GROUPED_HIDDEN_IDS = [
|
|
6
|
+
'cashAndEquivalentsOpeningBalance',
|
|
7
|
+
'cashAndEquivalentsClosingBalance',
|
|
8
|
+
];
|
|
9
|
+
const isShownInGroupedView = (id) => CASH_FLOW_GROUPED_HIDDEN_IDS.includes(id) === false;
|
|
10
|
+
const byDisplayOrder = (a, b) => cashFlowSectionIdsInOrder.indexOf(a) - cashFlowSectionIdsInOrder.indexOf(b);
|
|
11
|
+
export const CASH_FLOW_GROUPED_OPERATING_IDS_IN_ORDER = [
|
|
12
|
+
...ALL_CASHFLOW_OPERATING_ACTIVITIES_IDS,
|
|
13
|
+
]
|
|
14
|
+
.filter(isShownInGroupedView)
|
|
15
|
+
.sort(byDisplayOrder);
|
|
16
|
+
export const CASH_FLOW_GROUPED_INVESTING_IDS_IN_ORDER = [
|
|
17
|
+
...ALL_CASHFLOW_INVESTING_ACTIVITIES_IDS,
|
|
18
|
+
]
|
|
19
|
+
.filter(isShownInGroupedView)
|
|
20
|
+
.sort(byDisplayOrder);
|
|
21
|
+
export const CASH_FLOW_GROUPED_FINANCING_IDS_IN_ORDER = [
|
|
22
|
+
...ALL_CASHFLOW_FINANCING_ACTIVITIES_IDS,
|
|
23
|
+
]
|
|
24
|
+
.filter(isShownInGroupedView)
|
|
25
|
+
.sort(byDisplayOrder);
|
|
26
|
+
export const CASH_FLOW_GROUPED_IDS_IN_ORDER = cashFlowSectionIdsInOrder.filter(isShownInGroupedView);
|
|
27
|
+
// The grouped response carries per-class/per-project balances only for these
|
|
28
|
+
// three; every other row on the report is a rollup computed in the selectors.
|
|
29
|
+
export const CASH_FLOW_GROUPED_SECTION_IDS = [
|
|
30
|
+
'operatingActivitiesAdjustments',
|
|
31
|
+
'investingActivities',
|
|
32
|
+
'financingActivities',
|
|
33
|
+
];
|
|
34
|
+
export const CASH_FLOW_GROUPED_CALCULATED_IDS = [
|
|
35
|
+
'operatingActivitiesNetIncome',
|
|
36
|
+
'operatingActivitiesTotal',
|
|
37
|
+
'changeInCashAndEquivalents',
|
|
38
|
+
];
|
|
39
|
+
/**
|
|
40
|
+
* Rows rendered with a per-class/per-project breakdown: the account sections
|
|
41
|
+
* plus the aggregates the response groups. Derived from the two lists above so a
|
|
42
|
+
* new grouped aggregate only has to be added once.
|
|
43
|
+
*/
|
|
44
|
+
export const CASH_FLOW_GROUPED_BREAKDOWN_IDS = [
|
|
45
|
+
...CASH_FLOW_GROUPED_SECTION_IDS,
|
|
46
|
+
...CASH_FLOW_GROUPED_CALCULATED_IDS,
|
|
47
|
+
];
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { from } from 'rxjs';
|
|
2
|
+
import { filter, switchMap } from 'rxjs/operators';
|
|
3
|
+
import { fetchCashFlowClassesView, fetchCashFlowForTimeframeClassesView, } from './cashFlowClassesViewReducer';
|
|
4
|
+
export const fetchCashFlowClassesViewEpic = (actions$, state) => actions$.pipe(filter(fetchCashFlowClassesView.match), switchMap((action) => {
|
|
5
|
+
const { cacheOverride } = action.payload;
|
|
6
|
+
if (cacheOverride === true) {
|
|
7
|
+
return from([
|
|
8
|
+
fetchCashFlowForTimeframeClassesView('month', true),
|
|
9
|
+
fetchCashFlowForTimeframeClassesView('quarter', true),
|
|
10
|
+
fetchCashFlowForTimeframeClassesView('year', true),
|
|
11
|
+
]);
|
|
12
|
+
}
|
|
13
|
+
else {
|
|
14
|
+
const fetchActions = [];
|
|
15
|
+
const classFetchState = state.value.cashFlowClassesViewState.fetchState;
|
|
16
|
+
if (classFetchState['month'].fetchState !== 'In-Progress' &&
|
|
17
|
+
classFetchState['month'].fetchState !== 'Completed') {
|
|
18
|
+
fetchActions.push(fetchCashFlowForTimeframeClassesView('month'));
|
|
19
|
+
}
|
|
20
|
+
if (classFetchState['quarter'].fetchState !== 'In-Progress' &&
|
|
21
|
+
classFetchState['quarter'].fetchState !== 'Completed') {
|
|
22
|
+
fetchActions.push(fetchCashFlowForTimeframeClassesView('quarter'));
|
|
23
|
+
}
|
|
24
|
+
if (classFetchState['year'].fetchState !== 'In-Progress' &&
|
|
25
|
+
classFetchState['year'].fetchState !== 'Completed') {
|
|
26
|
+
fetchActions.push(fetchCashFlowForTimeframeClassesView('year'));
|
|
27
|
+
}
|
|
28
|
+
return from(fetchActions);
|
|
29
|
+
}
|
|
30
|
+
}));
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
import { createSlice } from '@reduxjs/toolkit';
|
|
2
|
+
import { mapReportPayloadV2ToReportV2 } from '../../commonPayloadTypes/v2/viewAndReportPayloadv2';
|
|
3
|
+
import { geNestedClassIDHierarchyForReport } from '../../commonStateTypes/classesView/getNestedClassIDHierarchyForReport';
|
|
4
|
+
import { toClassMetadata } from '../../entity/class/classPayload';
|
|
5
|
+
import { clearAll } from '../../rootActions';
|
|
6
|
+
export const initialState = {
|
|
7
|
+
classHierarchy: [],
|
|
8
|
+
bookCloseDate: undefined,
|
|
9
|
+
fetchState: {
|
|
10
|
+
month: {
|
|
11
|
+
fetchState: 'Not-Started',
|
|
12
|
+
error: undefined,
|
|
13
|
+
},
|
|
14
|
+
quarter: {
|
|
15
|
+
fetchState: 'Not-Started',
|
|
16
|
+
error: undefined,
|
|
17
|
+
},
|
|
18
|
+
year: {
|
|
19
|
+
fetchState: 'Not-Started',
|
|
20
|
+
error: undefined,
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
uiState: {
|
|
24
|
+
nodeCollapseState: {},
|
|
25
|
+
scrollPosition: undefined,
|
|
26
|
+
accountViewMode: 'account_group',
|
|
27
|
+
classesToFilterOut: [],
|
|
28
|
+
},
|
|
29
|
+
firstMonthOfFY: 1,
|
|
30
|
+
reportId: 'cash_flow_by_classes',
|
|
31
|
+
reportTitle: 'cash_flow_by_classes',
|
|
32
|
+
};
|
|
33
|
+
const cashFlowClassesView = createSlice({
|
|
34
|
+
name: 'cashFlowClassesView',
|
|
35
|
+
initialState,
|
|
36
|
+
reducers: {
|
|
37
|
+
fetchCashFlowClassesView: {
|
|
38
|
+
prepare(cacheOverride = false) {
|
|
39
|
+
return { payload: { cacheOverride } };
|
|
40
|
+
},
|
|
41
|
+
reducer(
|
|
42
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
43
|
+
_draft,
|
|
44
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
45
|
+
_action) {
|
|
46
|
+
// nothing to do here
|
|
47
|
+
},
|
|
48
|
+
},
|
|
49
|
+
fetchCashFlowForTimeframeClassesView: {
|
|
50
|
+
prepare(timeframe, cacheOverride = false) {
|
|
51
|
+
return { payload: { timeframe, cacheOverride } };
|
|
52
|
+
},
|
|
53
|
+
reducer(draft, action) {
|
|
54
|
+
const timeframe = action.payload.timeframe;
|
|
55
|
+
draft.fetchState[timeframe].fetchState = 'In-Progress';
|
|
56
|
+
draft.fetchState[timeframe].error = undefined;
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
updateCashFlowForTimeframeClassesView(draft, action) {
|
|
60
|
+
doUpdateCashFlowClassesView(draft, action.payload.timeframe, action.payload.report);
|
|
61
|
+
},
|
|
62
|
+
updateCashFlowForTimeframeClassesViewFailure: {
|
|
63
|
+
prepare(error, timeframe) {
|
|
64
|
+
return {
|
|
65
|
+
payload: {
|
|
66
|
+
error,
|
|
67
|
+
timeframe,
|
|
68
|
+
},
|
|
69
|
+
};
|
|
70
|
+
},
|
|
71
|
+
reducer(draft, action) {
|
|
72
|
+
draft.fetchState[action.payload.timeframe] = {
|
|
73
|
+
fetchState: 'Error',
|
|
74
|
+
error: action.payload.error,
|
|
75
|
+
};
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
updateCashFlowClassesToFilterOut(draft, action) {
|
|
79
|
+
draft.uiState.classesToFilterOut = action.payload.classesToFilterOut;
|
|
80
|
+
},
|
|
81
|
+
updateCashFlowClassesViewUIState(draft, action) {
|
|
82
|
+
const { nodeCollapseState, scrollPosition, resetLeftScroll } = action.payload;
|
|
83
|
+
if (nodeCollapseState != null) {
|
|
84
|
+
draft.uiState.nodeCollapseState = Object.assign({}, draft.uiState.nodeCollapseState, {
|
|
85
|
+
[nodeCollapseState.nodeId]: nodeCollapseState.isCollapsed,
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
// Mutually exclusive: resetLeftScroll clears only scrollLeft from the
|
|
89
|
+
// recorded position, scrollPosition replaces the whole record.
|
|
90
|
+
if (resetLeftScroll === true && draft.uiState.scrollPosition != null) {
|
|
91
|
+
draft.uiState.scrollPosition.scrollLeft = undefined;
|
|
92
|
+
}
|
|
93
|
+
else if (scrollPosition != null) {
|
|
94
|
+
draft.uiState.scrollPosition = scrollPosition;
|
|
95
|
+
}
|
|
96
|
+
},
|
|
97
|
+
updateCashFlowClassesViewAccountViewMode(draft, action) {
|
|
98
|
+
draft.uiState.accountViewMode = action.payload.viewMode;
|
|
99
|
+
},
|
|
100
|
+
resetCashFlowClassesNodeCollapseState(draft) {
|
|
101
|
+
draft.uiState.nodeCollapseState = {};
|
|
102
|
+
},
|
|
103
|
+
},
|
|
104
|
+
extraReducers: (builder) => {
|
|
105
|
+
builder.addCase(clearAll, (draft) => {
|
|
106
|
+
Object.assign(draft, initialState);
|
|
107
|
+
});
|
|
108
|
+
},
|
|
109
|
+
});
|
|
110
|
+
export const { fetchCashFlowClassesView, fetchCashFlowForTimeframeClassesView, updateCashFlowForTimeframeClassesView, updateCashFlowForTimeframeClassesViewFailure, updateCashFlowClassesToFilterOut, updateCashFlowClassesViewUIState, updateCashFlowClassesViewAccountViewMode, resetCashFlowClassesNodeCollapseState, } = cashFlowClassesView.actions;
|
|
111
|
+
export default cashFlowClassesView.reducer;
|
|
112
|
+
const doUpdateCashFlowClassesView = (draft, timeframe, cashFlowReport) => {
|
|
113
|
+
const report = mapReportPayloadV2ToReportV2(cashFlowReport.report);
|
|
114
|
+
draft.currency = report.currency;
|
|
115
|
+
draft.dataAvailable = report.dataAvailable;
|
|
116
|
+
draft.firstMonthOfFY = report.firstMonthOfFY;
|
|
117
|
+
draft.bookCloseDate = report.bookCloseDate;
|
|
118
|
+
draft.status = report.status;
|
|
119
|
+
draft.fetchState[timeframe].fetchState = 'Completed';
|
|
120
|
+
draft.fetchState[timeframe].error = undefined;
|
|
121
|
+
const classMetadata = cashFlowReport.report.classes.map((eachClass) => toClassMetadata(eachClass));
|
|
122
|
+
// Populated once and then left alone, so a per-timeframe response cannot
|
|
123
|
+
// clobber a hierarchy built from a full one. A class added mid-session is
|
|
124
|
+
// therefore not picked up until the store is cleared, even by a hard refresh —
|
|
125
|
+
// the same trade-off profitAndLossClassesViewReducer makes.
|
|
126
|
+
if (draft.classHierarchy.length <= 0) {
|
|
127
|
+
draft.classHierarchy = geNestedClassIDHierarchyForReport(classMetadata);
|
|
128
|
+
}
|
|
129
|
+
};
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { getCOABalances } from '../../commonStateTypes/coaBalance/getCOABalancesSlice';
|
|
2
|
+
import { reduceFetchStateParallelTimeframes } from '../../commonStateTypes/reduceFetchState';
|
|
3
|
+
import { getSectionClassesViewReport } from '../../entity/sectionClassesViewV2/sectionClassesViewSelector';
|
|
4
|
+
import { CASH_FLOW_GROUPED_BREAKDOWN_IDS, CASH_FLOW_GROUPED_CALCULATED_IDS, CASH_FLOW_GROUPED_FINANCING_IDS_IN_ORDER, CASH_FLOW_GROUPED_IDS_IN_ORDER, CASH_FLOW_GROUPED_INVESTING_IDS_IN_ORDER, CASH_FLOW_GROUPED_OPERATING_IDS_IN_ORDER, } from '../cashFlow/cashFlowGroupedSectionOrder';
|
|
5
|
+
export const getCashFlowClassesView = (filter, accountState, classState, sectionsState, cashFlowClassesViewState) => {
|
|
6
|
+
const fetchState = reduceFetchStateParallelTimeframes([
|
|
7
|
+
cashFlowClassesViewState.fetchState.month,
|
|
8
|
+
cashFlowClassesViewState.fetchState.quarter,
|
|
9
|
+
cashFlowClassesViewState.fetchState.year,
|
|
10
|
+
]);
|
|
11
|
+
const reportId = 'cash_flow_by_classes';
|
|
12
|
+
const sections = {};
|
|
13
|
+
const calculatedSections = {};
|
|
14
|
+
if (fetchState.fetchState === 'Completed') {
|
|
15
|
+
CASH_FLOW_GROUPED_BREAKDOWN_IDS.forEach((sectionId) => {
|
|
16
|
+
sections[sectionId] = getSectionClassesViewReport(accountState, classState, sectionsState, { reportId, sectionId }, filter);
|
|
17
|
+
});
|
|
18
|
+
// These come back grouped, so each figure is read through the section layer
|
|
19
|
+
// and arrives already pruned by the class/project picker — the same source
|
|
20
|
+
// the breakdown rows above render from, so the two can never disagree.
|
|
21
|
+
CASH_FLOW_GROUPED_CALCULATED_IDS.forEach((calculatedSectionId) => {
|
|
22
|
+
calculatedSections[calculatedSectionId] = getCOABalances(
|
|
23
|
+
// Already built by the breakdown loop above; rebuilding it would repeat
|
|
24
|
+
// the whole section walk on every recompute.
|
|
25
|
+
sections[calculatedSectionId].sectionBalancesTotalByPeriod, filter);
|
|
26
|
+
});
|
|
27
|
+
calculatedSections['investingActivitiesTotal'] = getCOABalances(sections['investingActivities'].sectionBalancesTotalByPeriod, filter);
|
|
28
|
+
calculatedSections['financingActivitiesTotal'] = getCOABalances(sections['financingActivities'].sectionBalancesTotalByPeriod, filter);
|
|
29
|
+
}
|
|
30
|
+
return {
|
|
31
|
+
sections,
|
|
32
|
+
calculatedSections,
|
|
33
|
+
fetchState: fetchState.fetchState,
|
|
34
|
+
error: fetchState.error,
|
|
35
|
+
filter,
|
|
36
|
+
uiState: cashFlowClassesViewState.uiState,
|
|
37
|
+
classHierarchy: cashFlowClassesViewState.classHierarchy,
|
|
38
|
+
classesToFilterOut: cashFlowClassesViewState.uiState.classesToFilterOut,
|
|
39
|
+
reportId: cashFlowClassesViewState.reportId,
|
|
40
|
+
reportTitle: cashFlowClassesViewState.reportTitle,
|
|
41
|
+
firstMonthOfFY: cashFlowClassesViewState.firstMonthOfFY,
|
|
42
|
+
dataAvailable: cashFlowClassesViewState.dataAvailable,
|
|
43
|
+
bookCloseDate: cashFlowClassesViewState.bookCloseDate,
|
|
44
|
+
version: cashFlowClassesViewState.version,
|
|
45
|
+
status: cashFlowClassesViewState.status,
|
|
46
|
+
idsInOrder: CASH_FLOW_GROUPED_IDS_IN_ORDER,
|
|
47
|
+
rootSectionsWithSubSectionIds: {
|
|
48
|
+
operatingActivities: CASH_FLOW_GROUPED_OPERATING_IDS_IN_ORDER,
|
|
49
|
+
investingActivities: CASH_FLOW_GROUPED_INVESTING_IDS_IN_ORDER,
|
|
50
|
+
financingActivities: CASH_FLOW_GROUPED_FINANCING_IDS_IN_ORDER,
|
|
51
|
+
},
|
|
52
|
+
};
|
|
53
|
+
};
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { from, of } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap } from 'rxjs/operators';
|
|
3
|
+
import { updateSectionClassesView } from '../../entity/sectionClassesViewV2/sectionClassesViewReducer';
|
|
4
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../responsePayload';
|
|
5
|
+
import { toCashFlowReportViewID } from '../cashFlow/cashFlowPayload';
|
|
6
|
+
import { fetchCashFlowForTimeframeClassesView, updateCashFlowForTimeframeClassesView, updateCashFlowForTimeframeClassesViewFailure, } from './cashFlowClassesViewReducer';
|
|
7
|
+
const getTimeSeriesGroup = (timeframe) => {
|
|
8
|
+
switch (timeframe) {
|
|
9
|
+
case 'month':
|
|
10
|
+
return 'months';
|
|
11
|
+
case 'quarter':
|
|
12
|
+
return 'quarters';
|
|
13
|
+
case 'year':
|
|
14
|
+
return 'years';
|
|
15
|
+
}
|
|
16
|
+
};
|
|
17
|
+
export const reportIdUniqueKey = () => 'cash_flow_by_classes';
|
|
18
|
+
export const fetchCashFlowForTimeframeClassesViewEpic = (actions$, _, zeniAPI) => actions$.pipe(filter(fetchCashFlowForTimeframeClassesView.match), mergeMap((action) => {
|
|
19
|
+
const queryValue = {
|
|
20
|
+
is_full_response: true,
|
|
21
|
+
time_series_groups: [getTimeSeriesGroup(action.payload.timeframe)],
|
|
22
|
+
is_group_by_class: true,
|
|
23
|
+
// Only sent when refreshing: the flag makes the backend bypass its saved
|
|
24
|
+
// report and regenerate, so a normal lookup must not carry it.
|
|
25
|
+
...(action.payload.cacheOverride === true
|
|
26
|
+
? { is_hard_refresh: true }
|
|
27
|
+
: {}),
|
|
28
|
+
};
|
|
29
|
+
return zeniAPI
|
|
30
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/2.0/reports/cash_flow?query=${encodeURIComponent(JSON.stringify(queryValue))}`)
|
|
31
|
+
.pipe(mergeMap((response) => {
|
|
32
|
+
if (response.data != null && isSuccessResponse(response)) {
|
|
33
|
+
const actions = [];
|
|
34
|
+
const { report } = response.data;
|
|
35
|
+
const currency = report.currency;
|
|
36
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('adjustments'), reportIdUniqueKey(), report.operating_activities.adjustments, report.classes, report.accounts, currency));
|
|
37
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('investing_activities'), reportIdUniqueKey(), report.investing_activities, report.classes, report.accounts, currency));
|
|
38
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('financing_activities'), reportIdUniqueKey(), report.financing_activities, report.classes, report.accounts, currency));
|
|
39
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('net_income'), reportIdUniqueKey(), report.operating_activities.net_income, report.classes, report.accounts, currency));
|
|
40
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('operating_activities'), reportIdUniqueKey(), report.operating_activities, report.classes, report.accounts, currency));
|
|
41
|
+
actions.push(updateSectionClassesView(action.payload.timeframe, toCashFlowReportViewID('change_in_cash_and_equivalents'), reportIdUniqueKey(), report.change_in_cash_and_equivalents, report.classes, report.accounts, currency));
|
|
42
|
+
actions.push(updateCashFlowForTimeframeClassesView({
|
|
43
|
+
timeframe: action.payload.timeframe,
|
|
44
|
+
report: response.data,
|
|
45
|
+
}));
|
|
46
|
+
return from(actions);
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
return of(updateCashFlowForTimeframeClassesViewFailure(response.status, action.payload.timeframe));
|
|
50
|
+
}
|
|
51
|
+
}), catchError((error) => of(updateCashFlowForTimeframeClassesViewFailure(createZeniAPIStatus('Unexpected Error', 'Cash Flow by Class REST API call errored out: ' +
|
|
52
|
+
(error instanceof Error
|
|
53
|
+
? error.message
|
|
54
|
+
: JSON.stringify(error))), action.payload.timeframe))));
|
|
55
|
+
}));
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { from, of } from 'rxjs';
|
|
2
|
+
import { catchError, filter, mergeMap } from 'rxjs/operators';
|
|
3
|
+
import { updateProjects } from '../../entity/project/projectReducer';
|
|
4
|
+
import { updateSectionProjectView } from '../../entity/sectionProjectView/sectionProjectViewReducer';
|
|
5
|
+
import { createZeniAPIStatus, isSuccessResponse } from '../../responsePayload';
|
|
6
|
+
import { toCashFlowReportViewID } from '../cashFlow/cashFlowPayload';
|
|
7
|
+
import { fetchCashFlowForTimeframeProjectView, updateCashFlowForTimeframeProjectView, updateCashFlowForTimeframeProjectViewFailure, } from './cashFlowProjectViewReducer';
|
|
8
|
+
const getTimeSeriesGroup = (timeframe) => {
|
|
9
|
+
switch (timeframe) {
|
|
10
|
+
case 'month':
|
|
11
|
+
return 'months';
|
|
12
|
+
case 'quarter':
|
|
13
|
+
return 'quarters';
|
|
14
|
+
case 'year':
|
|
15
|
+
return 'years';
|
|
16
|
+
}
|
|
17
|
+
};
|
|
18
|
+
export const reportIdUniqueKey = () => 'cash_flow_by_projects';
|
|
19
|
+
export const fetchCashFlowForTimeframeProjectViewEpic = (actions$, _, zeniAPI) => actions$.pipe(filter(fetchCashFlowForTimeframeProjectView.match), mergeMap((action) => {
|
|
20
|
+
const queryValue = {
|
|
21
|
+
is_full_response: true,
|
|
22
|
+
time_series_groups: [getTimeSeriesGroup(action.payload.timeframe)],
|
|
23
|
+
is_group_by_project: true,
|
|
24
|
+
// Only sent when refreshing: the flag makes the backend bypass its saved
|
|
25
|
+
// report and regenerate, so a normal lookup must not carry it.
|
|
26
|
+
...(action.payload.cacheOverride === true
|
|
27
|
+
? { is_hard_refresh: true }
|
|
28
|
+
: {}),
|
|
29
|
+
};
|
|
30
|
+
return zeniAPI
|
|
31
|
+
.getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/2.0/reports/cash_flow?query=${encodeURIComponent(JSON.stringify(queryValue))}`)
|
|
32
|
+
.pipe(mergeMap((response) => {
|
|
33
|
+
if (response.data != null && isSuccessResponse(response)) {
|
|
34
|
+
const actions = [];
|
|
35
|
+
const { report } = response.data;
|
|
36
|
+
const currency = report.currency;
|
|
37
|
+
actions.push(updateProjects(report.projects));
|
|
38
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('adjustments'), reportIdUniqueKey(), report.operating_activities.adjustments, report.accounts, currency));
|
|
39
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('investing_activities'), reportIdUniqueKey(), report.investing_activities, report.accounts, currency));
|
|
40
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('financing_activities'), reportIdUniqueKey(), report.financing_activities, report.accounts, currency));
|
|
41
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('net_income'), reportIdUniqueKey(), report.operating_activities.net_income, report.accounts, currency));
|
|
42
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('operating_activities'), reportIdUniqueKey(), report.operating_activities, report.accounts, currency));
|
|
43
|
+
actions.push(updateSectionProjectView(action.payload.timeframe, toCashFlowReportViewID('change_in_cash_and_equivalents'), reportIdUniqueKey(), report.change_in_cash_and_equivalents, report.accounts, currency));
|
|
44
|
+
actions.push(updateCashFlowForTimeframeProjectView({
|
|
45
|
+
timeframe: action.payload.timeframe,
|
|
46
|
+
report: response.data,
|
|
47
|
+
}));
|
|
48
|
+
return from(actions);
|
|
49
|
+
}
|
|
50
|
+
else {
|
|
51
|
+
return of(updateCashFlowForTimeframeProjectViewFailure(response.status, action.payload.timeframe));
|
|
52
|
+
}
|
|
53
|
+
}), catchError((error) => of(updateCashFlowForTimeframeProjectViewFailure(createZeniAPIStatus('Unexpected Error', 'Cash Flow by Project REST API call errored out: ' +
|
|
54
|
+
(error instanceof Error
|
|
55
|
+
? error.message
|
|
56
|
+
: JSON.stringify(error))), action.payload.timeframe))));
|
|
57
|
+
}));
|