diff --git a/public/Warenkorb/warenkorb.html b/public/Warenkorb/warenkorb.html index 9b36e08..13331ff 100644 --- a/public/Warenkorb/warenkorb.html +++ b/public/Warenkorb/warenkorb.html @@ -29,7 +29,7 @@ document.addEventListener('DOMContentLoaded', function () { ladeWarenkorb(); - document.getElementById('zurKasseGehen').addEventListener('click', function() { + document.getElementById('zurKasseGehen').addEventListener('click', function () { window.location.href = '/bestellformular'; // Deine Bestellformular-Seite }); }); @@ -116,6 +116,6 @@ localStorage.setItem('warenkorb', JSON.stringify(warenkorb)); ladeWarenkorb(); } - + diff --git a/public/bestellformular/bestellformular.html b/public/bestellformular/bestellformular.html index 1e990b5..d218cb3 100644 --- a/public/bestellformular/bestellformular.html +++ b/public/bestellformular/bestellformular.html @@ -24,7 +24,7 @@ - + @@ -36,7 +36,7 @@ - + Bestellung absenden @@ -56,7 +56,6 @@ document.addEventListener('DOMContentLoaded', function () { - const formular = document.getElementById('bestellform'); const kundenNrInput = document.getElementById('KundenNr'); const VornameInput = document.getElementById('Vorname'); const NachnameInput = document.getElementById('Nachname'); @@ -142,7 +141,7 @@ const result = await response.json(); if (response.ok) { - // Bestellung erfolgreich -> Weiterleitung + // Bestellung erfolgreich → Weiterleitung warenkorbLeeren(); window.location.href = "/bestellung"; } else { diff --git a/public/bestellung/bestellung.html b/public/bestellung/bestellung.html index 12a5b23..118b2ce 100644 --- a/public/bestellung/bestellung.html +++ b/public/bestellung/bestellung.html @@ -33,23 +33,23 @@ window.location.href = '/login'; return; } - + try { const response = await fetch('/api/bestellung/daten', { method: 'POST', headers: { 'Content-Type': 'application/json' }, - body: JSON.stringify({ user_id: user_id }) + body: JSON.stringify({user_id: user_id}) }); - + if (response.ok) { const daten = await response.json(); const bestellungContainer = document.getElementById('bestellung'); bestellungContainer.innerHTML = ''; const bestellungen = {}; - + daten.forEach(item => { if (!bestellungen[item.order_id]) { bestellungen[item.order_id] = { @@ -68,24 +68,24 @@ const bestellung = bestellungen[orderId]; const bestellCard = document.createElement('div'); bestellCard.className = 'bestell-info-card'; - + let produkteHTML = ''; bestellung.produkte.forEach(produkt => { produkteHTML += `

• ${produkt.name} — ${produkt.quantity} Stück — Preis: ${produkt.preis.toFixed(2)} €

`; }); - + bestellCard.innerHTML = `

Bestellnummer: ${orderId}

${produkteHTML}

Gesamtsumme: ${bestellung.total.toFixed(2)} €

`; - + bestellungContainer.appendChild(bestellCard); } - + } else if (response.status === 404) { document.getElementById('bestellung').innerHTML = '

Keine Bestellungen gefunden.

'; } else { @@ -95,10 +95,10 @@ console.error('Fehler: ', error); } } - + window.addEventListener('DOMContentLoaded', ladeBestellung); - - + + diff --git a/public/header_footer/header.html b/public/header_footer/header.html index b83a6a1..06dddf7 100644 --- a/public/header_footer/header.html +++ b/public/header_footer/header.html @@ -1,6 +1,6 @@
@@ -24,7 +24,6 @@ 0 -
@@ -38,17 +37,17 @@ - + - + diff --git a/public/kontaktformular/kontaktformular.html b/public/kontaktformular/kontaktformular.html index c6481ff..be7748d 100644 --- a/public/kontaktformular/kontaktformular.html +++ b/public/kontaktformular/kontaktformular.html @@ -1,55 +1,58 @@ - - - Kontaktformular - - - + + + Kontaktformular + + +
- - + + -
-
-

Kontaktieren Sie uns

-

Sie haben Fragen oder Anregungen? Schreiben Sie uns – wir melden uns schnellstmöglich!

+
+
+

Kontaktieren Sie uns

+

Sie haben Fragen oder Anregungen? Schreiben Sie uns – wir melden uns + schnellstmöglich!

-
-
- - -
-
- - -
-
- - -
-
- -
- -
-
-
+
+
+ + +
+
+ + +
+
+ + +
+
+ +
+ +
+
+
- - + +
diff --git a/public/shop/shop.html b/public/shop/shop.html index 2d81b71..2cfcc38 100644 --- a/public/shop/shop.html +++ b/public/shop/shop.html @@ -33,12 +33,12 @@ - +