Show carousel indicators only if we have more than 1 item
This commit is contained in:
parent
db4362af01
commit
f4b252ff09
1 changed files with 7 additions and 6 deletions
|
@ -2,12 +2,13 @@
|
||||||
<header class="header_slider" style="background-image: url({{ instance.background_image.url }})">
|
<header class="header_slider" style="background-image: url({{ instance.background_image.url }})">
|
||||||
<div id="carousel-header-ungleich" class="carousel slide" data-ride="carousel" data-interval="{{ instance.carousel_data_interval}}">
|
<div id="carousel-header-ungleich" class="carousel slide" data-ride="carousel" data-interval="{{ instance.carousel_data_interval}}">
|
||||||
<!-- Indicators -->
|
<!-- Indicators -->
|
||||||
|
{% if instance.child_plugin_instances|length > 1 %}
|
||||||
<ol class="carousel-indicators">
|
<ol class="carousel-indicators">
|
||||||
{% for plugin in instance.child_plugin_instances %}
|
{% for plugin in instance.child_plugin_instances %}
|
||||||
<li data-target="#carousel-header-ungleich" data-slide-to="{{forloop.counter0}}" {% if forloop.counter0 == 0 %}class="active" {% endif %}></li>
|
<li data-target="#carousel-header-ungleich" data-slide-to="{{forloop.counter0}}" {% if forloop.counter0 == 0 %}class="active" {% endif %}></li>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ol>
|
</ol>
|
||||||
|
{% endif %}
|
||||||
<!-- Wrapper for slides -->
|
<!-- Wrapper for slides -->
|
||||||
<div class="carousel-inner" role="listbox">
|
<div class="carousel-inner" role="listbox">
|
||||||
{% for plugin in instance.child_plugin_instances %}
|
{% for plugin in instance.child_plugin_instances %}
|
||||||
|
|
Loading…
Reference in a new issue