mirror of
https://github.com/boostorg/website-v2.git
synced 2026-02-27 05:32:08 +00:00
#67 Show author and maintainer name on library pages
This commit is contained in:
@@ -14,7 +14,7 @@ class LibraryList(CategoryMixin, ListView):
|
||||
"""List all of our libraries by name"""
|
||||
|
||||
paginate_by = 25
|
||||
queryset = Library.objects.prefetch_related("categories").all().order_by("name")
|
||||
queryset = Library.objects.prefetch_related("authors", "categories").all().order_by("name")
|
||||
template_name = "libraries/list.html"
|
||||
|
||||
|
||||
|
||||
@@ -81,15 +81,17 @@
|
||||
<div class="py-6">
|
||||
<h3 class="text-2xl mb-4">Authors</h3>
|
||||
<div class="space-y-3">
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> Glen Fernandes</div>
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> Glen Fernandes</div>
|
||||
{% for author in object.authors.all %}
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> {{ author.get_full_name }}</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
<div class="py-6">
|
||||
<h3 class="text-2xl mb-4">Maintainers</h3>
|
||||
<div class="space-y-3">
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> Glen Fernandes</div>
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> Glen Fernandes</div>
|
||||
{% for maintainer in object.maintainers.all %}
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline mr-5" /> {{ maintainer.get_full_name }}</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -73,11 +73,13 @@
|
||||
<div class="md:w-1/4 mb-4 text-sm">
|
||||
<div class="my-5 flex">
|
||||
<div class="md:mr-5 w-1/3">Author(s):</div>
|
||||
<div class="space-y-3">
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline" /> Glen Fernandes</div>
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline" /> Glen Fernandes</div>
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline" /> Glen Fernandes</div>
|
||||
</div>
|
||||
{% if library.authors.count %}
|
||||
<div class="space-y-3">
|
||||
{% for author in library.authors.all %}
|
||||
<div><img src="{% static 'img/fpo/user.png' %}" alt="user" class="inline" /> {{ author.get_full_name }}</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user