aufraeumen

This commit is contained in:
rirat-0
2026-06-17 14:50:05 +02:00
parent 9353a7eaaa
commit beeab0ec90
+1 -3
View File
@@ -3,13 +3,10 @@ function initSorter() {
const form = document.getElementById('search-form-id'); const form = document.getElementById('search-form-id');
const sortRadios = document.querySelectorAll('.sort-radio'); const sortRadios = document.querySelectorAll('.sort-radio');
console.log("Sorter geladen. Formular gefunden:", !!form, "Radios gefunden:", sortRadios.length);
if (!form) return; if (!form) return;
sortRadios.forEach(radio => { sortRadios.forEach(radio => {
radio.addEventListener('change', function() { radio.addEventListener('change', function() {
console.log("Sortierung geändert auf:", this.value);
const pageInput = document.getElementById('s-res-page-input'); const pageInput = document.getElementById('s-res-page-input');
if (pageInput) { if (pageInput) {
@@ -21,6 +18,7 @@ function initSorter() {
}); });
} }
// ist das DOM bereits vollständig aufgebaut?
if (document.readyState === 'loading') { if (document.readyState === 'loading') {
document.addEventListener('DOMContentLoaded', initSorter); document.addEventListener('DOMContentLoaded', initSorter);
} else { } else {