Show More
@@ -1,182 +1,182 b'' | |||
|
1 | 1 | {% extends "boards/base.html" %} |
|
2 | 2 | |
|
3 | 3 | {% load i18n %} |
|
4 | 4 | {% load markup %} |
|
5 | 5 | |
|
6 | 6 | {% block head %} |
|
7 | 7 | {% if tag %} |
|
8 | 8 | <title>Neboard - {{ tag }}</title> |
|
9 | 9 | {% else %} |
|
10 | 10 | <title>Neboard</title> |
|
11 | 11 | {% endif %} |
|
12 | 12 | {% endblock %} |
|
13 | 13 | |
|
14 | 14 | {% block content %} |
|
15 | 15 | |
|
16 | 16 | {% if tag %} |
|
17 | 17 | <div class="tag_info"> |
|
18 | 18 | <h2>{% trans 'Tag: ' %}{{ tag }}</h2> |
|
19 | 19 | </div> |
|
20 | 20 | {% endif %} |
|
21 | 21 | |
|
22 | 22 | {% if threads %} |
|
23 | 23 | {% for thread in threads %} |
|
24 | 24 | <div class="thread"> |
|
25 | 25 | {% if thread.bumpable %} |
|
26 | 26 | <div class="post" id="{{ thread.thread.id }}"> |
|
27 | 27 | {% else %} |
|
28 | 28 | <div class="post dead_post" id="{{ thread.thread.id }}"> |
|
29 | 29 | {% endif %} |
|
30 | 30 | {% if thread.thread.image %} |
|
31 | 31 | <div class="image"> |
|
32 | 32 | <a class="fancy" |
|
33 | 33 | href="{{ thread.thread.image.url }}"><img |
|
34 | 34 | src="{{ thread.thread.image.url_200x150 }}" |
|
35 | 35 | alt="{% trans 'Post image' %}" |
|
36 | 36 | data-width="{{ thread.thread.image_width }}" |
|
37 | 37 | data-height="{{ thread.thread.image_height }}" /> |
|
38 | 38 | </a> |
|
39 | 39 | </div> |
|
40 | 40 | {% endif %} |
|
41 | 41 | <div class="message"> |
|
42 | 42 | <div class="post-info"> |
|
43 | 43 | <span class="title">{{ thread.thread.title }}</span> |
|
44 | 44 | <a class="post_id" href="{% url 'thread' thread.thread.id %}" |
|
45 | 45 | >(#{{ thread.thread.id }})</a> |
|
46 | 46 | [{{ thread.thread.pub_time }}] |
|
47 | 47 | [<a class="link" href="{% url 'thread' thread.thread.id %}#form" |
|
48 | 48 | >{% trans "Reply" %}</a>] |
|
49 | 49 | |
|
50 | 50 | {% if user.is_moderator %} |
|
51 | 51 | <span class="moderator_info"> |
|
52 | 52 | [<a href="{% url 'delete' post_id=thread.thread.id %}?next={{ request.path }}" |
|
53 | 53 | >{% trans 'Delete' %}</a>] |
|
54 | 54 | ({{ thread.thread.poster_ip }}) |
|
55 | 55 | [<a href="{% url 'ban' post_id=thread.thread.id %}?next={{ request.path }}" |
|
56 | 56 | >{% trans 'Ban IP' %}</a>] |
|
57 | 57 | </span> |
|
58 | 58 | {% endif %} |
|
59 | 59 | </div> |
|
60 | 60 | {% autoescape off %} |
|
61 | 61 | {{ thread.thread.text.rendered|truncatewords_html:50 }} |
|
62 | 62 | {% endautoescape %} |
|
63 | 63 | </div> |
|
64 | 64 | <div class="metadata"> |
|
65 | 65 | {{ thread.thread.get_reply_count }} {% trans 'replies' %}, |
|
66 | 66 | {{ thread.thread.get_images_count }} {% trans 'images' %}. |
|
67 |
{% if thread.t |
|
|
67 | {% if thread.thread.tags %} | |
|
68 | 68 | <span class="tags">{% trans 'Tags' %}: |
|
69 | 69 | {% for tag in thread.thread.tags.all %} |
|
70 | 70 | <a class="tag" href=" |
|
71 | 71 | {% url 'tag' tag_name=tag.name %}"> |
|
72 | 72 | {{ tag.name }}</a> |
|
73 | 73 | {% endfor %} |
|
74 | 74 | </span> |
|
75 | 75 | {% endif %} |
|
76 | 76 | </div> |
|
77 | 77 | </div> |
|
78 | 78 | {% if thread.thread.get_last_replies.exists %} |
|
79 | 79 | <div class="last-replies"> |
|
80 | 80 | {% for post in thread.thread.get_last_replies %} |
|
81 | 81 | {% if thread.bumpable %} |
|
82 | 82 | <div class="post" id="{{ post.id }}"> |
|
83 | 83 | {% else %} |
|
84 | 84 | <div class="post dead_post" id="{{ post.id }}"> |
|
85 | 85 | {% endif %} |
|
86 | 86 | {% if post.image %} |
|
87 | 87 | <div class="image"> |
|
88 | 88 | <a class="fancy" |
|
89 | 89 | href="{{ post.image.url }}"><img |
|
90 | 90 | src=" {{ post.image.url_200x150 }}" |
|
91 | 91 | alt="{% trans 'Post image' %}" |
|
92 | 92 | data-width="{{ post.image_width }}" |
|
93 | 93 | data-height="{{ post.image_height }}"/> |
|
94 | 94 | </a> |
|
95 | 95 | </div> |
|
96 | 96 | {% endif %} |
|
97 | 97 | <div class="message"> |
|
98 | 98 | <div class="post-info"> |
|
99 | 99 | <span class="title">{{ post.title }}</span> |
|
100 | 100 | <a class="post_id" href=" |
|
101 | 101 | {% url 'thread' thread.thread.id %}#{{ post.id }}"> |
|
102 | 102 | (#{{ post.id }})</a> |
|
103 | 103 | [{{ post.pub_time }}] |
|
104 | 104 | </div> |
|
105 | 105 | {% autoescape off %} |
|
106 | 106 | {{ post.text.rendered|truncatewords_html:50 }} |
|
107 | 107 | {% endautoescape %} |
|
108 | 108 | </div> |
|
109 | 109 | </div> |
|
110 | 110 | {% endfor %} |
|
111 | 111 | </div> |
|
112 | 112 | {% endif %} |
|
113 | 113 | </div> |
|
114 | 114 | {% endfor %} |
|
115 | 115 | {% else %} |
|
116 | 116 | <div class="post"> |
|
117 | 117 | {% trans 'No threads exist. Create the first one!' %}</div> |
|
118 | 118 | {% endif %} |
|
119 | 119 | |
|
120 | 120 | <form enctype="multipart/form-data" method="post">{% csrf_token %} |
|
121 | 121 | <div class="post-form-w"> |
|
122 | 122 | |
|
123 | 123 | <div class="form-title">{% trans "Create new thread" %}</div> |
|
124 | 124 | <div class="post-form"> |
|
125 | 125 | <div class="form-row"> |
|
126 | 126 | <div class="form-label">{% trans 'Title' %}</div> |
|
127 | 127 | <div class="form-input">{{ form.title }}</div> |
|
128 | 128 | <div class="form-errors">{{ form.title.errors }}</div> |
|
129 | 129 | </div> |
|
130 | 130 | <div class="form-row"> |
|
131 | 131 | <div class="form-label">{% trans 'Text' %}</div> |
|
132 | 132 | <div class="form-input">{{ form.text }}</div> |
|
133 | 133 | <div class="form-errors">{{ form.text.errors }}</div> |
|
134 | 134 | </div> |
|
135 | 135 | <div class="form-row"> |
|
136 | 136 | <div class="form-label">{% trans 'Image' %}</div> |
|
137 | 137 | <div class="form-input">{{ form.image }}</div> |
|
138 | 138 | <div class="form-errors">{{ form.image.errors }}</div> |
|
139 | 139 | </div> |
|
140 | 140 | <div class="form-row"> |
|
141 | 141 | <div class="form-label">{% trans 'Tags' %}</div> |
|
142 | 142 | <div class="form-input">{{ form.tags }}</div> |
|
143 | 143 | <div class="form-errors">{{ form.tags.errors }}</div> |
|
144 | 144 | </div> |
|
145 | 145 | <div class="form-row"> |
|
146 | 146 | {{ form.captcha }} |
|
147 | 147 | <div class="form-errors">{{ form.captcha.errors }}</div> |
|
148 | 148 | </div> |
|
149 | 149 | <div class="form-row"> |
|
150 | 150 | <div class="form-errors">{{ form.other.errors }}</div> |
|
151 | 151 | </div> |
|
152 | 152 | </div> |
|
153 | 153 | <div class="form-submit"> |
|
154 | 154 | <input type="submit" value="{% trans "Post" %}"/></div> |
|
155 | 155 | <div> |
|
156 | 156 | {% trans 'Tags must be delimited by spaces. Text or image is required.' %} |
|
157 | 157 | </div> |
|
158 | 158 | <div><a href="{% url "staticpage" name="help" %}"> |
|
159 | 159 | {% trans 'Text syntax' %}</a></div> |
|
160 | 160 | </div> |
|
161 | 161 | </form> |
|
162 | 162 | |
|
163 | 163 | {% endblock %} |
|
164 | 164 | |
|
165 | 165 | {% block metapanel %} |
|
166 | 166 | |
|
167 | 167 | <span class="metapanel"> |
|
168 | 168 | <b><a href="{% url "authors" %}">Neboard</a> 1.1</b> |
|
169 | 169 | {% trans "Pages:" %} |
|
170 | 170 | {% for page in pages %} |
|
171 | 171 | [<a href=" |
|
172 | 172 | {% if tag %} |
|
173 | 173 | {% url "tag" tag_name=tag page=page %} |
|
174 | 174 | {% else %} |
|
175 | 175 | {% url "index" page=page %} |
|
176 | 176 | {% endif %} |
|
177 | 177 | ">{{ page }}</a>] |
|
178 | 178 | {% endfor %} |
|
179 | 179 | [<a href="rss/">RSS</a>] |
|
180 | 180 | </span> |
|
181 | 181 | |
|
182 | 182 | {% endblock %} |
General Comments 0
You need to be logged in to leave comments.
Login now