{# La liste des travaux de l'atelier. Rendue dans la page, et rechargée telle quelle (GET …/atelier/list) quand /status dit que quelque chose a bougé : une seule écriture des cartes, côté serveur. Variables : rows (JobRowPresenter), site, canEdit. #} {% set openRows = rows|filter(r => r.open) %} {% set failedRows = rows|filter(r => r.status == 'failed') %} {% set doneRows = rows|filter(r => r.status == 'done') %} {% set cancelledRows = rows|filter(r => r.status == 'cancelled') %} {% if rows is empty %}

Aucune image demandée pour l'instant.

Décrivez-en une ci-dessus, ou retouchez une image de votre médiathèque : elle apparaîtra ici, puis dans la médiathèque dès qu'elle sera dessinée.

{% endif %} {% if openRows is not empty %}

En cours {{ openRows|length }}

{% for r in openRows %}
{% if r.sourceUrl %} {% else %} {% endif %}
{{ r.kindLabel }} {% if r.status == 'running' %}{% endif %} {{ r.statusLabel }} {% if r.position or r.eta %} {% if r.position %}position {{ r.position }}{% endif %}{% if r.position and r.eta %} · {% endif %}{% if r.eta %}{{ r.eta }}{% endif %} {% endif %} {% if r.priority %}Prioritaire{% endif %}

{{ r.prompt }}

{% if r.location %}{{ r.location }} · {% endif %}{{ r.width }} × {{ r.height }} · dossier « {{ r.folder }} » · demandée le {{ r.createdAt|date('d/m à H:i') }}
{% if r.error %}
{{ r.error }}
{% endif %}
{% if canEdit and r.canCancel %}
{% endif %}
{% endfor %}
{% endif %} {% if failedRows is not empty %}

En échec {{ failedRows|length }}

{% for r in failedRows %}
{% if r.sourceUrl %}{% else %}{% endif %}
{{ r.kindLabel }} {{ r.statusLabel }}

{{ r.prompt }}

{{ r.error ?? 'Le poste n\'a pas rendu d\'image.' }}
{% if r.location %}{{ r.location }} · {% endif %}{{ r.width }} × {{ r.height }} · {{ r.createdAt|date('d/m à H:i') }}
{% if canEdit and r.canRetry %}
{% endif %}
{% endfor %}
{% endif %} {% if doneRows is not empty %}

Livrées récemment {{ doneRows|length }} dans la médiathèque, dossier « ai-generated »

{% for r in doneRows %}
{{ r.location ?? (r.prompt|slice(0, 80)) }} {% if r.sourceUrl %}Retouche{% endif %}

{{ r.prompt }}

{% if r.location %}{{ r.location }} · {% endif %}{{ r.width }} × {{ r.height }}{% if r.finishedAt %} · {{ r.finishedAt|date('d/m à H:i') }}{% endif %}
{% if canEdit %} {% endif %}
{% endfor %}
{% endif %} {% if cancelledRows is not empty %}
{{ cancelledRows|length }} demande{{ cancelledRows|length > 1 ? 's' : '' }} annulée{{ cancelledRows|length > 1 ? 's' : '' }}
{% endif %}