From 790b43ccc36498d360ce60570ed7c3cd066791f6 Mon Sep 17 00:00:00 2001 From: Grizzly Date: Wed, 10 Jul 2019 12:24:06 +0000 Subject: [PATCH] Affichage propre d'un ticket simple --- re2o/settings.py | 1 + tickets/templates/tickets/aff_ticket.html | 19 ++++++++++++++++++- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/re2o/settings.py b/re2o/settings.py index ce7d3257..96fa9308 100644 --- a/re2o/settings.py +++ b/re2o/settings.py @@ -62,6 +62,7 @@ DJANGO_CONTRIB_APPS = ( 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', + 'django.contrib.humanize', ) EXTERNAL_CONTRIB_APPS = ( 'bootstrap3', diff --git a/tickets/templates/tickets/aff_ticket.html b/tickets/templates/tickets/aff_ticket.html index 4436182a..242aa4f4 100644 --- a/tickets/templates/tickets/aff_ticket.html +++ b/tickets/templates/tickets/aff_ticket.html @@ -25,11 +25,28 @@ with this program; if not, write to the Free Software Foundation, Inc., {% load bootstrap3 %} {% load i18n %} +{% load humanize %} {% block title %}{% trans "Tickets" %}{% endblock %} {% block content %} -{{ ticket.title }} +

Ticket #{{ticket.id}}

+ +
+
+ {% trans "Opened by" %} + + {{ ticket.user.get_full_name }} + + {{ ticket.date | naturalday}}. +
+
+ +

{% trans "Title:" %} {{ticket.title}}

+

{% trans "Description" %} {{ ticket.description }}

+ +
+
{% endblock %}