@zeniai/client-epic-state 5.1.94 → 5.1.95-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.
Files changed (112) hide show
  1. package/lib/commonStateTypes/viewAndReport/reportIDHelper.d.ts +16 -0
  2. package/lib/commonStateTypes/viewAndReport/reportIDHelper.js +22 -1
  3. package/lib/commonStateTypes/viewAndReport/viewAndReport.d.ts +2 -2
  4. package/lib/commonStateTypes/viewAndReport/viewAndReport.js +2 -0
  5. package/lib/entity/accountGroup/accountGroupState.d.ts +1 -1
  6. package/lib/entity/class/classReducer.d.ts +4 -4
  7. package/lib/entity/class/classSelectorV2.d.ts +2 -1
  8. package/lib/entity/class/classSelectorV2.js +7 -7
  9. package/lib/entity/class/classState.d.ts +1 -1
  10. package/lib/entity/forecast/forecastState.d.ts +1 -1
  11. package/lib/entity/invoicing/invoicingCommonPayload.d.ts +9 -0
  12. package/lib/entity/invoicing/invoicingCommonPayload.js +7 -0
  13. package/lib/entity/sectionAccountsView/sectionAccountsView.d.ts +1 -1
  14. package/lib/entity/sectionClassesViewV2/sectionClassesView.d.ts +1 -1
  15. package/lib/entity/sectionClassesViewV2/sectionClassesViewReducer.d.ts +2 -2
  16. package/lib/entity/sectionClassesViewV2/sectionClassesViewSelector.d.ts +2 -1
  17. package/lib/entity/sectionClassesViewV2/sectionClassesViewSelector.js +3 -3
  18. package/lib/entity/sectionProjectView/sectionProjectView.d.ts +1 -1
  19. package/lib/entity/sectionProjectView/sectionProjectViewReducer.d.ts +2 -2
  20. package/lib/entity/sectionProjectView/sectionProjectViewSelector.d.ts +2 -1
  21. package/lib/entity/sectionProjectView/sectionProjectViewSelector.js +4 -4
  22. package/lib/epic.d.ts +5 -1
  23. package/lib/epic.js +5 -1
  24. package/lib/esm/commonStateTypes/viewAndReport/reportIDHelper.js +17 -0
  25. package/lib/esm/commonStateTypes/viewAndReport/viewAndReport.js +2 -0
  26. package/lib/esm/entity/class/classSelectorV2.js +7 -7
  27. package/lib/esm/entity/invoicing/invoicingCommonPayload.js +6 -0
  28. package/lib/esm/entity/sectionClassesViewV2/sectionClassesViewSelector.js +3 -3
  29. package/lib/esm/entity/sectionProjectView/sectionProjectViewSelector.js +4 -4
  30. package/lib/esm/epic.js +5 -1
  31. package/lib/esm/index.js +10 -4
  32. package/lib/esm/reducer.js +6 -0
  33. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewEpic.js +30 -0
  34. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewPayload.js +1 -0
  35. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewReducer.js +132 -0
  36. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewSelector.js +90 -0
  37. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewSelectorTypes.js +1 -0
  38. package/lib/esm/view/balanceSheetClassesView/balanceSheetClassesViewState.js +1 -0
  39. package/lib/esm/view/balanceSheetClassesView/balanceSheetForTimeframeClassesViewEpic.js +61 -0
  40. package/lib/esm/view/balanceSheetProjectView/balanceSheetForTimeframeProjectViewEpic.js +63 -0
  41. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewEpic.js +30 -0
  42. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewPayload.js +1 -0
  43. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewReducer.js +128 -0
  44. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewSelector.js +90 -0
  45. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewSelectorTypes.js +1 -0
  46. package/lib/esm/view/balanceSheetProjectView/balanceSheetProjectViewState.js +1 -0
  47. package/lib/esm/view/financeStatement/financeStatementSelector.js +21 -1
  48. package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.js +16 -4
  49. package/lib/esm/view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig.js +34 -1
  50. package/lib/esm/view/invoicing/invoicingConfigView/invoicingConfigViewReducer.js +5 -1
  51. package/lib/esm/view/profitAndLossProjectView/profitAndLossProjectViewReducer.js +7 -2
  52. package/lib/esm/view/spendManagement/spendManagementFilterHelpers.js +1 -1
  53. package/lib/index.d.ts +15 -5
  54. package/lib/index.js +76 -48
  55. package/lib/reducer.d.ts +6 -0
  56. package/lib/reducer.js +6 -0
  57. package/lib/view/auditReportView/auditReportViewState.d.ts +1 -1
  58. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewEpic.d.ts +6 -0
  59. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewEpic.js +34 -0
  60. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewPayload.d.ts +20 -0
  61. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewPayload.js +2 -0
  62. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewReducer.d.ts +34 -0
  63. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewReducer.js +136 -0
  64. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewSelector.d.ts +7 -0
  65. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewSelector.js +94 -0
  66. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewSelectorTypes.d.ts +7 -0
  67. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewSelectorTypes.js +2 -0
  68. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewState.d.ts +23 -0
  69. package/lib/view/balanceSheetClassesView/balanceSheetClassesViewState.js +2 -0
  70. package/lib/view/balanceSheetClassesView/balanceSheetForTimeframeClassesViewEpic.d.ts +9 -0
  71. package/lib/view/balanceSheetClassesView/balanceSheetForTimeframeClassesViewEpic.js +66 -0
  72. package/lib/view/balanceSheetProjectView/balanceSheetForTimeframeProjectViewEpic.d.ts +10 -0
  73. package/lib/view/balanceSheetProjectView/balanceSheetForTimeframeProjectViewEpic.js +68 -0
  74. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewEpic.d.ts +6 -0
  75. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewEpic.js +34 -0
  76. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewPayload.d.ts +20 -0
  77. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewPayload.js +2 -0
  78. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewReducer.d.ts +33 -0
  79. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewReducer.js +132 -0
  80. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewSelector.d.ts +7 -0
  81. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewSelector.js +94 -0
  82. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewSelectorTypes.d.ts +18 -0
  83. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewSelectorTypes.js +2 -0
  84. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewState.d.ts +22 -0
  85. package/lib/view/balanceSheetProjectView/balanceSheetProjectViewState.js +2 -0
  86. package/lib/view/billPayCard/billPayCardSelector.d.ts +1 -1
  87. package/lib/view/cardBalance/cardBalanceSelector.d.ts +1 -1
  88. package/lib/view/cashBalance/cashBalanceSelector.d.ts +1 -1
  89. package/lib/view/cashInCashOut/cashInCashOutSelector.d.ts +1 -1
  90. package/lib/view/cashPosition/cashPositionSelector.d.ts +1 -1
  91. package/lib/view/dashboard/dashboardReducer.d.ts +2 -2
  92. package/lib/view/financeStatement/financeStatementReducer.d.ts +1 -1
  93. package/lib/view/financeStatement/financeStatementSelector.d.ts +4 -0
  94. package/lib/view/financeStatement/financeStatementSelector.js +21 -1
  95. package/lib/view/globalMerchantView/globalMerchantViewReducer.d.ts +2 -2
  96. package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.d.ts +4 -0
  97. package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewPayload.js +15 -3
  98. package/lib/view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewState.d.ts +17 -0
  99. package/lib/view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig.d.ts +7 -0
  100. package/lib/view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig.js +37 -2
  101. package/lib/view/invoicing/invoicingConfigView/invoicingConfigViewPayload.d.ts +2 -1
  102. package/lib/view/invoicing/invoicingConfigView/invoicingConfigViewReducer.d.ts +1 -1
  103. package/lib/view/invoicing/invoicingConfigView/invoicingConfigViewReducer.js +4 -0
  104. package/lib/view/invoicing/invoicingConfigView/invoicingConfigViewState.d.ts +7 -1
  105. package/lib/view/profitAndLossProjectView/profitAndLossProjectViewReducer.d.ts +1 -0
  106. package/lib/view/profitAndLossProjectView/profitAndLossProjectViewReducer.js +7 -2
  107. package/lib/view/reimbursementCard/reimbursementCardSelector.d.ts +1 -1
  108. package/lib/view/reportsResync/reportsResyncReducer.d.ts +2 -2
  109. package/lib/view/spendManagement/spendManagementFilterHelpers.js +1 -1
  110. package/lib/view/tasksCard/tasksCardSelector.d.ts +1 -1
  111. package/lib/view/topEx/topExSelector.d.ts +1 -1
  112. package/package.json +1 -1
@@ -0,0 +1,90 @@
1
+ import { newAdditionalBalancesOptions } from '../../commonStateTypes/coaBalance/additionalBalances/getAdditionalBalances';
2
+ import { getSumOfBalancesByGroupedByPeriod } from '../../commonStateTypes/coaBalance/classBalances/getSumOfBalancesGroupedByPeriod';
3
+ import { getCOABalances } from '../../commonStateTypes/coaBalance/coaBalance';
4
+ import { reduceFetchStateParallelTimeframes } from '../../commonStateTypes/reduceFetchState';
5
+ import { getProjectsByIds } from '../../entity/project/projectSelector';
6
+ import { getSectionProjectViewReport } from '../../entity/sectionProjectView/sectionProjectViewSelector';
7
+ import { ALL_BALANCE_SHEET_REPORT_VIEW_ASSET_IDS, ALL_BALANCE_SHEET_REPORT_VIEW_EQUITY_IDS, ALL_BALANCE_SHEET_REPORT_VIEW_LIABILITY_IDS, ALL_BALANCE_SHEET_REPORT_VIEW_SECTION_IDS, balanceSheetSectionIdsInOrder, } from '../balanceSheet/balanceSheetSelectorTypes';
8
+ // The section-id constants and the display order are both module-level, so the
9
+ // sorted groupings are computed once instead of on every selector call.
10
+ const byDisplayOrder = (a, b) => balanceSheetSectionIdsInOrder.indexOf(a) -
11
+ balanceSheetSectionIdsInOrder.indexOf(b);
12
+ const ASSET_IDS_IN_ORDER = [...ALL_BALANCE_SHEET_REPORT_VIEW_ASSET_IDS].sort(byDisplayOrder);
13
+ const LIABILITY_IDS_IN_ORDER = [
14
+ ...ALL_BALANCE_SHEET_REPORT_VIEW_LIABILITY_IDS,
15
+ ].sort(byDisplayOrder);
16
+ const EQUITY_IDS_IN_ORDER = [...ALL_BALANCE_SHEET_REPORT_VIEW_EQUITY_IDS].sort(byDisplayOrder);
17
+ export const getBalanceSheetProjectView = (filter, accountState, projectState, sectionsState, balanceSheetProjectViewState) => {
18
+ const fetchState = reduceFetchStateParallelTimeframes([
19
+ balanceSheetProjectViewState.fetchState.month,
20
+ balanceSheetProjectViewState.fetchState.quarter,
21
+ balanceSheetProjectViewState.fetchState.year,
22
+ ]);
23
+ const reportId = 'balance_sheet_by_projects';
24
+ const sections = {};
25
+ const calculatedSections = {};
26
+ if (fetchState.fetchState === 'Completed') {
27
+ // Balance Sheet balances are point-in-time, so the extra columns must be
28
+ // read as snapshots rather than period sums.
29
+ const additionalBalancesOptions = newAdditionalBalancesOptions(true);
30
+ ALL_BALANCE_SHEET_REPORT_VIEW_SECTION_IDS.forEach((sectionId) => {
31
+ sections[`${sectionId}`] = getSectionProjectViewReport(accountState, projectState, sectionsState, balanceSheetProjectViewState.projectIds, {
32
+ reportId,
33
+ sectionId,
34
+ }, filter, additionalBalancesOptions);
35
+ });
36
+ const totalCurrentAssetsBalancesByPeriod = getSumOfBalancesByGroupedByPeriod([
37
+ sections['cashAndEquivalents'].sectionBalancesTotalByPeriod,
38
+ sections['accountsReceiable'].sectionBalancesTotalByPeriod,
39
+ sections['otherCurrentAssets'].sectionBalancesTotalByPeriod,
40
+ ]);
41
+ calculatedSections['totalCurrentAssets'] = getCOABalances(totalCurrentAssetsBalancesByPeriod, filter, additionalBalancesOptions);
42
+ const totalAssetsBalancesByPeriod = getSumOfBalancesByGroupedByPeriod([
43
+ totalCurrentAssetsBalancesByPeriod ?? {},
44
+ sections['fixedAssets'].sectionBalancesTotalByPeriod,
45
+ sections['otherAssets'].sectionBalancesTotalByPeriod,
46
+ ]);
47
+ calculatedSections['totalAssets'] = getCOABalances(totalAssetsBalancesByPeriod, filter, additionalBalancesOptions);
48
+ const totalCurrentLiabilitiesBalancesByPeriod = getSumOfBalancesByGroupedByPeriod([
49
+ sections['accountsPayable'].sectionBalancesTotalByPeriod,
50
+ sections['creditCards'].sectionBalancesTotalByPeriod,
51
+ sections['otherCurrentLiabilities'].sectionBalancesTotalByPeriod,
52
+ ]);
53
+ calculatedSections['totalCurrentLiabilities'] = getCOABalances(totalCurrentLiabilitiesBalancesByPeriod, filter, additionalBalancesOptions);
54
+ calculatedSections['totalNonCurrentLiabilities'] = getCOABalances(sections['longTermLiabilities'].sectionBalancesTotalByPeriod, filter, additionalBalancesOptions);
55
+ const totalLiabilitiesBalancesByPeriod = getSumOfBalancesByGroupedByPeriod([
56
+ totalCurrentLiabilitiesBalancesByPeriod ?? {},
57
+ sections['longTermLiabilities'].sectionBalancesTotalByPeriod,
58
+ ]);
59
+ calculatedSections['totalLiabilities'] = getCOABalances(totalLiabilitiesBalancesByPeriod, filter, additionalBalancesOptions);
60
+ calculatedSections['totalEquity'] = getCOABalances(sections['equity'].sectionBalancesTotalByPeriod, filter, additionalBalancesOptions);
61
+ const liabilitiesAndEquityBalancesByPeriod = getSumOfBalancesByGroupedByPeriod([
62
+ totalLiabilitiesBalancesByPeriod ?? {},
63
+ sections['equity'].sectionBalancesTotalByPeriod,
64
+ ]);
65
+ calculatedSections['liabilitiesAndEquity'] = getCOABalances(liabilitiesAndEquityBalancesByPeriod, filter, additionalBalancesOptions);
66
+ }
67
+ return {
68
+ sections,
69
+ calculatedSections,
70
+ reportId: balanceSheetProjectViewState.reportId,
71
+ reportTitle: balanceSheetProjectViewState.reportTitle,
72
+ firstMonthOfFY: balanceSheetProjectViewState.firstMonthOfFY,
73
+ dataAvailable: balanceSheetProjectViewState.dataAvailable,
74
+ bookCloseDate: balanceSheetProjectViewState.bookCloseDate,
75
+ version: balanceSheetProjectViewState.version,
76
+ status: balanceSheetProjectViewState.status,
77
+ fetchState: fetchState.fetchState,
78
+ error: fetchState.error,
79
+ filter,
80
+ uiState: balanceSheetProjectViewState.uiState,
81
+ projects: getProjectsByIds(projectState, balanceSheetProjectViewState.projectIds),
82
+ projectsToFilterOut: balanceSheetProjectViewState.uiState.projectsToFilterOut,
83
+ idsInOrder: balanceSheetSectionIdsInOrder,
84
+ rootSectionsWithSubSectionIds: {
85
+ assets: ASSET_IDS_IN_ORDER,
86
+ liabilities: LIABILITY_IDS_IN_ORDER,
87
+ equity: EQUITY_IDS_IN_ORDER,
88
+ },
89
+ };
90
+ };
@@ -8,6 +8,8 @@ import { reduceAnyCompletedFetchState } from '../../commonStateTypes/reduceFetch
8
8
  import { toTimeframeTick, } from '../../commonStateTypes/timeframeTick';
9
9
  import { extractThisPeriod } from '../../commonStateTypes/viewAndReport/thisPeriodHelpers';
10
10
  import { getBalanceSheet } from '../balanceSheet/balanceSheetSelector';
11
+ import { getBalanceSheetClassesView } from '../balanceSheetClassesView/balanceSheetClassesViewSelector';
12
+ import { getBalanceSheetProjectView } from '../balanceSheetProjectView/balanceSheetProjectViewSelector';
11
13
  import { getCashFlow } from '../cashFlow/cashFlowSelector';
12
14
  import { getProfitAndLossReport, } from '../profitAndLoss/profitAndLossSelector';
13
15
  import { getProfitAndLossClassesHorizontalView } from '../profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector';
@@ -37,7 +39,7 @@ function getFirstMonthOfFY(profitAndLossState, balanceSheetState, cashFlowState)
37
39
  cashFlowState.firstMonthOfFY ??
38
40
  1);
39
41
  }
40
- export const getFinanceStatement = createSelector((state) => state.accountState, (state) => state.accountGroupState, (state) => state.classState, (state) => state.sectionClassesViewStateV2, (state) => state.profitAndLossState, (state) => state.profitAndLossClassesViewState, (state) => state.projectState, (state) => state.sectionProjectViewState, (state) => state.profitAndLossProjectViewState, (state) => state.balanceSheetState, (state) => state.cashFlowState, (state) => state.financeStatementState, (state) => state.sectionAccountsViewState, (state) => state.forecastState, (accountState, accountGroupState, classState, sectionsState, profitAndLossState, profitAndLossClassesViewState, projectState, sectionProjectViewState, profitAndLossProjectViewState, balanceSheetState, cashFlowState, financeStatementState, sectionAccountsViewState, forecastState) => {
42
+ export const getFinanceStatement = createSelector((state) => state.accountState, (state) => state.accountGroupState, (state) => state.classState, (state) => state.sectionClassesViewStateV2, (state) => state.profitAndLossState, (state) => state.profitAndLossClassesViewState, (state) => state.projectState, (state) => state.sectionProjectViewState, (state) => state.profitAndLossProjectViewState, (state) => state.balanceSheetState, (state) => state.balanceSheetClassesViewState, (state) => state.balanceSheetProjectViewState, (state) => state.cashFlowState, (state) => state.financeStatementState, (state) => state.sectionAccountsViewState, (state) => state.forecastState, (accountState, accountGroupState, classState, sectionsState, profitAndLossState, profitAndLossClassesViewState, projectState, sectionProjectViewState, profitAndLossProjectViewState, balanceSheetState, balanceSheetClassesViewState, balanceSheetProjectViewState, cashFlowState, financeStatementState, sectionAccountsViewState, forecastState) => {
41
43
  // to get min and max dates across three reports
42
44
  let allTimeframeTicks = [];
43
45
  let balancesInTimeframe = [];
@@ -77,6 +79,10 @@ export const getFinanceStatement = createSelector((state) => state.accountState,
77
79
  ? thisPeriod
78
80
  : undefined);
79
81
  const balanceSheetReport = getBalanceSheet(filter, accountState, accountGroupState, sectionAccountsViewState, balanceSheetState);
82
+ const balanceSheetClassFilter = newBalancesFilterClassesView(filter.firstMonthOfFY, filter.timeframe, filter.balancesRange.numberOfPeriods, filter.balancesRange.thisPeriod, filter.balancesRange.orderBy, filter.additionalBalances, balanceSheetClassesViewState.uiState.classesToFilterOut);
83
+ const balanceSheetByClassReport = getBalanceSheetClassesView(balanceSheetClassFilter, accountState, classState, sectionsState, balanceSheetClassesViewState);
84
+ const balanceSheetProjectFilter = newBalancesFilterProjectView(filter.firstMonthOfFY, filter.timeframe, filter.balancesRange.numberOfPeriods, filter.balancesRange.thisPeriod, filter.balancesRange.orderBy, filter.additionalBalances, balanceSheetProjectViewState.uiState.projectsToFilterOut);
85
+ const balanceSheetByProjectReport = getBalanceSheetProjectView(balanceSheetProjectFilter, accountState, projectState, sectionProjectViewState, balanceSheetProjectViewState);
80
86
  const cashFlowReport = getCashFlow(filter, accountState, accountGroupState, sectionAccountsViewState, cashFlowState);
81
87
  const allReports = [
82
88
  profitAndLossReport.reducedAnyFetchState,
@@ -105,6 +111,18 @@ export const getFinanceStatement = createSelector((state) => state.accountState,
105
111
  error: balanceSheetReport.error,
106
112
  };
107
113
  break;
114
+ case 'balance_sheet_by_classes':
115
+ selectedReportAndTimeframeFetchState = {
116
+ fetchState: balanceSheetByClassReport.fetchState,
117
+ error: balanceSheetByClassReport.error,
118
+ };
119
+ break;
120
+ case 'balance_sheet_by_projects':
121
+ selectedReportAndTimeframeFetchState = {
122
+ fetchState: balanceSheetByProjectReport.fetchState,
123
+ error: balanceSheetByProjectReport.error,
124
+ };
125
+ break;
108
126
  case 'cash_flow':
109
127
  selectedReportAndTimeframeFetchState = {
110
128
  fetchState: cashFlowReport.fetchState,
@@ -132,6 +150,8 @@ export const getFinanceStatement = createSelector((state) => state.accountState,
132
150
  profitAndLossByProjectReport,
133
151
  profitAndLossByClassHorizontalReport,
134
152
  balanceSheetReport,
153
+ balanceSheetByClassReport,
154
+ balanceSheetByProjectReport,
135
155
  cashFlowReport,
136
156
  filter,
137
157
  selectedReportId: financeStatementState.selectedReportId,
@@ -1,9 +1,13 @@
1
1
  import { toAddressUpdatableInfoPayload } from '../../addressView/addressViewPayload';
2
- import { billingFrequencyToPeriod } from './invoicingSubscriptionFormConfig';
2
+ import { billingFrequencyToPeriod, invoicingSubscriptionTodayIso, toInvoicingSubscriptionQuantity, } from './invoicingSubscriptionFormConfig';
3
3
  /**
4
4
  * Build the create/update subscription request body from the form draft. The
5
5
  * shipping address is sent as an object (captured via the shared Address
6
6
  * screen); the backend persists it — same pattern as the customer save flow.
7
+ *
8
+ * `remaining_billing_cycles` is omitted when the user left the field empty, so
9
+ * the backend applies the plan's own `billing_cycles` (or renews forever when
10
+ * the plan sets no limit) rather than being pinned to a value the form invented.
7
11
  */
8
12
  export const localDataToSaveInvoicingSubscriptionPayload = (localData, shippingAddress) => {
9
13
  const frequency = billingFrequencyToPeriod(localData.billingFrequency);
@@ -11,32 +15,40 @@ export const localDataToSaveInvoicingSubscriptionPayload = (localData, shippingA
11
15
  {
12
16
  item_price_code: localData.planPriceCode,
13
17
  item_type: 'plan',
14
- quantity: Math.max(1, localData.planQuantity || 1),
18
+ quantity: toInvoicingSubscriptionQuantity(localData.planQuantity),
15
19
  },
16
20
  ...localData.addonPriceCodes.map((priceCode) => ({
17
21
  item_price_code: priceCode,
18
22
  item_type: 'addon',
19
- quantity: 1,
23
+ quantity: toInvoicingSubscriptionQuantity(localData.addonQuantities[priceCode]),
20
24
  })),
21
25
  ...localData.chargePriceCodes.map((priceCode) => ({
22
26
  item_price_code: priceCode,
23
27
  item_type: 'charge',
24
- quantity: 1,
28
+ quantity: toInvoicingSubscriptionQuantity(localData.chargeQuantities[priceCode]),
25
29
  })),
26
30
  ];
27
31
  const setupFee = localData.setupFee?.amount;
28
32
  const poNumber = localData.poNumber.trim();
29
33
  const trialEnd = localData.trialEnd.trim();
34
+ const startedAt = localData.startedAt.trim();
35
+ const remainingBillingCycles = localData.remainingBillingCycles.trim();
30
36
  return {
31
37
  auto_collection: localData.autoCollection ? 'on' : 'off',
32
38
  billing_period: frequency.period,
33
39
  billing_period_unit: frequency.unit,
34
40
  currency_code: localData.preferredCurrencyCode,
35
41
  customer_id: localData.customerId,
42
+ started_at: startedAt !== '' ? startedAt : invoicingSubscriptionTodayIso(),
36
43
  subscription_items: items,
37
44
  ...(setupFee != null ? { setup_fee: setupFee } : {}),
38
45
  ...(poNumber !== '' ? { po_number: poNumber } : {}),
39
46
  ...(trialEnd !== '' ? { trial_end: trialEnd } : {}),
47
+ ...(remainingBillingCycles !== ''
48
+ ? {
49
+ remaining_billing_cycles: toInvoicingSubscriptionQuantity(Number(remainingBillingCycles)),
50
+ }
51
+ : {}),
40
52
  ...(localData.couponId !== '' ? { coupon_ids: [localData.couponId] } : {}),
41
53
  ...(shippingAddress != null
42
54
  ? { shipping_address: toAddressUpdatableInfoPayload(shippingAddress) }
@@ -33,17 +33,42 @@ const subscriptionItemPriceCodes = (subscription, itemType) => subscription?.sub
33
33
  ?.filter((item) => item.itemType === itemType)
34
34
  .map((item) => item.itemPriceCode)
35
35
  .filter((code) => code != null && code !== '') ?? [];
36
+ const subscriptionItemQuantities = (subscription, itemType) => {
37
+ const quantities = {};
38
+ subscription?.subscriptionItems
39
+ ?.filter((item) => item.itemType === itemType)
40
+ .forEach((item) => {
41
+ if (item.itemPriceCode != null && item.itemPriceCode !== '') {
42
+ quantities[item.itemPriceCode] = toInvoicingSubscriptionQuantity(item.quantity);
43
+ }
44
+ });
45
+ return quantities;
46
+ };
47
+ /** Today as `YYYY-MM-DD`, the default subscription start date. */
48
+ export const invoicingSubscriptionTodayIso = () => new Date().toISOString().slice(0, 10);
49
+ /**
50
+ * Clamp a subscription-item quantity to the minimum the API accepts. Shared by
51
+ * the plan, add-on and charge items so none of them can bill a 0 or a fraction.
52
+ */
53
+ export const toInvoicingSubscriptionQuantity = (quantity) => {
54
+ const whole = Math.floor(Number(quantity));
55
+ return Number.isFinite(whole) && whole > 0 ? whole : 1;
56
+ };
36
57
  export const initialInvoicingSubscriptionFormLocalData = {
37
58
  addonPriceCodes: [],
59
+ addonQuantities: {},
38
60
  autoCollection: true,
39
61
  billingFrequency: 'monthly',
40
62
  chargePriceCodes: [],
63
+ chargeQuantities: {},
41
64
  couponId: '',
42
65
  customerId: '',
43
66
  planPriceCode: '',
44
67
  planQuantity: 1,
45
68
  poNumber: '',
46
69
  preferredCurrencyCode: 'USD',
70
+ remainingBillingCycles: '',
71
+ startedAt: '',
47
72
  trialEnd: '',
48
73
  };
49
74
  /** Seed the form draft from an existing subscription entity (edit mode). */
@@ -54,18 +79,26 @@ export const entityToInvoicingSubscriptionFormLocalData = (subscription) => {
54
79
  const planItem = subscription.subscriptionItems?.find((item) => item.itemType === 'plan');
55
80
  return {
56
81
  addonPriceCodes: subscriptionItemPriceCodes(subscription, 'addon'),
82
+ addonQuantities: subscriptionItemQuantities(subscription, 'addon'),
57
83
  autoCollection: (subscription.autoCollection ?? 'on') === 'on',
58
84
  billingFrequency: periodToBillingFrequency(subscription.billingPeriod, subscription.billingPeriodUnit),
59
85
  chargePriceCodes: subscriptionItemPriceCodes(subscription, 'charge'),
86
+ chargeQuantities: subscriptionItemQuantities(subscription, 'charge'),
60
87
  couponId: subscription.coupons?.[0]?.couponCode ??
61
88
  subscription.coupons?.[0]?.couponID ??
62
89
  '',
63
90
  customerId: subscription.customerID ?? '',
64
91
  planPriceCode: subscriptionItemPriceCodes(subscription, 'plan')[0] ?? '',
65
- planQuantity: planItem?.quantity ?? 1,
92
+ planQuantity: toInvoicingSubscriptionQuantity(planItem?.quantity),
66
93
  poNumber: subscription.poNumber ?? '',
67
94
  preferredCurrencyCode: subscription.currencyCode ?? 'USD',
95
+ remainingBillingCycles: subscription.remainingBillingCycles != null
96
+ ? String(subscription.remainingBillingCycles)
97
+ : '',
68
98
  setupFee: subscription.setupFee,
99
+ startedAt: subscription.startedAt != null
100
+ ? subscription.startedAt.format('YYYY-MM-DD')
101
+ : '',
69
102
  trialEnd: subscription.trialEnd != null
70
103
  ? subscription.trialEnd.format('YYYY-MM-DD')
71
104
  : '',
@@ -1,5 +1,5 @@
1
1
  import { createSlice } from '@reduxjs/toolkit';
2
- import { toAuditLogEntityRouteOption, toInvoicingCatalogItemLifecycleActionOption, toInvoicingCatalogProductLifecycleActionOption, toInvoicingDiscountLifecycleActionOption, toInvoicingDunningAction, toInvoicingNamedOption, toInvoicingQboAccountMappingKindOption, toInvoicingSubscriptionEditFieldOption, toInvoicingSubscriptionLifecycleActionOption, } from '../../../entity/invoicing/invoicingCommonPayload';
2
+ import { toAuditLogEntityRouteOption, toInvoicingCatalogItemLifecycleActionOption, toInvoicingCatalogProductLifecycleActionOption, toInvoicingDiscountLifecycleActionOption, toInvoicingDunningAction, toInvoicingNamedOption, toInvoicingNamedOptionsByKey, toInvoicingQboAccountMappingKindOption, toInvoicingSubscriptionEditFieldOption, toInvoicingSubscriptionLifecycleActionOption, } from '../../../entity/invoicing/invoicingCommonPayload';
3
3
  import { clearAll } from '../../../rootActions';
4
4
  export const initialState = {
5
5
  fetchState: 'Not-Started',
@@ -10,6 +10,7 @@ export const initialState = {
10
10
  auditLogSourceLabels: [],
11
11
  autoCollectionOptions: [],
12
12
  billingPeriodUnitOptions: [],
13
+ catalogTierTypeOptionsByPricingModel: undefined,
13
14
  catalogTrialEndActionOptions: [],
14
15
  catalogTrialUnitOptions: [],
15
16
  customerTypeOptions: [],
@@ -61,6 +62,9 @@ export function mapInvoicingConfigPayloadToState(payload) {
61
62
  })),
62
63
  autoCollectionOptions: (payload.auto_collection_options ?? []).map(toInvoicingNamedOption),
63
64
  billingPeriodUnitOptions: (payload.billing_period_unit_options ?? []).map(toInvoicingNamedOption),
65
+ catalogTierTypeOptionsByPricingModel: payload.catalog_tier_type_options_by_pricing_model != null
66
+ ? toInvoicingNamedOptionsByKey(payload.catalog_tier_type_options_by_pricing_model)
67
+ : undefined,
64
68
  catalogTrialEndActionOptions: (payload.catalog_trial_end_action_options ?? []).map(toInvoicingNamedOption),
65
69
  catalogTrialUnitOptions: (payload.catalog_trial_unit_options ?? []).map(toInvoicingNamedOption),
66
70
  customerTypeOptions: (payload.customer_type_options ?? []).map(toInvoicingNamedOption),
@@ -77,13 +77,18 @@ const profitAndLossProjectView = createSlice({
77
77
  draft.uiState.projectsToFilterOut = action.payload.projectsToFilterOut;
78
78
  },
79
79
  updateProfitAndLossProjectViewUIState(draft, action) {
80
- const { nodeCollapseState, scrollPosition } = action.payload;
80
+ const { nodeCollapseState, scrollPosition, resetLeftScroll } = action.payload;
81
81
  if (nodeCollapseState != null) {
82
82
  draft.uiState.nodeCollapseState = Object.assign({}, draft.uiState.nodeCollapseState, {
83
83
  [nodeCollapseState.nodeId]: nodeCollapseState.isCollapsed,
84
84
  });
85
85
  }
86
- if (scrollPosition != null) {
86
+ // Mutually exclusive: resetLeftScroll clears only scrollLeft from the
87
+ // recorded position, scrollPosition replaces the whole record.
88
+ if (resetLeftScroll === true && draft.uiState.scrollPosition != null) {
89
+ draft.uiState.scrollPosition.scrollLeft = undefined;
90
+ }
91
+ else if (scrollPosition != null) {
87
92
  draft.uiState.scrollPosition = scrollPosition;
88
93
  }
89
94
  },
@@ -156,7 +156,7 @@ const getCategoryValueForBill = (key, bill) => {
156
156
  case 'dueDate':
157
157
  return bill.dueDate;
158
158
  case 'amount':
159
- return bill.amount.amount;
159
+ return bill.totalAmountInUSD?.amount ?? bill.amount.amount;
160
160
  case 'paymentMethod': {
161
161
  const paymentMethodCode = bill.billPayInfo.billPaymentMethodType.code;
162
162
  const paymentMethodSubCode = bill.billPayInfo.billPaymentMethodType.subCode;
package/lib/index.d.ts CHANGED
@@ -37,7 +37,7 @@ import { stringToUnion, stringToUnionStrict } from './commonStateTypes/stringToU
37
37
  import { AbsoluteDay, Day, Month, MonthYearPeriod, Quarter, SCHEDULE_DAYS_OF_MONTH, ScheduleDaysOfMonth, TimePeriod, convertToPeriod, toAbsoluteDay, toMonth, toMonthStrict, toMonthYearPeriodId, toQuarter, toQuarterStrict, toScheduleDaysOfMonth } from './commonStateTypes/timePeriod';
38
38
  import { TimeframeTick, TimeframeTickWithMetaData, mapTimePeriodtoTimeframeTick, toTimePeriod, toTimeframeTick } from './commonStateTypes/timeframeTick';
39
39
  import { AgingDateSelectionType, AgingDetailReportInvoice, AgingDetailReportUIState, AgingReportId, AgingReportInvoice, AgingReportSortKey, AgingReportUIState } from './commonStateTypes/viewAndReport/agingReportStateTypes';
40
- import { isAgingReport, isCashFlowOrBalanceSheetReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isDashboardReport, isFluxAnalysisOpExReport, isOpExByVendorReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isPAndLReport } from './commonStateTypes/viewAndReport/reportIDHelper';
40
+ import { isAgingReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isBalanceSheetReport, isCashFlowOrBalanceSheetReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isDashboardReport, isFluxAnalysisOpExReport, isGroupedBalanceSheetReport, isOpExByVendorReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isPAndLReport } from './commonStateTypes/viewAndReport/reportIDHelper';
41
41
  import { PageToken, Report, ReportFormat, ReportID, ReportIDPlusForecastID, SelectorReport, SelectorView, View, toReportFormatStrict, toReportID } from './commonStateTypes/viewAndReport/viewAndReport';
42
42
  import { PAYMENT_BUSINESS_DAYS, filterDays, getNextNthWorkingDay, getNextTransferDate, getPreviousNthWorkingDay, getYearsList, holidaysFormatted, isHoliday, isHolidayToday } from './commonStateTypes/workingDayHelper';
43
43
  import { AccountFilterOption, AccountReport, AccountWithBalanceReport, getAllAccounts, getTransactionFilterAccountOptions } from './entity/account/accountSelector';
@@ -200,6 +200,14 @@ import { fetchBalanceSheet, fetchBalanceSheetForTimeframe, resetBalanceSheetNode
200
200
  import { getBalanceSheet, getBalanceSheetFetchState, getBalanceSheetForFullDataAvailableRange } from './view/balanceSheet/balanceSheetSelector';
201
201
  import { BalanceSheetReport, BalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewID, BalanceSheetReportViewRootSectionID, BalanceSheetReportViewSectionID, SectionIdsWithSubSectionIds as BalanceSheetSectionIdsWithSubSectionIds, isBalanceSheetReportViewCalculatedSectionID, isBalanceSheetReportViewSectionID, typeOfBalanceSheetRootSection } from './view/balanceSheet/balanceSheetSelectorTypes';
202
202
  import { BalanceSheetState, BalanceSheetUIState } from './view/balanceSheet/balanceSheetState';
203
+ import { clearBalanceSheetClassesView, fetchBalanceSheetClassesView, fetchBalanceSheetForTimeframeClassesView, resetBalanceSheetClassesNodeCollapseState, updateBalanceSheetClassesToFilterOut, updateBalanceSheetClassesViewAccountViewMode, updateBalanceSheetClassesViewUIState } from './view/balanceSheetClassesView/balanceSheetClassesViewReducer';
204
+ import { getBalanceSheetClassesView } from './view/balanceSheetClassesView/balanceSheetClassesViewSelector';
205
+ import { BalanceSheetClassesViewReport } from './view/balanceSheetClassesView/balanceSheetClassesViewSelectorTypes';
206
+ import { BalanceSheetClassesViewUIState } from './view/balanceSheetClassesView/balanceSheetClassesViewState';
207
+ import { clearBalanceSheetProjectView, fetchBalanceSheetForTimeframeProjectView, fetchBalanceSheetProjectView, resetBalanceSheetProjectNodeCollapseState, updateBalanceSheetProjectViewAccountViewMode, updateBalanceSheetProjectViewUIState, updateBalanceSheetProjectsToFilterOut } from './view/balanceSheetProjectView/balanceSheetProjectViewReducer';
208
+ import { getBalanceSheetProjectView } from './view/balanceSheetProjectView/balanceSheetProjectViewSelector';
209
+ import { BalanceSheetProjectViewReport } from './view/balanceSheetProjectView/balanceSheetProjectViewSelectorTypes';
210
+ import { BalanceSheetProjectViewUIState } from './view/balanceSheetProjectView/balanceSheetProjectViewState';
203
211
  import { clearBankAccountView, createBankAccount, createInternationalBankAccount, createUserBankAccount, deleteBankAccount, deleteUserBankAccount, fetchBankCountryNameByIban, fetchBankNameByRouting, fetchBankNameBySwift, resetCreateBankAccountDetails, updateBankAccountViewLocalStoreData, updateInternationalBankAccountViewLocalStoreData, updateStatusForCreateBankAccountFlow } from './view/bankAccountView/bankAccountViewReducer';
204
212
  import { BankAccountSelectorView, getBankAccount } from './view/bankAccountView/bankAccountViewSelector';
205
213
  import { BankAccountContext, BankNameByRoutingState, BankNameBySwiftState, CreateBankAccountDetails, CreateBankAccountLocalData, CreateInternationalBankAccountDetails, CreateInternationalBankAccountLocalData } from './view/bankAccountView/bankAccountViewState';
@@ -678,7 +686,7 @@ export default initialize;
678
686
  export { initializePusher, disconnectPusher, Dayjs, ZeniDate, dateInLocal as zeniDateInLocal, date as zeniDate, dateLocal, dateNow, getBusinessDayOfDate, formatZeniDateFY as formatZeniDate, getFYMonths, getFYQuarterAndYear, getStartOfAndEndOfTimeframeForFY, getActualPeriodOfFYQtr, getActualPeriodOfFY, getLocalTimezone, addPeriod, subtractPeriod, setLocalTimezone, updateZeniDateLocaleID, ZeniUrl, toZeniUrl, toZeniUrlWithoutBaseURL, RESTAPIEndpoints, RootState, updateZeniAPIClientConfig, zeniAPIClientConfig, injectFeatureEpics, injectFeatureModules, initializeWithNewStore, ZeniStore, ZeniAPIStatus, getTimeframeTickTag, TimeFrameTickTag, isIncompleteMonthPresentInTimeframeTick, getLastMonthOfFYQuarter, getLastMonthOfFYYear, getMonthIndex, dateFromYearMonthDate, getMinDate, ExternalAPIEndpoints, };
679
687
  export { ID, FetchState, FetchStateAndError, FetchedState, UpdateType, Mode, AccountViewMode, CompletionStatusType, };
680
688
  export { Amount, toAmount, Currency };
681
- export { View, SelectorView, Report, ReportID, toReportID, ReportIDPlusForecastID, SelectorReport, ReportFormat, toReportFormatStrict, isCashFlowOrBalanceSheetReport, isDashboardReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isPAndLReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isAgingReport, isOpExByVendorReport, isFluxAnalysisOpExReport, PageToken, };
689
+ export { View, SelectorView, Report, ReportID, toReportID, ReportIDPlusForecastID, SelectorReport, ReportFormat, toReportFormatStrict, isCashFlowOrBalanceSheetReport, isBalanceSheetReport, isBalanceSheetClassesViewReport, isBalanceSheetProjectViewReport, isGroupedBalanceSheetReport, isDashboardReport, isDashboardClassesViewReport, isDashboardProjectViewReport, isPAndLReport, isPAndLClassesViewReport, isPAndLProjectViewReport, isAgingReport, isOpExByVendorReport, isFluxAnalysisOpExReport, PageToken, };
682
690
  export { NestedClassIDHierarchy, NestedClassID, NestedClassHierarchyForReport };
683
691
  export { NestedAccountHierarchyForReport, NestedAccountID, NestedAccountIDHierarchy, };
684
692
  export { NestedCustomerID, NestedCustomerHierarchy };
@@ -749,6 +757,8 @@ export { fetchAllPeopleRequiredViews, fetchPeoplePage, fetchPeople, deletePerson
749
757
  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, MyProfileSelectorView, MyBankConnectionsView, BillingView, MyProfile, SettingsViewState, SettingsViewUIState, NotificationSettings, NotificationSettingsLocalData, ReminderNotificationSettingsLocalData, NotificationSettingsSelectorView, ReminderNotificationSettingsData, MonthEndInsightsNotificationSettingsData, MonthEndInsightsNotificationSettingsLocalData, ReminderTypeKey, NotificationModeKey, FrequencyTypeKey, RemindersLocalData, IntegrationsSettings, ProductWisePrimaryAccount, OtherPaymentAccountWithSetup, updateMyProfile, updateMyProfileLocalData, MyProfileSettingsLocalData, initializeMyProfileLocalData, };
750
758
  export { PeopleViewSortKey };
751
759
  export { fetchBalanceSheet, BalanceSheetReport, getBalanceSheet, getBalanceSheetFetchState, getBalanceSheetForFullDataAvailableRange, BalanceSheetState, BalanceSheetUIState, resetBalanceSheetNodeCollapseState, updateBalanceSheetUIState, BalanceSheetReportViewID, BalanceSheetSectionIdsWithSubSectionIds, BalanceSheetReportViewCalculatedSectionID, BalanceSheetReportViewSectionID, BalanceSheetReportViewRootSectionID, typeOfBalanceSheetRootSection, isBalanceSheetReportViewSectionID, isBalanceSheetReportViewCalculatedSectionID, fetchBalanceSheetForTimeframe, };
760
+ export { clearBalanceSheetClassesView, fetchBalanceSheetClassesView, fetchBalanceSheetForTimeframeClassesView, resetBalanceSheetClassesNodeCollapseState, updateBalanceSheetClassesToFilterOut, updateBalanceSheetClassesViewAccountViewMode, updateBalanceSheetClassesViewUIState, getBalanceSheetClassesView, BalanceSheetClassesViewReport, BalanceSheetClassesViewUIState, };
761
+ export { clearBalanceSheetProjectView, fetchBalanceSheetForTimeframeProjectView, fetchBalanceSheetProjectView, resetBalanceSheetProjectNodeCollapseState, updateBalanceSheetProjectViewAccountViewMode, updateBalanceSheetProjectViewUIState, updateBalanceSheetProjectsToFilterOut, getBalanceSheetProjectView, BalanceSheetProjectViewReport, BalanceSheetProjectViewUIState, };
752
762
  export { fetchCashFlow, CashFlowReport, getCashFlow, getCashFlowReportFetchState, CashFlowReportViewCalculatedSectionID, resetCashFlowNodeCollapseState, updateCashFlowUIState, CashFlowReportViewRootSectionID, CashFlowSectionIdsWithSubSectionIds, typeOfCashFlowRootSection, CashFlowReportViewID, isCashFlowReportViewCalculatedSectionID, isCashFlowReportViewSectionID, isCashFlowReportViewCalculatedSectionType1ID, CashFlowReportViewSectionID, fetchCashFlowForTimeframe, };
753
763
  export { FinanceStatementReport, getFinanceStatement, getReportsResyncView, fetchFinanceStatement, updateCOABalancesRange, updateSelectedReportId, updateDownloadState, updateFinanceStatementAdditionalBalancesSelection, updateFinanceStatementDisplayOrder, updateFinanceStatementFormat, };
754
764
  export { initiateReportsResync, reportsResyncSuccess, reportsResyncFailure, clearReportsResync, };
@@ -1086,7 +1096,7 @@ export type { InvoicingCustomerFormView } from './view/invoicing/editInvoicingCu
1086
1096
  export { fetchInvoicingSubscriptionFormPage, initializeInvoicingSubscriptionAddress, resetEditInvoicingSubscriptionDetailView, submitInvoicingSubscriptionForm, updateInvoicingSubscriptionFormDraft, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
1087
1097
  export type { SubmitInvoicingSubscriptionFormPayload, UpdateInvoicingSubscriptionFormDraftPayload, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewReducer';
1088
1098
  export type { InvoicingSubscriptionFormLocalData } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewState';
1089
- export { INVOICING_SUBSCRIPTION_BILLING_FREQUENCY_VALUES, INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE, entityToInvoicingSubscriptionFormLocalData, initialInvoicingSubscriptionFormLocalData, } from './view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig';
1099
+ export { INVOICING_SUBSCRIPTION_BILLING_FREQUENCY_VALUES, INVOICING_SUBSCRIPTION_SHIPPING_ADDRESS_TYPE, entityToInvoicingSubscriptionFormLocalData, initialInvoicingSubscriptionFormLocalData, invoicingSubscriptionTodayIso, toInvoicingSubscriptionQuantity, } from './view/invoicing/editInvoicingSubscriptionDetailView/invoicingSubscriptionFormConfig';
1090
1100
  export { getEditInvoicingSubscriptionDetailViewState, getInvoicingSubscriptionFormView, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
1091
1101
  export type { EditInvoicingSubscriptionDetailView, InvoicingSubscriptionFormView, } from './view/invoicing/editInvoicingSubscriptionDetailView/editInvoicingSubscriptionDetailViewSelector';
1092
1102
  export { archiveInvoicingCatalogSubFamily, createInvoicingCatalogSubFamily, resetEditInvoicingCatalogItemDetailView, saveInvoicingCatalogItem, submitInvoicingCatalogItemForm, updateInvoicingCatalogItemFormDraft, } from './view/invoicing/editInvoicingCatalogItemDetailView/editInvoicingCatalogItemDetailViewReducer';
@@ -1220,8 +1230,8 @@ export { clearInvoicingQboView, fetchInvoicingQboAccounts, fetchInvoicingQboClas
1220
1230
  export { getInvoicingQboView } from './view/invoicing/invoicingQboView/invoicingQboViewSelector';
1221
1231
  export type { InvoicingQboView } from './view/invoicing/invoicingQboView/invoicingQboViewSelector';
1222
1232
  export type { InvoicingQboAccountOption, InvoicingQboConnection, InvoicingQboFailedTask, InvoicingQboSyncHealth, } from './view/invoicing/invoicingQboView/invoicingQboViewPayload';
1223
- export { INVOICING_QBO_CUSTOMER_MATCHING_MODES, getInvoicingQboAccountMappingId, toInvoicingQboCustomerMatchingMode, withInvoicingQboAccountMappingId, } from './entity/invoicing/invoicingCommonPayload';
1224
- export type { InvoicingNamedOption, InvoicingQboAccountMappingKindOption, InvoicingQboAccountMappingsPayload, InvoicingQboCustomerMatchingMode, InvoicingQboSettingsPayload, } from './entity/invoicing/invoicingCommonPayload';
1233
+ export { INVOICING_QBO_CUSTOMER_MATCHING_MODES, getInvoicingQboAccountMappingId, toInvoicingNamedOptionsByKey, toInvoicingQboCustomerMatchingMode, withInvoicingQboAccountMappingId, } from './entity/invoicing/invoicingCommonPayload';
1234
+ export type { InvoicingNamedOption, InvoicingNamedOptionsByKey, InvoicingQboAccountMappingKindOption, InvoicingQboAccountMappingsPayload, InvoicingQboCustomerMatchingMode, InvoicingQboSettingsPayload, } from './entity/invoicing/invoicingCommonPayload';
1225
1235
  export { acceptInvoicingTerms, clearInvoicingConfig, enableInvoicing, fetchInvoicingConfig, resetInvoicingConfigActionStates, updateInvoicingConfig, } from './view/invoicing/invoicingConfigView/invoicingConfigViewReducer';
1226
1236
  export { getInvoicingConfigView } from './view/invoicing/invoicingConfigView/invoicingConfigViewSelector';
1227
1237
  export type { InvoicingConfigView } from './view/invoicing/invoicingConfigView/invoicingConfigViewSelector';