@zeniai/client-epic-state 5.0.65-betaML1 → 5.0.65-betaML2
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/esm/view/recommendation/fetchEntityRecommendationsForLineUpdateEpic.js +10 -0
- package/lib/esm/view/transactionDetail/transactionDetailReducer.js +16 -0
- package/lib/tsconfig.typecheck.tsbuildinfo +1 -1
- package/lib/view/recommendation/fetchEntityRecommendationsForLineUpdateEpic.js +10 -0
- package/lib/view/transactionDetail/transactionDetailReducer.js +16 -0
- package/package.json +1 -1
|
@@ -45,6 +45,16 @@ const fetchEntityRecommendationsForLineUpdateEpic = (actions$, state$, zeniAPI)
|
|
|
45
45
|
const startAction = flowType === 'categorization' && selectedTab != null
|
|
46
46
|
? (0, transactionsViewReducer_1.markCategoryClassRecommendationsInProgressForCategorization)(selectedTab, transactionId, lineIds)
|
|
47
47
|
: (0, transactionDetailReducer_1.markCategoryClassRecommendationsInProgressForTransactionDetail)(transactionId, lineIds);
|
|
48
|
+
// TEMP-LOG[JE-skeleton]: epic dispatch payload — confirms the
|
|
49
|
+
// targeted-fetch fired with the expected flowType / txnId / lineIds.
|
|
50
|
+
// eslint-disable-next-line no-console
|
|
51
|
+
console.log('[JE-skeleton][epic] dispatch start arm', {
|
|
52
|
+
flowType,
|
|
53
|
+
selectedTab,
|
|
54
|
+
transactionId,
|
|
55
|
+
lineIds,
|
|
56
|
+
transactionType: transaction?.type,
|
|
57
|
+
});
|
|
48
58
|
const url = (0, recommendationHelper_1.buildRecommendationUrl)(zeniAPI.apiEndPoints.accountMicroServiceBaseUrl, entity, amount, transactionDetails, isFetchCOT === true);
|
|
49
59
|
const httpStream$ = zeniAPI
|
|
50
60
|
.getJSON(url)
|
|
@@ -415,6 +415,22 @@ const transactionDetail = (0, toolkit_1.createSlice)({
|
|
|
415
415
|
const { transactionId, lineIds } = action.payload;
|
|
416
416
|
const key = (0, transactionDetailState_1.getTransactionDetailKey)(transactionId);
|
|
417
417
|
const detail = (0, get_1.default)(draft.transactionDetailById, key, undefined);
|
|
418
|
+
// TEMP-LOG[JE-skeleton]: reducer entry — confirms the action reached
|
|
419
|
+
// the slice and shows whether incoming lineIds match the redux keys.
|
|
420
|
+
// eslint-disable-next-line no-console
|
|
421
|
+
console.log('[JE-skeleton][reducer] markInProgress detail', {
|
|
422
|
+
transactionId,
|
|
423
|
+
incomingLineIds: lineIds,
|
|
424
|
+
existingLineItemKeys: detail != null
|
|
425
|
+
? Object.keys(detail.transactionDetailLocalData.lineItemById)
|
|
426
|
+
: null,
|
|
427
|
+
matched: detail != null
|
|
428
|
+
? lineIds.filter((id) => detail.transactionDetailLocalData.lineItemById[id] != null)
|
|
429
|
+
: [],
|
|
430
|
+
missed: detail != null
|
|
431
|
+
? lineIds.filter((id) => detail.transactionDetailLocalData.lineItemById[id] == null)
|
|
432
|
+
: lineIds,
|
|
433
|
+
});
|
|
418
434
|
if (detail != null) {
|
|
419
435
|
lineIds.forEach((lineId) => {
|
|
420
436
|
const lineItem = detail.transactionDetailLocalData.lineItemById[lineId];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeniai/client-epic-state",
|
|
3
|
-
"version": "5.0.65-
|
|
3
|
+
"version": "5.0.65-betaML2",
|
|
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",
|