Refactor category article index
This commit is contained in:
parent
5b81e9a867
commit
5fe2e03b65
1 changed files with 19 additions and 20 deletions
|
@ -5,25 +5,7 @@
|
|||
|
||||
{% block content %}
|
||||
|
||||
{% if articles|length > 1 %}
|
||||
<section id="article-index">
|
||||
<div class="container">
|
||||
<h2>{{ page.trans_title }}</h2>
|
||||
<p class="lead">{{ page.trans_intro|richtext }}</p>
|
||||
<div class="article-body" role="main">
|
||||
{% for entry in articles %}
|
||||
<div class="item">
|
||||
<div class="article-caption">
|
||||
<h3><a href="{% pageurl entry %}">{{ entry.trans_title }}</a></h3>
|
||||
<p>{{ entry.trans_intro|richtext }}</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div><!-- /container -->
|
||||
</section>
|
||||
|
||||
{% elif articles|length > 0 %}
|
||||
{% if articles|length is 1 %}
|
||||
|
||||
<section id="news-details">
|
||||
<div class="container">
|
||||
|
@ -34,7 +16,24 @@
|
|||
</section>
|
||||
|
||||
{% else %}
|
||||
No articles here.
|
||||
|
||||
<section id="article-index">
|
||||
<div class="container">
|
||||
<h2>{{ page.trans_title }}</h2>
|
||||
<p class="lead">{{ page.trans_intro|richtext }}</p>
|
||||
<div class="article-body" role="main">
|
||||
{% for entry in articles %}
|
||||
<div class="item">
|
||||
<div class="article-caption">
|
||||
<h3><a href="{% pageurl entry %}">{{ entry.trans_title }}</a></h3>
|
||||
<p>{{ entry.trans_intro|richtext }}</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div><!-- /container -->
|
||||
</section>
|
||||
|
||||
{% endif %}
|
||||
|
||||
{% if subcategories %}
|
||||
|
|
Loading…
Reference in a new issue