From 92af6f6cd78f16b9f1db0c7b8fc915ae35fda681 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=BCnther?= Date: Sat, 1 Jun 2024 11:16:07 +0200 Subject: [PATCH] Tribes now selectable on signup --- components/partials/date-element.php | 2 +- components/partials/text-element.php | 4 ++-- .../Templates/Partials/Registration/kontaktdaten.php | 6 +----- .../event-participants/Views/events-registration-form.php | 8 ++++++++ 4 files changed, 12 insertions(+), 8 deletions(-) diff --git a/components/partials/date-element.php b/components/partials/date-element.php index 1ef6425..38e5d89 100644 --- a/components/partials/date-element.php +++ b/components/partials/date-element.php @@ -1,6 +1,6 @@ '; + echo ''; if (defined('WP_DEBUG') && WP_DEBUG == true) { echo '
' . $settingName; } diff --git a/components/partials/text-element.php b/components/partials/text-element.php index 3aaebe2..5208401 100644 --- a/components/partials/text-element.php +++ b/components/partials/text-element.php @@ -1,9 +1,9 @@ '; + echo ''; } else { - echo ''; + echo ''; } if (null !== $appendix) { echo ' ' . $appendix; diff --git a/modules/event-participants/Templates/Partials/Registration/kontaktdaten.php b/modules/event-participants/Templates/Partials/Registration/kontaktdaten.php index e1898b8..5f1c925 100644 --- a/modules/event-participants/Templates/Partials/Registration/kontaktdaten.php +++ b/modules/event-participants/Templates/Partials/Registration/kontaktdaten.php @@ -18,11 +18,7 @@ Stamm / ABG: diff --git a/modules/event-participants/Views/events-registration-form.php b/modules/event-participants/Views/events-registration-form.php index d5a9fba..26c34c9 100644 --- a/modules/event-participants/Views/events-registration-form.php +++ b/modules/event-participants/Views/events-registration-form.php @@ -62,11 +62,19 @@ function registrationForm(int $eventId, string $targetPage) : string $registerForm ); + $tribes_array = unserialize($event->contributing_tribes); + $tribes = ''; + foreach ($tribes_array as $tribe) { + $tribes .= ''; + } + + $registerForm = str_replace('{{startdate}}', $event->startdatum, $registerForm); $registerForm = str_replace('{{enddate}}', $event->enddatum, $registerForm); $registerForm = str_replace('{{amount_reduced}}', $event->amount_reduced, $registerForm); $registerForm = str_replace('{{amount_default}}', $event->amount_default, $registerForm); $registerForm = str_replace('{{amount_social}}', $event->amount_social, $registerForm); + $registerForm = str_replace('{{beteiligte_gruppen}}', $tribes, $registerForm); $registerForm = str_replace('{{URL}}', $targetPage, $registerForm);