Skip to content

Commit

Permalink
Fix starting migrations
Browse files Browse the repository at this point in the history
The first migration for this plugin had a very early down_revision and the server was running them too early. This should hopefully fix that.

Also includes fixes for misspelling of "complimentary" and updates override templates to refer to the base plugin correctly.
  • Loading branch information
kitsuta committed Apr 3, 2024
1 parent 382fc8f commit 4fc4dd6
Show file tree
Hide file tree
Showing 20 changed files with 35 additions and 23 deletions.
4 changes: 2 additions & 2 deletions alembic/versions/e68ef1dc43fc_initial_migration.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
"""Initial migration
Revision ID: e68ef1dc43fc
Revises: 1ed43776064f
Revises: 691be8fa880d
Create Date: 2017-04-24 09:24:20.038755
"""


# revision identifiers, used by Alembic.
revision = 'e68ef1dc43fc'
down_revision = '1ed43776064f'
down_revision = '691be8fa880d'
branch_labels = ('magprime',)
depends_on = None

Expand Down
10 changes: 8 additions & 2 deletions magprime/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class TableInfo:
], description="Please enter the license number for your Maryland Traders or Sellers Permit.")

def get_optional_fields(self, group, is_admin=False):
optional_fields = self.super_get_optional_fields(group)
optional_fields = self.super_get_optional_fields(group, is_admin)

if not self.has_prior_name.data:
optional_fields.append("prior_name")
Expand All @@ -85,7 +85,13 @@ def get_optional_fields(self, group, is_admin=False):
def website_desc(self):
return Markup("The link to your main portfolio. Please include additional links to social media accounts or \
additional places to view your items in the <em>What do you sell?</em> box below.")



@MagForm.form_mixin
class PersonalInfo:
def onsite_contact_label(self):
return "MAGBuddy"


@MagForm.form_mixin
class BadgeExtras:
Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/dept_checklist/printed_signs.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Department Checklist - Room Signage{% endblock %}
{% block content %}
{% set item = department.checklist_item_for_slug('printed_signs') %}
Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/emails/placeholders/panelist.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{% if attendee.first_name %}{{ attendee.first_name }},

{% endif %}Thanks for coming out to {{ c.EVENT_NAME }} as a Panelist! We've added you to our registration database for your complementary badge, but we don't have all of your personal information. To ensure that you can pick up your badge with no hassles at our registration desk, please fill out the rest of your info at {{ c.URL_BASE }}/preregistration/confirm?id={{ attendee.id }} and then simply bring a photo ID to {{ c.EVENT_NAME }}.
{% endif %}Thanks for coming out to {{ c.EVENT_NAME }} as a Panelist! We've added you to our registration database for your complimentary badge, but we don't have all of your personal information. To ensure that you can pick up your badge with no hassles at our registration desk, please fill out the rest of your info at {{ c.URL_BASE }}/preregistration/confirm?id={{ attendee.id }} and then simply bring a photo ID to {{ c.EVENT_NAME }}.

Please let us know if you have any questions.

Expand Down
6 changes: 4 additions & 2 deletions magprime/templates/emails/reg_workflow/badge_transfer.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{{ old.first_name }} and {{ new.first_name }},

Our records indicate that {{ old.full_name }} ({{ old.email }}) has transferred their {{ c.EVENT_NAME }} {{ old.badge_type_label }} registration to {{ new.full_name }} ({{ new.email }}). So {{ old.full_name }} no longer has a paid registration, and {{ new.full_name }} should have no trouble picking up the badge at our registration desk.
Our records indicate that {{ old.full_name }} ({{ old.email }}) has transferred their {{ c.EVENT_NAME }} {{ old.badge_type_label }} registration to {{ new.full_name }} ({{ new.email }}). So {{ old.full_name }} no longer has a paid registration, and {{ new.full_name }} should have no trouble picking up the badge at our registration desk.
{% if include_link %}

If {{ new.full_name }} needs to add or update the information associated with their new badge, use this link: {{ c.URL_BASE }}/preregistration/confirm?id={{ new.id }}

Expand All @@ -10,7 +11,8 @@ Our records indicate that {{ new.full_name }} is under the age of 18, and as suc

If you are actually over 18, you can update your age in our database at {{ c.URL_BASE }}/preregistration/confirm?id={{ new.id }} before {{ c.UBER_TAKEDOWN|datetime_local }}.
{% endif %}
{% endif %}

If this has happened in error, please contact {{ c.REGDESK_EMAIL|safe }}. Otherwise we look forward to seeing {{ new.first_name }} on {{ event_dates() }}.
If this has happened in error, please contact {{ c.REGDESK_EMAIL|safe }}. Otherwise we look forward to seeing {{ new.first_name }} on {{ event_dates() }}.

{{ c.REGDESK_EMAIL_SIGNATURE }}
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

As part of your MAGFest Season Supporter package {% if attendee.is_attendee %}this year{% else %}last year{% endif %}, you are eligible for complimentary admission to all of {% if attendee.is_attendee %}this and next year's{% else %}this year's{% endif %} MAGFest events. Our next event is {{ event.name }}, and it's coming up on {{ event.day|datetime_local("%A, %b %e") }} at {{ event.location }}, which you can read more about at {{ event.url }}

To claim your complementary badge, just visit {{ c.URL_BASE }}/season_supporters/event?slug={{ event.slug }}&id={{ attendee.id }}
To claim your complimentary badge, just visit {{ c.URL_BASE }}/season_supporters/event?slug={{ event.slug }}&id={{ attendee.id }}

Remember that our events often sell out, so if you would like to attend this event, please RSVP no later than {{ event.deadline|datetime_local }} so that we can reserve a ticket for you. Please note that your complimentary pass is only valid for you, and is not transferrable. Thanks so much for your support, and we hope to see you there!

Expand Down
4 changes: 4 additions & 0 deletions magprime/templates/forms/attendee/other_info.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{% extends 'uber/templates/forms/attendee/other_info.html' %}

{% block accessibility %}
{% endblock %}
2 changes: 1 addition & 1 deletion magprime/templates/guest_checklist/band_bio_deadline.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "guest_checklist/bio_deadline.html" %}
{% extends "uber/templates/guest_checklist/bio_deadline.html" %}

{% block deadline_text %}
{% if guest.bio_status %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "guest_checklist/travel_plans_deadline.html" %}
{% extends "uber/templates/guest_checklist/travel_plans_deadline.html" %}

{% block deadline_text %}
{% if guest.travel_plans_status %}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "guest_checklist/merch_deadline.html" %}
{% extends "uber/templates/guest_checklist/merch_deadline.html" %}

{%- set HAS_ROCK_ISLAND = c.ROCK_ISLAND in c.GUEST_MERCHS and guest.group_type in c.ROCK_ISLAND_GROUPS -%}

Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/magprime_reports/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Invalid Volunteers{% endblock %}
{% block content %}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Special Merch Counts{% endblock %}
{% block content %}

Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/magprime_reports/volunteer_food.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Volunteers Needing Food{% endblock %}
{% block content %}

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "./preregistration/preregbase.html" %}
{% extends "uber/templates/preregistration/preregbase.html" %}
{% block title %}Marketplace Application Received{% endblock %}
{% block backlink %}{% endblock %}
{% block content %}
Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/registration/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "registration/index_base.html" %}
{% extends "uber/templates/registration/index_base.html" %}
{% block badge_counts %}
{{ super() }}
{% if c.CHILD_BADGE_STOCK %}<button class="badge_count btn" data-warning-threshold="100" data-danger-threshold="50">{{ c.CHILD_BADGE_STOCK - c.CHILD_BADGE_COUNT }} Child badges left</button>{% endif %}
Expand Down
4 changes: 2 additions & 2 deletions magprime/templates/season_supporters/event.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,14 @@
<body style="margin-left:20% ; margin-right:20%">
<h2>{{ event.name }}</h2>
{% if registered %}
You have successfully preregistered for your complementary, non-transferable ticket for
You have successfully preregistered for your complimentary, non-transferable ticket for
<a href="{{ event.url }}">{{ event.name }}</a>. We'll see you on {{ event.day|datetime_local("%A, %B %e") }}
at {{ event.location }}.
{% elif deadline_passed %}
Unfortunately, the deadline for registering for {{ event.name }} has passed, but we'll definitely
keep you informed about other events as they approach!
{% else %}
Your {{ c.EVENT_NAME }} Season Supporter registration makes you eligible for a complementary, non-transferable ticket for
Your {{ c.EVENT_NAME }} Season Supporter registration makes you eligible for a complimentary, non-transferable ticket for
<a href="{{ event.url }}">{{ event.name }}</a>, which is coming up on {{ event.day|datetime_local("%A, %B %e") }}
at {{ event.location }}.
To claim your ticket, just click the following button:
Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/season_supporters/index.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Season Pass Tickets{% endblock %}
{% block content %}

Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/season_supporters/prev_supporters.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Previous Supporters{% endblock %}
{% block content %}

Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/staffing/food_restrictions.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Dietary Restrictions{% endblock %}
{% block backlink %}{% endblock %}
{% block content %}
Expand Down
2 changes: 1 addition & 1 deletion magprime/templates/staffing/volunteer_agreement.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{% extends "base.html" %}{% set admin_area=True %}
{% extends "uber/templates/base.html" %}{% set admin_area=True %}
{% block title %}Volunteer Agreement{% endblock %}
{% block backlink %}{% endblock %}
{% block content %}
Expand Down

0 comments on commit 4fc4dd6

Please sign in to comment.