@zeniai/client-epic-state 5.0.71 → 5.0.72
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/coreEpics.js +1 -1
- package/lib/entity/account/accountSelector.d.ts +1 -1
- package/lib/entity/account/accountState.d.ts +1 -1
- package/lib/entity/account/subAccountSelector.d.ts +1 -1
- package/lib/entity/aiAccountantCustomer/aiAccountantCustomerPayload.js +3 -1
- package/lib/entity/aiAccountantCustomer/aiAccountantCustomerReducer.js +2 -1
- package/lib/entity/aiAccountantCustomer/aiAccountantCustomerSelector.d.ts +1 -1
- package/lib/entity/chargeCard/chargeCardReducer.d.ts +2 -19
- package/lib/entity/chargeCard/chargeCardReducer.js +2 -35
- package/lib/entity/chargeCardTransaction/chargeCardTransactionReducer.d.ts +1 -14
- package/lib/entity/chargeCardTransaction/chargeCardTransactionReducer.js +2 -36
- package/lib/entity/sectionProjectView/sectionProjectViewReducer.d.ts +1 -1
- package/lib/entity/sectionProjectView/sectionProjectViewSelector.js +1 -1
- package/lib/entity/tenant/SessionManager.js +3 -6
- package/lib/entity/tenant/clearAllEpic.d.ts +2 -2
- package/lib/entity/tenant/clearAllEpic.js +2 -2
- package/lib/entity/tenant/epic/saveAPIKeyConnectionEpic.js +2 -6
- package/lib/entity/tenant/epic/saveOAuthConnectionEpic.js +2 -6
- package/lib/entity/tenant/tenantReducer.js +1 -6
- package/lib/entity/transaction/payloadTypes/transactionLinePayload.js +1 -3
- package/lib/epic.d.ts +9 -9
- package/lib/epic.js +10 -10
- package/lib/esm/coreEpics.js +1 -1
- package/lib/esm/entity/aiAccountantCustomer/aiAccountantCustomerPayload.js +3 -1
- package/lib/esm/entity/aiAccountantCustomer/aiAccountantCustomerReducer.js +2 -1
- package/lib/esm/entity/chargeCard/chargeCardReducer.js +1 -34
- package/lib/esm/entity/chargeCardTransaction/chargeCardTransactionReducer.js +1 -35
- package/lib/esm/entity/sectionProjectView/sectionProjectViewSelector.js +1 -1
- package/lib/esm/entity/tenant/SessionManager.js +1 -4
- package/lib/esm/entity/tenant/clearAllEpic.js +2 -2
- package/lib/esm/entity/tenant/epic/saveAPIKeyConnectionEpic.js +2 -6
- package/lib/esm/entity/tenant/epic/saveOAuthConnectionEpic.js +2 -6
- package/lib/esm/entity/tenant/tenantReducer.js +1 -6
- package/lib/esm/entity/transaction/payloadTypes/transactionLinePayload.js +1 -3
- package/lib/esm/epic.js +10 -10
- package/lib/esm/index.js +13 -17
- package/lib/esm/reducer.js +2 -2
- package/lib/esm/view/aiAccountantView/epics/fetchAiAccountantCustomersEpic.js +5 -2
- package/lib/esm/view/aiAccountantView/epics/fetchAiAccountantJobsEpic.js +5 -2
- package/lib/esm/view/aiAccountantView/epics/triggerAiAccountantJobEpic.js +1 -4
- package/lib/esm/view/companyTaskManagerView/companyTaskManagerViewSelector.js +1 -1
- package/lib/esm/view/companyTaskManagerView/epics/fetchTaskManagerMetricsEpic.js +1 -1
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/fetchBulkUploadBatchesEpic.js +2 -2
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/fetchCompletedTransactionsEpic.js +1 -2
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/restoreBulkUploadAutomatchingOnMountEpic.js +6 -8
- package/lib/esm/view/expenseAutomationView/epics/missingReceipts/searchTransactionsForManualMatchEpic.js +1 -7
- package/lib/esm/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationEpic.js +1 -11
- package/lib/esm/view/expenseAutomationView/reducers/missingReceiptsViewReducer.js +1 -2
- package/lib/esm/view/expenseAutomationView/reducers/transactionsViewReducer.js +1 -127
- package/lib/esm/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +1 -20
- package/lib/esm/view/expenseAutomationView/types/missingReceiptsViewState.js +2 -0
- package/lib/esm/view/financeStatement/financeStatementSelector.js +1 -1
- package/lib/esm/view/spendManagement/chargeCards/cashbackDetail/cashbackDetailReducer.js +2 -3
- package/lib/esm/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigReducer.js +2 -3
- package/lib/esm/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailReducer.js +18 -55
- package/lib/esm/view/spendManagement/chargeCards/chargeCardDetail/fetchChargeCardDetailEpic.js +2 -16
- package/lib/esm/view/spendManagement/chargeCards/chargeCardDetail/fetchChargeCardDetailPageEpic.js +4 -5
- package/lib/esm/view/spendManagement/chargeCards/chargeCardList/chargeCardListReducer.js +9 -26
- package/lib/esm/view/spendManagement/chargeCards/chargeCardList/fetchChargeCardListPageEpic.js +6 -9
- package/lib/esm/view/spendManagement/chargeCards/chargeCardPaymentHistory/chargeCardPaymentHistoryReducer.js +2 -3
- package/lib/esm/view/spendManagement/chargeCards/chargeCardPaymentHistory/fetchChargeCardPaymentPageEpic.js +1 -1
- package/lib/esm/view/spendManagement/chargeCards/chargeCardRepaymentDetail/chargeCardRepaymentDetailReducer.js +3 -7
- package/lib/esm/view/taskManager/cannedResponsesView/epics/fetchCannedResponsesEpic.js +1 -1
- package/lib/esm/view/taskManager/cannedResponsesView/epics/saveCannedResponseEpic.js +1 -1
- package/lib/esm/view/taskManager/taskDetailView/epics/unsnoozeTaskEpic.js +1 -1
- package/lib/esm/view/transactionDetail/transactionDetailSelector.js +1 -7
- package/lib/index.d.ts +15 -19
- package/lib/index.js +58 -72
- package/lib/reducer.d.ts +2 -2
- package/lib/reducer.js +2 -2
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -0
- package/lib/view/aiAccountantView/aiAccountantViewPayload.d.ts +2 -2
- package/lib/view/aiAccountantView/aiAccountantViewReducer.d.ts +1 -1
- package/lib/view/aiAccountantView/epics/fetchAiAccountantCustomersEpic.js +5 -2
- package/lib/view/aiAccountantView/epics/fetchAiAccountantJobsEpic.js +5 -2
- package/lib/view/aiAccountantView/epics/triggerAiAccountantJobEpic.js +1 -4
- package/lib/view/companyTaskManagerView/companyTaskManagerViewSelector.d.ts +1 -1
- package/lib/view/companyTaskManagerView/companyTaskManagerViewSelector.js +1 -1
- package/lib/view/expenseAutomationView/epics/missingReceipts/fetchBulkUploadBatchesEpic.js +2 -2
- package/lib/view/expenseAutomationView/epics/missingReceipts/fetchCompletedTransactionsEpic.js +1 -2
- package/lib/view/expenseAutomationView/epics/missingReceipts/restoreBulkUploadAutomatchingOnMountEpic.js +6 -8
- package/lib/view/expenseAutomationView/epics/missingReceipts/searchTransactionsForManualMatchEpic.js +1 -7
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationEpic.d.ts +2 -2
- package/lib/view/expenseAutomationView/epics/transactionCategorization/fetchTransactionCategorizationEpic.js +0 -10
- package/lib/view/expenseAutomationView/helpers/transactionCategorizationLocalDataHelper.d.ts +1 -1
- package/lib/view/expenseAutomationView/payload/transactionCategorizationPayload.d.ts +0 -21
- package/lib/view/expenseAutomationView/reducers/missingReceiptsViewReducer.d.ts +1 -2
- package/lib/view/expenseAutomationView/reducers/missingReceiptsViewReducer.js +1 -2
- package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.d.ts +3 -9
- package/lib/view/expenseAutomationView/reducers/transactionsViewReducer.js +2 -128
- package/lib/view/expenseAutomationView/selectorTypes/missingReceiptsSelectorTypes.d.ts +1 -2
- package/lib/view/expenseAutomationView/selectorTypes/transactionsViewSelectorTypes.d.ts +0 -14
- package/lib/view/expenseAutomationView/selectors/transactionCategorizationSelector.js +1 -20
- package/lib/view/expenseAutomationView/types/missingReceiptsViewState.d.ts +2 -1
- package/lib/view/expenseAutomationView/types/missingReceiptsViewState.js +4 -1
- package/lib/view/expenseAutomationView/types/transactionsViewState.d.ts +2 -41
- package/lib/view/financeStatement/financeStatementSelector.js +1 -1
- package/lib/view/profitAndLossProjectView/profitAndLossProjectViewSelectorTypes.d.ts +1 -1
- package/lib/view/spendManagement/chargeCards/cashbackDetail/cashbackDetailReducer.d.ts +1 -3
- package/lib/view/spendManagement/chargeCards/cashbackDetail/cashbackDetailReducer.js +2 -3
- package/lib/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigReducer.d.ts +1 -3
- package/lib/view/spendManagement/chargeCards/chargeCardConfig/chargeCardConfigReducer.js +2 -3
- package/lib/view/spendManagement/chargeCards/chargeCardDetail/chargeCardDetailReducer.js +18 -55
- package/lib/view/spendManagement/chargeCards/chargeCardDetail/fetchChargeCardDetailEpic.js +2 -16
- package/lib/view/spendManagement/chargeCards/chargeCardDetail/fetchChargeCardDetailPageEpic.js +4 -5
- package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardListReducer.d.ts +3 -18
- package/lib/view/spendManagement/chargeCards/chargeCardList/chargeCardListReducer.js +10 -27
- package/lib/view/spendManagement/chargeCards/chargeCardList/fetchChargeCardListPageEpic.js +6 -9
- package/lib/view/spendManagement/chargeCards/chargeCardPaymentHistory/chargeCardPaymentHistoryReducer.d.ts +1 -3
- package/lib/view/spendManagement/chargeCards/chargeCardPaymentHistory/chargeCardPaymentHistoryReducer.js +2 -3
- package/lib/view/spendManagement/chargeCards/chargeCardPaymentHistory/fetchChargeCardPaymentPageEpic.js +1 -1
- package/lib/view/spendManagement/chargeCards/chargeCardRepaymentDetail/chargeCardRepaymentDetailReducer.d.ts +1 -3
- package/lib/view/spendManagement/chargeCards/chargeCardRepaymentDetail/chargeCardRepaymentDetailReducer.js +3 -7
- package/lib/view/transactionDetail/transactionDetailSelector.js +1 -7
- package/lib/view/zeniOAuthView/zeniOAuthSelector.d.ts +1 -1
- package/package.json +4 -9
- package/lib/commonStateTypes/cacheOverrideFetchReducer.d.ts +0 -17
- package/lib/commonStateTypes/cacheOverrideFetchReducer.js +0 -20
- package/lib/commonStateTypes/pusherActions.d.ts +0 -11
- package/lib/commonStateTypes/pusherActions.js +0 -6
- package/lib/esm/commonStateTypes/cacheOverrideFetchReducer.js +0 -16
- package/lib/esm/commonStateTypes/pusherActions.js +0 -3
- package/lib/esm/view/expenseAutomationView/types/completedSubTab.js +0 -17
- package/lib/view/expenseAutomationView/types/completedSubTab.d.ts +0 -10
- package/lib/view/expenseAutomationView/types/completedSubTab.js +0 -21
|
@@ -16,7 +16,7 @@ const projectListSelector_1 = require("../../projectList/projectListSelector");
|
|
|
16
16
|
const expenseAutomationViewSelectorTypes_1 = require("../selectorTypes/expenseAutomationViewSelectorTypes");
|
|
17
17
|
function getExpenseAutomationTransactionView(state) {
|
|
18
18
|
const { accountState, classState, classListState, accountListState, expenseAutomationTransactionsViewState, expenseAutomationViewState, projectState, projectListState, transactionState, monthEndCloseChecksState, monthEndCloseChecksViewState, } = state;
|
|
19
|
-
const {
|
|
19
|
+
const { selectedTransactionCategorizationTab } = expenseAutomationTransactionsViewState;
|
|
20
20
|
const { uiState, refreshStatus, saveStatus, markAsNotMiscategorizedStatus, transactionIdsBySelectedPeriod, transactionReviewLocalDataById, selectedCheckBoxTransactionIds, transactionIdsWithUnsavedData, uploadReceiptStatusById, selectedTransactionId, selectedTransactionLineId, } = expenseAutomationTransactionsViewState.transactionCategorizationView[selectedTransactionCategorizationTab];
|
|
21
21
|
const uncategorizedIncomeExpense = (0, accountListSelector_1.getUncategorizedAccounts)(accountState, accountListState, 'accountList');
|
|
22
22
|
const accountList = (0, accountListSelector_1.getAccountList)(accountState, accountListState, 'accountList');
|
|
@@ -69,27 +69,10 @@ function getExpenseAutomationTransactionView(state) {
|
|
|
69
69
|
.uiState.totalCount;
|
|
70
70
|
const totalCountByAutoCat = expenseAutomationTransactionsViewState.transactionCategorizationView
|
|
71
71
|
.autoCategorized.uiState.totalCount;
|
|
72
|
-
// Per-(sub-)tab counts powering pagination, in-list "showing X of Y", and
|
|
73
|
-
// any save/refresh round-trips. Sourced from `uiState.totalCount` which
|
|
74
|
-
// mirrors the response's `total_count` for whatever tab/sub-tab the user is
|
|
75
|
-
// viewing (e.g. only the Manual sub-tab rows for Completed → Manual).
|
|
76
72
|
const totalCountByTab = {
|
|
77
73
|
review: monthYearPeriodId != null ? totalCountByReview[monthYearPeriodId] : 0,
|
|
78
74
|
autoCategorized: monthYearPeriodId != null ? totalCountByAutoCat[monthYearPeriodId] : 0,
|
|
79
75
|
};
|
|
80
|
-
// Parent-tab badge counts. Sourced from `parent_tab_total_count` in the
|
|
81
|
-
// listing response and used exclusively by the navbar / tab strip badges.
|
|
82
|
-
// Independent of which Completed sub-tab is active so the badge stays
|
|
83
|
-
// stable across sub-tab switches.
|
|
84
|
-
const parentTotalCountByTab = expenseAutomationTransactionsViewState.parentTotalCountByTab;
|
|
85
|
-
const parentTabTotalCountByTab = {
|
|
86
|
-
review: monthYearPeriodId != null
|
|
87
|
-
? (parentTotalCountByTab.review[monthYearPeriodId] ?? 0)
|
|
88
|
-
: 0,
|
|
89
|
-
autoCategorized: monthYearPeriodId != null
|
|
90
|
-
? (parentTotalCountByTab.autoCategorized[monthYearPeriodId] ?? 0)
|
|
91
|
-
: 0,
|
|
92
|
-
};
|
|
93
76
|
const fetchStateByTab = {
|
|
94
77
|
review: {
|
|
95
78
|
fetchState: expenseAutomationTransactionsViewState.transactionCategorizationView
|
|
@@ -131,11 +114,9 @@ function getExpenseAutomationTransactionView(state) {
|
|
|
131
114
|
markAsNotMiscategorizedStatus,
|
|
132
115
|
completionStatus,
|
|
133
116
|
totalCountByTab,
|
|
134
|
-
parentTabTotalCountByTab,
|
|
135
117
|
fetchStateByTransactionTabs: fetchStateByTab,
|
|
136
118
|
uploadReceiptStatusById,
|
|
137
119
|
selectedTransactionId,
|
|
138
120
|
selectedTransactionLineId,
|
|
139
|
-
selectedTransactionCategorizationCompletedSubTab,
|
|
140
121
|
};
|
|
141
122
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { FetchStateAndError, FetchedState, ID } from '../../../commonStateTypes/common';
|
|
2
2
|
import { SortOrder } from '../../../commonStateTypes/selectorTypes/sortOrderTypes';
|
|
3
3
|
import { MonthYearPeriodId } from '../../../commonStateTypes/timePeriod';
|
|
4
|
-
import { CompletedSubTab } from './completedSubTab';
|
|
5
4
|
export declare const toMissingReceiptsSortKey: (v: string) => "date" | "amount" | "vendor" | "category" | "class";
|
|
6
5
|
export type MissingReceiptsSortKey = ReturnType<typeof toMissingReceiptsSortKey>;
|
|
7
6
|
export interface MissingReceiptsViewUIState {
|
|
@@ -32,6 +31,8 @@ export declare const toBulkUploadResultsTab: (v: string) => "completed" | "unmat
|
|
|
32
31
|
export type BulkUploadResultsTab = ReturnType<typeof toBulkUploadResultsTab>;
|
|
33
32
|
export declare const toMissingReceiptsTab: (v: string) => "completed" | "unmatched" | "missing";
|
|
34
33
|
export type MissingReceiptsTab = ReturnType<typeof toMissingReceiptsTab>;
|
|
34
|
+
export declare const toCompletedSubTab: (v: string) => "all" | "manual" | "ai_accountant";
|
|
35
|
+
export type CompletedSubTab = ReturnType<typeof toCompletedSubTab>;
|
|
35
36
|
export declare const toMatchSource: (v: string) => "manual" | "ai";
|
|
36
37
|
export type MatchSource = ReturnType<typeof toMatchSource>;
|
|
37
38
|
export declare const toBulkUploadSortKey: (v: string) => "date" | "amount" | "vendor" | "category" | "class";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.toBulkUploadSortKey = exports.toMatchSource = exports.toMissingReceiptsTab = exports.toBulkUploadResultsTab = exports.toBulkUploadPhase = exports.toBatchFileStatus = exports.BATCH_FILE_STATUSES = exports.toBatchStatusValue = exports.MIN_MANUAL_TRANSACTION_SEARCH_LENGTH = exports.toMissingReceiptsSortKey = void 0;
|
|
3
|
+
exports.toBulkUploadSortKey = exports.toMatchSource = exports.toCompletedSubTab = exports.toMissingReceiptsTab = exports.toBulkUploadResultsTab = exports.toBulkUploadPhase = exports.toBatchFileStatus = exports.BATCH_FILE_STATUSES = exports.toBatchStatusValue = exports.MIN_MANUAL_TRANSACTION_SEARCH_LENGTH = exports.toMissingReceiptsSortKey = void 0;
|
|
4
4
|
exports.isUnmatchedTabFileStatus = isUnmatchedTabFileStatus;
|
|
5
5
|
const stringToUnion_1 = require("../../../commonStateTypes/stringToUnion");
|
|
6
6
|
const MISSING_RECEIPTS_SORT_KEYS = [
|
|
@@ -49,6 +49,9 @@ exports.toBulkUploadResultsTab = toBulkUploadResultsTab;
|
|
|
49
49
|
const MISSING_RECEIPTS_TABS = ['missing', 'completed', 'unmatched'];
|
|
50
50
|
const toMissingReceiptsTab = (v) => (0, stringToUnion_1.stringToUnion)(v.trim().toLowerCase(), MISSING_RECEIPTS_TABS);
|
|
51
51
|
exports.toMissingReceiptsTab = toMissingReceiptsTab;
|
|
52
|
+
const COMPLETED_SUB_TABS = ['all', 'ai_accountant', 'manual'];
|
|
53
|
+
const toCompletedSubTab = (v) => (0, stringToUnion_1.stringToUnion)(v.trim().toLowerCase(), COMPLETED_SUB_TABS);
|
|
54
|
+
exports.toCompletedSubTab = toCompletedSubTab;
|
|
52
55
|
const MATCH_SOURCES = ['ai', 'manual'];
|
|
53
56
|
const toMatchSource = (v) => (0, stringToUnion_1.stringToUnion)(v.trim().toLowerCase(), MATCH_SOURCES);
|
|
54
57
|
exports.toMatchSource = toMatchSource;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Amount } from '../../../commonStateTypes/amount';
|
|
2
|
-
import {
|
|
2
|
+
import { FetchStateAndError, FetchedState, ID } from '../../../commonStateTypes/common';
|
|
3
3
|
import { Recommendation, RecommendationWithCOT } from '../../../commonStateTypes/recommendationBase';
|
|
4
4
|
import { SortOrder } from '../../../commonStateTypes/selectorTypes/sortOrderTypes';
|
|
5
5
|
import { MonthYearPeriodId } from '../../../commonStateTypes/timePeriod';
|
|
@@ -7,17 +7,15 @@ import { PageToken } from '../../../commonStateTypes/viewAndReport/viewAndReport
|
|
|
7
7
|
import { AccountBase } from '../../../entity/account/accountState';
|
|
8
8
|
import { ClassBase } from '../../../entity/class/classState';
|
|
9
9
|
import { CustomerBase } from '../../../entity/customer/customerState';
|
|
10
|
-
import { Entity, EntityType } from '../../../entity/genericEntity/entity';
|
|
11
10
|
import { ProjectBase } from '../../../entity/project/projectState';
|
|
11
|
+
import { Entity, EntityType } from '../../../entity/genericEntity/entity';
|
|
12
12
|
import { TransactionID } from '../../../entity/transaction/stateTypes/transaction';
|
|
13
13
|
import { BillableStatus, CategorizationStatusType, PlatformLineDetailType, ProductOrService, TransactionLineBase } from '../../../entity/transaction/stateTypes/transactionLine';
|
|
14
14
|
import { TransactionCategory, TransactionType } from '../../../entity/transaction/stateTypes/transactionType';
|
|
15
15
|
import { VendorBase } from '../../../entity/vendor/vendorState';
|
|
16
|
-
import { ZeniAPIStatus } from '../../../responsePayload';
|
|
17
16
|
import { ZeniDate } from '../../../zeniDayJS';
|
|
18
17
|
import { EntityRecommendationKey } from '../../recommendation/recommendationState';
|
|
19
18
|
import { TransactionDetailKey } from '../../transactionDetail/transactionDetailState';
|
|
20
|
-
import { CompletedSubTab } from './completedSubTab';
|
|
21
19
|
export declare const toTransactionsSortKey: (v: string) => "date" | "amount" | "vendor" | "project" | "category" | "class" | "payment_account" | "transaction_type" | "memo_and_receipt";
|
|
22
20
|
export type TransactionsSortKey = ReturnType<typeof toTransactionsSortKey>;
|
|
23
21
|
export declare const TRANSACTIONS_TABS: readonly ["review", "autoCategorized"];
|
|
@@ -105,44 +103,7 @@ export interface TransactionsTabViewState extends FetchedState {
|
|
|
105
103
|
selectedTransactionId?: ID;
|
|
106
104
|
selectedTransactionLineId?: ID;
|
|
107
105
|
}
|
|
108
|
-
/**
|
|
109
|
-
* Snapshot of the autoCategorized tab's paginated dataset for a single
|
|
110
|
-
* Completed sub-tab. Stored in {@link TransactionsViewState.autoCategorizedSubTabCache}
|
|
111
|
-
* so revisiting an already-loaded sub-tab can short-circuit the fetch epic
|
|
112
|
-
* (mirrors parent-tab caching). The snapshot is period-spanning — both the
|
|
113
|
-
* `totalCount` map and `transactionIdsBySelectedPeriod` map preserve every
|
|
114
|
-
* period the user has paged through under that sub-tab.
|
|
115
|
-
*
|
|
116
|
-
* `scrollPosition` is captured per sub-tab so revisiting a sub-tab restores
|
|
117
|
-
* the user's last scroll offset; switching to a fresh / never-visited sub-tab
|
|
118
|
-
* starts at the top instead of inheriting the previous sub-tab's offset.
|
|
119
|
-
*/
|
|
120
|
-
export interface AutoCategorizedSubTabSnapshot {
|
|
121
|
-
error: ZeniAPIStatus | undefined;
|
|
122
|
-
fetchState: FetchState;
|
|
123
|
-
pageToken: PageToken;
|
|
124
|
-
scrollPosition: TransactionsViewUIState['scrollPosition'];
|
|
125
|
-
totalCount: Record<MonthYearPeriodId, number>;
|
|
126
|
-
transactionIdsBySelectedPeriod: Record<MonthYearPeriodId, ID[]>;
|
|
127
|
-
}
|
|
128
106
|
export type TransactionsViewState = {
|
|
129
|
-
/**
|
|
130
|
-
* Per-sub-tab snapshot cache for the Completed (autoCategorized) tab. Keyed
|
|
131
|
-
* by {@link CompletedSubTab}. Populated as the user navigates between
|
|
132
|
-
* sub-tabs and consulted on every switch — the active autoCategorized slot
|
|
133
|
-
* is restored from here when a snapshot exists, otherwise it is reset and
|
|
134
|
-
* the fetch epic loads page 1 fresh.
|
|
135
|
-
*/
|
|
136
|
-
autoCategorizedSubTabCache: Partial<Record<CompletedSubTab, AutoCategorizedSubTabSnapshot>>;
|
|
137
|
-
/**
|
|
138
|
-
* Period-keyed parent tab counts, scoped per {@link TransactionsTab}.
|
|
139
|
-
* Sourced from the listing response's `parent_tab_total_count` and used
|
|
140
|
-
* exclusively to drive the parent tab badges on the UI — every other
|
|
141
|
-
* count consumer (pagination, sub-tab chips, in-tab "showing X of Y")
|
|
142
|
-
* keeps reading from {@link TransactionsViewUIState.totalCount}.
|
|
143
|
-
*/
|
|
144
|
-
parentTotalCountByTab: Record<TransactionsTab, Record<MonthYearPeriodId, number>>;
|
|
145
|
-
selectedTransactionCategorizationCompletedSubTab: CompletedSubTab;
|
|
146
107
|
selectedTransactionCategorizationTab: TransactionsTab;
|
|
147
108
|
transactionCategorizationView: Record<TransactionsTab, TransactionsTabViewState>;
|
|
148
109
|
};
|
|
@@ -5,7 +5,6 @@ const toolkit_1 = require("@reduxjs/toolkit");
|
|
|
5
5
|
const coaBalanceType_1 = require("../../commonStateTypes/coaBalance/coaBalanceType");
|
|
6
6
|
const coaBalancesFilter_1 = require("../../commonStateTypes/coaBalance/coaBalancesFilter");
|
|
7
7
|
const coaBalancesFilterClassesView_1 = require("../../commonStateTypes/coaBalance/coaBalancesFilterClassesView");
|
|
8
|
-
const coaBalancesFilterProjectView_1 = require("../../commonStateTypes/coaBalance/coaBalancesFilterProjectView");
|
|
9
8
|
const dataAvailable_1 = require("../../commonStateTypes/dataAvailable");
|
|
10
9
|
const reduceFetchState_1 = require("../../commonStateTypes/reduceFetchState");
|
|
11
10
|
const timeframeTick_1 = require("../../commonStateTypes/timeframeTick");
|
|
@@ -13,6 +12,7 @@ const thisPeriodHelpers_1 = require("../../commonStateTypes/viewAndReport/thisPe
|
|
|
13
12
|
const balanceSheetSelector_1 = require("../balanceSheet/balanceSheetSelector");
|
|
14
13
|
const cashFlowSelector_1 = require("../cashFlow/cashFlowSelector");
|
|
15
14
|
const profitAndLossSelector_1 = require("../profitAndLoss/profitAndLossSelector");
|
|
15
|
+
const coaBalancesFilterProjectView_1 = require("../../commonStateTypes/coaBalance/coaBalancesFilterProjectView");
|
|
16
16
|
const profitAndLossClassesByClassHorizontalSelector_1 = require("../profitAndLossClassesView/profitAndLossClassesByClassHorizontalSelector");
|
|
17
17
|
const profitAndLossClassesViewSelector_1 = require("../profitAndLossClassesView/profitAndLossClassesViewSelector");
|
|
18
18
|
const profitAndLossProjectViewSelector_1 = require("../profitAndLossProjectView/profitAndLossProjectViewSelector");
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import { SectionProjectViewReport } from '../../entity/sectionProjectView/sectionProjectViewSelectorTypes';
|
|
1
2
|
import { COABalancesFilterProjectView } from '../../commonStateTypes/coaBalance/coaBalancesFilterProjectView';
|
|
2
3
|
import { ID } from '../../commonStateTypes/common';
|
|
3
4
|
import { DataAvailable } from '../../commonStateTypes/dataAvailable';
|
|
4
5
|
import { CalculatedSection } from '../../commonStateTypes/selectorTypes/selectorTypes';
|
|
5
6
|
import { SelectorReport } from '../../commonStateTypes/viewAndReport/viewAndReport';
|
|
6
7
|
import { Project } from '../../entity/project/projectState';
|
|
7
|
-
import { SectionProjectViewReport } from '../../entity/sectionProjectView/sectionProjectViewSelectorTypes';
|
|
8
8
|
import { PandLReportViewCalculatedSectionID, PandLReportViewSectionID } from '../profitAndLossClassesView/profitAndLossClassesViewSelectorTypes';
|
|
9
9
|
import { ProfitAndLossProjectViewUIState } from './profitAndLossProjectViewState';
|
|
10
10
|
export interface ProfitAndLossProjectViewReport extends SelectorReport {
|
|
@@ -2,9 +2,7 @@ import { ZeniAPIStatus } from '../../../../responsePayload';
|
|
|
2
2
|
import { ChargeCardCashbackPayload } from './cashbackDetailPayload';
|
|
3
3
|
import { CashbackDetailState, CashbackDetailUIState } from './cashbackDetailState';
|
|
4
4
|
export declare const initialState: CashbackDetailState;
|
|
5
|
-
export declare const fetchCashbackDetail: import("@reduxjs/toolkit").
|
|
6
|
-
cacheOverride: boolean;
|
|
7
|
-
}, "cashbackDetail/fetchCashbackDetail", never, never>, updateCashbackDetail: import("@reduxjs/toolkit").ActionCreatorWithPayload<ChargeCardCashbackPayload, "cashbackDetail/updateCashbackDetail">, updateCashbackDetailFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "cashbackDetail/updateCashbackDetailFailure">, updateCashbackDetailUIState: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
5
|
+
export declare const fetchCashbackDetail: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"cashbackDetail/fetchCashbackDetail">, updateCashbackDetail: import("@reduxjs/toolkit").ActionCreatorWithPayload<ChargeCardCashbackPayload, "cashbackDetail/updateCashbackDetail">, updateCashbackDetailFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "cashbackDetail/updateCashbackDetailFailure">, updateCashbackDetailUIState: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
8
6
|
uiState: Partial<CashbackDetailUIState>;
|
|
9
7
|
}, "cashbackDetail/updateCashbackDetailUIState">, clearCashbackDetail: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"cashbackDetail/clearCashbackDetail">;
|
|
10
8
|
declare const _default: import("redux").Reducer<CashbackDetailState>;
|
|
@@ -5,7 +5,6 @@ exports.clearCashbackDetail = exports.updateCashbackDetailUIState = exports.upda
|
|
|
5
5
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
6
6
|
const viewAndReportPayloadv2_1 = require("../../../../commonPayloadTypes/v2/viewAndReportPayloadv2");
|
|
7
7
|
const amount_1 = require("../../../../commonStateTypes/amount");
|
|
8
|
-
const cacheOverrideFetchReducer_1 = require("../../../../commonStateTypes/cacheOverrideFetchReducer");
|
|
9
8
|
const cashbackDetailState_1 = require("./cashbackDetailState");
|
|
10
9
|
exports.initialState = {
|
|
11
10
|
fetchState: 'Not-Started',
|
|
@@ -32,10 +31,10 @@ const cashbackDetail = (0, toolkit_1.createSlice)({
|
|
|
32
31
|
name: 'cashbackDetail',
|
|
33
32
|
initialState: exports.initialState,
|
|
34
33
|
reducers: {
|
|
35
|
-
fetchCashbackDetail
|
|
34
|
+
fetchCashbackDetail(draft) {
|
|
36
35
|
draft.fetchState = 'In-Progress';
|
|
37
36
|
draft.error = undefined;
|
|
38
|
-
}
|
|
37
|
+
},
|
|
39
38
|
updateCashbackDetail(draft, action) {
|
|
40
39
|
draft.cashbackByPeriod = toCashbackByPeriod(action.payload);
|
|
41
40
|
draft.cashbackSummary = toCashbackSummary(action.payload);
|
|
@@ -2,8 +2,6 @@ import { ZeniAPIStatus } from '../../../../responsePayload';
|
|
|
2
2
|
import { ChargeCardConfigPayload } from './chargeCardConfigPayload';
|
|
3
3
|
import { ChargeCardConfigState } from './chargeCardConfigState';
|
|
4
4
|
export declare const initialState: ChargeCardConfigState;
|
|
5
|
-
export declare const fetchChargeCardConfig: import("@reduxjs/toolkit").
|
|
6
|
-
cacheOverride: boolean;
|
|
7
|
-
}, "chargeCardConfig/fetchChargeCardConfig", never, never>, updateChargeCardConfig: import("@reduxjs/toolkit").ActionCreatorWithPayload<ChargeCardConfigPayload, "chargeCardConfig/updateChargeCardConfig">, updateChargeCardConfigFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardConfig/updateChargeCardConfigFailure">, clearChargeCardConfig: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardConfig/clearChargeCardConfig">;
|
|
5
|
+
export declare const fetchChargeCardConfig: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardConfig/fetchChargeCardConfig">, updateChargeCardConfig: import("@reduxjs/toolkit").ActionCreatorWithPayload<ChargeCardConfigPayload, "chargeCardConfig/updateChargeCardConfig">, updateChargeCardConfigFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardConfig/updateChargeCardConfigFailure">, clearChargeCardConfig: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardConfig/clearChargeCardConfig">;
|
|
8
6
|
declare const _default: import("redux").Reducer<ChargeCardConfigState>;
|
|
9
7
|
export default _default;
|
|
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.clearChargeCardConfig = exports.updateChargeCardConfigFailure = exports.updateChargeCardConfig = exports.fetchChargeCardConfig = exports.initialState = void 0;
|
|
5
5
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
6
6
|
const amount_1 = require("../../../../commonStateTypes/amount");
|
|
7
|
-
const cacheOverrideFetchReducer_1 = require("../../../../commonStateTypes/cacheOverrideFetchReducer");
|
|
8
7
|
const chargeCard_1 = require("../../../../entity/chargeCard/chargeCard");
|
|
9
8
|
const chargeCardConfigPayload_1 = require("./chargeCardConfigPayload");
|
|
10
9
|
exports.initialState = {
|
|
@@ -35,10 +34,10 @@ const chargeCardConfig = (0, toolkit_1.createSlice)({
|
|
|
35
34
|
name: 'chargeCardConfig',
|
|
36
35
|
initialState: exports.initialState,
|
|
37
36
|
reducers: {
|
|
38
|
-
fetchChargeCardConfig
|
|
37
|
+
fetchChargeCardConfig(draft) {
|
|
39
38
|
draft.fetchState = 'In-Progress';
|
|
40
39
|
draft.error = undefined;
|
|
41
|
-
}
|
|
40
|
+
},
|
|
42
41
|
updateChargeCardConfig(draft, action) {
|
|
43
42
|
const { payload } = action;
|
|
44
43
|
draft.creditLimitFrequency =
|
|
@@ -4,7 +4,6 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
4
4
|
exports.clearChargeCardDetail = exports.verifyOtpCardHolderFailure = exports.verifyOtpCardHolderSuccess = exports.verifyOtpCardHolder = exports.sendOtpCardHolderFailure = exports.sendOtpCardHolderSuccess = exports.resendOtpCardHolder = exports.sendOtpCardHolder = exports.updateChargeCardsRecurringExpensesFetchState = exports.updateChargeCardsRecurringExpenses = exports.fetchChargeCardsRecurringExpenses = exports.updateChargeCardTransactionStatisticsFetchState = exports.updateChargeCardTransactionStatistics = exports.fetchChargeCardTransactionStatistics = exports.updateDepositAccountLimitFetchStatus = exports.fetchDepositAccountLimit = exports.closeChargeCardSuccessOrFailure = exports.closeChargeCard = exports.unlockChargeCardSuccessOrFailure = exports.unlockChargeCard = exports.lockChargeCardSuccessOrFailure = exports.lockChargeCard = exports.updateChargeCardNameSuccessOrFailure = exports.updateChargeCardName = exports.updateChargeCardSpendLimitSuccessOrFailure = exports.updateChargeCardSpendLimit = exports.updateChargeCardDetailUpdateStatus = exports.completeDebitCardSetPinWait = exports.startDebitCardSetPinWait = exports.completeCVVActivationWait = exports.startCVVActivationWait = exports.updateChargeCardDetail = exports.updateChargeCardTransactionListFailure = exports.updateChargeCardTransactionAttachmentsInCardDetail = exports.updateChargeCardTransactionReceiptsShowTickFetchStatus = exports.updateDebitCardPinAttemptSuccessOrFailure = exports.updateDebitCardPinAttempt = exports.updatePhysicalChargeCardAttempt = exports.updatePhysicalChargeCardAttemptSuccessOrFailure = exports.updateChargeCardTransactionAttachmentsFailure = exports.updateChargeCardTransactionIsViewReceiptClicked = exports.fetchChargeCardTransactionAttachments = exports.updateChargeCardTransactionUploadReceiptsFetchStatus = exports.updateChargeCardTransactionList = exports.updateChargeCardDetailUIState = exports.fetchChargeCardTransactionList = exports.updateChargeCardDetailFetchState = exports.fetchChargeCardDetail = exports.fetchChargeCardDetailPage = exports.initialState = void 0;
|
|
5
5
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
6
6
|
const sortOrderPayload_1 = require("../../../../commonPayloadTypes/sortOrderPayload");
|
|
7
|
-
const pusherActions_1 = require("../../../../commonStateTypes/pusherActions");
|
|
8
7
|
const attachmentPayload_1 = require("../../../../entity/transaction/payloadTypes/attachmentPayload");
|
|
9
8
|
const chargeCardDetail_1 = require("./chargeCardDetail");
|
|
10
9
|
exports.initialState = {
|
|
@@ -69,30 +68,19 @@ const chargeCardDetail = (0, toolkit_1.createSlice)({
|
|
|
69
68
|
},
|
|
70
69
|
fetchChargeCardTransactionList: {
|
|
71
70
|
reducer(draft, action) {
|
|
72
|
-
const { chargeCardId, pageToken, pageTokenType
|
|
71
|
+
const { chargeCardId, pageToken, pageTokenType } = action.payload;
|
|
73
72
|
const existingCardDetail = draft.detailById[chargeCardId] ?? chargeCardDetail_1.emptyChargeCardDetail;
|
|
74
|
-
const existingUi = existingCardDetail.transactionList.uiState;
|
|
75
|
-
// cacheOverride=true (Pusher): preserve fetchState, error, and scroll
|
|
76
|
-
// to avoid skeleton flash. Normal fetches reset as before.
|
|
77
73
|
draft.detailById[chargeCardId] = {
|
|
78
74
|
...existingCardDetail,
|
|
79
75
|
transactionList: {
|
|
80
76
|
...existingCardDetail.transactionList,
|
|
81
|
-
fetchState:
|
|
82
|
-
|
|
83
|
-
: 'In-Progress',
|
|
84
|
-
error: cacheOverride
|
|
85
|
-
? existingCardDetail.transactionList.error
|
|
86
|
-
: undefined,
|
|
77
|
+
fetchState: 'In-Progress',
|
|
78
|
+
error: undefined,
|
|
87
79
|
uiState: {
|
|
88
|
-
...
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
? existingUi.scrollYOffset
|
|
93
|
-
: existingUi.pageToken === null
|
|
94
|
-
? 0
|
|
95
|
-
: existingUi.scrollYOffset,
|
|
80
|
+
...existingCardDetail.transactionList.uiState,
|
|
81
|
+
scrollYOffset: existingCardDetail.transactionList.uiState.pageToken === null
|
|
82
|
+
? 0
|
|
83
|
+
: existingCardDetail.transactionList.uiState.scrollYOffset,
|
|
96
84
|
pageToken: pageToken,
|
|
97
85
|
pageTokenType: pageTokenType,
|
|
98
86
|
},
|
|
@@ -109,24 +97,18 @@ const chargeCardDetail = (0, toolkit_1.createSlice)({
|
|
|
109
97
|
const { chargeCardId, data, cacheOverride } = action.payload;
|
|
110
98
|
const existingCardDetail = draft.detailById[chargeCardId] ?? chargeCardDetail_1.emptyChargeCardDetail;
|
|
111
99
|
const newTransactionIds = data.transactions.map((tran) => tran.transaction_id);
|
|
112
|
-
const existingIds = existingCardDetail.transactionList.transactionIds;
|
|
113
|
-
// cacheOverride (Pusher): refresh page 1 but keep page 2+ IDs.
|
|
114
|
-
// Normal pagination: append new page, deduped.
|
|
115
|
-
const newIdSet = new Set(newTransactionIds);
|
|
116
|
-
const mergedTransactionIds = cacheOverride
|
|
117
|
-
? [
|
|
118
|
-
...newTransactionIds,
|
|
119
|
-
...existingIds.filter((id) => !newIdSet.has(id)),
|
|
120
|
-
]
|
|
121
|
-
: [
|
|
122
|
-
...existingIds,
|
|
123
|
-
...newTransactionIds.filter((id) => !existingIds.includes(id)),
|
|
124
|
-
];
|
|
125
100
|
draft.detailById[chargeCardId] = {
|
|
126
101
|
...existingCardDetail,
|
|
127
102
|
transactionList: {
|
|
128
103
|
...existingCardDetail.transactionList,
|
|
129
|
-
transactionIds:
|
|
104
|
+
transactionIds: [
|
|
105
|
+
...new Set([
|
|
106
|
+
...(cacheOverride
|
|
107
|
+
? []
|
|
108
|
+
: existingCardDetail.transactionList.transactionIds),
|
|
109
|
+
...newTransactionIds,
|
|
110
|
+
]),
|
|
111
|
+
],
|
|
130
112
|
fetchState: 'Completed',
|
|
131
113
|
error: undefined,
|
|
132
114
|
uiState: {
|
|
@@ -138,12 +120,9 @@ const chargeCardDetail = (0, toolkit_1.createSlice)({
|
|
|
138
120
|
limit: data.query.limit,
|
|
139
121
|
pageToken: data.query.page_token,
|
|
140
122
|
pageTokenType: data.query.page_token_type,
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
: existingCardDetail.transactionList.uiState.pageToken === null
|
|
145
|
-
? 0
|
|
146
|
-
: existingCardDetail.transactionList.uiState.scrollYOffset,
|
|
123
|
+
scrollYOffset: existingCardDetail.transactionList.uiState.pageToken === null
|
|
124
|
+
? 0
|
|
125
|
+
: existingCardDetail.transactionList.uiState.scrollYOffset,
|
|
147
126
|
},
|
|
148
127
|
},
|
|
149
128
|
};
|
|
@@ -657,22 +636,6 @@ const chargeCardDetail = (0, toolkit_1.createSlice)({
|
|
|
657
636
|
Object.assign(draft, exports.initialState);
|
|
658
637
|
},
|
|
659
638
|
},
|
|
660
|
-
extraReducers: (builder) => {
|
|
661
|
-
const prependTransaction = (draft, cardId, txId) => {
|
|
662
|
-
const detail = draft.detailById[cardId];
|
|
663
|
-
if (detail != null &&
|
|
664
|
-
!detail.transactionList.transactionIds.includes(txId)) {
|
|
665
|
-
detail.transactionList.transactionIds.unshift(txId);
|
|
666
|
-
}
|
|
667
|
-
};
|
|
668
|
-
builder
|
|
669
|
-
.addCase(pusherActions_1.addChargeCardTransactionFromPusher, (draft, action) => {
|
|
670
|
-
prependTransaction(draft, action.payload.cardId, action.payload.transaction.transaction_id);
|
|
671
|
-
})
|
|
672
|
-
.addCase(pusherActions_1.addDeclinedChargeCardTransactionFromPusher, (draft, action) => {
|
|
673
|
-
prependTransaction(draft, action.payload.cardId, action.payload.transaction.transaction_id);
|
|
674
|
-
});
|
|
675
|
-
},
|
|
676
639
|
});
|
|
677
640
|
_a = chargeCardDetail.actions, exports.fetchChargeCardDetailPage = _a.fetchChargeCardDetailPage, exports.fetchChargeCardDetail = _a.fetchChargeCardDetail, exports.updateChargeCardDetailFetchState = _a.updateChargeCardDetailFetchState, exports.fetchChargeCardTransactionList = _a.fetchChargeCardTransactionList, exports.updateChargeCardDetailUIState = _a.updateChargeCardDetailUIState, exports.updateChargeCardTransactionList = _a.updateChargeCardTransactionList, exports.updateChargeCardTransactionUploadReceiptsFetchStatus = _a.updateChargeCardTransactionUploadReceiptsFetchStatus, exports.fetchChargeCardTransactionAttachments = _a.fetchChargeCardTransactionAttachments, exports.updateChargeCardTransactionIsViewReceiptClicked = _a.updateChargeCardTransactionIsViewReceiptClicked, exports.updateChargeCardTransactionAttachmentsFailure = _a.updateChargeCardTransactionAttachmentsFailure, exports.updatePhysicalChargeCardAttemptSuccessOrFailure = _a.updatePhysicalChargeCardAttemptSuccessOrFailure, exports.updatePhysicalChargeCardAttempt = _a.updatePhysicalChargeCardAttempt, exports.updateDebitCardPinAttempt = _a.updateDebitCardPinAttempt, exports.updateDebitCardPinAttemptSuccessOrFailure = _a.updateDebitCardPinAttemptSuccessOrFailure, exports.updateChargeCardTransactionReceiptsShowTickFetchStatus = _a.updateChargeCardTransactionReceiptsShowTickFetchStatus, exports.updateChargeCardTransactionAttachmentsInCardDetail = _a.updateChargeCardTransactionAttachmentsInCardDetail, exports.updateChargeCardTransactionListFailure = _a.updateChargeCardTransactionListFailure, exports.updateChargeCardDetail = _a.updateChargeCardDetail, exports.startCVVActivationWait = _a.startCVVActivationWait, exports.completeCVVActivationWait = _a.completeCVVActivationWait, exports.startDebitCardSetPinWait = _a.startDebitCardSetPinWait, exports.completeDebitCardSetPinWait = _a.completeDebitCardSetPinWait, exports.updateChargeCardDetailUpdateStatus = _a.updateChargeCardDetailUpdateStatus, exports.updateChargeCardSpendLimit = _a.updateChargeCardSpendLimit, exports.updateChargeCardSpendLimitSuccessOrFailure = _a.updateChargeCardSpendLimitSuccessOrFailure, exports.updateChargeCardName = _a.updateChargeCardName, exports.updateChargeCardNameSuccessOrFailure = _a.updateChargeCardNameSuccessOrFailure, exports.lockChargeCard = _a.lockChargeCard, exports.lockChargeCardSuccessOrFailure = _a.lockChargeCardSuccessOrFailure, exports.unlockChargeCard = _a.unlockChargeCard, exports.unlockChargeCardSuccessOrFailure = _a.unlockChargeCardSuccessOrFailure, exports.closeChargeCard = _a.closeChargeCard, exports.closeChargeCardSuccessOrFailure = _a.closeChargeCardSuccessOrFailure, exports.fetchDepositAccountLimit = _a.fetchDepositAccountLimit, exports.updateDepositAccountLimitFetchStatus = _a.updateDepositAccountLimitFetchStatus, exports.fetchChargeCardTransactionStatistics = _a.fetchChargeCardTransactionStatistics, exports.updateChargeCardTransactionStatistics = _a.updateChargeCardTransactionStatistics, exports.updateChargeCardTransactionStatisticsFetchState = _a.updateChargeCardTransactionStatisticsFetchState, exports.fetchChargeCardsRecurringExpenses = _a.fetchChargeCardsRecurringExpenses, exports.updateChargeCardsRecurringExpenses = _a.updateChargeCardsRecurringExpenses, exports.updateChargeCardsRecurringExpensesFetchState = _a.updateChargeCardsRecurringExpensesFetchState, exports.sendOtpCardHolder = _a.sendOtpCardHolder, exports.resendOtpCardHolder = _a.resendOtpCardHolder, exports.sendOtpCardHolderSuccess = _a.sendOtpCardHolderSuccess, exports.sendOtpCardHolderFailure = _a.sendOtpCardHolderFailure, exports.verifyOtpCardHolder = _a.verifyOtpCardHolder, exports.verifyOtpCardHolderSuccess = _a.verifyOtpCardHolderSuccess, exports.verifyOtpCardHolderFailure = _a.verifyOtpCardHolderFailure, exports.clearChargeCardDetail = _a.clearChargeCardDetail;
|
|
678
641
|
exports.default = chargeCardDetail.reducer;
|
|
@@ -19,24 +19,13 @@ const fetchChargeCardDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((
|
|
|
19
19
|
const chargeCardAction = [];
|
|
20
20
|
const state = state$.value;
|
|
21
21
|
const chargeCardDetail = (0, get_1.default)(state.chargeCardDetailState.detailById, chargeCardId, undefined);
|
|
22
|
-
// Skip if a user-triggered fetch is already in-flight (not applicable
|
|
23
|
-
// to cacheOverride/Pusher refreshes, which always proceed).
|
|
24
22
|
if (cacheOverride === true ||
|
|
25
23
|
chargeCardDetail == null ||
|
|
26
24
|
chargeCardDetail.fetchState !== 'In-Progress') {
|
|
27
|
-
// Silent refresh: preserve fetchState to avoid skeleton flash.
|
|
28
|
-
// Discriminate via fetchState (not null-check) because the reducer
|
|
29
|
-
// always creates an entry before the epic runs.
|
|
30
|
-
const isSilentRefresh = cacheOverride === true &&
|
|
31
|
-
chargeCardDetail != null &&
|
|
32
|
-
chargeCardDetail.fetchState !== 'Not-Started';
|
|
33
25
|
chargeCardAction.push((0, chargeCardDetailReducer_1.updateChargeCardDetailFetchState)({
|
|
34
26
|
chargeCardId,
|
|
35
|
-
isRefreshingViewInBackground:
|
|
36
|
-
fetchState:
|
|
37
|
-
? chargeCardDetail.fetchState
|
|
38
|
-
: 'In-Progress',
|
|
39
|
-
error: isSilentRefresh ? chargeCardDetail.error : undefined,
|
|
27
|
+
isRefreshingViewInBackground: cacheOverride,
|
|
28
|
+
fetchState: 'In-Progress',
|
|
40
29
|
}));
|
|
41
30
|
const query = {
|
|
42
31
|
is_include_card_activation_events: true,
|
|
@@ -54,8 +43,6 @@ const fetchChargeCardDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((
|
|
|
54
43
|
}));
|
|
55
44
|
}
|
|
56
45
|
else {
|
|
57
|
-
// Surface errors even on silent refresh so the user
|
|
58
|
-
// knows data is stale (follow-up: consider toast instead).
|
|
59
46
|
return (0, rxjs_1.of)((0, chargeCardDetailReducer_1.updateChargeCardDetailFetchState)({
|
|
60
47
|
chargeCardId,
|
|
61
48
|
fetchState: 'Error',
|
|
@@ -64,7 +51,6 @@ const fetchChargeCardDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((
|
|
|
64
51
|
}));
|
|
65
52
|
}
|
|
66
53
|
}), (0, operators_1.catchError)((error) => {
|
|
67
|
-
// Surface network failures even on silent refresh.
|
|
68
54
|
return (0, rxjs_1.of)((0, chargeCardDetailReducer_1.updateChargeCardDetailFetchState)({
|
|
69
55
|
chargeCardId,
|
|
70
56
|
fetchState: 'Error',
|
package/lib/view/spendManagement/chargeCards/chargeCardDetail/fetchChargeCardDetailPageEpic.js
CHANGED
|
@@ -18,16 +18,15 @@ const fetchChargeCardDetailPageEpic = (actions$, state$) => actions$.pipe((0, op
|
|
|
18
18
|
? exsitingChargeCardDetail.transactionList.uiState.pageTokenType
|
|
19
19
|
: null;
|
|
20
20
|
if (cacheOverride === true) {
|
|
21
|
-
// Forward cacheOverride to all sub-fetches to prevent skeleton flash.
|
|
22
21
|
chargeCardTransactionListAction.push((0, chargeCardDetailReducer_1.fetchChargeCardDetail)(chargeCardId, cacheOverride));
|
|
23
22
|
//latest transactions need to be fetched hence removing pageToken and pageTokenType
|
|
24
|
-
chargeCardTransactionListAction.push((0, chargeCardDetailReducer_1.fetchChargeCardTransactionList)(chargeCardId, null, null
|
|
25
|
-
chargeCardTransactionListAction.push((0, chargeCardConfigReducer_1.fetchChargeCardConfig)(
|
|
23
|
+
chargeCardTransactionListAction.push((0, chargeCardDetailReducer_1.fetchChargeCardTransactionList)(chargeCardId, null, null));
|
|
24
|
+
chargeCardTransactionListAction.push((0, chargeCardConfigReducer_1.fetchChargeCardConfig)());
|
|
26
25
|
if (doFetchCreditAccounts && isCreditCardEnabled) {
|
|
27
|
-
chargeCardTransactionListAction.push((0, chargeCardListReducer_1.fetchCreditAccount)(
|
|
26
|
+
chargeCardTransactionListAction.push((0, chargeCardListReducer_1.fetchCreditAccount)());
|
|
28
27
|
}
|
|
29
28
|
if (doFetchCreditAccounts && isCreditCardEnabled) {
|
|
30
|
-
chargeCardTransactionListAction.push((0, chargeCardListReducer_1.fetchCreditAccountRepayment)(
|
|
29
|
+
chargeCardTransactionListAction.push((0, chargeCardListReducer_1.fetchCreditAccountRepayment)());
|
|
31
30
|
}
|
|
32
31
|
}
|
|
33
32
|
else {
|
|
@@ -10,30 +10,15 @@ export declare const fetchChargeCardListPage: import("@reduxjs/toolkit").ActionC
|
|
|
10
10
|
isDebitCardEnabled: boolean;
|
|
11
11
|
isCreditCardEnabled: boolean;
|
|
12
12
|
cacheOverride: any;
|
|
13
|
-
}, "chargeCardList/fetchChargeCardListPage", never, never>, fetchCreditAccountRepayment: import("@reduxjs/toolkit").
|
|
14
|
-
cacheOverride: boolean;
|
|
15
|
-
}, "chargeCardList/fetchCreditAccountRepayment", never, never>, updateCreditAccountRepayment: import("@reduxjs/toolkit").ActionCreatorWithPayload<CreditAccountRepaymentPayload, "chargeCardList/updateCreditAccountRepayment">, updateCreditAccountRepaymentFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateCreditAccountRepaymentFailure">, updateCreditAccountRepaymentAmountAndDate: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
13
|
+
}, "chargeCardList/fetchChargeCardListPage", never, never>, fetchCreditAccountRepayment: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/fetchCreditAccountRepayment">, updateCreditAccountRepayment: import("@reduxjs/toolkit").ActionCreatorWithPayload<CreditAccountRepaymentPayload, "chargeCardList/updateCreditAccountRepayment">, updateCreditAccountRepaymentFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateCreditAccountRepaymentFailure">, updateCreditAccountRepaymentAmountAndDate: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
16
14
|
amount: Amount;
|
|
17
15
|
date: ZeniDate;
|
|
18
|
-
}, "chargeCardList/updateCreditAccountRepaymentAmountAndDate">, updateRowActionCardId: import("@reduxjs/toolkit").ActionCreatorWithOptionalPayload<string | undefined, "chargeCardList/updateRowActionCardId">, fetchCreditAccount: import("@reduxjs/toolkit").
|
|
19
|
-
cacheOverride: boolean;
|
|
20
|
-
}, "chargeCardList/fetchCreditAccount", never, never>, updateCreditAccount: import("@reduxjs/toolkit").ActionCreatorWithPayload<CreditAccountPayload[], "chargeCardList/updateCreditAccount">, updateCreditAccountFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateCreditAccountFailure">, fetchDebitCardSummary: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[cacheOverride?: boolean | undefined], {
|
|
21
|
-
cacheOverride: boolean;
|
|
22
|
-
}, "chargeCardList/fetchDebitCardSummary", never, never>, updateDebitCardSummary: import("@reduxjs/toolkit").ActionCreatorWithPayload<DebitCardSummariesPayload, "chargeCardList/updateDebitCardSummary">, updateDebitCardSummaryFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateDebitCardSummaryFailure">, fetchChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[cacheOverride?: boolean | undefined], {
|
|
23
|
-
cacheOverride: boolean;
|
|
24
|
-
}, "chargeCardList/fetchChargeCardList", never, never>, updateChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
16
|
+
}, "chargeCardList/updateCreditAccountRepaymentAmountAndDate">, updateRowActionCardId: import("@reduxjs/toolkit").ActionCreatorWithOptionalPayload<string | undefined, "chargeCardList/updateRowActionCardId">, fetchCreditAccount: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/fetchCreditAccount">, updateCreditAccount: import("@reduxjs/toolkit").ActionCreatorWithPayload<CreditAccountPayload[], "chargeCardList/updateCreditAccount">, updateCreditAccountFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateCreditAccountFailure">, fetchDebitCardSummary: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/fetchDebitCardSummary">, updateDebitCardSummary: import("@reduxjs/toolkit").ActionCreatorWithPayload<DebitCardSummariesPayload, "chargeCardList/updateDebitCardSummary">, updateDebitCardSummaryFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateDebitCardSummaryFailure">, fetchChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/fetchChargeCardList">, updateChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
25
17
|
chargeCardListPayload: ChargeCardListPayload;
|
|
26
18
|
keepExistingListItems?: boolean;
|
|
27
19
|
}, "chargeCardList/updateChargeCardList">, updateChargeCardListFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<ZeniAPIStatus<Record<string, unknown>>, "chargeCardList/updateChargeCardListFailure">, updateSearchText: import("@reduxjs/toolkit").ActionCreatorWithPayload<string, "chargeCardList/updateSearchText">, updateBulkActionCardIds: import("@reduxjs/toolkit").ActionCreatorWithPayload<string[], "chargeCardList/updateBulkActionCardIds">, updateChargeCardListUIState: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
28
20
|
uiState: Partial<ChargeCardListUIState>;
|
|
29
|
-
}, "chargeCardList/updateChargeCardListUIState">,
|
|
30
|
-
currencyCode: string;
|
|
31
|
-
currencySymbol: string;
|
|
32
|
-
available?: number;
|
|
33
|
-
balance?: number;
|
|
34
|
-
cashback?: number;
|
|
35
|
-
hold?: number;
|
|
36
|
-
}, "chargeCardList/updateCreditAccountBalanceFromPusher">, clearChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/clearChargeCardList">, resendCardInvite: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[cardId: string], {
|
|
21
|
+
}, "chargeCardList/updateChargeCardListUIState">, clearChargeCardList: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<"chargeCardList/clearChargeCardList">, resendCardInvite: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[cardId: string], {
|
|
37
22
|
cardId: string;
|
|
38
23
|
}, "chargeCardList/resendCardInvite", never, never>, resendCardInviteSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
|
|
39
24
|
cardId: ID;
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var _a;
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.revokeChargeCardsInviteSuccessOrFailure = exports.revokeChargeCardsInvite = exports.closeChargeCardsSuccessOrFailure = exports.closeChargeCards = exports.unlockChargeCardsSuccessOrFailure = exports.unlockChargeCards = exports.lockChargeCardsSuccessOrFailure = exports.lockChargeCards = exports.updateChargeCardsSpendLimitSuccessOrFailure = exports.updateChargeCardsSpendLimit = exports.revokeCardInviteFailure = exports.revokeCardInviteSuccess = exports.revokeCardInvite = exports.resendCardInviteFailure = exports.resendCardInviteSuccess = exports.resendCardInvite = exports.clearChargeCardList = exports.
|
|
4
|
+
exports.revokeChargeCardsInviteSuccessOrFailure = exports.revokeChargeCardsInvite = exports.closeChargeCardsSuccessOrFailure = exports.closeChargeCards = exports.unlockChargeCardsSuccessOrFailure = exports.unlockChargeCards = exports.lockChargeCardsSuccessOrFailure = exports.lockChargeCards = exports.updateChargeCardsSpendLimitSuccessOrFailure = exports.updateChargeCardsSpendLimit = exports.revokeCardInviteFailure = exports.revokeCardInviteSuccess = exports.revokeCardInvite = exports.resendCardInviteFailure = exports.resendCardInviteSuccess = exports.resendCardInvite = exports.clearChargeCardList = exports.updateChargeCardListUIState = exports.updateBulkActionCardIds = exports.updateSearchText = exports.updateChargeCardListFailure = exports.updateChargeCardList = exports.fetchChargeCardList = exports.updateDebitCardSummaryFailure = exports.updateDebitCardSummary = exports.fetchDebitCardSummary = exports.updateCreditAccountFailure = exports.updateCreditAccount = exports.fetchCreditAccount = exports.updateRowActionCardId = exports.updateCreditAccountRepaymentAmountAndDate = exports.updateCreditAccountRepaymentFailure = exports.updateCreditAccountRepayment = exports.fetchCreditAccountRepayment = exports.fetchChargeCardListPage = exports.initialState = void 0;
|
|
5
5
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
6
6
|
const amount_1 = require("../../../../commonStateTypes/amount");
|
|
7
|
-
const cacheOverrideFetchReducer_1 = require("../../../../commonStateTypes/cacheOverrideFetchReducer");
|
|
8
7
|
const zeniDayJS_1 = require("../../../../zeniDayJS");
|
|
9
8
|
const chargeCardList_1 = require("./chargeCardList");
|
|
10
9
|
exports.initialState = {
|
|
@@ -48,10 +47,6 @@ exports.initialState = {
|
|
|
48
47
|
revokeCardInvite: chargeCardList_1.initialResendRevokeCardInvite,
|
|
49
48
|
creditAccountRepayment: chargeCardList_1.initialCreditAccountRepayment,
|
|
50
49
|
};
|
|
51
|
-
// Silent-Pusher-refresh contract: when cacheOverride=true, fetch reducers
|
|
52
|
-
// leave fetchState and error unchanged so the list page's reduceFetchState
|
|
53
|
-
// selector stays 'Completed' and doesn't flash ChargeCardListLoading.
|
|
54
|
-
// See createCacheOverrideFetchReducer for details.
|
|
55
50
|
const chargeCardList = (0, toolkit_1.createSlice)({
|
|
56
51
|
name: 'chargeCardList',
|
|
57
52
|
initialState: exports.initialState,
|
|
@@ -71,10 +66,10 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
71
66
|
};
|
|
72
67
|
},
|
|
73
68
|
},
|
|
74
|
-
fetchCreditAccountRepayment
|
|
69
|
+
fetchCreditAccountRepayment(draft) {
|
|
75
70
|
draft.creditAccountRepayment.fetchState = 'In-Progress';
|
|
76
71
|
draft.creditAccountRepayment.error = undefined;
|
|
77
|
-
}
|
|
72
|
+
},
|
|
78
73
|
updateCreditAccountRepaymentAmountAndDate(draft, action) {
|
|
79
74
|
draft.creditAccountRepayment.initiatedRepayments = action.payload.amount;
|
|
80
75
|
draft.creditAccountRepayment.initiatedRepaymentDate = action.payload.date;
|
|
@@ -92,10 +87,10 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
92
87
|
updateRowActionCardId(draft, action) {
|
|
93
88
|
draft.rowActionCardId = action.payload;
|
|
94
89
|
},
|
|
95
|
-
fetchCreditAccount
|
|
90
|
+
fetchCreditAccount(draft) {
|
|
96
91
|
draft.creditAccount.fetchState = 'In-Progress';
|
|
97
92
|
draft.creditAccount.error = undefined;
|
|
98
|
-
}
|
|
93
|
+
},
|
|
99
94
|
updateCreditAccount(draft, action) {
|
|
100
95
|
if (action.payload.length > 0) {
|
|
101
96
|
draft.creditAccount = toCreditAccount(action.payload[0]);
|
|
@@ -108,10 +103,10 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
108
103
|
error: action.payload,
|
|
109
104
|
};
|
|
110
105
|
},
|
|
111
|
-
fetchDebitCardSummary
|
|
106
|
+
fetchDebitCardSummary(draft) {
|
|
112
107
|
draft.debitCardSummaries.fetchState = 'In-Progress';
|
|
113
108
|
draft.debitCardSummaries.error = undefined;
|
|
114
|
-
}
|
|
109
|
+
},
|
|
115
110
|
updateDebitCardSummary(draft, action) {
|
|
116
111
|
draft.debitCardSummaries = toDebitCardSummaries(action.payload);
|
|
117
112
|
},
|
|
@@ -122,10 +117,10 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
122
117
|
error: action.payload,
|
|
123
118
|
};
|
|
124
119
|
},
|
|
125
|
-
fetchChargeCardList
|
|
120
|
+
fetchChargeCardList(draft) {
|
|
126
121
|
draft.fetchState = 'In-Progress';
|
|
127
122
|
draft.error = undefined;
|
|
128
|
-
}
|
|
123
|
+
},
|
|
129
124
|
updateChargeCardList(draft, action) {
|
|
130
125
|
const { cards, unassigned_credit } = action.payload.chargeCardListPayload;
|
|
131
126
|
const newCard = cards.map((card) => card.card_id);
|
|
@@ -161,18 +156,6 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
161
156
|
draft.uiState.scrollYOffset = action.payload.uiState.scrollYOffset;
|
|
162
157
|
}
|
|
163
158
|
},
|
|
164
|
-
updateCreditAccountBalanceFromPusher(draft, action) {
|
|
165
|
-
const { currencyCode, currencySymbol } = action.payload;
|
|
166
|
-
const amt = (v) => v !== undefined ? (0, amount_1.toAmount)(v, currencyCode, currencySymbol) : undefined;
|
|
167
|
-
draft.creditAccount.available =
|
|
168
|
-
amt(action.payload.available) ?? draft.creditAccount.available;
|
|
169
|
-
draft.creditAccount.balance =
|
|
170
|
-
amt(action.payload.balance) ?? draft.creditAccount.balance;
|
|
171
|
-
draft.creditAccount.hold =
|
|
172
|
-
amt(action.payload.hold) ?? draft.creditAccount.hold;
|
|
173
|
-
draft.creditAccount.cashback =
|
|
174
|
-
amt(action.payload.cashback) ?? draft.creditAccount.cashback;
|
|
175
|
-
},
|
|
176
159
|
clearChargeCardList(draft) {
|
|
177
160
|
Object.assign(draft, exports.initialState);
|
|
178
161
|
},
|
|
@@ -328,7 +311,7 @@ const chargeCardList = (0, toolkit_1.createSlice)({
|
|
|
328
311
|
},
|
|
329
312
|
},
|
|
330
313
|
});
|
|
331
|
-
_a = chargeCardList.actions, exports.fetchChargeCardListPage = _a.fetchChargeCardListPage, exports.fetchCreditAccountRepayment = _a.fetchCreditAccountRepayment, exports.updateCreditAccountRepayment = _a.updateCreditAccountRepayment, exports.updateCreditAccountRepaymentFailure = _a.updateCreditAccountRepaymentFailure, exports.updateCreditAccountRepaymentAmountAndDate = _a.updateCreditAccountRepaymentAmountAndDate, exports.updateRowActionCardId = _a.updateRowActionCardId, exports.fetchCreditAccount = _a.fetchCreditAccount, exports.updateCreditAccount = _a.updateCreditAccount, exports.updateCreditAccountFailure = _a.updateCreditAccountFailure, exports.fetchDebitCardSummary = _a.fetchDebitCardSummary, exports.updateDebitCardSummary = _a.updateDebitCardSummary, exports.updateDebitCardSummaryFailure = _a.updateDebitCardSummaryFailure, exports.fetchChargeCardList = _a.fetchChargeCardList, exports.updateChargeCardList = _a.updateChargeCardList, exports.updateChargeCardListFailure = _a.updateChargeCardListFailure, exports.updateSearchText = _a.updateSearchText, exports.updateBulkActionCardIds = _a.updateBulkActionCardIds, exports.updateChargeCardListUIState = _a.updateChargeCardListUIState, exports.
|
|
314
|
+
_a = chargeCardList.actions, exports.fetchChargeCardListPage = _a.fetchChargeCardListPage, exports.fetchCreditAccountRepayment = _a.fetchCreditAccountRepayment, exports.updateCreditAccountRepayment = _a.updateCreditAccountRepayment, exports.updateCreditAccountRepaymentFailure = _a.updateCreditAccountRepaymentFailure, exports.updateCreditAccountRepaymentAmountAndDate = _a.updateCreditAccountRepaymentAmountAndDate, exports.updateRowActionCardId = _a.updateRowActionCardId, exports.fetchCreditAccount = _a.fetchCreditAccount, exports.updateCreditAccount = _a.updateCreditAccount, exports.updateCreditAccountFailure = _a.updateCreditAccountFailure, exports.fetchDebitCardSummary = _a.fetchDebitCardSummary, exports.updateDebitCardSummary = _a.updateDebitCardSummary, exports.updateDebitCardSummaryFailure = _a.updateDebitCardSummaryFailure, exports.fetchChargeCardList = _a.fetchChargeCardList, exports.updateChargeCardList = _a.updateChargeCardList, exports.updateChargeCardListFailure = _a.updateChargeCardListFailure, exports.updateSearchText = _a.updateSearchText, exports.updateBulkActionCardIds = _a.updateBulkActionCardIds, exports.updateChargeCardListUIState = _a.updateChargeCardListUIState, exports.clearChargeCardList = _a.clearChargeCardList, exports.resendCardInvite = _a.resendCardInvite, exports.resendCardInviteSuccess = _a.resendCardInviteSuccess, exports.resendCardInviteFailure = _a.resendCardInviteFailure, exports.revokeCardInvite = _a.revokeCardInvite, exports.revokeCardInviteSuccess = _a.revokeCardInviteSuccess, exports.revokeCardInviteFailure = _a.revokeCardInviteFailure, exports.updateChargeCardsSpendLimit = _a.updateChargeCardsSpendLimit, exports.updateChargeCardsSpendLimitSuccessOrFailure = _a.updateChargeCardsSpendLimitSuccessOrFailure, exports.lockChargeCards = _a.lockChargeCards, exports.lockChargeCardsSuccessOrFailure = _a.lockChargeCardsSuccessOrFailure, exports.unlockChargeCards = _a.unlockChargeCards, exports.unlockChargeCardsSuccessOrFailure = _a.unlockChargeCardsSuccessOrFailure, exports.closeChargeCards = _a.closeChargeCards, exports.closeChargeCardsSuccessOrFailure = _a.closeChargeCardsSuccessOrFailure, exports.revokeChargeCardsInvite = _a.revokeChargeCardsInvite, exports.revokeChargeCardsInviteSuccessOrFailure = _a.revokeChargeCardsInviteSuccessOrFailure;
|
|
332
315
|
exports.default = chargeCardList.reducer;
|
|
333
316
|
// helper
|
|
334
317
|
const toCreditAccount = (payload) => ({
|