{% extends "layout.html" %} {% block title_name %} - {{ source.name }}{% endblock %} {% block breadcrumb %} {{ [[_('source'), 'source_index'], source.name]|crumb }} {% endblock %} {% block content %}
{% if 'contributor'|is_authorized %} {{ _('edit')|button(url_for('source_update', id_=source.id)) }} {{ source|display_delete_link }} {% endif %} {{ source.id|bookmark_toggle }}

{{ source.name }}

{{ profile_image_id|display_profile_image }}
{{ info|display_info }} {{ source|note }} {{ source|display_external_references }} {{ source|description }}
{% for name in ['event', 'actor', 'place', 'feature', 'stratigraphic-unit', 'find'] %} {% if name not in ['feature', 'stratigraphic-unit', 'find'] or tables[name].rows %}
{% if 'contributor'|is_authorized and name not in ['feature', 'stratigraphic-unit', 'find'] %}
{{ _('add')|button(url_for('source_add', id_=source.id, class_name=name)) }} {% if name == 'place' %} {{ _('place')|button(url_for('place_insert', origin_id=source.id)) }} {% else %} {% for code in config['CLASS_CODES'][name]%} {{ code|get_class_name|button(url_for(name + '_insert', code=code, origin_id=source.id)) }} {% endfor %} {% endif %}
{% endif %} {{ tables[name].display(name)|safe }}
{% endif %} {% endfor %}
{% if 'contributor'|is_authorized %}
{{ _('add')|button(url_for('entity_add_reference', id_=source.id)) }} {{ _('bibliography')|button(url_for('reference_insert', code='bibliography', origin_id=source.id)) }} {{ _('edition')|button(url_for('reference_insert', code='edition', origin_id=source.id)) }} {{ _('external reference')|button(url_for('reference_insert', code='external_reference', origin_id=source.id)) }}
{% endif %} {{ tables['reference'].display('reference')|safe }}
{% if 'contributor'|is_authorized %}
{{ _('text')|button(url_for('translation_insert', source_id=source.id)) }}
{% endif %} {{ tables['text'].display('text')|safe }}
{% if 'contributor'|is_authorized %}
{{ _('add')|button(url_for('entity_add_file', id_=source.id)) }} {{ _('file')|button(url_for('file_insert', origin_id=source.id)) }}
{% endif %} {{ tables['file'].display('file')|safe }}
{% endblock %}