{# Adds 'Add Dataset' button #}

{% set dataset_type = dataset_type if dataset_type else 'dataset' %}

{% if group %}
    {% link_for _('Add Dataset'), controller='package', action='new', group=group, class_='btn btn-primary', icon='plus-square' %}
{% else %}
    {% link_for _('Add ' + dataset_type.title()), controller='package', action='new', named_route=dataset_type + '_new', class_='btn btn-primary', icon='plus-square' %}
{% endif %}
