This repository has been archived on 2023-02-21. You can view files and clone it, but cannot push or open issues or pull requests.
corbo/corbo/templates/corbo/announce_list.html

53 lines
1.5 KiB
HTML

{% extends 'corbo/manage.html' %}
{% load i18n %}
{% block breadcrumb %}
{{ block.super }}
{% if category %}
<a href='{% url "view_category" slug=category.slug %}'>{{ category }}</a>
{% endif %}
{% endblock %}
{% block appbar %}
<h2>{{ category.name }}</h2>
<a class="extra-actions-menu-opener"></a>
<ul class="extra-actions-menu">
<li><a href="{% url 'subscriptions-import' slug=category.slug %}" rel="popup">{% trans 'Import subscriptions' %}</a></li>
</ul>
<a href="{% url 'delete_category' slug=category.slug %}" rel="popup">{% trans 'Delete' %}</a>
<a href="{% url 'edit_category' slug=category.slug %}" rel="popup">{% trans 'Edit' %}</a>
<a href="{% url 'add_announce' slug=category.slug %}">{% trans 'New announce' %}</a>
{% endblock %}
{% block content %}
<div id="management">
{% if object_list %}
<ul class='objects-list single-links'>
{% for announce in object_list %}
<li class="{% if not announce.is_published %}unpublished{% endif %}">
<a href="{% url 'view_announce' pk=announce.id %}">{{ announce.title }}</a>
<div class="datetime">
{% if announce.publication_time %}
{% blocktrans with mtime=announce.publication_time|date:'DATETIME_FORMAT' %}
Published on {{ mtime }}
{% endblocktrans %}
{% endif %}
</div>
</li>
{% endfor %}
</ul>
{% include "gadjo/pagination.html" %}
{% else %}
<div class="big-msg-info">
{% blocktrans %}
This category doesn't have any announces yet. Click on "New announce" button in the top
right of the page to add a first one.
{% endblocktrans %}
</div>
{% endif %}
</div>
{% endblock %}