Commit 84233de671f217bb31ca9cbf9f25d415b838bbdf
Exists in
master
and in
39 other branches
Merge branch 'master' into haystack
Conflicts: requirements.txt
Showing
13 changed files
with
862 additions
and
67 deletions
Show diff stats
puppet/modules/colab/manifests/requirements.pp
@@ -36,7 +36,7 @@ class colab::requirements { | @@ -36,7 +36,7 @@ class colab::requirements { | ||
36 | package { 'pyOpenSSL': | 36 | package { 'pyOpenSSL': |
37 | ensure => installed, | 37 | ensure => installed, |
38 | provider => pip, | 38 | provider => pip, |
39 | - require => Package['python-pip'], | 39 | + require => [Package['python-pip'], Package['python-dev'], Package['build-essential']], |
40 | } | 40 | } |
41 | 41 | ||
42 | # links virtualenvwrapper to load automaticaly | 42 | # links virtualenvwrapper to load automaticaly |
requirements.txt
1 | -#https://www.djangoproject.com/download/1.6b4/tarball/ | ||
2 | -Django==1.5.2 | 1 | +https://www.djangoproject.com/download/1.6b4/tarball/ |
2 | +#Django==1.5.2 | ||
3 | South==0.8.1 | 3 | South==0.8.1 |
4 | psycopg2==2.5.1 | 4 | psycopg2==2.5.1 |
5 | django-piston==0.2.3 | 5 | django-piston==0.2.3 |
@@ -9,6 +9,7 @@ python-dateutil==1.5 | @@ -9,6 +9,7 @@ python-dateutil==1.5 | ||
9 | django-cliauth==0.9 | 9 | django-cliauth==0.9 |
10 | django-mobile==0.3.0 | 10 | django-mobile==0.3.0 |
11 | django-haystack==2.1 | 11 | django-haystack==2.1 |
12 | +html2text | ||
12 | 13 | ||
13 | gunicorn | 14 | gunicorn |
14 | gevent | 15 | gevent |
src/accounts/templates/accounts/user_detail.html
@@ -34,6 +34,7 @@ | @@ -34,6 +34,7 @@ | ||
34 | {{ user_.institution }} | 34 | {{ user_.institution }} |
35 | </li> | 35 | </li> |
36 | {% endif %} | 36 | {% endif %} |
37 | + {% if request.user.is_active %} | ||
37 | {% if user_.twitter %} | 38 | {% if user_.twitter %} |
38 | <li><span class="icon-twitter icon-fixed-width"></span> {{ user_.twitter }}</li> | 39 | <li><span class="icon-twitter icon-fixed-width"></span> {{ user_.twitter }}</li> |
39 | {% endif %} | 40 | {% endif %} |
@@ -46,6 +47,7 @@ | @@ -46,6 +47,7 @@ | ||
46 | {% if user_.webpage %} | 47 | {% if user_.webpage %} |
47 | <li><span class="icon-link icon-fixed-width"></span> {{ user_.webpage }}</li> | 48 | <li><span class="icon-link icon-fixed-width"></span> {{ user_.webpage }}</li> |
48 | {% endif %} | 49 | {% endif %} |
50 | + {% endif %} | ||
49 | </ul> | 51 | </ul> |
50 | </div> | 52 | </div> |
51 | 53 |
src/accounts/templatetags/gravatar.py
@@ -17,4 +17,4 @@ def gravatar(email, size=80): | @@ -17,4 +17,4 @@ def gravatar(email, size=80): | ||
17 | 17 | ||
18 | email_md5 = getattr(email, 'md5', 'anonymous') | 18 | email_md5 = getattr(email, 'md5', 'anonymous') |
19 | 19 | ||
20 | - return u'<img src="http://www.gravatar.com/avatar/{}?s={}&d=mm" height="{}px" width="{}px">'.format(email_md5, size, size, size) | 20 | + return u'<img src="http://www.gravatar.com/avatar/{}?s={}&d=mm" height="{}px" width="{}px" />'.format(email_md5, size, size, size) |
src/colab/custom_settings.py
@@ -128,6 +128,7 @@ TEMPLATE_CONTEXT_PROCESSORS = ( | @@ -128,6 +128,7 @@ TEMPLATE_CONTEXT_PROCESSORS = ( | ||
128 | 'django.core.context_processors.request', | 128 | 'django.core.context_processors.request', |
129 | 'django_browserid.context_processors.browserid', | 129 | 'django_browserid.context_processors.browserid', |
130 | 'django_mobile.context_processors.is_mobile', | 130 | 'django_mobile.context_processors.is_mobile', |
131 | + 'super_archives.context_processors.mailarchive', | ||
131 | ) | 132 | ) |
132 | 133 | ||
133 | MIDDLEWARE_CLASSES = ( | 134 | MIDDLEWARE_CLASSES = ( |
@@ -158,6 +159,10 @@ TEMPLATE_DIRS = ( | @@ -158,6 +159,10 @@ TEMPLATE_DIRS = ( | ||
158 | os.path.join(BASE_DIR, 'templates'), | 159 | os.path.join(BASE_DIR, 'templates'), |
159 | ) | 160 | ) |
160 | 161 | ||
162 | +LOCALE_PATHS = ( | ||
163 | + os.path.join(BASE_DIR, 'locale'), | ||
164 | +) | ||
165 | + | ||
161 | AUTH_USER_MODEL = 'accounts.User' | 166 | AUTH_USER_MODEL = 'accounts.User' |
162 | 167 | ||
163 | from django.contrib.messages import constants as messages | 168 | from django.contrib.messages import constants as messages |
No preview for this file type
@@ -0,0 +1,700 @@ | @@ -0,0 +1,700 @@ | ||
1 | +# SOME DESCRIPTIVE TITLE. | ||
2 | +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER | ||
3 | +# This file is distributed under the same license as the PACKAGE package. | ||
4 | +# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR. | ||
5 | +# | ||
6 | +msgid "" | ||
7 | +msgstr "" | ||
8 | +"Project-Id-Version: PACKAGE VERSION\n" | ||
9 | +"Report-Msgid-Bugs-To: \n" | ||
10 | +"POT-Creation-Date: 2013-10-02 14:19-0300\n" | ||
11 | +"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | ||
12 | +"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | ||
13 | +"Language-Team: LANGUAGE <LL@li.org>\n" | ||
14 | +"Language: \n" | ||
15 | +"MIME-Version: 1.0\n" | ||
16 | +"Content-Type: text/plain; charset=UTF-8\n" | ||
17 | +"Content-Transfer-Encoding: 8bit\n" | ||
18 | +"Plural-Forms: nplurals=2; plural=(n > 1);\n" | ||
19 | + | ||
20 | +#: accounts/admin.py:40 | ||
21 | +msgid "Personal info" | ||
22 | +msgstr "" | ||
23 | + | ||
24 | +#: accounts/admin.py:43 | ||
25 | +msgid "Permissions" | ||
26 | +msgstr "" | ||
27 | + | ||
28 | +#: accounts/admin.py:45 | ||
29 | +msgid "Important dates" | ||
30 | +msgstr "" | ||
31 | + | ||
32 | +#: accounts/forms.py:46 | ||
33 | +msgid "Mailing lists" | ||
34 | +msgstr "" | ||
35 | + | ||
36 | +#: accounts/views.py:91 | ||
37 | +msgid "Your profile has been created!" | ||
38 | +msgstr "" | ||
39 | + | ||
40 | +#: accounts/views.py:92 | ||
41 | +msgid "" | ||
42 | +"You must login to validated your profile. Profiles not validated are deleted " | ||
43 | +"in 24h." | ||
44 | +msgstr "" | ||
45 | + | ||
46 | +#: accounts/templates/accounts/user_create_form.html:6 | ||
47 | +msgid "Sign up" | ||
48 | +msgstr "" | ||
49 | + | ||
50 | +#: accounts/templates/accounts/user_create_form.html:11 | ||
51 | +msgid "Please correct the errors below and try again" | ||
52 | +msgstr "" | ||
53 | + | ||
54 | +#: accounts/templates/accounts/user_create_form.html:18 | ||
55 | +msgid "Required fields" | ||
56 | +msgstr "" | ||
57 | + | ||
58 | +#: accounts/templates/accounts/user_create_form.html:30 | ||
59 | +msgid "Personal Information" | ||
60 | +msgstr "" | ||
61 | + | ||
62 | +#: accounts/templates/accounts/user_create_form.html:47 | ||
63 | +msgid "Subscribe to mail lists" | ||
64 | +msgstr "" | ||
65 | + | ||
66 | +#: accounts/templates/accounts/user_create_form.html:61 templates/base.html:91 | ||
67 | +msgid "Register" | ||
68 | +msgstr "Cadastre-se" | ||
69 | + | ||
70 | +#: accounts/templates/accounts/user_detail.html:23 | ||
71 | +msgid "update your profile" | ||
72 | +msgstr "" | ||
73 | + | ||
74 | +#: accounts/templates/accounts/user_detail.html:55 | ||
75 | +msgid "Contributions by Area" | ||
76 | +msgstr "" | ||
77 | + | ||
78 | +#: accounts/templates/accounts/user_detail.html:67 | ||
79 | +msgid "Mailing list Participation" | ||
80 | +msgstr "" | ||
81 | + | ||
82 | +#: accounts/templates/accounts/user_detail.html:78 | ||
83 | +msgid "Latest posted" | ||
84 | +msgstr "" | ||
85 | + | ||
86 | +#: accounts/templates/accounts/user_detail.html:83 | ||
87 | +msgid "There are no posts by this user so far." | ||
88 | +msgstr "" | ||
89 | + | ||
90 | +#: accounts/templates/accounts/user_detail.html:89 | ||
91 | +msgid "Community inside participations" | ||
92 | +msgstr "" | ||
93 | + | ||
94 | +#: accounts/templates/accounts/user_detail.html:94 | ||
95 | +msgid "No contributions of this user so far." | ||
96 | +msgstr "" | ||
97 | + | ||
98 | +#: accounts/templates/accounts/user_update_form.html:11 | ||
99 | +msgid "Change your avatar at Gravatar.com" | ||
100 | +msgstr "" | ||
101 | + | ||
102 | +#: accounts/templates/accounts/user_update_form.html:32 | ||
103 | +msgid "Update" | ||
104 | +msgstr "" | ||
105 | + | ||
106 | +#: colab/custom_settings.py:11 | ||
107 | +msgid "English" | ||
108 | +msgstr "" | ||
109 | + | ||
110 | +#: colab/custom_settings.py:12 | ||
111 | +msgid "Spanish" | ||
112 | +msgstr "" | ||
113 | + | ||
114 | +#: colab/custom_settings.py:13 | ||
115 | +msgid "Portuguese" | ||
116 | +msgstr "" | ||
117 | + | ||
118 | +#: colab/custom_settings.py:172 | ||
119 | +msgid "Planet Colab" | ||
120 | +msgstr "" | ||
121 | + | ||
122 | +#: colab/custom_settings.py:173 | ||
123 | +msgid "Colab blog aggregator" | ||
124 | +msgstr "" | ||
125 | + | ||
126 | +#: colab/deprecated/signup.py:13 | ||
127 | +msgid "Colab: Checking e-mail" | ||
128 | +msgstr "" | ||
129 | + | ||
130 | +#: colab/deprecated/signup.py:31 | ||
131 | +msgid "Registration on the mailing list" | ||
132 | +msgstr "" | ||
133 | + | ||
134 | +#: colab/deprecated/views/other.py:65 | ||
135 | +msgid "anônimo" | ||
136 | +msgstr "" | ||
137 | + | ||
138 | +#: planet/templates/feedzilla/_post_template.html:8 | ||
139 | +msgid "From" | ||
140 | +msgstr "" | ||
141 | + | ||
142 | +#: planet/templates/feedzilla/_post_template.html:8 | ||
143 | +msgid "on" | ||
144 | +msgstr "" | ||
145 | + | ||
146 | +#: planet/templates/feedzilla/_post_template.html:12 | ||
147 | +msgid "Read original" | ||
148 | +msgstr "" | ||
149 | + | ||
150 | +#: planet/templates/feedzilla/base.html:5 templates/base.html:71 | ||
151 | +msgid "Planet" | ||
152 | +msgstr "" | ||
153 | + | ||
154 | +#: planet/templates/feedzilla/base.html:15 templates/base.html:84 | ||
155 | +msgid "Tags" | ||
156 | +msgstr "" | ||
157 | + | ||
158 | +#: planet/templates/feedzilla/base.html:19 | ||
159 | +msgid "Source Blogs" | ||
160 | +msgstr "" | ||
161 | + | ||
162 | +#: planet/templates/feedzilla/base.html:22 | ||
163 | +#: planet/templates/feedzilla/submit_blog.html:5 | ||
164 | +msgid "Submit a blog" | ||
165 | +msgstr "" | ||
166 | + | ||
167 | +#: planet/templates/feedzilla/index.html:10 | ||
168 | +msgid "There is no RSS registered" | ||
169 | +msgstr "" | ||
170 | + | ||
171 | +#: planet/templates/feedzilla/index.html:11 | ||
172 | +msgid "Please" | ||
173 | +msgstr "" | ||
174 | + | ||
175 | +#: planet/templates/feedzilla/index.html:12 | ||
176 | +msgid "click here" | ||
177 | +msgstr "" | ||
178 | + | ||
179 | +#: planet/templates/feedzilla/index.html:13 | ||
180 | +msgid "to submit a blog" | ||
181 | +msgstr "" | ||
182 | + | ||
183 | +#: planet/templates/feedzilla/submit_blog.html:8 | ||
184 | +msgid "" | ||
185 | +"Thank you. Your application has been accepted and will be reviewed by admin " | ||
186 | +"in the near time." | ||
187 | +msgstr "" | ||
188 | + | ||
189 | +#: planet/templates/feedzilla/submit_blog.html:27 | ||
190 | +msgid "Submit" | ||
191 | +msgstr "" | ||
192 | + | ||
193 | +#: planet/templates/feedzilla/tag.html:7 | ||
194 | +#, python-format | ||
195 | +msgid "Posts with «%(tag)s» label" | ||
196 | +msgstr "" | ||
197 | + | ||
198 | +#: planet/templates/feedzilla/tag.html:16 | ||
199 | +msgid "No posts with such label" | ||
200 | +msgstr "" | ||
201 | + | ||
202 | +#: rss/feeds.py:13 | ||
203 | +msgid "Latest Discussions" | ||
204 | +msgstr "" | ||
205 | + | ||
206 | +#: rss/feeds.py:32 | ||
207 | +msgid "Discussions Most Relevance" | ||
208 | +msgstr "" | ||
209 | + | ||
210 | +#: rss/feeds.py:51 | ||
211 | +msgid "Latest collaborations" | ||
212 | +msgstr "" | ||
213 | + | ||
214 | +#: super_archives/models.py:45 super_archives/templates/message-thread.html:4 | ||
215 | +msgid "Anonymous" | ||
216 | +msgstr "" | ||
217 | + | ||
218 | +#: super_archives/models.py:74 | ||
219 | +msgid "Mailing List" | ||
220 | +msgstr "" | ||
221 | + | ||
222 | +#: super_archives/models.py:75 | ||
223 | +msgid "The Mailing List where is the thread" | ||
224 | +msgstr "" | ||
225 | + | ||
226 | +#: super_archives/models.py:78 | ||
227 | +msgid "Latest message" | ||
228 | +msgstr "" | ||
229 | + | ||
230 | +#: super_archives/models.py:79 | ||
231 | +msgid "Latest message posted" | ||
232 | +msgstr "" | ||
233 | + | ||
234 | +#: super_archives/models.py:80 | ||
235 | +msgid "Score" | ||
236 | +msgstr "" | ||
237 | + | ||
238 | +#: super_archives/models.py:80 | ||
239 | +msgid "Thread score" | ||
240 | +msgstr "" | ||
241 | + | ||
242 | +#: super_archives/models.py:87 | ||
243 | +msgid "Thread" | ||
244 | +msgstr "" | ||
245 | + | ||
246 | +#: super_archives/models.py:88 | ||
247 | +msgid "Threads" | ||
248 | +msgstr "" | ||
249 | + | ||
250 | +#: super_archives/models.py:170 | ||
251 | +msgid "Subject" | ||
252 | +msgstr "" | ||
253 | + | ||
254 | +#: super_archives/models.py:171 | ||
255 | +msgid "Please enter a message subject" | ||
256 | +msgstr "" | ||
257 | + | ||
258 | +#: super_archives/models.py:174 | ||
259 | +msgid "Message body" | ||
260 | +msgstr "" | ||
261 | + | ||
262 | +#: super_archives/models.py:175 | ||
263 | +msgid "Please enter a message body" | ||
264 | +msgstr "" | ||
265 | + | ||
266 | +#: super_archives/models.py:184 | ||
267 | +msgid "Message" | ||
268 | +msgstr "" | ||
269 | + | ||
270 | +#: super_archives/models.py:185 | ||
271 | +msgid "Messages" | ||
272 | +msgstr "" | ||
273 | + | ||
274 | +#: super_archives/templates/message-list.html:6 templates/base.html:68 | ||
275 | +msgid "Discussions" | ||
276 | +msgstr "" | ||
277 | + | ||
278 | +#: super_archives/templates/message-list.html:11 templates/search.html:18 | ||
279 | +msgid "Filters" | ||
280 | +msgstr "" | ||
281 | + | ||
282 | +#: super_archives/templates/message-list.html:13 | ||
283 | +msgid "Sort by" | ||
284 | +msgstr "" | ||
285 | + | ||
286 | +#: super_archives/templates/message-list.html:15 | ||
287 | +#: super_archives/templates/message-list.html:17 | ||
288 | +#: super_archives/templates/message-list.html:25 templates/search.html:23 | ||
289 | +#: templates/search.html.py:27 templates/search.html:31 | ||
290 | +#: templates/search.html.py:35 | ||
291 | +msgid "Remove filter" | ||
292 | +msgstr "Remover filtro" | ||
293 | + | ||
294 | +#: super_archives/templates/message-list.html:16 | ||
295 | +msgid "Relevance" | ||
296 | +msgstr "" | ||
297 | + | ||
298 | +#: super_archives/templates/message-list.html:19 | ||
299 | +msgid "Recent activity" | ||
300 | +msgstr "" | ||
301 | + | ||
302 | +#: super_archives/templates/message-list.html:22 | ||
303 | +msgid "Lists" | ||
304 | +msgstr "" | ||
305 | + | ||
306 | +#: super_archives/templates/message-list.html:39 | ||
307 | +msgid "No discussion found" | ||
308 | +msgstr "" | ||
309 | + | ||
310 | +#: super_archives/templates/message-list.html:49 templates/search.html:57 | ||
311 | +msgid "Previous" | ||
312 | +msgstr "" | ||
313 | + | ||
314 | +#: super_archives/templates/message-list.html:53 templates/search.html:61 | ||
315 | +msgid "Page" | ||
316 | +msgstr "" | ||
317 | + | ||
318 | +#: super_archives/templates/message-list.html:53 templates/search.html:61 | ||
319 | +msgid "of" | ||
320 | +msgstr "" | ||
321 | + | ||
322 | +#: super_archives/templates/message-list.html:57 templates/search.html:65 | ||
323 | +msgid "Next" | ||
324 | +msgstr "" | ||
325 | + | ||
326 | +#: super_archives/templates/message-preview.html:35 | ||
327 | +msgid "by" | ||
328 | +msgstr "" | ||
329 | + | ||
330 | +#: super_archives/templates/message-preview.html:51 | ||
331 | +#: super_archives/templates/message-thread.html:182 | ||
332 | +msgid "ago" | ||
333 | +msgstr "" | ||
334 | + | ||
335 | +#: super_archives/templates/message-thread.html:39 | ||
336 | +msgid "You must login before voting." | ||
337 | +msgstr "" | ||
338 | + | ||
339 | +#: super_archives/templates/message-thread.html:164 | ||
340 | +msgid "Order by" | ||
341 | +msgstr "" | ||
342 | + | ||
343 | +#: super_archives/templates/message-thread.html:168 | ||
344 | +msgid "Votes" | ||
345 | +msgstr "" | ||
346 | + | ||
347 | +#: super_archives/templates/message-thread.html:172 | ||
348 | +msgid "Date" | ||
349 | +msgstr "" | ||
350 | + | ||
351 | +#: super_archives/templates/message-thread.html:176 | ||
352 | +msgid "Statistics:" | ||
353 | +msgstr "" | ||
354 | + | ||
355 | +#: super_archives/templates/message-thread.html:181 | ||
356 | +msgid "started at" | ||
357 | +msgstr "" | ||
358 | + | ||
359 | +#: super_archives/templates/message-thread.html:187 | ||
360 | +msgid "viewed" | ||
361 | +msgstr "" | ||
362 | + | ||
363 | +#: super_archives/templates/message-thread.html:188 | ||
364 | +#: super_archives/templates/message-thread.html:193 | ||
365 | +#: super_archives/templates/message-thread.html:198 | ||
366 | +msgid "times" | ||
367 | +msgstr "" | ||
368 | + | ||
369 | +#: super_archives/templates/message-thread.html:192 | ||
370 | +msgid "answered" | ||
371 | +msgstr "" | ||
372 | + | ||
373 | +#: super_archives/templates/message-thread.html:197 | ||
374 | +msgid "voted" | ||
375 | +msgstr "" | ||
376 | + | ||
377 | +#: templates/404.html:3 | ||
378 | +msgid "Not found. Keep searching! :)" | ||
379 | +msgstr "Não encontrado. Continue procurando! :)" | ||
380 | + | ||
381 | +#: templates/500.html:3 | ||
382 | +msgid "Ooopz... something went wrong!" | ||
383 | +msgstr "Opa... algo saiu errado!" | ||
384 | + | ||
385 | +#: templates/base.html:74 | ||
386 | +msgid "Contribute" | ||
387 | +msgstr "Contribua" | ||
388 | + | ||
389 | +#: templates/base.html:78 | ||
390 | +msgid "New Ticket" | ||
391 | +msgstr "Novo Tiquete" | ||
392 | + | ||
393 | +#: templates/base.html:80 | ||
394 | +msgid "Timeline" | ||
395 | +msgstr "Histórico" | ||
396 | + | ||
397 | +#: templates/base.html:81 | ||
398 | +msgid "Roadmap" | ||
399 | +msgstr "Planejamento" | ||
400 | + | ||
401 | +#: templates/base.html:82 | ||
402 | +msgid "Browse Source" | ||
403 | +msgstr "Ver Código" | ||
404 | + | ||
405 | +#: templates/base.html:83 | ||
406 | +msgid "View Tickets" | ||
407 | +msgstr "Visualizar Tiquetes" | ||
408 | + | ||
409 | +#: templates/base.html:105 | ||
410 | +msgid "My Profile" | ||
411 | +msgstr "Meu Perfil" | ||
412 | + | ||
413 | +#: templates/base.html:117 templates/base.html.py:120 | ||
414 | +msgid "Search here..." | ||
415 | +msgstr "Pesquise aqui..." | ||
416 | + | ||
417 | +#: templates/base.html:156 | ||
418 | +msgid "The contents of this site is published under license" | ||
419 | +msgstr "O conteúdo deste site está publicado sob a licença" | ||
420 | + | ||
421 | +#: templates/base.html:158 | ||
422 | +msgid "Creative Commons - attribution, non-commercial" | ||
423 | +msgstr "Creative Commons - atribuição e não-comercial" | ||
424 | + | ||
425 | +#: templates/home.html:15 | ||
426 | +msgid "INTERLEGIS COMMUNITIES" | ||
427 | +msgstr "COMUNIDADES INTERLEGIS" | ||
428 | + | ||
429 | +#: templates/home.html:23 | ||
430 | +msgid "Latest Collaborations" | ||
431 | +msgstr "Últimas Colaborações" | ||
432 | + | ||
433 | +#: templates/home.html:27 | ||
434 | +msgid "RSS - Latest collaborations" | ||
435 | +msgstr "RSS - Últimas Colaborações" | ||
436 | + | ||
437 | +#: templates/home.html:36 | ||
438 | +msgid "View more collaborations..." | ||
439 | +msgstr "Ver mais colaborações..." | ||
440 | + | ||
441 | +#: templates/home.html:43 | ||
442 | +msgid "Collaboration Graph" | ||
443 | +msgstr "Gráfico de Colaborações" | ||
444 | + | ||
445 | +#: templates/home.html:51 | ||
446 | +msgid "Most Relevant Threads" | ||
447 | +msgstr "Discussões Mais Relevantes" | ||
448 | + | ||
449 | +#: templates/home.html:55 | ||
450 | +msgid "RSS - Most Relevant Threads" | ||
451 | +msgstr "RSS - Discussões Mais Relevantes" | ||
452 | + | ||
453 | +#: templates/home.html:64 templates/home.html.py:83 | ||
454 | +msgid "View more discussions..." | ||
455 | +msgstr "Ver mais discussões..." | ||
456 | + | ||
457 | +#: templates/home.html:71 | ||
458 | +msgid "Latest Threads" | ||
459 | +msgstr "Últimas Discussões" | ||
460 | + | ||
461 | +#: templates/home.html:75 | ||
462 | +msgid "RSS - Latest Threads" | ||
463 | +msgstr "RSS - Últimas Discussões" | ||
464 | + | ||
465 | +#: templates/open-data.html:6 | ||
466 | +msgid "OpenData - Communities Interlegis" | ||
467 | +msgstr "OpenData - Comunidades Interlegis" | ||
468 | + | ||
469 | +#: templates/open-data.html:7 | ||
470 | +msgid "" | ||
471 | +"At this point the system Colab provides much of its data \n" | ||
472 | +" through its search engine." | ||
473 | +msgstr "" | ||
474 | + | ||
475 | +#: templates/open-data.html:9 | ||
476 | +msgid "" | ||
477 | +"If you are interested in integrating your system with the environment " | ||
478 | +"Colab \n" | ||
479 | +" and requires no other data provided by this API, please contact us " | ||
480 | +"via the ticketing \n" | ||
481 | +" system (you must be registered in order to create a ticket)." | ||
482 | +msgstr "" | ||
483 | + | ||
484 | +#: templates/open-data.html:13 | ||
485 | +msgid "Performing searches via the API" | ||
486 | +msgstr "" | ||
487 | + | ||
488 | +#: templates/open-data.html:14 | ||
489 | +msgid "" | ||
490 | +"The Colab API searches works through an HTTP/REST always returning JSON " | ||
491 | +"objects with result." | ||
492 | +msgstr "" | ||
493 | + | ||
494 | +#: templates/open-data.html:15 | ||
495 | +msgid "The base URL used for the search is:" | ||
496 | +msgstr "" | ||
497 | + | ||
498 | +#: templates/open-data.html:18 | ||
499 | +msgid "Parameters:" | ||
500 | +msgstr "" | ||
501 | + | ||
502 | +#: templates/open-data.html:21 | ||
503 | +msgid "Query" | ||
504 | +msgstr "" | ||
505 | + | ||
506 | +#: templates/open-data.html:22 | ||
507 | +msgid "" | ||
508 | +"The <i>query</i> is the \"question\" sent \n" | ||
509 | +" to the search server. A <i>query</i> consists of \n" | ||
510 | +" <b>field:value</b>, where the field represents a kind of " | ||
511 | +"system data,\n" | ||
512 | +" for example <b>collaborator</b> and represents the data " | ||
513 | +"stored \n" | ||
514 | +" by the system, for example <b>jeanferri</b>." | ||
515 | +msgstr "" | ||
516 | + | ||
517 | +#: templates/open-data.html:27 | ||
518 | +msgid "The following is a list of available fields to search:" | ||
519 | +msgstr "" | ||
520 | + | ||
521 | +#: templates/open-data.html:29 | ||
522 | +msgid "wiki, thread, ticket, changeset." | ||
523 | +msgstr "" | ||
524 | + | ||
525 | +#: templates/open-data.html:30 | ||
526 | +msgid "page name, title of the discussion or ticket, changeset description." | ||
527 | +msgstr "" | ||
528 | + | ||
529 | +#: templates/open-data.html:31 | ||
530 | +msgid "" | ||
531 | +"excerpt from the page or the discussion, description of the ticket or " | ||
532 | +"changeset." | ||
533 | +msgstr "" | ||
534 | + | ||
535 | +#: templates/open-data.html:32 | ||
536 | +msgid "name of user who created the document." | ||
537 | +msgstr "" | ||
538 | + | ||
539 | +#: templates/open-data.html:33 | ||
540 | +msgid "real name who created the document." | ||
541 | +msgstr "" | ||
542 | + | ||
543 | +#: templates/open-data.html:34 | ||
544 | +msgid "creation date." | ||
545 | +msgstr "" | ||
546 | + | ||
547 | +#: templates/open-data.html:35 | ||
548 | +msgid "modification date." | ||
549 | +msgstr "" | ||
550 | + | ||
551 | +#: templates/open-data.html:36 | ||
552 | +msgid "mailing list (only for type thread)." | ||
553 | +msgstr "" | ||
554 | + | ||
555 | +#: templates/open-data.html:37 | ||
556 | +msgid "name of the wiki page." | ||
557 | +msgstr "" | ||
558 | + | ||
559 | +#: templates/open-data.html:38 | ||
560 | +msgid "comments of tickets (all concatenated)." | ||
561 | +msgstr "" | ||
562 | + | ||
563 | +#: templates/open-data.html:39 | ||
564 | +msgid "" | ||
565 | +"contents of wiki page or messages of the discussions (all concatenated)." | ||
566 | +msgstr "" | ||
567 | + | ||
568 | +#: templates/open-data.html:40 | ||
569 | +msgid "keywords (ticket only)." | ||
570 | +msgstr "" | ||
571 | + | ||
572 | +#: templates/open-data.html:41 | ||
573 | +msgid "milestone (ticket only)." | ||
574 | +msgstr "" | ||
575 | + | ||
576 | +#: templates/open-data.html:42 | ||
577 | +msgid "priority (ticket only)." | ||
578 | +msgstr "" | ||
579 | + | ||
580 | +#: templates/open-data.html:43 | ||
581 | +msgid "component (ticket only)." | ||
582 | +msgstr "" | ||
583 | + | ||
584 | +#: templates/open-data.html:44 | ||
585 | +msgid "version (ticket only)." | ||
586 | +msgstr "" | ||
587 | + | ||
588 | +#: templates/open-data.html:45 | ||
589 | +msgid "severity (ticket only)." | ||
590 | +msgstr "" | ||
591 | + | ||
592 | +#: templates/open-data.html:46 | ||
593 | +msgid "responsible (ticket only)." | ||
594 | +msgstr "" | ||
595 | + | ||
596 | +#: templates/open-data.html:47 | ||
597 | +msgid "status (ticket only)." | ||
598 | +msgstr "" | ||
599 | + | ||
600 | +#: templates/open-data.html:48 | ||
601 | +msgid "review (ticket only)." | ||
602 | +msgstr "" | ||
603 | + | ||
604 | +#: templates/open-data.html:49 | ||
605 | +msgid "synonym for the title (for discussion)." | ||
606 | +msgstr "" | ||
607 | + | ||
608 | +#: templates/open-data.html:55 | ||
609 | +msgid "Results per page - n" | ||
610 | +msgstr "" | ||
611 | + | ||
612 | +#: templates/open-data.html:56 | ||
613 | +msgid "" | ||
614 | +"Number of results to be displayed per page. \n" | ||
615 | +" Its value must be an integer between 1 and 500." | ||
616 | +msgstr "" | ||
617 | + | ||
618 | +#: templates/open-data.html:58 | ||
619 | +msgid "Default: 50" | ||
620 | +msgstr "" | ||
621 | + | ||
622 | +#: templates/open-data.html:63 | ||
623 | +msgid "Page - p" | ||
624 | +msgstr "" | ||
625 | + | ||
626 | +#: templates/open-data.html:64 | ||
627 | +msgid "" | ||
628 | +"Page number that appears. Its value must be an \n" | ||
629 | +" integer equal to or greater than 1." | ||
630 | +msgstr "" | ||
631 | + | ||
632 | +#: templates/open-data.html:65 | ||
633 | +msgid "Default: 1" | ||
634 | +msgstr "" | ||
635 | + | ||
636 | +#: templates/open-data.html:70 | ||
637 | +msgid "Order - o" | ||
638 | +msgstr "" | ||
639 | + | ||
640 | +#: templates/open-data.html:71 | ||
641 | +msgid "" | ||
642 | +"Order in which the results will be displayed. Its value must be \n" | ||
643 | +" a string in the <b>field direction</b> where the same field " | ||
644 | +"are \n" | ||
645 | +" presented in the <i>query</i> parameter and direction can " | ||
646 | +"be \n" | ||
647 | +" <b>asc</b> for ascending or <b>desc</b> for descending." | ||
648 | +msgstr "" | ||
649 | + | ||
650 | +#: templates/pizza-chart.html:24 | ||
651 | +msgid "Emails" | ||
652 | +msgstr "Emails" | ||
653 | + | ||
654 | +#: templates/pizza-chart.html:25 | ||
655 | +msgid "Tickets" | ||
656 | +msgstr "Tiquetes" | ||
657 | + | ||
658 | +#: templates/pizza-chart.html:26 templates/search.html:25 | ||
659 | +msgid "Wiki" | ||
660 | +msgstr "Wiki" | ||
661 | + | ||
662 | +#: templates/pizza-chart.html:27 | ||
663 | +msgid "Code" | ||
664 | +msgstr "Código" | ||
665 | + | ||
666 | +#: templates/pizza-chart.html:29 | ||
667 | +msgid "Willing to help" | ||
668 | +msgstr "Vontade de ajudar" | ||
669 | + | ||
670 | +#: templates/search.html:7 | ||
671 | +msgid "Search" | ||
672 | +msgstr "Busca" | ||
673 | + | ||
674 | +#: templates/search.html:10 | ||
675 | +msgid "documents found in" | ||
676 | +msgstr "documentos encontrados em" | ||
677 | + | ||
678 | +#: templates/search.html:11 | ||
679 | +msgid "seconds" | ||
680 | +msgstr "segundos" | ||
681 | + | ||
682 | +#: templates/search.html:20 | ||
683 | +msgid "Types" | ||
684 | +msgstr "Tipos" | ||
685 | + | ||
686 | +#: templates/search.html:29 | ||
687 | +msgid "Discussion" | ||
688 | +msgstr "Discussões" | ||
689 | + | ||
690 | +#: templates/search.html:33 | ||
691 | +msgid "Ticket" | ||
692 | +msgstr "Tiquetes" | ||
693 | + | ||
694 | +#: templates/search.html:37 | ||
695 | +msgid "Changeset" | ||
696 | +msgstr "Conjunto de Mudanças" | ||
697 | + | ||
698 | +#: templates/search.html:48 | ||
699 | +msgid "No results for your search." | ||
700 | +msgstr "" |
src/super_archives/templates/message-preview.html
@@ -16,7 +16,7 @@ | @@ -16,7 +16,7 @@ | ||
16 | {% endif %} | 16 | {% endif %} |
17 | 17 | ||
18 | <span class="subject"> | 18 | <span class="subject"> |
19 | - <a href="{{ doc.url }}" | 19 | + <a href="{{ doc.url }}#msg-{{ doc.id }}" |
20 | {% if | 20 | {% if |
21 | title="{% filter striptags|truncatewords:50 %} | 21 | title="{% filter striptags|truncatewords:50 %} |
22 | {{ doc.Description|escape }} | 22 | {{ doc.Description|escape }} |
src/super_archives/templates/message-thread.html
1 | {% extends "base.html" %} | 1 | {% extends "base.html" %} |
2 | -{% load i18n append_to_get gravatar %} | 2 | +{% load i18n append_to_get gravatar superarchives %} |
3 | 3 | ||
4 | {% trans "Anonymous" as anonymous %} | 4 | {% trans "Anonymous" as anonymous %} |
5 | 5 | ||
6 | {% block head_js %} | 6 | {% block head_js %} |
7 | 7 | ||
8 | <script> | 8 | <script> |
9 | - function vote_done_callback(msg_id, step) { | 9 | + function vote_done_callback(step) { |
10 | console.debug('(un)vote successfuly (step ' + step + ')'); | 10 | console.debug('(un)vote successfuly (step ' + step + ')'); |
11 | - var $msg = $('#msg-' + msg_id) | 11 | + var $btn = $(this); |
12 | + var step; | ||
12 | 13 | ||
13 | - $('.vote-count', $msg).text(function(self, count) { | 14 | + if ($btn.hasClass('btn-default')) { |
15 | + step = 1; | ||
16 | + } else { | ||
17 | + step = -1; | ||
18 | + } | ||
19 | + | ||
20 | + $btn.prev('.vote-count').text(function(self, count) { | ||
14 | return parseInt(count) + step; | 21 | return parseInt(count) + step; |
15 | }); | 22 | }); |
16 | 23 | ||
17 | - if (step == -1) { | ||
18 | - var $btn = $('.vote.btn-success', $msg); | ||
19 | - $btn.unbind('click'); | ||
20 | - $btn.bind('click', function() { | ||
21 | - vote(msg_id); | ||
22 | - }); | ||
23 | - } else { | ||
24 | - var $btn = $('.vote.btn-default', $msg); | ||
25 | - $btn.unbind('click'); | ||
26 | - $btn.bind('click', function() { | ||
27 | - unvote(msg_id); | ||
28 | - }); | ||
29 | - } | ||
30 | $btn.toggleClass('btn-success'); | 24 | $btn.toggleClass('btn-success'); |
31 | $btn.toggleClass('btn-default'); | 25 | $btn.toggleClass('btn-default'); |
32 | $btn.button('reset') | 26 | $btn.button('reset') |
@@ -37,61 +31,57 @@ | @@ -37,61 +31,57 @@ | ||
37 | 31 | ||
38 | if (jqXHR.status === 403) { | 32 | if (jqXHR.status === 403) { |
39 | msg = " {% trans 'You must login before voting.' %}" | 33 | msg = " {% trans 'You must login before voting.' %}" |
40 | - } else { | ||
41 | - return; | 34 | + |
35 | + $('#alert-js #alert-message').html(msg); | ||
36 | + $('#alert-js').show(); | ||
37 | + scroll(0, 0); | ||
42 | } | 38 | } |
43 | 39 | ||
44 | - $('#alert-js #alert-message').html(msg); | ||
45 | - $('#alert-js').show(); | ||
46 | - scroll(0, 0); | ||
47 | } | 40 | } |
48 | 41 | ||
49 | - function get_vote_ajax_dict(msg_id, method) { | 42 | + function vote(event) { |
43 | + var $ajax; | ||
44 | + var $btn = $(this); | ||
45 | + var $msg = $(this).parents('.email-message'); | ||
46 | + | ||
47 | + var method; | ||
50 | var csrftoken = $.cookie('csrftoken'); | 48 | var csrftoken = $.cookie('csrftoken'); |
51 | - $('#msg-' + msg_id + ' .vote.btn-success').button('loading'); | 49 | + var msg_id = $msg.attr('id').split('-')[1]; |
50 | + | ||
51 | + if($btn.hasClass('btn-default')) { | ||
52 | + method = 'PUT'; | ||
53 | + } else { | ||
54 | + method = 'DELETE'; | ||
55 | + } | ||
52 | 56 | ||
53 | - return { | 57 | + console.debug('trying to vote'); |
58 | + $btn.button('loading'); | ||
59 | + $ajax = $.ajax({ | ||
54 | url: "/api/message/" + msg_id + "/vote", | 60 | url: "/api/message/" + msg_id + "/vote", |
55 | type: method, | 61 | type: method, |
62 | + context: $btn.get(0), | ||
56 | beforeSend: function(xhr, settings) { | 63 | beforeSend: function(xhr, settings) { |
57 | xhr.setRequestHeader("X-CSRFToken", csrftoken); | 64 | xhr.setRequestHeader("X-CSRFToken", csrftoken); |
58 | } | 65 | } |
59 | - } | ||
60 | - } | ||
61 | - | ||
62 | - function vote(msg_id) { | ||
63 | - console.debug('trying to vote'); | ||
64 | - $.ajax(get_vote_ajax_dict(msg_id, 'PUT')) | ||
65 | - .done(function(){ | ||
66 | - vote_done_callback(msg_id, 1); | ||
67 | - }) | ||
68 | - .fail(vote_fail_callback); | ||
69 | - } | ||
70 | - | ||
71 | - function unvote(msg_id) { | ||
72 | - console.debug('trying to remove vote'); | ||
73 | - $.ajax(get_vote_ajax_dict(msg_id, 'DELETE')) | ||
74 | - .done(function(){ | ||
75 | - vote_done_callback(msg_id, -1); | ||
76 | - }) | ||
77 | - .fail(vote_fail_callback); | 66 | + }); |
67 | + $ajax.done(vote_done_callback); | ||
68 | + $ajax.fail(vote_fail_callback); | ||
78 | } | 69 | } |
79 | 70 | ||
80 | // Binding functions | 71 | // Binding functions |
81 | $(function() { | 72 | $(function() { |
82 | - console.debug('binding vote function to btns'); | ||
83 | - $('.email-message').each(function() { | ||
84 | - var msg_id = this.getAttribute('id').split('-')[1]; | ||
85 | - | ||
86 | - $('.vote.btn-default', this).bind('click', function() { | ||
87 | - vote(msg_id); | ||
88 | - }); | ||
89 | - | ||
90 | - $('.vote.btn-success', this).bind('click', function() { | ||
91 | - unvote(msg_id); | ||
92 | - }); | ||
93 | - | 73 | + $(".panel-heading").on('click', function(event) { |
74 | + var $target = $(event.target); | ||
75 | + // Do not collapse the the message if the clicked element (target) | ||
76 | + // is a button or a link | ||
77 | + if($target.hasClass('btn') || $target.is('a') || $target.parent().is('a')) { | ||
78 | + return; | ||
79 | + } | ||
80 | + | ||
81 | + $(this).next('.panel-collapse').collapse('toggle'); | ||
94 | }); | 82 | }); |
83 | + | ||
84 | + $('.vote.btn', this).on('click', vote); | ||
95 | }); | 85 | }); |
96 | 86 | ||
97 | </script> | 87 | </script> |
@@ -148,8 +138,10 @@ | @@ -148,8 +138,10 @@ | ||
148 | </div> | 138 | </div> |
149 | 139 | ||
150 | </div> | 140 | </div> |
151 | - <div class="panel-body"> | ||
152 | - <pre>{{ email.body }}</pre> | 141 | + <div class="panel-collapse in"> |
142 | + <div class="panel-body"> | ||
143 | + {% display_message email emails %} | ||
144 | + </div> | ||
153 | </div> | 145 | </div> |
154 | </div> | 146 | </div> |
155 | </div> | 147 | </div> |
src/super_archives/templates/superarchives/tags/display_message.html
0 → 100644
@@ -0,0 +1,9 @@ | @@ -0,0 +1,9 @@ | ||
1 | +{% load cache %} | ||
2 | + | ||
3 | +{% cache cache_timeout 'display_message' cache_key %} | ||
4 | +{% for message, class in messages %} | ||
5 | + {% if class == 'reply' %} | ||
6 | + <button class="btn btn-info btn-xs" onclick="$(this).next().toggle();">...</button> | ||
7 | + <pre style="display: none; color: #707";>{% else %}<pre>{% endif %}{{ message }}</pre> | ||
8 | +{% endfor %} | ||
9 | +{% endcache %} |
@@ -0,0 +1,74 @@ | @@ -0,0 +1,74 @@ | ||
1 | + | ||
2 | +import re | ||
3 | + | ||
4 | +from django import template | ||
5 | +from django.core.cache import cache | ||
6 | + | ||
7 | +from html2text import html2text | ||
8 | + | ||
9 | + | ||
10 | +register = template.Library() | ||
11 | +TEMPLATE_PATH = 'superarchives/tags/' | ||
12 | + | ||
13 | + | ||
14 | +EXTENDED_PUNCTUATION = '!"#$%&\'()*+,-./:;=?@[\\]^_`{|}~ \t\n\r\x0b\x0c' | ||
15 | +RE_WRAPPED_BY_HTML = re.compile(r'^<[a-z]+[^>]*>.*</[a-z]+[^>]*>$', | ||
16 | + re.MULTILINE|re.IGNORECASE|re.DOTALL) | ||
17 | + | ||
18 | + | ||
19 | +def join(block): | ||
20 | + block_txt = u''.join(block) | ||
21 | + | ||
22 | + if RE_WRAPPED_BY_HTML.match(block_txt.strip()): | ||
23 | + return html2text(block_txt) | ||
24 | + | ||
25 | + return block_txt | ||
26 | + | ||
27 | +def is_reply(line, message, thread): | ||
28 | + clean_line = line.strip() | ||
29 | + if clean_line.startswith('>'): | ||
30 | + return True | ||
31 | + | ||
32 | + for other_msg in thread: | ||
33 | + if other_msg == message: | ||
34 | + return False | ||
35 | + | ||
36 | + clean_body = other_msg.body.replace('\r', ' ')\ | ||
37 | + .replace('\n', ' ') | ||
38 | + if clean_line.strip('> ') in clean_body: | ||
39 | + return True | ||
40 | + | ||
41 | + return False | ||
42 | + | ||
43 | + | ||
44 | +@register.inclusion_tag(TEMPLATE_PATH + 'display_message.html', | ||
45 | + takes_context=False) | ||
46 | +def display_message(email, thread): | ||
47 | + message = email.body | ||
48 | + messages = [] | ||
49 | + | ||
50 | + block = [] | ||
51 | + reply_block = False | ||
52 | + | ||
53 | + for line in message.split('\n'): | ||
54 | + if line.strip(EXTENDED_PUNCTUATION): | ||
55 | + if is_reply(line, email, thread): | ||
56 | + if not reply_block: | ||
57 | + reply_block = True | ||
58 | + messages.append((join(block), 'normal')) | ||
59 | + block = [] | ||
60 | + elif reply_block: | ||
61 | + reply_block = False | ||
62 | + messages.append((join(block), 'reply')) | ||
63 | + block = [] | ||
64 | + | ||
65 | + block.append(line.rstrip() + '\n') | ||
66 | + | ||
67 | + if reply_block: | ||
68 | + messages.append((join(block), 'reply')) | ||
69 | + else: | ||
70 | + messages.append((join(block), 'normal')) | ||
71 | + | ||
72 | + return {'messages': messages, | ||
73 | + 'cache_key': email.pk, | ||
74 | + 'cache_timeout': cache.default_timeout} |
src/templates/base.html
@@ -81,7 +81,6 @@ | @@ -81,7 +81,6 @@ | ||
81 | <li><a href="/roadmap">{% trans "Roadmap" %}</a></li> | 81 | <li><a href="/roadmap">{% trans "Roadmap" %}</a></li> |
82 | <li><a href="/browser">{% trans "Browse Source" %}</a></li> | 82 | <li><a href="/browser">{% trans "Browse Source" %}</a></li> |
83 | <li><a href="/report">{% trans "View Tickets" %}</a></li> | 83 | <li><a href="/report">{% trans "View Tickets" %}</a></li> |
84 | - <li><a href="/tags">{% trans "Tags" %}</a></li> | ||
85 | </ul> | 84 | </ul> |
86 | </li> | 85 | </li> |
87 | </ul> | 86 | </ul> |
@@ -147,9 +146,10 @@ | @@ -147,9 +146,10 @@ | ||
147 | 146 | ||
148 | <div class="row"> </div> | 147 | <div class="row"> </div> |
149 | 148 | ||
150 | - <div class="row"> | ||
151 | - {% block footer %} | 149 | + {% block footer %} |
152 | <p class="col-lg-12 text-center"><a href="{% url 'opendata' %}"><img src="{{ STATIC_URL }}img/opendata3.png"/></a></p> | 150 | <p class="col-lg-12 text-center"><a href="{% url 'opendata' %}"><img src="{{ STATIC_URL }}img/opendata3.png"/></a></p> |
151 | + <p class="col-lg-12 text-center">{% trans "Last email imported at" %} {{ last_imported_message.received_time|date:'DATETIME_FORMAT' }}</p> | ||
152 | + <div class="row"> | ||
153 | </div> | 153 | </div> |
154 | <div class="row"> | 154 | <div class="row"> |
155 | <p class="col-lg-12 text-center"> | 155 | <p class="col-lg-12 text-center"> |
@@ -158,8 +158,8 @@ | @@ -158,8 +158,8 @@ | ||
158 | {% trans "Creative Commons - attribution, non-commercial" %} | 158 | {% trans "Creative Commons - attribution, non-commercial" %} |
159 | </a> | 159 | </a> |
160 | </p> | 160 | </p> |
161 | - {% endblock %} | ||
162 | </div> | 161 | </div> |
162 | + {% endblock %} | ||
163 | 163 | ||
164 | 164 | ||
165 | {% if not is_mobile %} | 165 | {% if not is_mobile %} |