Display user full name then fallback to username and only display change password link is user has usable password
This commit is contained in:
@@ -27,8 +27,10 @@
|
|||||||
{% if user.is_anonymous %}
|
{% if user.is_anonymous %}
|
||||||
{% trans 'Anonymous' %}
|
{% trans 'Anonymous' %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{{ user }}
|
{{ user.full_name|default:user }}
|
||||||
<a href="{% url password_change_view %}">({% trans 'New password' %})</a>
|
{% if has_usable_password %}
|
||||||
|
<a href="{% url password_change_view %}">({% trans 'New password' %})</a>
|
||||||
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</li>
|
</li>
|
||||||
{% if user.is_staff %}
|
{% if user.is_staff %}
|
||||||
|
|||||||
Reference in New Issue
Block a user