@zeniai/client-epic-state 4.12.77 → 4.12.78

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.
@@ -3,7 +3,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.vendorFiling1099ListSelectorMock = void 0;
4
4
  const vendorStateMocks_1 = require("../../../entity/vendor/__mocks__/vendorStateMocks");
5
5
  exports.vendorFiling1099ListSelectorMock = {
6
- fetchState: 'Completed',
6
+ fetchState: 'Not-Started',
7
7
  error: undefined,
8
8
  version: 0,
9
9
  vendors: [
@@ -31,16 +31,15 @@ const vendorFiling1099List = (0, toolkit_1.createSlice)({
31
31
  payload: { cacheOverride },
32
32
  };
33
33
  },
34
- reducer() {
35
- // Do nothing
34
+ reducer(draft) {
35
+ draft.fetchState = 'In-Progress';
36
+ draft.error = undefined;
36
37
  },
37
38
  },
38
39
  fetchVendorsFiling1099List: {
39
40
  reducer(draft) {
40
- draft.fetchState = 'In-Progress';
41
41
  // Note: Need to reset scroll position whenever a new fetch happens, except when fetching through scroll
42
42
  draft.uiState = exports.initialState.uiState;
43
- draft.error = undefined;
44
43
  },
45
44
  prepare() {
46
45
  return {
@@ -9,12 +9,21 @@ const orderBy_1 = __importDefault(require("lodash/orderBy"));
9
9
  const reduceFetchState_1 = require("../../../commonStateTypes/reduceFetchState");
10
10
  const getVendorFiling1099List = (state) => {
11
11
  var _a;
12
- const { vendorFiling1099ListState, vendorState, vendorTypeListState } = state;
12
+ const { vendorFiling1099ListState, vendorState, vendorTypeListState, accountMappingState, } = state;
13
13
  const targetIds = vendorFiling1099ListState.vendorIds;
14
- const fetchStatus = (0, reduceFetchState_1.reduceFetchState)([
15
- vendorFiling1099ListState,
16
- vendorTypeListState,
17
- ]);
14
+ const allFetchStates = [
15
+ accountMappingState.accountListFetchState,
16
+ accountMappingState.recommendationFetchState,
17
+ {
18
+ fetchState: vendorFiling1099ListState.fetchState,
19
+ error: vendorFiling1099ListState.error,
20
+ },
21
+ {
22
+ fetchState: vendorTypeListState.fetchState,
23
+ error: vendorTypeListState.error,
24
+ },
25
+ ];
26
+ const fetchStatus = (0, reduceFetchState_1.reduceAllFetchState)(allFetchStates);
18
27
  const vendorTypeList = vendorTypeListState.vendorTypes;
19
28
  const loweredSearchText = vendorFiling1099ListState.uiState.searchString
20
29
  .trim()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeniai/client-epic-state",
3
- "version": "4.12.77",
3
+ "version": "4.12.78",
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
  "types": "lib/index.d.ts",