mirror of https://github.com/scrapy/scrapy.git
Adding if clause that will display blog entries box only if there are any entry to list
--HG-- extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%40109
This commit is contained in:
parent
56e110af78
commit
4c193f47ed
|
|
@ -32,10 +32,12 @@
|
|||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% load lastblogentry %}
|
||||
{% get_latest_blog_entries 2 as entries %}
|
||||
|
||||
{% if entries %}
|
||||
<div class="box">
|
||||
<h3>Scrapy Weblog</h3>
|
||||
{% load lastblogentry %}
|
||||
{% get_latest_blog_entries 2 as entries %}
|
||||
|
||||
{% for entry in entries %}
|
||||
<div class="post{% if forloop.last %} last{% endif %}">
|
||||
|
|
@ -46,6 +48,7 @@
|
|||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
|
|
|||
Loading…
Reference in New Issue