diff --git a/TGBeta.ps1 b/TGBeta.ps1 index 8bb5103..e59f091 100644 --- a/TGBeta.ps1 +++ b/TGBeta.ps1 @@ -951,6 +951,14 @@ function GetHtmlContent { } } + function updateSelectAllCheckbox(selectAllId, checkboxGroupSelector) { + const selectAllCheckbox = document.getElementById(selectAllId); + const checkboxes = document.querySelectorAll(checkboxGroupSelector); + + // If any checkbox is unchecked, uncheck "Select All" + selectAllCheckbox.checked = Array.from(checkboxes).every(checkbox => checkbox.checked); + } + function toggleLeftColumnCheckboxes(selectAllCheckbox) { const leftCheckboxes = document.querySelectorAll('#leftColumn input[type="checkbox"]:not(#selectAllLeftCheckbox)'); const dattoRMMCheckbox = document.getElementById('installDattoRMMCheckbox'); @@ -975,17 +983,7 @@ function GetHtmlContent { } } - - function updateSelectAllonboard() { - const selectAllCheckbox = document.getElementById('selectAllOnboardCheckbox'); - const checkboxes = document - .getElementById('onboardTab') - .querySelectorAll('input[type="checkbox"]:not(#selectAllOnboardCheckbox)'); - - // If any checkbox is unchecked, uncheck "Select All" - selectAllCheckbox.checked = Array.from(checkboxes).every(checkbox => checkbox.checked); - } - + function gatherSelectedTasks() { const selectedLeftTasks = Array.from(document.querySelectorAll('.left-checkbox:checked')).map(checkbox => checkbox.name); const selectedRightTasks = Array.from(document.querySelectorAll('.right-checkbox:checked')).map(checkbox => checkbox.name);