From 539fa2dfdd2bb5308da9748a4f0af428a5da7f49 Mon Sep 17 00:00:00 2001
From: Joel Addison
Date: Wed, 2 Oct 2019 23:25:17 +1000
Subject: [PATCH] Finalise registration
Add shirt types and sizes. Improve messaging about discounts.
Restyle ticket wizard and product category screens. Enable page titles
and messages. Update dashboard to hide raffle.
Enable inventory population for dev container.
---
make_dev_container.sh | 2 +-
.../management/commands/populate_inventory.py | 39 ++++++++++---------
pinaxcon/settings.py | 22 +++++------
pinaxcon/templates/_form_snippet.html | 9 +++--
.../registrasion/_invoice_details.html | 9 ++---
pinaxcon/templates/registrasion/base.html | 16 +++++---
.../templates/registrasion/discount_list.html | 33 +++++++++++-----
.../registrasion/guided_registration.html | 39 ++++++++-----------
pinaxcon/templates/registrasion/invoice.html | 9 ++---
.../registrasion/product_category.html | 22 +++--------
pinaxcon/templates/registrasion/review.html | 29 +++++++-------
.../stripe/credit_card_payment.html | 2 +-
pinaxcon/templates/site_base.html | 12 +++---
.../symposion/dashboard/_categories.html | 11 ++++--
pinaxcon/templates/utility_page.html | 2 +-
pinaxcon/templatetags/lca2019_tags.py | 23 ++++++++++-
static/src/scss/app.scss | 9 ++++-
vendor/registrasion/registrasion/views.py | 4 +-
18 files changed, 165 insertions(+), 127 deletions(-)
diff --git a/make_dev_container.sh b/make_dev_container.sh
index 919b7d6a..4ed7cd61 100755
--- a/make_dev_container.sh
+++ b/make_dev_container.sh
@@ -21,7 +21,7 @@ docker exec symposion ./manage.py migrate
docker exec symposion ./manage.py loaddata ./fixtures/{conference,sites,sitetree,flatpages}.json
docker exec symposion ./manage.py create_review_permissions
docker exec symposion ./manage.py loaddata ./fixtures/????/*.json
-#docker exec symposion ./manage.py populate_inventory
+docker exec symposion ./manage.py populate_inventory
if [ -e ./symposion-tools ]; then
pushd ./symposion-tools
diff --git a/pinaxcon/registrasion/management/commands/populate_inventory.py b/pinaxcon/registrasion/management/commands/populate_inventory.py
index c0877d34..ec274571 100644
--- a/pinaxcon/registrasion/management/commands/populate_inventory.py
+++ b/pinaxcon/registrasion/management/commands/populate_inventory.py
@@ -61,7 +61,7 @@ class Command(BaseCommand):
name="Ticket",
description="Each type of ticket has different included products. "
"For details of what products are included, see our "
- "registration page",
+ "registration page.",
required=True,
render_type=inv.Category.RENDER_TYPE_RADIO,
limit_per_user=1,
@@ -101,13 +101,10 @@ class Command(BaseCommand):
name="Speakers' Dinner Ticket",
description="Tickets to our exclusive Speakers' Dinner on the "
"evening of "
- f"{settings.SPEAKER_DINNER_TICKET_DATE: %A %d %B}. "
- "You may purchase up "
- "to 5 tickets in total, for significant others and "
- "family members.",
+ f"{settings.SPEAKER_DINNER_TICKET_DATE: %A %d %B}.",
required=False,
render_type=inv.Category.RENDER_TYPE_QUANTITY,
- limit_per_user=5,
+ limit_per_user=1,
order=30,
)
self.pdns_category = self.find_or_make(
@@ -129,8 +126,10 @@ class Command(BaseCommand):
inv.Category,
("name",),
name="Shirt",
- description="Commemorative conference polo shirts, featuring the "
- f"linux.conf.au {settings.LCA_START.year} artwork.",
+ description="Commemorative conference shirts, featuring the "
+ f"linux.conf.au {settings.LCA_START.year} artwork. "
+ "View the "
+ "sizing guide.",
required=False,
render_type=inv.Category.RENDER_TYPE_ITEM_QUANTITY,
order=50,
@@ -355,13 +354,17 @@ class Command(BaseCommand):
# Shirts
ShirtGroup = namedtuple("ShirtGroup", ("prefix", "sizes"))
shirt_names = {
- "mens": ShirtGroup(
- "Men's/Straight Cut",
- ("S", "M", "L", "XL", "2XL", "3XL", "4XL"),
+ "straight": ShirtGroup(
+ "Straight Cut",
+ ("S", "M", "L", "XL", "2XL", "3XL", "4XL", "5XL"),
),
- "womens": ShirtGroup(
- "Women's Classic Fit",
- ("8", "10", "12", "14", "16", "18"),
+ "semi_fitted": ShirtGroup(
+ "Semi-Fitted",
+ ("XS", "S", "M", "L", "XL", "2XL"),
+ ),
+ "fitted": ShirtGroup(
+ "Fitted",
+ ("XS", "S", "M", "L", "XL", "2XL"),
),
}
@@ -463,7 +466,7 @@ class Command(BaseCommand):
volunteer_ticket_cap = self.find_or_make(
cond.TimeOrStockLimitFlag,
("description", ),
- description="Reserrved for volunteers and organizers",
+ description="Reserved for volunteers and organisers",
condition=cond.FlagBase.DISABLE_IF_FALSE,
limit=62,
)
@@ -563,14 +566,14 @@ class Command(BaseCommand):
speaker_tickets.proposal_kind.set(self.main_conference_proposals)
speaker_tickets.products.set([self.ticket_speaker, ])
- # Speaker dinner tickets are for primary and secondary speakers
+ # Speaker dinner tickets are for primary speakers only
speaker_dinner_tickets = self.find_or_make(
cond.SpeakerFlag,
("description", ),
description="Speaker dinner tickets",
condition=cond.FlagBase.ENABLE_IF_TRUE,
is_presenter=True,
- is_copresenter=True,
+ is_copresenter=False,
)
speaker_dinner_tickets.proposal_kind.set(self.main_conference_proposals)
speaker_dinner_tickets.categories.set([self.speakers_dinner_ticket, ])
@@ -767,7 +770,7 @@ class Command(BaseCommand):
ticket_staff_inclusions = self.find_or_make(
cond.IncludedProductDiscount,
("description", ),
- description="Complimentary for ticket holder staff)",
+ description="Complimentary for ticket holder (Staff)",
)
ticket_staff_inclusions.enabling_products.set([
self.ticket_team,
diff --git a/pinaxcon/settings.py b/pinaxcon/settings.py
index cc0c83f0..e3d62ad5 100644
--- a/pinaxcon/settings.py
+++ b/pinaxcon/settings.py
@@ -360,7 +360,7 @@ PROPOSAL_FORMS = {
# Registrasion bits:
ATTENDEE_PROFILE_MODEL = "pinaxcon.registrasion.models.AttendeeProfile"
ATTENDEE_PROFILE_FORM = "pinaxcon.registrasion.forms.ProfileForm"
-INVOICE_CURRENCY = "NZD"
+INVOICE_CURRENCY = "AUD"
TICKET_PRODUCT_CATEGORY = 1
TERMS_PRODUCT_CATEGORY = 2
ATTENDEE_PROFILE_FORM = "pinaxcon.registrasion.forms.ProfileForm"
@@ -546,14 +546,14 @@ SPEAKERS_DINNER_ADULT = SpeakersDinnerCat.create(
"Includes an adult's meal and full beverage service.",
timedelta(hours=1))
-SPEAKERS_DINNER_CHILD = SpeakersDinnerCat.create(
- "Child", Decimal("60.00"),
- "Children 14 and under. "
- "Includes a child's meal and soft drink service.",
- timedelta(hours=1))
+# SPEAKERS_DINNER_CHILD = SpeakersDinnerCat.create(
+# "Child", Decimal("60.00"),
+# "Children 14 and under. "
+# "Includes a child's meal and soft drink service.",
+# timedelta(hours=1))
-SPEAKERS_DINNER_INFANT = SpeakersDinnerCat.create(
- "Infant", Decimal("00.00"),
- "Infant must be seated in an adult's lap. "
- "No food or beverage service.",
- timedelta(hours=1))
+# SPEAKERS_DINNER_INFANT = SpeakersDinnerCat.create(
+# "Infant", Decimal("00.00"),
+# "Infant must be seated in an adult's lap. "
+# "No food or beverage service.",
+# timedelta(hours=1))
diff --git a/pinaxcon/templates/_form_snippet.html b/pinaxcon/templates/_form_snippet.html
index c0d40045..01609625 100644
--- a/pinaxcon/templates/_form_snippet.html
+++ b/pinaxcon/templates/_form_snippet.html
@@ -10,10 +10,13 @@
{% endif %}
+
{% if form|has_required_fields %}
-
- Fields marked with a * are required
-
+Fields marked with a * are required.
{% endif %}
+{% if form|has_price_fields %}
+Item prices are before any discount.
+{% endif %}
+
{{ form|crispy }}
diff --git a/pinaxcon/templates/registrasion/_invoice_details.html b/pinaxcon/templates/registrasion/_invoice_details.html
index aac6070e..51609ba7 100644
--- a/pinaxcon/templates/registrasion/_invoice_details.html
+++ b/pinaxcon/templates/registrasion/_invoice_details.html
@@ -3,10 +3,10 @@
Tax Invoice/Statement
Linux Australia
-GST #90-792-369
+ABN 56 987 117 479
- Enquiries: please e-mail contact@lca2019.org
+ Enquiries: please e-mail contact@lca2020.linux.org.au
@@ -23,7 +23,7 @@
{{ invoice.recipient|linebreaksbr}}
-This invoice has been issued as a result of an application to attend {% conference_name %}. All amounts are in New Zealand Dollars (NZD).
+This invoice has been issued as a result of an application to attend {% conference_name %}. All amounts are in Australian Dollars (AUD).
@@ -47,7 +47,7 @@
|
- Includes 15% New Zealand Goods and Services Tax |
+ Includes 10% Australian Goods and Services Tax |
${{ invoice.value|gst}} |
@@ -87,5 +87,4 @@
Sydney NSW 2001
Australia
ABN 56 987 117 479
- NZ GST #90-792-369
diff --git a/pinaxcon/templates/registrasion/base.html b/pinaxcon/templates/registrasion/base.html
index 999a0e9d..a83e70e7 100644
--- a/pinaxcon/templates/registrasion/base.html
+++ b/pinaxcon/templates/registrasion/base.html
@@ -1,9 +1,15 @@
-{% extends "utility_page.html" %}
+{% extends "site_base.html" %}
{% load staticfiles %}
+{% load lca2018_tags %}
+{% load i18n %}
+{% block head_title %}{% block page_title %}{% endblock %}{% endblock %}
-{% block utility_body %}
- {% block proposals_body %}
- {% endblock %}
+{% block content_base %}
+{% block content %}
+
+ {% block proposals_body %}
+ {% endblock %}
+
+{% endblock content %}
{% endblock %}
-
diff --git a/pinaxcon/templates/registrasion/discount_list.html b/pinaxcon/templates/registrasion/discount_list.html
index 441c6e70..41eeac06 100644
--- a/pinaxcon/templates/registrasion/discount_list.html
+++ b/pinaxcon/templates/registrasion/discount_list.html
@@ -1,16 +1,31 @@
{% if discounts %}
-
-
Discounts and Complimentary Items
-
The following discounts and complimentary items are available to you. If you wish to take advantage of this offer, you must choose your items below. The discounts will be applied automatically when you check out.
+
+
Discounts and Complimentary Items
+
The following discounts and complimentary items are available to you:
{% regroup discounts by discount.description as discounts_grouped %}
+
{% for discount_type in discounts_grouped %}
- {{ discount_type.grouper }}
-
- {% for discount in discount_type.list %}
- - {{ discount.quantity }} × {{ discount.clause }}
- {% endfor %}
-
+ -
+ {{ discount_type.grouper }}
+
+ {% for discount in discount_type.list %}
+ - {{ discount.quantity }} × {{ discount.clause }}
+ {% endfor %}
+
+
{% endfor %}
+
+
+
+ Please ensure you enter a value in the form below to take advantage of this discount.
+ The discounts will be applied automatically when you check out.
+
+
+
+
+ If you do not enter anything, you will not receive anything from this category.
+
+
{% endif %}
diff --git a/pinaxcon/templates/registrasion/guided_registration.html b/pinaxcon/templates/registrasion/guided_registration.html
index 93630c35..5900dd31 100644
--- a/pinaxcon/templates/registrasion/guided_registration.html
+++ b/pinaxcon/templates/registrasion/guided_registration.html
@@ -1,14 +1,14 @@
{% extends "registrasion/base.html" %}
{% load lca2018_tags %}
-{% block header_title %}Buy Your Ticket{% endblock %}
-{% block header_paragraph %}Step {{ current_step }} of {{ total_steps|add:1 }} – {{ title }} {% endblock %}
+{% block page_title %}Buy Your Ticket{% endblock %}
+{% block page_lead %}Step {{ current_step }} of {{ total_steps|add:1 }} – {{ title }} {% endblock %}
{% block scripts_extra %}
{% for section in sections %}
{{ section.form.media.js }}
{% endfor %}
-
-
+
{% endblock %}
{% block proposals_body %}
-
-
-
{% endblock %}
diff --git a/pinaxcon/templates/registrasion/invoice.html b/pinaxcon/templates/registrasion/invoice.html
index 3cfb62c0..dcd0a017 100644
--- a/pinaxcon/templates/registrasion/invoice.html
+++ b/pinaxcon/templates/registrasion/invoice.html
@@ -3,11 +3,12 @@
{% load lca2018_tags %}
{% load staticfiles %}
-{% block header_title %}{% conference_name %}{% endblock %}
+{% block head_title %}Tax Invoice/Statement #{{ invoice.id }}{% endblock %}
+{% block page_title %}{% conference_name %}{% endblock %}
{% block proposals_body %}
{% include "registrasion/_invoice_details.html" %}
-
+
-
-
{% endblock %}
diff --git a/pinaxcon/templates/registrasion/product_category.html b/pinaxcon/templates/registrasion/product_category.html
index 42b9c26e..df61fbfa 100644
--- a/pinaxcon/templates/registrasion/product_category.html
+++ b/pinaxcon/templates/registrasion/product_category.html
@@ -2,35 +2,26 @@
{% load registrasion_tags %}
{% load lca2018_tags %}
-{% block header_title %}Product Category: {{ category.name }}{% endblock %}
-{% block header_inset_image %}{% illustration "lavender.svg" %}{% endblock %}
+{% block page_title %}Product Category: {{ category.name }}{% endblock %}
{% block scripts_extra %}
{{ voucher_form.media.js }}
{{ form.media.js }}
-
-
{% endblock %}
{% block proposals_body %}
-
-
{% endblock %}
diff --git a/pinaxcon/templates/registrasion/review.html b/pinaxcon/templates/registrasion/review.html
index a8ced980..da2f5dbc 100644
--- a/pinaxcon/templates/registrasion/review.html
+++ b/pinaxcon/templates/registrasion/review.html
@@ -2,9 +2,8 @@
{% load registrasion_tags %}
{% load lca2018_tags %}
-{% block header_title %}Review your selection{% endblock %}
-{% block header_inset_image %}{% illustration "wineglass.svg" %}{% endblock %}
-{% block header_paragraph %}
+{% block page_title %}Review your selection{% endblock %}
+{% block page_lead %}
Please ensure that you have selected all of the products you require, including
t-shirts and social event tickets.
{% endblock %}
@@ -22,8 +21,7 @@
{% if pending %}
Current selection
-
You've selected the following items, which will be in your invoice when
- you check out:
+
You've selected the following items, which will be in your invoice when you check out:
{% include "registrasion/_items_list.html" with items=pending %}
{% endif %}
@@ -39,20 +37,22 @@
Modify your selection
-
+
{% missing_categories as missing %}
{% if missing %}
- You have not selected anything from the following
- categories. If your ticket includes any of these, you still need to
- make a selection:
-
+
+
You have empty categories
+
You have not selected anything from the following
+ categories. If your ticket includes any of these, you still need to
+ make a selection:
+
{% include "registrasion/_category_list.html" with categories=missing %}
- {% endif %}
-
+
+ {% endif %}
- You can also change your selection from these categories:
+ You can change your selection from these categories:
{% available_categories as available %}
{% include "registrasion/_category_list.html" with categories=available exclude=missing %}
@@ -64,7 +64,6 @@
-
What next?
{% if pending %}
@@ -88,6 +87,4 @@
{% endif %}
-
-
{% endblock %}
diff --git a/pinaxcon/templates/registrasion/stripe/credit_card_payment.html b/pinaxcon/templates/registrasion/stripe/credit_card_payment.html
index 4d5ff2b6..0317b36a 100644
--- a/pinaxcon/templates/registrasion/stripe/credit_card_payment.html
+++ b/pinaxcon/templates/registrasion/stripe/credit_card_payment.html
@@ -63,7 +63,7 @@
{% endblock %}
-{% block header_title %}Credit card payment for invoice #{{ invoice.id}}{% endblock %}
+{% block page_title %}Credit card payment for invoice #{{ invoice.id}}{% endblock %}
{% block proposals_body %}
diff --git a/pinaxcon/templates/site_base.html b/pinaxcon/templates/site_base.html
index b172663a..50ecb819 100644
--- a/pinaxcon/templates/site_base.html
+++ b/pinaxcon/templates/site_base.html
@@ -31,14 +31,14 @@
{% block template_overrides %}{% endblock %}
-
+
{% block alert %}{% endblock %}
{% block navbar %}{% include 'nav.html' %}{% endblock %}
{% if messages %}
-
+
{% for message in messages %}
- {{ message }}
{% endfor %}
@@ -47,11 +47,13 @@
{% endif %}
- {% block page_title %}{% endblock %}
+
{% block body_base %}
{% block body_out %}
-
{% block body_outer %}
@@ -98,7 +100,7 @@
{% endblock %}
-