-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #454 from magfest/super2025
Merge Super 2025 to main branch
- Loading branch information
Showing
30 changed files
with
353 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
ARG BRANCH=main | ||
ARG BRANCH=super2025 | ||
FROM ghcr.io/magfest/ubersystem:${BRANCH} | ||
ENV uber_plugins=["magprime"] | ||
|
||
|
74 changes: 74 additions & 0 deletions
74
alembic/versions/3b1f31ec9f24_add_external_sync_created_and_last_.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
"""Add external sync, created, and last updated columns to magprime tables | ||
Revision ID: 3b1f31ec9f24 | ||
Revises: 0173330bfb6e | ||
Create Date: 2024-08-01 02:30:54.112080 | ||
""" | ||
|
||
|
||
# revision identifiers, used by Alembic. | ||
revision = '3b1f31ec9f24' | ||
down_revision = '0173330bfb6e' | ||
branch_labels = None | ||
depends_on = None | ||
|
||
from alembic import op | ||
import sqlalchemy as sa | ||
from sqlalchemy.dialects import postgresql | ||
import residue | ||
|
||
|
||
try: | ||
is_sqlite = op.get_context().dialect.name == 'sqlite' | ||
except Exception: | ||
is_sqlite = False | ||
|
||
if is_sqlite: | ||
op.get_context().connection.execute('PRAGMA foreign_keys=ON;') | ||
utcnow_server_default = "(datetime('now', 'utc'))" | ||
else: | ||
utcnow_server_default = "timezone('utc', current_timestamp)" | ||
|
||
def sqlite_column_reflect_listener(inspector, table, column_info): | ||
"""Adds parenthesis around SQLite datetime defaults for utcnow.""" | ||
if column_info['default'] == "datetime('now', 'utc')": | ||
column_info['default'] = utcnow_server_default | ||
|
||
sqlite_reflect_kwargs = { | ||
'listeners': [('column_reflect', sqlite_column_reflect_listener)] | ||
} | ||
|
||
# =========================================================================== | ||
# HOWTO: Handle alter statements in SQLite | ||
# | ||
# def upgrade(): | ||
# if is_sqlite: | ||
# with op.batch_alter_table('table_name', reflect_kwargs=sqlite_reflect_kwargs) as batch_op: | ||
# batch_op.alter_column('column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# else: | ||
# op.alter_column('table_name', 'column_name', type_=sa.Unicode(), server_default='', nullable=False) | ||
# | ||
# =========================================================================== | ||
|
||
|
||
def upgrade(): | ||
op.add_column('prev_season_supporter', sa.Column('created', residue.UTCDateTime(), server_default=sa.text("timezone('utc', current_timestamp)"), nullable=False)) | ||
op.add_column('prev_season_supporter', sa.Column('last_updated', residue.UTCDateTime(), server_default=sa.text("timezone('utc', current_timestamp)"), nullable=False)) | ||
op.add_column('prev_season_supporter', sa.Column('external_id', postgresql.JSONB(astext_type=sa.Text()), server_default='{}', nullable=False)) | ||
op.add_column('prev_season_supporter', sa.Column('last_synced', postgresql.JSONB(astext_type=sa.Text()), server_default='{}', nullable=False)) | ||
op.add_column('season_pass_ticket', sa.Column('created', residue.UTCDateTime(), server_default=sa.text("timezone('utc', current_timestamp)"), nullable=False)) | ||
op.add_column('season_pass_ticket', sa.Column('last_updated', residue.UTCDateTime(), server_default=sa.text("timezone('utc', current_timestamp)"), nullable=False)) | ||
op.add_column('season_pass_ticket', sa.Column('external_id', postgresql.JSONB(astext_type=sa.Text()), server_default='{}', nullable=False)) | ||
op.add_column('season_pass_ticket', sa.Column('last_synced', postgresql.JSONB(astext_type=sa.Text()), server_default='{}', nullable=False)) | ||
|
||
|
||
def downgrade(): | ||
op.drop_column('season_pass_ticket', 'last_synced') | ||
op.drop_column('season_pass_ticket', 'external_id') | ||
op.drop_column('season_pass_ticket', 'last_updated') | ||
op.drop_column('season_pass_ticket', 'created') | ||
op.drop_column('prev_season_supporter', 'last_synced') | ||
op.drop_column('prev_season_supporter', 'external_id') | ||
op.drop_column('prev_season_supporter', 'last_updated') | ||
op.drop_column('prev_season_supporter', 'created') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
magprime/templates/emails/reg_workflow/group_confirmation.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
<html> | ||
<head></head> | ||
<body> | ||
|
||
Your {{ group.is_dealer|yesno(c.DEALER_REG_TERM + ",group") }} ({{ group.name }}) has been preregistered for | ||
{{ c.EVENT_NAME }} this coming {{ event_dates() }} and your payment of {{ (group.amount_paid / 100)|format_currency }} has been received. | ||
|
||
{% if group.unregistered_badges %} | ||
<br/> <br/> | ||
Some of your badges are not yet assigned to a specific person. If you assign these badges | ||
now then it will take much less time for their owners to pick them up at the event. Preassigning | ||
badges also allows individual members of your group to preorder merch or donate | ||
extra money. You may preassign your badges on your | ||
<a href="{{ c.URL_BASE }}/preregistration/group_members?id={{ group.id }}">group management page</a>. | ||
The individual registration links on the group management page can be filled out by you, or distributed | ||
to your group members for them to fill out themselves. | ||
|
||
<b>Your</b> registration confirmation number is {{ group.leader_id }}, and you can update your information, preorder merch, | ||
or donate extra money <a href="{{ c.URL_BASE }}/preregistration/confirm?id={{ group.leader_id }}">here</a>. | ||
|
||
{% if not group.is_dealer %} | ||
<br/> <br/> | ||
Please email your {{ c.EVENT_NAME }} contact regarding adding badges to your group. You may be asked to pay for the extra badges after the badges are added. | ||
{% endif %} | ||
{% endif %} | ||
|
||
{% if c.CONSENT_FORM_URL and group.leader.age_group_conf['consent_form'] %} | ||
<br/> <br/> | ||
Because you are under 18, you must bring a <a href="{{ c.CONSENT_FORM_URL }}">signed parental | ||
consent form</a> to be granted admission to {{ c.EVENT_NAME }}. | ||
<br/> <br/> | ||
If you are over 18, update your date of birth on your | ||
<a href="{{ c.URL_BASE }}/preregistration/confirm?id={{ group.leader.id }}">badge confirmation page</a>. | ||
{% endif %} | ||
|
||
<br/> <br/> | ||
Badges are not mailed out before the event, so your group members may pick up their badge at Registration | ||
when they arrive at {{ c.EVENT_NAME }}. Inform your group to bring a photo ID{{ c.EXTRA_CHECKIN_DOCS }} to Registration, | ||
where they'll be provided with their badge. If anyone in your group pre-ordered a t-shirt or other merch package, | ||
they can pick those up at our merchandise booth. The location and | ||
hours of Registration and merchandise booth will be emailed prior to the event. | ||
<br/> <br/> | ||
You can always <a href="{{ c.URL_BASE }}/preregistration/group_members?id={{ group.id }}">use this link</a> to manage your group. | ||
|
||
</body> | ||
</html> |
32 changes: 32 additions & 0 deletions
32
magprime/templates/emails/reg_workflow/promo_code_group_confirmation.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<html> | ||
<head></head> | ||
<body> | ||
|
||
You have successfully registered group "{{ group.name }}" for {{ c.EVENT_NAME }} this coming {{ event_dates() }} and your payment of {{ (group.buyer.amount_paid / 100)|format_currency }} has been received. Your group has {{ group.promo_codes|length|int + 1 }} badges, including your own. | ||
|
||
<br/><br/> | ||
Group badges are allocated using promo codes: your group members will simply enter a promo code <a href="{{ c.URL_BASE }}/preregistration/">while preregistering</a> to claim a badge in your group. | ||
You can either allocate specific promo codes for each group member using your <a href="{{ c.URL_BASE }}/preregistration/group_promo_codes?id={{ group.id }}">group management page</a> or distribute your group's universal promo code ("{{ group.code }}"), which will let people claim badges in your group until it has no more available badges. | ||
|
||
<br/><br/> | ||
You may edit your own registration <a href="{{ c.URL_BASE }}/preregistration/confirm?id={{ group.buyer.id }}">here</a>. | ||
|
||
{% if c.CONSENT_FORM_URL and group.buyer.age_group_conf['consent_form'] %} | ||
<br/> <br/> | ||
Because you are under 18, you must bring a <a href="{{ c.CONSENT_FORM_URL }}">signed parental | ||
consent form</a> to be granted admission to {{ c.EVENT_NAME }}. | ||
<br/> <br/> | ||
If you are over 18, update your date of birth on your | ||
<a href="{{ c.URL_BASE }}/preregistration/confirm?id={{ group.leader.id }}">badge confirmation page</a>. | ||
{% endif %} | ||
|
||
<br/> <br/> | ||
Badges are not mailed out before the event, so your group members may pick up their badge at Registration when they arrive | ||
at {{ c.EVENT_NAME }}. Inform your group to bring a photo ID{{ c.EXTRA_CHECKIN_DOCS }} to Registration, | ||
where they'll be provided with their badge. If anyone in your group pre-orders a t-shirt or other merch package, | ||
they can pick those up at our merchandise booth. The location and | ||
hours of Registration and merchandise booth will be emailed prior to the event. | ||
<br/> <br/> | ||
|
||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
{% if attendee.staffing and not attendee.assigned_depts %} | ||
<br><br> | ||
Thanks for your interest in volunteering! | ||
{% if attendee.paid == c.HAS_PAID %} | ||
Now that we've received your payment | ||
{% elif attendee.paid == c.PAID_BY_GROUP %} | ||
As soon as we get a chance, | ||
{% else %} | ||
After we receive your payment | ||
{% endif %} | ||
we will review your request to volunteer at {{ c.EVENT_NAME }}. If you are selected, we will email further | ||
instructions about your department assignment and how to sign up for shifts. | ||
{% endif %} | ||
|
||
{% if c.CONSENT_FORM_URL and attendee.age_group_conf['consent_form'] %} | ||
<br><br> | ||
Our records indicate that you are under the age of 18, and as such, you | ||
will need a signed parental consent form. If a parent/legal guardian will | ||
be present at {{ c.EVENT_NAME }}, then they can sign the consent form when | ||
you pick up your badge at Registration in Expo Hall E. If a parent/legal | ||
guardian will not be at the event, the form may be brought pre-signed. | ||
You may find the form <a href="{{ c.CONSENT_FORM_URL }}">by clicking here</a>. | ||
<br><br> | ||
If you are actually over 18, please update your age in our | ||
<a href="{{ c.URL_BASE }}/preregistration/confirm?id={{ attendee.id }}">database here</a> | ||
prior to picking up your badge. | ||
{% endif %} | ||
|
||
{% if c.CODE_OF_CONDUCT_URL %} | ||
<br><br> | ||
Registered attendees agree to the <a href="{{ c.CODE_OF_CONDUCT_URL }}">{{ c.EVENT_NAME }} code of conduct</a> by picking up their badge. | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
{{ attendee.first_name }}, | ||
|
||
Thanks for pre-registering for {{ c.EVENT_NAME }}. Our records indicate that you are under the age of 18, and as such, you will need a signed parental consent form. If a parent/legal guardian will be present at {{ c.EVENT_NAME }}, then they can sign the consent form when you pick up your badge at the registration desk. If a parent/legal guardian will not be at the event, the form may be brought pre-signed. You may find the form at {{ c.CONSENT_FORM_URL }}. | ||
|
||
If you are actually over 18, please update your age in our database at {{ c.URL_BASE }}/preregistration/confirm?id={{ attendee.id }} prior to picking up your badge. | ||
|
||
We look forward to seeing you at {{ c.EVENT_NAME_AND_YEAR }}! | ||
|
||
{{ c.REGDESK_EMAIL_SIGNATURE }} |
Oops, something went wrong.