{% extends theme('layouts/1-column.html') %} {% from theme('macros/dataset_information.html') import information_col, information_section, information_accordion %} {% from theme('macros/follow.html') import follow_btn with context %} {% from theme('macros/integrate.html') import integrate_btn with context %} {% from theme('macros/paginator.html') import paginator with context %} {% from theme('macros/breadcrumb.html') import breadcrumb with context %} {% from theme('macros/banner_info.html') import banner_info %} {% from theme('macros/leaflet.html') import leaflet_map %} {% from theme('macros/banner_warning.html') import banner_warning %} {% from theme('macros/quality_score_with_warning_below.html') import quality_score_with_warning_below %} ## FIXME: remove inspire:indentifier robots condition when geo.data.gouv.fr is shutdown {% set meta = { 'title': dataset.full_title, 'description': dataset.description|mdstrip(60)|forceescape, 'image': dataset.organization and dataset.organization.logo(external=True) or '', 'keywords': [_('dataset')] + dataset.tags, 'robots': 'noindex, nofollow' if dataset.is_hidden or 'inspire:identifier' in dataset.extras else '', } %} {% set bundle = 'dataset' %} {% set body_class = 'dataset-display' %} {% set community_subtitle = _('Explore with %(certifier)s', certifier=config.SITE_TITLE ) %} {% set read_only_mode = config.READ_ONLY_MODE %} {# Harvesting source #} {% block extra_head %} {% cache cache_duration, 'dataset-extra-head', dataset.id|string, g.lang_code, dataset.last_modified|string %} {% endcache %} {% endblock %} {% block breadcrumb %} {% cache cache_duration, 'dataset-breadcrumb', dataset.id|string, g.lang_code, dataset.last_modified|string %}
  • {{ _('Datasets') }}
  • {{ dataset.acronym or dataset.title|truncate(128) }}
  • {% endcache %} {% endblock %} {% block toolbar %} {{ follow_btn(dataset) }} {{ hook('dataset.display.explore-button') }} {% if can_edit %}
    {{ _('Edit') }}
    {% endif %} {% endblock %} {% block content %} {% cache cache_duration, 'dataset-content', dataset.id|string, reuses.page|string, g.lang_code, current_user.slug or 'anonymous', dataset.last_modified|string %} {{ breadcrumb(self) }}
    {% if dataset.private or dataset.deleted or dataset.archived %}
    {% if dataset.private %}

    {{ _('Private') }}

    {% endif %} {% if dataset.deleted %}

    {{ _('Deleted') }}

    {% endif %} {% if dataset.archived %} {% set title = _('This dataset has been archived automatically because it has been deleted from the remote platform.') if dataset.harvest and dataset.harvest.archived == 'not-on-remote' else _('This dataset has been archived.') %}

    {{ _('Archived') }}

    {% endif %}
    {% endif %}

    {{ dataset.title }} {% if dataset.acronym %}{{ dataset.acronym }}{% endif %}

    {{ _('Description') }}

    {{ dataset.description|markdown }}
    {% if sysadmin %}
    {% endif %} {% if dataset.organization %}

    {{ _('Producer') }}

    {% with organization=dataset.organization, producer_type='organization' %} {% include theme('organization/producer-name-with-logo.html') %} {% endwith %} {% elif dataset.owner %}

    {{ _('Author') }}

    {% with organization=dataset.owner, producer_type='owner' %} {% include theme('organization/producer-name-with-logo.html') %} {% endwith %}

    {% trans date=dataset.created_at|dateformat(format='long'), update=dataset.last_modified|dateformat(format='long'), author=dataset.owner.fullname %}This dataset has been published on the initiative and under the responsibility of {{author}}
    Published on {{date}} and updated on {{update}}{% endtrans %}

    {% endif %} {% if external_source(dataset) %}
    {{ banner_info( "fr-icon-external-link-line", _("This dataset come from an external portal. View the original source.") .format(external_source=external_source(dataset)) )}}
    {% endif %} {# FIXME: remove when geo.data.gouv.fr is shutdown #} {% if 'geop:dataset_id' in dataset.extras %}

    ⚠️ {{ _("This dataset is handled by the geo.data.gouv.fr platform. This platform is not actively maintained and as a result, you may find some bogus data or metadata. More information about the shutdown of geo.data.gouv.fr is available here.").format( geo_link='https://geo.data.gouv.fr', blog_link='https://www.data.gouv.fr/fr/posts/extinction-de-geo-data-gouv-fr/' )}}

    {% endif %}
    {{ hook('dataset.display.transport-banner') }}

    {{ _('Latest update') }}

    {{ dataset.last_update|dateformat(format='long') }}

    {% if dataset.license %}

    {{ _('License') }}

    {% if dataset.license.url %}{% endif %} {{ dataset.license.title }} {% if dataset.license.url %}{% endif %}

    {% endif %} {{quality_score_with_warning_below(dataset)}}
    {{ hook('dataset.display.after-description') }}
    {% set show_all_resources = request.args.get('resources') == 'all' %} {% set grouped_resources = dataset.resources|group_resources_by_type %} {% set nb_groups = grouped_resources.keys()|length %} {% set has_multiple_groups = nb_groups > 1 %} {% set resources_per_page = config.RESOURCES_DEFAULT_PAGE_SIZE %} {% for (type, type_label), resources in grouped_resources.items() %} {% else %}
    {% include theme('svg/blank_state/resource.svg') %}

    {{ _('There are no files for this dataset yet.') }}

    {% if can_edit %}

    {{ _('Add a file') }}

    {% endif %}
    {% endfor %}
    {{ hook('dataset.display.after-files') }}
    {{ hook('dataset.display.after-reuses') }} {% if reuses|length %}

    {{ ngettext('%(num)d Reuse', '%(num)d Reuses', total_reuses) }}

    {% if not read_only_mode %} {% endif %}
    {% for reuse in reuses %}
    {% include theme('reuse/card.html') %}
    {% endfor %}
    {{ paginator(reuses, arg_name='reuses_page', url='#community-reuses') }} {% else %}
    {% include theme('svg/blank_state/reuse.svg') %}

    {{ _('There are no reuses for this dataset yet.') }}

    {{ _('Publish a reuse') }} {{ _("What's a reuse ?") }}

    {% endif %}
    {% if not dataset.metrics.discussions %}
    {% include theme('svg/blank_state/discussion.svg') %}

    {{ _('There are no discussions for this dataset yet.') }}

    {% endif %}
    {% if dataset.community_resources|length %}
    {{ banner_warning( "fr-icon-alert-line", _("These resources are published by the community and the producer isn't responsible for them.") )}}
    {% else %}
    {% include theme('svg/blank_state/resource.svg') %}

    {{ _('There are no community resources for this dataset yet.') }}

    {{ _('Share your resources') }} {{ _('Learn more about the community') }}

    {% endif %}
    {% call() information_section(_('Information')) %}

    {{_('Tags')}}

    {% if dataset.tags %} {% endif %}
    {% if dataset.license %} {% call() information_col(_('License')) %} {% if dataset.license.url %}{% endif %} {{ dataset.license.title }} {% if dataset.license.url %}{% endif %} {% endcall %} {% endif %} {% call() information_col(_('ID')) %} {{dataset.id}} {% endcall %} {% if external_source(dataset) %} {% call() information_col(_('Remote source'), 'text-overflow-ellipsis') %} {{external_source(dataset)}} {% endcall %} {% endif %}
    {% endcall %} {% call() information_section(_('Temporality')) %}
    {% call() information_col(_('Creation')) %} {{dataset.created_at|dateformat(format='long')}} {% endcall %} {% if dataset.frequency %} {% call() information_col(_('Frequency')) %} {{dataset.frequency_label}} {% endcall %} {% endif %} {% if dataset.temporal_coverage %} {% call() information_col(_('Temporal coverage')) %} {{dataset.temporal_coverage|daterange(details=True)}} {% endcall %} {% endif %}
    {% call() information_col(_('Latest update')) %} {{ dataset.last_update|dateformat(format='long') }} {% endcall %}
    {% endcall %} {% if dataset.spatial %} {% call() information_section(_('Spatial coverage')) %}
    {% if dataset.spatial.zones %} {% call() information_col(_('Territorial coverage')) %} {% for zone in dataset.spatial.zones %} {{zone.name}}{% if not loop.last %},{% endif %} {% endfor %} {% endcall %} {% endif %} {% if dataset.spatial.geom %} {% call() information_col(_('Territorial coverage')) %} {{ leaflet_map(dataset.spatial.geom) }} {% endcall %} {% endif %} {% if dataset.spatial.granularity %} {% call() information_col(_('Territorial coverage granularity')) %} {{dataset.spatial.granularity_label}} {% endcall %} {% endif %}
    {% endcall %} {% endif %} {% set schemas = dataset.resources|group_resources_by_schema%} {% if schemas|length %} {% call() information_section(_('Data schema')) %} {% for name in schemas %}

    {{_('The dataset files are following the schema: ')}}

    {{name}}

    {{_('Schemas allow to describe data models, discover how schemas improve your data quality and the available use cases on schema.data.gouv.fr') .format(url=config.SCHEMA_DOCUMENTATION_URL)}}

    {% endfor %} {% endcall %} {% endif %} {% call() information_section(_('Actions')) %}

    {{_('Embed')}}

    {{integrate_btn(dataset)}} {% endcall %} {% if dataset.extras %} {% call(slot) information_accordion(_('Extras')) %} {% if slot == "button" %} {% else %}
    {% call() information_section() %}
    {% for extra_name, extra_value in dataset.extras.items() %} {% call() information_col(extra_name) %} {{extra_value}} {% endcall %} {% endfor %}
    {% endcall %}
    {% endif %} {% endcall %} {% endif %} {% if dataset.harvest %} {% call(slot) information_accordion(_('Harvest')) %} {% if slot == "button" %} {% else %}
    {% call() information_section() %}
    {% for harvest_extra_name, harvest_extra_value in dataset.harvest._data.items() %} {% call() information_col(harvest_extra_name) %} {{harvest_extra_value}} {% endcall %} {% endfor %}
    {% endcall %}
    {% endif %} {% endcall %} {% endif %} {{ hook('dataset.display.metrics') }}
    {% endcache %} {% endblock %}