forked from CGM_Public/pretix_original
Compare commits
2 Commits
stripe-gir
...
fix-seatin
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3c014a91b0 | ||
|
|
9fe6916ab5 |
@@ -48,7 +48,7 @@
|
|||||||
{% if c %}
|
{% if c %}
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr class="sortable-disabled"><th colspan="9" scope="colgroup" class="text-muted">
|
<tr class="sortable-disabled"><th colspan="9" scope="colgroup" class="text-muted">
|
||||||
{{ c.name }}{% if c.category_type != "normal" %} <span class="font-normal">({{ c.get_category_type_display }})</span>{% endif %}
|
{{ c.internal_name|default:c.name }}{% if c.category_type != "normal" %} <span class="font-normal">({{ c.get_category_type_display }})</span>{% endif %}
|
||||||
<a href="{% url "control:event.items.categories.edit" organizer=request.event.organizer.slug event=request.event.slug category=c.id %}" title="{% trans "Edit" %}"><span class="fa fa-edit fa-fw"></span></a>
|
<a href="{% url "control:event.items.categories.edit" organizer=request.event.organizer.slug event=request.event.slug category=c.id %}" title="{% trans "Edit" %}"><span class="fa fa-edit fa-fw"></span></a>
|
||||||
</th></tr>
|
</th></tr>
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ class Paypal2App(AppConfig):
|
|||||||
featured = True
|
featured = True
|
||||||
picture = 'pretixplugins/paypal2/paypal_logo.svg'
|
picture = 'pretixplugins/paypal2/paypal_logo.svg'
|
||||||
description = _("Accept payments with your PayPal account. In addition to regular PayPal payments, you can now "
|
description = _("Accept payments with your PayPal account. In addition to regular PayPal payments, you can now "
|
||||||
"also offer payments in a variety of local payment methods such as eps, iDEAL, and "
|
"also offer payments in a variety of local payment methods such as giropay, SOFORT, iDEAL and "
|
||||||
"many more to your customers - they don't even need a PayPal account. PayPal is one of the "
|
"many more to your customers - they don't even need a PayPal account. PayPal is one of the "
|
||||||
"most popular payment methods world-wide.")
|
"most popular payment methods world-wide.")
|
||||||
|
|
||||||
|
|||||||
@@ -149,7 +149,7 @@ class PaypalSettingsHolder(BasePaymentProvider):
|
|||||||
label=_('Alternative Payment Methods'),
|
label=_('Alternative Payment Methods'),
|
||||||
help_text=_(
|
help_text=_(
|
||||||
'In addition to payments through a PayPal account, you can also offer your customers the option '
|
'In addition to payments through a PayPal account, you can also offer your customers the option '
|
||||||
'to pay with credit cards and other, local payment methods such as eps, iDEAL, and '
|
'to pay with credit cards and other, local payment methods such as SOFORT, giropay, iDEAL, and '
|
||||||
'many more - even when they do not have a PayPal account. Eligible payment methods will be '
|
'many more - even when they do not have a PayPal account. Eligible payment methods will be '
|
||||||
'determined based on the shoppers location. For German merchants, this is the direct successor '
|
'determined based on the shoppers location. For German merchants, this is the direct successor '
|
||||||
'of PayPal Plus.'
|
'of PayPal Plus.'
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ class StripeApp(AppConfig):
|
|||||||
featured = True
|
featured = True
|
||||||
picture = 'pretixplugins/stripe/stripe_logo.svg'
|
picture = 'pretixplugins/stripe/stripe_logo.svg'
|
||||||
description = _("Accept payments via Stripe, a globally popular payment service provider. Stripe supports "
|
description = _("Accept payments via Stripe, a globally popular payment service provider. Stripe supports "
|
||||||
"payments via credit cards as well as many local payment methods such as iDEAL, Alipay,"
|
"payments via credit cards as well as many local payment methods such as giropay, iDEAL, Alipay,"
|
||||||
"and many more.")
|
"and many more.")
|
||||||
|
|
||||||
def ready(self):
|
def ready(self):
|
||||||
|
|||||||
@@ -36,9 +36,7 @@ import json
|
|||||||
import logging
|
import logging
|
||||||
import re
|
import re
|
||||||
import urllib.parse
|
import urllib.parse
|
||||||
import zoneinfo
|
|
||||||
from collections import OrderedDict
|
from collections import OrderedDict
|
||||||
from datetime import datetime
|
|
||||||
from decimal import Decimal
|
from decimal import Decimal
|
||||||
from json import JSONDecodeError
|
from json import JSONDecodeError
|
||||||
|
|
||||||
@@ -110,7 +108,7 @@ logger = logging.getLogger('pretix.plugins.stripe')
|
|||||||
# - Bancontact: ✓
|
# - Bancontact: ✓
|
||||||
# - BLIK: ✗
|
# - BLIK: ✗
|
||||||
# - EPS: ✓
|
# - EPS: ✓
|
||||||
# - giropay: (deprecated)
|
# - giropay: ✓
|
||||||
# - iDEAL: ✓
|
# - iDEAL: ✓
|
||||||
# - P24: ✓
|
# - P24: ✓
|
||||||
# - Sofort: ✓
|
# - Sofort: ✓
|
||||||
@@ -337,6 +335,14 @@ class StripeSettingsHolder(BasePaymentProvider):
|
|||||||
label=_('Credit card payments'),
|
label=_('Credit card payments'),
|
||||||
required=False,
|
required=False,
|
||||||
)),
|
)),
|
||||||
|
('method_giropay',
|
||||||
|
forms.BooleanField(
|
||||||
|
label=_('giropay'),
|
||||||
|
disabled=self.event.currency != 'EUR',
|
||||||
|
help_text=_('Some payment methods might need to be enabled in the settings of your Stripe account '
|
||||||
|
'before they work properly.'),
|
||||||
|
required=False,
|
||||||
|
)),
|
||||||
('method_ideal',
|
('method_ideal',
|
||||||
forms.BooleanField(
|
forms.BooleanField(
|
||||||
label=_('iDEAL'),
|
label=_('iDEAL'),
|
||||||
@@ -1481,17 +1487,6 @@ class StripeGiropay(StripeRedirectWithAccountNamePaymentIntentMethod):
|
|||||||
)
|
)
|
||||||
redirect_in_widget_allowed = False
|
redirect_in_widget_allowed = False
|
||||||
|
|
||||||
def is_allowed(self, request: HttpRequest, total: Decimal=None) -> bool:
|
|
||||||
# Stripe<>giropay is shut down July 1st
|
|
||||||
return super().is_allowed(request, total) and now() < datetime(
|
|
||||||
2024, 7, 1, 0, 0, 0, tzinfo=zoneinfo.ZoneInfo("Europe/Berlin")
|
|
||||||
)
|
|
||||||
|
|
||||||
def order_change_allowed(self, order: Order, request: HttpRequest=None) -> bool:
|
|
||||||
return super().order_change_allowed(order, request) and now() < datetime(
|
|
||||||
2024, 7, 1, 0, 0, 0, tzinfo=zoneinfo.ZoneInfo("Europe/Berlin")
|
|
||||||
)
|
|
||||||
|
|
||||||
def _payment_intent_kwargs(self, request, payment):
|
def _payment_intent_kwargs(self, request, payment):
|
||||||
return {
|
return {
|
||||||
"payment_method_data": {
|
"payment_method_data": {
|
||||||
@@ -1565,6 +1560,7 @@ class StripeBancontact(StripeRedirectWithAccountNamePaymentIntentMethod):
|
|||||||
return {
|
return {
|
||||||
"payment_method_data": {
|
"payment_method_data": {
|
||||||
"type": "bancontact",
|
"type": "bancontact",
|
||||||
|
"giropay": {},
|
||||||
"billing_details": {
|
"billing_details": {
|
||||||
"name": request.session.get(f"payment_stripe_{self.method}_account") or gettext("unknown name")
|
"name": request.session.get(f"payment_stripe_{self.method}_account") or gettext("unknown name")
|
||||||
},
|
},
|
||||||
@@ -1667,6 +1663,7 @@ class StripeEPS(StripeRedirectWithAccountNamePaymentIntentMethod):
|
|||||||
return {
|
return {
|
||||||
"payment_method_data": {
|
"payment_method_data": {
|
||||||
"type": "eps",
|
"type": "eps",
|
||||||
|
"giropay": {},
|
||||||
"billing_details": {
|
"billing_details": {
|
||||||
"name": request.session.get(f"payment_stripe_{self.method}_account") or gettext("unknown name")
|
"name": request.session.get(f"payment_stripe_{self.method}_account") or gettext("unknown name")
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
{% if css_theme %}
|
{% if css_theme %}
|
||||||
<link rel="stylesheet" type="text/css" href="{{ css_theme }}" />
|
<link rel="stylesheet" type="text/css" href="{{ css_theme }}" />
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
{{ html_head|safe }}
|
||||||
{% include "pretixpresale/fragment_js.html" %}
|
{% include "pretixpresale/fragment_js.html" %}
|
||||||
<meta name="referrer" content="origin">
|
<meta name="referrer" content="origin">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0">
|
<meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=0">
|
||||||
|
|||||||
Reference in New Issue
Block a user