{% for pair in resource.spec %} {% assign name = pair[0] %} {% assign spec = pair[1] %} {% assign type = spec.type %}
{% if type == 'string' %} {% elsif type == 'text' %} {% elsif type == 'number' %} {% elsif type == 'enum' or type == 'foreign-key' %} {% elsif type == 'video' %}
{% elsif type == 'image' %}
{{spec.value.caption | escape}}
{% elsif type == 'file' %}
(view)
{% elsif type == 'date' %}
{% elsif type == 'flag' %}
{% elsif type == 'tag-list' %}
{% elsif type == 'link-list' %} {% elsif type == 'media-list' or type == 'media' %}
    {% for image in spec.value %} {% if image.type and (image.type == "vimeo" or image.type == "youtube" or image.type == "video") %}
  1. {% elsif image.type and (image.type == "audio" or image.type == "soundcloud") %}
  2. {% elsif image.type and image.type == "link" %} {% else %}
  3. {{image.caption | strip_html}}
  4. {% endif %} {% endfor %}
{% elsif type == 'captioned-image-list' or type == 'gallery' %}
    {% for image in spec.value %}
  1. {{image.caption | strip_html}}
  2. {% endfor %}
{% elsif type == 'double-captioned-image-list' %}
    {% for image in spec.value %}
  1. {{image.caption | strip_html}}
  2. {% endfor %}
{% elsif type == 'triple-captioned-image-list' %}
    {% for image in spec.value %}
  1. {{image.caption | strip_html}}
  2. {% endfor %}
{% elsif type == 'meta' %} {% else %}

Admin template doesn't support '{{type}}' properties!

{% endif %}
{% endfor %}