stop showing logged-in users the login form [#29858801]
parent
365976933e
commit
a4e15bcda3
|
@ -45,6 +45,7 @@
|
|||
<div id="collapser" class="collapser_x">X</div>
|
||||
<h3 class="module-title">Start Ungluing Now!</h3>
|
||||
<div class="jsmod-content">
|
||||
{% if not request.user.is_authenticated %}
|
||||
<form action='/accounts/register/' method='post'>{% csrf_token %}
|
||||
<div class="user-name">
|
||||
<label>Username</label>
|
||||
|
@ -69,6 +70,12 @@
|
|||
<div class="google_signup">
|
||||
<a href="/socialauth/login/google?next={{request.build_absolute_uri}}"><img src="{{ STATIC_URL }}images/auth/google_32_noborder.png" alt="google" /></a><div>Or: <a href="/socialauth/login/google?next={{request.build_absolute_uri}}">Sign Up With Google</a></div>
|
||||
</div>
|
||||
{% else %}
|
||||
<div>
|
||||
You are logged in as <a href="/supporter/{{request.user.username}}">{{ request.user.username }}</a>.
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -113,6 +120,7 @@
|
|||
<div class="js-rightcol-padd">
|
||||
<div class="jsmodule" id="mainlogin">
|
||||
<h3 class="module-title">Start Ungluing Now!</h3>
|
||||
{% if not request.user.is_authenticated %}
|
||||
<div class="jsmod-content">
|
||||
<form action='/accounts/register/' method='post'>{% csrf_token %}
|
||||
<div class="user-name">
|
||||
|
@ -139,6 +147,12 @@
|
|||
</div>
|
||||
</form>
|
||||
</div>
|
||||
{% else %}
|
||||
<div>
|
||||
You are logged in as <a href="/supporter/{{request.user.username}}">{{ request.user.username }}</a>.
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
<div class="jsmodule">
|
||||
<h3 class="module-title">Who's ungluing what</h3>
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
{% extends "registration/registration_base.html" %}
|
||||
{% block title %}Activation complete{% endblock %}
|
||||
{% block doccontent %}
|
||||
{% if not user.is_authenticated %}
|
||||
<div>
|
||||
<p>Thanks, your activation is complete! You may now sign in using the username and password you set at registration:</p>
|
||||
{% with 'welcome' as next %}
|
||||
|
@ -11,6 +12,11 @@
|
|||
<div>
|
||||
<a href="{% url auth_password_reset %}">Forgot</a> your password?
|
||||
</div>
|
||||
{% else %}
|
||||
<div>
|
||||
You are already logged in as <a href="/supporter/{{user.username}}">{{ user.username }}</a>.
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
<p class="errorlist">Your username and password didn't match. Please try again.</p>
|
||||
Make sure the username box has your <b>username, not your email</b> -- some browsers automatically fill in your email. We're working on fixing this bug.
|
||||
{% endif %}
|
||||
|
||||
{% if not user.is_authenticated %}
|
||||
<h3>Sign in to your account</h3>
|
||||
|
||||
{% include "login_form.html" %}
|
||||
|
@ -20,5 +20,9 @@ Make sure the username box has your <b>username, not your email</b> -- some brow
|
|||
<div class="google_signup">
|
||||
<a href="/socialauth/login/google?next=/next/"><img src="{{ STATIC_URL }}images/auth/google_32_noborder.png" alt="google" /></a><div>Or: <a href="/socialauth/login/google?next=/next/">Sign in with Google</a></div>
|
||||
</div>
|
||||
|
||||
{% else %}
|
||||
<div>
|
||||
You are already logged in as <a href="/supporter/{{user.username}}">{{ user.username }}</a>.
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
{% block title %}Register for an account{% endblock %}
|
||||
|
||||
{% block doccontent %}
|
||||
{% if not user.is_authenticated %}
|
||||
|
||||
<h3>Sign up for a Unglue.it account:</h3>
|
||||
|
||||
<form method='post' action=''>{% csrf_token %}
|
||||
|
@ -15,6 +17,12 @@
|
|||
<h3>Or use an account you already have:</h3>
|
||||
<a href="/socialauth/login/google?next=/"><img src="{{ STATIC_URL }}images/auth/google_32_noborder.png"><div>Sign in with Google</div></a>
|
||||
</div>
|
||||
{% else %}
|
||||
<div>
|
||||
You are already logged in as <a href="/supporter/{{user.username}}">{{ user.username }}</a>.
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</div>
|
||||
|
||||
{% endblock %}
|
||||
|
|
Loading…
Reference in New Issue