Commit 26e9d78973538332f762c5254e4c7edcf411d0f7
1 parent
5f5f8e88
Exists in
master
and in
2 other branches
Adding log to bulletin difficulties
Showing
31 changed files
with
197 additions
and
88 deletions
Show diff stats
amadeus/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
analytics/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
api/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
bulletin/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" |
... | ... | @@ -70,7 +70,7 @@ msgstr "Metas" |
70 | 70 | msgid "Relevant Indicators" |
71 | 71 | msgstr "Indicadores Relevantes" |
72 | 72 | |
73 | -#: bulletin/models.py:25 bulletin/views.py:883 | |
73 | +#: bulletin/models.py:25 bulletin/views.py:932 | |
74 | 74 | msgid "Bulletin" |
75 | 75 | msgstr "Boletim" |
76 | 76 | |
... | ... | @@ -124,7 +124,7 @@ msgstr "Período desejado" |
124 | 124 | msgid "Save" |
125 | 125 | msgstr "Salvar" |
126 | 126 | |
127 | -#: bulletin/templates/bulletin/create.html:20 bulletin/views.py:454 | |
127 | +#: bulletin/templates/bulletin/create.html:20 bulletin/views.py:503 | |
128 | 128 | msgid "Create Bulletin" |
129 | 129 | msgstr "Criar boletim" |
130 | 130 | |
... | ... | @@ -189,14 +189,14 @@ msgid "The picture could not exceed 5MB." |
189 | 189 | msgstr "A imagem não pode exceder 5MB." |
190 | 190 | |
191 | 191 | #: bulletin/templates/bulletin/send_message.html:62 |
192 | -#: bulletin/templates/bulletin/view.html:223 | |
193 | -#: bulletin/templates/bulletin/window_view.html:234 | |
192 | +#: bulletin/templates/bulletin/view.html:235 | |
193 | +#: bulletin/templates/bulletin/window_view.html:257 | |
194 | 194 | msgid "Close" |
195 | 195 | msgstr "Fechar" |
196 | 196 | |
197 | 197 | #: bulletin/templates/bulletin/send_message.html:63 |
198 | -#: bulletin/templates/bulletin/view.html:224 | |
199 | -#: bulletin/templates/bulletin/window_view.html:235 | |
198 | +#: bulletin/templates/bulletin/view.html:236 | |
199 | +#: bulletin/templates/bulletin/window_view.html:258 | |
200 | 200 | msgid "Send" |
201 | 201 | msgstr "Enviar" |
202 | 202 | |
... | ... | @@ -204,50 +204,55 @@ msgstr "Enviar" |
204 | 204 | msgid "Edit: " |
205 | 205 | msgstr "Editar: " |
206 | 206 | |
207 | -#: bulletin/templates/bulletin/view.html:203 | |
208 | -#: bulletin/templates/bulletin/window_view.html:214 | |
207 | +#: bulletin/templates/bulletin/view.html:215 | |
208 | +#: bulletin/templates/bulletin/window_view.html:237 | |
209 | 209 | msgid "There are obstructions to your activities?" |
210 | 210 | msgstr "Existem impedimentos para as suas atividades?" |
211 | 211 | |
212 | -#: bulletin/templates/bulletin/view.html:204 | |
213 | -#: bulletin/templates/bulletin/window_view.html:215 | |
212 | +#: bulletin/templates/bulletin/view.html:216 | |
213 | +#: bulletin/templates/bulletin/window_view.html:238 | |
214 | 214 | msgid "Click here" |
215 | 215 | msgstr "Clique aqui" |
216 | 216 | |
217 | -#: bulletin/templates/bulletin/view.html:204 | |
218 | -#: bulletin/templates/bulletin/window_view.html:215 | |
217 | +#: bulletin/templates/bulletin/view.html:216 | |
218 | +#: bulletin/templates/bulletin/window_view.html:238 | |
219 | 219 | msgid "to communicate the difficulties that may decrease your performance." |
220 | 220 | msgstr "para informar as dificuldades que podem prejudicar seu desempenho." |
221 | 221 | |
222 | -#: bulletin/templates/bulletin/view.html:219 | |
223 | -#: bulletin/templates/bulletin/window_view.html:230 | |
222 | +#: bulletin/templates/bulletin/view.html:231 | |
223 | +#: bulletin/templates/bulletin/window_view.html:253 | |
224 | 224 | msgid "Type here the dificulties that may harm your performance" |
225 | 225 | msgstr "Escreva aqui as dificuldades que podem diminuir sua performance" |
226 | 226 | |
227 | -#: bulletin/utils.py:50 bulletin/views.py:950 | |
227 | +#: bulletin/utils.py:50 bulletin/views.py:1019 | |
228 | 228 | #, python-format |
229 | 229 | msgid "Last message in %s" |
230 | 230 | msgstr "Última mensagem em %s" |
231 | 231 | |
232 | -#: bulletin/views.py:84 bulletin/views.py:227 | |
232 | +#: bulletin/views.py:87 | |
233 | 233 | #, python-format |
234 | -msgid "#Dificulty(ies) found in %s" | |
234 | +msgid "#Difficulty(ies) found in %s" | |
235 | 235 | msgstr "#Dificuldade(s) encontrada(s) em %s" |
236 | 236 | |
237 | -#: bulletin/views.py:88 bulletin/views.py:231 | |
237 | +#: bulletin/views.py:113 bulletin/views.py:280 | |
238 | 238 | msgid "Difficulties sent to the subject professor(s)" |
239 | 239 | msgstr "Dificuldades enviadas para o(s) professor(es) do assunto" |
240 | 240 | |
241 | -#: bulletin/views.py:91 bulletin/views.py:234 | |
241 | +#: bulletin/views.py:117 bulletin/views.py:283 | |
242 | 242 | msgid "You should inform some difficulty" |
243 | 243 | msgstr "Você deve informar alguma dificuldade" |
244 | 244 | |
245 | -#: bulletin/views.py:351 | |
245 | +#: bulletin/views.py:254 | |
246 | +#, python-format | |
247 | +msgid "#Dificulty(ies) found in %s" | |
248 | +msgstr "#Dificuldade(s) encontrada(s) em %s" | |
249 | + | |
250 | +#: bulletin/views.py:400 | |
246 | 251 | #, python-format |
247 | 252 | msgid "The topic %s has no goals, so you can't create a Bulletin." |
248 | 253 | msgstr "O tópico %s não possui metas, então você não pode criar um Boletim." |
249 | 254 | |
250 | -#: bulletin/views.py:358 | |
255 | +#: bulletin/views.py:407 | |
251 | 256 | #, python-format |
252 | 257 | msgid "" |
253 | 258 | "The deadline to submit the goals of the topic %s has not yet closed, so you " |
... | ... | @@ -256,17 +261,17 @@ msgstr "" |
256 | 261 | "O prazo para submeter as metas do tópico %s ainda não foi fechado, então " |
257 | 262 | "você não pode criar um Boletim." |
258 | 263 | |
259 | -#: bulletin/views.py:363 | |
264 | +#: bulletin/views.py:412 | |
260 | 265 | #, python-format |
261 | 266 | msgid "The topic %s already has a Bulletin, so you can't create another." |
262 | 267 | msgstr "O tópico %s já possui um Boletim, então você não pode criar outro." |
263 | 268 | |
264 | -#: bulletin/views.py:381 bulletin/views.py:394 bulletin/views.py:663 | |
265 | -#: bulletin/views.py:665 bulletin/views.py:681 bulletin/views.py:683 | |
269 | +#: bulletin/views.py:430 bulletin/views.py:443 bulletin/views.py:712 | |
270 | +#: bulletin/views.py:714 bulletin/views.py:730 bulletin/views.py:732 | |
266 | 271 | msgid "Visualize" |
267 | 272 | msgstr "Visualizar" |
268 | 273 | |
269 | -#: bulletin/views.py:474 | |
274 | +#: bulletin/views.py:523 | |
270 | 275 | #, python-format |
271 | 276 | msgid "" |
272 | 277 | "The Bulletin \"%s\" was added to the Topic \"%s\" of the virtual environment " |
... | ... | @@ -275,58 +280,58 @@ msgstr "" |
275 | 280 | "O Boletim \"%s\" foi adicionado ao Tópio \"%s\" do ambiente virtual \"%s\" " |
276 | 281 | "com sucesso!" |
277 | 282 | |
278 | -#: bulletin/views.py:727 | |
283 | +#: bulletin/views.py:776 | |
279 | 284 | msgid "Update Bulletin" |
280 | 285 | msgstr "Atualizar boletim" |
281 | 286 | |
282 | -#: bulletin/views.py:745 | |
287 | +#: bulletin/views.py:794 | |
283 | 288 | #, python-format |
284 | 289 | msgid "The Bulletin \"%s\" was updated successfully!" |
285 | 290 | msgstr "O Boletim \"%s\" foi atualizado com sucesso!" |
286 | 291 | |
287 | -#: bulletin/views.py:781 | |
292 | +#: bulletin/views.py:830 | |
288 | 293 | #, python-format |
289 | 294 | msgid "" |
290 | 295 | "The bulletin \"%s\" was removed successfully from virtual environment \"%s\"!" |
291 | 296 | msgstr "O boletim \"%s\" foi removido com sucesso do ambiente virtual \"%s\"! " |
292 | 297 | |
293 | -#: bulletin/views.py:840 | |
298 | +#: bulletin/views.py:889 | |
294 | 299 | msgid "Bulletin Reports" |
295 | 300 | msgstr "Relatórios do Boletim" |
296 | 301 | |
297 | -#: bulletin/views.py:859 | |
302 | +#: bulletin/views.py:908 | |
298 | 303 | msgid "Realized" |
299 | 304 | msgstr "Realizada" |
300 | 305 | |
301 | -#: bulletin/views.py:859 | |
306 | +#: bulletin/views.py:908 | |
302 | 307 | msgid "Unrealized" |
303 | 308 | msgstr "Não realizada" |
304 | 309 | |
305 | -#: bulletin/views.py:859 | |
310 | +#: bulletin/views.py:908 | |
306 | 311 | msgid "Historic" |
307 | 312 | msgstr "Histórico" |
308 | 313 | |
309 | -#: bulletin/views.py:874 bulletin/views.py:882 | |
314 | +#: bulletin/views.py:923 bulletin/views.py:931 | |
310 | 315 | msgid "View" |
311 | 316 | msgstr "Visualizar" |
312 | 317 | |
313 | -#: bulletin/views.py:888 | |
318 | +#: bulletin/views.py:937 | |
314 | 319 | msgid "Actions about resource" |
315 | 320 | msgstr "Ações sobre o recurso" |
316 | 321 | |
317 | -#: bulletin/views.py:889 | |
322 | +#: bulletin/views.py:938 | |
318 | 323 | msgid "Quantity" |
319 | 324 | msgstr "Quantidade" |
320 | 325 | |
321 | -#: bulletin/views.py:938 | |
326 | +#: bulletin/views.py:1007 | |
322 | 327 | msgid "[Photo]" |
323 | 328 | msgstr "[Foto]" |
324 | 329 | |
325 | -#: bulletin/views.py:959 | |
330 | +#: bulletin/views.py:1028 | |
326 | 331 | msgid "The message was successfull sent!" |
327 | 332 | msgstr "A mensagem foi enviada com sucesso!" |
328 | 333 | |
329 | -#: bulletin/views.py:961 | |
334 | +#: bulletin/views.py:1030 | |
330 | 335 | msgid "No user selected!" |
331 | 336 | msgstr "Nenhum usuário selecionado!" |
332 | 337 | ... | ... |
bulletin/templates/bulletin/view.html
... | ... | @@ -248,6 +248,17 @@ |
248 | 248 | |
249 | 249 | |
250 | 250 | <script type="text/javascript"> |
251 | + $('#bulletin-difficulties-modal').on('shown.bs.modal', function (e) { | |
252 | + $.ajax({ | |
253 | + url: "{% url 'bulletin:difficulties_log' bulletin.slug %}", | |
254 | + dataType: 'json', | |
255 | + success: function (data) { | |
256 | + }, | |
257 | + error: function (data) { | |
258 | + console.log(data); | |
259 | + } | |
260 | + }); | |
261 | + }); | |
251 | 262 | // Variável obtidas a partir do número de metas atendidas |
252 | 263 | var percent = "{{ percent }}"; |
253 | 264 | ... | ... |
bulletin/templates/bulletin/window_view.html
... | ... | @@ -65,6 +65,16 @@ |
65 | 65 | |
66 | 66 | </head> |
67 | 67 | <body style="background: #FFF"> |
68 | + {% if messages %} | |
69 | + {% for message in messages %} | |
70 | + <div class="alert alert-{{ message.tags }} alert-dismissible" role="alert"> | |
71 | + <button type="button" class="close" data-dismiss="alert" aria-label="Close"> | |
72 | + <span aria-hidden="true">×</span> | |
73 | + </button> | |
74 | + <p>{{ message }}</p> | |
75 | + </div> | |
76 | + {% endfor %} | |
77 | + {% endif %} | |
68 | 78 | |
69 | 79 | {% subject_permissions request.user bulletin.topic.subject as has_subject_permissions %} |
70 | 80 | <div class="container-fluid" style="padding-top: 20px;"> |
... | ... | @@ -217,40 +227,40 @@ |
217 | 227 | </div> |
218 | 228 | |
219 | 229 | {% if not has_subject_permissions %} |
220 | - <div class="form-group" style="background-color:#fff; box-shadow: 1px 1px 25px #c0beaf; margin-top: 15px;"> | |
230 | + <div class="form-group" style="background-color:#fff; box-shadow: 1px 1px 25px #c0beaf; margin-top: 15px;"> | |
221 | 231 | <div class="row"> |
222 | - <div class="col-md-1" align="left" style="padding-left: 25px; padding-top: 10px;"> | |
223 | - <img src="{% static 'img/warning.png' %}" height="80" width="95"/> | |
224 | - </div> | |
225 | - <div class="col-md-11"> | |
226 | - <div class="row"> | |
232 | + <div class="col-md-1" align="left" style="padding-left: 25px; padding-top: 10px;"> | |
233 | + <img src="{% static 'img/warning.png' %}" height="80" width="95"/> | |
234 | + </div> | |
235 | + <div class="col-md-11"> | |
236 | + <div class="row"> | |
227 | 237 | <div align="left" style="padding-left: 25px; font-size:22px; color: #878787; padding-top: 15px;padding-bottom: 20px;">{% trans 'There are obstructions to your activities?' %}</div> |
228 | 238 | <div align="left" style="padding-left: 25px; padding-right:35px; font-size:16px;"><p><a data-toggle="modal" data-target="#bulletin-difficulties-modal" href=""><b>{% trans 'Click here' %}</b></a> {% trans 'to communicate the difficulties that may decrease your performance.' %}</p></div> |
239 | + </div> | |
229 | 240 | </div> |
230 | 241 | </div> |
231 | 242 | </div> |
232 | - </div> | |
233 | - </br> | |
234 | - <div class="modal fade" tabindex="-1" role="dialog" id="bulletin-difficulties-modal"> | |
235 | - <div class="modal-dialog" role="document"> | |
236 | - <div class="modal-content"> | |
243 | + </br> | |
244 | + <div class="modal fade" tabindex="-1" role="dialog" id="bulletin-difficulties-modal"> | |
245 | + <div class="modal-dialog" role="document"> | |
246 | + <div class="modal-content"> | |
237 | 247 | <div class="modal-header"> |
238 | - <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | |
248 | + <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | |
239 | 249 | </div> |
240 | 250 | <div class="modal-body"> |
241 | - <form id="bulletin-difficulties" action="" method="POST" enctype="multipart/form-data"> | |
242 | - {% csrf_token %} | |
243 | - <textarea class="form-control" id="dificulties" name="difficulties" placeholder="{% trans 'Type here the dificulties that may harm your performance' %}"></textarea> | |
244 | - </form> | |
251 | + <form id="bulletin-difficulties" action="" method="POST" enctype="multipart/form-data"> | |
252 | + {% csrf_token %} | |
253 | + <textarea class="form-control" id="dificulties" name="difficulties" placeholder="{% trans 'Type here the dificulties that may harm your performance' %}"></textarea> | |
254 | + </form> | |
245 | 255 | </div> |
246 | 256 | <div class="modal-footer"> |
247 | - <button type="button" class="btn btn-default btn-raised" data-dismiss="modal">{% trans "Close" %}</button> | |
248 | - <button type="submit" class="btn btn-success btn-raised erase-button" form="bulletin-difficulties">{% trans "Send" %}</button> | |
257 | + <button type="button" class="btn btn-default btn-raised" data-dismiss="modal">{% trans "Close" %}</button> | |
258 | + <button type="submit" class="btn btn-success btn-raised erase-button" form="bulletin-difficulties">{% trans "Send" %}</button> | |
249 | 259 | </div> |
260 | + </div> | |
250 | 261 | </div> |
251 | - </div> | |
252 | - </div> | |
253 | - {% endif %} | |
262 | + </div> | |
263 | + {% endif %} | |
254 | 264 | |
255 | 265 | {% include 'session_security/all.html' %} |
256 | 266 | <script type="text/javascript"> |
... | ... | @@ -261,6 +271,19 @@ |
261 | 271 | $('[data-toggle="tooltip"]').tooltip({ |
262 | 272 | trigger: 'hover' |
263 | 273 | }); |
274 | + | |
275 | + $('#bulletin-difficulties-modal').on('shown.bs.modal', function (e) { | |
276 | + $.ajax({ | |
277 | + url: "{% url 'bulletin:difficulties_log' bulletin.slug %}", | |
278 | + dataType: 'json', | |
279 | + success: function (data) { | |
280 | + }, | |
281 | + error: function (data) { | |
282 | + console.log(data); | |
283 | + } | |
284 | + }); | |
285 | + }); | |
286 | + | |
264 | 287 | // Variável obtidas a partir do número de metas atendidas |
265 | 288 | var percent = "{{ percent }}"; |
266 | 289 | ... | ... |
bulletin/urls.py
... | ... | @@ -12,4 +12,5 @@ urlpatterns = [ |
12 | 12 | url(r'^chart/(?P<slug>[\w_-]+)/$', views.StatisticsView.as_view(), name = 'get_chart'), |
13 | 13 | url(r'^send-message/(?P<slug>[\w_-]+)/$', views.SendMessage.as_view(), name = 'send_message'), |
14 | 14 | url(r'^download_file/(?P<file>[\w_-]+)/$', views.download_excel, name = 'download_file'), |
15 | + url(r'^difficulties_log/(?P<slug>[\w_-]+)/$', views.bulletin_diff_view_log, name = 'difficulties_log') | |
15 | 16 | ] | ... | ... |
bulletin/views.py
... | ... | @@ -30,6 +30,8 @@ from .forms import BulletinForm |
30 | 30 | from .models import Bulletin |
31 | 31 | |
32 | 32 | from log.models import Log |
33 | +from log.decorators import log_decorator | |
34 | + | |
33 | 35 | from chat.models import Conversation, TalkMessages, ChatVisualizations |
34 | 36 | from users.models import User |
35 | 37 | from subjects.models import Subject |
... | ... | @@ -81,11 +83,35 @@ class NewWindowView(LoginRequiredMixin, LogMixin, generic.DetailView): |
81 | 83 | self.student = user |
82 | 84 | else: |
83 | 85 | if not difficulties is None and not difficulties == "": |
84 | - message = _("#Dificulty(ies) found in %s")%(str(bulletin)) + ":<p>" + difficulties + "</p>" | |
86 | + print(difficulties) | |
87 | + message = _("#Difficulty(ies) found in %s")%(str(bulletin)) + ":<p>" + difficulties + "</p>" | |
85 | 88 | |
86 | 89 | brodcast_dificulties(self.request, message, bulletin.topic.subject) |
87 | 90 | |
91 | + self.log_context = {} | |
92 | + self.log_context['category_id'] = bulletin.topic.subject.category.id | |
93 | + self.log_context['category_name'] = bulletin.topic.subject.category.name | |
94 | + self.log_context['category_slug'] = bulletin.topic.subject.category.slug | |
95 | + self.log_context['subject_id'] = bulletin.topic.subject.id | |
96 | + self.log_context['subject_name'] = bulletin.topic.subject.name | |
97 | + self.log_context['subject_slug'] = bulletin.topic.subject.slug | |
98 | + self.log_context['topic_id'] = bulletin.topic.id | |
99 | + self.log_context['topic_name'] = bulletin.topic.name | |
100 | + self.log_context['topic_slug'] = bulletin.topic.slug | |
101 | + self.log_context['bulletin_id'] = bulletin.id | |
102 | + self.log_context['bulletin_name'] = bulletin.name | |
103 | + self.log_context['bulletin_slug'] = bulletin.slug | |
104 | + | |
105 | + self.log_action = "send_difficulties" | |
106 | + | |
107 | + super(NewWindowView, self).createLog(self.request.user, self.log_component, self.log_action, | |
108 | + self.log_resource, self.log_context) | |
109 | + | |
110 | + self.log_action = "view" | |
111 | + self.log_context = {} | |
112 | + | |
88 | 113 | messages.success(self.request, message = _("Difficulties sent to the subject professor(s)")) |
114 | + | |
89 | 115 | return self.render_to_response(context = self.get_context_data()) |
90 | 116 | else: |
91 | 117 | messages.error(self.request, message = _("You should inform some difficulty")) |
... | ... | @@ -186,6 +212,7 @@ class NewWindowView(LoginRequiredMixin, LogMixin, generic.DetailView): |
186 | 212 | context['students'] = students |
187 | 213 | |
188 | 214 | return context |
215 | + | |
189 | 216 | class InsideView(LoginRequiredMixin, LogMixin, generic.DetailView): |
190 | 217 | log_component = 'resources' |
191 | 218 | log_action = 'view' |
... | ... | @@ -228,6 +255,28 @@ class InsideView(LoginRequiredMixin, LogMixin, generic.DetailView): |
228 | 255 | |
229 | 256 | brodcast_dificulties(self.request, message, bulletin.topic.subject) |
230 | 257 | |
258 | + self.log_context = {} | |
259 | + self.log_context['category_id'] = bulletin.topic.subject.category.id | |
260 | + self.log_context['category_name'] = bulletin.topic.subject.category.name | |
261 | + self.log_context['category_slug'] = bulletin.topic.subject.category.slug | |
262 | + self.log_context['subject_id'] = bulletin.topic.subject.id | |
263 | + self.log_context['subject_name'] = bulletin.topic.subject.name | |
264 | + self.log_context['subject_slug'] = bulletin.topic.subject.slug | |
265 | + self.log_context['topic_id'] = bulletin.topic.id | |
266 | + self.log_context['topic_name'] = bulletin.topic.name | |
267 | + self.log_context['topic_slug'] = bulletin.topic.slug | |
268 | + self.log_context['bulletin_id'] = bulletin.id | |
269 | + self.log_context['bulletin_name'] = bulletin.name | |
270 | + self.log_context['bulletin_slug'] = bulletin.slug | |
271 | + | |
272 | + self.log_action = "send_difficulties" | |
273 | + | |
274 | + super(NewWindowView, self).createLog(self.request.user, self.log_component, self.log_action, | |
275 | + self.log_resource, self.log_context) | |
276 | + | |
277 | + self.log_action = "view" | |
278 | + self.log_context = {} | |
279 | + | |
231 | 280 | messages.success(self.request, message = _("Difficulties sent to the subject professor(s)")) |
232 | 281 | return self.render_to_response(context = self.get_context_data()) |
233 | 282 | else: |
... | ... | @@ -893,7 +942,27 @@ class StatisticsView(LoginRequiredMixin, LogMixin, generic.DetailView): |
893 | 942 | context["history_table"] = history |
894 | 943 | return context |
895 | 944 | |
945 | +@log_decorator('resources', 'access_difficulties_modal', 'bulletin') | |
946 | +def bulletin_diff_view_log(request, slug): | |
947 | + bulletin = get_object_or_404(Bulletin, slug = slug) | |
896 | 948 | |
949 | + log_context = {} | |
950 | + log_context['category_id'] = bulletin.topic.subject.category.id | |
951 | + log_context['category_name'] = bulletin.topic.subject.category.name | |
952 | + log_context['category_slug'] = bulletin.topic.subject.category.slug | |
953 | + log_context['subject_id'] = bulletin.topic.subject.id | |
954 | + log_context['subject_name'] = bulletin.topic.subject.name | |
955 | + log_context['subject_slug'] = bulletin.topic.subject.slug | |
956 | + log_context['topic_id'] = bulletin.topic.id | |
957 | + log_context['topic_name'] = bulletin.topic.name | |
958 | + log_context['topic_slug'] = bulletin.topic.slug | |
959 | + log_context['bulletin_id'] = bulletin.id | |
960 | + log_context['bulletin_name'] = bulletin.name | |
961 | + log_context['bulletin_slug'] = bulletin.slug | |
962 | + | |
963 | + request.log_context = log_context | |
964 | + | |
965 | + return JsonResponse({'message': 'ok'}) | |
897 | 966 | |
898 | 967 | from django.http import HttpResponse #used to send HTTP 404 error to ajax |
899 | 968 | ... | ... |
categories/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
chat/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
dashboards/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
file_link/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
goals/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
links/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
log/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
mailsender/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
mural/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
news/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" |
... | ... | @@ -132,7 +132,7 @@ msgstr "Pesquisar Notícia" |
132 | 132 | msgid "Update News" |
133 | 133 | msgstr "Atualizar Notícia" |
134 | 134 | |
135 | -#: news/templates/news/view.html:32 | |
135 | +#: news/templates/news/view.html:35 | |
136 | 136 | msgid "Print News" |
137 | 137 | msgstr "Imprimir Notícia" |
138 | 138 | ... | ... |
notifications/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
pdf_file/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
pendencies/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
reports/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
security/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
students_group/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
subjects/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
themes/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
topics/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
users/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
webconference/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
webpage/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |
youtube_video/locale/pt_BR/LC_MESSAGES/django.po
... | ... | @@ -8,7 +8,7 @@ msgid "" |
8 | 8 | msgstr "" |
9 | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-09-02 01:44-0300\n" | |
11 | +"POT-Creation-Date: 2017-09-03 00:15-0300\n" | |
12 | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" | ... | ... |