SciPost Code Repository

Skip to content
Snippets Groups Projects
Commit 58ef623a authored by George Katsikas's avatar George Katsikas :goat:
Browse files

hide specialties section in journal if none exist

parent 12e92f0e
No related branches found
No related tags found
No related merge requests found
......@@ -95,18 +95,24 @@
</h2>
{% automarkup journal.scope %}
<br><br>
<h4>Specialties covered by this Journal</h4>
<ul>
{% if journal.specialties.length > 0 %}
{% for spec in journal.specialties.all %}
<li>{{ spec }}</li>
{% endfor %}
{% elif journal.college %}
{% for spec in journal.college.acad_field.specialties.all %}
<li>{{ spec }}</li>
{% endfor %}
{% endif %}
</ul>
{% if journal.specialties.exists or journal.college.acad_field.specialties.exists %}
<h4>Specialties covered by this Journal</h4>
<ul>
{% for spec in journal.specialties.all %}
<li>{{ spec }}</li>
{% empty %}
{% if journal.college %}
{% for spec in journal.college.acad_field.specialties.all %}
<li>{{ spec }}</li>
{% endfor %}
{% endif %}
{% endfor %}
</ul>
{% endif %}
<h2 class="highlight" id="content">
Content
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment