diff --git a/Website/main.py b/Website/main.py index fbcf118..60a1a0a 100644 --- a/Website/main.py +++ b/Website/main.py @@ -2442,7 +2442,13 @@ def booking_payment(): packages_str = _sanitize_text(request.values.get("packages") or request.values.get("package") or "", 200).lower() booking_flow = _sanitize_text(request.values.get("flow") or "payment", 24).lower() - is_trial = booking_flow in {"trial", "testversion"} or request.values.get("testversion", "").strip().lower() in {"1", "on", "true", "yes"} + requested_trial = request.values.get("testversion", "").strip().lower() in {"1", "on", "true", "yes"} + package_requests_trial = "testversion" in { + package.strip().lower() + for package in packages_str.split(",") + if package.strip() + } + is_trial = booking_flow in {"trial", "testversion"} or requested_trial or package_requests_trial trial_days = int(request.values.get("trial_days") or 14) if booking_flow not in BOOKING_FLOW_MAP and booking_flow != "trial": diff --git a/Website/templates/schnell_buchung.html b/Website/templates/schnell_buchung.html index 9ebdec3..6c243a2 100644 --- a/Website/templates/schnell_buchung.html +++ b/Website/templates/schnell_buchung.html @@ -304,6 +304,7 @@
+
1. Angaben zur Schule & Ansprechpartner
@@ -524,17 +525,16 @@ let backendData = null; // Speichert das finale Backend-Resultat let isFailed = false; - // Echte Log-Meldungen, die exakt alle 10 Sekunden durchgeschaltet werden const statusSteps = [ - { atMs: 0, msg: "[INFO] Verarbeite Trigger: Starte Provisionierung für " + slug + "..." }, - { atMs: 10000, msg: "[INFO] Prüfe freie Ports... Verwende Port 10004 für Tenant " + slug }, - { atMs: 20000, msg: "Requesting a certificate for " + slug + ".invario-software.de..." }, - { atMs: 30000, msg: "Successfully deployed certificate to Nginx. Restarting app container..." }, - { atMs: 40000, msg: "Container inventarsystem-app-1 Recreated. Waiting for MongoDB/Redis..." }, - { atMs: 50000, msg: "Initializing database for " + slug + "... Default admin created." }, - { atMs: 60000, msg: "Module configurations updated successfully (library=on)..." }, - { atMs: 70000, msg: "Rebuilding and/or restarting app container using docker-compose..." }, - { atMs: 80000, msg: "[INFO] Bereinige verwaiste App-Container. Cleaning up old temporary files..." } + { atMs: 0, msg: "[INFO] Processing trigger: Starting deployment for " + slug + "..." }, + { atMs: 10000, msg: "[INFO] Checking available resources and allocating network ports..." }, + { atMs: 20000, msg: "[INFO] Requesting security certificate for " + slug + "..." }, + { atMs: 30000, msg: "[INFO] Deploying certificate to proxy layer. Restarting service..." }, + { atMs: 40000, msg: "[INFO] Service containers recreated. Waiting for backend dependencies..." }, + { atMs: 50000, msg: "[INFO] Initializing storage for " + slug + "... Default admin created." }, + { atMs: 60000, msg: "[INFO] Configurations updated successfully..." }, + { atMs: 70000, msg: "[INFO] Rebuilding and restarting application stack..." }, + { atMs: 80000, msg: "[INFO] Cleaning up temporary files and orphan processes..." } ]; // 1. Hintergrund-Polling: Fragt den echten Status ab, OHNE die UI abzubrechen