From 9e3943581866a521be694a7c7a87db70130ee2d7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Thomas=20G=C3=BCnther?=
Date: Sun, 26 Apr 2026 15:58:24 +0200
Subject: [PATCH] Bugfixes
---
legacy/after-submit/alreadyexist.jsx | 14 -
legacy/after-submit/success.jsx | 87 -------
legacy/components/amount-selector.jsx | 45 ----
legacy/partials/addons.jsx | 48 ----
legacy/partials/age.jsx | 36 ---
legacy/partials/allergies.jsx | 60 -----
legacy/partials/arrival.jsx | 65 -----
legacy/partials/contactperson.jsx | 68 -----
legacy/partials/personaldata.jsx | 91 -------
legacy/partials/photopermissions.jsx | 77 ------
legacy/partials/registration-groupbased.jsx | 51 ----
legacy/partials/registration-solidarity.jsx | 47 ----
legacy/partials/summary.jsx | 75 ------
legacy/signup-main.jsx | 267 --------------------
14 files changed, 1031 deletions(-)
delete mode 100644 legacy/after-submit/alreadyexist.jsx
delete mode 100644 legacy/after-submit/success.jsx
delete mode 100644 legacy/components/amount-selector.jsx
delete mode 100644 legacy/partials/addons.jsx
delete mode 100644 legacy/partials/age.jsx
delete mode 100644 legacy/partials/allergies.jsx
delete mode 100644 legacy/partials/arrival.jsx
delete mode 100644 legacy/partials/contactperson.jsx
delete mode 100644 legacy/partials/personaldata.jsx
delete mode 100644 legacy/partials/photopermissions.jsx
delete mode 100644 legacy/partials/registration-groupbased.jsx
delete mode 100644 legacy/partials/registration-solidarity.jsx
delete mode 100644 legacy/partials/summary.jsx
delete mode 100644 legacy/signup-main.jsx
diff --git a/legacy/after-submit/alreadyexist.jsx b/legacy/after-submit/alreadyexist.jsx
deleted file mode 100644
index f7e90ed..0000000
--- a/legacy/after-submit/alreadyexist.jsx
+++ /dev/null
@@ -1,14 +0,0 @@
-import React from 'react';
-
-function AlreadyExistsContainer({ labels, participant_data }) {
- return (
-
-
{participant_data.nicename}
- {participant_data.text_1}
- {participant_data.text_2}
- {participant_data.email_text} ( {participant_data.email_text} )
-
- );
-}
-
-export default AlreadyExistsContainer;
\ No newline at end of file
diff --git a/legacy/after-submit/success.jsx b/legacy/after-submit/success.jsx
deleted file mode 100644
index 478f0ed..0000000
--- a/legacy/after-submit/success.jsx
+++ /dev/null
@@ -1,87 +0,0 @@
-import React from 'react';
-import {__} from '../../../../assets/javascripts/library.js';
-
-function EfzStatusMessage({ efzStatus }) {
- if (efzStatus === 'NOT_CHECKED') {
- return
- Dein erweitertes Führungszeugnis konnte nicht automatisch überprüft werden. Bitte kontaktiere die Aktionsleitung, da deine Teilnahme nur mit gültigem eFZ möglich ist.
-
;
- }
-
- if (efzStatus === 'CHECKED_INVALID') {
- return
- Du hast noch kein erweitertes Führungszeugnis bereitgestellt, sodass deine Teilnahme nicht möglich ist. Bitte reiche dein erweitertes Führungszeugnis umgehend ein,
- da deine Teilnahme andernfalls storniert werden kann. Bitte setze dich mit der Aktionsleitung in Verbindung.
-
;
- }
-
- return null; // default: nix anzeigen
-}
-
-function SuccessContainer({ participant_data }) {
- return (
-
-
{__('Hello', 'solea')} {participant_data.nicename}
-
- {participant_data.introduction}
- {__('We have received the following information:', 'solea')}
-
-
- {__('Arrival', 'solea')}: {participant_data.arrival}
- {__('Departure', 'solea')}: {participant_data.departure}
- {__('Participation group', 'solea')}: {participant_data.participation_group}
-
- {participant_data.needs_payment ? (
-
-
-
- {__('Account owner', 'solea')}:
- {participant_data.account_owner}
-
-
-
- {__('IBAN', 'solea')}:
- {participant_data.account_iban}
-
-
-
- {__('Purpose', 'solea')}:
- {participant_data.payment_purpose}
-
-
-
- { __('Total amount', 'solea')}:
- {participant_data.amount}
-
-
-
-
- {__('If your bank supports QR-Code based paying, use this code', 'solea')}
-
-
-
-
-
- {__( 'If payment is not possible or only partially possible within this period, please contact the event management.', 'solea' )}
-
-
- ) : (
-
- {__('You do not have to pay the registration fee. This is the case if participation is supported, billing is done through your local group, or there are other decisions.', 'solea')}
- {__('Your registration is confirmed now.', 'solea' ) }
-
-
-
- )}
-
-
-
-
- {__('You will receive an email with further information within 2 hours. If you do not receive this mail or have any questions about your registration, please contact the event management.', 'solea')}
- {__('You can contact us at', 'solea')}: {participant_data.event_email}
-
-
- );
-}
-
-export default SuccessContainer;
\ No newline at end of file
diff --git a/legacy/components/amount-selector.jsx b/legacy/components/amount-selector.jsx
deleted file mode 100644
index 865c676..0000000
--- a/legacy/components/amount-selector.jsx
+++ /dev/null
@@ -1,45 +0,0 @@
-import React from 'react';
-import { ArrivalDepratureValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function AmountSelectorContainer({ labels, event_data }) {
- return (
-
- );
-}
-
-export default AmountSelectorContainer;
\ No newline at end of file
diff --git a/legacy/partials/addons.jsx b/legacy/partials/addons.jsx
deleted file mode 100644
index 543d514..0000000
--- a/legacy/partials/addons.jsx
+++ /dev/null
@@ -1,48 +0,0 @@
-import React from 'react';
-import AmountSelectorContainer from "../components/amount-selector.jsx";
-
-function AddonsContainer({ onStepClick, labels, event_data }) {
- const handle_next_step = () => {
- onStepClick(7);
- }
-
-
- return (
-
- {event_data.registration_mode === 'solidarity' && (
-
- )}
-
- {event_data.addons.length > 0 && (
-
-
{labels.addons.addons.available_addons}
-
-
- )}
- onStepClick(5)} />
- handle_next_step()} />
-
- );
-}
-
-
-
-export default AddonsContainer;
\ No newline at end of file
diff --git a/legacy/partials/age.jsx b/legacy/partials/age.jsx
deleted file mode 100644
index 96dfde5..0000000
--- a/legacy/partials/age.jsx
+++ /dev/null
@@ -1,36 +0,0 @@
-import React from 'react';
-
-
-
-function AgeContainer({ onStepClick, labels, configuration }) {
- return (
-
-
onStepClick(2)} className="solea_age_selector">
-
-
-
{labels.age.headline_children}
- {labels.age.text_children}
-
-
-
-
-
-
-
-
-
onStepClick(3)} className="solea_age_selector">
-
-
{labels.age.headline_adults}
- {labels.age.text_adults}
-
-
-
-
-
-
-
- );
-}
-
-
-export default AgeContainer;
\ No newline at end of file
diff --git a/legacy/partials/allergies.jsx b/legacy/partials/allergies.jsx
deleted file mode 100644
index bed72ac..0000000
--- a/legacy/partials/allergies.jsx
+++ /dev/null
@@ -1,60 +0,0 @@
-import React from 'react';
-import { ContactDataValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function AllergiesContainer({ onStepClick, labels, event_data, participant_data }) {
- const handle_next_step = () => {
- onStepClick(9);
- }
-
- return (
-
- );
-}
-
-export default AllergiesContainer;
\ No newline at end of file
diff --git a/legacy/partials/arrival.jsx b/legacy/partials/arrival.jsx
deleted file mode 100644
index 9dc86b8..0000000
--- a/legacy/partials/arrival.jsx
+++ /dev/null
@@ -1,65 +0,0 @@
-import React from 'react';
-import { ArrivalDepratureValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function ArrivalContainer({ onStepClick, labels, event_data }) {
- const handle_next_step = () => {
- if (ArrivalDepratureValidator(
-
- new Date(event_data.date_begin),
- new Date (event_data.date_end)
- ) ) {
- if (event_data.addons.length > 0 || event_data.registration_mode === 'solidarity') {
- onStepClick(6);
- } else {
- onStepClick(7);
- }
-
- }
- }
-
- return (
-
- );
-}
-
-export default ArrivalContainer;
\ No newline at end of file
diff --git a/legacy/partials/contactperson.jsx b/legacy/partials/contactperson.jsx
deleted file mode 100644
index b9ef2f2..0000000
--- a/legacy/partials/contactperson.jsx
+++ /dev/null
@@ -1,68 +0,0 @@
-import React from 'react';
-import { ContactPersonValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function ContactPersonContainer({ onStepClick, labels, participant_data }) {
- const handle_next_step = () => {
-
- if (ContactPersonValidator() ) {
- onStepClick(3);
- }
- }
-
- return (
-
- );
-}
-
-export default ContactPersonContainer;
\ No newline at end of file
diff --git a/legacy/partials/personaldata.jsx b/legacy/partials/personaldata.jsx
deleted file mode 100644
index c7a8e03..0000000
--- a/legacy/partials/personaldata.jsx
+++ /dev/null
@@ -1,91 +0,0 @@
-import React from 'react';
-import { ContactDataValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function PersonalDataContainer({ onStepClick, labels, participant_data, local_groups }) {
- const handle_next_step = () => {
- if (ContactDataValidator()) {
- onStepClick(4);
- }
- }
-
- return (
-
- );
-}
-
-export default PersonalDataContainer;
\ No newline at end of file
diff --git a/legacy/partials/photopermissions.jsx b/legacy/partials/photopermissions.jsx
deleted file mode 100644
index 7dc3b67..0000000
--- a/legacy/partials/photopermissions.jsx
+++ /dev/null
@@ -1,77 +0,0 @@
-import React from 'react';
-
-function PhotopermissionsContainer({ onStepClick, labels, event_data }) {
- const accept_all_permissions = () => {
- document.getElementById( 'foto_socialmedia' ).checked = true;
- document.getElementById( 'foto_print' ).checked = true;
- document.getElementById( 'foto_webseite' ).checked = true;
- document.getElementById( 'foto_partner' ).checked = true;
- document.getElementById( 'foto_intern' ).checked = true;
- handle_next_step();
- }
-
- const handle_next_step = () => {
- onStepClick(8);
-
- }
-
- const handle_previous_step = () => {
- if (event_data.addons.length > 0 || event_data.registration_mode === 'solidarity') {
- onStepClick(6);
- } else {
- onStepClick(5);
- }
- }
-
- return (
-
- );
-}
-
-export default PhotopermissionsContainer;
\ No newline at end of file
diff --git a/legacy/partials/registration-groupbased.jsx b/legacy/partials/registration-groupbased.jsx
deleted file mode 100644
index 5fb9bb4..0000000
--- a/legacy/partials/registration-groupbased.jsx
+++ /dev/null
@@ -1,51 +0,0 @@
-import React from 'react';
-import { ContactDataValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function GroupBasedRegistrationContainer({ onStepClick, labels, participant_data, local_groups, event_data }) {
- const handle_next_step = () => {
- onStepClick(5);
- }
-
- return (
-
-
-
- );
-}
-
-export default GroupBasedRegistrationContainer;
\ No newline at end of file
diff --git a/legacy/partials/registration-solidarity.jsx b/legacy/partials/registration-solidarity.jsx
deleted file mode 100644
index 438f112..0000000
--- a/legacy/partials/registration-solidarity.jsx
+++ /dev/null
@@ -1,47 +0,0 @@
-import React from 'react';
-import { ContactDataValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function SolidarityRegistrationContainer({ onStepClick, labels, participant_data, local_groups, event_data }) {
- const handle_next_step = () => {
- onStepClick(5);
- }
-
- return (
-
- );
-}
-
-export default SolidarityRegistrationContainer;
\ No newline at end of file
diff --git a/legacy/partials/summary.jsx b/legacy/partials/summary.jsx
deleted file mode 100644
index 45a4ab6..0000000
--- a/legacy/partials/summary.jsx
+++ /dev/null
@@ -1,75 +0,0 @@
-import React from 'react';
-import { ContactDataValidator } from '../../../../assets/javascripts/registration-validator.js'
-
-
-function SummaryContainer({ onStepClick, labels, participant_data, local_groups }) {
- const handle_next_step = () => {
- onStepClick(4);
-
- if (ContactDataValidator()) {
- onStepClick(4);
- }
- }
-
- return (
-
- );
-}
-
-export default SummaryContainer;
\ No newline at end of file
diff --git a/legacy/signup-main.jsx b/legacy/signup-main.jsx
deleted file mode 100644
index 420debd..0000000
--- a/legacy/signup-main.jsx
+++ /dev/null
@@ -1,267 +0,0 @@
-import React from 'react';
-import AgeContainer from './partials/age.jsx';
-import ContactPersonContainer from './partials/contactperson.jsx';
-import PersonalDataContainer from './partials/personaldata.jsx';
-import SolidarityRegistrationContainer from './partials/registration-solidarity.jsx';
-import GroupSelectionContainer from './partials/registration-groupbased.jsx';
-import ArrivalContainer from './partials/arrival.jsx';
-import AddonsContainer from "./partials/addons.jsx";
-import PhotopermissionsContainer from "./partials/photopermissions.jsx";
-import AllergiesContainer from "./partials/allergies.jsx";
-import SummaryContainer from "./partials/summary.jsx";
-import { FinalValidator } from '../../../assets/javascripts/registration-validator.js'
-import { SelectedAddons } from '../../../assets/javascripts/registration-validator.js'
-import SuccessContainer from "./after-submit/success.jsx";
-import ReactDOM from "react-dom/client";
-import AlreadyExistsContainer from "./after-submit/alreadyexist.jsx";
-import { __ } from '../../../assets/javascripts/library.js';
-
-const { configuration, labels, participant_data, event_data, local_groups } = window.solea_data;
-
-function showStep(step) {
- var steps = [
- 'step_1', // Age-Selector
- 'step_2', // Children only: Contact data
- 'step_3', // Personal data
- 'step_4', // Participation group
- 'step_5', // Arival & Departure
- 'step_6', // Addon information
- 'step_7', // Photo-Permissions
- 'step_8', // Allergies & Intolerances
- 'step_9' // Summary
- ];
-
- for (var idx = 0; idx < steps.length; idx++) {
- var currentElement = steps[idx];
- document.getElementById(currentElement).classList.add('container_hidden');
- document.getElementById(currentElement).classList.remove('container_visible');
- }
-
- document.getElementById('step_' + step).classList.remove('container_hidden');
- document.getElementById('step_' + step).classList.add('container_visible');
-
- document.getElementById('summary_loading').classList.remove('container_hidden');
- document.getElementById('summary_loading').classList.add('container_visible');
- document.getElementById('summary_content').classList.add('container_hidden');
- document.getElementById('summary_content').classList.remove('container_visible');
-
- if (step === 9) {
- var [ayear, amonth, aday] = document.getElementById('anreise').value.split('-');
- var [dyear, dmonth, dday] = document.getElementById('abreise').value.split('-');
-
- document.getElementById('summary_eventname').innerHTML= event_data.event_name;
- document.getElementById('summary_arrival').innerHTML=`${aday}.${amonth}.${ayear}`;
- document.getElementById('summary_departure').innerHTML=`${dday}.${dmonth}.${dyear}`;
-
- const response = fetch("/wp-json/solea/signup/preview_amount", {
- method: "POST",
- headers: {
- "Content-Type": "application/json",
- },
- body: JSON.stringify({
- anreise: document.getElementById('anreise').value,
- abreise: document.getElementById('abreise').value,
- event_id: event_data.id,
- participation_group: document.querySelector('input[name="participant_group"]:checked').value,
- selected_amount: document.querySelector('input[name="beitrag"]:checked').value,
- addons: SelectedAddons(),
- }),
- })
- .then((res) => res.json())
- .then((data) => {
- document.getElementById('payment_information_label').innerHTML = data.amount
- document.getElementById('summary_loading').classList.add('container_hidden');
- document.getElementById('summary_loading').classList.remove('container_visible');
-
- document.getElementById('summary_content').classList.add('container_visible');
- document.getElementById('summary_content').classList.remove('container_hidden');
- });
- }
-}
-
-function ParticipantSignup() {
- let RegistrationMode;
-
- switch (event_data.registration_mode) {
- case 'solidarity':
- RegistrationMode = SolidarityRegistrationContainer;
- break;
-
- case 'groupbased':
- RegistrationMode = GroupSelectionContainer;
- break;
- }
-
- const handleSubmit = (e) => {
- e.preventDefault();
- const form = e.target;
- const data = new FormData(form);
-
- if (!FinalValidator()) {
- return;
- }
-
- const formData = Object.fromEntries(data.entries());
- const response = fetch("/wp-json/solea/signup/do-register", {
- method: "POST",
- headers: {
- "Content-Type": "application/json",
- },
- body: JSON.stringify({
- addons: SelectedAddons(),
- registration_data: formData
- })
- })
- .then((res) => res.json())
- .then((data) => {
- const container = document.getElementById('solea_registration_form_frame');
- const root = ReactDOM.createRoot(container);
-
- if (data.already_exists === true) {
- root.render( );
- } else {
- root.render( );
- }
- });
- }
-
- return (
-
-
- );
-}
-
-export default ParticipantSignup;
\ No newline at end of file