From e98c966a1f1ab4ec9f57f890f9fdef6ac9ecbed0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Knud=20M=C3=B6ller?= Date: Thu, 11 Apr 2024 02:28:41 +0200 Subject: [PATCH] add sample_record metadata field --- CHANGELOG.md | 2 ++ .../datasetsnippets/snippets/additional_info.html | 12 ++++++++++++ 2 files changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 361caf2..687d4e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,8 @@ ## Development +- Add new metadata field `sample_record` (to link to the matching "Musterdatensatz", see https://www.dcat-ap.de/def/dcatde/2.0/implRules/#verwendung-des-musterdatenkatalogs-fur-kommunen). + ## [0.1.4](https://github.com/berlinonline/ckanext-datasetsnippets/releases/tag/0.1.4) _(2024-03-22)_ diff --git a/ckanext/datasetsnippets/templates/datasetsnippets/snippets/additional_info.html b/ckanext/datasetsnippets/templates/datasetsnippets/snippets/additional_info.html index c11f829..6b9ce85 100644 --- a/ckanext/datasetsnippets/templates/datasetsnippets/snippets/additional_info.html +++ b/ckanext/datasetsnippets/templates/datasetsnippets/snippets/additional_info.html @@ -30,6 +30,18 @@

{{ _('Informationen zum Datensatz') }}

{% endif %} {{ h.snippet('datasetsnippets/snippets/metadata_item.html', name='geographical_coverage', title='Geographischer Bezug', value=package.geographical_coverage, create_link=True) }} {{ h.snippet('datasetsnippets/snippets/metadata_item.html', name='geographical_granularity', title='Geographische Granularität', value=package.geographical_granularity, create_link=True) }} + {# Musterdatensatz #} + {% if package.sample_record %} +
  • +
    +
    {{ _('Musterdatensatz') }}:
    +
    +
    + {{ h.berlin_render_sample_record(package.sample_record, class='extern') }} +
    +
  • + {% endif %} + {% if package.temporal_coverage_from %}