Widget: Pass cart IDs around in some more places

This commit is contained in:
Raphael Michel
2018-08-16 18:40:21 +02:00
parent efdbbc6098
commit dfc7f7c827
6 changed files with 26 additions and 9 deletions

View File

@@ -115,7 +115,8 @@
browser settings.
{% endblocktrans %}
<br>
<a href="{% eventurl event "presale:event.index" %}" class="btn btn-default" target="_blank">
<a href="{% eventurl event "presale:event.index" cart_namespace=cart_namespace %}{% if "cart_id" in request.GET %}?src=widget&take_cart_id={{ request.GET.cart_id }}{% endif %}"
class="btn btn-primary" target="_blank">
{% trans "Open ticket shop in new tab" %}
</a>
<div class="clearfix"></div>

View File

@@ -20,10 +20,11 @@
</p>
{% if event.presale_is_running or event.settings.show_items_outside_presale_period %}
<form method="post" data-asynctask
action="{% eventurl request.event "presale:event.cart.add" cart_namespace=cart_namespace %}?next={% eventurl request.event "presale:event.index" cart_namespace=cart_namespace %}">
action="{% eventurl request.event "presale:event.cart.add" cart_namespace=cart_namespace %}?next={% eventurl request.event "presale:event.index" cart_namespace=cart_namespace %}{% if "iframe" in request.GET %}&iframe={{ request.GET.iframe }}{% endif %}">
{% csrf_token %}
<input type="hidden" name="subevent" value="{{ subevent.id|default_if_none:"" }}" />
<input type="hidden" name="_voucher_code" value="{{ voucher.code }}">
{% for tup in items_by_category %}
<section>
{% if tup.0 %}