##// END OF EJS Templates
Added link to the pub-time sorted thread list
neko259 -
r1376:a9439dbc default
parent child Browse files
Show More
1 NO CONTENT: modified file, binary diff hidden
NO CONTENT: modified file, binary diff hidden
@@ -1,490 +1,493 b''
1 # SOME DESCRIPTIVE TITLE.
1 # SOME DESCRIPTIVE TITLE.
2 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
2 # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3 # This file is distributed under the same license as the PACKAGE package.
3 # This file is distributed under the same license as the PACKAGE package.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
4 # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5 #
5 #
6 msgid ""
6 msgid ""
7 msgstr ""
7 msgstr ""
8 "Project-Id-Version: PACKAGE VERSION\n"
8 "Project-Id-Version: PACKAGE VERSION\n"
9 "Report-Msgid-Bugs-To: \n"
9 "Report-Msgid-Bugs-To: \n"
10 "POT-Creation-Date: 2015-10-09 23:21+0300\n"
10 "POT-Creation-Date: 2015-10-09 23:21+0300\n"
11 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
11 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
12 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
12 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13 "Language-Team: LANGUAGE <LL@li.org>\n"
13 "Language-Team: LANGUAGE <LL@li.org>\n"
14 "Language: ru\n"
14 "Language: ru\n"
15 "MIME-Version: 1.0\n"
15 "MIME-Version: 1.0\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
16 "Content-Type: text/plain; charset=UTF-8\n"
17 "Content-Transfer-Encoding: 8bit\n"
17 "Content-Transfer-Encoding: 8bit\n"
18 "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
18 "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
19 "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
19 "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
20
20
21 #: admin.py:22
21 #: admin.py:22
22 msgid "{} posters were banned"
22 msgid "{} posters were banned"
23 msgstr ""
23 msgstr ""
24
24
25 #: authors.py:9
25 #: authors.py:9
26 msgid "author"
26 msgid "author"
27 msgstr "автор"
27 msgstr "автор"
28
28
29 #: authors.py:10
29 #: authors.py:10
30 msgid "developer"
30 msgid "developer"
31 msgstr "разработчик"
31 msgstr "разработчик"
32
32
33 #: authors.py:11
33 #: authors.py:11
34 msgid "javascript developer"
34 msgid "javascript developer"
35 msgstr "разработчик javascript"
35 msgstr "разработчик javascript"
36
36
37 #: authors.py:12
37 #: authors.py:12
38 msgid "designer"
38 msgid "designer"
39 msgstr "дизайнер"
39 msgstr "дизайнер"
40
40
41 #: forms.py:30
41 #: forms.py:30
42 msgid "Type message here. Use formatting panel for more advanced usage."
42 msgid "Type message here. Use formatting panel for more advanced usage."
43 msgstr ""
43 msgstr ""
44 "Вводите сообщение сюда. Используйте панель для более сложного форматирования."
44 "Вводите сообщение сюда. Используйте панель для более сложного форматирования."
45
45
46 #: forms.py:31
46 #: forms.py:31
47 msgid "music images i_dont_like_tags"
47 msgid "music images i_dont_like_tags"
48 msgstr "музыка картинки теги_не_нужны"
48 msgstr "музыка картинки теги_не_нужны"
49
49
50 #: forms.py:33
50 #: forms.py:33
51 msgid "Title"
51 msgid "Title"
52 msgstr "Заголовок"
52 msgstr "Заголовок"
53
53
54 #: forms.py:34
54 #: forms.py:34
55 msgid "Text"
55 msgid "Text"
56 msgstr "Текст"
56 msgstr "Текст"
57
57
58 #: forms.py:35
58 #: forms.py:35
59 msgid "Tag"
59 msgid "Tag"
60 msgstr "Метка"
60 msgstr "Метка"
61
61
62 #: forms.py:36 templates/boards/base.html:40 templates/search/search.html:7
62 #: forms.py:36 templates/boards/base.html:40 templates/search/search.html:7
63 msgid "Search"
63 msgid "Search"
64 msgstr "Поиск"
64 msgstr "Поиск"
65
65
66 #: forms.py:139
66 #: forms.py:139
67 msgid "File"
67 msgid "File"
68 msgstr "Файл"
68 msgstr "Файл"
69
69
70 #: forms.py:142
70 #: forms.py:142
71 msgid "File URL"
71 msgid "File URL"
72 msgstr "URL файла"
72 msgstr "URL файла"
73
73
74 #: forms.py:148
74 #: forms.py:148
75 msgid "e-mail"
75 msgid "e-mail"
76 msgstr ""
76 msgstr ""
77
77
78 #: forms.py:151
78 #: forms.py:151
79 msgid "Additional threads"
79 msgid "Additional threads"
80 msgstr "Дополнительные темы"
80 msgstr "Дополнительные темы"
81
81
82 #: forms.py:162
82 #: forms.py:162
83 #, python-format
83 #, python-format
84 msgid "Title must have less than %s characters"
84 msgid "Title must have less than %s characters"
85 msgstr "Заголовок должен иметь меньше %s символов"
85 msgstr "Заголовок должен иметь меньше %s символов"
86
86
87 #: forms.py:172
87 #: forms.py:172
88 #, python-format
88 #, python-format
89 msgid "Text must have less than %s characters"
89 msgid "Text must have less than %s characters"
90 msgstr "Текст должен быть короче %s символов"
90 msgstr "Текст должен быть короче %s символов"
91
91
92 #: forms.py:192
92 #: forms.py:192
93 msgid "Invalid URL"
93 msgid "Invalid URL"
94 msgstr "Неверный URL"
94 msgstr "Неверный URL"
95
95
96 #: forms.py:213
96 #: forms.py:213
97 msgid "Invalid additional thread list"
97 msgid "Invalid additional thread list"
98 msgstr "Неверный список дополнительных тем"
98 msgstr "Неверный список дополнительных тем"
99
99
100 #: forms.py:258
100 #: forms.py:258
101 msgid "Either text or file must be entered."
101 msgid "Either text or file must be entered."
102 msgstr "Текст или файл должны быть введены."
102 msgstr "Текст или файл должны быть введены."
103
103
104 #: forms.py:317 templates/boards/all_threads.html:153
104 #: forms.py:317 templates/boards/all_threads.html:153
105 #: templates/boards/rss/post.html:10 templates/boards/tags.html:6
105 #: templates/boards/rss/post.html:10 templates/boards/tags.html:6
106 msgid "Tags"
106 msgid "Tags"
107 msgstr "Метки"
107 msgstr "Метки"
108
108
109 #: forms.py:324
109 #: forms.py:324
110 msgid "Inappropriate characters in tags."
110 msgid "Inappropriate characters in tags."
111 msgstr "Недопустимые символы в метках."
111 msgstr "Недопустимые символы в метках."
112
112
113 #: forms.py:344
113 #: forms.py:344
114 msgid "Need at least one section."
114 msgid "Need at least one section."
115 msgstr "Нужен хотя бы один раздел."
115 msgstr "Нужен хотя бы один раздел."
116
116
117 #: forms.py:356
117 #: forms.py:356
118 msgid "Theme"
118 msgid "Theme"
119 msgstr "Тема"
119 msgstr "Тема"
120
120
121 #: forms.py:357
121 #: forms.py:357
122 msgid "Image view mode"
122 msgid "Image view mode"
123 msgstr "Режим просмотра изображений"
123 msgstr "Режим просмотра изображений"
124
124
125 #: forms.py:358
125 #: forms.py:358
126 msgid "User name"
126 msgid "User name"
127 msgstr "Имя пользователя"
127 msgstr "Имя пользователя"
128
128
129 #: forms.py:359
129 #: forms.py:359
130 msgid "Time zone"
130 msgid "Time zone"
131 msgstr "Часовой пояс"
131 msgstr "Часовой пояс"
132
132
133 #: forms.py:365
133 #: forms.py:365
134 msgid "Inappropriate characters."
134 msgid "Inappropriate characters."
135 msgstr "Недопустимые символы."
135 msgstr "Недопустимые символы."
136
136
137 #: templates/boards/404.html:6
137 #: templates/boards/404.html:6
138 msgid "Not found"
138 msgid "Not found"
139 msgstr "Не найдено"
139 msgstr "Не найдено"
140
140
141 #: templates/boards/404.html:12
141 #: templates/boards/404.html:12
142 msgid "This page does not exist"
142 msgid "This page does not exist"
143 msgstr "Этой страницы не существует"
143 msgstr "Этой страницы не существует"
144
144
145 #: templates/boards/all_threads.html:35
145 #: templates/boards/all_threads.html:35
146 msgid "Related message"
146 msgid "Related message"
147 msgstr "Связанное сообщение"
147 msgstr "Связанное сообщение"
148
148
149 #: templates/boards/all_threads.html:69
149 #: templates/boards/all_threads.html:69
150 msgid "Edit tag"
150 msgid "Edit tag"
151 msgstr "Изменить метку"
151 msgstr "Изменить метку"
152
152
153 #: templates/boards/all_threads.html:76
153 #: templates/boards/all_threads.html:76
154 #, python-format
154 #, python-format
155 msgid "%(count)s active thread"
155 msgid "%(count)s active thread"
156 msgid_plural "%(count)s active threads"
156 msgid_plural "%(count)s active threads"
157 msgstr[0] "%(count)s активная тема"
157 msgstr[0] "%(count)s активная тема"
158 msgstr[1] "%(count)s активные темы"
158 msgstr[1] "%(count)s активные темы"
159 msgstr[2] "%(count)s активных тем"
159 msgstr[2] "%(count)s активных тем"
160
160
161 #: templates/boards/all_threads.html:77
161 #: templates/boards/all_threads.html:77
162 #, python-format
162 #, python-format
163 msgid "%(count)s archived thread"
163 msgid "%(count)s archived thread"
164 msgid_plural "%(count)s archived thread"
164 msgid_plural "%(count)s archived thread"
165 msgstr[0] "%(count)s архивная тема"
165 msgstr[0] "%(count)s архивная тема"
166 msgstr[1] "%(count)s архивные темы"
166 msgstr[1] "%(count)s архивные темы"
167 msgstr[2] "%(count)s архивных тем"
167 msgstr[2] "%(count)s архивных тем"
168
168
169 #: templates/boards/all_threads.html:78 templates/boards/post.html:102
169 #: templates/boards/all_threads.html:78 templates/boards/post.html:102
170 #, python-format
170 #, python-format
171 #| msgid "%(count)s message"
171 #| msgid "%(count)s message"
172 #| msgid_plural "%(count)s messages"
172 #| msgid_plural "%(count)s messages"
173 msgid "%(count)s message"
173 msgid "%(count)s message"
174 msgid_plural "%(count)s messages"
174 msgid_plural "%(count)s messages"
175 msgstr[0] "%(count)s сообщение"
175 msgstr[0] "%(count)s сообщение"
176 msgstr[1] "%(count)s сообщения"
176 msgstr[1] "%(count)s сообщения"
177 msgstr[2] "%(count)s сообщений"
177 msgstr[2] "%(count)s сообщений"
178
178
179 #: templates/boards/all_threads.html:95 templates/boards/feed.html:30
179 #: templates/boards/all_threads.html:95 templates/boards/feed.html:30
180 #: templates/boards/notifications.html:17 templates/search/search.html:26
180 #: templates/boards/notifications.html:17 templates/search/search.html:26
181 msgid "Previous page"
181 msgid "Previous page"
182 msgstr "Предыдущая страница"
182 msgstr "Предыдущая страница"
183
183
184 #: templates/boards/all_threads.html:109
184 #: templates/boards/all_threads.html:109
185 #, python-format
185 #, python-format
186 msgid "Skipped %(count)s reply. Open thread to see all replies."
186 msgid "Skipped %(count)s reply. Open thread to see all replies."
187 msgid_plural "Skipped %(count)s replies. Open thread to see all replies."
187 msgid_plural "Skipped %(count)s replies. Open thread to see all replies."
188 msgstr[0] "Пропущен %(count)s ответ. Откройте тред, чтобы увидеть все ответы."
188 msgstr[0] "Пропущен %(count)s ответ. Откройте тред, чтобы увидеть все ответы."
189 msgstr[1] ""
189 msgstr[1] ""
190 "Пропущено %(count)s ответа. Откройте тред, чтобы увидеть все ответы."
190 "Пропущено %(count)s ответа. Откройте тред, чтобы увидеть все ответы."
191 msgstr[2] ""
191 msgstr[2] ""
192 "Пропущено %(count)s ответов. Откройте тред, чтобы увидеть все ответы."
192 "Пропущено %(count)s ответов. Откройте тред, чтобы увидеть все ответы."
193
193
194 #: templates/boards/all_threads.html:127 templates/boards/feed.html:40
194 #: templates/boards/all_threads.html:127 templates/boards/feed.html:40
195 #: templates/boards/notifications.html:27 templates/search/search.html:37
195 #: templates/boards/notifications.html:27 templates/search/search.html:37
196 msgid "Next page"
196 msgid "Next page"
197 msgstr "Следующая страница"
197 msgstr "Следующая страница"
198
198
199 #: templates/boards/all_threads.html:132
199 #: templates/boards/all_threads.html:132
200 msgid "No threads exist. Create the first one!"
200 msgid "No threads exist. Create the first one!"
201 msgstr "Нет тем. Создайте первую!"
201 msgstr "Нет тем. Создайте первую!"
202
202
203 #: templates/boards/all_threads.html:138
203 #: templates/boards/all_threads.html:138
204 msgid "Create new thread"
204 msgid "Create new thread"
205 msgstr "Создать новую тему"
205 msgstr "Создать новую тему"
206
206
207 #: templates/boards/all_threads.html:143 templates/boards/preview.html:16
207 #: templates/boards/all_threads.html:143 templates/boards/preview.html:16
208 #: templates/boards/thread_normal.html:51
208 #: templates/boards/thread_normal.html:51
209 msgid "Post"
209 msgid "Post"
210 msgstr "Отправить"
210 msgstr "Отправить"
211
211
212 #: templates/boards/all_threads.html:144 templates/boards/preview.html:6
212 #: templates/boards/all_threads.html:144 templates/boards/preview.html:6
213 #: templates/boards/staticpages/help.html:21
213 #: templates/boards/staticpages/help.html:21
214 #: templates/boards/thread_normal.html:52
214 #: templates/boards/thread_normal.html:52
215 msgid "Preview"
215 msgid "Preview"
216 msgstr "Предпросмотр"
216 msgstr "Предпросмотр"
217
217
218 #: templates/boards/all_threads.html:149
218 #: templates/boards/all_threads.html:149
219 msgid "Tags must be delimited by spaces. Text or image is required."
219 msgid "Tags must be delimited by spaces. Text or image is required."
220 msgstr ""
220 msgstr ""
221 "Метки должны быть разделены пробелами. Текст или изображение обязательны."
221 "Метки должны быть разделены пробелами. Текст или изображение обязательны."
222
222
223 #: templates/boards/all_threads.html:152 templates/boards/thread_normal.html:58
223 #: templates/boards/all_threads.html:152 templates/boards/thread_normal.html:58
224 msgid "Text syntax"
224 msgid "Text syntax"
225 msgstr "Синтаксис текста"
225 msgstr "Синтаксис текста"
226
226
227 #: templates/boards/all_threads.html:166 templates/boards/feed.html:53
227 #: templates/boards/all_threads.html:166 templates/boards/feed.html:53
228 msgid "Pages:"
228 msgid "Pages:"
229 msgstr "Страницы: "
229 msgstr "Страницы: "
230
230
231 #: templates/boards/authors.html:6 templates/boards/authors.html.py:12
231 #: templates/boards/authors.html:6 templates/boards/authors.html.py:12
232 msgid "Authors"
232 msgid "Authors"
233 msgstr "Авторы"
233 msgstr "Авторы"
234
234
235 #: templates/boards/authors.html:26
235 #: templates/boards/authors.html:26
236 msgid "Distributed under the"
236 msgid "Distributed under the"
237 msgstr "Распространяется под"
237 msgstr "Распространяется под"
238
238
239 #: templates/boards/authors.html:28
239 #: templates/boards/authors.html:28
240 msgid "license"
240 msgid "license"
241 msgstr "лицензией"
241 msgstr "лицензией"
242
242
243 #: templates/boards/authors.html:30
243 #: templates/boards/authors.html:30
244 msgid "Repository"
244 msgid "Repository"
245 msgstr "Репозиторий"
245 msgstr "Репозиторий"
246
246
247 #: templates/boards/base.html:14 templates/boards/base.html.py:41
247 #: templates/boards/base.html:14 templates/boards/base.html.py:41
248 msgid "Feed"
248 msgid "Feed"
249 msgstr "Лента"
249 msgstr "Лента"
250
250
251 #: templates/boards/base.html:31
251 #: templates/boards/base.html:31
252 msgid "All threads"
252 msgid "All threads"
253 msgstr "Все темы"
253 msgstr "Все темы"
254
254
255 #: templates/boards/base.html:37
255 #: templates/boards/base.html:37
256 msgid "Add tags"
256 msgid "Add tags"
257 msgstr "Добавить метки"
257 msgstr "Добавить метки"
258
258
259 #: templates/boards/base.html:39
259 #: templates/boards/base.html:39
260 msgid "Tag management"
260 msgid "Tag management"
261 msgstr "Управление метками"
261 msgstr "Управление метками"
262
262
263 #: templates/boards/base.html:39
263 #: templates/boards/base.html:39
264 msgid "tags"
264 msgid "tags"
265 msgstr "метки"
265 msgstr "метки"
266
266
267 #: templates/boards/base.html:40
267 #: templates/boards/base.html:40
268 msgid "search"
268 msgid "search"
269 msgstr "поиск"
269 msgstr "поиск"
270
270
271 #: templates/boards/base.html:41 templates/boards/feed.html:11
271 #: templates/boards/base.html:41 templates/boards/feed.html:11
272 msgid "feed"
272 msgid "feed"
273 msgstr "лента"
273 msgstr "лента"
274
274
275 #: templates/boards/base.html:42 templates/boards/random.html:6
275 #: templates/boards/base.html:42 templates/boards/random.html:6
276 msgid "Random images"
276 msgid "Random images"
277 msgstr "Случайные изображения"
277 msgstr "Случайные изображения"
278
278
279 #: templates/boards/base.html:42
279 #: templates/boards/base.html:42
280 msgid "random"
280 msgid "random"
281 msgstr "случайные"
281 msgstr "случайные"
282
282
283 #: templates/boards/base.html:44
283 #: templates/boards/base.html:44
284 msgid "favorites"
284 msgid "favorites"
285 msgstr "избранное"
285 msgstr "избранное"
286
286
287 #: templates/boards/base.html:48 templates/boards/base.html.py:49
287 #: templates/boards/base.html:48 templates/boards/base.html.py:49
288 #: templates/boards/notifications.html:8
288 #: templates/boards/notifications.html:8
289 msgid "Notifications"
289 msgid "Notifications"
290 msgstr "Уведомления"
290 msgstr "Уведомления"
291
291
292 #: templates/boards/base.html:56 templates/boards/settings.html:8
292 #: templates/boards/base.html:56 templates/boards/settings.html:8
293 msgid "Settings"
293 msgid "Settings"
294 msgstr "Настройки"
294 msgstr "Настройки"
295
295
296 #: templates/boards/base.html:59
296 #: templates/boards/base.html:59
297 msgid "Loading..."
297 msgid "Loading..."
298 msgstr "Загрузка..."
298 msgstr "Загрузка..."
299
299
300 #: templates/boards/base.html:71
300 #: templates/boards/base.html:71
301 msgid "Admin"
301 msgid "Admin"
302 msgstr "Администрирование"
302 msgstr "Администрирование"
303
303
304 #: templates/boards/base.html:73
304 #: templates/boards/base.html:73
305 #, python-format
305 #, python-format
306 msgid "Speed: %(ppd)s posts per day"
306 msgid "Speed: %(ppd)s posts per day"
307 msgstr "Скорость: %(ppd)s сообщений в день"
307 msgstr "Скорость: %(ppd)s сообщений в день"
308
308
309 #: templates/boards/base.html:75
309 #: templates/boards/base.html:75
310 msgid "Up"
310 msgid "Up"
311 msgstr "Вверх"
311 msgstr "Вверх"
312
312
313 #: templates/boards/feed.html:45
313 #: templates/boards/feed.html:45
314 msgid "No posts exist. Create the first one!"
314 msgid "No posts exist. Create the first one!"
315 msgstr "Нет сообщений. Создайте первое!"
315 msgstr "Нет сообщений. Создайте первое!"
316
316
317 #: templates/boards/post.html:33
317 #: templates/boards/post.html:33
318 msgid "Open"
318 msgid "Open"
319 msgstr "Открыть"
319 msgstr "Открыть"
320
320
321 #: templates/boards/post.html:35 templates/boards/post.html.py:46
321 #: templates/boards/post.html:35 templates/boards/post.html.py:46
322 msgid "Reply"
322 msgid "Reply"
323 msgstr "Ответить"
323 msgstr "Ответить"
324
324
325 #: templates/boards/post.html:41
325 #: templates/boards/post.html:41
326 msgid " in "
326 msgid " in "
327 msgstr " в "
327 msgstr " в "
328
328
329 #: templates/boards/post.html:51
329 #: templates/boards/post.html:51
330 msgid "Edit"
330 msgid "Edit"
331 msgstr "Изменить"
331 msgstr "Изменить"
332
332
333 #: templates/boards/post.html:53
333 #: templates/boards/post.html:53
334 msgid "Edit thread"
334 msgid "Edit thread"
335 msgstr "Изменить тему"
335 msgstr "Изменить тему"
336
336
337 #: templates/boards/post.html:91
337 #: templates/boards/post.html:91
338 msgid "Replies"
338 msgid "Replies"
339 msgstr "Ответы"
339 msgstr "Ответы"
340
340
341 #: templates/boards/post.html:103
341 #: templates/boards/post.html:103
342 #, python-format
342 #, python-format
343 msgid "%(count)s image"
343 msgid "%(count)s image"
344 msgid_plural "%(count)s images"
344 msgid_plural "%(count)s images"
345 msgstr[0] "%(count)s изображение"
345 msgstr[0] "%(count)s изображение"
346 msgstr[1] "%(count)s изображения"
346 msgstr[1] "%(count)s изображения"
347 msgstr[2] "%(count)s изображений"
347 msgstr[2] "%(count)s изображений"
348
348
349 #: templates/boards/rss/post.html:5
349 #: templates/boards/rss/post.html:5
350 msgid "Post image"
350 msgid "Post image"
351 msgstr "Изображение сообщения"
351 msgstr "Изображение сообщения"
352
352
353 #: templates/boards/settings.html:15
353 #: templates/boards/settings.html:15
354 msgid "You are moderator."
354 msgid "You are moderator."
355 msgstr "Вы модератор."
355 msgstr "Вы модератор."
356
356
357 #: templates/boards/settings.html:19
357 #: templates/boards/settings.html:19
358 msgid "Hidden tags:"
358 msgid "Hidden tags:"
359 msgstr "Скрытые метки:"
359 msgstr "Скрытые метки:"
360
360
361 #: templates/boards/settings.html:25
361 #: templates/boards/settings.html:25
362 msgid "No hidden tags."
362 msgid "No hidden tags."
363 msgstr "Нет скрытых меток."
363 msgstr "Нет скрытых меток."
364
364
365 #: templates/boards/settings.html:34
365 #: templates/boards/settings.html:34
366 msgid "Save"
366 msgid "Save"
367 msgstr "Сохранить"
367 msgstr "Сохранить"
368
368
369 #: templates/boards/staticpages/banned.html:6
369 #: templates/boards/staticpages/banned.html:6
370 msgid "Banned"
370 msgid "Banned"
371 msgstr "Заблокирован"
371 msgstr "Заблокирован"
372
372
373 #: templates/boards/staticpages/banned.html:11
373 #: templates/boards/staticpages/banned.html:11
374 msgid "Your IP address has been banned. Contact the administrator"
374 msgid "Your IP address has been banned. Contact the administrator"
375 msgstr "Ваш IP адрес был заблокирован. Свяжитесь с администратором"
375 msgstr "Ваш IP адрес был заблокирован. Свяжитесь с администратором"
376
376
377 #: templates/boards/staticpages/help.html:6
377 #: templates/boards/staticpages/help.html:6
378 #: templates/boards/staticpages/help.html:10
378 #: templates/boards/staticpages/help.html:10
379 msgid "Syntax"
379 msgid "Syntax"
380 msgstr "Синтаксис"
380 msgstr "Синтаксис"
381
381
382 #: templates/boards/staticpages/help.html:11
382 #: templates/boards/staticpages/help.html:11
383 msgid "Italic text"
383 msgid "Italic text"
384 msgstr "Курсивный текст"
384 msgstr "Курсивный текст"
385
385
386 #: templates/boards/staticpages/help.html:12
386 #: templates/boards/staticpages/help.html:12
387 msgid "Bold text"
387 msgid "Bold text"
388 msgstr "Полужирный текст"
388 msgstr "Полужирный текст"
389
389
390 #: templates/boards/staticpages/help.html:13
390 #: templates/boards/staticpages/help.html:13
391 msgid "Spoiler"
391 msgid "Spoiler"
392 msgstr "Спойлер"
392 msgstr "Спойлер"
393
393
394 #: templates/boards/staticpages/help.html:14
394 #: templates/boards/staticpages/help.html:14
395 msgid "Link to a post"
395 msgid "Link to a post"
396 msgstr "Ссылка на сообщение"
396 msgstr "Ссылка на сообщение"
397
397
398 #: templates/boards/staticpages/help.html:15
398 #: templates/boards/staticpages/help.html:15
399 msgid "Strikethrough text"
399 msgid "Strikethrough text"
400 msgstr "Зачеркнутый текст"
400 msgstr "Зачеркнутый текст"
401
401
402 #: templates/boards/staticpages/help.html:16
402 #: templates/boards/staticpages/help.html:16
403 msgid "Comment"
403 msgid "Comment"
404 msgstr "Комментарий"
404 msgstr "Комментарий"
405
405
406 #: templates/boards/staticpages/help.html:17
406 #: templates/boards/staticpages/help.html:17
407 #: templates/boards/staticpages/help.html:18
407 #: templates/boards/staticpages/help.html:18
408 msgid "Quote"
408 msgid "Quote"
409 msgstr "Цитата"
409 msgstr "Цитата"
410
410
411 #: templates/boards/staticpages/help.html:21
411 #: templates/boards/staticpages/help.html:21
412 msgid "You can try pasting the text and previewing the result here:"
412 msgid "You can try pasting the text and previewing the result here:"
413 msgstr "Вы можете попробовать вставить текст и проверить результат здесь:"
413 msgstr "Вы можете попробовать вставить текст и проверить результат здесь:"
414
414
415 #: templates/boards/tags.html:17
415 #: templates/boards/tags.html:17
416 msgid "Sections:"
416 msgid "Sections:"
417 msgstr "Разделы:"
417 msgstr "Разделы:"
418
418
419 #: templates/boards/tags.html:30
419 #: templates/boards/tags.html:30
420 msgid "Other tags:"
420 msgid "Other tags:"
421 msgstr "Другие метки:"
421 msgstr "Другие метки:"
422
422
423 #: templates/boards/tags.html:43
423 #: templates/boards/tags.html:43
424 msgid "All tags..."
424 msgid "All tags..."
425 msgstr "Все метки..."
425 msgstr "Все метки..."
426
426
427 #: templates/boards/thread.html:14
427 #: templates/boards/thread.html:14
428 msgid "Normal"
428 msgid "Normal"
429 msgstr "Нормальный"
429 msgstr "Нормальный"
430
430
431 #: templates/boards/thread.html:15
431 #: templates/boards/thread.html:15
432 msgid "Gallery"
432 msgid "Gallery"
433 msgstr "Галерея"
433 msgstr "Галерея"
434
434
435 #: templates/boards/thread.html:16
435 #: templates/boards/thread.html:16
436 msgid "Tree"
436 msgid "Tree"
437 msgstr "Дерево"
437 msgstr "Дерево"
438
438
439 #: templates/boards/thread.html:35
439 #: templates/boards/thread.html:35
440 msgid "message"
440 msgid "message"
441 msgid_plural "messages"
441 msgid_plural "messages"
442 msgstr[0] "сообщение"
442 msgstr[0] "сообщение"
443 msgstr[1] "сообщения"
443 msgstr[1] "сообщения"
444 msgstr[2] "сообщений"
444 msgstr[2] "сообщений"
445
445
446 #: templates/boards/thread.html:38
446 #: templates/boards/thread.html:38
447 msgid "image"
447 msgid "image"
448 msgid_plural "images"
448 msgid_plural "images"
449 msgstr[0] "изображение"
449 msgstr[0] "изображение"
450 msgstr[1] "изображения"
450 msgstr[1] "изображения"
451 msgstr[2] "изображений"
451 msgstr[2] "изображений"
452
452
453 #: templates/boards/thread.html:40
453 #: templates/boards/thread.html:40
454 msgid "Last update: "
454 msgid "Last update: "
455 msgstr "Последнее обновление: "
455 msgstr "Последнее обновление: "
456
456
457 #: templates/boards/thread_gallery.html:36
457 #: templates/boards/thread_gallery.html:36
458 msgid "No images."
458 msgid "No images."
459 msgstr "Нет изображений."
459 msgstr "Нет изображений."
460
460
461 #: templates/boards/thread_normal.html:30
461 #: templates/boards/thread_normal.html:30
462 msgid "posts to bumplimit"
462 msgid "posts to bumplimit"
463 msgstr "сообщений до бамплимита"
463 msgstr "сообщений до бамплимита"
464
464
465 #: templates/boards/thread_normal.html:44
465 #: templates/boards/thread_normal.html:44
466 msgid "Reply to thread"
466 msgid "Reply to thread"
467 msgstr "Ответить в тему"
467 msgstr "Ответить в тему"
468
468
469 #: templates/boards/thread_normal.html:44
469 #: templates/boards/thread_normal.html:44
470 msgid "to message "
470 msgid "to message "
471 msgstr "на сообщение"
471 msgstr "на сообщение"
472
472
473 #: templates/boards/thread_normal.html:59
473 #: templates/boards/thread_normal.html:59
474 msgid "Close form"
474 msgid "Close form"
475 msgstr "Закрыть форму"
475 msgstr "Закрыть форму"
476
476
477 #: templates/search/search.html:17
477 #: templates/search/search.html:17
478 msgid "Ok"
478 msgid "Ok"
479 msgstr "Ок"
479 msgstr "Ок"
480
480
481 #: utils.py:120
481 #: utils.py:120
482 #, python-format
482 #, python-format
483 msgid "File must be less than %s bytes"
483 msgid "File must be less than %s bytes"
484 msgstr "Файл должен быть менее %s байт"
484 msgstr "Файл должен быть менее %s байт"
485
485
486 msgid "Please wait %(delay)d second before sending message"
486 msgid "Please wait %(delay)d second before sending message"
487 msgid_plural "Please wait %(delay)d seconds before sending message"
487 msgid_plural "Please wait %(delay)d seconds before sending message"
488 msgstr[0] "Пожалуйста подождите %(delay)d секунду перед отправкой сообщения"
488 msgstr[0] "Пожалуйста подождите %(delay)d секунду перед отправкой сообщения"
489 msgstr[1] "Пожалуйста подождите %(delay)d секунды перед отправкой сообщения"
489 msgstr[1] "Пожалуйста подождите %(delay)d секунды перед отправкой сообщения"
490 msgstr[2] "Пожалуйста подождите %(delay)d секунд перед отправкой сообщения"
490 msgstr[2] "Пожалуйста подождите %(delay)d секунд перед отправкой сообщения"
491
492 msgid "New threads"
493 msgstr "Новые темы"
@@ -1,79 +1,80 b''
1 {% load staticfiles %}
1 {% load staticfiles %}
2 {% load i18n %}
2 {% load i18n %}
3 {% load l10n %}
3 {% load l10n %}
4 {% load static from staticfiles %}
4 {% load static from staticfiles %}
5
5
6 <!DOCTYPE html>
6 <!DOCTYPE html>
7 <html>
7 <html>
8 <head>
8 <head>
9 <link rel="stylesheet" type="text/css" href="{% static 'css/base.css' %}" media="all"/>
9 <link rel="stylesheet" type="text/css" href="{% static 'css/base.css' %}" media="all"/>
10 <link rel="stylesheet" type="text/css" href="{% static 'css/3party/highlight.css' %}" media="all"/>
10 <link rel="stylesheet" type="text/css" href="{% static 'css/3party/highlight.css' %}" media="all"/>
11 <link rel="stylesheet" type="text/css" href="{% static 'css/3party/jquery-ui.min.css' %}" media="all"/>
11 <link rel="stylesheet" type="text/css" href="{% static 'css/3party/jquery-ui.min.css' %}" media="all"/>
12 <link rel="stylesheet" type="text/css" href="{% static theme_css %}" media="all"/>
12 <link rel="stylesheet" type="text/css" href="{% static theme_css %}" media="all"/>
13
13
14 <link rel="alternate" type="application/rss+xml" href="rss/" title="{% trans 'Feed' %}"/>
14 <link rel="alternate" type="application/rss+xml" href="rss/" title="{% trans 'Feed' %}"/>
15
15
16 <link rel="icon" type="image/png"
16 <link rel="icon" type="image/png"
17 href="{% static 'favicon.png' %}">
17 href="{% static 'favicon.png' %}">
18
18
19 <meta name="viewport" content="width=device-width, initial-scale=1"/>
19 <meta name="viewport" content="width=device-width, initial-scale=1"/>
20 <meta charset="utf-8"/>
20 <meta charset="utf-8"/>
21
21
22 {% block head %}{% endblock %}
22 {% block head %}{% endblock %}
23 </head>
23 </head>
24 <body data-image-viewer="{{ image_viewer }}">
24 <body data-image-viewer="{{ image_viewer }}">
25 <script src="{% static 'js/jquery-2.0.1.min.js' %}"></script>
25 <script src="{% static 'js/jquery-2.0.1.min.js' %}"></script>
26 <script src="{% static 'js/3party/jquery-ui.min.js' %}"></script>
26 <script src="{% static 'js/3party/jquery-ui.min.js' %}"></script>
27 <script src="{% static 'js/jquery.mousewheel.js' %}"></script>
27 <script src="{% static 'js/jquery.mousewheel.js' %}"></script>
28 <script src="{% url 'js_info_dict' %}"></script>
28 <script src="{% url 'js_info_dict' %}"></script>
29
29
30 <div class="navigation_panel header">
30 <div class="navigation_panel header">
31 <a class="link" href="{% url 'index' %}">{% trans "All threads" %}</a>
31 <a class="link" href="{% url 'index' %}">{% trans "All threads" %}</a>
32 {% if tags_str %}
32 {% if tags_str %}
33 {% autoescape off %}
33 {% autoescape off %}
34 {{ tags_str }},
34 {{ tags_str }},
35 {% endautoescape %}
35 {% endautoescape %}
36 {% else %}
36 {% else %}
37 {% trans 'Add tags' %} →
37 {% trans 'Add tags' %} →
38 {% endif %}
38 {% endif %}
39 <a href="{% url 'tags' 'required'%}" title="{% trans 'Tag management' %}">{% trans "tags" %}</a>,
39 <a href="{% url 'tags' 'required'%}" title="{% trans 'Tag management' %}">{% trans "tags" %}</a>,
40 <a href="{% url 'search' %}" title="{% trans 'Search' %}">{% trans 'search' %}</a>,
40 <a href="{% url 'search' %}" title="{% trans 'Search' %}">{% trans 'search' %}</a>,
41 <a href="{% url 'feed' %}" title="{% trans 'Feed' %}">{% trans 'feed' %}</a>,
41 <a href="{% url 'feed' %}" title="{% trans 'Feed' %}">{% trans 'feed' %}</a>,
42 <a href="{% url 'random' %}" title="{% trans 'Random images' %}">{% trans 'random' %}</a>{% if has_fav_threads %},
42 <a href="{% url 'random' %}" title="{% trans 'Random images' %}">{% trans 'random' %}</a>{% if has_fav_threads %},
43
43
44 <a href="#" id="fav-panel-btn">{% trans 'favorites' %} <span id="new-fav-post-count"></span></a>
44 <a href="#" id="fav-panel-btn">{% trans 'favorites' %} <span id="new-fav-post-count"></span></a>
45 {% endif %}
45 {% endif %}
46
46
47 {% if username %}
47 {% if username %}
48 <a class="right-link link" href="{% url 'notifications' username %}" title="{% trans 'Notifications' %}">
48 <a class="right-link link" href="{% url 'notifications' username %}" title="{% trans 'Notifications' %}">
49 {% trans 'Notifications' %}
49 {% trans 'Notifications' %}
50 {% ifnotequal new_notifications_count 0 %}
50 {% ifnotequal new_notifications_count 0 %}
51 (<b>{{ new_notifications_count }}</b>)
51 (<b>{{ new_notifications_count }}</b>)
52 {% endifnotequal %}
52 {% endifnotequal %}
53 </a>
53 </a>
54 {% endif %}
54 {% endif %}
55
55
56 <a class="right-link link" href="{% url 'settings' %}">{% trans 'Settings' %}</a>
56 <a class="right-link link" href="{% url 'settings' %}">{% trans 'Settings' %}</a>
57 </div>
57 </div>
58
58
59 <div id="fav-panel"><div class="post">{% trans "Loading..." %}</div></div>
59 <div id="fav-panel"><div class="post">{% trans "Loading..." %}</div></div>
60
60
61 {% block content %}{% endblock %}
61 {% block content %}{% endblock %}
62
62
63 <script src="{% static 'js/3party/highlight.min.js' %}"></script>
63 <script src="{% static 'js/3party/highlight.min.js' %}"></script>
64 <script src="{% static 'js/popup.js' %}"></script>
64 <script src="{% static 'js/popup.js' %}"></script>
65 <script src="{% static 'js/image.js' %}"></script>
65 <script src="{% static 'js/image.js' %}"></script>
66 <script src="{% static 'js/refpopup.js' %}"></script>
66 <script src="{% static 'js/refpopup.js' %}"></script>
67 <script src="{% static 'js/main.js' %}"></script>
67 <script src="{% static 'js/main.js' %}"></script>
68
68
69 <div class="navigation_panel footer">
69 <div class="navigation_panel footer">
70 {% block metapanel %}{% endblock %}
70 {% block metapanel %}{% endblock %}
71 [<a href="{% url 'admin:index' %}">{% trans 'Admin' %}</a>]
71 [<a href="{% url 'admin:index' %}">{% trans 'Admin' %}</a>]
72 [<a href="{% url 'index' %}?order=pub">{% trans 'New threads' %}</a>]
72 {% with ppd=posts_per_day|floatformat:2 %}
73 {% with ppd=posts_per_day|floatformat:2 %}
73 {% blocktrans %}Speed: {{ ppd }} posts per day{% endblocktrans %}
74 {% blocktrans %}Speed: {{ ppd }} posts per day{% endblocktrans %}
74 {% endwith %}
75 {% endwith %}
75 <a class="link" href="#top" id="up">{% trans 'Up' %}</a>
76 <a class="link" href="#top" id="up">{% trans 'Up' %}</a>
76 </div>
77 </div>
77
78
78 </body>
79 </body>
79 </html>
80 </html>
@@ -1,157 +1,166 b''
1 from django.core.urlresolvers import reverse
1 from django.core.urlresolvers import reverse
2 from django.core.files import File
2 from django.core.files import File
3 from django.core.files.temp import NamedTemporaryFile
3 from django.core.files.temp import NamedTemporaryFile
4 from django.core.paginator import EmptyPage
4 from django.core.paginator import EmptyPage
5 from django.db import transaction
5 from django.db import transaction
6 from django.http import Http404
6 from django.http import Http404
7 from django.shortcuts import render, redirect
7 from django.shortcuts import render, redirect
8 import requests
8 import requests
9
9
10 from boards import utils, settings
10 from boards import utils, settings
11 from boards.abstracts.paginator import get_paginator
11 from boards.abstracts.paginator import get_paginator
12 from boards.abstracts.settingsmanager import get_settings_manager
12 from boards.abstracts.settingsmanager import get_settings_manager
13 from boards.forms import ThreadForm, PlainErrorList
13 from boards.forms import ThreadForm, PlainErrorList
14 from boards.models import Post, Thread, Ban, Tag, PostImage, Banner
14 from boards.models import Post, Thread, Ban, Tag, PostImage, Banner
15 from boards.views.banned import BannedView
15 from boards.views.banned import BannedView
16 from boards.views.base import BaseBoardView, CONTEXT_FORM
16 from boards.views.base import BaseBoardView, CONTEXT_FORM
17 from boards.views.posting_mixin import PostMixin
17 from boards.views.posting_mixin import PostMixin
18
18
19
19
20 FORM_TAGS = 'tags'
20 FORM_TAGS = 'tags'
21 FORM_TEXT = 'text'
21 FORM_TEXT = 'text'
22 FORM_TITLE = 'title'
22 FORM_TITLE = 'title'
23 FORM_IMAGE = 'image'
23 FORM_IMAGE = 'image'
24 FORM_THREADS = 'threads'
24 FORM_THREADS = 'threads'
25
25
26 TAG_DELIMITER = ' '
26 TAG_DELIMITER = ' '
27
27
28 PARAMETER_CURRENT_PAGE = 'current_page'
28 PARAMETER_CURRENT_PAGE = 'current_page'
29 PARAMETER_PAGINATOR = 'paginator'
29 PARAMETER_PAGINATOR = 'paginator'
30 PARAMETER_THREADS = 'threads'
30 PARAMETER_THREADS = 'threads'
31 PARAMETER_BANNERS = 'banners'
31 PARAMETER_BANNERS = 'banners'
32
32
33 PARAMETER_PREV_LINK = 'prev_page_link'
33 PARAMETER_PREV_LINK = 'prev_page_link'
34 PARAMETER_NEXT_LINK = 'next_page_link'
34 PARAMETER_NEXT_LINK = 'next_page_link'
35
35
36 TEMPLATE = 'boards/all_threads.html'
36 TEMPLATE = 'boards/all_threads.html'
37 DEFAULT_PAGE = 1
37 DEFAULT_PAGE = 1
38
38
39
39
40 class AllThreadsView(PostMixin, BaseBoardView):
40 class AllThreadsView(PostMixin, BaseBoardView):
41
41
42 def __init__(self):
42 def __init__(self):
43 self.settings_manager = None
43 self.settings_manager = None
44 super(AllThreadsView, self).__init__()
44 super(AllThreadsView, self).__init__()
45
45
46 def get(self, request, form: ThreadForm=None):
46 def get(self, request, form: ThreadForm=None):
47 page = request.GET.get('page', DEFAULT_PAGE)
47 page = request.GET.get('page', DEFAULT_PAGE)
48
48
49 params = self.get_context_data(request=request)
49 params = self.get_context_data(request=request)
50
50
51 if not form:
51 if not form:
52 form = ThreadForm(error_class=PlainErrorList)
52 form = ThreadForm(error_class=PlainErrorList)
53
53
54 self.settings_manager = get_settings_manager(request)
54 self.settings_manager = get_settings_manager(request)
55 paginator = get_paginator(self.get_threads().order_by('-bump_time'),
55
56 threads = self.get_threads()
57
58 order = request.GET.get('order', 'bump')
59 if order == 'bump':
60 threads = threads.order_by('-bump_time')
61 else:
62 threads = threads.filter(multi_replies__opening=True).order_by('-multi_replies__pub_time')
63
64 paginator = get_paginator(threads,
56 settings.get_int('View', 'ThreadsPerPage'))
65 settings.get_int('View', 'ThreadsPerPage'))
57 paginator.current_page = int(page)
66 paginator.current_page = int(page)
58
67
59 try:
68 try:
60 threads = paginator.page(page).object_list
69 threads = paginator.page(page).object_list
61 except EmptyPage:
70 except EmptyPage:
62 raise Http404()
71 raise Http404()
63
72
64 params[PARAMETER_THREADS] = threads
73 params[PARAMETER_THREADS] = threads
65 params[CONTEXT_FORM] = form
74 params[CONTEXT_FORM] = form
66 params[PARAMETER_BANNERS] = Banner.objects.order_by('-id').all()
75 params[PARAMETER_BANNERS] = Banner.objects.order_by('-id').all()
67
76
68 self.get_page_context(paginator, params, page, request.GET.dict())
77 self.get_page_context(paginator, params, page, request.GET.dict())
69
78
70 return render(request, TEMPLATE, params)
79 return render(request, TEMPLATE, params)
71
80
72 def post(self, request):
81 def post(self, request):
73 form = ThreadForm(request.POST, request.FILES,
82 form = ThreadForm(request.POST, request.FILES,
74 error_class=PlainErrorList)
83 error_class=PlainErrorList)
75 form.session = request.session
84 form.session = request.session
76
85
77 if form.is_valid():
86 if form.is_valid():
78 return self.create_thread(request, form)
87 return self.create_thread(request, form)
79 if form.need_to_ban:
88 if form.need_to_ban:
80 # Ban user because he is suspected to be a bot
89 # Ban user because he is suspected to be a bot
81 self._ban_current_user(request)
90 self._ban_current_user(request)
82
91
83 return self.get(request, form)
92 return self.get(request, form)
84
93
85 def get_page_context(self, paginator, params, page, url_params):
94 def get_page_context(self, paginator, params, page, url_params):
86 """
95 """
87 Get pagination context variables
96 Get pagination context variables
88 """
97 """
89
98
90 params[PARAMETER_PAGINATOR] = paginator
99 params[PARAMETER_PAGINATOR] = paginator
91 current_page = paginator.page(int(page))
100 current_page = paginator.page(int(page))
92 params[PARAMETER_CURRENT_PAGE] = current_page
101 params[PARAMETER_CURRENT_PAGE] = current_page
93 if current_page.has_previous():
102 if current_page.has_previous():
94 params[PARAMETER_PREV_LINK] = self.get_previous_page_link(
103 params[PARAMETER_PREV_LINK] = self.get_previous_page_link(
95 current_page, url_params)
104 current_page, url_params)
96 if current_page.has_next():
105 if current_page.has_next():
97 params[PARAMETER_NEXT_LINK] = self.get_next_page_link(current_page,
106 params[PARAMETER_NEXT_LINK] = self.get_next_page_link(current_page,
98 url_params)
107 url_params)
99
108
100 def get_previous_page_link(self, current_page, params):
109 def get_previous_page_link(self, current_page, params):
101 params['page'] = current_page.previous_page_number()
110 params['page'] = current_page.previous_page_number()
102 return self.get_reverse_url(params)
111 return self.get_reverse_url(params)
103
112
104 def get_next_page_link(self, current_page, params):
113 def get_next_page_link(self, current_page, params):
105 params['page'] = current_page.next_page_number()
114 params['page'] = current_page.next_page_number()
106 return self.get_reverse_url(params)
115 return self.get_reverse_url(params)
107
116
108 def get_url_params(self, params):
117 def get_url_params(self, params):
109 return '?' + '&'.join(['{}={}'.format(key, params[key]) for key in params.keys()])
118 return '?' + '&'.join(['{}={}'.format(key, params[key]) for key in params.keys()])
110
119
111 def get_reverse_url(self, params):
120 def get_reverse_url(self, params):
112 return reverse('index') + self.get_url_params(params)
121 return reverse('index') + self.get_url_params(params)
113
122
114 @transaction.atomic
123 @transaction.atomic
115 def create_thread(self, request, form: ThreadForm, html_response=True):
124 def create_thread(self, request, form: ThreadForm, html_response=True):
116 """
125 """
117 Creates a new thread with an opening post.
126 Creates a new thread with an opening post.
118 """
127 """
119
128
120 ip = utils.get_client_ip(request)
129 ip = utils.get_client_ip(request)
121 is_banned = Ban.objects.filter(ip=ip).exists()
130 is_banned = Ban.objects.filter(ip=ip).exists()
122
131
123 if is_banned:
132 if is_banned:
124 if html_response:
133 if html_response:
125 return redirect(BannedView().as_view())
134 return redirect(BannedView().as_view())
126 else:
135 else:
127 return
136 return
128
137
129 data = form.cleaned_data
138 data = form.cleaned_data
130
139
131 title = form.get_title()
140 title = form.get_title()
132 text = data[FORM_TEXT]
141 text = data[FORM_TEXT]
133 file = form.get_file()
142 file = form.get_file()
134 threads = data[FORM_THREADS]
143 threads = data[FORM_THREADS]
135
144
136 text = self._remove_invalid_links(text)
145 text = self._remove_invalid_links(text)
137
146
138 tags = data[FORM_TAGS]
147 tags = data[FORM_TAGS]
139
148
140 post = Post.objects.create_post(title=title, text=text, file=file,
149 post = Post.objects.create_post(title=title, text=text, file=file,
141 ip=ip, tags=tags, opening_posts=threads,
150 ip=ip, tags=tags, opening_posts=threads,
142 tripcode=form.get_tripcode())
151 tripcode=form.get_tripcode())
143
152
144 # This is required to update the threads to which posts we have replied
153 # This is required to update the threads to which posts we have replied
145 # when creating this one
154 # when creating this one
146 post.notify_clients()
155 post.notify_clients()
147
156
148 if html_response:
157 if html_response:
149 return redirect(post.get_absolute_url())
158 return redirect(post.get_absolute_url())
150
159
151 def get_threads(self):
160 def get_threads(self):
152 """
161 """
153 Gets list of threads that will be shown on a page.
162 Gets list of threads that will be shown on a page.
154 """
163 """
155
164
156 return Thread.objects\
165 return Thread.objects\
157 .exclude(tags__in=self.settings_manager.get_hidden_tags())
166 .exclude(tags__in=self.settings_manager.get_hidden_tags())
General Comments 0
You need to be logged in to leave comments. Login now