From daaa555a72264c8f429fdb7d15793beee2163b66 Mon Sep 17 00:00:00 2001 From: Victoria Earl Date: Thu, 6 Jun 2024 12:58:17 -0400 Subject: [PATCH] Fix check-in form formatting --- magstock/forms.py | 9 ++++- .../forms/attendee/check_in_form.html | 24 ++++++++++++ .../templates/registration/check_in_form.html | 37 ------------------- 3 files changed, 32 insertions(+), 38 deletions(-) create mode 100644 magstock/templates/forms/attendee/check_in_form.html delete mode 100644 magstock/templates/registration/check_in_form.html diff --git a/magstock/forms.py b/magstock/forms.py index 278c9fa..e469857 100644 --- a/magstock/forms.py +++ b/magstock/forms.py @@ -127,4 +127,11 @@ class PreregOtherInfo: def staffing_label(self): return ("We already have enough volunteers to run MAGStock this year. If you'd like to be added " "to our waitlist, click here and indicate your areas of interest. If we can accommodate more " - "volunteers, Staffing Operations will reach out to you in mid-May") \ No newline at end of file + "volunteers, Staffing Operations will reach out to you in mid-May") + +@MagForm.form_mixin +class CheckInForm: + camping_type = HiddenField('Camping Type') + cabin_type = HiddenField('Cabin Type') + meal_plan = HiddenField('Meal Plan') + license_plate = PersonalInfo.license_plate diff --git a/magstock/templates/forms/attendee/check_in_form.html b/magstock/templates/forms/attendee/check_in_form.html new file mode 100644 index 0000000..f726aad --- /dev/null +++ b/magstock/templates/forms/attendee/check_in_form.html @@ -0,0 +1,24 @@ +{% extends 'uber/templates/forms/attendee/check_in_form.html' %} + +{% block merch %} +
+
{{ form_macros.form_input(check_in_form.camping_type, hidden_field_text=attendee.camping_type_label) }}
+ {% if attendee.camping_type == c.CABIN %} +
{{ form_macros.form_input(check_in_form.cabin_type, hidden_field_text=attendee.cabin_type_label) }}
+ {% endif %} +
{{ form_macros.form_input(check_in_form.meal_plan, hidden_field_text=attendee.meal_plan_label) }}
+ + {{ super() }} +
+{% endblock %} + +{% block editable %} +
+ {% if c.COLLECT_EXACT_BIRTHDATE %} +
+ {{ form_macros.form_input(check_in_form.birthdate) }} +
+ {% endif %} +
{{ form_macros.form_input(check_in_form.license_plate, help_text='The license plate # of the car they parked.') }}
+
+{% endblock %} \ No newline at end of file diff --git a/magstock/templates/registration/check_in_form.html b/magstock/templates/registration/check_in_form.html deleted file mode 100644 index 54adccd..0000000 --- a/magstock/templates/registration/check_in_form.html +++ /dev/null @@ -1,37 +0,0 @@ -{% extends "uber/templates/registration/check_in_form_base.html" %} -{% block checkin_fields %} -
- -
-
{{ attendee.amount_extra_label }} - {% if attendee.amount_extra >= c.SHIRT_LEVEL %} - (Shirt size: {{ attendee.shirt_label or 'Not Selected' }}) - {% endif %} -
-
-
- {{ super() }} -
- -
-
{{ attendee.camping_type_label }} - {% if attendee.camping_type == c.CABIN %} - ({{ attendee.cabin_type }}) - {% endif %} -
-
-
-
- -
-
{{ attendee.meal_plan_label }} -
-
-
-
- -
- -
-
-{% endblock checkin_fields %}