forked from CGM_Public/pretix_original
Added voucher_redeem_info signal and improved signal documentation
This commit is contained in:
@@ -1,20 +1,38 @@
|
||||
from pretix.base.signals import EventPluginSignal
|
||||
|
||||
"""
|
||||
This signal is sent out to include code into the HTML <head> tag
|
||||
"""
|
||||
html_head = EventPluginSignal(
|
||||
providing_args=["request"]
|
||||
)
|
||||
"""
|
||||
This signal allows you to put code inside the HTML ``<head>`` tag
|
||||
of every page in the frontend. You will get the request as a keyword argument
|
||||
``request`` and can return plain HTML.
|
||||
|
||||
As with all plugin signals, the ``sender`` keyword argument will contain the event.
|
||||
"""
|
||||
This signal is sent out to include links in the footer
|
||||
"""
|
||||
|
||||
footer_link = EventPluginSignal(
|
||||
providing_args=["request"]
|
||||
)
|
||||
"""
|
||||
The signal ``pretix.presale.signals.footer_links`` allows you to add links to the footer of an event page. You
|
||||
are expected to return a dictionary containing the keys ``label`` and ``url``.
|
||||
|
||||
As with all plugin signals, the ``sender`` keyword argument will contain the event.
|
||||
"""
|
||||
|
||||
checkout_flow_steps = EventPluginSignal()
|
||||
"""
|
||||
This signal is sent out to retrieve pages for the checkout flow
|
||||
|
||||
As with all plugin signals, the ``sender`` keyword argument will contain the event.
|
||||
"""
|
||||
|
||||
voucher_redeem_info = EventPluginSignal(
|
||||
providing_args=["voucher"]
|
||||
)
|
||||
"""
|
||||
This signal is sent out to display additional information on the "redeem a voucher" page
|
||||
|
||||
As with all plugin signals, the ``sender`` keyword argument will contain the event.
|
||||
"""
|
||||
checkout_flow_steps = EventPluginSignal()
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
{% extends "pretixpresale/event/base.html" %}
|
||||
{% load i18n %}
|
||||
{% load eventurl %}
|
||||
{% load eventsignal %}
|
||||
{% load thumbnail %}
|
||||
{% block title %}{% trans "Voucher redemption" %}{% endblock %}
|
||||
|
||||
@@ -139,6 +140,7 @@
|
||||
{% endfor %}
|
||||
</section>
|
||||
{% endfor %}
|
||||
{% eventsignal event "pretix.presale.signals.voucher_redeem_info" voucher=voucher %}
|
||||
{% if event.presale_is_running %}
|
||||
<div class="row-fluid checkout-button-row">
|
||||
<div class="col-md-4 col-md-offset-8 col-xs-12">
|
||||
|
||||
Reference in New Issue
Block a user