522838d281
- added title - added permission checks
29 lines
802 B
HTML
29 lines
802 B
HTML
{% extends "base.html" %}
|
|
{% block title %}Arch Linux - News{% endblock %}
|
|
{% block content %}
|
|
<div class="greybox">
|
|
{% if perms.main.add_news %}
|
|
<div style="float:right">
|
|
<a href="/news/add/">Add News Item</a>
|
|
</div>
|
|
{% endif %}
|
|
<h2 class="title">News Updates</h2>
|
|
<table class="results" width="100%">
|
|
{% for item in news_list %}
|
|
<tr class="{% cycle pkgr2,pkgr1 %}">
|
|
<td>{{ item.postdate }}</td>
|
|
<td><a href="{{ item.get_absolute_url }}">{{ item.title }}</a></td>
|
|
<td>
|
|
{% if perms.main.change_news %}
|
|
<a href="/news/edit/{{ item.id }}/">edit</a>
|
|
{% endif %}
|
|
{% if perms.main.delete_news %}
|
|
<a href="/news/delete/{{ item.id }}/">delete</a>
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</table>
|
|
</div>
|
|
{% endblock %}
|