Skip to content
Snippets Groups Projects
Commit edb627fc authored by Thorge Petersen's avatar Thorge Petersen
Browse files

Show appl. legislation and hvd category in package's info sidebar

parent 1d32eb58
Branches
Tags
1 merge request!52Added applicableLegislation and hvdCategory support
...@@ -91,6 +91,36 @@ Example: ...@@ -91,6 +91,36 @@ Example:
{% endif %} {% endif %}
{% endblock musterdatensatz %} {% endblock musterdatensatz %}
{% block applicableLegislation %}
{% if pkg.applicableLegislation %}
{% set applicable_legislation_urls = pkg.applicableLegislation.split(',') %}
<div class="applicableLegislation-detail info-detail">
<div>{{ _('Applicable Legislation') }}</div>
<ul class="inline-list">
{% for url in applicable_legislation_urls %}
{% set applicable_legislation = h.odsh_load_applicable_legislations(url.strip('{}')) %}
<li><a href="{{ applicable_legislation.uri }}">{{ applicable_legislation.short_title if applicable_legislation.short_title else applicable_legislation.title }}</a></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% endblock applicableLegislation %}
{% block hvdCategories %}
{% if pkg.hvdCategory %}
{% set hvd_urls = pkg.hvdCategory.split(',') %}
<div class="hvdCategories-detail info-detail">
<div>{{ _('HVD Categories') }}</div>
<ul class="inline-list">
{% for url in hvd_urls %}
{% set hvd = h.odsh_load_hvd_categories(url.strip('{}')) %}
<li><a href="{{ hvd.uri }}">{{ hvd.short_title if hvd.short_title else hvd.title }}</a></li>
{% endfor %}
</ul>
</div>
{% endif %}
{% endblock hvdCategories %}
{% endblock package_info_inner %} {% endblock package_info_inner %}
</div> </div>
{% set map_text = h.odsh_get_spatial_text(pkg) %} {% set map_text = h.odsh_get_spatial_text(pkg) %}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment