From ec6f22d7014a6a35ed1939c712f244a834787e20 Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Thu, 13 Aug 2015 19:09:32 +0200 Subject: [PATCH] Fixed payment details for unpaid stripe payments --- .../pretixplugins/stripe/control.html | 40 +++++++++++-------- 1 file changed, 24 insertions(+), 16 deletions(-) diff --git a/src/pretix/plugins/stripe/templates/pretixplugins/stripe/control.html b/src/pretix/plugins/stripe/templates/pretixplugins/stripe/control.html index 3aad4a3eca..ba3d416267 100644 --- a/src/pretix/plugins/stripe/templates/pretixplugins/stripe/control.html +++ b/src/pretix/plugins/stripe/templates/pretixplugins/stripe/control.html @@ -14,22 +14,30 @@ This order has been planned to be paid via Stripe, but the payment has not yet been completed. {% endblocktrans %}

{% endif %} -
-
{% trans "Charge ID" %}
-
{{ payment_info.id }}
-
{% trans "Card type" %}
-
{{ payment_info.source.brand }}
-
{% trans "Card number" %}
-
**** **** **** {{ payment_info.source.last4 }}
-
{% trans "Payer name" %}
-
{{ payment_info.source.name }}
-
{% trans "Total value" %}
-
{{ payment_info.amount|floatformat:2 }}
-
{% trans "Currency" %}
-
{{ payment_info.currency|upper }}
-
{% trans "Status" %}
-
{{ payment_info.status }}
-
+ {% if order.status != "p" %} +
+
{% trans "Charge ID" %}
+
{{ payment_info.id }}
+
{% trans "Card type" %}
+
{{ payment_info.source.brand }}
+
{% trans "Card number" %}
+
**** **** **** {{ payment_info.source.last4 }}
+
{% trans "Payer name" %}
+
{{ payment_info.source.name }}
+
{% trans "Total value" %}
+
{{ payment_info.amount|floatformat:2 }}
+
{% trans "Currency" %}
+
{{ payment_info.currency|upper }}
+
{% trans "Status" %}
+
{{ payment_info.status }}
+
+ {% endif %} + {% if "message" in payment_info %} +
+
{% trans "Error message" %}
+
{{ payment_info.message }}
+
+ {% endif %} {% else %}

{% blocktrans trimmed %} This order has been planned to be paid via Stripe, but the payment has not yet been completed.