@zeniai/client-epic-state 5.2.24 → 5.2.26-betaAK0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/epic.d.ts +2 -1
- package/lib/epic.js +2 -0
- package/lib/esm/epic.js +2 -0
- package/lib/esm/index.js +2 -2
- package/lib/esm/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +45 -7
- package/lib/esm/view/expenseAutomationView/epics/jeSchedule/oneTimeAccrualActionsEpic.js +13 -6
- package/lib/esm/view/expenseAutomationView/epics/jeSchedule/prefetchOtherJeSchedulesTabEpic.js +35 -0
- package/lib/esm/view/expenseAutomationView/payload/jeSchedulesPayload.js +1 -1
- package/lib/esm/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +31 -7
- package/lib/esm/view/expenseAutomationView/selectors/jeSchedulesViewSelector.js +1 -0
- package/lib/esm/view/invoicing/couponView/couponViewState.js +4 -4
- package/lib/esm/view/invoicing/invoicingCatalogListView/invoicingCatalogListViewSelector.js +1 -0
- package/lib/esm/view/invoicing/invoicingCustomerListView/invoicingCustomerListViewState.js +3 -3
- package/lib/esm/view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewState.js +4 -4
- package/lib/index.d.ts +2 -2
- package/lib/index.js +20 -18
- package/lib/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.d.ts +1 -1
- package/lib/view/expenseAutomationView/epics/jeSchedule/fetchJeSchedulesEpic.js +45 -7
- package/lib/view/expenseAutomationView/epics/jeSchedule/oneTimeAccrualActionsEpic.d.ts +2 -2
- package/lib/view/expenseAutomationView/epics/jeSchedule/oneTimeAccrualActionsEpic.js +12 -5
- package/lib/view/expenseAutomationView/epics/jeSchedule/prefetchOtherJeSchedulesTabEpic.d.ts +12 -0
- package/lib/view/expenseAutomationView/epics/jeSchedule/prefetchOtherJeSchedulesTabEpic.js +39 -0
- package/lib/view/expenseAutomationView/payload/jeSchedulesPayload.d.ts +54 -1
- package/lib/view/expenseAutomationView/payload/jeSchedulesPayload.js +3 -3
- package/lib/view/expenseAutomationView/reducers/jeSchedulesViewReducer.d.ts +11 -6
- package/lib/view/expenseAutomationView/reducers/jeSchedulesViewReducer.js +33 -9
- package/lib/view/expenseAutomationView/selectors/jeSchedulesViewSelector.d.ts +2 -0
- package/lib/view/expenseAutomationView/selectors/jeSchedulesViewSelector.js +1 -0
- package/lib/view/expenseAutomationView/types/jeSchedulesViewState.d.ts +2 -0
- package/lib/view/invoicing/couponView/couponViewState.d.ts +2 -2
- package/lib/view/invoicing/couponView/couponViewState.js +4 -4
- package/lib/view/invoicing/invoicingCatalogListView/invoicingCatalogListViewSelector.d.ts +1 -0
- package/lib/view/invoicing/invoicingCatalogListView/invoicingCatalogListViewSelector.js +1 -0
- package/lib/view/invoicing/invoicingCustomerListView/invoicingCustomerListViewState.d.ts +2 -2
- package/lib/view/invoicing/invoicingCustomerListView/invoicingCustomerListViewState.js +3 -3
- package/lib/view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewState.d.ts +2 -2
- package/lib/view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewState.js +4 -4
- package/package.json +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var _a;
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
-
exports.
|
|
5
|
-
exports.updateRecommendationForAccountSettingsFailure = exports.updateRecommendationForAccountSettings = exports.updateNewScheduleLocalData = exports.updateJeScheduleTransactionKeys = exports.updateJeScheduleLocalDataById = exports.updateJEScheduleTypeFilter = exports.updateJESchedulesUIState = exports.updateAccountSettingsListForAccountTypesFailure = exports.updateAccountSettingsListForAccountTypes = exports.toggleJEPendingGroupCollapsed = exports.toggleJECreatedGroupCollapsed = exports.searchTransactionsForNewScheduleSuccess = exports.searchTransactionsForNewScheduleFailure = exports.searchTransactionsForNewSchedule = void 0;
|
|
4
|
+
exports.saveNewScheduleFailure = exports.saveNewSchedule = exports.saveAccountSettingsSuccess = exports.saveAccountSettingsLocalData = exports.saveAccountSettingsFailure = exports.saveAccountSettings = exports.retryJeScheduleSuccess = exports.retryJeScheduleFailure = exports.retryJeSchedule = exports.resetNewScheduleLocalData = exports.removeJeScheduleTransactionKey = exports.removeJeAccruedScheduleKey = exports.removeJeScheduleLocalDataById = exports.removeJeOneTimeAccrualLocalData = exports.removeFailedJeScheduleTransactionKey = exports.initializeNewSchedule = exports.initializeJeScheduleLocalData = exports.initializeAccountSettingsView = exports.ignoreRecommendedJeScheduleSuccess = exports.ignoreRecommendedJeScheduleFailure = exports.ignoreRecommendedJeSchedule = exports.fetchRecommendationForAccountSettings = exports.fetchOneTimeAccrualSuccess = exports.fetchOneTimeAccrualFailure = exports.fetchOneTimeAccrual = exports.fetchJeSchedulesSuccess = exports.fetchJeSchedulesPage = exports.fetchJeSchedulesFailure = exports.fetchJeSchedules = exports.fetchAccountSettingsListForAccountTypes = exports.revertOneTimeAccrual = exports.revertJeScheduleSuccess = exports.revertJeScheduleFailure = exports.revertJeSchedule = exports.promoteOneTimeAccrual = exports.oneTimeAccrualActionSuccess = exports.oneTimeAccrualActionFailure = exports.ignoreOneTimeAccrual = exports.createOneTimeAccrualSuccess = exports.createOneTimeAccrualFailure = exports.createOneTimeAccrual = exports.clearSearchTransactionsForNewSchedule = exports.clearJeScheduleLocalData = exports.clearJeAccountSettingsLocalData = exports.clearExpenseAutomationJESchedulesView = exports.initialState = exports.searchTransactionsInitialState = exports.newScheduleInitialState = exports.getBaseNewScheduleLocalData = exports.accountSettingsInitialState = void 0;
|
|
5
|
+
exports.updateRecommendationForAccountSettingsFailure = exports.updateRecommendationForAccountSettings = exports.updateNewScheduleLocalData = exports.updateJeScheduleTransactionKeys = exports.updateJeScheduleLocalDataById = exports.updateJeOneTimeAccrualLocalData = exports.updateJEScheduleTypeFilter = exports.updateJESchedulesUIState = exports.updateAccountSettingsListForAccountTypesFailure = exports.updateAccountSettingsListForAccountTypes = exports.toggleJEPendingGroupCollapsed = exports.toggleJECreatedGroupCollapsed = exports.searchTransactionsForNewScheduleSuccess = exports.searchTransactionsForNewScheduleFailure = exports.searchTransactionsForNewSchedule = exports.saveNewScheduleSuccess = void 0;
|
|
6
6
|
const toolkit_1 = require("@reduxjs/toolkit");
|
|
7
7
|
const getNestedAccountIDHierarchyForReport_1 = require("../../../commonStateTypes/accountView/getNestedAccountIDHierarchyForReport");
|
|
8
8
|
const timePeriod_1 = require("../../../commonStateTypes/timePeriod");
|
|
@@ -72,6 +72,7 @@ exports.initialState = {
|
|
|
72
72
|
ignoreStatusById: {},
|
|
73
73
|
revertStatusById: {},
|
|
74
74
|
jeScheduleLocalDataById: {},
|
|
75
|
+
oneTimeAccrualLocalDataById: {},
|
|
75
76
|
oneTimeAccrualActionStatusById: {},
|
|
76
77
|
oneTimeAccrualFetchStatusById: {},
|
|
77
78
|
uiState: {
|
|
@@ -133,11 +134,15 @@ const expenseAutomationJESchedulesView = (0, toolkit_1.createSlice)({
|
|
|
133
134
|
draft.error = undefined;
|
|
134
135
|
}
|
|
135
136
|
},
|
|
136
|
-
|
|
137
|
+
// `selectedPageTab` is for the prefetch, which fetches the tab the user is NOT on. Everyone
|
|
138
|
+
// else omits it and the epic uses the selected tab -- passing the visible tab explicitly
|
|
139
|
+
// would be the same thing.
|
|
140
|
+
prepare(period, refreshViewInBackground = false, selectedPageTab) {
|
|
137
141
|
return {
|
|
138
142
|
payload: {
|
|
139
143
|
period,
|
|
140
144
|
refreshViewInBackground,
|
|
145
|
+
selectedPageTab,
|
|
141
146
|
},
|
|
142
147
|
};
|
|
143
148
|
},
|
|
@@ -405,6 +410,24 @@ const expenseAutomationJESchedulesView = (0, toolkit_1.createSlice)({
|
|
|
405
410
|
const { scheduledJournalEntryID } = action.payload;
|
|
406
411
|
delete draft.jeScheduleLocalDataById[scheduledJournalEntryID];
|
|
407
412
|
},
|
|
413
|
+
/**
|
|
414
|
+
* Merge, not replace: the detail form reports one field at a time, so a full overwrite would
|
|
415
|
+
* drop every other edit on each keystroke.
|
|
416
|
+
*/
|
|
417
|
+
updateJeOneTimeAccrualLocalData(draft, action) {
|
|
418
|
+
const { accrualId, localData } = action.payload;
|
|
419
|
+
draft.oneTimeAccrualLocalDataById = {
|
|
420
|
+
...draft.oneTimeAccrualLocalDataById,
|
|
421
|
+
[accrualId]: {
|
|
422
|
+
...draft.oneTimeAccrualLocalDataById[accrualId],
|
|
423
|
+
...localData,
|
|
424
|
+
},
|
|
425
|
+
};
|
|
426
|
+
},
|
|
427
|
+
/** Called when the detail page unmounts and after a successful promote. */
|
|
428
|
+
removeJeOneTimeAccrualLocalData(draft, action) {
|
|
429
|
+
delete draft.oneTimeAccrualLocalDataById[action.payload.accrualId];
|
|
430
|
+
},
|
|
408
431
|
initializeAccountSettingsView(draft) {
|
|
409
432
|
draft.accountSettings.localData = exports.accountSettingsInitialState.localData;
|
|
410
433
|
},
|
|
@@ -581,13 +604,14 @@ const expenseAutomationJESchedulesView = (0, toolkit_1.createSlice)({
|
|
|
581
604
|
};
|
|
582
605
|
},
|
|
583
606
|
/**
|
|
584
|
-
* Promote applies the body and posts in one step
|
|
585
|
-
*
|
|
586
|
-
*
|
|
607
|
+
* Promote applies the body and posts in one step. The edits it applies come from
|
|
608
|
+
* `oneTimeAccrualLocalDataById`, not from this action -- the list's inline Post has no form, so
|
|
609
|
+
* it writes no local data and the epic falls back to the stored accrual. `amount` stays on the
|
|
610
|
+
* action because both callers already have it and `OneTimeAccrualEdits` has no slot for it.
|
|
587
611
|
*/
|
|
588
612
|
promoteOneTimeAccrual: {
|
|
589
|
-
prepare(accrualId, amount
|
|
590
|
-
return { payload: { accrualId, amount
|
|
613
|
+
prepare(accrualId, amount) {
|
|
614
|
+
return { payload: { accrualId, amount } };
|
|
591
615
|
},
|
|
592
616
|
reducer(draft, action) {
|
|
593
617
|
draft.oneTimeAccrualActionStatusById[action.payload.accrualId] = {
|
|
@@ -691,7 +715,7 @@ const expenseAutomationJESchedulesView = (0, toolkit_1.createSlice)({
|
|
|
691
715
|
});
|
|
692
716
|
},
|
|
693
717
|
});
|
|
694
|
-
_a = expenseAutomationJESchedulesView.actions, exports.clearExpenseAutomationJESchedulesView = _a.clearExpenseAutomationJESchedulesView, exports.clearJeAccountSettingsLocalData = _a.clearJeAccountSettingsLocalData, exports.clearJeScheduleLocalData = _a.clearJeScheduleLocalData, exports.clearSearchTransactionsForNewSchedule = _a.clearSearchTransactionsForNewSchedule, exports.createOneTimeAccrual = _a.createOneTimeAccrual, exports.createOneTimeAccrualFailure = _a.createOneTimeAccrualFailure, exports.createOneTimeAccrualSuccess = _a.createOneTimeAccrualSuccess, exports.ignoreOneTimeAccrual = _a.ignoreOneTimeAccrual, exports.oneTimeAccrualActionFailure = _a.oneTimeAccrualActionFailure, exports.oneTimeAccrualActionSuccess = _a.oneTimeAccrualActionSuccess, exports.promoteOneTimeAccrual = _a.promoteOneTimeAccrual, exports.revertJeSchedule = _a.revertJeSchedule, exports.revertJeScheduleFailure = _a.revertJeScheduleFailure, exports.revertJeScheduleSuccess = _a.revertJeScheduleSuccess, exports.revertOneTimeAccrual = _a.revertOneTimeAccrual, exports.fetchAccountSettingsListForAccountTypes = _a.fetchAccountSettingsListForAccountTypes, exports.fetchJeSchedules = _a.fetchJeSchedules, exports.fetchJeSchedulesFailure = _a.fetchJeSchedulesFailure, exports.fetchJeSchedulesPage = _a.fetchJeSchedulesPage, exports.fetchJeSchedulesSuccess = _a.fetchJeSchedulesSuccess, exports.fetchOneTimeAccrual = _a.fetchOneTimeAccrual, exports.fetchOneTimeAccrualFailure = _a.fetchOneTimeAccrualFailure, exports.fetchOneTimeAccrualSuccess = _a.fetchOneTimeAccrualSuccess, exports.fetchRecommendationForAccountSettings = _a.fetchRecommendationForAccountSettings, exports.ignoreRecommendedJeSchedule = _a.ignoreRecommendedJeSchedule, exports.ignoreRecommendedJeScheduleFailure = _a.ignoreRecommendedJeScheduleFailure, exports.ignoreRecommendedJeScheduleSuccess = _a.ignoreRecommendedJeScheduleSuccess, exports.initializeAccountSettingsView = _a.initializeAccountSettingsView, exports.initializeJeScheduleLocalData = _a.initializeJeScheduleLocalData, exports.initializeNewSchedule = _a.initializeNewSchedule, exports.removeFailedJeScheduleTransactionKey = _a.removeFailedJeScheduleTransactionKey, exports.removeJeScheduleLocalDataById = _a.removeJeScheduleLocalDataById, exports.removeJeAccruedScheduleKey = _a.removeJeAccruedScheduleKey, exports.removeJeScheduleTransactionKey = _a.removeJeScheduleTransactionKey, exports.resetNewScheduleLocalData = _a.resetNewScheduleLocalData, exports.retryJeSchedule = _a.retryJeSchedule, exports.retryJeScheduleFailure = _a.retryJeScheduleFailure, exports.retryJeScheduleSuccess = _a.retryJeScheduleSuccess, exports.saveAccountSettings = _a.saveAccountSettings, exports.saveAccountSettingsFailure = _a.saveAccountSettingsFailure, exports.saveAccountSettingsLocalData = _a.saveAccountSettingsLocalData, exports.saveAccountSettingsSuccess = _a.saveAccountSettingsSuccess, exports.saveNewSchedule = _a.saveNewSchedule, exports.saveNewScheduleFailure = _a.saveNewScheduleFailure, exports.saveNewScheduleSuccess = _a.saveNewScheduleSuccess, exports.searchTransactionsForNewSchedule = _a.searchTransactionsForNewSchedule, exports.searchTransactionsForNewScheduleFailure = _a.searchTransactionsForNewScheduleFailure, exports.searchTransactionsForNewScheduleSuccess = _a.searchTransactionsForNewScheduleSuccess, exports.toggleJECreatedGroupCollapsed = _a.toggleJECreatedGroupCollapsed, exports.toggleJEPendingGroupCollapsed = _a.toggleJEPendingGroupCollapsed, exports.updateAccountSettingsListForAccountTypes = _a.updateAccountSettingsListForAccountTypes, exports.updateAccountSettingsListForAccountTypesFailure = _a.updateAccountSettingsListForAccountTypesFailure, exports.updateJESchedulesUIState = _a.updateJESchedulesUIState, exports.updateJEScheduleTypeFilter = _a.updateJEScheduleTypeFilter, exports.updateJeScheduleLocalDataById = _a.updateJeScheduleLocalDataById, exports.updateJeScheduleTransactionKeys = _a.updateJeScheduleTransactionKeys, exports.updateNewScheduleLocalData = _a.updateNewScheduleLocalData, exports.updateRecommendationForAccountSettings = _a.updateRecommendationForAccountSettings, exports.updateRecommendationForAccountSettingsFailure = _a.updateRecommendationForAccountSettingsFailure;
|
|
718
|
+
_a = expenseAutomationJESchedulesView.actions, exports.clearExpenseAutomationJESchedulesView = _a.clearExpenseAutomationJESchedulesView, exports.clearJeAccountSettingsLocalData = _a.clearJeAccountSettingsLocalData, exports.clearJeScheduleLocalData = _a.clearJeScheduleLocalData, exports.clearSearchTransactionsForNewSchedule = _a.clearSearchTransactionsForNewSchedule, exports.createOneTimeAccrual = _a.createOneTimeAccrual, exports.createOneTimeAccrualFailure = _a.createOneTimeAccrualFailure, exports.createOneTimeAccrualSuccess = _a.createOneTimeAccrualSuccess, exports.ignoreOneTimeAccrual = _a.ignoreOneTimeAccrual, exports.oneTimeAccrualActionFailure = _a.oneTimeAccrualActionFailure, exports.oneTimeAccrualActionSuccess = _a.oneTimeAccrualActionSuccess, exports.promoteOneTimeAccrual = _a.promoteOneTimeAccrual, exports.revertJeSchedule = _a.revertJeSchedule, exports.revertJeScheduleFailure = _a.revertJeScheduleFailure, exports.revertJeScheduleSuccess = _a.revertJeScheduleSuccess, exports.revertOneTimeAccrual = _a.revertOneTimeAccrual, exports.fetchAccountSettingsListForAccountTypes = _a.fetchAccountSettingsListForAccountTypes, exports.fetchJeSchedules = _a.fetchJeSchedules, exports.fetchJeSchedulesFailure = _a.fetchJeSchedulesFailure, exports.fetchJeSchedulesPage = _a.fetchJeSchedulesPage, exports.fetchJeSchedulesSuccess = _a.fetchJeSchedulesSuccess, exports.fetchOneTimeAccrual = _a.fetchOneTimeAccrual, exports.fetchOneTimeAccrualFailure = _a.fetchOneTimeAccrualFailure, exports.fetchOneTimeAccrualSuccess = _a.fetchOneTimeAccrualSuccess, exports.fetchRecommendationForAccountSettings = _a.fetchRecommendationForAccountSettings, exports.ignoreRecommendedJeSchedule = _a.ignoreRecommendedJeSchedule, exports.ignoreRecommendedJeScheduleFailure = _a.ignoreRecommendedJeScheduleFailure, exports.ignoreRecommendedJeScheduleSuccess = _a.ignoreRecommendedJeScheduleSuccess, exports.initializeAccountSettingsView = _a.initializeAccountSettingsView, exports.initializeJeScheduleLocalData = _a.initializeJeScheduleLocalData, exports.initializeNewSchedule = _a.initializeNewSchedule, exports.removeFailedJeScheduleTransactionKey = _a.removeFailedJeScheduleTransactionKey, exports.removeJeOneTimeAccrualLocalData = _a.removeJeOneTimeAccrualLocalData, exports.removeJeScheduleLocalDataById = _a.removeJeScheduleLocalDataById, exports.removeJeAccruedScheduleKey = _a.removeJeAccruedScheduleKey, exports.removeJeScheduleTransactionKey = _a.removeJeScheduleTransactionKey, exports.resetNewScheduleLocalData = _a.resetNewScheduleLocalData, exports.retryJeSchedule = _a.retryJeSchedule, exports.retryJeScheduleFailure = _a.retryJeScheduleFailure, exports.retryJeScheduleSuccess = _a.retryJeScheduleSuccess, exports.saveAccountSettings = _a.saveAccountSettings, exports.saveAccountSettingsFailure = _a.saveAccountSettingsFailure, exports.saveAccountSettingsLocalData = _a.saveAccountSettingsLocalData, exports.saveAccountSettingsSuccess = _a.saveAccountSettingsSuccess, exports.saveNewSchedule = _a.saveNewSchedule, exports.saveNewScheduleFailure = _a.saveNewScheduleFailure, exports.saveNewScheduleSuccess = _a.saveNewScheduleSuccess, exports.searchTransactionsForNewSchedule = _a.searchTransactionsForNewSchedule, exports.searchTransactionsForNewScheduleFailure = _a.searchTransactionsForNewScheduleFailure, exports.searchTransactionsForNewScheduleSuccess = _a.searchTransactionsForNewScheduleSuccess, exports.toggleJECreatedGroupCollapsed = _a.toggleJECreatedGroupCollapsed, exports.toggleJEPendingGroupCollapsed = _a.toggleJEPendingGroupCollapsed, exports.updateAccountSettingsListForAccountTypes = _a.updateAccountSettingsListForAccountTypes, exports.updateAccountSettingsListForAccountTypesFailure = _a.updateAccountSettingsListForAccountTypesFailure, exports.updateJESchedulesUIState = _a.updateJESchedulesUIState, exports.updateJEScheduleTypeFilter = _a.updateJEScheduleTypeFilter, exports.updateJeOneTimeAccrualLocalData = _a.updateJeOneTimeAccrualLocalData, exports.updateJeScheduleLocalDataById = _a.updateJeScheduleLocalDataById, exports.updateJeScheduleTransactionKeys = _a.updateJeScheduleTransactionKeys, exports.updateNewScheduleLocalData = _a.updateNewScheduleLocalData, exports.updateRecommendationForAccountSettings = _a.updateRecommendationForAccountSettings, exports.updateRecommendationForAccountSettingsFailure = _a.updateRecommendationForAccountSettingsFailure;
|
|
695
719
|
exports.default = expenseAutomationJESchedulesView.reducer;
|
|
696
720
|
const doUpdateRecommendationForAccountSettings = (draft, payload) => {
|
|
697
721
|
const { prepaidExpensesRecommendations, fixedAssetsRecommendations, accruedExpensesRecommendations, } = (0, accountTypeRecommendationPayload_1.mapAccountTypeRecommendationPayloadToAccountRecommendationByType)(payload);
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { FetchStateAndError, ID } from '../../../commonStateTypes/common';
|
|
2
2
|
import { JEAccruedSchedule, JEOneTimeAccrual } from '../../../entity/jeSchedules/jeSchedulesSelector';
|
|
3
|
+
import { OneTimeAccrualEdits } from '../../../entity/jeSchedules/jeSchedulesState';
|
|
3
4
|
import { ScheduleTypes } from '../../../entity/jeSchedules/jeSchedulesTypes';
|
|
4
5
|
import { RootState } from '../../../rootStateTypes';
|
|
5
6
|
import { ExpenseAutomationJESchedulesViewSelector, JEScheduleRow } from '../selectorTypes/jeSchedulesSelectorTypes';
|
|
@@ -22,6 +23,7 @@ export interface ExpenseAutomationJEOneTimeAccrualDetailView {
|
|
|
22
23
|
actionFetchState: FetchStateAndError;
|
|
23
24
|
detailFetchState: FetchStateAndError;
|
|
24
25
|
accrual?: JEOneTimeAccrual;
|
|
26
|
+
localData?: OneTimeAccrualEdits;
|
|
25
27
|
}
|
|
26
28
|
/**
|
|
27
29
|
* One accrual plus the status of its promote / ignore request, for the detail screen.
|
|
@@ -5,6 +5,7 @@ import { Recommendation } from '../../../commonStateTypes/recommendationBase';
|
|
|
5
5
|
import { SortOrder } from '../../../commonStateTypes/selectorTypes/sortOrderTypes';
|
|
6
6
|
import { MonthYearPeriodId, ScheduleDaysOfMonth } from '../../../commonStateTypes/timePeriod';
|
|
7
7
|
import { AccountBase } from '../../../entity/account/accountState';
|
|
8
|
+
import { OneTimeAccrualEdits } from '../../../entity/jeSchedules/jeSchedulesState';
|
|
8
9
|
import { JEOneTimeAccrualKey, JEScheduleKey, JEScheduleTransactionKey, ScheduleJournalEntryStatusCodeType, ScheduleTransactionID, ScheduleTypes } from '../../../entity/jeSchedules/jeSchedulesTypes';
|
|
9
10
|
import { VendorBase } from '../../../entity/vendor/vendorState';
|
|
10
11
|
import { ZeniDate } from '../../../zeniDayJS';
|
|
@@ -51,6 +52,7 @@ export interface JESchedulesViewState extends FetchedState {
|
|
|
51
52
|
newSchedule: NewJeScheduleState;
|
|
52
53
|
oneTimeAccrualActionStatusById: Record<ID, FetchStateAndError>;
|
|
53
54
|
oneTimeAccrualFetchStatusById: Record<ID, FetchStateAndError>;
|
|
55
|
+
oneTimeAccrualLocalDataById: Record<ID, OneTimeAccrualEdits>;
|
|
54
56
|
postStatusById: Record<ID, FetchStateAndError>;
|
|
55
57
|
refreshStatus: FetchStateAndError;
|
|
56
58
|
revertStatusById: Record<JEScheduleKey | JEScheduleTransactionKey, FetchStateAndError>;
|
|
@@ -4,8 +4,8 @@ import { InvoicingListSort } from '../invoicingApiHelper';
|
|
|
4
4
|
export interface InvoicingCouponFilters {
|
|
5
5
|
search?: string;
|
|
6
6
|
}
|
|
7
|
-
export declare const ALL_INVOICING_COUPON_SORT_KEYS: readonly ["
|
|
8
|
-
export declare const toInvoicingCouponSortKey: (v: string) => "
|
|
7
|
+
export declare const ALL_INVOICING_COUPON_SORT_KEYS: readonly ["code", "coupon", "discount", "duration", "created", "valid_till", "apply_on", "status", "redemptions"];
|
|
8
|
+
export declare const toInvoicingCouponSortKey: (v: string) => "code" | "status" | "discount" | "coupon" | "duration" | "created" | "valid_till" | "apply_on" | "redemptions";
|
|
9
9
|
export type InvoicingCouponSortKey = ReturnType<typeof toInvoicingCouponSortKey>;
|
|
10
10
|
/**
|
|
11
11
|
* Structural column descriptor owned by CES so the discounts-list column set,
|
|
@@ -3,8 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.toInvoicingCouponTabId = exports.ALL_INVOICING_COUPON_TAB_IDS = exports.INVOICING_COUPON_COLUMNS = exports.toInvoicingCouponSortKey = exports.ALL_INVOICING_COUPON_SORT_KEYS = void 0;
|
|
4
4
|
const stringToUnion_1 = require("../../../commonStateTypes/stringToUnion");
|
|
5
5
|
exports.ALL_INVOICING_COUPON_SORT_KEYS = [
|
|
6
|
-
'
|
|
7
|
-
'
|
|
6
|
+
'code',
|
|
7
|
+
'coupon',
|
|
8
8
|
'discount',
|
|
9
9
|
'duration',
|
|
10
10
|
'created',
|
|
@@ -16,8 +16,8 @@ exports.ALL_INVOICING_COUPON_SORT_KEYS = [
|
|
|
16
16
|
const toInvoicingCouponSortKey = (v) => (0, stringToUnion_1.stringToUnion)(v, exports.ALL_INVOICING_COUPON_SORT_KEYS);
|
|
17
17
|
exports.toInvoicingCouponSortKey = toInvoicingCouponSortKey;
|
|
18
18
|
exports.INVOICING_COUPON_COLUMNS = [
|
|
19
|
-
{ key: '
|
|
20
|
-
{ key: '
|
|
19
|
+
{ key: 'code', sortable: true },
|
|
20
|
+
{ key: 'coupon', sortable: true },
|
|
21
21
|
{ key: 'discount', sortable: false },
|
|
22
22
|
{ key: 'duration', sortable: true },
|
|
23
23
|
{ key: 'created', sortable: true },
|
|
@@ -19,6 +19,7 @@ export interface InvoicingCatalogListView extends SelectorView {
|
|
|
19
19
|
productFilters: InvoicingCatalogProductFilters;
|
|
20
20
|
productNextCursor: string | null;
|
|
21
21
|
products: InvoicingPlan[];
|
|
22
|
+
planSort?: InvoicingListSort;
|
|
22
23
|
productSort?: InvoicingListSort;
|
|
23
24
|
}
|
|
24
25
|
export declare const getInvoicingCatalogPrices: (items: InvoicingPlan[]) => InvoicingProduct[];
|
|
@@ -29,6 +29,7 @@ exports.getInvoicingCatalogListView = (0, toolkit_1.createSelector)((state) => s
|
|
|
29
29
|
countsFetchState: listViewState.countsFetchState,
|
|
30
30
|
planFilters: listViewState.planFilters,
|
|
31
31
|
planNextCursor: listViewState.planNextCursor,
|
|
32
|
+
planSort: listViewState.planSort,
|
|
32
33
|
productFilters: listViewState.productFilters,
|
|
33
34
|
productNextCursor: listViewState.productNextCursor,
|
|
34
35
|
productFetchState: listViewState.productFetchState,
|
|
@@ -4,8 +4,8 @@ import { InvoicingListSort } from '../invoicingApiHelper';
|
|
|
4
4
|
export interface InvoicingCustomerFilters {
|
|
5
5
|
search?: string;
|
|
6
6
|
}
|
|
7
|
-
export declare const ALL_INVOICING_CUSTOMER_SORT_KEYS: readonly ["name", "email", "billingAddress", "
|
|
8
|
-
export declare const toInvoicingCustomerSortKey: (v: string) => "status" | "name" | "
|
|
7
|
+
export declare const ALL_INVOICING_CUSTOMER_SORT_KEYS: readonly ["name", "email", "billingAddress", "card", "autoCollect", "status"];
|
|
8
|
+
export declare const toInvoicingCustomerSortKey: (v: string) => "status" | "name" | "card" | "email" | "billingAddress" | "autoCollect";
|
|
9
9
|
export type InvoicingCustomerSortKey = ReturnType<typeof toInvoicingCustomerSortKey>;
|
|
10
10
|
/**
|
|
11
11
|
* Structural column descriptor owned by CES so the customer-list column set,
|
|
@@ -6,17 +6,17 @@ exports.ALL_INVOICING_CUSTOMER_SORT_KEYS = [
|
|
|
6
6
|
'name',
|
|
7
7
|
'email',
|
|
8
8
|
'billingAddress',
|
|
9
|
-
'
|
|
9
|
+
'card',
|
|
10
10
|
'autoCollect',
|
|
11
11
|
'status',
|
|
12
12
|
];
|
|
13
13
|
const toInvoicingCustomerSortKey = (v) => (0, stringToUnion_1.stringToUnion)(v, exports.ALL_INVOICING_CUSTOMER_SORT_KEYS);
|
|
14
14
|
exports.toInvoicingCustomerSortKey = toInvoicingCustomerSortKey;
|
|
15
15
|
exports.INVOICING_CUSTOMER_COLUMNS = [
|
|
16
|
-
{ key: 'name', sortable:
|
|
16
|
+
{ key: 'name', sortable: false },
|
|
17
17
|
{ key: 'email', sortable: true },
|
|
18
18
|
{ key: 'billingAddress', sortable: false },
|
|
19
|
-
{ key: '
|
|
19
|
+
{ key: 'card', sortable: true },
|
|
20
20
|
{ key: 'autoCollect', sortable: true },
|
|
21
21
|
{ key: 'status', sortable: true },
|
|
22
22
|
];
|
package/lib/view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewState.d.ts
CHANGED
|
@@ -4,8 +4,8 @@ import { InvoicingListSort } from '../invoicingApiHelper';
|
|
|
4
4
|
export interface InvoicingDunningCaseFilters {
|
|
5
5
|
search?: string;
|
|
6
6
|
}
|
|
7
|
-
export declare const ALL_INVOICING_DUNNING_CASE_SORT_KEYS: readonly ["customer", "invoice", "attempts", "
|
|
8
|
-
export declare const toInvoicingDunningCaseSortKey: (v: string) => "status" | "invoice" | "amount" | "customer" | "
|
|
7
|
+
export declare const ALL_INVOICING_DUNNING_CASE_SORT_KEYS: readonly ["customer", "invoice", "attempts", "next_retry", "days_past_due", "failureReason", "status", "amount"];
|
|
8
|
+
export declare const toInvoicingDunningCaseSortKey: (v: string) => "status" | "invoice" | "amount" | "customer" | "attempts" | "next_retry" | "days_past_due" | "failureReason";
|
|
9
9
|
export type InvoicingDunningCaseSortKey = ReturnType<typeof toInvoicingDunningCaseSortKey>;
|
|
10
10
|
/**
|
|
11
11
|
* Structural column descriptor owned by CES so the dunning-list column set,
|
package/lib/view/invoicing/invoicingDunningCaseListView/invoicingDunningCaseListViewState.js
CHANGED
|
@@ -6,8 +6,8 @@ exports.ALL_INVOICING_DUNNING_CASE_SORT_KEYS = [
|
|
|
6
6
|
'customer',
|
|
7
7
|
'invoice',
|
|
8
8
|
'attempts',
|
|
9
|
-
'
|
|
10
|
-
'
|
|
9
|
+
'next_retry',
|
|
10
|
+
'days_past_due',
|
|
11
11
|
'failureReason',
|
|
12
12
|
'status',
|
|
13
13
|
'amount',
|
|
@@ -18,8 +18,8 @@ exports.INVOICING_DUNNING_CASE_COLUMNS = [
|
|
|
18
18
|
{ key: 'customer', sortable: true },
|
|
19
19
|
{ key: 'invoice', sortable: true },
|
|
20
20
|
{ key: 'attempts', sortable: true },
|
|
21
|
-
{ key: '
|
|
22
|
-
{ key: '
|
|
21
|
+
{ key: 'next_retry', sortable: true },
|
|
22
|
+
{ key: 'days_past_due', sortable: true },
|
|
23
23
|
{ key: 'failureReason', sortable: false },
|
|
24
24
|
{ key: 'status', sortable: true },
|
|
25
25
|
{ key: 'amount', sortable: true },
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeniai/client-epic-state",
|
|
3
|
-
"version": "5.2.
|
|
3
|
+
"version": "5.2.26-betaAK0",
|
|
4
4
|
"description": "Shared module between Web & Mobile containing required abstractions for state management, async network communication. ",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "lib/esm/index.js",
|