Commit 7dcdbd9d authored by Carlo Joseph Echon's avatar Carlo Joseph Echon 🐟

Changed the pub date in templates so it outputs the required format

parent 211a8543
......@@ -3,7 +3,7 @@
{% block content %}
<h1>{{announcement.announcement_title}}</h1>
<div>
<h2>by {{announcement.author.first_name}} {{announcement.author.last_name}}, {{announcement.pub_date}}</h2>
<h2>by {{announcement.author.first_name}} {{announcement.author.last_name}}, {{announcement.pub_date|date:"d/m/Y"}}</h2>
<p>
Description: {{announcement.announcement_body}}<br><br>
Reaction:<br>
......
......@@ -7,7 +7,7 @@
{% if announcement_list %}
<ul>
{% for announcement in announcement_list %}
<li><a href="{% url 'announcements:details' announcement.id %}">{{announcement.announcement_title}}</a> by {{announcement.author.first_name}} {{announcement.author.last_name}} dated {{announcement.pub_date}}</li>
<li><a href="{% url 'announcements:details' announcement.id %}">{{announcement.announcement_title}}</a> by {{announcement.author.first_name}} {{announcement.author.last_name}} dated {{announcement.pub_date|date:"d/m/Y"}}</li>
{% endfor %}
</ul>
{% else %}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment