From a998ad94f454d3a145650671ba1a8731f1bfaea4 Mon Sep 17 00:00:00 2001 From: Weitian LI Date: Wed, 23 Apr 2014 01:45:46 +0800 Subject: * implemented 'ListNoticeView' based on ListView * added list_notice template, css, urls * updated models and admin of app notice * updated navbar.html --- notice/templates/notice/list_notice.html | 50 ++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 notice/templates/notice/list_notice.html (limited to 'notice/templates') diff --git a/notice/templates/notice/list_notice.html b/notice/templates/notice/list_notice.html new file mode 100644 index 0000000..77d194c --- /dev/null +++ b/notice/templates/notice/list_notice.html @@ -0,0 +1,50 @@ +{% extends 'base.html' %} +{% load staticfiles %} +{% load url from future %} +{% load i18n %} +{% load bootstrap3 %} + +{# template to show notice list #} + +{% block title %} +全部通知 | 2014 SKA Summer School +{% endblock %} + +{% block css_extra %} + +{% endblock %} + +{% block content %} +
+

全部通知

+
+ {% for notice in object_list %} +
+

{{ notice.title }} {% if notice.is_important %}重要{% endif %}

+

{{ notice.show_pubtime }}, {{ notice.category.category_name }}

+
+
+ {{ notice.contents }} +
+ {% if notice.attachments %} +
+
    + {% for attachment in notice.get_attachment_list %} +
  • + 附件{{ forloop.counter }}: + {{ attachment.title }} +
  • + {% endfor %} +
+
+ {% endif %} +
+ {% empty %} +
+ 暂时没有通知,多谢您的关注…… +
+ {% endfor %} +
+{% endblock %} + +{# vim: set ts=8 sw=2 tw=0 fenc=utf-8 ft=htmldjango.html: #} -- cgit v1.2.2