Commit 43d9bf13 authored by Øyvind gjesdal's avatar Øyvind gjesdal
Browse files

bruk variabler for sammensatt, php feiler og models.collection | length faller ut

parent 83d4cb9a
Pipeline #48919 passed with stages
in 1 minute and 29 seconds
...@@ -221,18 +221,29 @@ ...@@ -221,18 +221,29 @@
</p> </p>
{%endif%} {%endif%}
</div> </div>
{% if models.events | length > 0 %}
{% set events_enabled = true %}
{% else %}
{% set events_enabled = false %}
{% endif %}
{% if models.collections | length > 0 %}
{% set collections_enabled = true %}
{% else %}
{% set collections_enabled = false %}
{% endif %}
<!-- KNYTTET TIL... --> <!-- KNYTTET TIL... -->
<div class="twelve wide column lightgrey"> <div class="twelve wide column lightgrey">
{% if (models.events| length > 0) || models.collection | length > 0 %} {% if events_enabled || models_enabled %}
<!-- COLLECTIONS --> <!-- COLLECTIONS -->
{% if models.collections|length > 0 %} {% if collections_enabled %}
<span class="header">Knyttet til følgende samlinger:</span> <span class="header">Knyttet til følgende samlinger:</span>
{% include "../../includes/collections.inc" %} {% include "../../includes/collections.inc" %}
<br /> <br />
{% endif %} {% endif %}
<!-- EVENTS --> <!-- EVENTS -->
{% if models.events| length > 0 %} {% if events_enabled %}
<span class="header">Knyttet til følgende hendelser:</span> <span class="header">Knyttet til følgende hendelser:</span>
{%include "../../includes/events.inc"%} {%include "../../includes/events.inc"%}
<br /> <br />
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment