@zeniai/client-epic-state 4.11.14 → 4.11.16

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.
Files changed (83) hide show
  1. package/lib/entity/snackbar/snackbarTypes.d.ts +1 -1
  2. package/lib/entity/snackbar/snackbarTypes.js +0 -4
  3. package/lib/entity/task/taskPayload.d.ts +2 -2
  4. package/lib/entity/task/taskPayload.js +0 -1
  5. package/lib/entity/task/taskState.d.ts +0 -1
  6. package/lib/entity/tenant/clearAllEpic.d.ts +2 -4
  7. package/lib/entity/tenant/clearAllEpic.js +0 -6
  8. package/lib/entity/toastNotification/epic/pushToastNotificationEpic.d.ts +1 -1
  9. package/lib/entity/transaction/stateTypes/attachment.d.ts +0 -6
  10. package/lib/entity/transaction/stateTypes/transactionType.d.ts +0 -3
  11. package/lib/entity/transaction/stateTypes/transactionType.js +3 -7
  12. package/lib/entity/vendor/vendorPayload.d.ts +0 -2
  13. package/lib/entity/vendor/vendorPayload.js +1 -5
  14. package/lib/entity/vendor/vendorState.d.ts +0 -2
  15. package/lib/epic.d.ts +1 -8
  16. package/lib/epic.js +1 -8
  17. package/lib/index.d.ts +9 -12
  18. package/lib/index.js +3 -13
  19. package/lib/reducer.d.ts +0 -6
  20. package/lib/reducer.js +0 -6
  21. package/lib/view/companyView/selector/companyManagementViewSelector.js +7 -13
  22. package/lib/view/companyView/selector/companyPortfolioViewSelector.js +6 -1
  23. package/lib/view/fileView/fileUploadHelpers.d.ts +0 -5
  24. package/lib/view/people/changeZeniPersonRolesEpic.d.ts +1 -1
  25. package/lib/view/people/deletePersonEpic.d.ts +1 -1
  26. package/lib/view/people/invitePeopleEpic.d.ts +1 -1
  27. package/lib/view/people/inviteZeniPeopleEpic.d.ts +1 -1
  28. package/lib/view/people/resendInviteEpic.d.ts +1 -1
  29. package/lib/view/reviewCompanyView/reviewCompanyViewSelector.js +9 -26
  30. package/lib/view/settingsView/epic/saveNotificationSettingsEpic.d.ts +1 -1
  31. package/lib/view/subscriptionView/subscriptionViewSelector.js +1 -5
  32. package/lib/view/tagView/epics/createTagEpic.d.ts +1 -1
  33. package/lib/view/tagView/epics/deleteTagEpic.d.ts +1 -1
  34. package/lib/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.d.ts +1 -2
  35. package/lib/view/taskManager/taskDetailView/epics/saveTaskDetailEpic.js +4 -11
  36. package/lib/view/taskManager/taskDetailView/taskDetailReducer.d.ts +1 -2
  37. package/lib/view/taskManager/taskDetailView/taskDetailReducer.js +1 -2
  38. package/lib/view/taskManager/taskListView/fetchTaskListPageEpic.d.ts +1 -3
  39. package/lib/view/taskManager/taskListView/fetchTaskListPageEpic.js +0 -12
  40. package/lib/view/taskManager/taskListView/taskList.d.ts +1 -14
  41. package/lib/view/taskManager/taskListView/taskListReducer.d.ts +2 -31
  42. package/lib/view/taskManager/taskListView/taskListReducer.js +9 -136
  43. package/lib/view/taskManager/taskListView/taskListSelector.d.ts +2 -12
  44. package/lib/view/taskManager/taskListView/taskListSelector.js +23 -59
  45. package/lib/view/transactionDetail/epics/updateTransactionDetailEpic.js +5 -22
  46. package/lib/view/vendorReviewView/vendorFirstReviewView/epics/fetchVendorFirstReviewViewEpic.js +0 -1
  47. package/lib/view/vendorReviewView/vendorFirstReviewView/epics/saveVendorFirstReviewViewEpic.js +5 -11
  48. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewPayload.d.ts +0 -15
  49. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewReducer.d.ts +3 -13
  50. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewReducer.js +3 -45
  51. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewSelector.d.ts +0 -8
  52. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewSelector.js +2 -17
  53. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewState.d.ts +2 -6
  54. package/lib/view/vendorReviewView/vendorFirstReviewView/vendorFirstReviewViewState.js +1 -2
  55. package/package.json +1 -1
  56. package/lib/entity/taskGroup/taskGroupPayload.d.ts +0 -9
  57. package/lib/entity/taskGroup/taskGroupPayload.js +0 -14
  58. package/lib/entity/taskGroup/taskGroupReducer.d.ts +0 -6
  59. package/lib/entity/taskGroup/taskGroupReducer.js +0 -33
  60. package/lib/entity/taskGroup/taskGroupSelector.d.ts +0 -4
  61. package/lib/entity/taskGroup/taskGroupSelector.js +0 -18
  62. package/lib/entity/taskGroup/taskGroupState.d.ts +0 -12
  63. package/lib/entity/taskGroup/taskGroupState.js +0 -2
  64. package/lib/view/taskManager/taskGroupView/epics/createNewTaskGroupEpic.d.ts +0 -10
  65. package/lib/view/taskManager/taskGroupView/epics/createNewTaskGroupEpic.js +0 -57
  66. package/lib/view/taskManager/taskGroupView/epics/deleteTaskGroupEpic.d.ts +0 -10
  67. package/lib/view/taskManager/taskGroupView/epics/deleteTaskGroupEpic.js +0 -41
  68. package/lib/view/taskManager/taskGroupView/epics/fetchAllTaskGroupsEpic.d.ts +0 -8
  69. package/lib/view/taskManager/taskGroupView/epics/fetchAllTaskGroupsEpic.js +0 -33
  70. package/lib/view/taskManager/taskGroupView/epics/updateTaskGroupNameEpic.d.ts +0 -10
  71. package/lib/view/taskManager/taskGroupView/epics/updateTaskGroupNameEpic.js +0 -51
  72. package/lib/view/taskManager/taskGroupView/taskGroupViewPayload.d.ts +0 -6
  73. package/lib/view/taskManager/taskGroupView/taskGroupViewPayload.js +0 -2
  74. package/lib/view/taskManager/taskGroupView/taskGroupViewReducer.d.ts +0 -34
  75. package/lib/view/taskManager/taskGroupView/taskGroupViewReducer.js +0 -123
  76. package/lib/view/taskManager/taskGroupView/taskGroupViewState.d.ts +0 -7
  77. package/lib/view/taskManager/taskGroupView/taskGroupViewState.js +0 -2
  78. package/lib/view/taskManager/taskListView/bulkUpdateTaskListEpic.d.ts +0 -8
  79. package/lib/view/taskManager/taskListView/bulkUpdateTaskListEpic.js +0 -88
  80. package/lib/view/taskManager/taskListView/dragNDropTasksEpic.d.ts +0 -6
  81. package/lib/view/taskManager/taskListView/dragNDropTasksEpic.js +0 -20
  82. package/lib/view/vendorReviewView/vendorFirstReviewView/epics/fetchVendorFirstReviewAttachmentsEpic.d.ts +0 -10
  83. package/lib/view/vendorReviewView/vendorFirstReviewView/epics/fetchVendorFirstReviewAttachmentsEpic.js +0 -37
@@ -6,22 +6,20 @@ const operators_1 = require("rxjs/operators");
6
6
  const responsePayload_1 = require("../../../../responsePayload");
7
7
  const taskDetailReducer_1 = require("../taskDetailReducer");
8
8
  const taskReducer_1 = require("../../../../entity/task/taskReducer");
9
- const taskListReducer_1 = require("../../taskListView/taskListReducer");
10
9
  const taskSelector_1 = require("../../../../entity/task/taskSelector");
11
10
  const snackbarReducer_1 = require("../../../../entity/snackbar/snackbarReducer");
12
11
  const formatZeniDateFY_1 = require("../../../../commonStateTypes/fiscalYearHelpers/formatZeniDateFY");
13
12
  const saveTaskDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(taskDetailReducer_1.saveTaskDetail.match), (0, operators_1.mergeMap)((action) => {
14
- const { taskId, taskGroupId } = action.payload;
13
+ const { taskId } = action.payload;
15
14
  const state = state$.value;
16
- const payload = prepareTaskPayload(state, taskId, taskGroupId);
15
+ const payload = prepareTaskPayload(state, taskId);
17
16
  const saveTaskApi = taskId != null
18
17
  ? zeniAPI.putAndGetJSON(`${zeniAPI.apiEndPoints.taskMicroServiceBaseUrl}/1.0/task-manager/tasks/${taskId}`, payload)
19
18
  : zeniAPI.postAndGetJSON(`${zeniAPI.apiEndPoints.taskMicroServiceBaseUrl}/1.0/task-manager/tasks`, payload);
20
19
  return saveTaskApi.pipe((0, operators_1.mergeMap)((response) => {
21
20
  if ((0, responsePayload_1.isSuccessResponse)(response) &&
22
21
  response.data != null &&
23
- response.data.tasks.length > 0 &&
24
- taskGroupId != null) {
22
+ response.data.tasks.length > 0) {
25
23
  const newTaskId = response.data.tasks[0].task_id;
26
24
  const fetchActions = [
27
25
  (0, taskReducer_1.updateTasks)(response.data.tasks),
@@ -30,10 +28,6 @@ const saveTaskDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
30
28
  newTaskId,
31
29
  taskId,
32
30
  }),
33
- (0, taskListReducer_1.updateTaskListOnNewTaskCreationSuccess)({
34
- taskGroupId,
35
- taskId: newTaskId,
36
- }),
37
31
  ];
38
32
  return (0, rxjs_1.from)(fetchActions);
39
33
  }
@@ -64,7 +58,7 @@ const saveTaskDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, oper
64
58
  }))));
65
59
  }));
66
60
  exports.saveTaskDetailEpic = saveTaskDetailEpic;
67
- const prepareTaskPayload = (state, taskId, taskGroupId) => {
61
+ const prepareTaskPayload = (state, taskId) => {
68
62
  var _a, _b, _c, _d, _e, _f, _g, _h;
69
63
  const { taskDetailState, taskState } = state;
70
64
  const syncToken = taskId != null ? (_b = (_a = (0, taskSelector_1.getTaskById)(taskState, taskId)) === null || _a === void 0 ? void 0 : _a.syncToken) !== null && _b !== void 0 ? _b : '' : '';
@@ -90,6 +84,5 @@ const prepareTaskPayload = (state, taskId, taskGroupId) => {
90
84
  ? (_h = (_g = localData.recurringStartDate) === null || _g === void 0 ? void 0 : _g.format(formatZeniDateFY_1.DEFAULT_DATE_FORMAT)) !== null && _h !== void 0 ? _h : null
91
85
  : null,
92
86
  sync_token: syncToken,
93
- task_group_ids: taskGroupId != null ? [taskGroupId] : [],
94
87
  };
95
88
  };
@@ -20,9 +20,8 @@ export declare const fetchTaskDetailPage: import("@reduxjs/toolkit").ActionCreat
20
20
  taskId?: string | undefined;
21
21
  }, string>, discardTaskUpdatesInLocalStore: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
22
22
  taskId?: string | undefined;
23
- }, string>, saveTaskDetail: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[taskId?: string | undefined, taskGroupId?: string | undefined], {
23
+ }, string>, saveTaskDetail: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[taskId?: string | undefined], {
24
24
  taskId: string | undefined;
25
- taskGroupId: string | undefined;
26
25
  }, string, never, never>, archiveTask: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[taskId: string], {
27
26
  taskId: string;
28
27
  }, string, never, never>, archiveTaskSuccessOrFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
@@ -125,11 +125,10 @@ const taskDetailView = (0, toolkit_1.createSlice)({
125
125
  } });
126
126
  }
127
127
  },
128
- prepare(taskId, taskGroupId) {
128
+ prepare(taskId) {
129
129
  return {
130
130
  payload: {
131
131
  taskId,
132
- taskGroupId,
133
132
  },
134
133
  };
135
134
  },
@@ -4,7 +4,5 @@ import { fetchTaskListPage, fetchTaskList } from './taskListReducer';
4
4
  import { RootState } from '../../../reducer';
5
5
  import { fetchUserListByType } from '../../userListView/userListViewReducer';
6
6
  import { fetchClassList } from '../../classList/classListReducer';
7
- import { fetchTagList } from '../../tagView/tagViewReducer';
8
- import { fetchAllTaskGroups } from '../taskGroupView/taskGroupViewReducer';
9
- export declare type ActionType = ReturnType<typeof fetchTaskListPage> | ReturnType<typeof fetchTaskList> | ReturnType<typeof fetchUserListByType> | ReturnType<typeof fetchTagList> | ReturnType<typeof fetchAllTaskGroups> | ReturnType<typeof fetchClassList>;
7
+ export declare type ActionType = ReturnType<typeof fetchTaskListPage> | ReturnType<typeof fetchTaskList> | ReturnType<typeof fetchUserListByType> | ReturnType<typeof fetchClassList>;
10
8
  export declare const fetchTaskListPageEpic: (actions$: ActionsObservable<ActionType>, state$: StateObservable<RootState>) => Observable<ActionType>;
@@ -6,8 +6,6 @@ const operators_1 = require("rxjs/operators");
6
6
  const taskListReducer_1 = require("./taskListReducer");
7
7
  const userListViewReducer_1 = require("../../userListView/userListViewReducer");
8
8
  const classListReducer_1 = require("../../classList/classListReducer");
9
- const tagViewReducer_1 = require("../../tagView/tagViewReducer");
10
- const taskGroupViewReducer_1 = require("../taskGroupView/taskGroupViewReducer");
11
9
  const fetchTaskListPageEpic = (actions$, state$) => actions$.pipe((0, operators_1.filter)(taskListReducer_1.fetchTaskListPage.match), (0, operators_1.mergeMap)((action) => {
12
10
  const { cacheOverride } = action.payload;
13
11
  const taskListPageActions = [];
@@ -16,8 +14,6 @@ const fetchTaskListPageEpic = (actions$, state$) => actions$.pipe((0, operators_
16
14
  taskListPageActions.push((0, taskListReducer_1.fetchTaskList)());
17
15
  taskListPageActions.push((0, classListReducer_1.fetchClassList)());
18
16
  taskListPageActions.push((0, userListViewReducer_1.fetchUserListByType)('taskManagerCandidate', true));
19
- taskListPageActions.push((0, tagViewReducer_1.fetchTagList)());
20
- taskListPageActions.push((0, taskGroupViewReducer_1.fetchAllTaskGroups)());
21
17
  }
22
18
  else {
23
19
  taskListPageActions.push((0, taskListReducer_1.fetchTaskList)());
@@ -30,14 +26,6 @@ const fetchTaskListPageEpic = (actions$, state$) => actions$.pipe((0, operators_
30
26
  taskManageUsers.fetchState !== 'In-Progress') {
31
27
  taskListPageActions.push((0, userListViewReducer_1.fetchUserListByType)('taskManagerCandidate', false));
32
28
  }
33
- if (state.tagViewState.hasValidState() === false &&
34
- state.tagViewState.fetchState !== 'In-Progress') {
35
- taskListPageActions.push((0, tagViewReducer_1.fetchTagList)());
36
- }
37
- if (state.taskGroupViewState.hasValidState() === false &&
38
- state.taskGroupViewState.fetchState !== 'In-Progress') {
39
- taskListPageActions.push((0, taskGroupViewReducer_1.fetchAllTaskGroups)());
40
- }
41
29
  }
42
30
  return (0, rxjs_1.concat)((0, rxjs_1.from)(taskListPageActions));
43
31
  }));
@@ -1,25 +1,12 @@
1
- import { FetchedState, FetchStateAndError, ID } from '../../../commonStateTypes/common';
1
+ import { FetchedState, ID } from '../../../commonStateTypes/common';
2
2
  import { ZeniDate } from '../../../zeniDayJS';
3
3
  import { SpendManagementUIState } from '../../spendManagement/billPay/billList/billListState';
4
4
  import { CategoryCombinationOperator, FilterCategoryType } from '../../spendManagement/spendManagementFilterHelpers';
5
- export interface NewTaskGroupLocalData {
6
- taskIds: ID[];
7
- groupName: string;
8
- }
9
- export interface TaskListLocalData {
10
- newTaskGroupName: string;
11
- selectedTaskIds: ID[];
12
- existingTaskGroupNamesByGroupId: Record<ID, string>;
13
- defaultTaskGroupId: ID | null;
14
- }
15
5
  export interface TaskListState extends FetchedState {
16
6
  taskIds: ID[];
17
- taskIdsByGroupsIds: Record<ID, ID[]>;
18
7
  uiState: TaskListUIState;
19
8
  searchText: string;
20
9
  filters: TaskListFilters;
21
- localData: TaskListLocalData;
22
- updateTasksFetchState: FetchStateAndError;
23
10
  }
24
11
  export interface TaskListFilters {
25
12
  categoryCombinationOperator: CategoryCombinationOperator;
@@ -1,11 +1,7 @@
1
- import { FetchState, ID, UpdateType } from '../../../commonStateTypes/common';
1
+ import { FetchState, UpdateType } from '../../../commonStateTypes/common';
2
2
  import { TaskPayload } from '../../../entity/task/taskPayload';
3
3
  import { ZeniAPIStatus } from '../../../responsePayload';
4
- import { TaskListFilters, TaskListLocalData, TaskListState, TaskListUIState } from './taskList';
5
- import { TaskGroup } from '../../../entity/taskGroup/taskGroupState';
6
- import { Task } from '../../../entity/task/taskState';
7
- import { TaskGroupPayload } from '../../../entity/taskGroup/taskGroupPayload';
8
- export declare const initialLocalData: TaskListLocalData;
4
+ import { TaskListFilters, TaskListState, TaskListUIState } from './taskList';
9
5
  export declare const initialState: TaskListState;
10
6
  export declare const fetchTaskListPage: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[cacheOverride: boolean], {
11
7
  cacheOverride: boolean;
@@ -21,31 +17,6 @@ export declare const fetchTaskListPage: import("@reduxjs/toolkit").ActionCreator
21
17
  uiState: Partial<TaskListUIState>;
22
18
  }, string>, updateTaskFilters: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
23
19
  filters: TaskListFilters;
24
- }, string>, updateTaskListOnNewGroupCreationSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
25
- newTaskGroup: TaskGroupPayload;
26
- }, string>, bulkUpdateTaskList: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[taskIds: string[], updates: Partial<Task>], {
27
- taskIds: string[];
28
- updates: Partial<Task>;
29
- }, string, never, never>, updateTasksListOnBulkUpdateTasksSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
30
- taskIds: ID[];
31
- groupId: ID | null;
32
- }, string>, updateTasksListOnBulkUpdateTasksFailure: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
33
- error: ZeniAPIStatus;
34
- }, string>, initiateTaskListLocalData: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
35
- taskGroupById: Record<ID, TaskGroup>;
36
- }, string>, updateTaskListLocalData: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
37
- localData: TaskListLocalData;
38
- }, string>, updateTaskListOnTaskGroupDeletion: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
39
- taskGroupId: ID;
40
- }, string>, dragNDropTasks: import("@reduxjs/toolkit").ActionCreatorWithPreparedPayload<[taskIds: string[], groupId: any], {
41
- taskIds: string[];
42
- groupId: any;
43
- }, string, never, never>, updateTaskListOnNewTaskCreationSuccess: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
44
- taskId: ID;
45
- taskGroupId: ID;
46
- }, string>, updateTaskListOnTaskGroupNameUpdate: import("@reduxjs/toolkit").ActionCreatorWithPayload<{
47
- taskGroupName: ID;
48
- taskGroupId: ID;
49
20
  }, string>, clearTaskList: import("@reduxjs/toolkit").ActionCreatorWithoutPayload<string>;
50
21
  declare const _default: import("@reduxjs/toolkit").Reducer<TaskListState, import("@reduxjs/toolkit").AnyAction>;
51
22
  export default _default;
@@ -1,17 +1,10 @@
1
1
  "use strict";
2
2
  var _a;
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.clearTaskList = exports.updateTaskListOnTaskGroupNameUpdate = exports.updateTaskListOnNewTaskCreationSuccess = exports.dragNDropTasks = exports.updateTaskListOnTaskGroupDeletion = exports.updateTaskListLocalData = exports.initiateTaskListLocalData = exports.updateTasksListOnBulkUpdateTasksFailure = exports.updateTasksListOnBulkUpdateTasksSuccess = exports.bulkUpdateTaskList = exports.updateTaskListOnNewGroupCreationSuccess = exports.updateTaskFilters = exports.updateTaskListUIState = exports.updateTaskListSearchText = exports.updateTaskListFetchStatus = exports.updateTaskList = exports.fetchTaskList = exports.fetchTaskListPage = exports.initialState = exports.initialLocalData = void 0;
4
+ exports.clearTaskList = exports.updateTaskFilters = exports.updateTaskListUIState = exports.updateTaskListSearchText = exports.updateTaskListFetchStatus = exports.updateTaskList = exports.fetchTaskList = exports.fetchTaskListPage = exports.initialState = void 0;
5
5
  const toolkit_1 = require("@reduxjs/toolkit");
6
- exports.initialLocalData = {
7
- newTaskGroupName: '',
8
- existingTaskGroupNamesByGroupId: {},
9
- selectedTaskIds: [],
10
- defaultTaskGroupId: null,
11
- };
12
6
  exports.initialState = {
13
7
  taskIds: [],
14
- taskIdsByGroupsIds: {},
15
8
  fetchState: 'Not-Started',
16
9
  searchText: '',
17
10
  error: undefined,
@@ -33,11 +26,6 @@ exports.initialState = {
33
26
  hasValidState() {
34
27
  return this.fetchState == 'Completed';
35
28
  },
36
- localData: Object.assign({}, exports.initialLocalData),
37
- updateTasksFetchState: {
38
- fetchState: 'Not-Started',
39
- error: undefined,
40
- },
41
29
  };
42
30
  const taskList = (0, toolkit_1.createSlice)({
43
31
  name: 'taskList',
@@ -58,40 +46,15 @@ const taskList = (0, toolkit_1.createSlice)({
58
46
  draft.error = undefined;
59
47
  },
60
48
  updateTaskList(draft, action) {
61
- const { data } = action.payload;
49
+ var _a;
50
+ const { data, updateType } = action.payload;
62
51
  draft.fetchState = 'Completed';
63
52
  draft.error = undefined;
64
- const taskIdsByGroupsIds = {};
65
- data.forEach((task) => {
66
- draft.taskIds.push(task.task_id);
67
- if (task.task_group_ids != null) {
68
- task.task_group_ids.forEach((groupId) => {
69
- if (taskIdsByGroupsIds[groupId] != null) {
70
- taskIdsByGroupsIds[groupId].push(task.task_id);
71
- }
72
- else {
73
- taskIdsByGroupsIds[groupId] = [task.task_id];
74
- }
75
- });
76
- }
77
- });
78
- draft.taskIdsByGroupsIds = taskIdsByGroupsIds;
79
- },
80
- initiateTaskListLocalData(draft, action) {
81
- const { taskGroupById } = action.payload;
82
- const existingTaskGroupNamesByGroupId = {};
83
- let defaultTaskGroupId = null;
84
- Object.keys(taskGroupById).forEach((groupId) => {
85
- existingTaskGroupNamesByGroupId[groupId] = taskGroupById[groupId].name;
86
- if (taskGroupById[groupId].isDefault === true) {
87
- defaultTaskGroupId = groupId;
88
- }
89
- });
90
- draft.localData = Object.assign(Object.assign({}, exports.initialLocalData), { defaultTaskGroupId,
91
- existingTaskGroupNamesByGroupId });
92
- },
93
- updateTaskListLocalData(draft, action) {
94
- draft.localData = action.payload.localData;
53
+ const newAccounts = (_a = data.map((task) => task.task_id)) !== null && _a !== void 0 ? _a : [];
54
+ draft.taskIds =
55
+ updateType === 'merge'
56
+ ? [...new Set([...draft.taskIds, ...newAccounts])]
57
+ : newAccounts;
95
58
  },
96
59
  updateTaskListFetchStatus(draft, action) {
97
60
  draft.fetchState = action.payload.fetchState;
@@ -116,100 +79,10 @@ const taskList = (0, toolkit_1.createSlice)({
116
79
  draft.filters = action.payload.filters;
117
80
  }
118
81
  },
119
- updateTaskListOnNewGroupCreationSuccess(draft, action) {
120
- const { newTaskGroup } = action.payload;
121
- draft.localData = Object.assign(Object.assign({}, draft.localData), { existingTaskGroupNamesByGroupId: Object.assign(Object.assign({}, draft.localData.existingTaskGroupNamesByGroupId), { [newTaskGroup.task_group_id]: newTaskGroup.name }) });
122
- },
123
- bulkUpdateTaskList: {
124
- reducer(draft) {
125
- draft.updateTasksFetchState = {
126
- fetchState: 'In-Progress',
127
- error: undefined,
128
- };
129
- },
130
- prepare(taskIds, updates) {
131
- return {
132
- payload: {
133
- taskIds,
134
- updates,
135
- },
136
- };
137
- },
138
- },
139
- dragNDropTasks: {
140
- reducer() {
141
- //do nothing
142
- },
143
- prepare(taskIds, groupId) {
144
- return {
145
- payload: {
146
- taskIds,
147
- groupId,
148
- },
149
- };
150
- },
151
- },
152
- updateTasksListOnBulkUpdateTasksSuccess(draft, action) {
153
- const { taskIds, groupId } = action.payload;
154
- draft.updateTasksFetchState.fetchState = 'Completed';
155
- draft.updateTasksFetchState.error = undefined;
156
- Object.keys(draft.taskIdsByGroupsIds).forEach((groupId) => {
157
- draft.taskIdsByGroupsIds[groupId] = draft.taskIdsByGroupsIds[groupId].filter((taskId) => taskIds.includes(taskId) === false);
158
- });
159
- if (groupId != null) {
160
- if (draft.taskIdsByGroupsIds[groupId] != null) {
161
- draft.taskIdsByGroupsIds[groupId] = [
162
- ...draft.taskIdsByGroupsIds[groupId],
163
- ...taskIds,
164
- ];
165
- }
166
- else {
167
- draft.taskIdsByGroupsIds = Object.assign(Object.assign({}, draft.taskIdsByGroupsIds), { [groupId]: taskIds });
168
- }
169
- }
170
- draft.localData = Object.assign(Object.assign({}, draft.localData), { newTaskGroupName: '', selectedTaskIds: [] });
171
- },
172
- updateTasksListOnBulkUpdateTasksFailure(draft, action) {
173
- draft.updateTasksFetchState.fetchState = 'Error';
174
- draft.updateTasksFetchState.error = action.payload.error;
175
- },
176
- updateTaskListOnTaskGroupDeletion(draft, action) {
177
- var _a;
178
- const { taskGroupId } = action.payload;
179
- const { defaultTaskGroupId } = draft.localData;
180
- if (((_a = draft.taskIdsByGroupsIds[taskGroupId]) === null || _a === void 0 ? void 0 : _a.length) > 0) {
181
- const tasks = draft.taskIdsByGroupsIds[taskGroupId];
182
- if (defaultTaskGroupId != null) {
183
- draft.taskIdsByGroupsIds[defaultTaskGroupId] = [
184
- ...draft.taskIdsByGroupsIds[defaultTaskGroupId],
185
- ...tasks,
186
- ];
187
- }
188
- }
189
- delete draft.taskIdsByGroupsIds[taskGroupId];
190
- delete draft.localData.existingTaskGroupNamesByGroupId[taskGroupId];
191
- },
192
- updateTaskListOnNewTaskCreationSuccess(draft, action) {
193
- const { taskId, taskGroupId } = action.payload;
194
- draft.taskIds.push(taskId);
195
- if (draft.taskIdsByGroupsIds[taskGroupId] != null) {
196
- draft.taskIdsByGroupsIds[taskGroupId] = [
197
- taskId,
198
- ...draft.taskIdsByGroupsIds[taskGroupId],
199
- ];
200
- }
201
- else {
202
- draft.taskIdsByGroupsIds[taskGroupId] = [taskId];
203
- }
204
- },
205
- updateTaskListOnTaskGroupNameUpdate(draft, action) {
206
- const { taskGroupName, taskGroupId } = action.payload;
207
- draft.localData.existingTaskGroupNamesByGroupId = Object.assign(Object.assign({}, draft.localData.existingTaskGroupNamesByGroupId), { [taskGroupId]: taskGroupName });
208
- },
209
82
  clearTaskList(draft) {
210
83
  Object.assign(draft, exports.initialState);
211
84
  },
212
85
  },
213
86
  });
214
- _a = taskList.actions, exports.fetchTaskListPage = _a.fetchTaskListPage, exports.fetchTaskList = _a.fetchTaskList, exports.updateTaskList = _a.updateTaskList, exports.updateTaskListFetchStatus = _a.updateTaskListFetchStatus, exports.updateTaskListSearchText = _a.updateTaskListSearchText, exports.updateTaskListUIState = _a.updateTaskListUIState, exports.updateTaskFilters = _a.updateTaskFilters, exports.updateTaskListOnNewGroupCreationSuccess = _a.updateTaskListOnNewGroupCreationSuccess, exports.bulkUpdateTaskList = _a.bulkUpdateTaskList, exports.updateTasksListOnBulkUpdateTasksSuccess = _a.updateTasksListOnBulkUpdateTasksSuccess, exports.updateTasksListOnBulkUpdateTasksFailure = _a.updateTasksListOnBulkUpdateTasksFailure, exports.initiateTaskListLocalData = _a.initiateTaskListLocalData, exports.updateTaskListLocalData = _a.updateTaskListLocalData, exports.updateTaskListOnTaskGroupDeletion = _a.updateTaskListOnTaskGroupDeletion, exports.dragNDropTasks = _a.dragNDropTasks, exports.updateTaskListOnNewTaskCreationSuccess = _a.updateTaskListOnNewTaskCreationSuccess, exports.updateTaskListOnTaskGroupNameUpdate = _a.updateTaskListOnTaskGroupNameUpdate, exports.clearTaskList = _a.clearTaskList;
87
+ _a = taskList.actions, exports.fetchTaskListPage = _a.fetchTaskListPage, exports.fetchTaskList = _a.fetchTaskList, exports.updateTaskList = _a.updateTaskList, exports.updateTaskListFetchStatus = _a.updateTaskListFetchStatus, exports.updateTaskListSearchText = _a.updateTaskListSearchText, exports.updateTaskListUIState = _a.updateTaskListUIState, exports.updateTaskFilters = _a.updateTaskFilters, exports.clearTaskList = _a.clearTaskList;
215
88
  exports.default = taskList.reducer;
@@ -1,27 +1,17 @@
1
- import { FetchStateAndError } from '../../../commonStateTypes/common';
2
1
  import { SelectorView } from '../../../commonStateTypes/viewAndReport/viewAndReport';
3
2
  import { Task } from '../../../entity/task/taskState';
4
3
  import { RootState } from '../../../reducer';
5
4
  import { UserAndRole } from '../../companyView/types/userAndRole';
6
- import { TaskListFilters, TaskListUIState, TaskListLocalData } from './taskList';
5
+ import { TaskListFilters, TaskListUIState } from './taskList';
7
6
  import { UserListSelectorView } from '../../userListView/userListViewSelector';
8
- import { TaskGroup } from '../../../entity/taskGroup/taskGroupState';
9
7
  export interface TaskWithUserDetails extends Task {
10
8
  assigneeUsers: UserAndRole[];
11
9
  }
12
- export interface TaskGroupWithTasksList extends TaskGroup {
13
- tasks: TaskWithUserDetails[];
14
- }
15
10
  export interface TaskListSelectorView extends SelectorView {
16
- taskGroupsWithTasksList: TaskGroupWithTasksList[];
11
+ taskList: TaskWithUserDetails[];
17
12
  searchText: string;
18
13
  uiState: TaskListUIState;
19
14
  filters: TaskListFilters;
20
15
  userList: UserListSelectorView;
21
- localData: TaskListLocalData;
22
- updateTasksFetchState: FetchStateAndError;
23
- taskGroupDeleteStatus: FetchStateAndError;
24
- taskGroupUpdateStatus: FetchStateAndError;
25
- taskGroupCreationStatus: FetchStateAndError;
26
16
  }
27
17
  export declare const getAllTasks: (state: RootState) => TaskListSelectorView;
@@ -12,10 +12,26 @@ const userAndRole_1 = require("../../companyView/types/userAndRole");
12
12
  const userListViewSelector_1 = require("../../userListView/userListViewSelector");
13
13
  const spendManagementFilterHelpers_1 = require("../../spendManagement/spendManagementFilterHelpers");
14
14
  const tagSelector_1 = require("../../../entity/tag/tagSelector");
15
- const reduceFetchState_1 = require("../../../commonStateTypes/reduceFetchState");
16
- const taskGroupSelector_1 = require("../../../entity/taskGroup/taskGroupSelector");
17
- const sortTasksList = (state, tasksList, sortKey, sortOrder) => {
18
- const tasksInOrder = (0, orderBy_1.default)(tasksList, (task) => {
15
+ const getAllTasks = (state) => {
16
+ const { taskListState, taskState, userState, userRoleState, addressState } = state;
17
+ const searchText = taskListState.searchText;
18
+ const unFilteredTaskList = taskListState.taskIds
19
+ .map((taskId) => {
20
+ const task = (0, taskSelector_1.getTaskById)(taskState, taskId);
21
+ if (task != null) {
22
+ const assigneeUsers = task.assignees
23
+ .map((userId) => (0, userAndRole_1.getUserAndUserRole)(userState, userRoleState, addressState, userId))
24
+ .filter((value) => value != null);
25
+ return Object.assign(Object.assign({}, task), { assigneeUsers });
26
+ }
27
+ return undefined;
28
+ })
29
+ .filter((value) => value != null);
30
+ const searchedTaskList = unFilteredTaskList.filter((task) => task.name.toLowerCase().includes(searchText.toLowerCase()));
31
+ const sortKey = taskListState.uiState.sortKey;
32
+ const sortOrder = (0, sortOrderPayload_1.getSortOrder)(taskListState.uiState.sortOrder);
33
+ const filteredTaskList = (0, spendManagementFilterHelpers_1.applyAdvancedFiltersOnList)('task_management', searchedTaskList, taskListState.filters);
34
+ const tasksInOrder = (0, orderBy_1.default)(filteredTaskList, (task) => {
19
35
  var _a, _b;
20
36
  const tagsByIds = (0, tagSelector_1.getTagsByIds)(state.tagState, task.tagIds);
21
37
  switch (sortKey) {
@@ -34,67 +50,15 @@ const sortTasksList = (state, tasksList, sortKey, sortOrder) => {
34
50
  return task.name.toLowerCase();
35
51
  }
36
52
  }, sortOrder);
37
- return tasksInOrder;
38
- };
39
- const getAllTasks = (state) => {
40
- const { taskListState, taskState, userState, userRoleState, addressState, taskGroupState, taskGroupViewState, tagViewState, } = state;
41
- const { localData, searchText } = taskListState;
42
- const sortKey = taskListState.uiState.sortKey;
43
- const sortOrder = (0, sortOrderPayload_1.getSortOrder)(taskListState.uiState.sortOrder);
44
- const taskGroupIds = taskGroupViewState.taskGroupsIds;
45
- const taskGroupsWithTasksList = taskGroupIds
46
- .map((taskGroupId) => {
47
- var _a;
48
- const taskGroup = (0, taskGroupSelector_1.getTaskGroupById)(taskGroupState, taskGroupId);
49
- const taskIds = (_a = taskListState.taskIdsByGroupsIds[taskGroupId]) !== null && _a !== void 0 ? _a : [];
50
- const tasks = taskIds
51
- .map((taskId) => {
52
- const task = (0, taskSelector_1.getTaskById)(taskState, taskId);
53
- if (task != null) {
54
- const assigneeUsers = task.assignees
55
- .map((userId) => (0, userAndRole_1.getUserAndUserRole)(userState, userRoleState, addressState, userId))
56
- .filter((value) => value != null);
57
- return Object.assign(Object.assign({}, task), { assigneeUsers });
58
- }
59
- return undefined;
60
- })
61
- .filter((value) => (value === null || value === void 0 ? void 0 : value.name.toLowerCase().includes(searchText.toLowerCase())) ===
62
- true);
63
- if (taskGroup != null) {
64
- const filteredTaskList = (0, spendManagementFilterHelpers_1.applyAdvancedFiltersOnList)('task_management', tasks, taskListState.filters);
65
- const sortedTaskList = sortTasksList(state, filteredTaskList, sortKey, sortOrder);
66
- return Object.assign(Object.assign({}, taskGroup), { tasks: sortedTaskList });
67
- }
68
- return undefined;
69
- })
70
- .filter((value) => value != null);
71
- taskGroupsWithTasksList.sort((a, b) => {
72
- return b.createdAt.valueOf() - a.createdAt.valueOf();
73
- });
74
- const sortedTaskGroupsWithTasksList = taskGroupsWithTasksList.filter((taskGroup) => taskGroup.isDefault === false);
75
- const defaultTaskGroup = taskGroupsWithTasksList.find((taskGroup) => taskGroup.isDefault === true);
76
- if (defaultTaskGroup != null) {
77
- sortedTaskGroupsWithTasksList.push(defaultTaskGroup);
78
- }
79
- const { fetchState, error } = (0, reduceFetchState_1.reduceAnyFetchState)([
80
- taskListState,
81
- taskGroupViewState,
82
- tagViewState,
83
- ]);
84
53
  return {
54
+ taskList: tasksInOrder,
85
55
  searchText: taskListState.searchText,
86
56
  uiState: taskListState.uiState,
87
57
  filters: taskListState.filters,
88
- fetchState: fetchState,
58
+ fetchState: taskListState.fetchState,
89
59
  userList: (0, userListViewSelector_1.getUserList)(state, 'taskManagerCandidate'),
90
- error: error,
60
+ error: taskListState.error,
91
61
  version: 0,
92
- taskGroupsWithTasksList: sortedTaskGroupsWithTasksList,
93
- localData,
94
- updateTasksFetchState: taskListState.updateTasksFetchState,
95
- taskGroupDeleteStatus: taskGroupViewState.taskGroupDeleteStatus,
96
- taskGroupUpdateStatus: taskGroupViewState.taskGroupUpdateStatus,
97
- taskGroupCreationStatus: taskGroupViewState.taskGroupCreationStatus,
98
62
  };
99
63
  };
100
64
  exports.getAllTasks = getAllTasks;
@@ -23,8 +23,8 @@ const snackbarReducer_1 = require("../../../entity/snackbar/snackbarReducer");
23
23
  const recommendationPayload_1 = require("../../../commonPayloadTypes/recommendationPayload");
24
24
  const vendorSelector_1 = require("../../../entity/vendor/vendorSelector");
25
25
  const vendorReducer_1 = require("../../../entity/vendor/vendorReducer");
26
- const transactionSelector_1 = require("../../../entity/transaction/transactionSelector");
27
26
  const transactionType_1 = require("../../../entity/transaction/stateTypes/transactionType");
27
+ const transactionSelector_1 = require("../../../entity/transaction/transactionSelector");
28
28
  const updateTransactionDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(transactionDetailReducer_1.updateTransactionDetail.match), (0, operators_1.mergeMap)((action) => {
29
29
  const { transactionState, vendorState, transactionDetailState } = state$.value;
30
30
  return zeniAPI
@@ -63,15 +63,11 @@ const updateTransactionDetailEpic = (actions$, state$, zeniAPI) => actions$.pipe
63
63
  }));
64
64
  actions.push((0, transactionDetailReducer_1.updateTransactionDetailSaveStatus)(transactionIdResp, 'Completed'));
65
65
  let callMarkTransactionAsNotMiscategorized = true;
66
- // NOTE: If tran is vendorType OR JE OR Deposit transaction and there is no vendor chosen on this tranaction while saving,
66
+ // NOTE: If tran is vendorType transaction and there is no vendor chosen on this tranaction while saving,
67
67
  // then we need to skip mark-miscategorized-as-correct api call
68
- if ((0, transactionType_1.toVendorTransactionTypeStrict)(response.data.transaction.transaction_type) != null ||
69
- (0, transactionType_1.toJEAndDepositTransactionTypeStrict)(response.data.transaction.transaction_type) != null) {
68
+ if ((0, transactionType_1.toVendorTransactionTypeStrict)(response.data.transaction.transaction_type) != null) {
70
69
  const isAnyClassMissing = checkIfClassMissingForAnyLineItem(response.data.transaction);
71
- const isVendorOrCustomerMissingInAnyLine = checkIfVendorOrCustomerMissingForAnyLineItem(response.data.transaction);
72
- if (((vendorUpdates === null || vendorUpdates === void 0 ? void 0 : vendorUpdates.id) == null &&
73
- isVendorOrCustomerMissingInAnyLine == true) ||
74
- isAnyClassMissing == true) {
70
+ if ((vendorUpdates === null || vendorUpdates === void 0 ? void 0 : vendorUpdates.id) == null || isAnyClassMissing == true) {
75
71
  callMarkTransactionAsNotMiscategorized = false;
76
72
  }
77
73
  }
@@ -200,7 +196,7 @@ const toTransactionUpdatePayload = (updates, detail, vendorUpdates) => {
200
196
  };
201
197
  const checkIfClassMissingForAnyLineItem = (transactionPayload) => {
202
198
  let isAnyClassMissing = false;
203
- if (transactionPayload.lines != null) {
199
+ if ((transactionPayload === null || transactionPayload === void 0 ? void 0 : transactionPayload.lines) != null) {
204
200
  transactionPayload.lines.forEach((line) => {
205
201
  var _a;
206
202
  if (((_a = line.line_detail) === null || _a === void 0 ? void 0 : _a.class.accounting_class_id) == null) {
@@ -210,19 +206,6 @@ const checkIfClassMissingForAnyLineItem = (transactionPayload) => {
210
206
  }
211
207
  return isAnyClassMissing;
212
208
  };
213
- const checkIfVendorOrCustomerMissingForAnyLineItem = (transactionPayload) => {
214
- let isAnyVendorOrCustomerMissing = false;
215
- if (transactionPayload.lines != null) {
216
- transactionPayload.lines.forEach((line) => {
217
- var _a, _b;
218
- if (((_a = line.line_detail) === null || _a === void 0 ? void 0 : _a.vendor) == null &&
219
- ((_b = line.line_detail) === null || _b === void 0 ? void 0 : _b.customer) == null) {
220
- isAnyVendorOrCustomerMissing = true;
221
- }
222
- });
223
- }
224
- return isAnyVendorOrCustomerMissing;
225
- };
226
209
  const toEntityUpdatePayload = (entityUpdates) => {
227
210
  const entityUpdatesPayload = [];
228
211
  let entityKey;
@@ -67,7 +67,6 @@ const mapVendorPayloadFromVendorFirstReviewViewResponse = (vendor) => {
67
67
  qbo_id: vendor.qbo_id,
68
68
  currency_code: vendor.currency_code,
69
69
  currency_symbol: vendor.currency_symbol,
70
- transaction_attachments: vendor.transaction_attachments,
71
70
  };
72
71
  };
73
72
  const mapUsersPayloadFromVendorFirstReviewViewResponse = (vendorsResponse) => {
@@ -21,12 +21,12 @@ const fetchVendorFirstReviewViewEpic_1 = require("./fetchVendorFirstReviewViewEp
21
21
  const globalMerchantSelector_1 = require("../../../../entity/globalMerchant/globalMerchantSelector");
22
22
  const saveVendorFirstReviewViewEpic = (actions$, state$, zeniAPI) => actions$.pipe((0, operators_1.filter)(vendorFirstReviewViewReducer_1.saveVendorFirstReviewView.match), (0, operators_1.mergeMap)((action) => {
23
23
  const { vendorFirstReviewViewState, globalMerchantState, vendorState } = state$.value;
24
- const { vendorId, markAsEmployee, markAsLocalContractor } = action.payload;
24
+ const { vendorId, markAsEmployee } = action.payload;
25
25
  const currentVendorLocalData = vendorFirstReviewViewState.vendorFirstReviewViewLocalDataById[vendorId]
26
26
  .vendorFirstReviewViewLocalData;
27
27
  const currentVendor = (0, vendorSelector_1.getVendorByVendorId)(state$.value.vendorState, vendorId);
28
28
  const { vendorName, selectedGlobalMerchant, recommendations, nonExistingRecommendations, } = getSaveVendorFirstReviewViewPayloadDetails(currentVendorLocalData, globalMerchantState, vendorState);
29
- const payload = Object.assign({}, prepareSaveVendorFirstReviewViewPayload(vendorName, recommendations, nonExistingRecommendations, markAsEmployee, markAsLocalContractor, currentVendor === null || currentVendor === void 0 ? void 0 : currentVendor.qboId, selectedGlobalMerchant));
29
+ const payload = Object.assign({}, prepareSaveVendorFirstReviewViewPayload(vendorName, recommendations, nonExistingRecommendations, markAsEmployee, currentVendor === null || currentVendor === void 0 ? void 0 : currentVendor.qboId, selectedGlobalMerchant));
30
30
  const queryParam = {
31
31
  view: 'merchant_review_list',
32
32
  };
@@ -68,14 +68,9 @@ const saveVendorFirstReviewViewEpic = (actions$, state$, zeniAPI) => actions$.pi
68
68
  actions.push((0, snackbarReducer_1.openSnackbar)({
69
69
  messageSection: payload.is_employee === true
70
70
  ? 'save_vendor_marked_as_employee'
71
- : payload.is_local_contractor === true
72
- ? 'save_vendor_marked_as_local_contractor'
73
- : 'save_vendor_sent_for_review',
71
+ : 'save_vendor_sent_for_review',
74
72
  messageText: 'success',
75
- type: payload.is_employee === true ||
76
- payload.is_local_contractor === true
77
- ? 'success'
78
- : 'info',
73
+ type: payload.is_employee === true ? 'success' : 'info',
79
74
  variables: [
80
75
  {
81
76
  variableName: '_vendor_name_',
@@ -148,7 +143,7 @@ exports.saveVendorFirstReviewViewEpic = saveVendorFirstReviewViewEpic;
148
143
  /**
149
144
  * Helpers
150
145
  */
151
- const prepareSaveVendorFirstReviewViewPayload = (vendorName, recommendations, nonExistingRecommendations, markAsEmployee, markAsLocalContractor, vendorQboId, selectedGlobalMerchant) => {
146
+ const prepareSaveVendorFirstReviewViewPayload = (vendorName, recommendations, nonExistingRecommendations, markAsEmployee, vendorQboId, selectedGlobalMerchant) => {
152
147
  const selectedGlobalMerchantBase = (selectedGlobalMerchant === null || selectedGlobalMerchant === void 0 ? void 0 : selectedGlobalMerchant.globalMerchantId) != null
153
148
  ? (0, omit_1.default)((0, globalMerchantPayload_1.toGlobalMerchantBasePayload)(selectedGlobalMerchant), ['create_time', 'update_time'])
154
149
  : selectedGlobalMerchant != null
@@ -160,7 +155,6 @@ const prepareSaveVendorFirstReviewViewPayload = (vendorName, recommendations, no
160
155
  selected_global_merchant: markAsEmployee === true ? null : selectedGlobalMerchantBase,
161
156
  recommendations: (0, commonTypes_2.toVendorReviewViewRecommendationPayload)(recommendations, nonExistingRecommendations),
162
157
  is_employee: markAsEmployee,
163
- is_local_contractor: markAsLocalContractor,
164
158
  };
165
159
  return payload;
166
160
  };