mirror of
https://github.com/ae-utbm/sith.git
synced 2025-07-10 20:09:25 +00:00
Improve weekmail
This commit is contained in:
@ -1,4 +1,5 @@
|
||||
{% extends "core/base.jinja" %}
|
||||
{% from 'core/macros.jinja' import user_profile_link %}
|
||||
|
||||
{% block title %}
|
||||
{% trans %}Weekmail{% endtrans %}
|
||||
@ -6,7 +7,57 @@
|
||||
|
||||
{% block content %}
|
||||
<h3>{% trans %}Weekmail{% endtrans %}</h3>
|
||||
{{ object }}
|
||||
<h4>{% trans %}Articles in no weekmail yet{% endtrans %}</h4>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<td>{% trans %}Author{% endtrans %}</td>
|
||||
<td>{% trans %}Club{% endtrans %}</td>
|
||||
<td>{% trans %}Title{% endtrans %}</td>
|
||||
<td>{% trans %}Content{% endtrans %}</td>
|
||||
<td>{% trans %}Actions{% endtrans %}</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for a in orphans.all() %}
|
||||
<tr>
|
||||
<td>{{ user_profile_link(a.author) }}</td>
|
||||
<td><a href="{{ a.club.get_absolute_url() }}">{{ a.club }}</a></td>
|
||||
<td>{{ a.title }}</td>
|
||||
<td>{{ a.content|markdown }}</td>
|
||||
<td><a href="?add_article={{ a.id }}">{% trans %}Add to weekmail{% endtrans %}</a></td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
<h4>{% trans %}Articles included the next weekmail{% endtrans %}</h4>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<td>{% trans %}Author{% endtrans %}</td>
|
||||
<td>{% trans %}Club{% endtrans %}</td>
|
||||
<td>{% trans %}Title{% endtrans %}</td>
|
||||
<td>{% trans %}Content{% endtrans %}</td>
|
||||
<td>{% trans %}Actions{% endtrans %}</td>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for a in object.articles.order_by('rank') %}
|
||||
<tr>
|
||||
<td>{{ user_profile_link(a.author) }}</td>
|
||||
<td><a href="{{ a.club.get_absolute_url() }}">{{ a.club }}</a></td>
|
||||
<td>{{ a.title }}</td>
|
||||
<td>{{ a.content|markdown }}</td>
|
||||
<td>
|
||||
<a href="{{ url('com:weekmail_article_edit', article_id=a.id) }}">{% trans %}Edit{% endtrans %}</a> |
|
||||
<a href="?del_article={{ a.id }}">{% trans %}Delete from weekmail{% endtrans %}</a> |
|
||||
<a href="?up_article={{ a.id }}">{% trans %}Up{% endtrans %}</a> |
|
||||
<a href="?down_article={{ a.id }}">{% trans %}Down{% endtrans %}</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
<form action="" method="post" enctype="multipart/form-data">
|
||||
{% csrf_token %}
|
||||
{{ form.as_p() }}
|
||||
|
Reference in New Issue
Block a user