##// END OF EJS Templates
Sort tags alphabetically in metadata
neko259 -
r315:0647dc8f default
parent child Browse files
Show More
@@ -311,6 +311,11 b' class Post(models.Model):'
311 311
312 312 return last_replies
313 313
314 def get_tags(self):
315 """Get a sorted tag list"""
316
317 return self.tags.order_by('name')
318
314 319
315 320 class User(models.Model):
316 321
@@ -84,7 +84,7 b''
84 84 {{ thread.thread.get_images_count }} {% trans 'images' %}.
85 85 {% if thread.thread.tags %}
86 86 <span class="tags">
87 {% for tag in thread.thread.tags.all %}
87 {% for tag in thread.thread.get_tags %}
88 88 <a class="tag" href="
89 89 {% url 'tag' tag_name=tag.name %}">
90 90 #{{ tag.name }}</a>
@@ -78,7 +78,7 b''
78 78 {% if post.id == posts.0.id %}
79 79 <div class="metadata">
80 80 <span class="tags">
81 {% for tag in post.tags.all %}
81 {% for tag in post.get_tags %}
82 82 <a class="tag" href="{% url 'tag' tag.name %}">
83 83 #{{ tag.name }}</a>
84 84 {% endfor %}
General Comments 0
You need to be logged in to leave comments. Login now