Skip to content

Commit e060cae

Browse files
committed
Replaced some cases of using person.plain_name when linking to a person's profile with person.name, as plain_name can fail.
- Legacy-Id: 15427
1 parent b2bfc78 commit e060cae

4 files changed

Lines changed: 6 additions & 4 deletions

File tree

ietf/templates/group/all_photos.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ <h1>{{ group_type | upper }} {{ role }} Photos</h1>
2828
{% for person_with_groups in person_groups %}
2929
<li>
3030
<div class="well photo-thumbnail">
31-
<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.plain_name %}">
31+
<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.name %}">
3232
<div>
3333
{% if person_with_groups.grouper.photo_thumb %}
3434
<img width=100 src="{{person_with_groups.grouper.photo_thumb.url}}" alt="Photo of {{person_with_groups.grouper.name}}"/>

ietf/templates/group/group_photos.html

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,13 @@ <h1>{{ group }} ({{group.acronym}}) Photos</h1>
2727
{% regroup role_name.list by person as person_groups %}
2828
{% for person_with_groups in person_groups %}
2929
<li>
30-
<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.plain_name %}">
30+
<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.name %}">
3131
<div class="well photo-thumbnail">
3232
<div>
3333
{% if person_with_groups.grouper.photo_thumb %}
3434
<img width=100 src="{{person_with_groups.grouper.photo_thumb.url}}" alt="Photo of {{person_with_groups.grouper.name}}" />
35+
{% elif person_with_groups.grouper.photo %}
36+
<img width=100 src="{{person_with_groups.grouper.photo.url}}" alt="Photo of {{person_with_groups.grouper.name}}" />
3537
{% else %}
3638
<img width=100 src="{{ MEDIA_URL }}photo/nopictureavailable.jpg" alt="No picture available"/>
3739
{% endif %}

ietf/templates/iesg/photos.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ <h1>{{ group_type | upper }} {{ role }} Photos</h1>
4141
{% regroup letter.list by person as person_groups %}
4242
{% for person_with_groups in person_groups %}
4343
<li>
44-
{% if person_with_groups.grouper.photo %}<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.plain_name %}">{% endif %}
44+
{% if person_with_groups.grouper.photo %}<a href="{% url 'ietf.person.views.profile' email_or_name=person_with_groups.grouper.name %}">{% endif %}
4545
<div class="well photo-thumbnail">
4646
<div>
4747
{% if person_with_groups.grouper.photo_thumb %}

ietf/templates/nomcom/eligible.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ <h2>Eligible People for {{ nomcom.group }}</h2>
2626

2727
{% for p in eligible_persons %}
2828
<tr>
29-
<td><a href="{% url 'ietf.person.views.profile' p.plain_name %}">{{p.last_name}}</a></td>
29+
<td><a href="{% url 'ietf.person.views.profile' p.name %}">{{p.last_name}}</a></td>
3030
<td>{{p.first_name}}</td>
3131
<td>{% for e in p.email_set.all %}{{e.address}}{% if not forloop.last %}, {% endif %}{% endfor %}</td>
3232
</tr>

0 commit comments

Comments
 (0)