Skip to content

Commit d0c17b3

Browse files
authored
Tt 299 activities when active inactive an activity not display information in name description (#713)
* fix: TT-299 modified state machine to not show name and description of activities * fix: TT-299 removal of variables and tests that are no longer neccessary * fix: TT-299 modified state machine to not show name and description of activities * fix: TT-299 removal of variables and tests that are no longer neccessary
1 parent 64e102d commit d0c17b3

File tree

2 files changed

+0
-21
lines changed

2 files changed

+0
-21
lines changed

src/app/modules/activities-management/store/activity-management.reducers.spec.ts

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -142,20 +142,4 @@ describe('activityManagementReducer', () => {
142142
expect(state.message).toEqual('Something went wrong unarchiving activities!');
143143
expect(state.isLoading).toBeFalse();
144144
});
145-
146-
it('on SetActivityToEdit, should save the activityId to edit', () => {
147-
const action = new actions.SetActivityToEdit(activity.id);
148-
149-
const state = activityManagementReducer(initialState, action);
150-
151-
expect(state.activityIdToEdit).toEqual('1');
152-
});
153-
154-
it('on ResetActivityToEdit, should clean the activityIdToEdit variable', () => {
155-
const action = new actions.ResetActivityToEdit();
156-
157-
const state = activityManagementReducer(initialState, action);
158-
159-
expect(state.activityIdToEdit).toEqual('');
160-
});
161145
});

src/app/modules/activities-management/store/activity-management.reducers.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ export function activityManagementReducer(state: ActivityState = initialState, a
6868
...state,
6969
isLoading: true,
7070
message: 'Set activityIdToArchive property',
71-
activityIdToEdit: action.activityId,
7271
};
7372
}
7473

@@ -89,7 +88,6 @@ export function activityManagementReducer(state: ActivityState = initialState, a
8988
data: [],
9089
isLoading: false,
9190
message: 'Something went wrong deleting activity!',
92-
activityIdToEdit: '',
9391
};
9492
}
9593

@@ -127,7 +125,6 @@ export function activityManagementReducer(state: ActivityState = initialState, a
127125
...state,
128126
isLoading: true,
129127
message: 'Set activityIdToUnarchive property',
130-
activityIdToEdit: action.payload,
131128
};
132129
}
133130

@@ -140,7 +137,6 @@ export function activityManagementReducer(state: ActivityState = initialState, a
140137
data: activityList,
141138
isLoading: false,
142139
message: 'Unarchive activity successfully!',
143-
activityIdToEdit: '',
144140
};
145141
}
146142

@@ -149,7 +145,6 @@ export function activityManagementReducer(state: ActivityState = initialState, a
149145
...state,
150146
isLoading: false,
151147
message: 'Something went wrong unarchiving activities!',
152-
activityIdToEdit: '',
153148
};
154149
}
155150

0 commit comments

Comments
 (0)