2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2026-02-08 14:58:17 +00:00

old user, first registration. cleaner

This commit is contained in:
2025-01-27 23:50:08 +00:00
parent 98594a07e2
commit bac65b5897
4 changed files with 58 additions and 23 deletions

View File

@@ -68,11 +68,19 @@ So type in the same email address that you use there if you have already signed
<div style='width: 700px; font-family: monospace; font-weight: bold; font-size: 150%; text-align: right; '>
<form method="post" accept-charset="utf-8">{% csrf_token %}
<p>
{% if email_stored %}
<label for="id_username">Username <span style="color:blue">(checked)</span>:</label>
{% else %}
<label for="id_username">Username:</label>
{% endif %}
{{form.username}}
</p>
<p>
{% if email_stored %}
<label for="id_email">email <span style="color:blue">(stored)</span>:</label>
{% else %}
<label for="id_email">email:</label>
{% endif %}
{{form.email}}
</p>
{% if logged_in %}<!-- one we have initially logged in,
@@ -104,26 +112,39 @@ all later password chnages are done ONLY via email token password re-set-->
Get login token by email &rarr;
</button>
{% else %}
<button class="fancybutton"
{% if logged_in %}
<button class="fancybutton" type="button"
{% if logged_in or email_stored %}
style="padding: 0.5em 25px; font-size: 100%;"
{% else %}
style="padding: 0.5em 25px; font-size: 100%; background: silver;"
disabled
{% endif %}
onclick="window.location.href='/accounts/password_reset/'" value = "Go to" >
Reset password
Confirm email
</button>
&nbsp;&nbsp;&nbsp;
<button class="fancybutton" style="padding: 0.5em 25px; font-size: 100%;" type = "submit" >
{% if logged_in %}
<button class="fancybutton" style="padding: 0.5em 25px; font-size: 100%;" type = "submit" >
Change or confirm email &rarr;
{% else %}
Register &rarr;
{% endif %}
</button>
{% else %}
{% if email_stored %}
{% else %}
<button class="fancybutton" style="padding: 0.5em 25px; font-size: 100%;" type = "submit" >
Register &rarr;
</button>
{% endif %}
{% endif %}
{%endif %}
{% if email_stored %}
<button class="fancybutton" type="button"
style="padding: 0.5em 25px; font-size: 100%;"
onclick="window.location.href='/accounts/login/'" value = "Go to" >
Login &rarr;
</button>
{% endif %}
</div>
</form>
</div>

View File

@@ -24,6 +24,10 @@ Email change - for a personal login to Troggle
<!--using template login/register_email.html -->
</div>
<!--ONLY for an expo-valid logged-on User
The reason for separating this template from the other one (register.html) is that the logic
gets very confused. So despite the partial duplication, it is easier to debug and maintain by
having two separate templates.
-->
<h3>Register your email address</h3>