@zeniai/client-epic-state 4.20.2-betaJK4 → 4.20.2-betaNB1
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/viewAndReport/viewAndReport.d.ts +2 -2
- package/lib/commonStateTypes/viewAndReport/viewAndReport.js +0 -1
- package/lib/entity/account/accountPayload.d.ts +0 -2
- package/lib/entity/account/accountReducer.d.ts +2 -5
- package/lib/entity/account/accountReducer.js +2 -7
- package/lib/entity/account/accountState.d.ts +1 -1
- 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/sectionClassesViewReducer.d.ts +2 -2
- package/lib/entity/transaction/payloadTypes/transactionPayload.js +0 -1
- package/lib/epic.d.ts +1 -3
- package/lib/epic.js +1 -3
- package/lib/esm/commonStateTypes/viewAndReport/viewAndReport.js +0 -1
- package/lib/esm/entity/account/accountReducer.js +1 -6
- package/lib/esm/entity/transaction/payloadTypes/transactionPayload.js +0 -1
- package/lib/esm/epic.js +1 -3
- package/lib/esm/index.js +2 -2
- package/lib/esm/view/expenseAutomationView/epics/accountRecon/fetchReconciliationViewEpic.js +9 -4
- package/lib/esm/view/expenseAutomationView/reducers/reconciliationViewReducer.js +3 -151
- package/lib/esm/view/expenseAutomationView/selectors/reconciliationViewSelector.js +0 -69
- package/lib/esm/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +0 -3
- package/lib/esm/view/transactionDetail/transactionDetailSelector.js +2 -9
- package/lib/index.d.ts +4 -4
- package/lib/index.js +31 -33
- 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/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/accountRecon/fetchReconciliationViewEpic.js +9 -4
- package/lib/view/expenseAutomationView/payload/reconciliationPayload.d.ts +0 -33
- package/lib/view/expenseAutomationView/reducers/reconciliationViewReducer.d.ts +3 -14
- package/lib/view/expenseAutomationView/reducers/reconciliationViewReducer.js +4 -152
- package/lib/view/expenseAutomationView/selectorTypes/reconciliationViewSelectorTypes.d.ts +1 -11
- package/lib/view/expenseAutomationView/selectors/reconciliationViewSelector.js +0 -69
- package/lib/view/expenseAutomationView/types/reconciliationViewState.d.ts +0 -12
- package/lib/view/financeStatement/financeStatementReducer.d.ts +1 -1
- package/lib/view/globalMerchantView/globalMerchantViewReducer.d.ts +2 -2
- package/lib/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +0 -3
- 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/lib/view/transactionDetail/transactionDetailSelector.d.ts +0 -1
- package/lib/view/transactionDetail/transactionDetailSelector.js +2 -9
- package/package.json +1 -1
- package/lib/esm/view/expenseAutomationView/epics/accountRecon/excludeAccountFromReconciliationEpic.js +0 -44
- package/lib/esm/view/expenseAutomationView/epics/accountRecon/includeAccountInReconciliationEpic.js +0 -44
- package/lib/view/expenseAutomationView/epics/accountRecon/excludeAccountFromReconciliationEpic.d.ts +0 -8
- package/lib/view/expenseAutomationView/epics/accountRecon/excludeAccountFromReconciliationEpic.js +0 -48
- package/lib/view/expenseAutomationView/epics/accountRecon/includeAccountInReconciliationEpic.d.ts +0 -9
- package/lib/view/expenseAutomationView/epics/accountRecon/includeAccountInReconciliationEpic.js +0 -48
|
@@ -2,10 +2,9 @@ import { Amount } from '../../../commonStateTypes/amount';
|
|
|
2
2
|
import { FetchState, ID } from '../../../commonStateTypes/common';
|
|
3
3
|
import { SortOrder } from '../../../commonStateTypes/selectorTypes/sortOrderTypes';
|
|
4
4
|
import { MonthYearPeriod } from '../../../commonStateTypes/timePeriod';
|
|
5
|
-
import { ReconciliationDataPayload } from '../../../entity/accountRecon/accountReconPayload';
|
|
6
5
|
import { ZeniAPIStatus } from '../../../responsePayload';
|
|
7
|
-
import {
|
|
8
|
-
import { AccountReconciliationLocalData, ActionFetchStates,
|
|
6
|
+
import { ReconciliationPayload, UploadStatementDocumentAIPayload } from '../payload/reconciliationPayload';
|
|
7
|
+
import { AccountReconciliationLocalData, ActionFetchStates, ReconReconcileSortKey, ReconReviewSortKey, ReconciliationReviewTabLocalData, ReconciliationTabsState, ReconciliationViewState, ReconciliationViewTabType, SaveReconcileDetailActionPayload, SaveReconciliationDetailFailurePayload, TransactionSummary } from '../types/reconciliationViewState';
|
|
9
8
|
export declare const initialReconciliationTabsState: ReconciliationTabsState;
|
|
10
9
|
export declare const initialActionFetchState: ActionFetchStates;
|
|
11
10
|
export declare const initialState: ReconciliationViewState;
|
|
@@ -87,17 +86,7 @@ export declare const fetchReconciliation: import("@reduxjs/toolkit").ActionCreat
|
|
|
87
86
|
accountId: ID;
|
|
88
87
|
error: ZeniAPIStatus;
|
|
89
88
|
selectedPeriod: MonthYearPeriod;
|
|
90
|
-
}, "expenseAutomationReconciliationView/deleteAccountStatementFailure">,
|
|
91
|
-
selectedPeriod: MonthYearPeriod;
|
|
92
|
-
account?: ExcludedAccountFromReconciliationPayload;
|
|
93
|
-
}, "expenseAutomationReconciliationView/excludeAccountFromReconciliationSuccess">, excludeAccountFromReconciliationFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
94
|
-
error: ZeniAPIStatus;
|
|
95
|
-
}, "expenseAutomationReconciliationView/excludeAccountFromReconciliationFailure">, includeAccountInReconciliation: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[payload: ExcludeAccountFromReconciliationPayload], ExcludeAccountFromReconciliationPayload, "expenseAutomationReconciliationView/includeAccountInReconciliation", never, never>, includeAccountInReconciliationSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
96
|
-
selectedPeriod: MonthYearPeriod;
|
|
97
|
-
reconciliation?: ReconciliationDataPayload;
|
|
98
|
-
}, "expenseAutomationReconciliationView/includeAccountInReconciliationSuccess">, includeAccountInReconciliationFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
99
|
-
error: ZeniAPIStatus;
|
|
100
|
-
}, "expenseAutomationReconciliationView/includeAccountInReconciliationFailure">, uploadAccountStatement: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
89
|
+
}, "expenseAutomationReconciliationView/deleteAccountStatementFailure">, uploadAccountStatement: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
101
90
|
accountId: ID;
|
|
102
91
|
payload: UploadStatementDocumentAIPayload;
|
|
103
92
|
selectedPeriod: MonthYearPeriod;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var _a;
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.updateStatementUploadChosen = exports.uploadAccountStatementFailure = exports.uploadAccountStatementSuccess = exports.uploadAccountStatement = exports.
|
|
4
|
+
exports.updateStatementUploadChosen = exports.uploadAccountStatementFailure = exports.uploadAccountStatementSuccess = exports.uploadAccountStatement = exports.deleteAccountStatementFailure = exports.deleteAccountStatementSuccess = exports.deleteAccountStatement = exports.updateAccountReconciliationLocalData = exports.updateReconListScrollPosition = exports.updateSaveReconciliationReviewFetchStatus = exports.saveReconciliationReview = exports.updateReviewTabLocalData = exports.initializeReconciliationReviewTabLocalData = exports.updateReviewTabSortState = exports.updateSelectedDrawerAccountId = exports.clearExpenseAutomationReconciliationView = exports.initialiseLocalDataForSelectedAccountId = exports.updateBalancesLocalData = exports.updateSelectedTab = exports.saveReconciliationDetailSuccess = exports.updateReconcileTabListScrollState = exports.updateReconcileTabListSortState = exports.updateReconcileTabLocalData = exports.setStatementParseInProgress = exports.setConnectionInProgressForAccount = exports.updateSelectedAccountId = exports.saveReconciliationDetailFailure = exports.saveReconciliationDetail = exports.fetchReconciliationSuccess = exports.fetchReconciliationFailure = exports.fetchReconciliation = exports.initialState = exports.initialActionFetchState = exports.initialReconciliationTabsState = void 0;
|
|
5
5
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
6
6
|
const timePeriod_1 = require("../../../commonStateTypes/timePeriod");
|
|
7
7
|
const accountState_1 = require("../../../entity/account/accountState");
|
|
@@ -41,15 +41,7 @@ exports.initialReconciliationTabsState = {
|
|
|
41
41
|
},
|
|
42
42
|
};
|
|
43
43
|
exports.initialActionFetchState = {
|
|
44
|
-
excludeAccountFetch: {
|
|
45
|
-
fetchState: 'Not-Started',
|
|
46
|
-
error: undefined,
|
|
47
|
-
},
|
|
48
44
|
excludeFetchById: {},
|
|
49
|
-
includeAccountFetch: {
|
|
50
|
-
fetchState: 'Not-Started',
|
|
51
|
-
error: undefined,
|
|
52
|
-
},
|
|
53
45
|
reconcileFetch: {
|
|
54
46
|
fetchState: 'Not-Started',
|
|
55
47
|
error: undefined,
|
|
@@ -63,7 +55,6 @@ exports.initialActionFetchState = {
|
|
|
63
55
|
exports.initialState = {
|
|
64
56
|
accountReconciliationRecordsBySelectedPeriod: {},
|
|
65
57
|
accountConnectionStatusByAccountID: {},
|
|
66
|
-
excludedAccountExclusionInfo: {},
|
|
67
58
|
fetchState: 'Not-Started',
|
|
68
59
|
error: undefined,
|
|
69
60
|
selectedTab: 'review',
|
|
@@ -77,7 +68,6 @@ exports.initialState = {
|
|
|
77
68
|
scrollTop: 0,
|
|
78
69
|
},
|
|
79
70
|
},
|
|
80
|
-
excludedAccountIDs: [],
|
|
81
71
|
};
|
|
82
72
|
// Create slice with reducers
|
|
83
73
|
const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
@@ -146,7 +136,7 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
146
136
|
fetchReconciliationSuccess: {
|
|
147
137
|
reducer(draft, action) {
|
|
148
138
|
if (action.payload.accountId == null) {
|
|
149
|
-
updateAllReconciliation(draft, action.payload.reconciliation.accounts, action.payload.selectedPeriod, action.payload.reconciliation.reconciliation, action.payload.refreshViewInBackground
|
|
139
|
+
updateAllReconciliation(draft, action.payload.reconciliation.accounts, action.payload.selectedPeriod, action.payload.reconciliation.reconciliation, action.payload.refreshViewInBackground);
|
|
150
140
|
}
|
|
151
141
|
else if (action.payload.reconciliation.reconciliation.length > 0 &&
|
|
152
142
|
action.payload.reconciliation.accounts.length > 0) {
|
|
@@ -435,116 +425,6 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
435
425
|
...localData,
|
|
436
426
|
};
|
|
437
427
|
},
|
|
438
|
-
excludeAccountFromReconciliation: {
|
|
439
|
-
reducer(draft) {
|
|
440
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
441
|
-
fetchState: 'In-Progress',
|
|
442
|
-
error: undefined,
|
|
443
|
-
};
|
|
444
|
-
},
|
|
445
|
-
prepare(payload) {
|
|
446
|
-
return { payload };
|
|
447
|
-
},
|
|
448
|
-
},
|
|
449
|
-
excludeAccountFromReconciliationSuccess: (draft, action) => {
|
|
450
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
451
|
-
fetchState: 'Completed',
|
|
452
|
-
error: undefined,
|
|
453
|
-
};
|
|
454
|
-
const { account, selectedPeriod } = action.payload;
|
|
455
|
-
if (account != null) {
|
|
456
|
-
if (!draft.excludedAccountIDs.includes(account.account_id)) {
|
|
457
|
-
draft.excludedAccountIDs.push(account.account_id);
|
|
458
|
-
}
|
|
459
|
-
draft.excludedAccountExclusionInfo[account.account_id] = {
|
|
460
|
-
bankBalance: account.bank_balance != null
|
|
461
|
-
? {
|
|
462
|
-
amount: account.bank_balance,
|
|
463
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
464
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
465
|
-
}
|
|
466
|
-
: undefined,
|
|
467
|
-
clearedBalance: account.cleared_balance != null
|
|
468
|
-
? {
|
|
469
|
-
amount: account.cleared_balance,
|
|
470
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
471
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
472
|
-
}
|
|
473
|
-
: undefined,
|
|
474
|
-
variance: account.variance != null
|
|
475
|
-
? {
|
|
476
|
-
amount: account.variance,
|
|
477
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
478
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
479
|
-
}
|
|
480
|
-
: undefined,
|
|
481
|
-
};
|
|
482
|
-
const monthYearPeriodId = (0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod);
|
|
483
|
-
if (draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId]
|
|
484
|
-
?.accountIDs != null) {
|
|
485
|
-
draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId].accountIDs = draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId].accountIDs.filter((id) => id !== account.account_id);
|
|
486
|
-
}
|
|
487
|
-
}
|
|
488
|
-
},
|
|
489
|
-
excludeAccountFromReconciliationFailure: (draft, action) => {
|
|
490
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
491
|
-
fetchState: 'Error',
|
|
492
|
-
error: action.payload.error,
|
|
493
|
-
};
|
|
494
|
-
},
|
|
495
|
-
includeAccountInReconciliation: {
|
|
496
|
-
reducer(draft) {
|
|
497
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
498
|
-
fetchState: 'In-Progress',
|
|
499
|
-
error: undefined,
|
|
500
|
-
};
|
|
501
|
-
},
|
|
502
|
-
prepare(payload) {
|
|
503
|
-
return { payload };
|
|
504
|
-
},
|
|
505
|
-
},
|
|
506
|
-
includeAccountInReconciliationSuccess: (draft, action) => {
|
|
507
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
508
|
-
fetchState: 'Completed',
|
|
509
|
-
error: undefined,
|
|
510
|
-
};
|
|
511
|
-
const { reconciliation, selectedPeriod } = action.payload;
|
|
512
|
-
if (reconciliation == null) {
|
|
513
|
-
return;
|
|
514
|
-
}
|
|
515
|
-
const accountId = reconciliation.account_id;
|
|
516
|
-
draft.excludedAccountIDs = draft.excludedAccountIDs.filter((id) => id !== accountId);
|
|
517
|
-
delete draft.excludedAccountExclusionInfo[accountId];
|
|
518
|
-
const monthYearPeriodId = (0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod);
|
|
519
|
-
const accountReconciliationRecords = draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId];
|
|
520
|
-
if (accountReconciliationRecords != null) {
|
|
521
|
-
if (!accountReconciliationRecords.accountIDs.includes(accountId)) {
|
|
522
|
-
accountReconciliationRecords.accountIDs.push(accountId);
|
|
523
|
-
}
|
|
524
|
-
accountReconciliationRecords.reconciliationByAccountID[accountId] = {
|
|
525
|
-
accountId,
|
|
526
|
-
reconciliationId: reconciliation.reconciliation_id ?? undefined,
|
|
527
|
-
transactionFetchState: { fetchState: 'Not-Started', error: undefined },
|
|
528
|
-
refreshStatus: { fetchState: 'Not-Started', error: undefined },
|
|
529
|
-
statementDeleteStatus: { fetchState: 'Not-Started', error: undefined },
|
|
530
|
-
statementUploadStatus: { fetchState: 'Not-Started', error: undefined },
|
|
531
|
-
statementUpdateStatus: { fetchState: 'Not-Started', error: undefined },
|
|
532
|
-
statementParseInProgress: reconciliation.bank_status.code === 'parsing',
|
|
533
|
-
localData: {},
|
|
534
|
-
};
|
|
535
|
-
}
|
|
536
|
-
draft.accountConnectionStatusByAccountID[accountId] = {
|
|
537
|
-
status: (0, accountReconState_1.toBankStatusCodeType)(reconciliation.bank_status.code),
|
|
538
|
-
connectionInProgress: false,
|
|
539
|
-
paymentAccountId: undefined,
|
|
540
|
-
};
|
|
541
|
-
},
|
|
542
|
-
includeAccountInReconciliationFailure: (draft, action) => {
|
|
543
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
544
|
-
fetchState: 'Error',
|
|
545
|
-
error: action.payload.error,
|
|
546
|
-
};
|
|
547
|
-
},
|
|
548
428
|
updateStatementUploadChosen: (draft, action) => {
|
|
549
429
|
draft.statementUploadChosen = action.payload.statementUploadChosen;
|
|
550
430
|
},
|
|
@@ -554,38 +434,10 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
554
434
|
},
|
|
555
435
|
});
|
|
556
436
|
// Export actions
|
|
557
|
-
_a = expenseAutomationReconciliationView.actions, exports.fetchReconciliation = _a.fetchReconciliation, exports.fetchReconciliationFailure = _a.fetchReconciliationFailure, exports.fetchReconciliationSuccess = _a.fetchReconciliationSuccess, exports.saveReconciliationDetail = _a.saveReconciliationDetail, exports.saveReconciliationDetailFailure = _a.saveReconciliationDetailFailure, exports.updateSelectedAccountId = _a.updateSelectedAccountId, exports.setConnectionInProgressForAccount = _a.setConnectionInProgressForAccount, exports.setStatementParseInProgress = _a.setStatementParseInProgress, exports.updateReconcileTabLocalData = _a.updateReconcileTabLocalData, exports.updateReconcileTabListSortState = _a.updateReconcileTabListSortState, exports.updateReconcileTabListScrollState = _a.updateReconcileTabListScrollState, exports.saveReconciliationDetailSuccess = _a.saveReconciliationDetailSuccess, exports.updateSelectedTab = _a.updateSelectedTab, exports.updateBalancesLocalData = _a.updateBalancesLocalData, exports.initialiseLocalDataForSelectedAccountId = _a.initialiseLocalDataForSelectedAccountId, exports.clearExpenseAutomationReconciliationView = _a.clearExpenseAutomationReconciliationView, exports.updateSelectedDrawerAccountId = _a.updateSelectedDrawerAccountId, exports.updateReviewTabSortState = _a.updateReviewTabSortState, exports.initializeReconciliationReviewTabLocalData = _a.initializeReconciliationReviewTabLocalData, exports.updateReviewTabLocalData = _a.updateReviewTabLocalData, exports.saveReconciliationReview = _a.saveReconciliationReview, exports.updateSaveReconciliationReviewFetchStatus = _a.updateSaveReconciliationReviewFetchStatus, exports.updateReconListScrollPosition = _a.updateReconListScrollPosition, exports.updateAccountReconciliationLocalData = _a.updateAccountReconciliationLocalData, exports.deleteAccountStatement = _a.deleteAccountStatement, exports.deleteAccountStatementSuccess = _a.deleteAccountStatementSuccess, exports.deleteAccountStatementFailure = _a.deleteAccountStatementFailure, exports.
|
|
437
|
+
_a = expenseAutomationReconciliationView.actions, exports.fetchReconciliation = _a.fetchReconciliation, exports.fetchReconciliationFailure = _a.fetchReconciliationFailure, exports.fetchReconciliationSuccess = _a.fetchReconciliationSuccess, exports.saveReconciliationDetail = _a.saveReconciliationDetail, exports.saveReconciliationDetailFailure = _a.saveReconciliationDetailFailure, exports.updateSelectedAccountId = _a.updateSelectedAccountId, exports.setConnectionInProgressForAccount = _a.setConnectionInProgressForAccount, exports.setStatementParseInProgress = _a.setStatementParseInProgress, exports.updateReconcileTabLocalData = _a.updateReconcileTabLocalData, exports.updateReconcileTabListSortState = _a.updateReconcileTabListSortState, exports.updateReconcileTabListScrollState = _a.updateReconcileTabListScrollState, exports.saveReconciliationDetailSuccess = _a.saveReconciliationDetailSuccess, exports.updateSelectedTab = _a.updateSelectedTab, exports.updateBalancesLocalData = _a.updateBalancesLocalData, exports.initialiseLocalDataForSelectedAccountId = _a.initialiseLocalDataForSelectedAccountId, exports.clearExpenseAutomationReconciliationView = _a.clearExpenseAutomationReconciliationView, exports.updateSelectedDrawerAccountId = _a.updateSelectedDrawerAccountId, exports.updateReviewTabSortState = _a.updateReviewTabSortState, exports.initializeReconciliationReviewTabLocalData = _a.initializeReconciliationReviewTabLocalData, exports.updateReviewTabLocalData = _a.updateReviewTabLocalData, exports.saveReconciliationReview = _a.saveReconciliationReview, exports.updateSaveReconciliationReviewFetchStatus = _a.updateSaveReconciliationReviewFetchStatus, exports.updateReconListScrollPosition = _a.updateReconListScrollPosition, exports.updateAccountReconciliationLocalData = _a.updateAccountReconciliationLocalData, exports.deleteAccountStatement = _a.deleteAccountStatement, exports.deleteAccountStatementSuccess = _a.deleteAccountStatementSuccess, exports.deleteAccountStatementFailure = _a.deleteAccountStatementFailure, exports.uploadAccountStatement = _a.uploadAccountStatement, exports.uploadAccountStatementSuccess = _a.uploadAccountStatementSuccess, exports.uploadAccountStatementFailure = _a.uploadAccountStatementFailure, exports.updateStatementUploadChosen = _a.updateStatementUploadChosen;
|
|
558
438
|
// Export reducer
|
|
559
439
|
exports.default = expenseAutomationReconciliationView.reducer;
|
|
560
|
-
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground
|
|
561
|
-
draft.excludedAccountIDs = excludedAccounts.map((ea) => ea.account_id);
|
|
562
|
-
draft.excludedAccountExclusionInfo = {};
|
|
563
|
-
excludedAccounts.forEach((ea) => {
|
|
564
|
-
const { exclusion_info } = ea;
|
|
565
|
-
draft.excludedAccountExclusionInfo[ea.account_id] = {
|
|
566
|
-
bankBalance: exclusion_info.bank_balance != null
|
|
567
|
-
? {
|
|
568
|
-
amount: exclusion_info.bank_balance,
|
|
569
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
570
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
571
|
-
}
|
|
572
|
-
: undefined,
|
|
573
|
-
clearedBalance: exclusion_info.cleared_balance != null
|
|
574
|
-
? {
|
|
575
|
-
amount: exclusion_info.cleared_balance,
|
|
576
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
577
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
578
|
-
}
|
|
579
|
-
: undefined,
|
|
580
|
-
variance: exclusion_info.variance != null
|
|
581
|
-
? {
|
|
582
|
-
amount: exclusion_info.variance,
|
|
583
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
584
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
585
|
-
}
|
|
586
|
-
: undefined,
|
|
587
|
-
};
|
|
588
|
-
});
|
|
440
|
+
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground) {
|
|
589
441
|
draft.accountReconciliationRecordsBySelectedPeriod[(0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod)] = {
|
|
590
442
|
accountIDs: [],
|
|
591
443
|
reconciliationByAccountID: {},
|
|
@@ -3,7 +3,7 @@ import { Amount } from '../../../commonStateTypes/amount';
|
|
|
3
3
|
import { NestedClassHierarchyForReport } from '../../../commonStateTypes/classesView/nestedClassID';
|
|
4
4
|
import { CompletionStatusType, FetchStateAndError, ID } from '../../../commonStateTypes/common';
|
|
5
5
|
import { MonthYearPeriod } from '../../../commonStateTypes/timePeriod';
|
|
6
|
-
import {
|
|
6
|
+
import { AccountBase } from '../../../entity/account/accountState';
|
|
7
7
|
import { AccountReconciliationEntity } from '../../../entity/accountRecon/accountReconSelector';
|
|
8
8
|
import { BankStatusCodeType } from '../../../entity/accountRecon/accountReconState';
|
|
9
9
|
import { ClassBase } from '../../../entity/class/classState';
|
|
@@ -13,11 +13,6 @@ import { AccountReconciliationLocalData, ActionFetchStates, ReconListUIState, Re
|
|
|
13
13
|
export declare const ALL_ACCOUNT_RECON_SECTION_IDS: readonly ["assets", "liabilities"];
|
|
14
14
|
declare const toAccountReconSectionID: (v: string) => "assets" | "liabilities";
|
|
15
15
|
export type AccountReconSectionID = ReturnType<typeof toAccountReconSectionID>;
|
|
16
|
-
export interface ExcludedAccountReconciliation extends Account {
|
|
17
|
-
bankBalance?: Amount;
|
|
18
|
-
clearedBalance?: Amount;
|
|
19
|
-
variance?: Amount;
|
|
20
|
-
}
|
|
21
16
|
export interface ExpenseAutomationReconciliationViewSelector {
|
|
22
17
|
accountListNestedAccountHierarchy: NestedAccountHierarchyForReport[];
|
|
23
18
|
accountReconciliationBySectionID: Record<AccountReconSectionID, AccountReconciliationBySection>;
|
|
@@ -29,12 +24,7 @@ export interface ExpenseAutomationReconciliationViewSelector {
|
|
|
29
24
|
classListNestedAccountHierarchy: NestedClassHierarchyForReport[];
|
|
30
25
|
completionStatus: CompletionStatusType;
|
|
31
26
|
creditCards: AccountBase[];
|
|
32
|
-
excludeAccountFetchState: FetchStateAndError;
|
|
33
|
-
excludedAccountIDs: ID[];
|
|
34
|
-
excludedAccountReconciliationByAccountID: Record<ID, ExcludedAccountReconciliation>;
|
|
35
|
-
excludedAccountReconciliationBySectionID: Record<AccountReconSectionID, AccountReconciliationBySection>;
|
|
36
27
|
fetchStatus: FetchStateAndError;
|
|
37
|
-
includeAccountFetchState: FetchStateAndError;
|
|
38
28
|
monthYearPeriod: MonthYearPeriod;
|
|
39
29
|
plaidConnectionDetails: PlaidConnectionDetails;
|
|
40
30
|
reconciliationTabsState: ReconciliationTabsState;
|
|
@@ -96,30 +96,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
96
96
|
totalVariancePercentage: undefined,
|
|
97
97
|
},
|
|
98
98
|
},
|
|
99
|
-
excludedAccountReconciliationByAccountID: {},
|
|
100
|
-
excludedAccountReconciliationBySectionID: {
|
|
101
|
-
assets: {
|
|
102
|
-
sectionId: 'assets',
|
|
103
|
-
accountIDs: [],
|
|
104
|
-
totalBankBalance: undefined,
|
|
105
|
-
totalClearedBalance: undefined,
|
|
106
|
-
totalReconciledBalance: undefined,
|
|
107
|
-
totalVariance: undefined,
|
|
108
|
-
totalVariancePercentage: undefined,
|
|
109
|
-
},
|
|
110
|
-
liabilities: {
|
|
111
|
-
sectionId: 'liabilities',
|
|
112
|
-
accountIDs: [],
|
|
113
|
-
totalBankBalance: undefined,
|
|
114
|
-
totalClearedBalance: undefined,
|
|
115
|
-
totalReconciledBalance: undefined,
|
|
116
|
-
totalVariance: undefined,
|
|
117
|
-
totalVariancePercentage: undefined,
|
|
118
|
-
},
|
|
119
|
-
},
|
|
120
|
-
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
121
|
-
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
122
|
-
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
123
99
|
};
|
|
124
100
|
}
|
|
125
101
|
const allAccountIDs = accountReconForMonthYearPeriod.accountIDs;
|
|
@@ -279,46 +255,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
279
255
|
totalVariancePercentage: liabilityTotals.variancePercentage,
|
|
280
256
|
},
|
|
281
257
|
};
|
|
282
|
-
const bankAccountIdSet = new Set(uniqueBankAccounts.map((a) => a.accountId));
|
|
283
|
-
const creditCardIdSet = new Set(uniqueCreditCards.map((a) => a.accountId));
|
|
284
|
-
const excludedAssetAccountIDs = [];
|
|
285
|
-
const excludedLiabilityAccountIDs = [];
|
|
286
|
-
reconciliationViewState.excludedAccountIDs.forEach((accountID) => {
|
|
287
|
-
const isAsset = bankAccountIdSet.has(accountID);
|
|
288
|
-
const isLiability = creditCardIdSet.has(accountID);
|
|
289
|
-
if (!isAsset && !isLiability) {
|
|
290
|
-
return;
|
|
291
|
-
}
|
|
292
|
-
if (isAsset) {
|
|
293
|
-
excludedAssetAccountIDs.push(accountID);
|
|
294
|
-
}
|
|
295
|
-
else {
|
|
296
|
-
excludedLiabilityAccountIDs.push(accountID);
|
|
297
|
-
}
|
|
298
|
-
});
|
|
299
|
-
const excludedAccountReconciliationBySectionID = {
|
|
300
|
-
assets: {
|
|
301
|
-
sectionId: 'assets',
|
|
302
|
-
accountIDs: excludedAssetAccountIDs,
|
|
303
|
-
},
|
|
304
|
-
liabilities: {
|
|
305
|
-
sectionId: 'liabilities',
|
|
306
|
-
accountIDs: excludedLiabilityAccountIDs,
|
|
307
|
-
},
|
|
308
|
-
};
|
|
309
|
-
const excludedAccountReconciliationByAccountID = {};
|
|
310
|
-
const accountsInState = Object.values(accountState.accountsByKey);
|
|
311
|
-
const accountsInStateMap = new Map(accountsInState.map((a) => [a.accountId, a]));
|
|
312
|
-
reconciliationViewState.excludedAccountIDs.forEach((excludedAccountID) => {
|
|
313
|
-
const account = accountsInStateMap.get(excludedAccountID);
|
|
314
|
-
const exclusionInfo = reconciliationViewState.excludedAccountExclusionInfo[excludedAccountID];
|
|
315
|
-
if (account != null) {
|
|
316
|
-
excludedAccountReconciliationByAccountID[excludedAccountID] = {
|
|
317
|
-
...account,
|
|
318
|
-
...exclusionInfo,
|
|
319
|
-
};
|
|
320
|
-
}
|
|
321
|
-
});
|
|
322
258
|
const accountListNestedAccountHierarchy = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'accountList');
|
|
323
259
|
const classListNestedAccountHierarchy = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
|
|
324
260
|
const accountsList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'accountList');
|
|
@@ -379,11 +315,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
379
315
|
allClassList: allClasses,
|
|
380
316
|
reviewTabSelectedVendorByTransactionId,
|
|
381
317
|
reconListUIState: reconciliationViewState.reconListUIState,
|
|
382
|
-
excludedAccountReconciliationBySectionID,
|
|
383
|
-
excludedAccountReconciliationByAccountID,
|
|
384
|
-
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
385
|
-
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
386
|
-
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
387
318
|
};
|
|
388
319
|
});
|
|
389
320
|
const isAccountReconReport = (reportId) => {
|
|
@@ -74,18 +74,8 @@ export interface ReconciliationReviewTabLocalData {
|
|
|
74
74
|
matchedTransactionId?: ID;
|
|
75
75
|
vendor?: VendorBase;
|
|
76
76
|
}
|
|
77
|
-
export interface ExcludeAccountFromReconciliationPayload {
|
|
78
|
-
accountId: ID;
|
|
79
|
-
}
|
|
80
|
-
export interface ExclusionInfo {
|
|
81
|
-
bankBalance: Amount | undefined;
|
|
82
|
-
clearedBalance: Amount | undefined;
|
|
83
|
-
variance: Amount | undefined;
|
|
84
|
-
}
|
|
85
77
|
export interface ActionFetchStates {
|
|
86
|
-
excludeAccountFetch: FetchStateAndError;
|
|
87
78
|
excludeFetchById: Record<ID, FetchStateAndError>;
|
|
88
|
-
includeAccountFetch: FetchStateAndError;
|
|
89
79
|
reconcileFetch: FetchStateAndError;
|
|
90
80
|
saveForLaterFetch: FetchStateAndError;
|
|
91
81
|
saveReconciliationReviewFetch: Record<ID, FetchStateAndError>;
|
|
@@ -100,8 +90,6 @@ export interface ReconciliationViewState extends FetchStateAndError {
|
|
|
100
90
|
accountConnectionStatusByAccountID: Record<ID, BankConnectionStatus>;
|
|
101
91
|
accountReconciliationRecordsBySelectedPeriod: Record<MonthYearPeriodId, AccountReconciliationRecords>;
|
|
102
92
|
actionFetchState: ActionFetchStates;
|
|
103
|
-
excludedAccountExclusionInfo: Record<ID, ExclusionInfo>;
|
|
104
|
-
excludedAccountIDs: ID[];
|
|
105
93
|
reconListUIState: ReconListUIState;
|
|
106
94
|
reconTabsState: ReconciliationTabsState;
|
|
107
95
|
refreshStatus: FetchStateAndError;
|
|
@@ -17,7 +17,7 @@ export declare const fetchFinanceStatement: import("@reduxjs/toolkit").ActionCre
|
|
|
17
17
|
firstMonthOfFY: Month;
|
|
18
18
|
maxNumOfPeriodsToHighlight: number;
|
|
19
19
|
thisPeriod: TimeframeTick;
|
|
20
|
-
}, "financeStatement/updateFinanceStatementThisPeriod">, updateCOABalancesRange: import("@reduxjs/toolkit").ActionCreatorWithPayload<COABalancesRange, "financeStatement/updateCOABalancesRange">, updateSelectedReportId: import("@reduxjs/toolkit").ActionCreatorWithPayload<"cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
20
|
+
}, "financeStatement/updateFinanceStatementThisPeriod">, updateCOABalancesRange: import("@reduxjs/toolkit").ActionCreatorWithPayload<COABalancesRange, "financeStatement/updateCOABalancesRange">, updateSelectedReportId: import("@reduxjs/toolkit").ActionCreatorWithPayload<"cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card", "financeStatement/updateSelectedReportId">, updateFinanceStatementAdditionalBalancesSelection: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
21
21
|
additionalBalances: COABalanceType[];
|
|
22
22
|
coaBalances: COABalance[];
|
|
23
23
|
firstMonthOfFY: Month;
|
|
@@ -3,9 +3,9 @@ import { ZeniAPIStatus } from '../../responsePayload';
|
|
|
3
3
|
import { VendorReviewViewAllRecommendationsPayload } from '../vendorReviewView/common/payload/commonTypes';
|
|
4
4
|
import { GlobalMerchantViewState, GlobalRecommendationFetchSource, NewGlobalMerchantCurrentSelection } from './globalMerchantViewState';
|
|
5
5
|
export declare const initialState: GlobalMerchantViewState;
|
|
6
|
-
export declare const createGlobalMerchant: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[merchantId?: string | undefined, context?: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" |
|
|
6
|
+
export declare const createGlobalMerchant: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[merchantId?: string | undefined, context?: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | undefined], {
|
|
7
7
|
merchantId: string | undefined;
|
|
8
|
-
context: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" |
|
|
8
|
+
context: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card" | undefined;
|
|
9
9
|
}, "globalMerchantView/createGlobalMerchant", never, never>, createGlobalMerchantSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
10
10
|
merchantId: ID;
|
|
11
11
|
}, "globalMerchantView/createGlobalMerchantSuccess">, createGlobalMerchantFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
@@ -6,7 +6,6 @@ const getSummationBalance_1 = require("../../commonStateTypes/coaBalance/additio
|
|
|
6
6
|
const currencyHelper_1 = require("../../commonStateTypes/currencyHelper");
|
|
7
7
|
const reduceFetchState_1 = require("../../commonStateTypes/reduceFetchState");
|
|
8
8
|
const sectionClassesViewSelector_1 = require("../../entity/sectionClassesViewV2/sectionClassesViewSelector");
|
|
9
|
-
const profitAndLossClassesByClassHorizontalSelectorTypes_1 = require("./profitAndLossClassesByClassHorizontalSelectorTypes");
|
|
10
9
|
const profitAndLossHorizontalEnrichment_1 = require("./profitAndLossHorizontalEnrichment");
|
|
11
10
|
exports.profitAndLossHorizontalIdsInOrder = [
|
|
12
11
|
'income',
|
|
@@ -308,7 +307,6 @@ function buildHeaderBalances(classColumns, timeframe, selectedPeriod, currency)
|
|
|
308
307
|
startDate,
|
|
309
308
|
type: 'default',
|
|
310
309
|
label: col.className,
|
|
311
|
-
id: col.classId,
|
|
312
310
|
}));
|
|
313
311
|
// Add a "Total" column
|
|
314
312
|
balances.push({
|
|
@@ -318,7 +316,6 @@ function buildHeaderBalances(classColumns, timeframe, selectedPeriod, currency)
|
|
|
318
316
|
startDate,
|
|
319
317
|
type: 'default',
|
|
320
318
|
label: 'Total',
|
|
321
|
-
id: profitAndLossClassesByClassHorizontalSelectorTypes_1.HORIZONTAL_CLASS_TOTAL_BALANCE_ID,
|
|
322
319
|
});
|
|
323
320
|
return balances;
|
|
324
321
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RootState } from '../../reducer';
|
|
2
2
|
export declare const getReimbursementCardReport: (state: RootState) => {
|
|
3
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
3
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
6
|
fetchState: import("../..").FetchState;
|
|
@@ -2,8 +2,8 @@ import { ReportID } from '../../commonStateTypes/viewAndReport/viewAndReport';
|
|
|
2
2
|
import { ZeniAPIStatus } from '../../responsePayload';
|
|
3
3
|
import { ReportsResyncState } from './reportsResyncState';
|
|
4
4
|
export declare const initialReportsResyncState: ReportsResyncState;
|
|
5
|
-
export declare const initiateReportsResync: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[reportIdToResync: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
6
|
-
reportIdToResync: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
5
|
+
export declare const initiateReportsResync: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[reportIdToResync: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"], {
|
|
6
|
+
reportIdToResync: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card";
|
|
7
7
|
}, "initiateReportsResync/initiateReportsResync", never, never>, initiateReportsClassViewRefetching: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
8
8
|
reportIdToResync: ReportID;
|
|
9
9
|
}, "initiateReportsResync/initiateReportsClassViewRefetching">, reportsResyncSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { RootState } from '../../reducer';
|
|
2
2
|
export declare const getTasksCardReport: (state: RootState) => {
|
|
3
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
3
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card";
|
|
4
4
|
reportTitle: string;
|
|
5
5
|
version: string | number | undefined;
|
|
6
6
|
status: import("../..").Status | undefined;
|
|
@@ -4,7 +4,7 @@ import { RootState } from '../../reducer';
|
|
|
4
4
|
import { TopExReport, TopExTimePeriodWithMetaData } from './topExSelectorTypes';
|
|
5
5
|
import { TopExState } from './topExState';
|
|
6
6
|
export declare const getTopExpenses: (accountState: AccountState, topExState: TopExState, numberOfExpenses?: number) => {
|
|
7
|
-
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card"
|
|
7
|
+
reportId: "cash_balance" | "card_balance" | "expense_automation_card" | "operating_expenses" | "operating_expenses_by_classes" | "revenue" | "revenue_by_classes" | "net_burn_or_income" | "net_burn_or_income_story_card" | "net_burn_or_income_by_classes" | "cash_position" | "top_expenses" | "profit_and_loss" | "profit_and_loss_by_classes" | "balance_sheet" | "cash_flow" | "dashboard" | "finance_statement" | "transaction_list_of_account" | "transaction_list_missing_receipt" | "transaction_list_of_account_by_class" | "transaction_detail" | "cash_in_cash_out" | "insights_dashboard" | "company_details" | "class_list" | "account_list" | "account_list_by_type" | "vendor" | "task_card" | "bill_pay" | "reimbursement" | "bill_pay_card" | "reimbursement_card" | "bill_pay_promo_card" | "zeni_accounts" | "zeni_accounts_promo_card" | "zeni_treasury" | "charge_cards" | "other_connection" | "reimbursement_promo_card" | "onboarding" | "operating_expenses_by_vendor" | "operating_expenses_by_vendor_summary" | "vendors_tab" | "accounts_payable_aging" | "accounts_receivable_aging" | "vendor_global_review" | "prepaid_expenses" | "fixed_assets" | "notification" | "rewards_card" | "billing" | "flux_analysis_operating_expense" | "account_reconciliation" | "zeni_credit_promo_card" | "treasury_promo_card";
|
|
8
8
|
reportTitle: string;
|
|
9
9
|
version: string | number | undefined;
|
|
10
10
|
status: import("../..").Status | undefined;
|
|
@@ -17,7 +17,6 @@ export interface TransactionDetailReport extends SelectorView {
|
|
|
17
17
|
classHierarchyList: NestedClassHierarchyForReport[];
|
|
18
18
|
classList: ClassListSelectorView;
|
|
19
19
|
deleteStatusByAttachmentName: Record<string, FetchStateAndError>;
|
|
20
|
-
isAccountingClassesEnabled: boolean;
|
|
21
20
|
linkedTransactions: SupportedTransactionWithCOT[];
|
|
22
21
|
transactionDetailLocalData: TransactionDetailLocalData;
|
|
23
22
|
transactionDetailUpdateStatus: FetchStateAndError;
|
|
@@ -7,7 +7,6 @@ exports.getInitialUpdatablePeriodsForTransactionRecommendations = exports.getTra
|
|
|
7
7
|
exports.getTransactionDetailForTransaction = getTransactionDetailForTransaction;
|
|
8
8
|
const get_1 = __importDefault(require("lodash/get"));
|
|
9
9
|
const reduceFetchState_1 = require("../../commonStateTypes/reduceFetchState");
|
|
10
|
-
const tenantSelector_1 = require("../../entity/tenant/tenantSelector");
|
|
11
10
|
const transactionType_1 = require("../../entity/transaction/stateTypes/transactionType");
|
|
12
11
|
const transactionHelper_1 = require("../../entity/transaction/transactionHelper");
|
|
13
12
|
const transactionSelector_1 = require("../../entity/transaction/transactionSelector");
|
|
@@ -59,14 +58,9 @@ const getTransactionDetail = (state, transactionId, fetchLinkedTransactions = tr
|
|
|
59
58
|
}
|
|
60
59
|
}
|
|
61
60
|
const accountsList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'accountList');
|
|
62
|
-
const
|
|
63
|
-
const classList = isAccountingClassesEnabled
|
|
64
|
-
? (0, classListSelector_1.getClassList)(classState, classListState)
|
|
65
|
-
: { classes: [], nestedClassHierarchy: [], fetchState: 'Completed', error: undefined, version: 0 };
|
|
61
|
+
const classList = (0, classListSelector_1.getClassList)(classState, classListState);
|
|
66
62
|
const accountsHierarchyList = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'accountList');
|
|
67
|
-
const classHierarchyList =
|
|
68
|
-
? (0, classListSelector_1.getNestedClassListHierarchy)(classListState)
|
|
69
|
-
: [];
|
|
63
|
+
const classHierarchyList = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
|
|
70
64
|
const transactionDetailAnyUpdateStatus = reduceUpdateFetchStates(transactionDetail);
|
|
71
65
|
const vendors = (0, vendorSelector_1.getVendorsByVendorIds)(vendorState, vendorListState.vendorIds);
|
|
72
66
|
return {
|
|
@@ -84,7 +78,6 @@ const getTransactionDetail = (state, transactionId, fetchLinkedTransactions = tr
|
|
|
84
78
|
classHierarchyList,
|
|
85
79
|
accountsHierarchyList,
|
|
86
80
|
classList: classList,
|
|
87
|
-
isAccountingClassesEnabled,
|
|
88
81
|
isUpdateNotAllowed: transactionDetail?.isUpdateNotAllowed,
|
|
89
82
|
transactionDetailLocalData: transactionDetail?.transactionDetailLocalData ??
|
|
90
83
|
transactionDetailState_1.initialSupportedTransactionDetail.transactionDetailLocalData,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeniai/client-epic-state",
|
|
3
|
-
"version": "4.20.2-
|
|
3
|
+
"version": "4.20.2-betaNB1",
|
|
4
4
|
"description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/esm/index.js",
|