{% extends "core.html" %} {% block content %}

{{ product.name }}

Version: {{ product.version }} ID: {{ product.id }} Uploaded: {{ product.uploaded.strftime('%Y-%m-%d %H:%M:%S') }} Modified: {{ product.updated.strftime('%Y-%m-%d %H:%M:%S') }} Owner: {{ product.owner }}

Product Description

{% markdown %}{{ product.description }}{% endmarkdown %}

Sources

{% for slug, source in sources.items() %} {% endfor %}
Slug Link Description Size
{{slug}} {{ source.name }} {{ source.description }} {{ source.size | filesizeformat }}
{% if product.metadata %}

Metadata

{% for key, value in product.metadata.model_dump().items() %} {% if key != 'metadata_type' %}
  • {{ key }}
  • {% if value is mapping %}
  • {% for keysub1, valuesub1 in value.items() %} {# Two possible cases: valuesub1 can be iterable OR it can just be a value #} {% if valuesub1 is iterable and valuesub1 is not string %} {% if loop.index == 1 %} {% for keysub2, valuesub2 in valuesub1.items() %} {% endfor %} {% endif %} {% for keysub2, valuesub2 in valuesub1.items() %} {% endfor %} {% else %} {% endif %} {% endfor %}
    {{ keysub2 }}
    {{ valuesub2 }}
    {{ keysub1 }} {{ valuesub1 }}
  • {% else %}
  • {{ value }}
  • {% endif %}
{% endif %} {% endfor %} {% endif %}
{% if product.child_of %}

Parents:

{% endif %} {% if product.parent_of %}

Children:

{% endif %} {% if product.collections %}

Collections

{% endif %}

Readers

{% for reader in product.readers %} {{reader}} {% endfor %}

Writers

{% for writer in product.writers %} {{writer}} {% endfor %}

Version History

{% if request.user.groups.intersection(product.writers) or "hippo:admin" in request.auth.scopes %} Edit {% endif %} {% for version, metadata in versions.items() %} {% endfor %}
Version Updated
{% if version != product.version %} {{ version }} {% else %} {{ version }} {% endif %}
{{ metadata.updated.strftime('%Y-%m-%d %H:%M:%S') }}
{% endblock %}