From ebc2a7857b17cbd433dde10cb1b68d4451777506 Mon Sep 17 00:00:00 2001 From: Victoria Earl Date: Sat, 24 Aug 2024 21:14:30 -0400 Subject: [PATCH] Update Music/Guest checklist for Super 2025 Replaces the travel step with a Google form link, and overrides relevant validations. --- magprime/model_checks.py | 17 +++++++- .../band_travel_plans_deadline.html | 11 ----- .../travel_plans_deadline.html | 41 +++++++++++++++++++ 3 files changed, 57 insertions(+), 12 deletions(-) delete mode 100644 magprime/templates/guest_checklist/band_travel_plans_deadline.html create mode 100644 magprime/templates/guest_checklist/travel_plans_deadline.html diff --git a/magprime/model_checks.py b/magprime/model_checks.py index f8cd383..07cd473 100644 --- a/magprime/model_checks.py +++ b/magprime/model_checks.py @@ -31,4 +31,19 @@ def address(attendee): if not attendee.region and attendee.country in ['United States', 'Canada']: return 'Please enter a state, province, or region.' if not attendee.country: - return 'Please enter a country.' \ No newline at end of file + return 'Please enter a country.' + + +@validation.GuestTravelPlans +def has_modes(guest_travel_plans): + return + + +@validation.GuestTravelPlans +def has_modes_text(guest_travel_plans): + return + + +@validation.GuestTravelPlans +def has_details(guest_travel_plans): + return \ No newline at end of file diff --git a/magprime/templates/guest_checklist/band_travel_plans_deadline.html b/magprime/templates/guest_checklist/band_travel_plans_deadline.html deleted file mode 100644 index 9b1c290..0000000 --- a/magprime/templates/guest_checklist/band_travel_plans_deadline.html +++ /dev/null @@ -1,11 +0,0 @@ -{% extends "uber/templates/guest_checklist/travel_plans_deadline.html" %} - -{% block deadline_text %} -{% if guest.travel_plans_status %} - You have already told us how you will be traveling to {{ c.EVENT_NAME }}, but you can use the link above to update your - preferences. -{% else %} - Use the link above to provide travel details so that our liaison team can coordinate with you on providing anything that - you may need to arrive at Super MAGFest. -{% endif %} -{% endblock %} diff --git a/magprime/templates/guest_checklist/travel_plans_deadline.html b/magprime/templates/guest_checklist/travel_plans_deadline.html new file mode 100644 index 0000000..805e3ea --- /dev/null +++ b/magprime/templates/guest_checklist/travel_plans_deadline.html @@ -0,0 +1,41 @@ +{% if snippet %} + + {{ macros.checklist_image(guest.travel_plans_status) }} + + {% block deadline_headline %}Travel Plans{% endblock %} + Deadline: {{ guest.deadline_from_model('travel_plans')|datetime_local }} + + + + {% block deadline_text %} + Please fill out a form so we are aware of your travel plans and can accommodate accordingly. + {% endblock %} +

+ + +{% else %} + +

{% block form_title %}Travel Plans for {{ guest.group.name }}{% endblock %}

+ + {% block form_desc %} + {% if guest.travel_plans_status %} + You've already indicated that you have completed our travel plans form. + If you need to update something, please contact us at {% if guest.group_type == c.BAND %}{{ c.BAND_EMAIL|email_only|email_to_link }}{% else %}{{ c.GUEST_EMAIL|email_only|email_to_link }}{% endif %}. + {% else %} + Please fill out this form so we know when/how to expect you! + {% endif %} + {% endblock %} +

+ + {% if guest.travel_plans_status %} + Back to Checklist + {% else %} +
+ + + {{ csrf_token() }} + {% block form_extra %}{% endblock %} + +
+ {% endif %} +{% endif %}