Do not list alias on profile page

This commit is contained in:
Alexandre Iooss 2020-08-25 15:05:50 +02:00
parent bac14521ae
commit 63dc184ce4
2 changed files with 13 additions and 7 deletions

View File

@ -54,8 +54,12 @@
<dd class="col-xl-6">{{ club.note.balance | pretty_money }}</dd> <dd class="col-xl-6">{{ club.note.balance | pretty_money }}</dd>
{% endif %} {% endif %}
<dt class="col-xl-6"><a href="{% url 'member:club_alias' club.pk %}">{% trans 'aliases'|capfirst %}</a></dt> <dt class="col-xl-6">{% trans 'aliases'|capfirst %}</dt>
<dd class="col-xl-6 text-truncate">{{ club.note.alias_set.all|join:", " }}</dd> <dd class="col-xl-6">
<a class="small" href="{% url 'member:club_alias' club.pk %}">
{% trans 'Edit my aliases' %} ({{ club.note.alias_set.all|length }})
</a>
</dd>
<dt class="col-xl-4">{% trans 'email'|capfirst %}</dt> <dt class="col-xl-4">{% trans 'email'|capfirst %}</dt>
<dd class="col-xl-8"><a href="mailto:{{ club.email }}">{{ club.email }}</a></dd> <dd class="col-xl-8"><a href="mailto:{{ club.email }}">{{ club.email }}</a></dd>

View File

@ -26,6 +26,13 @@
</dd> </dd>
{% endif %} {% endif %}
<dt class="col-xl-6">{% trans 'aliases'|capfirst %}</dt>
<dd class="col-xl-6">
<a class="small" href="{% url 'member:user_alias' user_object.pk %}">
{% trans 'Edit my aliases' %} ({{ user_object.note.alias_set.all|length }})
</a>
</dd>
<dt class="col-xl-6">{% trans 'section'|capfirst %}</dt> <dt class="col-xl-6">{% trans 'section'|capfirst %}</dt>
<dd class="col-xl-6">{{ user_object.profile.section }}</dd> <dd class="col-xl-6">{{ user_object.profile.section }}</dd>
@ -47,11 +54,6 @@
<dd class="col-xl-6">{{ user_object.profile.paid|yesno }}</dd> <dd class="col-xl-6">{{ user_object.profile.paid|yesno }}</dd>
{% endif %} {% endif %}
</dl> </dl>
<h4><a href="{% url 'member:user_alias' user_object.pk %}">{% trans 'aliases'|capfirst %}</a></h4>
{% for alias in user_object.note.alias_set.all %}
<span class="badge badge-secondary">{{ alias }}</span>
{% endfor %}
</div> </div>
<div class="card-footer"> <div class="card-footer">
<a class="btn btn-sm btn-secondary" href="{% url 'member:user_update_profile' user_object.pk %}"> <a class="btn btn-sm btn-secondary" href="{% url 'member:user_update_profile' user_object.pk %}">