{% load common %} {% load data_view_config %} {% include "catmaid/common_data_view_header.html" %} {% with sort=config|get_or_none:"sort"|default_if_none:1 %} {% with filter_tags=config|get_or_none:"filter_tags"|default_if_none:0 %} {% with row_tags=config|get_or_none:"row_tags"|default_if_none:0 %} {% with col_tags=config|get_or_none:"col_tags"|default_if_none:0 %} {% with linked_stacks=config|get_or_none:"linked_stacks"|default_if_none:"all" %} {% with force_stack_list=config|get_or_none:"force_stack_list"|default_if_none:0 %} {% with catalogue_link=config|get_or_none:"catalogue_link"|default_if_none:1 %} {% with sample_images=config|get_or_none:"sample_images"|default_if_none:0 %} {% with sample_slice=config|get_or_none:"sample_slice"|default_if_none:"center" %} {% with sample_width=config|get_or_none:"sample_width"|default_if_none:-1 %} {% with sample_height=config|get_or_none:"sample_height"|default_if_none:-1 %} {% if not row_tags or not col_tags %} There are no row or no column tags defined. Without these, this data view can't be rendered. Please adjust your configuration. {% else %} {# Have one empty field in the upper left corner #} {% for ct in col_tags %} {% endfor %} {% for rt in row_tags %} {% for ct in col_tags %} {% tagged_projects ct rt filter_tags as tprojects sort %} {% cycle 'even' 'odd' as rowtype silent %} {% if sample_images %} {% endfor %} {% endfor %}
{{ ct }}
{{ rt }} {% else %} {% endif %} {% for p in tprojects %} {% with stacks=p.stacks|order_by:'id'|filter_stacks:linked_stacks %} {# Make the project name a link if we are not forced to have #} {# a stack list and only one stack is available. Draw a definiton #} {# list otherwise. #} {% if not force_stack_list and stacks|length == 1 and not sample_images %} {{ p.title }}
{% elif sample_images %} {% for s in stacks %} {% with slice=s|get_slice:sample_slice %} Sample image for {{ s.title }} on slice {{ slice }} -1 %} width="{{ sample_width }}" {% endif %} {% if sample_height > -1 %} height="{{ sample_height }}" {% endif %} /> {% endwith %} {% endfor %} {% else %}
{{ p.title }}
{% for s in stacks %}
{{ s.title }}
{% endfor %} {# Optionally, add the the neuron catalogue link #} {% if p.is_catalogueable and catalogue_link %}
Neuron Catalogue
{% endif %}
{% endif %} {% endwith %} {% endfor %} {% if tprojects|length == 0 %} - {% endif %}
{% endif %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %} {% endwith %}