Skip to content

Conversation

@RopRaptor
Copy link
Contributor

🎫 Issue IBX-10608

Description:

Added clearCheckboxes method to reset checkbox states after actions in admin notifications list.
It worked fine in Chrome, but these changes are meant to fix the bug inside Firefox.

For QA:

Documentation:

@RopRaptor RopRaptor requested a review from a team October 23, 2025 08:09
@ezrobot ezrobot requested review from GrabowskiM, OstafinL, albozek, alekmick, dew326 and tischsoic and removed request for a team October 23, 2025 08:09
.filter((checkbox) => checkbox.checked)
.map((checkbox) => checkbox.dataset.notificationId);

if (!selectedNotifications.length) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder whether this check is really needed? Because "mark as read" button should be disabled if nothing is selected, so if this condition is false this function should not be called in the first place.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, you have a point with the disable state of the button that I was not aware of.
In this specific case it might not be neccesarry then as this is just a double-check

});
};

const clearCheckboxes = () => {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it would be better to place this logic in admin-ui/src/bundle/Resources/public/js/scripts/admin.table.js? And trigger it with an event. In this file there is a logic related to managing these selection checkboxes in all tables.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see the file now.
I think it would make more sense to have the logic there too

@sonarqubecloud
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants