Changeset - 41ba224759b8
[Not reviewed]
0 3 0
Christopher Neugebauer - 7 years ago 2017-10-02 23:29:40
chrisjrn@gmail.com
Adds special login link for buy_tickets that displays an message
3 files changed with 14 insertions and 3 deletions:
0 comments (0 inline, 0 general)
pinaxcon/templates/static_pages/attend/attend.html
Show inline comments
 
{% extends "page_with_title_and_lede.html" %}
 

	
 
{% load i18n %}
 
{% load markdown_deux_tags %}
 

	
 
{% block head_title %}Attend{% endblock %}
 

	
 
{% block heading %}Come to North Bay Python!{% endblock %}
 

	
 
{% block body_class %}attend{% endblock %}
 

	
 
{% block lede %}
 
  P-Town. Rivertown. That place where the cows are. No matter that you call Petaluma, we want you to join us here for a great weekend of Python talks and networking. North Bay Python tickets start at $25 for unaffiliated individuals, and $180 for corporate attendees.
 
{% endblock %}
 

	
 

	
 
{% block content %}
 

	
 
<p>To buy a ticket, <a href="/dashboard">create an account, and go to the dashboard</a>. If you've already bought a ticket, you can check out our information on <a href="/attend/hotels">where to stay</a> if you want to come up for the weekend, and <a href="/attend/travel">how to get here</a>.</p>
 

	
 
<br />
 

	
 
<div class="pull-right"><a class="btn btn-lg btn-primary" href="/dashboard">Buy a Ticket</a></div>
 
<div class="pull-right"><a class="btn btn-lg btn-primary" href="/tickets/buy">Buy a Ticket</a></div>
 
<h2>Which Ticket?</h2>
 

	
 
<p><em>Early Bird discounts are available for the first 100 tickets sold, or until October 20, whichever comes first. T-shirts are only available for tickets bought before November 7.</em></p>
 

	
 
<h3>Corporate <small>$200 ($180 Early Bird)</small></h3>
 

	
 
<p><strong>For company employees, and individuals who can legitimately claim the cost of attending the conference as a business expense or a tax deduction</strong>.</p>
 

	
 
<p>Includes a free t-shirt, and recognition of your affiliation on your conference badge and on the conference supporters list. Group discounts are available for organizations that buy 5 or more tickets.</p>
 

	
 
<h3>Individual Supporter <small>$100 ($80 Early Bird)</small></h3>
 

	
 
<p><strong>For individuals who want to financially contribute to the success of the conference.</strong></p>
 

	
 
<p>This ticket includes a free t-shirt, and recognition of your Free and Open Source Software, hobby, or nonprofit project on your conference badge.</p>
 

	
 
<h3>Unaffiliated Individual <small>$50 ($25 Early Bird)</small></h3>
 

	
 
<p><strong>For students, hobbyists, and unemployed/underemployed people who are coming to North Bay Python at their own expense.</strong></p>
 

	
 
<p>The cheapest ticket we can offer. You can add a t-shirt for $30.</p>
 

	
 

	
 
<h3>Special Tickets</h3>
...
 
@@ -80,49 +80,49 @@
 
  <td>  Yes </td><td>  Yes </td><td>  Yes </td><td>  Yes </td></tr>
 
<tr>
 
  <th>Morning refreshments</th>
 
  <td> TBA </td><td> TBA </td><td> TBA </td><td> TBA </td></tr>
 
<tr>
 
  <th>Free Lunch</th>
 
  <td> No </td><td> No </td><td> No </td><td> No </td></tr>
 
<tr>
 
  <th>T-Shirt</th>
 
  <td>$30 each</td><td>1 free</br>Extras $30 each</td><td>1 free</br>Extras $30 each</td><td>1 free</br>Extras $30 each</td></tr>
 
<tr>
 
  <th>Affiliation on your badge</th>
 
  <td> No </td><td>Personal projects only</td><td> Yes </td><td>Yes</td></tr>
 
<tr>
 
  <th>Supporter recognition</th>
 
  <td> None </td><td>For you </td><td>For you and your company </td><td>Top billing for you and your company or project</td></tr>
 
<tr>
 
  <th>Sponsor benefits</th>
 
  <td> No </td><td>No</td><td> No </td><td>Yes</td></tr>
 
</table>
 

	
 
<p>If you can’t afford to attend on these prices, please email <a href="mailto:spam@northbaypthon.org">spam@northbaypython.org</a> – we’ll enthusiastically waive ticket fees for people who need it.</em></p>
 

	
 
<div class="btn-group">
 
  <a class="btn btn-lg btn-primary" href="/dashboard">Buy a Ticket</a>
 
  <a class="btn btn-lg btn-primary" href="/tickets/buy">Buy a Ticket</a>
 
</div>
 

	
 

	
 
<h2>Benefits</h2>
 

	
 
<h3>Conference access</h3>
 
<p>Two days of high-caliber talks about Python, and meeting new Pythonistas at North Bay Python.</p>
 

	
 
<h3>Lunch</h3>
 
<p>In order to keep ticket costs as low as possible, we won’t be catering lunch this year.</p>
 

	
 
<p>To make up for it, we’ve located our conference right in the middle of Historic Downtown Petaluma’s restaurant district. You can find everything from market delis and barbecue, through to Michelin-rated restaurants, all within 5 minutes walk. You’ll get a better lunch than we’d ever be able to cater, for much less. We'll have a locals' guide to Petaluma to help you find places to eat.</p>
 

	
 
<h3>Morning Refreshments (TBA)</h3>
 
<p>If budget permits, or if we find a sponsor, we’ll provide coffee, tea, hot chocolate, and some light snacks in the morning before proceedings kick off on both days.</p>
 

	
 
<h3>T-Shirt</h3>
 
<p>We’ll be designing a collectible North Bay Python t-shirt for you to pick up at the conference, and they’ll be available in a variety of cuts and colors. Each t-shirt costs $30, and for supporter, corporate, and sponsor ticket holders, you’ll get your first t-shirt free!</p>
 

	
 
<p>T-shirts are available only for tickets purchased by Tuesday 7 November.</p>
 

	
 

	
 
<h3>Affiliation</h3>
 
<p>Every attendee gets their very own lanyard and a badge with their name on it. As a paying ticket holder, you’ll get your project’s name (supporter and above) or company name (corporate or sponsor levels only) on your badge, just below your name.</p>
pinaxcon/urls.py
Show inline comments
...
 
@@ -10,48 +10,49 @@ from django.contrib import admin
 
from pinaxcon import views
 

	
 
import symposion.views
 

	
 

	
 
urlpatterns = [
 
    url(r"^$", TemplateView.as_view(template_name="static_pages/homepage.html"), name="home"),
 

	
 
    # about
 
    url(r"^about/north-bay-python$", TemplateView.as_view(template_name="static_pages/about/north_bay_python.html"), name="about/north-bay-python"),
 
    url(r"^about/petaluma$", TemplateView.as_view(template_name="static_pages/about/petaluma.html"), name="about/petaluma"),
 
    url(r"^about/team$", TemplateView.as_view(template_name="static_pages/about/team.html"), name="about/team"),
 
    url(r"^about/colophon$", TemplateView.as_view(template_name="static_pages/about/colophon.html"), name="about/colophon"),
 

	
 
    # program
 
    url(r"^program/events$", TemplateView.as_view(template_name="static_pages/program/events.html"), name="program/events"),
 
    url(r"^program/call-for-proposals$", TemplateView.as_view(template_name="static_pages/program/call_for_proposals.html"), name="program/call-for-proposals"),
 
    url(r"^program/selection-process$", TemplateView.as_view(template_name="static_pages/program/selection_process.html"), name="program/selection-process"),
 
    url(r"^proposals$", RedirectView.as_view(url="program/call-for-proposals")),
 
    url(r"^cfp$", RedirectView.as_view(url="program/call-for-proposals")),
 

	
 
    # attend
 
    url(r"^attend$", TemplateView.as_view(template_name="static_pages/attend/attend.html"), name="attend/attend"),
 
    url(r"^tickets$", RedirectView.as_view(url="attend")),
 
    url(r"^tickets/buy$", views.buy_ticket, name="buy_ticket"),
 
    url(r"^attend/business-case$", TemplateView.as_view(template_name="static_pages/attend/business-case.html"), name="attend/business-case"),
 
    url(r"^attend/travel$", TemplateView.as_view(template_name="static_pages/attend/travel.html"), name="attend/travel"),
 
    url(r"^attend/hotels$", TemplateView.as_view(template_name="static_pages/attend/hotels.html"), name="attend/hotels"),
 

	
 
    url(r"^code-of-conduct$", TemplateView.as_view(template_name="static_pages/code_of_conduct/code_of_conduct.html"), name="code-of-conduct"),
 
    url(r"^code-of-conduct/harassment-incidents$", TemplateView.as_view(template_name="static_pages/code_of_conduct/harassment_procedure_attendee.html"), name="code-of-conduct/harassment-incidents"),
 
    url(r"^code-of-conduct/harassment-staff-procedures$", TemplateView.as_view(template_name="static_pages/code_of_conduct/harassment_procedure_staff.html"), name="code-of-conduct/harassment-staff-procedures"),
 
    url(r"^terms-and-conditions$", TemplateView.as_view(template_name="static_pages/terms_and_conditions.html"), name="terms-and-conditions"),
 
    url(r"^terms$", RedirectView.as_view(url="terms-and-conditions")),
 

	
 
    # sponsor
 
    url(r"^sponsors/prospectus$", RedirectView.as_view(url=_static("assets/northbaypython_prospectus.pdf")), name="sponsors/prospectus"),
 
    url(r"^northbaypython_prospectus.pdf$", RedirectView.as_view(url=_static("assets/northbaypython_prospectus.pdf")), name="northbaypython_prospectus.pdf"),
 
    url(r"^sponsors/become-a-sponsor$", TemplateView.as_view(template_name="static_pages/sponsors/become_a_sponsor.html"), name="sponsors/become-a-sponsor"),
 
    url(r"^sponsors/donate$", TemplateView.as_view(template_name="static_pages/sponsors/donate.html"), name="sponsors/donate"),
 
    url(r"^donate$", RedirectView.as_view(url="sponsors/donate")),
 
    url(r"^about/donate$", RedirectView.as_view(url="sponsors/donate")),
 

	
 
    # news
 
    url(r"^news$", TemplateView.as_view(template_name="static_pages/news.html"), name="news"),
 

	
 
    # Django, Symposion, and Registrasion URLs
 

	
 
    url(r"^admin/", include(admin.site.urls)),
pinaxcon/views.py
Show inline comments
 
from django.conf import settings
 
from django.contrib import messages
 
from django.http import HttpResponseServerError
 
from django.shortcuts import render
 
from django.shortcuts import redirect, render
 
from django.template import RequestContext
 
from django.template import Template
 
from django.template.loader import get_template
 
from django.views import defaults
 

	
 
from account.forms import LoginEmailForm, LoginUsernameForm, SignupForm
 
from account.views import LoginView
 

	
 
def server_error(request, template_name=defaults.ERROR_500_TEMPLATE_NAME):
 
    t = Template("{%% include '%s' %%}" % template_name)
 
    return HttpResponseServerError(t.render(RequestContext(request)))
 

	
 

	
 
def account_login(request):
 

	
 
    d = {
 
        "login_form": LoginEmailForm(),
 
        "signup_form": SignupForm(),
 
        "signup_open": getattr(settings, "ACCOUNT_OPEN_SIGNUP", True),
 
    }
 

	
 
    print d["signup_open"], settings.ACCOUNT_OPEN_SIGNUP
 
    return render(request, "account_login.html", d)
 

	
 

	
 
class EmailLoginView(LoginView):
 
    form_class = LoginEmailForm
 

	
 

	
 
def buy_ticket(request):
 

	
 
    print(dir(request.user))
 
    if not request.user.is_authenticated():
 
        messages.warning(request, 'To buy a ticket, either create an account, or log in.')
 

	
 
    return redirect("/dashboard")
0 comments (0 inline, 0 general)