change member url to unique id

This commit is contained in:
2020-12-10 23:59:39 +00:00
parent 570e951189
commit 768f2fd2a9
5 changed files with 23 additions and 12 deletions

View File

@@ -26,15 +26,23 @@
<div class="article-details">
{{ post.subtitle|default_if_none:"&nbsp;"|tags_to_url }}
{% if post.author %}
<div class="article-author"><a href="{% url 'member' post.author %}">
<img src="{{ author_image }}" alt="" /> {{ post.author }}
{% if author_image and author %}
<div class="article-author">
<a href="{% url 'member' author.id %}">
<img src="{{ author_image }}" alt="" /> {{ author.firstname }}
</a>
</div>
{% elif post.author %}
<div class="article-author">
<a href="">
<img src="" alt="" /> {{ post.author }}
</a>
</div>
{% else %}
<div class="article-author"><a href="">
<div class="article-author">
<a href="">
<img src="" alt="" />
{{ post.author }}</a>
</a>
</div>
{% endif %}
</div>