diff options
author | Ismael Carnales <icarnales@gmail.com> | 2009-10-31 17:28:53 +0100 |
---|---|---|
committer | Ismael Carnales <icarnales@gmail.com> | 2009-11-10 01:24:51 +0100 |
commit | 522838d28153fc05d10fc7913babf477894aab79 (patch) | |
tree | 38ae15054fcb16e56990a388564c618e55275620 /templates/news | |
parent | a008b0de807fab5285cd481a8a227ae06b1e1c19 (diff) | |
download | archweb-522838d28153fc05d10fc7913babf477894aab79.tar.gz archweb-522838d28153fc05d10fc7913babf477894aab79.tar.xz |
updated news list template
- added title
- added permission checks
Diffstat (limited to 'templates/news')
-rw-r--r-- | templates/news/list.html | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/templates/news/list.html b/templates/news/list.html index 0edaae1..a35c41e 100644 --- a/templates/news/list.html +++ b/templates/news/list.html @@ -1,5 +1,5 @@ {% extends "base.html" %} - +{% block title %}Arch Linux - News{% endblock %} {% block content %} <div class="greybox"> {% if perms.main.add_news %} @@ -14,10 +14,12 @@ <td>{{ item.postdate }}</td> <td><a href="{{ item.get_absolute_url }}">{{ item.title }}</a></td> <td> - {% comment %}{% if item.author %}{% ifequal user.username item.author.username %}{% endcomment %} + {% 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> - {% comment %}{% endifequal %}{% endif %}{% endcomment %} + {% endif %} </td> </tr> {% endfor %} |