{% load combo assets %}
{% block cell-content %}
{% if forms %}
<ul>
  {% for data in forms.data|dictsortreversed:"form_receipt_datetime" %}
  {% if data.url and data.title %}
  <li class="{{ data.category_slug }}{% if data.status_css_class %} {{data.status_css_class}}{% endif %}">
    <div class="form-name" style="background-image: url({% asset_url "category:"|add:data.category_slug %})">{{ data.name }}</div>
    <div class="form-details">
      {% if not draft %}
      <div class="form-status">{{ data.status }}</div>
      {% endif %}
      <div class="form-created"><span class="label">Créée le :</span> {{ data.datetime|strptime:"%Y-%m-%d %H:%M:%S"|date:"d/m/Y" }}</div>
      {% if not draft %}
      <div class="form-updated"><span class="label">Mise à jour :</span> {{ data.last_update_time|strptime:"%Y-%m-%d %H:%M:%S"|date:"d/m/Y" }}</div>
      {% endif %}
      <div class="form-url"><a href="{{ data.url }}">{{ button_label|default:"Ouvrir" }}</a></div>
    </div>
    {% endif %}
  {% endfor %}
</ul>
{% endif %}
{% endblock %}
