diff --git a/backend/app/database/myp.db-shm b/backend/app/database/myp.db-shm
index 863ce04e..df032d2a 100644
Binary files a/backend/app/database/myp.db-shm and b/backend/app/database/myp.db-shm differ
diff --git a/backend/app/database/myp.db-wal b/backend/app/database/myp.db-wal
index c694ca03..dde875e5 100644
Binary files a/backend/app/database/myp.db-wal and b/backend/app/database/myp.db-wal differ
diff --git a/backend/app/templates/jobs.html b/backend/app/templates/jobs.html
index e877df0b..032b11f1 100644
--- a/backend/app/templates/jobs.html
+++ b/backend/app/templates/jobs.html
@@ -572,7 +572,7 @@
-
-
+
Abbrechen
@@ -1841,35 +1841,60 @@ class JobManager {
}
}
-// Modal Animations
+// Modal Animations - Robuste Version
function showModal(modalId) {
+ console.log('Opening modal:', modalId);
const modal = document.getElementById(modalId);
const content = modal.querySelector('.mercedes-modal, .dashboard-card');
- // Entferne hidden-Klasse und setze display
+ if (!modal || !content) {
+ console.error('Modal or content not found:', modalId);
+ return;
+ }
+
+ // 1. Setze grundlegende Sichtbarkeit
modal.classList.remove('hidden');
modal.style.display = 'block';
+ modal.style.visibility = 'visible';
- // Animation mit leichter Verzögerung für smooth transition
- setTimeout(() => {
+ // 2. Stelle sicher, dass Modal im Ausgangszustand ist
+ content.classList.remove('scale-100', 'opacity-100');
+ content.classList.add('scale-95', 'opacity-0');
+
+ // 3. Force repaint für smooth animation
+ modal.offsetHeight;
+
+ // 4. Animiere zur sichtbaren Position
+ requestAnimationFrame(() => {
content.classList.remove('scale-95', 'opacity-0');
content.classList.add('scale-100', 'opacity-100');
- }, 10);
+ });
+
+ console.log('Modal opened successfully:', modalId);
}
function hideModal(modalId) {
+ console.log('Closing modal:', modalId);
const modal = document.getElementById(modalId);
const content = modal.querySelector('.mercedes-modal, .dashboard-card');
+ if (!modal || !content) {
+ console.error('Modal or content not found:', modalId);
+ return;
+ }
+
// Animation rückwärts
content.classList.remove('scale-100', 'opacity-100');
content.classList.add('scale-95', 'opacity-0');
- // Nach Animation verstecken
+ // Nach Animation komplett verstecken
setTimeout(() => {
modal.classList.add('hidden');
modal.style.display = 'none';
+ modal.style.visibility = 'hidden';
}, 200);
+
+ console.log('Modal closed successfully:', modalId);
}
// Global functions for UI interactions
@@ -1927,6 +1952,7 @@ function changePage(direction) {
}
function showQuickReservation() {
+ console.log('🔧 TEST: showQuickReservation() aufgerufen');
showModal('quickReservationModal');
}
@@ -1960,5 +1986,74 @@ let jobManager;
document.addEventListener('DOMContentLoaded', () => {
jobManager = new JobManager();
});
+
+// Debug-Test-Funktionen
+function testModal() {
+ console.log('🧪 Modal-Test gestartet...');
+ const modal = document.getElementById('quickReservationModal');
+ const content = modal.querySelector('.mercedes-modal');
+
+ console.log('Modal gefunden:', !!modal);
+ console.log('Content gefunden:', !!content);
+ console.log('Modal HTML:', modal ? modal.outerHTML.substring(0, 200) + '...' : 'NULL');
+
+ if (modal && content) {
+ console.log('✅ Elemente gefunden - Modal wird geöffnet');
+ showModal('quickReservationModal');
+ } else {
+ console.error('❌ Modal oder Content nicht gefunden');
+ }
+}
+
+// Inline Test-Button (nur für Debugging)
+window.testModalFunction = testModal;
+
+function openQuickModal() {
+ console.log('🚀 openQuickModal() aufgerufen');
+
+ // Direkte Modal-Öffnung ohne komplizierte Funktionen
+ const modal = document.getElementById('quickReservationModal');
+ const content = modal.querySelector('.mercedes-modal');
+
+ console.log('Modal Element:', modal);
+ console.log('Content Element:', content);
+
+ if (modal && content) {
+ // Schritt 1: Modal sichtbar machen
+ modal.classList.remove('hidden');
+ modal.style.display = 'block';
+
+ // Schritt 2: Animation starten (mit setTimeout für Browser-Repaint)
+ setTimeout(() => {
+ content.classList.remove('scale-95', 'opacity-0');
+ content.classList.add('scale-100', 'opacity-100');
+ console.log('✅ Modal Animation gestartet');
+ }, 100);
+
+ console.log('✅ Modal sollte jetzt sichtbar sein');
+ } else {
+ console.error('❌ Modal oder Content nicht gefunden');
+ }
+}
+
+function closeQuickModal() {
+ console.log('🔒 closeQuickModal() aufgerufen');
+
+ const modal = document.getElementById('quickReservationModal');
+ const content = modal.querySelector('.mercedes-modal');
+
+ if (modal && content) {
+ // Animation rückwärts
+ content.classList.remove('scale-100', 'opacity-100');
+ content.classList.add('scale-95', 'opacity-0');
+
+ // Nach Animation verstecken
+ setTimeout(() => {
+ modal.classList.add('hidden');
+ modal.style.display = 'none';
+ console.log('✅ Modal geschlossen');
+ }, 200);
+ }
+}
{% endblock %}
\ No newline at end of file