39 lines
1,005 B
Django/Jinja
39 lines
1,005 B
Django/Jinja
{% extends 'base.html.j2' %}
|
|
|
|
{% block title %}Profile{% endblock %}
|
|
|
|
{% block content %}
|
|
<h1>Your Profile</h1>
|
|
{% if gravatar_url %}
|
|
<img src="{{ gravatar_url }}" alt="Gravatar Image">
|
|
{% endif %}
|
|
<p>Username: {{ user.username or "Not set" }}</p>
|
|
|
|
<form method="POST">
|
|
<label>
|
|
<input type="checkbox" name="enable_gravatar" {% if user.enable_gravatar %}checked{% endif %}>
|
|
Enable Gravatar
|
|
</label><br><br>
|
|
|
|
<label>
|
|
New Username:
|
|
<input type="text" name="new_username" placeholder="Enter new username">
|
|
</label><br><br>
|
|
|
|
<button type="submit">Update Profile</button>
|
|
</form>
|
|
|
|
<h2>Your Owned Namespaces</h2>
|
|
{% if owner_namespaces %}
|
|
<ul>
|
|
{% for ns in owner_namespaces %}
|
|
<li>
|
|
<a href="{{ request.route_url('manage_namespace', namespace_short_id=ns.short_id) }}">{{ ns.name }}</a>
|
|
</li>
|
|
{% endfor %}
|
|
</ul>
|
|
{% else %}
|
|
<p>You do not own any namespaces.</p>
|
|
{% endif %}
|
|
|
|
{% endblock %}
|