{% extends "base.html" %} {% block title %}Feedbacks dos Tickets{% endblock %} {% block content %} {% set total = feedbacks|length %} {% if total > 0 %} {% set soma_notas = feedbacks|sum(attribute='nota') %} {% set media = (soma_notas / total) | round(1) %} {% endif %}

Resumo das avaliações

Acompanhe notas e comentários registrados pelos usuários.

{{ total }} Feedback{% if total != 1 %}s{% endif %} {{ media if total > 0 else '—' }} Nota média
{% if feedbacks %}
{% for fb in feedbacks %} {% set ticket = tickets.get(fb.ticket_id) %} {% set solicitante = usuarios.get(fb.solicitante_id) %} {% set agente = usuarios.get(fb.agente_id) if fb.agente_id else None %} {% endfor %}
Ticket Solicitante Agente Nota Comentário Data
{% if ticket %} #{{ ticket.id_ticket[:8] }}...
{{ ticket.assunto }} {% else %} Ticket removido {% endif %}
{{ solicitante.nome_completo if solicitante else 'Solicitante removido' }} {{ agente.nome_completo if agente else 'Não atribuído' }} {{ fb.nota }}/5 {% if fb.comentario %} {{ fb.comentario }} {% else %} Sem comentários adicionais {% endif %} {{ fb.data_criacao.strftime('%d/%m/%Y %H:%M') if fb.data_criacao else '-' }}
{% else %}

Nenhum feedback registrado

Assim que os solicitantes avaliarem os tickets, os resultados aparecerão aqui.

{% endif %}
{% endblock %}