Skip to content

Commit

Permalink
add conditional to show closing date (#363)
Browse files Browse the repository at this point in the history
  • Loading branch information
erivanio authored Aug 31, 2021
1 parent b0c430b commit f80cf12
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/templates/components/document-opinions.html
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,12 @@
<h1 class="js-documentTitle" >{{ object.title }}</h1>
<p class="js-documentDescription description">{{ object.description }}</p>
<div class="infoBottom">

{% now "Y-m-d" as todays_date %}
{% if group.closing_date|date:"Y-m-d" >= todays_date %}
<span class="date -active">Aberto até {{group.closing_date|date:'d/m/Y'}}</span>
{% else %}
<span class="date -inactive">Participação encerrada em {{group.closing_date|date:'d/m/Y'}}</span>
{% endif %}
<a href="{% url 'download-csv' group.id %}"><span class="date -csvExport">Exportar CSV </span>{% include "svgs/export-icon.html" %}</a>
</div>

Expand Down

0 comments on commit f80cf12

Please sign in to comment.