forked from damnlie/bolt-theme-easy_start
-
Notifications
You must be signed in to change notification settings - Fork 0
/
_aside.twig
30 lines (25 loc) · 1.54 KB
/
_aside.twig
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<div class="span4 sidebar">
{{ widgets('aside_top') }}
{% set relatedrecords = record.related() %}
{% if relatedrecords is not empty %}
<div class="sidebox">
{% for related in relatedrecords %}
<h3 class="sidebox-title"><a href="{{ related.link }}">{{ related.title }}</h3>
<a href="{{ related.link }}"><img src="{{ related.image | thumbnail(150,90,"c")}}"></a>
{% endfor %}
</div>
{% else %}
<div class="sidebox">
{% setcontent stuff='page/1' %}
<h2><a href="{{ stuff.link }}">{{ stuff.title }}</a></h2>
{%if stuff.image %}<a href="{{ stuff.link }}"><img src="{{ stuff.image|thumbnail(150,90,c) }}" class="img-polaroid"></a>{% endif %}
{% setcontent stuff='page/2' %}
<h2><a href="{{ stuff.link }}">{{ stuff.title }}</a></h2>
{%if stuff.image %}<a href="{{ stuff.link }}"><img src="{{ stuff.image|thumbnail(150,90,c) }}" class="img-polaroid"></a>{% endif %}
{% setcontent stuff='page/3' %}
<h2><a href="{{ stuff.link }}">{{ stuff.title }}</a></h2>
{%if stuff.image %}<a href="{{ stuff.link }}"><img src="{{ stuff.image|thumbnail(150,90,c) }}" class="img-polaroid"></a>{% endif %}
</div>
{% endif %}
{{ widgets('aside_bottom') }}
</div>