You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

13 lines
562 B
JavaScript

document.addEventListener("DOMContentLoaded", function () {
var showReportButtons = document.querySelectorAll(".showReportButton");
// Iterate through each button and attach the click event
showReportButtons.forEach(function (button) {
button.addEventListener("click", function () {
// Find the related reportContainer based on the button's parent
var reportContainer = button.closest(".daily-report").querySelector(".reportContainer");
reportContainer.classList.toggle("hidden");
});
});
});