@zeniai/client-epic-state 4.11.96 → 4.11.97

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 (67) hide show
  1. package/lib/commonStateTypes/animations.d.ts +2 -0
  2. package/lib/commonStateTypes/animations.js +32 -0
  3. package/lib/commonStateTypes/coaBalance/coaBalance.d.ts +3 -1
  4. package/lib/commonStateTypes/viewAndReport/reportUIState.d.ts +2 -2
  5. package/lib/entity/company/companyPayload.d.ts +0 -8
  6. package/lib/entity/company/companyPayload.js +0 -2
  7. package/lib/entity/company/companyStateTypes.d.ts +0 -2
  8. package/lib/index.d.ts +8 -6
  9. package/lib/index.js +21 -18
  10. package/lib/view/balanceSheet/balanceSheetSelector.d.ts +6 -1
  11. package/lib/view/balanceSheet/balanceSheetSelector.js +28 -9
  12. package/lib/view/balanceSheet/balanceSheetSelectorTypes.d.ts +5 -0
  13. package/lib/view/billPayCard/fetchBillPayCardEpic.js +1 -1
  14. package/lib/view/cashFlow/cashFlowSelector.d.ts +6 -1
  15. package/lib/view/cashFlow/cashFlowSelector.js +28 -13
  16. package/lib/view/cashFlow/cashFlowSelectorTypes.d.ts +5 -0
  17. package/lib/view/financeStatement/financeStatementEpic.d.ts +4 -10
  18. package/lib/view/financeStatement/financeStatementEpic.js +48 -17
  19. package/lib/view/financeStatement/financeStatementReducer.d.ts +2 -1
  20. package/lib/view/financeStatement/financeStatementReducer.js +5 -2
  21. package/lib/view/financeStatement/financeStatementSelector.d.ts +2 -1
  22. package/lib/view/financeStatement/financeStatementSelector.js +29 -4
  23. package/lib/view/profitAndLoss/profitAndLossSelector.d.ts +9 -1
  24. package/lib/view/profitAndLoss/profitAndLossSelector.js +28 -13
  25. package/lib/view/profitAndLoss/profitAndLossState.d.ts +3 -6
  26. package/lib/view/reimbursementCard/fetchReimbursementCardEpic.js +1 -1
  27. package/lib/view/spendManagement/billPay/billDetailView/epics/approveOrRejectBillEpic.js +1 -1
  28. package/lib/view/spendManagement/billPay/billDetailView/epics/cancelAndDeleteBillEpic.js +1 -1
  29. package/lib/view/spendManagement/billPay/billDetailView/epics/deleteBillEpic.js +1 -1
  30. package/lib/view/spendManagement/billPay/billDetailView/epics/fetchBillDetailEpic.js +1 -1
  31. package/lib/view/spendManagement/billPay/billList/fetchBillListPerTabEpic.js +1 -1
  32. package/lib/view/spendManagement/billPay/billPayConfig/fetchBillPayConfigEpic.js +1 -1
  33. package/lib/view/spendManagement/billPay/billsBulkActionView/epics/approveOrRejectBillsBulkActionEpic.js +1 -1
  34. package/lib/view/spendManagement/billPay/billsBulkActionView/epics/cancelOrDeleteBillsBulkActionEpic.js +1 -1
  35. package/lib/view/spendManagement/billPay/billsBulkActionView/epics/reviewDraftBillsBulkActionEpic.ts.js +1 -1
  36. package/lib/view/spendManagement/billPay/billsBulkActionView/epics/submitDraftBillsBulkActionEpic.js +1 -1
  37. package/lib/view/spendManagement/billPay/editBillView/epics/convertAmountToHomeCurrencyEpic.js +1 -1
  38. package/lib/view/spendManagement/billPay/editBillView/epics/saveBillDetailEpic.js +1 -1
  39. package/lib/view/spendManagement/billPay/magicLinkView/epics/fetchMagicLinkBillEpic.js +1 -1
  40. package/lib/view/spendManagement/billPay/previousBills/fetchPreviousBillsEpic.js +1 -1
  41. package/lib/view/spendManagement/commonHistoryView/fetchEntityHistoryEpic.js +1 -1
  42. package/lib/view/spendManagement/plaidAccount/epic/paymentAccounts/updateMappedCashAccountEpic.js +1 -1
  43. package/lib/view/spendManagement/reimbursement/editRemiView/epics/fetchCurrencyConversionValueEpic.js +1 -1
  44. package/lib/view/spendManagement/reimbursement/editRemiView/epics/saveRemiDetailEpic.js +2 -2
  45. package/lib/view/spendManagement/reimbursement/reimbursementConfig/fetchReimbursementConfigEpic.js +1 -1
  46. package/lib/view/spendManagement/reimbursement/remiDetailView/epics/approveOrRejectRemiEpic.js +1 -1
  47. package/lib/view/spendManagement/reimbursement/remiDetailView/epics/cancelAndDeleteRemiEpic.js +1 -1
  48. package/lib/view/spendManagement/reimbursement/remiDetailView/epics/deleteRemiEpic.js +1 -1
  49. package/lib/view/spendManagement/reimbursement/remiDetailView/epics/fetchDuplicateReimbursementEpic.js +1 -1
  50. package/lib/view/spendManagement/reimbursement/remiDetailView/epics/fetchRemiDetailEpic.js +1 -1
  51. package/lib/view/spendManagement/reimbursement/remiListView/fetchRemiListPerTabEpic.js +1 -1
  52. package/lib/view/spendManagement/zeniAccounts/checkDeposit/checkDepositEpic.js +1 -1
  53. package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountEpic.js +1 -1
  54. package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/fetchDepositAccountHistoryEpic.js +1 -1
  55. package/lib/view/spendManagement/zeniAccounts/depositAccountDetail/updateDepositAccountEpic.js +1 -1
  56. package/lib/view/spendManagement/zeniAccounts/depositAccountList/fetchDepositAccountListEpic.js +1 -1
  57. package/lib/view/spendManagement/zeniAccounts/depositAccountTransactionList/fetchDepositAccountTransactionListEpic.js +1 -1
  58. package/lib/view/spendManagement/zeniAccounts/transferDetail/fetchReviewTransferDetailEpic.js +1 -1
  59. package/lib/view/spendManagement/zeniAccounts/transferDetail/transferMoneyEpic.js +1 -1
  60. package/lib/view/spendManagement/zeniAccounts/zeniAccountList/createCheckingAccountEpic.js +1 -1
  61. package/lib/view/spendManagement/zeniAccounts/zeniAccountList/zeniAccountListSelector.d.ts +1 -4
  62. package/lib/view/spendManagement/zeniAccounts/zeniAccountList/zeniAccountListSelector.js +1 -5
  63. package/lib/view/spendManagement/zeniAccounts/zeniAccountsConfig/fetchZeniAccountsConfigEpic.js +1 -1
  64. package/lib/view/zeniAccStatementList/fetchZeniAccStatementListEpic.js +2 -2
  65. package/lib/view/zeniAccountsPromoCard/zeniAccountsPromoCardEpic.js +1 -1
  66. package/lib/zeniAPI.d.ts +2 -0
  67. package/package.json +1 -1
@@ -8,24 +8,18 @@ import { fetchCashFlow } from '../cashFlow/cashFlowReducer';
8
8
  export declare type ActionType = ReturnType<typeof fetchFinanceStatement> | ReturnType<typeof fetchAllTenants> | ReturnType<typeof fetchProfitAndLoss> | ReturnType<typeof fetchBalanceSheet> | ReturnType<typeof fetchCashFlow>;
9
9
  export declare const fetchFinanceStatementEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>) => import("rxjs").Observable<{
10
10
  payload: {
11
- userId: string;
12
- zeniSessionId: string | undefined;
13
- };
14
- type: string;
15
- } | {
16
- payload: {
17
- forecastId: string | undefined;
18
- cacheOverride: boolean;
11
+ timeframe: "month" | "year" | "quarter";
12
+ fetchFullReport: boolean;
19
13
  };
20
14
  type: string;
21
15
  } | {
22
16
  payload: {
23
- cacheOverride: boolean;
17
+ userId: string;
18
+ zeniSessionId: string | undefined;
24
19
  };
25
20
  type: string;
26
21
  } | {
27
22
  payload: {
28
- fetchFullReport: boolean;
29
23
  cacheOverride: boolean;
30
24
  };
31
25
  type: string;
@@ -12,31 +12,62 @@ const cashFlowSelector_1 = require("../cashFlow/cashFlowSelector");
12
12
  const cashFlowReducer_1 = require("../cashFlow/cashFlowReducer");
13
13
  const balanceSheetSelector_1 = require("../balanceSheet/balanceSheetSelector");
14
14
  const fetchFinanceStatementEpic = (actions$, state$) => actions$.pipe((0, operators_1.filter)(financeStatementReducer_1.fetchFinanceStatement.match), (0, operators_1.switchMap)((action) => {
15
- const { userId, fetchFullReport, cacheOverride } = action.payload;
15
+ const { userId, fetchSelectedTab, fetchFullReport, cacheOverride } = action.payload;
16
+ const state = state$.value;
16
17
  if (cacheOverride === true) {
17
18
  return (0, rxjs_1.of)((0, tenantReducer_1.fetchAllTenants)(userId), (0, profitAndLossReducer_1.fetchProfitAndLoss)(), (0, balanceSheetReducer_1.fetchBalanceSheet)(), (0, cashFlowReducer_1.fetchCashFlow)());
18
19
  }
19
20
  else {
20
- const state = state$.value;
21
+ const { tenantState, financeStatementState } = state;
21
22
  const fetchActions = [];
22
- if (state.tenantState.fetchState !== 'In-Progress' &&
23
- !state.tenantState.hasValidState()) {
23
+ if (tenantState.fetchState !== 'In-Progress' &&
24
+ !tenantState.hasValidState()) {
24
25
  fetchActions.push((0, tenantReducer_1.fetchAllTenants)(userId));
25
26
  }
26
- const pandLFetchState = (0, profitAndLossSelector_1.getPandLReportFetchState)(undefined, state.profitAndLossState).fetchState;
27
- if (pandLFetchState !== 'In-Progress' &&
28
- pandLFetchState !== 'Completed') {
29
- fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLoss)());
27
+ const pandLFetchState = (0, profitAndLossSelector_1.getPandLReportFetchState)(undefined, state.profitAndLossState);
28
+ const balanceSheetFetchState = (0, balanceSheetSelector_1.getBalanceSheetFetchState)(state.balanceSheetState);
29
+ const cashFlowFetchState = (0, cashFlowSelector_1.getCashFlowReportFetchState)(state.cashFlowState);
30
+ if (fetchSelectedTab) {
31
+ switch (financeStatementState.selectedReportId) {
32
+ case 'profit_and_loss':
33
+ case 'profit_and_loss_by_classes':
34
+ if (pandLFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
35
+ pandLFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
36
+ fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLossForTimeframe)(financeStatementState.timeframe));
37
+ }
38
+ break;
39
+ case 'balance_sheet':
40
+ if (balanceSheetFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
41
+ balanceSheetFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
42
+ fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheetForTimeframe)(financeStatementState.timeframe));
43
+ }
44
+ break;
45
+ case 'cash_flow':
46
+ if (cashFlowFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'In-Progress' &&
47
+ cashFlowFetchState.fetchStateByTimeframe[financeStatementState.timeframe].fetchState !== 'Completed') {
48
+ fetchActions.push((0, cashFlowReducer_1.fetchCashFlowForTimeframe)(financeStatementState.timeframe, fetchFullReport));
49
+ }
50
+ break;
51
+ default:
52
+ break;
53
+ }
30
54
  }
31
- const balanceSheetFetchState = (0, balanceSheetSelector_1.getBalanceSheetFetchState)(state.balanceSheetState).fetchState;
32
- if (balanceSheetFetchState !== 'In-Progress' &&
33
- balanceSheetFetchState !== 'Completed') {
34
- fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheet)(fetchFullReport));
35
- }
36
- const cashFlowFetchState = (0, cashFlowSelector_1.getCashFlowReportFetchState)(state.cashFlowState).fetchState;
37
- if (cashFlowFetchState !== 'In-Progress' &&
38
- cashFlowFetchState !== 'Completed') {
39
- fetchActions.push((0, cashFlowReducer_1.fetchCashFlow)(fetchFullReport));
55
+ else {
56
+ if (pandLFetchState.reducedAllFetchState.fetchState !== 'In-Progress' &&
57
+ pandLFetchState.reducedAllFetchState.fetchState !== 'Completed') {
58
+ fetchActions.push((0, profitAndLossReducer_1.fetchProfitAndLoss)());
59
+ }
60
+ if (balanceSheetFetchState.reducedAllFetchState.fetchState !==
61
+ 'In-Progress' &&
62
+ balanceSheetFetchState.reducedAllFetchState.fetchState !==
63
+ 'Completed') {
64
+ fetchActions.push((0, balanceSheetReducer_1.fetchBalanceSheet)(fetchFullReport));
65
+ }
66
+ if (cashFlowFetchState.reducedAllFetchState.fetchState !==
67
+ 'In-Progress' &&
68
+ cashFlowFetchState.reducedAllFetchState.fetchState !== 'Completed') {
69
+ fetchActions.push((0, cashFlowReducer_1.fetchCashFlow)(fetchFullReport));
70
+ }
40
71
  }
41
72
  return (0, rxjs_1.from)(fetchActions);
42
73
  }
@@ -7,8 +7,9 @@ import { COABalanceType } from '../../commonStateTypes/coaBalance/coaBalanceType
7
7
  import { FinanceStatementState } from './financeStatementState';
8
8
  import { Month } from '../../commonStateTypes/timePeriod';
9
9
  export declare const initialFinanceStatementState: FinanceStatementState;
10
- export declare const fetchFinanceStatement: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, fetchFullReport?: boolean | undefined, cacheOverride?: boolean | undefined], {
10
+ export declare const fetchFinanceStatement: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[userId: string, fetchSelectedTab?: boolean | undefined, fetchFullReport?: boolean | undefined, cacheOverride?: boolean | undefined], {
11
11
  userId: string;
12
+ fetchSelectedTab: boolean;
12
13
  fetchFullReport: boolean;
13
14
  cacheOverride: boolean;
14
15
  }, string, never, never>, updateFinanceStatementTimeframe: import("@reduxjs/toolkit").ActionCreatorWithPayload<"month" | "year" | "quarter", string>, updateFinanceStatementThisPeriod: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
@@ -29,10 +29,13 @@ const financeStatement = (0, toolkit_1.createSlice)({
29
29
  reducer(draft) {
30
30
  draft.lastFetchRequestTime = (0, zeniDayJS_1.dateNow)();
31
31
  },
32
- prepare(userId, fetchFullReport = false, // eslint-disable-line @typescript-eslint/no-inferrable-types,
32
+ prepare(userId, fetchSelectedTab = true, // eslint-disable-line @typescript-eslint/no-inferrable-types,
33
+ fetchFullReport = false, // eslint-disable-line @typescript-eslint/no-inferrable-types,
33
34
  cacheOverride = false // eslint-disable-line @typescript-eslint/no-inferrable-types
34
35
  ) {
35
- return { payload: { userId, fetchFullReport, cacheOverride } };
36
+ return {
37
+ payload: { userId, fetchSelectedTab, fetchFullReport, cacheOverride },
38
+ };
36
39
  },
37
40
  },
38
41
  updateFinanceStatementTimeframe(draft, action) {
@@ -1,5 +1,5 @@
1
1
  import { RootState } from '../../reducer';
2
- import { FetchState } from '../../commonStateTypes/common';
2
+ import { FetchState, FetchStateAndError } from '../../commonStateTypes/common';
3
3
  import { SelectorReport, ReportID, ReportFormat } from '../../commonStateTypes/viewAndReport/viewAndReport';
4
4
  import { TimeframeTickWithMetaData } from '../../commonStateTypes/timeframeTick';
5
5
  import { COABalancesFilter, COABalancesOrder } from '../../commonStateTypes/coaBalance/coaBalancesFilter';
@@ -13,6 +13,7 @@ export interface FinanceStatementReport extends SelectorReport {
13
13
  allTimeframeTicks: TimeframeTickWithMetaData[];
14
14
  balancesInTimeframe: COABalance[];
15
15
  dataAvailable?: DataAvailable;
16
+ selectedReportAndTimeframeFetchState: FetchStateAndError;
16
17
  profitAndLossReport: ProfitAndLossReport;
17
18
  profitAndLossByClassReport: ProfitAndLossClassesViewReport;
18
19
  balanceSheetReport: BalanceSheetReport;
@@ -66,11 +66,35 @@ exports.getFinanceStatement = (0, toolkit_1.createSelector)((state) => state.acc
66
66
  const balanceSheetReport = (0, balanceSheetSelector_1.getBalanceSheet)(filter, accountState, accountGroupState, sectionAccountsViewState, balanceSheetState);
67
67
  const cashFlowReport = (0, cashFlowSelector_1.getCashFlow)(filter, accountState, accountGroupState, sectionAccountsViewState, cashFlowState);
68
68
  const allReports = [
69
- profitAndLossReport,
70
- balanceSheetReport,
71
- cashFlowReport,
69
+ profitAndLossReport.reducedAnyFetchState,
70
+ balanceSheetReport.reducedAnyFetchState,
71
+ cashFlowReport.reducedAnyFetchState,
72
72
  ];
73
- const fetchState = (0, reduceFetchState_1.reduceFetchState)(allReports);
73
+ const fetchState = (0, reduceFetchState_1.reduceAnyCompletedFetchState)(allReports);
74
+ let selectedReportAndTimeframeFetchState = fetchState;
75
+ switch (financeStatementState.selectedReportId) {
76
+ case 'profit_and_loss':
77
+ case 'profit_and_loss_by_classes':
78
+ selectedReportAndTimeframeFetchState = {
79
+ fetchState: profitAndLossReport.fetchState,
80
+ error: profitAndLossReport.error,
81
+ };
82
+ break;
83
+ case 'balance_sheet':
84
+ selectedReportAndTimeframeFetchState = {
85
+ fetchState: balanceSheetReport.fetchState,
86
+ error: balanceSheetReport.error,
87
+ };
88
+ break;
89
+ case 'cash_flow':
90
+ selectedReportAndTimeframeFetchState = {
91
+ fetchState: cashFlowReport.fetchState,
92
+ error: cashFlowReport.error,
93
+ };
94
+ break;
95
+ default:
96
+ break;
97
+ }
74
98
  return {
75
99
  reportId: 'finance_statement',
76
100
  reportTitle: '',
@@ -79,6 +103,7 @@ exports.getFinanceStatement = (0, toolkit_1.createSelector)((state) => state.acc
79
103
  error: fetchState.error,
80
104
  allTimeframeTicks,
81
105
  balancesInTimeframe,
106
+ selectedReportAndTimeframeFetchState,
82
107
  displayOrder: financeStatementState.displayOrder,
83
108
  reportFormat: financeStatementState.reportFormat,
84
109
  firstMonthOfFY,
@@ -7,8 +7,12 @@ import { ForecastState } from '../../entity/forecast/forecastState';
7
7
  import { SectionAccountsViewState } from '../../entity/sectionAccountsView/sectionAccountsViewState';
8
8
  import { PandLReportViewCalculatedSectionID, PandLReportViewSectionID } from '../profitAndLossClassesView/profitAndLossClassesViewSelectorTypes';
9
9
  import { ProfitAndLossUIState, ProfitAndLossWithForecastState } from './profitAndLossState';
10
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
10
11
  export interface ProfitAndLossReport extends AccountsViewSelectorReport<PandLReportViewSectionID, PandLReportViewCalculatedSectionID> {
11
12
  uiState: ProfitAndLossUIState;
13
+ fetchStateByTimeframe: FetchStateByTimeframe;
14
+ reducedAnyFetchState: FetchStateAndError;
15
+ reducedAllFetchState: FetchStateAndError;
12
16
  }
13
17
  /**
14
18
  * Get P&L with forecast data overlaid on actuals.
@@ -37,4 +41,8 @@ export declare const getProfitAndLossReport: (filter: COABalancesFilter, forecas
37
41
  * @param state
38
42
  */
39
43
  export declare function getProfitAndLossForFullDataAvailableRange(timeframe: 'month' | 'quarter' | 'year', forecastId: ID | undefined, accountState: AccountState, accountGroupState: AccountGroupState, sectionsState: SectionAccountsViewState, forecastState: ForecastState, state: ProfitAndLossWithForecastState): ProfitAndLossReport;
40
- export declare const getPandLReportFetchState: (forecastId: ID | undefined, profitAndLossState: ProfitAndLossWithForecastState) => FetchStateAndError;
44
+ export declare const getPandLReportFetchState: (forecastId: ID | undefined, profitAndLossState: ProfitAndLossWithForecastState) => {
45
+ reducedAnyFetchState: FetchStateAndError;
46
+ reducedAllFetchState: FetchStateAndError;
47
+ fetchStateByTimeframe: FetchStateByTimeframe;
48
+ };
@@ -30,16 +30,16 @@ function getProfitAndLossWithForecastOnDataAvailableDateRange(filter, forecastId
30
30
  }
31
31
  exports.getProfitAndLossWithForecastOnDataAvailableDateRange = getProfitAndLossWithForecastOnDataAvailableDateRange;
32
32
  const getProfitAndLossReport = (filter, forecastId, accountState, accountGroupState, sectionsState, profitAndLossState, forecastState) => {
33
+ if (filter.timeframe === 'week' || filter.timeframe === 'free_range') {
34
+ throw Error('free_range or week period is invalid');
35
+ }
33
36
  const pandLState = (0, profitAndLossReducer_1.getState)(profitAndLossState, forecastId);
34
- const fetchState = (0, reduceFetchState_1.reduceAnyFetchState)([
35
- pandLState.fetchState.month,
36
- pandLState.fetchState.quarter,
37
- pandLState.fetchState.year,
38
- ]);
37
+ const { reducedAllFetchState, reducedAnyFetchState, fetchStateByTimeframe } = (0, exports.getPandLReportFetchState)(forecastId, profitAndLossState);
39
38
  const reportId = (0, profitAndLossForTimeframeEpic_1.reportIdUniqueKey)(forecastId);
40
39
  const sections = {};
41
40
  const calculatedSections = {};
42
- if (fetchState.fetchState === 'Completed') {
41
+ const selectedTimeframeFetchState = fetchStateByTimeframe[filter.timeframe];
42
+ if (selectedTimeframeFetchState.fetchState === 'Completed') {
43
43
  profitAndLossClassesViewSelectorTypes_1.ALL_PANDL_REPORT_VIEW_SECTION_IDS.forEach((sectionId) => {
44
44
  sections[`${sectionId}`] = (0, sectionAccountsViewSelector_1.getSectionAccountsViewReport)(accountState, accountGroupState, sectionsState, {
45
45
  reportId,
@@ -67,8 +67,11 @@ const getProfitAndLossReport = (filter, forecastId, accountState, accountGroupSt
67
67
  bookCloseDate: pandLState.bookCloseDate,
68
68
  version: pandLState.version,
69
69
  status: pandLState.status,
70
- fetchState: fetchState.fetchState,
71
- error: fetchState.error,
70
+ reducedAllFetchState,
71
+ reducedAnyFetchState,
72
+ fetchStateByTimeframe,
73
+ fetchState: selectedTimeframeFetchState.fetchState,
74
+ error: selectedTimeframeFetchState.error,
72
75
  filter: filter,
73
76
  uiState: pandLState.uiState,
74
77
  idsInOrder: profitAndLossClassesViewSelector_1.profitAndLossIdsInOrder,
@@ -95,10 +98,22 @@ function getProfitAndLossForFullDataAvailableRange(timeframe, forecastId, accoun
95
98
  exports.getProfitAndLossForFullDataAvailableRange = getProfitAndLossForFullDataAvailableRange;
96
99
  const getPandLReportFetchState = (forecastId, profitAndLossState) => {
97
100
  const pandLState = (0, profitAndLossReducer_1.getState)(profitAndLossState, forecastId);
98
- return (0, reduceFetchState_1.reduceAnyFetchState)([
99
- pandLState.fetchState.month,
100
- pandLState.fetchState.quarter,
101
- pandLState.fetchState.year,
102
- ]);
101
+ return {
102
+ reducedAnyFetchState: (0, reduceFetchState_1.reduceAnyCompletedFetchState)([
103
+ pandLState.fetchState.month,
104
+ pandLState.fetchState.quarter,
105
+ pandLState.fetchState.year,
106
+ ]),
107
+ reducedAllFetchState: (0, reduceFetchState_1.reduceAllFetchState)([
108
+ pandLState.fetchState.month,
109
+ pandLState.fetchState.quarter,
110
+ pandLState.fetchState.year,
111
+ ]),
112
+ fetchStateByTimeframe: {
113
+ month: pandLState.fetchState.month,
114
+ quarter: pandLState.fetchState.quarter,
115
+ year: pandLState.fetchState.year,
116
+ },
117
+ };
103
118
  };
104
119
  exports.getPandLReportFetchState = getPandLReportFetchState;
@@ -1,4 +1,5 @@
1
- import { FetchStateAndError, ID } from '../../commonStateTypes/common';
1
+ import { FetchStateByTimeframe } from '../../commonStateTypes/coaBalance/coaBalance';
2
+ import { ID } from '../../commonStateTypes/common';
2
3
  import { Report } from '../../commonStateTypes/viewAndReport/viewAndReport';
3
4
  export interface ProfitAndLossUIState {
4
5
  nodeCollapseState: Record<ID, boolean>;
@@ -10,11 +11,7 @@ export interface ProfitAndLossUIState {
10
11
  export interface ProfitAndLossState extends Report {
11
12
  uiState: ProfitAndLossUIState;
12
13
  forecastId?: ID;
13
- fetchState: {
14
- month: FetchStateAndError;
15
- quarter: FetchStateAndError;
16
- year: FetchStateAndError;
17
- };
14
+ fetchState: FetchStateByTimeframe;
18
15
  }
19
16
  export interface ProfitAndLossWithForecastState {
20
17
  pandL: ProfitAndLossState;
@@ -28,7 +28,7 @@ const fetchReimbursementCardEpic = (actions$, _state$, zeniAPI) => actions$.pipe
28
28
  get_count_only: true,
29
29
  };
30
30
  return zeniAPI
31
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursement-card?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
31
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursement-card?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
32
32
  .pipe((0, operators_1.mergeMap)((response) => {
33
33
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
34
34
  return (0, rxjs_1.of)((0, reimbursementCardReducer_1.updateReimbursementCard)({
@@ -16,7 +16,7 @@ const approveOrRejectBillEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
16
16
  description,
17
17
  };
18
18
  return zeniAPI
19
- .putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}/approval-status`, payload)
19
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${billId}/approval-status`, payload)
20
20
  .pipe((0, operators_1.mergeMap)((response) => {
21
21
  var _a, _b;
22
22
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
@@ -20,7 +20,7 @@ const cancelAndDeleteBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
20
20
  const transaction = billTransactionState.transactionById[action.payload.billId];
21
21
  const isRecurring = (_a = transaction === null || transaction === void 0 ? void 0 : transaction.isRecurring) !== null && _a !== void 0 ? _a : false;
22
22
  const recurringConfigId = transaction === null || transaction === void 0 ? void 0 : transaction.recurringBillConfigId;
23
- let cancelApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
23
+ let cancelApiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
24
24
  if (isRecurring === true) {
25
25
  cancelApiUrl = `${cancelApiUrl}/recurring/cancel-payment`;
26
26
  }
@@ -20,7 +20,7 @@ const deleteBillEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operator
20
20
  const transaction = billTransactionState.transactionById[action.payload.billId];
21
21
  const isRecurring = (_a = transaction === null || transaction === void 0 ? void 0 : transaction.isRecurring) !== null && _a !== void 0 ? _a : false;
22
22
  const recurringConfigId = transaction === null || transaction === void 0 ? void 0 : transaction.recurringBillConfigId;
23
- let deleteApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
23
+ let deleteApiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${action.payload.billId}`;
24
24
  if (isRecurring === true) {
25
25
  deleteApiUrl = `${deleteApiUrl}/recurring`;
26
26
  }
@@ -53,7 +53,7 @@ const fetchBillDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, ope
53
53
  is_include_deleted: isShowDeletedBillsEnabled,
54
54
  };
55
55
  const getTransactionDetail$ = zeniAPI
56
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}?query=${encodeURIComponent(JSON.stringify(query))}`)
56
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${billId}?query=${encodeURIComponent(JSON.stringify(query))}`)
57
57
  .pipe((0, operators_1.mergeMap)((response) => {
58
58
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p;
59
59
  if ((0, responsePayload_1.isSuccessResponse)(response) &&
@@ -25,7 +25,7 @@ const fetchBillListPerTabEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
25
25
  is_include_deleted: isShowDeletedBillsEnabled ? tab !== 'draft' : false,
26
26
  };
27
27
  return zeniAPI
28
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
28
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
29
29
  .pipe((0, operators_1.mergeMap)((response) => {
30
30
  var _a, _b;
31
31
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
@@ -13,7 +13,7 @@ const fetchBillPayConfigEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0,
13
13
  is_include_payment_accounts_info: true,
14
14
  };
15
15
  return zeniAPI
16
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bill-pay/config?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
16
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bill-pay/config?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
17
17
  .pipe((0, operators_1.mergeMap)((response) => {
18
18
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
19
19
  const updateActions = [];
@@ -13,7 +13,7 @@ const approveOrRejectBillsBulkActionEpic = (actions$, state$, zeniAPI) => action
13
13
  const transactionIds = billsBulkActionViewState.billsSelectedForBulkAction;
14
14
  const payload = prepareBulkApproveOrRejectPayload(transactionIds, approvalType, description);
15
15
  return zeniAPI
16
- .putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`, payload)
16
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bulk/bills/transactions`, payload)
17
17
  .pipe((0, operators_1.mergeMap)((response) => {
18
18
  var _a, _b, _c, _d, _e, _f;
19
19
  if ((0, responsePayload_1.isSuccessStatus)(response)) {
@@ -12,7 +12,7 @@ const cancelOrDeleteBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions
12
12
  const { billsBulkActionViewState } = state$.value;
13
13
  const transactionIds = billsBulkActionViewState.billsSelectedForBulkAction;
14
14
  const payload = prepareBulkCancelOrDeletePayload(transactionIds, operationType, description);
15
- const bulkApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
15
+ const bulkApiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
16
16
  const api = operationType === 'cancel'
17
17
  ? zeniAPI.putAndGetJSON(bulkApiUrl, payload)
18
18
  : zeniAPI.deleteAndGetJSON(bulkApiUrl, payload);
@@ -12,7 +12,7 @@ const reviewDraftBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions$.p
12
12
  entity_ids: transactionIds,
13
13
  };
14
14
  return zeniAPI
15
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills//transactions/validate?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
15
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bulk/bills/transactions/validate?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
16
16
  .pipe((0, operators_1.mergeMap)((response) => {
17
17
  var _a, _b;
18
18
  if ((0, responsePayload_1.isSuccessStatus)(response)) {
@@ -11,7 +11,7 @@ const editBillViewSelector_1 = require("../../editBillView/editBillViewSelector"
11
11
  const submitDraftBillsBulkActionEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(billsBulkActionViewReducer_1.submitDraftBillsBulkAction.match), (0, operators_1.mergeMap)(() => {
12
12
  const { billsBulkActionViewState, billTransactionState } = state$.value;
13
13
  const payload = prepareBulkSubmitPayload(billsBulkActionViewState, billTransactionState);
14
- const bulkApiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
14
+ const bulkApiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bulk/bills/transactions`;
15
15
  return zeniAPI
16
16
  .putAndGetJSON(bulkApiUrl, payload)
17
17
  .pipe((0, operators_1.mergeMap)((response) => {
@@ -27,7 +27,7 @@ const convertAmountToHomeCurrencyEpic = (actions$, state$, zeniAPI) => actions$.
27
27
  home_currency_code: conversionCurrencyCode,
28
28
  };
29
29
  return zeniAPI
30
- .postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/currencies/conversion`, payload)
30
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/currencies/conversion`, payload)
31
31
  .pipe((0, operators_1.mergeMap)((response) => {
32
32
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
33
33
  const updateActions = [];
@@ -32,7 +32,7 @@ const saveBillDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
32
32
  : state.editBillDetailViewState.newBillState;
33
33
  const payload = prepareSaveBillPayload(state.accountState, state.billTransactionState, state.paymentAccountState, state.recurringBillState, billDetail, billStageCode);
34
34
  const isRecurringBill = billDetail.billDetailLocalData.isRecurring;
35
- const saveBillBaseURL = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions`;
35
+ const saveBillBaseURL = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions`;
36
36
  const saveBillApi = billId != null
37
37
  ? zeniAPI.putAndGetJSON(getSaveBillApiURL(saveBillBaseURL, isRecurringBill, billId, state.billTransactionState), payload)
38
38
  : zeniAPI.postAndGetJSON(getSaveBillApiURL(saveBillBaseURL, isRecurringBill), payload);
@@ -8,7 +8,7 @@ const responsePayload_1 = require("../../../../../responsePayload");
8
8
  const attachmentPayload_1 = require("../../../../../entity/transaction/payloadTypes/attachmentPayload");
9
9
  const fetchMagicLinkBillEpic = (actions$, _, zeniAPI) => actions$.pipe((0, operators_1.filter)(magicLinkViewReducer_1.fetchBillAttachment.match), (0, operators_1.mergeMap)((action) => {
10
10
  const { billId } = action.payload;
11
- let apiUrl = `${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions/${billId}`;
11
+ let apiUrl = `${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions/${billId}`;
12
12
  const queryParam = {
13
13
  transaction_type: 'bill',
14
14
  bill_pay_provider: 'zeni',
@@ -34,7 +34,7 @@ const fetchPreviousBillsEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
34
34
  limit: 3,
35
35
  };
36
36
  return zeniAPI
37
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
37
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/bills/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
38
38
  .pipe((0, operators_1.mergeMap)((response) => {
39
39
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
40
40
  const updateActions = [];
@@ -26,7 +26,7 @@ const fetchEntityHistoryEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
26
26
  }));
27
27
  const entityTypeInUrl = entityType === 'bill_pay' ? 'bill' : entityType;
28
28
  const getHistoryDetail$ = zeniAPI
29
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/${entityTypeInUrl}s/transactions/${entityId}/history`)
29
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/${entityTypeInUrl}s/transactions/${entityId}/history`)
30
30
  .pipe((0, operators_1.mergeMap)((response) => {
31
31
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
32
32
  return (0, rxjs_1.of)((0, commonHistoryReducer_1.updateCommonHistory)({
@@ -9,7 +9,7 @@ const depositAccountReducer_1 = require("../../../../../entity/depositAccount/de
9
9
  const updateMappedCashAccountEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(plaidAccountViewReducer_1.updateMappedCashAccount.match), (0, operators_1.mergeMap)((action) => {
10
10
  const { plaidAccountKeyType, accountId, depositAccountId } = action.payload;
11
11
  return zeniAPI
12
- .putAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}`, {
12
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${depositAccountId}`, {
13
13
  zeni_mapped_account_id: accountId,
14
14
  })
15
15
  .pipe((0, operators_1.mergeMap)((response) => {
@@ -25,7 +25,7 @@ const fetchCurrencyConversionValueEpic = (actions$, state$, zeniAPI) => actions$
25
25
  home_currency_code: conversionCurrencyCode,
26
26
  };
27
27
  return zeniAPI
28
- .postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/currencies/conversion`, payload)
28
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/currencies/conversion`, payload)
29
29
  .pipe((0, operators_1.mergeMap)((response) => {
30
30
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
31
31
  const updateActions = [];
@@ -29,8 +29,8 @@ const saveRemiDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
29
29
  : state.editRemiDetailViewState.newRemiState;
30
30
  const payload = prepareSaveRemiPayload(state.reimbursementState, state.tenantState, remiDetail, remiStageCode, isSubmitted);
31
31
  const saveVendorApi = reimbursementId != null
32
- ? zeniAPI.putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}`, payload)
33
- : zeniAPI.postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions`, payload);
32
+ ? zeniAPI.putAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}`, payload)
33
+ : zeniAPI.postAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions`, payload);
34
34
  return saveVendorApi.pipe((0, operators_1.mergeMap)((response) => {
35
35
  var _a, _b, _c;
36
36
  if ((0, responsePayload_1.isSuccessResponse)(response) &&
@@ -8,7 +8,7 @@ const responsePayload_1 = require("../../../../responsePayload");
8
8
  const currencyReducer_1 = require("../../../../entity/currency/currencyReducer");
9
9
  const fetchReimbursementConfigEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(reimbursementConfigReducer_1.fetchReimbursementConfig.match), (0, operators_1.mergeMap)(() => {
10
10
  return zeniAPI
11
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/config`)
11
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/config`)
12
12
  .pipe((0, operators_1.mergeMap)((response) => {
13
13
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
14
14
  const updateActions = [];
@@ -16,7 +16,7 @@ const approveOrRejectRemiEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
16
16
  description,
17
17
  };
18
18
  return zeniAPI
19
- .putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}/approval-status`, payload)
19
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}/approval-status`, payload)
20
20
  .pipe((0, operators_1.mergeMap)((response) => {
21
21
  var _a, _b;
22
22
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
@@ -16,7 +16,7 @@ const cancelAndDeleteRemiEpic = (actions$, state$, zeniAPI) => actions$.pipe((0,
16
16
  const { reimbursementState } = state$.value;
17
17
  const transaction = reimbursementState.reimbursementById[action.payload.reimbursementId];
18
18
  return zeniAPI
19
- .putAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}/cancel-payment`, query)
19
+ .putAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}/cancel-payment`, query)
20
20
  .pipe((0, operators_1.mergeMap)((response) => {
21
21
  var _a, _b;
22
22
  if (action.payload.isDeleteRemi === true &&
@@ -16,7 +16,7 @@ const deleteRemiEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operator
16
16
  const { reimbursementState } = state$.value;
17
17
  const transaction = reimbursementState.reimbursementById[action.payload.reimbursementId];
18
18
  return zeniAPI
19
- .deleteAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
19
+ .deleteAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/${action.payload.reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
20
20
  .pipe((0, operators_1.mergeMap)((response) => {
21
21
  if ((0, responsePayload_1.isSuccessStatus)(response)) {
22
22
  const actions = [
@@ -49,7 +49,7 @@ const fetchDuplicateReimbursementEpic = (actions$, state$, zeniAPI) => actions$.
49
49
  lines: lines.map(reimbursementPayload_1.toReimbursementLinePayload),
50
50
  };
51
51
  return zeniAPI
52
- .postAndGetJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/duplicates`, payload)
52
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/duplicates`, payload)
53
53
  .pipe((0, operators_1.mergeMap)((response) => {
54
54
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
55
55
  const updateActions = [];
@@ -44,7 +44,7 @@ const fetchRemiDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, ope
44
44
  is_include_deleted: isShowDeletedReimbursementEnabled,
45
45
  };
46
46
  const getTransactionDetail$ = zeniAPI
47
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
47
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions/${reimbursementId}?query=${encodeURIComponent(JSON.stringify(query))}`)
48
48
  .pipe((0, operators_1.mergeMap)((response) => {
49
49
  var _a, _b, _c, _d;
50
50
  if ((0, responsePayload_1.isSuccessResponse)(response) &&
@@ -28,7 +28,7 @@ const fetchRemiListPerTabEpic = (actions$, _state$, zeniAPI) => actions$.pipe((0
28
28
  is_include_line_items: isIncludeLineItems ? tab !== 'draft' : false,
29
29
  };
30
30
  return zeniAPI
31
- .getJSON(`${zeniAPI.apiEndPoints.accountMicroServiceBaseUrl}/1.0/reimbursements/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
31
+ .getJSON(`${zeniAPI.apiEndPoints.spendManagementMicroServiceBaseUrl}/1.0/reimbursements/transactions?query=${encodeURIComponent(JSON.stringify(queryParam))}`)
32
32
  .pipe((0, operators_1.mergeMap)((response) => {
33
33
  var _a;
34
34
  if ((0, responsePayload_1.isSuccessResponse)(response) && response.data != null) {
@@ -23,7 +23,7 @@ const checkDepositEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operat
23
23
  check_back_file_id: checkBack === null || checkBack === void 0 ? void 0 : checkBack.fileId,
24
24
  };
25
25
  return zeniAPI
26
- .postAndGetJSON(`${zeniAPI.apiEndPoints.payMicroServiceBaseUrl}/1.0/deposit-accounts/${(_a = localData.depositTo) === null || _a === void 0 ? void 0 : _a.id}/check-deposits`, payload)
26
+ .postAndGetJSON(`${zeniAPI.apiEndPoints.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${(_a = localData.depositTo) === null || _a === void 0 ? void 0 : _a.id}/check-deposits`, payload)
27
27
  .pipe((0, operators_1.mergeMap)((response) => {
28
28
  if ((0, responsePayload_1.isSuccessResponse)(response)) {
29
29
  return (0, rxjs_1.of)((0, snackbarReducer_1.openSnackbar)({