Added signals to extend the order detail page

This commit is contained in:
Raphael Michel
2016-07-11 19:46:26 +02:00
parent 10c18c5cc9
commit af8e017b07
3 changed files with 17 additions and 0 deletions

View File

@@ -37,6 +37,12 @@ There are multiple signals that will be sent out in the ordering cycle:
.. automodule:: pretix.base.signals .. automodule:: pretix.base.signals
:members: order_paid, order_placed :members: order_paid, order_placed
Sale flow
---------
.. automodule:: pretix.presale.signals
:members: order_info
Voucher system Voucher system
-------------- --------------

View File

@@ -36,3 +36,12 @@ This signal is sent out to display additional information on the "redeem a vouch
As with all plugin signals, the ``sender`` keyword argument will contain the event. As with all plugin signals, the ``sender`` keyword argument will contain the event.
""" """
order_info = EventPluginSignal(
providing_args=["order"]
)
"""
This signal is sent out to display additional information on the order detail page
As with all plugin signals, the ``sender`` keyword argument will contain the event.
"""

View File

@@ -1,6 +1,7 @@
{% extends "pretixpresale/event/base.html" %} {% extends "pretixpresale/event/base.html" %}
{% load i18n %} {% load i18n %}
{% load bootstrap3 %} {% load bootstrap3 %}
{% load eventsignal %}
{% load eventurl %} {% load eventurl %}
{% block title %}{% trans "Order details" %}{% endblock %} {% block title %}{% trans "Order details" %}{% endblock %}
{% block content %} {% block content %}
@@ -91,6 +92,7 @@
{% include "pretixpresale/event/fragment_cart.html" with cart=cart event=request.event editable=False %} {% include "pretixpresale/event/fragment_cart.html" with cart=cart event=request.event editable=False %}
</div> </div>
</div> </div>
{% eventsignal event "pretix.presale.signals.order_info" order=order %}
<div class="row"> <div class="row">
{% if invoices %} {% if invoices %}
<div class="col-xs-12 {% if request.event.settings.invoice_address_asked %}col-md-6{% endif %}"> <div class="col-xs-12 {% if request.event.settings.invoice_address_asked %}col-md-6{% endif %}">