Skip to content

Commit

Permalink
fix(AddSystemsToGroupModal): Modal's tabs should drop applied filters…
Browse files Browse the repository at this point in the history
… when it closes

The systems table of ImmutableDevicesView, which uses Edge's DevicesView, persists filters in the Session Storage
  • Loading branch information
LiorKGOW committed Apr 24, 2024
1 parent 863a529 commit 821c1b2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/components/GroupSystems/GroupImmutableSystems.js
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ const GroupImmutableSystems = ({ groupName, groupId, ...props }) => {
isModalOpen={addToGroupModalOpen}
setIsModalOpen={(value) => {
dispatch(clearEntitiesAction());
// ImmutableDevicesView, which uses Edge's DevicesView, systems table persists filters in the Session Storage
window.sessionStorage.removeItem('edge-devices-table-filters');
setAddToGroupModalOpen(value);
}}
groupId={groupId}
Expand Down
2 changes: 2 additions & 0 deletions src/components/GroupSystems/GroupSystems.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,8 @@ const GroupSystems = ({ groupName, groupId }) => {
isModalOpen={addToGroupModalOpen}
setIsModalOpen={(value) => {
dispatch(clearEntitiesAction());
// The systems table of ImmutableDevicesView, which uses Edge's DevicesView, persists filters in the Session Storage
window.sessionStorage.removeItem('edge-devices-table-filters');
setAddToGroupModalOpen(value);
}}
groupId={groupId}
Expand Down

0 comments on commit 821c1b2

Please sign in to comment.