@zeniai/client-epic-state 4.20.3-betaML22 → 4.20.3-betaML4
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/snackbar/snackbarTypes.d.ts +1 -1
- package/lib/entity/snackbar/snackbarTypes.js +0 -1
- package/lib/entity/tenant/tenantReducer.d.ts +2 -5
- package/lib/entity/tenant/tenantReducer.js +2 -8
- package/lib/entity/transaction/payloadTypes/transactionPayload.d.ts +0 -6
- package/lib/entity/transaction/payloadTypes/transactionPayload.js +0 -62
- package/lib/entity/transaction/stateTypes/transaction.d.ts +0 -6
- package/lib/epic.d.ts +7 -10
- package/lib/epic.js +7 -10
- package/lib/esm/commonStateTypes/viewAndReport/viewAndReport.js +0 -1
- package/lib/esm/entity/account/accountReducer.js +1 -6
- package/lib/esm/entity/snackbar/snackbarTypes.js +0 -1
- package/lib/esm/entity/tenant/tenantReducer.js +1 -7
- package/lib/esm/entity/transaction/payloadTypes/transactionPayload.js +0 -62
- package/lib/esm/epic.js +7 -10
- package/lib/esm/index.js +6 -6
- package/lib/esm/view/companyView/companyViewReducer.js +1 -26
- package/lib/esm/view/companyView/types/companyPassport/companyPassportViewState.js +0 -4
- package/lib/esm/view/expenseAutomationView/epics/accountRecon/fetchReconciliationViewEpic.js +9 -4
- package/lib/esm/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +1 -5
- package/lib/esm/view/expenseAutomationView/reducers/reconciliationViewReducer.js +3 -167
- package/lib/esm/view/expenseAutomationView/selectorTypes/reconciliationViewSelectorTypes.js +2 -1
- package/lib/esm/view/expenseAutomationView/selectors/reconciliationViewSelector.js +0 -114
- package/lib/esm/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +6 -10
- package/lib/esm/view/expenseAutomationView/types/jeSchedulesViewState.js +0 -6
- package/lib/esm/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +2 -4
- package/lib/index.d.ts +6 -6
- package/lib/index.js +32 -38
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -1
- 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/companyView/companyViewReducer.d.ts +1 -6
- package/lib/view/companyView/companyViewReducer.js +2 -28
- package/lib/view/companyView/types/companyPassport/companyPassportViewState.d.ts +0 -1
- package/lib/view/companyView/types/companyPassport/companyPassportViewState.js +0 -4
- package/lib/view/dashboard/dashboardReducer.d.ts +2 -2
- package/lib/view/expenseAutomationView/epics/accountRecon/fetchReconciliationViewEpic.js +9 -4
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +1 -1
- package/lib/view/expenseAutomationView/payload/reconciliationPayload.d.ts +0 -45
- package/lib/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +1 -5
- package/lib/view/expenseAutomationView/reducers/reconciliationViewReducer.d.ts +4 -18
- package/lib/view/expenseAutomationView/reducers/reconciliationViewReducer.js +4 -168
- package/lib/view/expenseAutomationView/selectorTypes/reconciliationViewSelectorTypes.d.ts +2 -7
- package/lib/view/expenseAutomationView/selectorTypes/reconciliationViewSelectorTypes.js +2 -2
- package/lib/view/expenseAutomationView/selectors/reconciliationViewSelector.js +0 -114
- package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +5 -9
- package/lib/view/expenseAutomationView/types/jeSchedulesViewState.d.ts +0 -3
- package/lib/view/expenseAutomationView/types/jeSchedulesViewState.js +1 -8
- package/lib/view/expenseAutomationView/types/reconciliationViewState.d.ts +0 -14
- package/lib/view/financeStatement/financeStatementReducer.d.ts +1 -1
- package/lib/view/globalMerchantView/globalMerchantViewReducer.d.ts +2 -2
- package/lib/view/profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector.js +2 -4
- package/lib/view/reimbursementCard/reimbursementCardSelector.d.ts +1 -1
- package/lib/view/reportsResync/reportsResyncReducer.d.ts +2 -2
- package/lib/view/tasksCard/tasksCardSelector.d.ts +1 -1
- package/lib/view/topEx/topExSelector.d.ts +1 -1
- package/package.json +1 -1
- package/lib/esm/view/companyView/epic/companyPassport/updateAccountingClassesEnabledEpic.js +0 -61
- 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/companyView/epic/companyPassport/updateAccountingClassesEnabledEpic.d.ts +0 -10
- package/lib/view/companyView/epic/companyPassport/updateAccountingClassesEnabledEpic.js +0 -65
- 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
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var _a;
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
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',
|
|
@@ -73,12 +64,10 @@ exports.initialState = {
|
|
|
73
64
|
selectedAccountId: undefined,
|
|
74
65
|
statementUploadChosen: false,
|
|
75
66
|
reconListUIState: {
|
|
76
|
-
nodeCollapseState: {},
|
|
77
67
|
scrollPosition: {
|
|
78
68
|
scrollTop: 0,
|
|
79
69
|
},
|
|
80
70
|
},
|
|
81
|
-
excludedAccountIDs: [],
|
|
82
71
|
};
|
|
83
72
|
// Create slice with reducers
|
|
84
73
|
const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
@@ -147,7 +136,7 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
147
136
|
fetchReconciliationSuccess: {
|
|
148
137
|
reducer(draft, action) {
|
|
149
138
|
if (action.payload.accountId == null) {
|
|
150
|
-
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);
|
|
151
140
|
}
|
|
152
141
|
else if (action.payload.reconciliation.reconciliation.length > 0 &&
|
|
153
142
|
action.payload.reconciliation.accounts.length > 0) {
|
|
@@ -359,10 +348,6 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
359
348
|
updateReconListScrollPosition: (draft, action) => {
|
|
360
349
|
draft.reconListUIState.scrollPosition = action.payload.scrollPosition;
|
|
361
350
|
},
|
|
362
|
-
updateNodeCollapseState: (draft, action) => {
|
|
363
|
-
draft.reconListUIState.nodeCollapseState[action.payload.nodeId] =
|
|
364
|
-
action.payload.collapsed;
|
|
365
|
-
},
|
|
366
351
|
setConnectionInProgressForAccount: (draft, action) => {
|
|
367
352
|
if (draft.accountConnectionStatusByAccountID[action.payload.accountId] ==
|
|
368
353
|
null) {
|
|
@@ -440,85 +425,6 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
440
425
|
...localData,
|
|
441
426
|
};
|
|
442
427
|
},
|
|
443
|
-
excludeAccountFromReconciliation: {
|
|
444
|
-
reducer(draft) {
|
|
445
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
446
|
-
fetchState: 'In-Progress',
|
|
447
|
-
error: undefined,
|
|
448
|
-
};
|
|
449
|
-
},
|
|
450
|
-
prepare(payload) {
|
|
451
|
-
return { payload };
|
|
452
|
-
},
|
|
453
|
-
},
|
|
454
|
-
excludeAccountFromReconciliationSuccess: (draft, action) => {
|
|
455
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
456
|
-
fetchState: 'Completed',
|
|
457
|
-
error: undefined,
|
|
458
|
-
};
|
|
459
|
-
const { account, selectedPeriod } = action.payload;
|
|
460
|
-
if (account != null) {
|
|
461
|
-
if (!draft.excludedAccountIDs.includes(account.account_id)) {
|
|
462
|
-
draft.excludedAccountIDs.push(account.account_id);
|
|
463
|
-
}
|
|
464
|
-
updateExcludedAccountExclusionInfo(draft, account);
|
|
465
|
-
const monthYearPeriodId = (0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod);
|
|
466
|
-
if (draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId]
|
|
467
|
-
?.accountIDs != null) {
|
|
468
|
-
draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId].accountIDs = draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId].accountIDs.filter((id) => id !== account.account_id);
|
|
469
|
-
}
|
|
470
|
-
}
|
|
471
|
-
},
|
|
472
|
-
excludeAccountFromReconciliationFailure: (draft, action) => {
|
|
473
|
-
draft.actionFetchState.excludeAccountFetch = {
|
|
474
|
-
fetchState: 'Error',
|
|
475
|
-
error: action.payload.error,
|
|
476
|
-
};
|
|
477
|
-
},
|
|
478
|
-
includeAccountInReconciliation: {
|
|
479
|
-
reducer(draft) {
|
|
480
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
481
|
-
fetchState: 'In-Progress',
|
|
482
|
-
error: undefined,
|
|
483
|
-
};
|
|
484
|
-
},
|
|
485
|
-
prepare(payload) {
|
|
486
|
-
return { payload };
|
|
487
|
-
},
|
|
488
|
-
},
|
|
489
|
-
includeAccountInReconciliationSuccess: (draft, action) => {
|
|
490
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
491
|
-
fetchState: 'Completed',
|
|
492
|
-
error: undefined,
|
|
493
|
-
};
|
|
494
|
-
const { reconciliation, selectedPeriod } = action.payload;
|
|
495
|
-
if (reconciliation == null) {
|
|
496
|
-
return;
|
|
497
|
-
}
|
|
498
|
-
const accountId = reconciliation.account_id;
|
|
499
|
-
draft.excludedAccountIDs = draft.excludedAccountIDs.filter((id) => id !== accountId);
|
|
500
|
-
delete draft.excludedAccountExclusionInfo[accountId];
|
|
501
|
-
const monthYearPeriodId = (0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod);
|
|
502
|
-
const accountReconciliationRecords = draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId];
|
|
503
|
-
if (accountReconciliationRecords != null) {
|
|
504
|
-
if (!accountReconciliationRecords.accountIDs.includes(accountId)) {
|
|
505
|
-
accountReconciliationRecords.accountIDs.push(accountId);
|
|
506
|
-
}
|
|
507
|
-
// put this in a function
|
|
508
|
-
updateReconciliationByAccountIDOnIncludeAccount(draft, accountId, reconciliation, monthYearPeriodId);
|
|
509
|
-
}
|
|
510
|
-
draft.accountConnectionStatusByAccountID[accountId] = {
|
|
511
|
-
status: (0, accountReconState_1.toBankStatusCodeType)(reconciliation.bank_status.code),
|
|
512
|
-
connectionInProgress: false,
|
|
513
|
-
paymentAccountId: undefined,
|
|
514
|
-
};
|
|
515
|
-
},
|
|
516
|
-
includeAccountInReconciliationFailure: (draft, action) => {
|
|
517
|
-
draft.actionFetchState.includeAccountFetch = {
|
|
518
|
-
fetchState: 'Error',
|
|
519
|
-
error: action.payload.error,
|
|
520
|
-
};
|
|
521
|
-
},
|
|
522
428
|
updateStatementUploadChosen: (draft, action) => {
|
|
523
429
|
draft.statementUploadChosen = action.payload.statementUploadChosen;
|
|
524
430
|
},
|
|
@@ -528,38 +434,10 @@ const expenseAutomationReconciliationView = (0, toolkit_1.createSlice)({
|
|
|
528
434
|
},
|
|
529
435
|
});
|
|
530
436
|
// Export actions
|
|
531
|
-
_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;
|
|
532
438
|
// Export reducer
|
|
533
439
|
exports.default = expenseAutomationReconciliationView.reducer;
|
|
534
|
-
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground
|
|
535
|
-
draft.excludedAccountIDs = excludedAccounts.map((ea) => ea.account_id);
|
|
536
|
-
draft.excludedAccountExclusionInfo = {};
|
|
537
|
-
excludedAccounts.forEach((ea) => {
|
|
538
|
-
const { exclusion_info } = ea;
|
|
539
|
-
draft.excludedAccountExclusionInfo[ea.account_id] = {
|
|
540
|
-
bankBalance: exclusion_info.bank_balance != null
|
|
541
|
-
? {
|
|
542
|
-
amount: exclusion_info.bank_balance,
|
|
543
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
544
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
545
|
-
}
|
|
546
|
-
: undefined,
|
|
547
|
-
clearedBalance: exclusion_info.cleared_balance != null
|
|
548
|
-
? {
|
|
549
|
-
amount: exclusion_info.cleared_balance,
|
|
550
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
551
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
552
|
-
}
|
|
553
|
-
: undefined,
|
|
554
|
-
variance: exclusion_info.variance != null
|
|
555
|
-
? {
|
|
556
|
-
amount: exclusion_info.variance,
|
|
557
|
-
currencyCode: ea.currency_code ?? 'USD',
|
|
558
|
-
currencySymbol: ea.currency_symbol ?? '$',
|
|
559
|
-
}
|
|
560
|
-
: undefined,
|
|
561
|
-
};
|
|
562
|
-
});
|
|
440
|
+
function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliationData, refreshViewInBackground) {
|
|
563
441
|
draft.accountReconciliationRecordsBySelectedPeriod[(0, timePeriod_1.toMonthYearPeriodId)(selectedPeriod)] = {
|
|
564
442
|
accountIDs: [],
|
|
565
443
|
reconciliationByAccountID: {},
|
|
@@ -597,9 +475,6 @@ function updateAllReconciliation(draft, accounts, selectedPeriod, reconciliation
|
|
|
597
475
|
? (0, accountState_1.toReconciliationAccountSource)(account.reconciliation_source)
|
|
598
476
|
: undefined,
|
|
599
477
|
},
|
|
600
|
-
accountDetectionReason: account?.detection_info != null && account.detection_reason != null
|
|
601
|
-
? account.detection_reason
|
|
602
|
-
: undefined,
|
|
603
478
|
};
|
|
604
479
|
accountReconciliationRecords.accountIDs.push(reconciliation.account_id);
|
|
605
480
|
});
|
|
@@ -645,42 +520,3 @@ function updateReconciliationByAccountID(draft, accounts, selectedPeriod, accoun
|
|
|
645
520
|
};
|
|
646
521
|
}
|
|
647
522
|
}
|
|
648
|
-
const updateExcludedAccountExclusionInfo = (draft, account) => {
|
|
649
|
-
draft.excludedAccountExclusionInfo[account.account_id] = {
|
|
650
|
-
bankBalance: account.bank_balance != null
|
|
651
|
-
? {
|
|
652
|
-
amount: account.bank_balance,
|
|
653
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
654
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
655
|
-
}
|
|
656
|
-
: undefined,
|
|
657
|
-
clearedBalance: account.cleared_balance != null
|
|
658
|
-
? {
|
|
659
|
-
amount: account.cleared_balance,
|
|
660
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
661
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
662
|
-
}
|
|
663
|
-
: undefined,
|
|
664
|
-
variance: account.variance != null
|
|
665
|
-
? {
|
|
666
|
-
amount: account.variance,
|
|
667
|
-
currencyCode: account.currency_code ?? 'USD',
|
|
668
|
-
currencySymbol: account.currency_symbol ?? '$',
|
|
669
|
-
}
|
|
670
|
-
: undefined,
|
|
671
|
-
};
|
|
672
|
-
};
|
|
673
|
-
const updateReconciliationByAccountIDOnIncludeAccount = (draft, accountId, reconciliation, monthYearPeriodId) => {
|
|
674
|
-
draft.accountReconciliationRecordsBySelectedPeriod[monthYearPeriodId].reconciliationByAccountID[accountId] = {
|
|
675
|
-
accountId,
|
|
676
|
-
reconciliationId: reconciliation.reconciliation_id ?? undefined,
|
|
677
|
-
transactionFetchState: { fetchState: 'Not-Started', error: undefined },
|
|
678
|
-
refreshStatus: { fetchState: 'Not-Started', error: undefined },
|
|
679
|
-
statementDeleteStatus: { fetchState: 'Not-Started', error: undefined },
|
|
680
|
-
statementUploadStatus: { fetchState: 'Not-Started', error: undefined },
|
|
681
|
-
statementUpdateStatus: { fetchState: 'Not-Started', error: undefined },
|
|
682
|
-
statementParseInProgress: reconciliation.bank_status.code === 'parsing',
|
|
683
|
-
localData: {},
|
|
684
|
-
accountDetectionReason: undefined,
|
|
685
|
-
};
|
|
686
|
-
};
|
|
@@ -11,7 +11,7 @@ import { Vendor } from '../../../entity/vendor/vendorState';
|
|
|
11
11
|
import { PlaidConnectionDetails } from '../../spendManagement/plaidAccount/plaidAccountViewState';
|
|
12
12
|
import { AccountReconciliationLocalData, ActionFetchStates, ReconListUIState, ReconciliationTabsState, ReconciliationViewTabType } from '../types/reconciliationViewState';
|
|
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
16
|
export interface ExpenseAutomationReconciliationViewSelector {
|
|
17
17
|
accountListNestedAccountHierarchy: NestedAccountHierarchyForReport[];
|
|
@@ -24,12 +24,7 @@ export interface ExpenseAutomationReconciliationViewSelector {
|
|
|
24
24
|
classListNestedAccountHierarchy: NestedClassHierarchyForReport[];
|
|
25
25
|
completionStatus: CompletionStatusType;
|
|
26
26
|
creditCards: AccountBase[];
|
|
27
|
-
excludeAccountFetchState: FetchStateAndError;
|
|
28
|
-
excludedAccountIDs: ID[];
|
|
29
|
-
excludedAccountReconciliationByAccountID: Record<ID, AccountReconciliationByAccount>;
|
|
30
|
-
excludedAccountReconciliationBySectionID: Record<AccountReconSectionID, AccountReconciliationBySection>;
|
|
31
27
|
fetchStatus: FetchStateAndError;
|
|
32
|
-
includeAccountFetchState: FetchStateAndError;
|
|
33
28
|
monthYearPeriod: MonthYearPeriod;
|
|
34
29
|
plaidConnectionDetails: PlaidConnectionDetails;
|
|
35
30
|
reconciliationTabsState: ReconciliationTabsState;
|
|
@@ -62,6 +57,6 @@ export interface AccountReconciliationByAccount {
|
|
|
62
57
|
statementUpdateStatus: FetchStateAndError;
|
|
63
58
|
statementUploadStatus: FetchStateAndError;
|
|
64
59
|
transactionFetchState: FetchStateAndError;
|
|
65
|
-
accountDetectionReason?: string;
|
|
66
60
|
paymentAccountId?: ID;
|
|
67
61
|
}
|
|
62
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.ALL_ACCOUNT_RECON_SECTION_IDS = void 0;
|
|
4
4
|
const stringToUnion_1 = require("../../../commonStateTypes/stringToUnion");
|
|
5
5
|
exports.ALL_ACCOUNT_RECON_SECTION_IDS = ['assets', 'liabilities'];
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
6
7
|
const toAccountReconSectionID = (v) => (0, stringToUnion_1.stringToUnion)(v, exports.ALL_ACCOUNT_RECON_SECTION_IDS);
|
|
7
|
-
exports.toAccountReconSectionID = toAccountReconSectionID;
|
|
@@ -15,7 +15,6 @@ const accountSelector_1 = require("../../../entity/account/accountSelector");
|
|
|
15
15
|
const accountReconSelector_1 = require("../../../entity/accountRecon/accountReconSelector");
|
|
16
16
|
const tenantSelector_1 = require("../../../entity/tenant/tenantSelector");
|
|
17
17
|
const vendorSelector_1 = require("../../../entity/vendor/vendorSelector");
|
|
18
|
-
const zeniDayJS_1 = require("../../../zeniDayJS");
|
|
19
18
|
const accountListSelector_1 = require("../../accountList/accountListSelector");
|
|
20
19
|
const classListSelector_1 = require("../../classList/classListSelector");
|
|
21
20
|
const reconciliationViewReducer_1 = require("../reducers/reconciliationViewReducer");
|
|
@@ -97,30 +96,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
97
96
|
totalVariancePercentage: undefined,
|
|
98
97
|
},
|
|
99
98
|
},
|
|
100
|
-
excludedAccountReconciliationByAccountID: {},
|
|
101
|
-
excludedAccountReconciliationBySectionID: {
|
|
102
|
-
assets: {
|
|
103
|
-
sectionId: 'assets',
|
|
104
|
-
accountIDs: [],
|
|
105
|
-
totalBankBalance: undefined,
|
|
106
|
-
totalClearedBalance: undefined,
|
|
107
|
-
totalReconciledBalance: undefined,
|
|
108
|
-
totalVariance: undefined,
|
|
109
|
-
totalVariancePercentage: undefined,
|
|
110
|
-
},
|
|
111
|
-
liabilities: {
|
|
112
|
-
sectionId: 'liabilities',
|
|
113
|
-
accountIDs: [],
|
|
114
|
-
totalBankBalance: undefined,
|
|
115
|
-
totalClearedBalance: undefined,
|
|
116
|
-
totalReconciledBalance: undefined,
|
|
117
|
-
totalVariance: undefined,
|
|
118
|
-
totalVariancePercentage: undefined,
|
|
119
|
-
},
|
|
120
|
-
},
|
|
121
|
-
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
122
|
-
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
123
|
-
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
124
99
|
};
|
|
125
100
|
}
|
|
126
101
|
const allAccountIDs = accountReconForMonthYearPeriod.accountIDs;
|
|
@@ -258,8 +233,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
258
233
|
.transactionFetchState,
|
|
259
234
|
accountListState.byReportId.accountList,
|
|
260
235
|
]),
|
|
261
|
-
accountDetectionReason: accountReconForMonthYearPeriod.reconciliationByAccountID[accountID]
|
|
262
|
-
.accountDetectionReason,
|
|
263
236
|
};
|
|
264
237
|
});
|
|
265
238
|
const accountReconciliationBySectionID = {
|
|
@@ -282,88 +255,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
282
255
|
totalVariancePercentage: liabilityTotals.variancePercentage,
|
|
283
256
|
},
|
|
284
257
|
};
|
|
285
|
-
const bankAccountIdSet = new Set(uniqueBankAccounts.map((a) => a.accountId));
|
|
286
|
-
const creditCardIdSet = new Set(uniqueCreditCards.map((a) => a.accountId));
|
|
287
|
-
const excludedAssetAccountIDs = [];
|
|
288
|
-
const excludedLiabilityAccountIDs = [];
|
|
289
|
-
reconciliationViewState.excludedAccountIDs.forEach((accountID) => {
|
|
290
|
-
const isAsset = bankAccountIdSet.has(accountID);
|
|
291
|
-
const isLiability = creditCardIdSet.has(accountID);
|
|
292
|
-
if (!isAsset && !isLiability) {
|
|
293
|
-
return;
|
|
294
|
-
}
|
|
295
|
-
if (isAsset) {
|
|
296
|
-
excludedAssetAccountIDs.push(accountID);
|
|
297
|
-
}
|
|
298
|
-
else {
|
|
299
|
-
excludedLiabilityAccountIDs.push(accountID);
|
|
300
|
-
}
|
|
301
|
-
});
|
|
302
|
-
const excludedAccountReconciliationBySectionID = {
|
|
303
|
-
assets: {
|
|
304
|
-
sectionId: 'assets',
|
|
305
|
-
accountIDs: excludedAssetAccountIDs,
|
|
306
|
-
},
|
|
307
|
-
liabilities: {
|
|
308
|
-
sectionId: 'liabilities',
|
|
309
|
-
accountIDs: excludedLiabilityAccountIDs,
|
|
310
|
-
},
|
|
311
|
-
};
|
|
312
|
-
const excludedAccountReconciliationByAccountID = {};
|
|
313
|
-
const accountsInState = Object.values(accountState.accountsByKey);
|
|
314
|
-
const accountsInStateMap = new Map(accountsInState.map((a) => [a.accountId, a]));
|
|
315
|
-
reconciliationViewState.excludedAccountIDs.forEach((excludedAccountID) => {
|
|
316
|
-
const account = accountsInStateMap.get(excludedAccountID);
|
|
317
|
-
const exclusionInfo = reconciliationViewState.excludedAccountExclusionInfo[excludedAccountID];
|
|
318
|
-
if (account != null) {
|
|
319
|
-
excludedAccountReconciliationByAccountID[excludedAccountID] = {
|
|
320
|
-
refreshStatus: { fetchState: 'Not-Started' },
|
|
321
|
-
statementUpdateStatus: { fetchState: 'Not-Started' },
|
|
322
|
-
statementUploadStatus: { fetchState: 'Not-Started' },
|
|
323
|
-
statementDeleteStatus: { fetchState: 'Not-Started' },
|
|
324
|
-
localData: {},
|
|
325
|
-
connectionInProgress: false,
|
|
326
|
-
statementParseInProgress: false,
|
|
327
|
-
accountConnectionStatus: 'not_connected',
|
|
328
|
-
transactionFetchState: { fetchState: 'Not-Started' },
|
|
329
|
-
accountReconEntity: {
|
|
330
|
-
account: {
|
|
331
|
-
accountId: account.accountId,
|
|
332
|
-
accountName: account.accountName,
|
|
333
|
-
accountType: account.accountType,
|
|
334
|
-
accountSubType: account.accountSubType,
|
|
335
|
-
accountDescription: account.accountDescription,
|
|
336
|
-
qboId: account.qboId,
|
|
337
|
-
coaId: account.coaId,
|
|
338
|
-
labels: account.labels,
|
|
339
|
-
},
|
|
340
|
-
currency: {
|
|
341
|
-
currencyCode: exclusionInfo?.bankBalance?.currencyCode ??
|
|
342
|
-
exclusionInfo?.clearedBalance?.currencyCode ??
|
|
343
|
-
'USD',
|
|
344
|
-
currencySymbol: exclusionInfo?.bankBalance?.currencySymbol ??
|
|
345
|
-
exclusionInfo?.clearedBalance?.currencySymbol ??
|
|
346
|
-
'$',
|
|
347
|
-
},
|
|
348
|
-
startDate: (0, zeniDayJS_1.date)(new Date().toDateString()),
|
|
349
|
-
endDate: (0, zeniDayJS_1.date)(new Date().toDateString()),
|
|
350
|
-
statementStatus: { code: 'not_found', label: 'Not Found' },
|
|
351
|
-
transactionsToReconcile: [],
|
|
352
|
-
transactionsToReview: [],
|
|
353
|
-
balance: exclusionInfo?.bankBalance,
|
|
354
|
-
clearedBalance: exclusionInfo?.clearedBalance,
|
|
355
|
-
variance: exclusionInfo?.variance,
|
|
356
|
-
variancePercentage: exclusionInfo?.variance != null &&
|
|
357
|
-
exclusionInfo?.bankBalance != null &&
|
|
358
|
-
exclusionInfo?.bankBalance.amount !== 0
|
|
359
|
-
? Math.abs((exclusionInfo.variance.amount /
|
|
360
|
-
exclusionInfo.bankBalance.amount) *
|
|
361
|
-
100)
|
|
362
|
-
: undefined,
|
|
363
|
-
},
|
|
364
|
-
};
|
|
365
|
-
}
|
|
366
|
-
});
|
|
367
258
|
const accountListNestedAccountHierarchy = (0, accountListSelector_1.getNestedAccountListHierarchy)(accountListState, 'accountList');
|
|
368
259
|
const classListNestedAccountHierarchy = (0, classListSelector_1.getNestedClassListHierarchy)(classListState);
|
|
369
260
|
const accountsList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'accountList');
|
|
@@ -424,11 +315,6 @@ exports.getExpenseAutomationReconciliationView = (0, toolkit_1.createSelector)((
|
|
|
424
315
|
allClassList: allClasses,
|
|
425
316
|
reviewTabSelectedVendorByTransactionId,
|
|
426
317
|
reconListUIState: reconciliationViewState.reconListUIState,
|
|
427
|
-
excludedAccountReconciliationBySectionID,
|
|
428
|
-
excludedAccountReconciliationByAccountID,
|
|
429
|
-
excludeAccountFetchState: reconciliationViewState.actionFetchState.excludeAccountFetch,
|
|
430
|
-
includeAccountFetchState: reconciliationViewState.actionFetchState.includeAccountFetch,
|
|
431
|
-
excludedAccountIDs: reconciliationViewState.excludedAccountIDs,
|
|
432
318
|
};
|
|
433
319
|
});
|
|
434
320
|
const isAccountReconReport = (reportId) => {
|
|
@@ -50,16 +50,12 @@ function getExpenseAutomationTransactionView(state) {
|
|
|
50
50
|
const monthEndFetchState = monthYearPeriodId != null
|
|
51
51
|
? (monthEndCloseChecksViewState.monthEndCloseChecksViewByTenantId[currentTenant.tenantId]?.[monthYearPeriodId] ?? { fetchState: 'Not-Started', error: undefined })
|
|
52
52
|
: { fetchState: 'Not-Started', error: undefined };
|
|
53
|
-
const isAccountingClassesEnabled = (0, tenantSelector_1.getIsAccountingClassesEnabled)(state);
|
|
54
|
-
const allFetchStateList = [
|
|
55
|
-
accountList,
|
|
56
|
-
expenseAutomationTransactionsViewState.transactionCategorizationView[selectedTransactionCategorizationTab],
|
|
57
|
-
];
|
|
58
|
-
if (isAccountingClassesEnabled) {
|
|
59
|
-
allFetchStateList.push(classList);
|
|
60
|
-
}
|
|
61
53
|
const fetchStatus = (0, reduceFetchState_1.reduceAnyFetchState)([
|
|
62
|
-
(0, reduceFetchState_1.reduceAllFetchState)(
|
|
54
|
+
(0, reduceFetchState_1.reduceAllFetchState)([
|
|
55
|
+
accountList,
|
|
56
|
+
classList,
|
|
57
|
+
expenseAutomationTransactionsViewState.transactionCategorizationView[selectedTransactionCategorizationTab],
|
|
58
|
+
]),
|
|
63
59
|
monthEndFetchState,
|
|
64
60
|
]);
|
|
65
61
|
const totalCountByReview = expenseAutomationTransactionsViewState.transactionCategorizationView.review
|
|
@@ -8,15 +8,12 @@ import { JEScheduleTransactionKey, ScheduleTypes } from '../../../entity/jeSched
|
|
|
8
8
|
import { VendorBase } from '../../../entity/vendor/vendorState';
|
|
9
9
|
export declare const toJEScheduleSortKey: (v: string) => "vendor" | "type" | "category" | "class" | "memo" | "transactionDate" | "totalAmount" | "runningBalance" | "depCategory" | "scheduleCategory" | "startMonth" | "amortizationPeriod" | "jePostingDate" | "remainingMonths";
|
|
10
10
|
export type JEScheduleSortKey = ReturnType<typeof toJEScheduleSortKey>;
|
|
11
|
-
export declare const toJEScheduleMainTab: (v: string) => "completed" | "pending_review" | "ongoing";
|
|
12
|
-
export type JEScheduleMainTab = ReturnType<typeof toJEScheduleMainTab>;
|
|
13
11
|
export interface JESchedulesViewUIState {
|
|
14
12
|
scrollPosition: {
|
|
15
13
|
scrollTop: number;
|
|
16
14
|
scrollLeft?: number;
|
|
17
15
|
} | undefined;
|
|
18
16
|
searchString: string;
|
|
19
|
-
selectedMainTab: JEScheduleMainTab;
|
|
20
17
|
sortKey: JEScheduleSortKey;
|
|
21
18
|
sortOrder: SortOrder;
|
|
22
19
|
totalCount: number;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.toJEScheduleSortKey = void 0;
|
|
4
4
|
const stringToUnion_1 = require("../../../commonStateTypes/stringToUnion");
|
|
5
5
|
const JE_SCHEDULE_SORT_KEYS = [
|
|
6
6
|
'vendor',
|
|
@@ -20,10 +20,3 @@ const JE_SCHEDULE_SORT_KEYS = [
|
|
|
20
20
|
];
|
|
21
21
|
const toJEScheduleSortKey = (v) => (0, stringToUnion_1.stringToUnion)(v, JE_SCHEDULE_SORT_KEYS);
|
|
22
22
|
exports.toJEScheduleSortKey = toJEScheduleSortKey;
|
|
23
|
-
const JE_SCHEDULE_MAIN_TABS = [
|
|
24
|
-
'pending_review',
|
|
25
|
-
'ongoing',
|
|
26
|
-
'completed',
|
|
27
|
-
];
|
|
28
|
-
const toJEScheduleMainTab = (v) => (0, stringToUnion_1.stringToUnion)(v, JE_SCHEDULE_MAIN_TABS);
|
|
29
|
-
exports.toJEScheduleMainTab = toJEScheduleMainTab;
|
|
@@ -74,24 +74,13 @@ 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>;
|
|
92
82
|
}
|
|
93
83
|
export interface ReconListUIState {
|
|
94
|
-
nodeCollapseState: Record<ID, boolean>;
|
|
95
84
|
scrollPosition: {
|
|
96
85
|
scrollTop: number;
|
|
97
86
|
scrollLeft?: number;
|
|
@@ -101,8 +90,6 @@ export interface ReconciliationViewState extends FetchStateAndError {
|
|
|
101
90
|
accountConnectionStatusByAccountID: Record<ID, BankConnectionStatus>;
|
|
102
91
|
accountReconciliationRecordsBySelectedPeriod: Record<MonthYearPeriodId, AccountReconciliationRecords>;
|
|
103
92
|
actionFetchState: ActionFetchStates;
|
|
104
|
-
excludedAccountExclusionInfo: Record<ID, ExclusionInfo>;
|
|
105
|
-
excludedAccountIDs: ID[];
|
|
106
93
|
reconListUIState: ReconListUIState;
|
|
107
94
|
reconTabsState: ReconciliationTabsState;
|
|
108
95
|
refreshStatus: FetchStateAndError;
|
|
@@ -132,7 +119,6 @@ export interface AccountReconciliationDataWithTransactionFetchState {
|
|
|
132
119
|
statementUpdateStatus: FetchStateAndError;
|
|
133
120
|
statementUploadStatus: FetchStateAndError;
|
|
134
121
|
transactionFetchState: FetchStateAndError;
|
|
135
|
-
accountDetectionReason?: string;
|
|
136
122
|
reconciliationId?: ID;
|
|
137
123
|
}
|
|
138
124
|
export {};
|
|
@@ -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<{
|
|
@@ -126,12 +126,10 @@ function buildClassColumns(classHierarchy, classesToFilterOut) {
|
|
|
126
126
|
qboId: c.qboId,
|
|
127
127
|
}))
|
|
128
128
|
.sort((a, b) => {
|
|
129
|
-
|
|
130
|
-
const bIsNotSpecified = b.classId === exports.NOT_SPECIFIED_CLASS_ID;
|
|
131
|
-
if (aIsNotSpecified && !bIsNotSpecified) {
|
|
129
|
+
if (a.classId === exports.NOT_SPECIFIED_CLASS_ID) {
|
|
132
130
|
return 1;
|
|
133
131
|
}
|
|
134
|
-
if (
|
|
132
|
+
if (b.classId === exports.NOT_SPECIFIED_CLASS_ID) {
|
|
135
133
|
return -1;
|
|
136
134
|
}
|
|
137
135
|
return a.className.localeCompare(b.className, [], {
|
|
@@ -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;
|