bornhack-website/src/tickets/templates/pdf/ticket.html

66 lines
1.5 KiB
HTML

{% load static from staticfiles %}
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<table style="width:100%;">
<tr>
<td style="width: 75%;">&nbsp;</td>
<td>
<h3>
{{ ticket.created|date:"b jS, Y" }}<br>
</h3>
</td>
</tr>
</table>
<br>
<h2>{{ ticket.ticket_type.camp.title }} Ticket</h2>
<h3>Type: {{ ticket.ticket_type.name }}</h3>
<h3>Product: {{ ticket.product.name }}</h3>
{% if quantity %}
<h3>Quantity: {{ quantity }}</h3>
{% endif %}
{% if ticket.name %}
<h3>Participant: {{ ticket.name }}</h3>
<br>
{% elif ticket.order.user.email %}
<h3>Participant: {{ ticket.order.user.email }}</h3>
<br>
{% elif ticket.sponsor %}
<h3>Sponsor: {{ ticket.sponsor.name }} </h3>
<img src="{% static 'img/sponsors/' %}{{ sponsor.logo_filename }}"></img>
{% endif %}
{% if ticket.used %}
<h2>This ticket has been used.</h2>
{% endif %}
<center>
<img src="{{ ticket.get_qr_code_url }}"></img>
<p>{{ ticket.token }}</p>
</center>
{% if ticket.ticket_type.includes_badge %}
<div style="display:block; clear:both; page-break-after:always;"></div>
<table style="width:100%;">
<tr>
<td style="width: 75%;">&nbsp;</td>
<td>
<h3>
{{ ticket.created|date:"b jS, Y" }}<br>
</h3>
</td>
</tr>
</table>
<br />
<h2>Badge voucher</h2>
<center>
<img src="{{ ticket.get_qr_badge_code_url }}"></img>
<p>{{ ticket.badge_token }}</p>
</center>
{% endif %}