|
| 1 | +{% extends "base.html" %} |
| 2 | +{% load static from staticfiles %} |
| 3 | +{% load crispy_forms_tags %} |
| 4 | +{% block title %}TrackIt | Checkout | Go PRO{% endblock %} |
| 5 | +{% block head %} |
| 6 | +<!-- Stripe JS --> |
| 7 | +<script type="text/javascript" src="https://js.stripe.com/v2/"></script> |
| 8 | +<script type="text/javascript"> |
| 9 | + //<![CDATA[ |
| 10 | + Stripe.publishableKey = '{{ publishable }}'; |
| 11 | + //]]> |
| 12 | +</script> |
| 13 | +<!-- Stripe JS --> |
| 14 | +<script type="text/javascript" src="{% static 'js/stripe.js' %}"></script> |
| 15 | +{% endblock head %} |
| 16 | +{% block page_heading %}<span class="material-icons"> |
| 17 | + shopping_cart |
| 18 | +</span> Checkout<br> |
| 19 | +<hr>{% endblock %} |
| 20 | +{% block container-class %}checkout-container{% endblock %} |
| 21 | +{% block content %} |
| 22 | +<div class="jumbotron mx-auto" style="max-width: 1200px;"> |
| 23 | + <div class="row"> |
| 24 | + <div class="col-12"> |
| 25 | + <h3>Go PRO</h3> |
| 26 | + <b>Includes:</b> |
| 27 | + <ul> |
| 28 | + <li>Unlimited Tickets/month</li> |
| 29 | + <li>KANBAN View</li> |
| 30 | + <li>24/7 Live Support</li> |
| 31 | + </ul> |
| 32 | + <p class="lead">Total Due: 9.90 EUR (Single Payment)</p> |
| 33 | + <!-- <p><span class="glyphicon glyphicon-euro" aria-hidden="true"></span>{{ total }}</p> --> |
| 34 | + <form role="form" method="post" id="payment-form" action="{% url 'checkout' %}" enctype="multipart/form-data"> |
| 35 | + {% csrf_token %} |
| 36 | + <div class="row"> |
| 37 | + <div id="credit-card-errors" style="display: none;"> |
| 38 | + <div id="alert-message block-message error" id="stripe-error-message"></div> |
| 39 | + </div> |
| 40 | + </div> |
| 41 | + <div class="row"> |
| 42 | + <div class="col-md-9 col-lg-6"> |
| 43 | + <legend>Your Details</legend> |
| 44 | + {{ order_form.full_name | as_crispy_field }} |
| 45 | + </div> |
| 46 | + </div> |
| 47 | + <div class="row"> |
| 48 | + <div class="col-md-9 col-lg-6"> |
| 49 | + {{ order_form.phone_number | as_crispy_field }} |
| 50 | + </div> |
| 51 | + </div> |
| 52 | + <div class="row"> |
| 53 | + <div class="col-md-12"> |
| 54 | + {{ order_form.street_address1 | as_crispy_field }} |
| 55 | + </div> |
| 56 | + <div class="col-md-12"> |
| 57 | + {{ order_form.street_address2 | as_crispy_field }} |
| 58 | + </div> |
| 59 | + <div class="col-md-6 col-lg-3"> |
| 60 | + {{ order_form.town_or_city | as_crispy_field }} |
| 61 | + </div> |
| 62 | + <div class="col-md-6 col-lg-3"> |
| 63 | + {{ order_form.county | as_crispy_field }} |
| 64 | + </div> |
| 65 | + </div> |
| 66 | + <div class="row"> |
| 67 | + <div class="col-md-6 col-lg-3"> |
| 68 | + {{ order_form.country | as_crispy_field }} |
| 69 | + </div> |
| 70 | + <div class="col-md-6 col-lg-3"> |
| 71 | + {{ order_form.postcode | as_crispy_field }} |
| 72 | + </div> |
| 73 | + </div> |
| 74 | + <div class="row"> |
| 75 | + <legend>Payment Details</legend> |
| 76 | + <div class="col-md-12 col-lg-6"> |
| 77 | + {{ payment_form.credit_card_number | as_crispy_field }} |
| 78 | + </div> |
| 79 | + </div> |
| 80 | + <div class="row"> |
| 81 | + <div class="col-6 col-lg-2"> |
| 82 | + {{ payment_form.expiry_month | as_crispy_field }} |
| 83 | + </div> |
| 84 | + <div class="col-6 col-lg-2"> |
| 85 | + {{ payment_form.expiry_year | as_crispy_field }} |
| 86 | + </div> |
| 87 | + <div class="col-6 col-lg-2"> |
| 88 | + {{ payment_form.cvv | as_crispy_field }} |
| 89 | + </div> |
| 90 | + </div> |
| 91 | + <hr> |
| 92 | + {{ payment_form.stripe_id | as_crispy_field }} |
| 93 | + <div class="col-md-12"> |
| 94 | + <input class=" btn btn-primary" id="submit_payment_btn" name="commit" type="submit" |
| 95 | + value="Submit Payment"> |
| 96 | + <a href="{% url 'tickets' %}" class="float-right">Cancel</a> |
| 97 | + </div> |
| 98 | + </div> |
| 99 | + </form> |
| 100 | + </div> |
| 101 | +</div> |
| 102 | +</div> |
| 103 | +{% endblock %} |
0 commit comments