From 01a52f88d3613be4f071c9a34830b1b2cefaf3c8 Mon Sep 17 00:00:00 2001 From: Jean-Romain Garnier Date: Fri, 17 Apr 2020 22:20:45 +0200 Subject: [PATCH] Fix error in profil of users with an unverified email --- users/locale/fr/LC_MESSAGES/django.po | 4 ++++ users/templates/users/profil.html | 21 ++++++++++++++------- 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/users/locale/fr/LC_MESSAGES/django.po b/users/locale/fr/LC_MESSAGES/django.po index 922c2dbe..e19e19c6 100644 --- a/users/locale/fr/LC_MESSAGES/django.po +++ b/users/locale/fr/LC_MESSAGES/django.po @@ -1028,6 +1028,10 @@ msgstr "Pas de connexion" msgid "Pay for a connection" msgstr "Payer une connexion" +#: users/templates/users/profil.html:81 +msgid "Resend the email" +msgstr "Renvoyer le mail" + #: users/templates/users/profil.html:60 msgid "Ask someone with the appropriate rights to pay for a connection." msgstr "" diff --git a/users/templates/users/profil.html b/users/templates/users/profil.html index 82feb8e6..4fec3c18 100644 --- a/users/templates/users/profil.html +++ b/users/templates/users/profil.html @@ -70,14 +70,21 @@ with this program; if not, write to the Free Software Foundation, Inc., {% elif not users.has_access %}
{% trans "No connection" %}
+
- {% can_create Facture %} - - {% trans "Pay for a connection" %} - - {% acl_else %} - {% trans "Ask someone with the appropriate rights to pay for a connection." %} - {% acl_end %} + {% if users.email_state == users.EMAIL_STATE_UNVERIFIED %} + + {% trans "Resend the email" %} + + {% else %} + {% can_create Facture %} + + {% trans "Pay for a connection" %} + + {% acl_else %} + {% trans "Ask someone with the appropriate rights to pay for a connection." %} + {% acl_end %} + {% endif %}
{% else %}