-
Notifications
You must be signed in to change notification settings - Fork 0
/
notice.html
79 lines (75 loc) · 3.06 KB
/
notice.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>系统公告</title>
<!-- 最新版本的 Bootstrap 核心 CSS 文件 -->
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css"
integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
</head>
<body>
{#导航栏#}
<nav class="navbar navbar-default">
<div class="container-fluid">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse"
data-target="#bs-example-navbar-collapse-1" aria-expanded="false">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">崝赛</a>
</div>
<!-- Collect the nav links, forms, and other content for toggling -->
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
<ul class="nav navbar-nav">
<li><a href="/">主页</a></li>
<li><a href="/notice?matchID=0">通知公告</a></li>
<li><a href="/anticheating/">烽火台</a></li>
</ul>
<form class="navbar-form navbar-left" action="/search/">
<div class="form-group">
<input type="text" class="form-control" placeholder="Search">
</div>
<button type="submit" class="btn btn-default">搜索</button>
</form>
<ul class="nav navbar-nav navbar-right">
{% if user.is_authenticated %}
<li><a href="/user/{{ user.id }}">{{ user.username }},您好!</a></li>
<li><a href="/password_change/">修改密码</a></li>
{% else %}
<li><a href="/login/">登陆</a></li>
{% endif %}
<li><a href="/logout/">注销</a></li>
</ul>
</div><!-- /.navbar-collapse -->
</div><!-- /.container-fluid -->
</nav>
{#通知列表#}
<div class="container">
{#主体#}
{% for notice_info in notice %}
<div class="jumbotron">
<h3>{{ notice_info.notice_content }}</h3>
<p>{{ notice_info.notice_time | date:'Y年m月d日 H:i' }}</p>
</div>
{% endfor %}
</div>
{# 通知翻页按钮 #}
<div class="container">
<nav aria-label="...">
<ul class="pager">
{% if notice.has_previous %}
<li><a href="?page={{ notice.previous_page_number }}">上一页</a></li>
{% endif %}
第 {{ notice.number }} / {{ notice.paginator.num_pages }}页
{% if notice.has_next %}
<li><a href="?page={{ notice.next_page_number }}">下一页</a></li>
{% endif %}
</ul>
</nav>
</div>
</body>
</html>