From ed5c6626cc3d90339118da36b94ace5ca59bea3f Mon Sep 17 00:00:00 2001 From: YvanSv <yvan.savergne@gmail.com> Date: Wed, 3 Apr 2024 17:58:06 +0200 Subject: [PATCH] user unable to pay pret if not premium --- templates/annonce_detail/annonce.html.twig | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/templates/annonce_detail/annonce.html.twig b/templates/annonce_detail/annonce.html.twig index ce2364e0..c7cb063c 100644 --- a/templates/annonce_detail/annonce.html.twig +++ b/templates/annonce_detail/annonce.html.twig @@ -64,7 +64,15 @@ <a href=""><button class="btn-connexion2" id="btnListeAttente">Se mettre en liste d'attente</button></a> {% endif %} {% else %} - <a href="{{ path('app_reserver_prestation', {'id': annonce.id, 'interet': true}) }}"><button class="btn-connexion" id="btnRepondre">Répondre à l'annonce</button></a> + {% if annonce.type == "Pret" %} + {% if user.statusAbonnement() == "0" %} + <a href="{{ path('app_modif_user_abonnement') }}"><button class="btn-connexion" id="btnRepondre">Améliorer mon abonnement</button></a> + {% else %} + <a href="{{ path('app_reserver_prestation', {'id': annonce.id, 'interet': true}) }}"><button class="btn-connexion" id="btnRepondre">Répondre à l'annonce</button></a> + {% endif %} + {% else %} + <a href="{{ path('app_reserver_prestation', {'id': annonce.id, 'interet': true}) }}"><button class="btn-connexion" id="btnRepondre">Répondre à l'annonce</button></a> + {% endif %} {% endif %} {% endif %} {% endif %} -- GitLab