From 76396cdeb0f7f736bbe16c8c9c15dba78c775f6f Mon Sep 17 00:00:00 2001 From: TitouanDor Date: Mon, 16 Mar 2026 15:55:15 +0100 Subject: [PATCH] add partnership with eurock in eboutic --- eboutic/templates/eboutic/eboutic_main.jinja | 50 +++++++++++++++++++ ...k_fragment.jinja => eurock_fragment.jinja} | 0 eboutic/urls.py | 2 + eboutic/views.py | 7 ++- locale/fr/LC_MESSAGES/django.po | 36 +++++++++++++ 5 files changed, 93 insertions(+), 2 deletions(-) rename eboutic/templates/eboutic/{eurok_fragment.jinja => eurock_fragment.jinja} (100%) diff --git a/eboutic/templates/eboutic/eboutic_main.jinja b/eboutic/templates/eboutic/eboutic_main.jinja index 3ee0d745..43d95738 100644 --- a/eboutic/templates/eboutic/eboutic_main.jinja +++ b/eboutic/templates/eboutic/eboutic_main.jinja @@ -116,6 +116,56 @@ {% endif %} +
+
+

{% trans %}Eurockéennes 2025 partnership{% endtrans %}

+ {% if user.is_subscribed %} +
+

+ {% trans trimmed %} + Our partner uses Weezevent to sell tickets. + Weezevent may collect user info according to + its own privacy policy. + By clicking the accept button you consent to + their terms of services. + {% endtrans %} +

+ + {% trans %}Privacy policy{% endtrans %} + + +
+ {% else %} +

+ {%- trans trimmed %} + You must be subscribed to benefit from the partnership with the Eurockéennes. + {% endtrans -%} +

+

+ {%- trans trimmed %} + This partnership offers a discount of up to 33% + on tickets for Friday, Saturday and Sunday, + as well as the 3-day package from Friday to Sunday. + {% endtrans -%} +

+ {% endif %} +
+
{% for priority_groups in products|groupby('order') %} {% for category, items in priority_groups.list|groupby('category') %} {% if items|count > 0 %} diff --git a/eboutic/templates/eboutic/eurok_fragment.jinja b/eboutic/templates/eboutic/eurock_fragment.jinja similarity index 100% rename from eboutic/templates/eboutic/eurok_fragment.jinja rename to eboutic/templates/eboutic/eurock_fragment.jinja diff --git a/eboutic/urls.py b/eboutic/urls.py index 732dac2f..70fce4b5 100644 --- a/eboutic/urls.py +++ b/eboutic/urls.py @@ -31,6 +31,7 @@ from eboutic.views import ( EbouticMainView, EbouticPayWithSith, EtransactionAutoAnswer, + EurockPartnerFragment, payment_result, ) @@ -50,4 +51,5 @@ urlpatterns = [ EtransactionAutoAnswer.as_view(), name="etransation_autoanswer", ), + path("eurock/", EurockPartnerFragment.as_view(), name="eurock"), ] diff --git a/eboutic/views.py b/eboutic/views.py index f48c86c1..3ac02946 100644 --- a/eboutic/views.py +++ b/eboutic/views.py @@ -42,11 +42,11 @@ from django.shortcuts import redirect, render from django.urls import reverse from django.utils.translation import gettext_lazy as _ from django.views.decorators.http import require_GET -from django.views.generic import DetailView, FormView, UpdateView, View +from django.views.generic import DetailView, FormView, UpdateView, View, TemplateView from django.views.generic.edit import SingleObjectMixin from django_countries.fields import Country -from core.auth.mixins import CanViewMixin +from core.auth.mixins import CanViewMixin, IsSubscriberMixin from core.views.mixins import FragmentMixin, UseFragmentsMixin from counter.forms import BaseBasketForm, BasketProductForm, BillingInfoForm from counter.models import ( @@ -350,3 +350,6 @@ class EtransactionAutoAnswer(View): return HttpResponse( "Payment failed with error: " + request.GET["Error"], status=202 ) + +class EurockPartnerFragment(IsSubscriberMixin, TemplateView): + template_name = "eboutic/eurock_fragment.jinja" \ No newline at end of file diff --git a/locale/fr/LC_MESSAGES/django.po b/locale/fr/LC_MESSAGES/django.po index 7ef7b81b..6976999b 100644 --- a/locale/fr/LC_MESSAGES/django.po +++ b/locale/fr/LC_MESSAGES/django.po @@ -5838,3 +5838,39 @@ msgstr "Vous ne pouvez plus écrire de commentaires, la date est passée." #, python-format msgid "Maximum characters: %(max_length)s" msgstr "Nombre de caractères max: %(max_length)s" + +#: eboutic/templates/eboutic/eboutic_main.jinja +msgid "Eurockéennes 2025 partnership" +msgstr "Partenariat Eurockéennes 2025" + +#: eboutic/templates/eboutic/eboutic_main.jinja +msgid "" +"Our partner uses Weezevent to sell tickets. Weezevent may collect user info " +"according to its own privacy policy. By clicking the accept button you " +"consent to their terms of services." +msgstr "" +"Notre partenaire utilises Wezevent pour vendre ses billets. Weezevent peut " +"collecter des informations utilisateur conformément à sa propre politique de " +"confidentialité. En cliquant sur le bouton d'acceptation vous consentez à " +"leurs termes de service." + +#: eboutic/templates/eboutic/eboutic_main.jinja +msgid "Privacy policy" +msgstr "Politique de confidentialité" + +#: eboutic/templates/eboutic/eboutic_main.jinja +msgid "" +"You must be subscribed to benefit from the partnership with the Eurockéennes." +msgstr "" +"Vous devez être cotisant pour bénéficier du partenariat avec les " +"Eurockéennes." + +#: eboutic/templates/eboutic/eboutic_main.jinja +#, python-format +msgid "" +"This partnership offers a discount of up to 33%% on tickets for Friday, " +"Saturday and Sunday, as well as the 3-day package from Friday to Sunday." +msgstr "" +"Ce partenariat permet de profiter d'une réduction jusqu'à 33%% sur les " +"billets du vendredi, du samedi et du dimanche, ainsi qu'au forfait 3 jours, " +"du vendredi au dimanche."