Commit dd32871323ac4fcfdf6585ef60db29573d784862
Committed by
GitHub
Exists in
master
and in
2 other branches
Merge pull request #467 from amadeusproject/refactoring
Possible Socket Fix
Showing
21 changed files
with
274 additions
and
142 deletions
Show diff stats
amadeus/static/css/base/amadeus.css
@@ -1113,7 +1113,7 @@ li.item .notify_badge { | @@ -1113,7 +1113,7 @@ li.item .notify_badge { | ||
1113 | } | 1113 | } |
1114 | 1114 | ||
1115 | .comment-section { | 1115 | .comment-section { |
1116 | - max-height: 700px; | 1116 | + max-height: 500px; |
1117 | overflow-y: scroll; | 1117 | overflow-y: scroll; |
1118 | border-top-width: 1px; | 1118 | border-top-width: 1px; |
1119 | border-top-style: solid; | 1119 | border-top-style: solid; |
@@ -1568,6 +1568,7 @@ div.dataTables_wrapper div.dataTables_paginate { | @@ -1568,6 +1568,7 @@ div.dataTables_wrapper div.dataTables_paginate { | ||
1568 | overflow-y: auto; | 1568 | overflow-y: auto; |
1569 | opacity: 0; | 1569 | opacity: 0; |
1570 | visibility: hidden; | 1570 | visibility: hidden; |
1571 | + display: none; | ||
1571 | } | 1572 | } |
1572 | 1573 | ||
1573 | #participants { | 1574 | #participants { |
amadeus/static/js/main.js
@@ -11,7 +11,8 @@ $(function () { | @@ -11,7 +11,8 @@ $(function () { | ||
11 | }); | 11 | }); |
12 | 12 | ||
13 | $('.text_wysiwyg').summernote({ | 13 | $('.text_wysiwyg').summernote({ |
14 | - height: 200 | 14 | + height: 200, |
15 | + disableDragAndDrop: true, | ||
15 | }); | 16 | }); |
16 | 17 | ||
17 | $('[data-toggle="tooltip"]').tooltip({ | 18 | $('[data-toggle="tooltip"]').tooltip({ |
amadeus/static/js/socket.js
@@ -4,7 +4,7 @@ if (("Notification" in window)) { | @@ -4,7 +4,7 @@ if (("Notification" in window)) { | ||
4 | } | 4 | } |
5 | } | 5 | } |
6 | 6 | ||
7 | -socket = new WebSocket("ws://" + window.location.host + "/"); | 7 | +socket = new WebSocket("ws://" + window.location.host + ":8888/"); |
8 | 8 | ||
9 | socket.onmessage = function(e) { | 9 | socket.onmessage = function(e) { |
10 | content = JSON.parse(e.data); | 10 | content = JSON.parse(e.data); |
amadeus/static/summernote/summernote.js
@@ -4631,7 +4631,7 @@ | @@ -4631,7 +4631,7 @@ | ||
4631 | documentEventHandlers.onDrop = function (e) { | 4631 | documentEventHandlers.onDrop = function (e) { |
4632 | e.preventDefault(); | 4632 | e.preventDefault(); |
4633 | }; | 4633 | }; |
4634 | - $document.on('drop', documentEventHandlers.onDrop); | 4634 | + $dropzone.on('drop', documentEventHandlers.onDrop); |
4635 | } else { | 4635 | } else { |
4636 | this.attachDragAndDropEvent(); | 4636 | this.attachDragAndDropEvent(); |
4637 | } | 4637 | } |
chat/templates/chat/_form.html
@@ -66,6 +66,7 @@ | @@ -66,6 +66,7 @@ | ||
66 | $(function () { | 66 | $(function () { |
67 | $('.text_simple_wysiwyg').summernote({ | 67 | $('.text_simple_wysiwyg').summernote({ |
68 | dialogsInBody: true, | 68 | dialogsInBody: true, |
69 | + disableDragAndDrop: true, | ||
69 | height: 150, | 70 | height: 150, |
70 | toolbar: [ | 71 | toolbar: [ |
71 | // [groupName, [list of button]] | 72 | // [groupName, [list of button]] |
mural/templates/mural/_form.html
@@ -108,6 +108,7 @@ | @@ -108,6 +108,7 @@ | ||
108 | $(function () { | 108 | $(function () { |
109 | $('.text_simple_wysiwyg').summernote({ | 109 | $('.text_simple_wysiwyg').summernote({ |
110 | dialogsInBody: true, | 110 | dialogsInBody: true, |
111 | + disableDragAndDrop: true, | ||
111 | height: 150, | 112 | height: 150, |
112 | toolbar: [ | 113 | toolbar: [ |
113 | // [groupName, [list of button]] | 114 | // [groupName, [list of button]] |
mural/templates/mural/_form_comment.html
@@ -135,6 +135,7 @@ | @@ -135,6 +135,7 @@ | ||
135 | 135 | ||
136 | $('.text_simple_wysiwyg').summernote({ | 136 | $('.text_simple_wysiwyg').summernote({ |
137 | dialogsInBody: true, | 137 | dialogsInBody: true, |
138 | + disableDragAndDrop: true, | ||
138 | height: 150, | 139 | height: 150, |
139 | toolbar: [ | 140 | toolbar: [ |
140 | // [groupName, [list of button]] | 141 | // [groupName, [list of button]] |
@@ -0,0 +1,12 @@ | @@ -0,0 +1,12 @@ | ||
1 | +from django import forms | ||
2 | +from django.utils.translation import ugettext_lazy as _ | ||
3 | + | ||
4 | +from .models import News | ||
5 | + | ||
6 | +class NewsForm(forms.ModelForm): | ||
7 | + class Meta: | ||
8 | + model = News | ||
9 | + fields = ['title','image','content'] | ||
10 | + widgets = { | ||
11 | + 'content': forms.Textarea, | ||
12 | + } |
@@ -0,0 +1,21 @@ | @@ -0,0 +1,21 @@ | ||
1 | +from django.db import models | ||
2 | + | ||
3 | +# Create your models here. | ||
4 | +from autoslug.fields import AutoSlugField | ||
5 | + | ||
6 | +from django.utils.translation import ugettext_lazy as _ | ||
7 | +from django.core.exceptions import ValidationError | ||
8 | + | ||
9 | + | ||
10 | +def validate_img_extension(value): | ||
11 | + valid_formats = ['image/jpeg','image/x-citrix-jpeg','image/png','image/x-citrix-png','image/x-png'] | ||
12 | + | ||
13 | + if hasattr(value.file, 'content_type'): | ||
14 | + if not value.file.content_type in valid_formats: | ||
15 | + raise ValidationError(_('File not supported.')) | ||
16 | + | ||
17 | +class News(models.Model): | ||
18 | + title = models.CharField( _("Name"), unique = True,max_length= 200) | ||
19 | + slug = AutoSlugField(_("Slug"),populate_from='title',unique=True) | ||
20 | + image = models.ImageField(verbose_name = _('News Image'), upload_to = 'news/', validators = [validate_img_extension]) | ||
21 | + content = models.TextField(_('Description')) |
reports/forms.py
@@ -29,7 +29,6 @@ class ResourceAndTagForm(forms.Form): | @@ -29,7 +29,6 @@ class ResourceAndTagForm(forms.Form): | ||
29 | initial = kwargs['initial'] | 29 | initial = kwargs['initial'] |
30 | self.fields['resource'].choices = [(classes.__name__.lower(), classes.__name__.lower()) for classes in initial['class_name']] | 30 | self.fields['resource'].choices = [(classes.__name__.lower(), classes.__name__.lower()) for classes in initial['class_name']] |
31 | self.fields['tag'].choices = [(tag.id, tag.name) for tag in initial['tag']] | 31 | self.fields['tag'].choices = [(tag.id, tag.name) for tag in initial['tag']] |
32 | - | ||
33 | 32 | ||
34 | 33 | ||
35 | class CreateInteractionReportForm(forms.Form): | 34 | class CreateInteractionReportForm(forms.Form): |
reports/locale/pt_BR/LC_MESSAGES/django.po
@@ -8,7 +8,7 @@ msgid "" | @@ -8,7 +8,7 @@ msgid "" | ||
8 | msgstr "" | 8 | msgstr "" |
9 | "Project-Id-Version: PACKAGE VERSION\n" | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | "Report-Msgid-Bugs-To: \n" | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-04-02 23:42-0300\n" | 11 | +"POT-Creation-Date: 2017-04-06 16:30-0300\n" |
12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | "Language-Team: LANGUAGE <LL@li.org>\n" | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" |
@@ -26,39 +26,39 @@ msgstr "Tipo de recurso" | @@ -26,39 +26,39 @@ msgstr "Tipo de recurso" | ||
26 | msgid "Tag" | 26 | msgid "Tag" |
27 | msgstr "Tag" | 27 | msgstr "Tag" |
28 | 28 | ||
29 | -#: forms.py:36 | 29 | +#: forms.py:35 |
30 | msgid "Topics" | 30 | msgid "Topics" |
31 | msgstr "Tópicos" | 31 | msgstr "Tópicos" |
32 | 32 | ||
33 | -#: forms.py:37 templates/reports/view.html:58 | 33 | +#: forms.py:36 templates/reports/view.html:58 |
34 | msgid "Initial Date" | 34 | msgid "Initial Date" |
35 | msgstr "Data inicial" | 35 | msgstr "Data inicial" |
36 | 36 | ||
37 | -#: forms.py:38 | 37 | +#: forms.py:37 |
38 | msgid "Final Date" | 38 | msgid "Final Date" |
39 | msgstr "Data Final" | 39 | msgstr "Data Final" |
40 | 40 | ||
41 | -#: forms.py:40 | 41 | +#: forms.py:39 |
42 | msgid "From Mural" | 42 | msgid "From Mural" |
43 | msgstr "Mural da disciplina" | 43 | msgstr "Mural da disciplina" |
44 | 44 | ||
45 | -#: forms.py:41 | 45 | +#: forms.py:40 |
46 | msgid "Messages" | 46 | msgid "Messages" |
47 | msgstr "Mensagens" | 47 | msgstr "Mensagens" |
48 | 48 | ||
49 | -#: forms.py:52 views.py:134 views.py:205 | 49 | +#: forms.py:51 views.py:127 views.py:198 |
50 | msgid "All" | 50 | msgid "All" |
51 | msgstr "Todos" | 51 | msgstr "Todos" |
52 | 52 | ||
53 | -#: forms.py:61 | 53 | +#: forms.py:60 |
54 | msgid "The initial date can't be after the end one." | 54 | msgid "The initial date can't be after the end one." |
55 | msgstr "A data inicial não pode ser depois da final" | 55 | msgstr "A data inicial não pode ser depois da final" |
56 | 56 | ||
57 | -#: forms.py:66 | 57 | +#: forms.py:65 |
58 | msgid "This date should be right or after " | 58 | msgid "This date should be right or after " |
59 | msgstr "Esta data deve ser igual ou após" | 59 | msgstr "Esta data deve ser igual ou após" |
60 | 60 | ||
61 | -#: forms.py:72 | 61 | +#: forms.py:71 |
62 | msgid "This date should be right or before " | 62 | msgid "This date should be right or before " |
63 | msgstr "Esta data deve ser igual ou anterior à" | 63 | msgstr "Esta data deve ser igual ou anterior à" |
64 | 64 | ||
@@ -130,133 +130,167 @@ msgstr "Dados de interação (.csv)" | @@ -130,133 +130,167 @@ msgstr "Dados de interação (.csv)" | ||
130 | msgid "Interactions Data (.xls)" | 130 | msgid "Interactions Data (.xls)" |
131 | msgstr "Dados de interação (.xls)" | 131 | msgstr "Dados de interação (.xls)" |
132 | 132 | ||
133 | -#: views.py:71 | 133 | +#: views.py:60 |
134 | msgid "Report created successfully" | 134 | msgid "Report created successfully" |
135 | msgstr "Relatório criado com sucesso!" | 135 | msgstr "Relatório criado com sucesso!" |
136 | 136 | ||
137 | -#: views.py:209 | 137 | +#: views.py:202 |
138 | msgid "User" | 138 | msgid "User" |
139 | msgstr "" | 139 | msgstr "" |
140 | 140 | ||
141 | -#: views.py:229 | 141 | +#: views.py:222 |
142 | msgid "Number of help posts created by the user." | 142 | msgid "Number of help posts created by the user." |
143 | msgstr "Número de postagens de dúvidas criadas no mural da disciplina." | 143 | msgstr "Número de postagens de dúvidas criadas no mural da disciplina." |
144 | 144 | ||
145 | -#: views.py:235 | 145 | +#: views.py:228 |
146 | msgid "Amount of comments on help posts created by the student." | 146 | msgid "Amount of comments on help posts created by the student." |
147 | msgstr "" | 147 | msgstr "" |
148 | "Número de comentários criados para as próprias postagens de dúvidas no mural " | 148 | "Número de comentários criados para as próprias postagens de dúvidas no mural " |
149 | "da disciplina." | 149 | "da disciplina." |
150 | 150 | ||
151 | -#: views.py:240 | 151 | +#: views.py:233 |
152 | msgid "Amount of comments made by the student on teachers help posts." | 152 | msgid "Amount of comments made by the student on teachers help posts." |
153 | msgstr "" | 153 | msgstr "" |
154 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " | 154 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " |
155 | "pelo professor." | 155 | "pelo professor." |
156 | 156 | ||
157 | -#: views.py:244 | 157 | +#: views.py:237 |
158 | msgid "Amount of comments made by the student on other students help posts." | 158 | msgid "Amount of comments made by the student on other students help posts." |
159 | msgstr "" | 159 | msgstr "" |
160 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " | 160 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " |
161 | "por outros estudantes." | 161 | "por outros estudantes." |
162 | 162 | ||
163 | -#: views.py:255 | 163 | +#: views.py:248 |
164 | msgid "Number of help posts created by the user that the teacher commented on." | 164 | msgid "Number of help posts created by the user that the teacher commented on." |
165 | msgstr "" | 165 | msgstr "" |
166 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " | 166 | "Número de comentários às postagens de dúvidas no mural da disciplina criadas " |
167 | "por outros estudantes" | 167 | "por outros estudantes" |
168 | 168 | ||
169 | -#: views.py:263 | 169 | +#: views.py:256 |
170 | msgid "Number of help posts created by the user others students commented on." | 170 | msgid "Number of help posts created by the user others students commented on." |
171 | msgstr "" | 171 | msgstr "" |
172 | " Número de postagens de dúvidas criadas no mural da disciplina que foram " | 172 | " Número de postagens de dúvidas criadas no mural da disciplina que foram " |
173 | "comentadas por outros estudantes." | 173 | "comentadas por outros estudantes." |
174 | 174 | ||
175 | -#: views.py:266 | 175 | +#: views.py:259 |
176 | msgid "Number of student visualizations on the mural of the subject." | 176 | msgid "Number of student visualizations on the mural of the subject." |
177 | msgstr "Número de visualizações do mural da disciplina." | 177 | msgstr "Número de visualizações do mural da disciplina." |
178 | 178 | ||
179 | -#: views.py:278 | 179 | +#: views.py:271 |
180 | msgid "Number of access to mural between 6 a.m to 12a.m. ." | 180 | msgid "Number of access to mural between 6 a.m to 12a.m. ." |
181 | msgstr "" | 181 | msgstr "" |
182 | "Número de acessos ao ambiente virtual da disciplina no horário de 06h às 12h." | 182 | "Número de acessos ao ambiente virtual da disciplina no horário de 06h às 12h." |
183 | 183 | ||
184 | -#: views.py:282 | 184 | +#: views.py:275 |
185 | msgid "Number of access to mural between 0 p.m to 6p.m. ." | 185 | msgid "Number of access to mural between 0 p.m to 6p.m. ." |
186 | msgstr "" | 186 | msgstr "" |
187 | "Número de acessos ao ambiente virtual da disciplina no horário de 12h às 18h." | 187 | "Número de acessos ao ambiente virtual da disciplina no horário de 12h às 18h." |
188 | 188 | ||
189 | -#: views.py:285 | 189 | +#: views.py:278 |
190 | msgid "Number of access to mural between 6 p.m to 12p.m. ." | 190 | msgid "Number of access to mural between 6 p.m to 12p.m. ." |
191 | msgstr "" | 191 | msgstr "" |
192 | "Número de acessos ao ambiente virtual da disciplina no horário de 18h às 24h." | 192 | "Número de acessos ao ambiente virtual da disciplina no horário de 18h às 24h." |
193 | 193 | ||
194 | -#: views.py:289 | 194 | +#: views.py:282 |
195 | msgid "Number of access to mural between 0 a.m to 6a.m. ." | 195 | msgid "Number of access to mural between 0 a.m to 6a.m. ." |
196 | msgstr "" | 196 | msgstr "" |
197 | "Número de acessos ao ambiente virtual da disciplina no horário de 24h às 06h." | 197 | "Número de acessos ao ambiente virtual da disciplina no horário de 24h às 06h." |
198 | 198 | ||
199 | -#: views.py:294 | 199 | +#: views.py:287 |
200 | msgid "sunday" | 200 | msgid "sunday" |
201 | msgstr "domingo" | 201 | msgstr "domingo" |
202 | 202 | ||
203 | -#: views.py:294 | 203 | +#: views.py:287 |
204 | msgid "monday" | 204 | msgid "monday" |
205 | msgstr "segunda" | 205 | msgstr "segunda" |
206 | 206 | ||
207 | -#: views.py:294 | 207 | +#: views.py:287 |
208 | msgid "tuesday" | 208 | msgid "tuesday" |
209 | msgstr "terça-feira" | 209 | msgstr "terça-feira" |
210 | 210 | ||
211 | -#: views.py:294 | 211 | +#: views.py:287 |
212 | msgid "wednesday" | 212 | msgid "wednesday" |
213 | msgstr "quarta" | 213 | msgstr "quarta" |
214 | 214 | ||
215 | -#: views.py:294 | 215 | +#: views.py:287 |
216 | msgid "thursday" | 216 | msgid "thursday" |
217 | msgstr "quinta-feira" | 217 | msgstr "quinta-feira" |
218 | 218 | ||
219 | -#: views.py:295 | 219 | +#: views.py:288 |
220 | msgid "friday" | 220 | msgid "friday" |
221 | msgstr "sexta" | 221 | msgstr "sexta" |
222 | 222 | ||
223 | -#: views.py:295 | 223 | +#: views.py:288 |
224 | msgid "saturday" | 224 | msgid "saturday" |
225 | msgstr "sábado" | 225 | msgstr "sábado" |
226 | 226 | ||
227 | -#: views.py:299 views.py:302 | 227 | +#: views.py:292 views.py:295 |
228 | msgid "Number of access to the subject on " | 228 | msgid "Number of access to the subject on " |
229 | msgstr "Número de acessos ao assunto na(o) " | 229 | msgstr "Número de acessos ao assunto na(o) " |
230 | 230 | ||
231 | -#: views.py:305 | 231 | +#: views.py:298 |
232 | msgid "Number of distinct days the user access the subject. " | 232 | msgid "Number of distinct days the user access the subject. " |
233 | msgstr "Número de dias distintos que acessou o ambiente virtual da disciplina." | 233 | msgstr "Número de dias distintos que acessou o ambiente virtual da disciplina." |
234 | 234 | ||
235 | -#: views.py:306 | 235 | +#: views.py:299 |
236 | msgid "Class" | 236 | msgid "Class" |
237 | msgstr "Classe" | 237 | msgstr "Classe" |
238 | 238 | ||
239 | -#: views.py:307 | 239 | +#: views.py:299 views.py:300 |
240 | +msgid "Undefined" | ||
241 | +msgstr "Indefinido" | ||
242 | + | ||
243 | +#: views.py:300 | ||
240 | msgid "Performance" | 244 | msgid "Performance" |
241 | msgstr "Desempenho" | 245 | msgstr "Desempenho" |
242 | 246 | ||
243 | -#: views.py:419 | 247 | +#: views.py:448 views.py:498 |
248 | +msgid "PDF File" | ||
249 | +msgstr "" | ||
250 | + | ||
251 | +#: views.py:449 views.py:499 | ||
252 | +#, fuzzy | ||
253 | +#| msgid "Topics" | ||
254 | +msgid "Topic Goals" | ||
255 | +msgstr "Tópicos" | ||
256 | + | ||
257 | +#: views.py:450 views.py:500 | ||
258 | +msgid "Link to Website" | ||
259 | +msgstr "" | ||
260 | + | ||
261 | +#: views.py:451 views.py:501 | ||
262 | +msgid "File Link" | ||
263 | +msgstr "" | ||
264 | + | ||
265 | +#: views.py:452 views.py:502 | ||
266 | +msgid "Web Conference" | ||
267 | +msgstr "" | ||
268 | + | ||
269 | +#: views.py:453 views.py:503 | ||
270 | +msgid "YouTube Video" | ||
271 | +msgstr "" | ||
272 | + | ||
273 | +#: views.py:454 views.py:504 | ||
274 | +msgid "WebPage" | ||
275 | +msgstr "" | ||
276 | + | ||
277 | +#: views.py:456 views.py:463 | ||
244 | msgid "number of visualizations of " | 278 | msgid "number of visualizations of " |
245 | msgstr "Número de visualizações do(e) " | 279 | msgstr "Número de visualizações do(e) " |
246 | 280 | ||
247 | -#: views.py:419 views.py:420 views.py:421 views.py:424 | 281 | +#: views.py:456 views.py:457 views.py:458 views.py:461 |
248 | msgid " with tag " | 282 | msgid " with tag " |
249 | msgstr " com a tag " | 283 | msgstr " com a tag " |
250 | 284 | ||
251 | -#: views.py:420 | 285 | +#: views.py:457 views.py:464 |
252 | msgid "number of visualizations of distintic " | 286 | msgid "number of visualizations of distintic " |
253 | msgstr "Número de visualizações dos distintos " | 287 | msgstr "Número de visualizações dos distintos " |
254 | 288 | ||
255 | -#: views.py:421 | 289 | +#: views.py:458 views.py:465 |
256 | msgid "distintic days " | 290 | msgid "distintic days " |
257 | msgstr "número de dias distintos " | 291 | msgstr "número de dias distintos " |
258 | 292 | ||
259 | -#: views.py:424 | 293 | +#: views.py:461 views.py:468 |
260 | msgid "hours viewed of " | 294 | msgid "hours viewed of " |
261 | msgstr "quantidade de horas vistas " | 295 | msgstr "quantidade de horas vistas " |
262 | 296 |
reports/views.py
@@ -23,6 +23,7 @@ import pandas as pd | @@ -23,6 +23,7 @@ import pandas as pd | ||
23 | import math | 23 | import math |
24 | from io import BytesIO | 24 | from io import BytesIO |
25 | import os | 25 | import os |
26 | +import copy | ||
26 | 27 | ||
27 | class ReportView(LoginRequiredMixin, generic.FormView): | 28 | class ReportView(LoginRequiredMixin, generic.FormView): |
28 | template_name = "reports/create.html" | 29 | template_name = "reports/create.html" |
@@ -46,19 +47,7 @@ class ReportView(LoginRequiredMixin, generic.FormView): | @@ -46,19 +47,7 @@ class ReportView(LoginRequiredMixin, generic.FormView): | ||
46 | context = super(ReportView, self).get_context_data(**kwargs) | 47 | context = super(ReportView, self).get_context_data(**kwargs) |
47 | subject = Subject.objects.get(id=self.request.GET['subject_id']) | 48 | subject = Subject.objects.get(id=self.request.GET['subject_id']) |
48 | 49 | ||
49 | - context['subject'] = subject | ||
50 | - | ||
51 | - topics = subject.topic_subject.all() | ||
52 | - #get all resources associated with topics | ||
53 | - tags = [] | ||
54 | - for topic in topics: | ||
55 | - resources_set = topic.resource_topic.all() | ||
56 | - for resource in resources_set: | ||
57 | - for tag in resource.tags.all(): | ||
58 | - tags.append(tag) | ||
59 | - | ||
60 | - | ||
61 | - classes = Resource.__subclasses__() | 50 | + context['subject'] = subject |
62 | 51 | ||
63 | #set formset | 52 | #set formset |
64 | resourceTagFormSet = formset_factory(ResourceAndTagForm, formset=BaseResourceAndTagFormset) | 53 | resourceTagFormSet = formset_factory(ResourceAndTagForm, formset=BaseResourceAndTagFormset) |
@@ -104,6 +93,10 @@ class ReportView(LoginRequiredMixin, generic.FormView): | @@ -104,6 +93,10 @@ class ReportView(LoginRequiredMixin, generic.FormView): | ||
104 | for tag in resource.tags.all(): | 93 | for tag in resource.tags.all(): |
105 | tags.append(tag) | 94 | tags.append(tag) |
106 | 95 | ||
96 | + | ||
97 | + t = Tag(name=" ") | ||
98 | + t.id = -1 #so I know he choose empyt one | ||
99 | + tags.append(t) | ||
107 | classes = Resource.__subclasses__() | 100 | classes = Resource.__subclasses__() |
108 | amount_of_forms = self.request.POST['form-TOTAL_FORMS'] | 101 | amount_of_forms = self.request.POST['form-TOTAL_FORMS'] |
109 | initial_datum = {'class_name': classes , 'tag': tags} | 102 | initial_datum = {'class_name': classes , 'tag': tags} |
@@ -211,7 +204,7 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | @@ -211,7 +204,7 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | ||
211 | #I use this so the system can gather data up to end_date 11h59 p.m. | 204 | #I use this so the system can gather data up to end_date 11h59 p.m. |
212 | end_date = end_date + timedelta(days=1) | 205 | end_date = end_date + timedelta(days=1) |
213 | 206 | ||
214 | - | 207 | + self.used_tags = copy.deepcopy(tags_id) #so I can check whether we are dealing with multiple or single tags (empty option) |
215 | #For each student in the subject | 208 | #For each student in the subject |
216 | for student in students: | 209 | for student in students: |
217 | data[student.id] = [] | 210 | data[student.id] = [] |
@@ -303,8 +296,8 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | @@ -303,8 +296,8 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | ||
303 | distinct_days += 1 | 296 | distinct_days += 1 |
304 | 297 | ||
305 | interactions[_('Number of distinct days the user access the subject. ')] = distinct_days | 298 | interactions[_('Number of distinct days the user access the subject. ')] = distinct_days |
306 | - interactions[_("Class")] = "" | ||
307 | - interactions[_("Performance")] = "" | 299 | + interactions[_("Class")] = _("Undefined") |
300 | + interactions[_("Performance")] = _("Undefined") | ||
308 | for value in interactions.values(): | 301 | for value in interactions.values(): |
309 | data[student.id].append(value) | 302 | data[student.id].append(value) |
310 | 303 | ||
@@ -316,13 +309,47 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | @@ -316,13 +309,47 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | ||
316 | def get_resources_and_tags_data(self, resources_types, tags, student, subject, topics, init_date, end_date): | 309 | def get_resources_and_tags_data(self, resources_types, tags, student, subject, topics, init_date, end_date): |
317 | data = OrderedDict() | 310 | data = OrderedDict() |
318 | 311 | ||
312 | + new_tags = [] #tags will be replaced by this variable | ||
319 | for i in range(len(resources_types)): | 313 | for i in range(len(resources_types)): |
320 | - | 314 | + |
315 | + if tags[i] == "-1": #it means I should select all of tags available for this kind of resource | ||
316 | + new_tags = set() | ||
317 | + if not isinstance(topics,Topic): | ||
318 | + topics = subject.topic_subject.all() | ||
319 | + for topic in topics: | ||
320 | + resource_set = Resource.objects.select_related(resources_types[i].lower()).filter(topic = topic) | ||
321 | + | ||
322 | + for resource in resource_set: | ||
323 | + if resource._my_subclass == resources_types[i].lower(): | ||
324 | + for tag in resource.tags.all(): | ||
325 | + if tag.name != "": | ||
326 | + new_tags.add(tag) | ||
327 | + else: | ||
328 | + topics = topics | ||
329 | + resource_set = Resource.objects.select_related(resources_types[i].lower()).filter(topic = topics) | ||
330 | + | ||
331 | + for resource in resource_set: | ||
332 | + if resource._my_subclass == resources_types[i].lower(): | ||
333 | + for tag in resource.tags.all(): | ||
334 | + if tag.name != "": | ||
335 | + new_tags.add(tag) | ||
336 | + data = {} | ||
337 | + | ||
338 | + | ||
339 | + new_tags = [tag.id for tag in new_tags] | ||
340 | + tags[i] = new_tags | ||
341 | + for i in range(len(resources_types)): | ||
342 | + original_tags = copy.deepcopy(self.used_tags) #effectiving copy | ||
321 | if isinstance(topics,Topic): | 343 | if isinstance(topics,Topic): |
322 | - resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = tags, topic=topics) | 344 | + if type(tags[i]) == type(list()): |
345 | + resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = tags[i], topic=topics) | ||
346 | + else: | ||
347 | + resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = [tags[i]], topic=topics) | ||
323 | else: | 348 | else: |
324 | - resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = tags, topic__in=topics) | ||
325 | - | 349 | + if type(tags[i]) == type(list()): |
350 | + resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = tags[i], topic__in=topics) | ||
351 | + else: | ||
352 | + resources = Resource.objects.select_related(resources_types[i].lower()).filter(tags__in = [tags[i]], topic__in=topics) | ||
326 | distinct_resources = 0 | 353 | distinct_resources = 0 |
327 | total_count = 0 | 354 | total_count = 0 |
328 | 355 | ||
@@ -425,15 +452,20 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | @@ -425,15 +452,20 @@ class ViewReportView(LoginRequiredMixin, generic.TemplateView): | ||
425 | mapping['webconference'] = str(_('Web Conference')) | 452 | mapping['webconference'] = str(_('Web Conference')) |
426 | mapping['ytvideo'] = str(_('YouTube Video')) | 453 | mapping['ytvideo'] = str(_('YouTube Video')) |
427 | mapping['webpage'] = str(_('WebPage')) | 454 | mapping['webpage'] = str(_('WebPage')) |
428 | - data[str(_("number of visualizations of ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = total_count | ||
429 | - data[str(_("number of visualizations of distintic ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = distinct_resources | ||
430 | - data[str(_("distintic days ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = distinct_days | ||
431 | - | ||
432 | - if resources_types[i].lower() in ["ytvideo", "webconference"]: | ||
433 | - data[str(_("hours viewed of ")) + str(resources_types[i]) + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = hours_viewed | 455 | + if original_tags[i] != "-1": |
456 | + data[str(_("number of visualizations of ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = total_count | ||
457 | + data[str(_("number of visualizations of distintic ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = distinct_resources | ||
458 | + data[str(_("distintic days ")) + mapping[str(resources_types[i])] + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = distinct_days | ||
459 | + | ||
460 | + if resources_types[i].lower() in ["ytvideo", "webconference"]: | ||
461 | + data[str(_("hours viewed of ")) + str(resources_types[i]) + str(_(" with tag ")) + Tag.objects.get(id=int(tags[i])).name] = hours_viewed | ||
462 | + else: | ||
463 | + data[str(_("number of visualizations of ")) + mapping[str(resources_types[i])] ] = total_count | ||
464 | + data[str(_("number of visualizations of distintic ")) + mapping[str(resources_types[i])] ] = distinct_resources | ||
465 | + data[str(_("distintic days ")) + mapping[str(resources_types[i])]] = distinct_days | ||
434 | 466 | ||
435 | - """data["distinct" + str(resources[i]) + " with tag " + Tag.objects.get(id=int(tags[i])).name] = Log.objects.filter(action="view", resource=resources[i].lower(), | ||
436 | - user_id = student.id, context__contains = {'subject_id': subject.id}).distinct().count()""" | 467 | + if resources_types[i].lower() in ["ytvideo", "webconference"]: |
468 | + data[str(_("hours viewed of ")) + str(resources_types[i]) ] = hours_viewed | ||
437 | 469 | ||
438 | return data | 470 | return data |
439 | 471 | ||
@@ -504,7 +536,10 @@ def get_tags(request): | @@ -504,7 +536,10 @@ def get_tags(request): | ||
504 | 536 | ||
505 | #adding empty tag for the purpose of giving the user this option for adicional behavior | 537 | #adding empty tag for the purpose of giving the user this option for adicional behavior |
506 | tags = list(tags) | 538 | tags = list(tags) |
507 | - tags.append(Tag(name=" ")) | 539 | + #creating empty tag |
540 | + t = Tag(name=" ") | ||
541 | + t.id = -1 #so I know he choose empyt one | ||
542 | + tags.append(t) | ||
508 | data['tags'] = [ {'id':tag.id, 'name':tag.name} for tag in tags] | 543 | data['tags'] = [ {'id':tag.id, 'name':tag.name} for tag in tags] |
509 | return JsonResponse(data) | 544 | return JsonResponse(data) |
510 | 545 |
subjects/templates/subjects/view.html
@@ -196,7 +196,7 @@ | @@ -196,7 +196,7 @@ | ||
196 | list.animate({ | 196 | list.animate({ |
197 | right : '-180px', | 197 | right : '-180px', |
198 | opacity: 0 | 198 | opacity: 0 |
199 | - }, 500).css({visibility: 'hidden'}); | 199 | + }, 500).css({display: "none", visibility: 'hidden'}); |
200 | 200 | ||
201 | $this.removeClass('open'); | 201 | $this.removeClass('open'); |
202 | } else { | 202 | } else { |
@@ -206,8 +206,12 @@ | @@ -206,8 +206,12 @@ | ||
206 | 206 | ||
207 | list.animate({ | 207 | list.animate({ |
208 | right : 0, | 208 | right : 0, |
209 | - opacity: 1 | 209 | + opacity: 1, |
210 | }, 500).css({visibility: 'visible'}); | 210 | }, 500).css({visibility: 'visible'}); |
211 | + | ||
212 | + setTimeout(function () { | ||
213 | + list.fadeIn(); | ||
214 | + }, 500); | ||
211 | } | 215 | } |
212 | }); | 216 | }); |
213 | }); | 217 | }); |
users/locale/pt_BR/LC_MESSAGES/django.po
@@ -8,7 +8,7 @@ msgid "" | @@ -8,7 +8,7 @@ msgid "" | ||
8 | msgstr "" | 8 | msgstr "" |
9 | "Project-Id-Version: PACKAGE VERSION\n" | 9 | "Project-Id-Version: PACKAGE VERSION\n" |
10 | "Report-Msgid-Bugs-To: \n" | 10 | "Report-Msgid-Bugs-To: \n" |
11 | -"POT-Creation-Date: 2017-03-21 22:47-0300\n" | 11 | +"POT-Creation-Date: 2017-04-04 23:45-0300\n" |
12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" | 12 | "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" |
13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" | 13 | "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" |
14 | "Language-Team: LANGUAGE <LL@li.org>\n" | 14 | "Language-Team: LANGUAGE <LL@li.org>\n" |
@@ -18,57 +18,57 @@ msgstr "" | @@ -18,57 +18,57 @@ msgstr "" | ||
18 | "Content-Transfer-Encoding: 8bit\n" | 18 | "Content-Transfer-Encoding: 8bit\n" |
19 | "Plural-Forms: nplurals=2; plural=(n > 1);\n" | 19 | "Plural-Forms: nplurals=2; plural=(n > 1);\n" |
20 | 20 | ||
21 | -#: .\forms.py:25 .\forms.py:30 .\forms.py:189 | 21 | +#: .\forms.py:28 .\forms.py:33 .\forms.py:276 |
22 | msgid "You must insert an email address" | 22 | msgid "You must insert an email address" |
23 | msgstr "Você deve inserir um endereço de email" | 23 | msgstr "Você deve inserir um endereço de email" |
24 | 24 | ||
25 | -#: .\forms.py:40 | 25 | +#: .\forms.py:43 |
26 | msgid "The image is too large. It should have less than 2MB." | 26 | msgid "The image is too large. It should have less than 2MB." |
27 | msgstr "A imagem é muito grande. Ela deve conter menos de 2MB." | 27 | msgstr "A imagem é muito grande. Ela deve conter menos de 2MB." |
28 | 28 | ||
29 | -#: .\forms.py:51 | 29 | +#: .\forms.py:54 |
30 | msgid "The confirmation password is incorrect." | 30 | msgid "The confirmation password is incorrect." |
31 | msgstr "A confirmação de senha está incorreta." | 31 | msgstr "A confirmação de senha está incorreta." |
32 | 32 | ||
33 | -#: .\forms.py:58 .\forms.py:114 .\templates\users\login.html:52 | 33 | +#: .\forms.py:61 .\forms.py:173 .\templates\users\login.html:52 |
34 | msgid "Password" | 34 | msgid "Password" |
35 | msgstr "Senha" | 35 | msgstr "Senha" |
36 | 36 | ||
37 | -#: .\forms.py:59 .\forms.py:115 .\forms.py:146 .\forms.py:202 | 37 | +#: .\forms.py:62 .\forms.py:174 .\forms.py:233 .\forms.py:289 |
38 | msgid "Confirm Password" | 38 | msgid "Confirm Password" |
39 | msgstr "Confirmação de Senha" | 39 | msgstr "Confirmação de Senha" |
40 | 40 | ||
41 | -#: .\forms.py:76 .\forms.py:180 .\templates\users\list.html:56 | 41 | +#: .\forms.py:108 .\forms.py:267 .\templates\users\list.html:56 |
42 | #: .\templates\users\login.html:47 .\templates\users\search.html:47 | 42 | #: .\templates\users\login.html:47 .\templates\users\search.html:47 |
43 | msgid "Email" | 43 | msgid "Email" |
44 | msgstr "Email" | 44 | msgstr "Email" |
45 | 45 | ||
46 | -#: .\forms.py:77 .\models.py:27 .\templates\users\list.html:55 | 46 | +#: .\forms.py:109 .\models.py:27 .\templates\users\list.html:55 |
47 | #: .\templates\users\search.html:46 | 47 | #: .\templates\users\search.html:46 |
48 | msgid "Name" | 48 | msgid "Name" |
49 | msgstr "Nome" | 49 | msgstr "Nome" |
50 | 50 | ||
51 | -#: .\forms.py:78 .\models.py:28 | 51 | +#: .\forms.py:110 .\models.py:28 |
52 | msgid "Last Name" | 52 | msgid "Last Name" |
53 | msgstr "Sobrenome" | 53 | msgstr "Sobrenome" |
54 | 54 | ||
55 | -#: .\forms.py:79 .\models.py:29 | 55 | +#: .\forms.py:111 .\models.py:29 |
56 | msgid "Social Name" | 56 | msgid "Social Name" |
57 | msgstr "Nome Social" | 57 | msgstr "Nome Social" |
58 | 58 | ||
59 | -#: .\forms.py:145 .\forms.py:201 | 59 | +#: .\forms.py:232 .\forms.py:288 |
60 | msgid "New Password" | 60 | msgid "New Password" |
61 | msgstr "Nova Senha" | 61 | msgstr "Nova Senha" |
62 | 62 | ||
63 | -#: .\forms.py:152 | 63 | +#: .\forms.py:239 |
64 | msgid "The value inputed does not match with your actual password." | 64 | msgid "The value inputed does not match with your actual password." |
65 | msgstr "O valor inserido não corresponde à sua senha atual." | 65 | msgstr "O valor inserido não corresponde à sua senha atual." |
66 | 66 | ||
67 | -#: .\forms.py:173 | 67 | +#: .\forms.py:260 |
68 | msgid "Actual Password" | 68 | msgid "Actual Password" |
69 | msgstr "Senha Atual" | 69 | msgstr "Senha Atual" |
70 | 70 | ||
71 | -#: .\forms.py:194 | 71 | +#: .\forms.py:281 |
72 | msgid "You must insert a valid email address" | 72 | msgid "You must insert a valid email address" |
73 | msgstr "Você deve inserir um endereço de email válido" | 73 | msgstr "Você deve inserir um endereço de email válido" |
74 | 74 | ||
@@ -149,44 +149,36 @@ msgstr "Sim" | @@ -149,44 +149,36 @@ msgstr "Sim" | ||
149 | msgid "Is not an admin" | 149 | msgid "Is not an admin" |
150 | msgstr "Não é administrador" | 150 | msgstr "Não é administrador" |
151 | 151 | ||
152 | -#: .\templates\users\_form.html:16 .\templates\users\register.html:52 | 152 | +#: .\templates\users\_form.html:16 .\templates\users\register.html:53 |
153 | msgid "Choose your photo..." | 153 | msgid "Choose your photo..." |
154 | msgstr "Escolha sua foto..." | 154 | msgstr "Escolha sua foto..." |
155 | 155 | ||
156 | -#: .\templates\users\_form.html:62 | 156 | +#: .\templates\users\_form.html:70 |
157 | msgid "Save" | 157 | msgid "Save" |
158 | msgstr "Salvar" | 158 | msgstr "Salvar" |
159 | 159 | ||
160 | -#: .\templates\users\_form.html:65 .\templates\users\delete.html:27 | ||
161 | -#: .\templates\users\delete_account.html:27 | 160 | +#: .\templates\users\_form.html:73 .\templates\users\modal_crop.html:24 |
162 | msgid "Cancel" | 161 | msgid "Cancel" |
163 | msgstr "Cancelar" | 162 | msgstr "Cancelar" |
164 | 163 | ||
165 | -#: .\templates\users\delete.html:9 | ||
166 | -msgid "Delete User" | ||
167 | -msgstr "Deletar Usuário" | ||
168 | - | ||
169 | -#: .\templates\users\delete.html:19 | 164 | +#: .\templates\users\delete.html:12 |
170 | msgid "Are you sure you want delete the user" | 165 | msgid "Are you sure you want delete the user" |
171 | msgstr "Tem certeza que deseja deletar o usuário" | 166 | msgstr "Tem certeza que deseja deletar o usuário" |
172 | 167 | ||
173 | -#: .\templates\users\delete.html:20 .\templates\users\delete_account.html:20 | ||
174 | -msgid "All data will be lost and havent how recover it." | ||
175 | -msgstr "Toda informação será perdida e não poderá ser recuperada" | 168 | +#: .\templates\users\delete.html:18 .\templates\users\delete_account.html:18 |
169 | +msgid "Close" | ||
170 | +msgstr "" | ||
176 | 171 | ||
177 | -#: .\templates\users\delete.html:24 .\templates\users\delete_account.html:24 | ||
178 | -msgid "Remove" | 172 | +#: .\templates\users\delete.html:19 .\templates\users\delete_account.html:19 |
173 | +#: .\templates\users\list.html:66 .\templates\users\search.html:57 | ||
174 | +msgid "Delete" | ||
179 | msgstr "Deletar" | 175 | msgstr "Deletar" |
180 | 176 | ||
181 | -#: .\templates\users\delete_account.html:9 | ||
182 | -msgid "Remove Account" | ||
183 | -msgstr "Remover Conta" | ||
184 | - | ||
185 | -#: .\templates\users\delete_account.html:19 | 177 | +#: .\templates\users\delete_account.html:12 |
186 | msgid "Are you sure you want delete your account?" | 178 | msgid "Are you sure you want delete your account?" |
187 | msgstr "Tem certeza que deseja deletar sua conta?" | 179 | msgstr "Tem certeza que deseja deletar sua conta?" |
188 | 180 | ||
189 | -#: .\templates\users\forgot_password.html:39 .\views.py:380 | 181 | +#: .\templates\users\forgot_password.html:39 .\views.py:389 |
190 | msgid "Forgot Password" | 182 | msgid "Forgot Password" |
191 | msgstr "Esqueceu Senha" | 183 | msgstr "Esqueceu Senha" |
192 | 184 | ||
@@ -203,7 +195,7 @@ msgid "Recover" | @@ -203,7 +195,7 @@ msgid "Recover" | ||
203 | msgstr "Recuperar" | 195 | msgstr "Recuperar" |
204 | 196 | ||
205 | #: .\templates\users\forgot_password.html:75 | 197 | #: .\templates\users\forgot_password.html:75 |
206 | -#: .\templates\users\new_password.html:80 .\templates\users\register.html:91 | 198 | +#: .\templates\users\new_password.html:80 .\templates\users\register.html:92 |
207 | msgid "Back" | 199 | msgid "Back" |
208 | msgstr "Voltar" | 200 | msgstr "Voltar" |
209 | 201 | ||
@@ -224,10 +216,6 @@ msgstr "Não Informado" | @@ -224,10 +216,6 @@ msgstr "Não Informado" | ||
224 | msgid "Edit" | 216 | msgid "Edit" |
225 | msgstr "Editar" | 217 | msgstr "Editar" |
226 | 218 | ||
227 | -#: .\templates\users\list.html:66 .\templates\users\search.html:57 | ||
228 | -msgid "Delete" | ||
229 | -msgstr "Deletar" | ||
230 | - | ||
231 | #: .\templates\users\list.html:76 .\templates\users\search.html:67 | 219 | #: .\templates\users\list.html:76 .\templates\users\search.html:67 |
232 | msgid "No users found" | 220 | msgid "No users found" |
233 | msgstr "Nenhum usuário encontrado" | 221 | msgstr "Nenhum usuário encontrado" |
@@ -240,7 +228,7 @@ msgstr "Entre com a sua conta para continuar" | @@ -240,7 +228,7 @@ msgstr "Entre com a sua conta para continuar" | ||
240 | msgid "Log in" | 228 | msgid "Log in" |
241 | msgstr "Entrar" | 229 | msgstr "Entrar" |
242 | 230 | ||
243 | -#: .\templates\users\login.html:66 .\views.py:354 | 231 | +#: .\templates\users\login.html:66 .\views.py:363 |
244 | msgid "Sign Up" | 232 | msgid "Sign Up" |
245 | msgstr "Cadastrar" | 233 | msgstr "Cadastrar" |
246 | 234 | ||
@@ -248,6 +236,14 @@ msgstr "Cadastrar" | @@ -248,6 +236,14 @@ msgstr "Cadastrar" | ||
248 | msgid "Forgot your password?" | 236 | msgid "Forgot your password?" |
249 | msgstr "Esqueceu sua senha?" | 237 | msgstr "Esqueceu sua senha?" |
250 | 238 | ||
239 | +#: .\templates\users\modal_crop.html:10 | ||
240 | +msgid "Image selection" | ||
241 | +msgstr "Seleção de Imagem" | ||
242 | + | ||
243 | +#: .\templates\users\modal_crop.html:25 | ||
244 | +msgid "Save Image" | ||
245 | +msgstr "Salvar Imagem" | ||
246 | + | ||
251 | #: .\templates\users\new_password.html:39 | 247 | #: .\templates\users\new_password.html:39 |
252 | msgid "Set new password" | 248 | msgid "Set new password" |
253 | msgstr "Digite a nova senha" | 249 | msgstr "Digite a nova senha" |
@@ -272,11 +268,11 @@ msgstr "Professor em" | @@ -272,11 +268,11 @@ msgstr "Professor em" | ||
272 | msgid "Student in" | 268 | msgid "Student in" |
273 | msgstr "Estudante em" | 269 | msgstr "Estudante em" |
274 | 270 | ||
275 | -#: .\templates\users\register.html:39 | 271 | +#: .\templates\users\register.html:40 |
276 | msgid "User Register" | 272 | msgid "User Register" |
277 | msgstr "Cadastro de Usuário" | 273 | msgstr "Cadastro de Usuário" |
278 | 274 | ||
279 | -#: .\templates\users\register.html:88 | 275 | +#: .\templates\users\register.html:89 |
280 | msgid "Register" | 276 | msgid "Register" |
281 | msgstr "Cadastrar" | 277 | msgstr "Cadastrar" |
282 | 278 | ||
@@ -292,37 +288,37 @@ msgstr "Não é professor" | @@ -292,37 +288,37 @@ msgstr "Não é professor" | ||
292 | msgid "Is not a student" | 288 | msgid "Is not a student" |
293 | msgstr "Não é estudante" | 289 | msgstr "Não é estudante" |
294 | 290 | ||
295 | -#: .\views.py:55 | 291 | +#: .\views.py:60 |
296 | msgid "Manage Users" | 292 | msgid "Manage Users" |
297 | msgstr "Gerenciar Usuários" | 293 | msgstr "Gerenciar Usuários" |
298 | 294 | ||
299 | -#: .\views.py:85 | 295 | +#: .\views.py:90 |
300 | msgid "Search Users" | 296 | msgid "Search Users" |
301 | msgstr "Pesquisar Usuário" | 297 | msgstr "Pesquisar Usuário" |
302 | 298 | ||
303 | -#: .\views.py:108 | 299 | +#: .\views.py:113 |
304 | #, python-format | 300 | #, python-format |
305 | msgid "User \"%s\" created successfully" | 301 | msgid "User \"%s\" created successfully" |
306 | msgstr "Usuário \"%s\" criado com sucesso" | 302 | msgstr "Usuário \"%s\" criado com sucesso" |
307 | 303 | ||
308 | -#: .\views.py:122 | 304 | +#: .\views.py:127 |
309 | msgid "Add User" | 305 | msgid "Add User" |
310 | msgstr "Cadastrar Usuário" | 306 | msgstr "Cadastrar Usuário" |
311 | 307 | ||
312 | -#: .\views.py:156 | 308 | +#: .\views.py:161 |
313 | #, python-format | 309 | #, python-format |
314 | msgid "User \"%s\" updated successfully" | 310 | msgid "User \"%s\" updated successfully" |
315 | msgstr "Usuário \"%s\" atualizado com sucesso" | 311 | msgstr "Usuário \"%s\" atualizado com sucesso" |
316 | 312 | ||
317 | -#: .\views.py:170 | 313 | +#: .\views.py:175 |
318 | msgid "Update User" | 314 | msgid "Update User" |
319 | msgstr "Atualizar Usuário" | 315 | msgstr "Atualizar Usuário" |
320 | 316 | ||
321 | -#: .\views.py:225 | 317 | +#: .\views.py:232 |
322 | msgid "User removed successfully!" | 318 | msgid "User removed successfully!" |
323 | msgstr "Usuário removido com sucesso!" | 319 | msgstr "Usuário removido com sucesso!" |
324 | 320 | ||
325 | -#: .\views.py:226 | 321 | +#: .\views.py:233 |
326 | msgid "" | 322 | msgid "" |
327 | "Could not remove the account. The user is attach to one or more functions " | 323 | "Could not remove the account. The user is attach to one or more functions " |
328 | "(administrator, coordinator, professor ou student) in the system." | 324 | "(administrator, coordinator, professor ou student) in the system." |
@@ -330,39 +326,39 @@ msgstr "" | @@ -330,39 +326,39 @@ msgstr "" | ||
330 | "Não é possível deletar a conta. O usuário está vinculado com uma ou mais " | 326 | "Não é possível deletar a conta. O usuário está vinculado com uma ou mais " |
331 | "funções (administrador, coordenador, professor ou estudante) no sistema." | 327 | "funções (administrador, coordenador, professor ou estudante) no sistema." |
332 | 328 | ||
333 | -#: .\views.py:249 | 329 | +#: .\views.py:257 |
334 | msgid "Delete Account" | 330 | msgid "Delete Account" |
335 | msgstr "Remover Conta" | 331 | msgstr "Remover Conta" |
336 | 332 | ||
337 | -#: .\views.py:292 | 333 | +#: .\views.py:301 |
338 | msgid "Password changed successfully!" | 334 | msgid "Password changed successfully!" |
339 | msgstr "Senha alterada com sucesso!" | 335 | msgstr "Senha alterada com sucesso!" |
340 | 336 | ||
341 | -#: .\views.py:298 | 337 | +#: .\views.py:307 |
342 | msgid "Change Password" | 338 | msgid "Change Password" |
343 | msgstr "Alterar Senha" | 339 | msgstr "Alterar Senha" |
344 | 340 | ||
345 | -#: .\views.py:316 | 341 | +#: .\views.py:325 |
346 | msgid "Profile" | 342 | msgid "Profile" |
347 | msgstr "Perfil" | 343 | msgstr "Perfil" |
348 | 344 | ||
349 | -#: .\views.py:335 | 345 | +#: .\views.py:344 |
350 | msgid "Update Profile" | 346 | msgid "Update Profile" |
351 | msgstr "Atualizar Perfil" | 347 | msgstr "Atualizar Perfil" |
352 | 348 | ||
353 | -#: .\views.py:341 | 349 | +#: .\views.py:350 |
354 | msgid "Profile edited successfully!" | 350 | msgid "Profile edited successfully!" |
355 | msgstr "Perfil editado com sucesso!" | 351 | msgstr "Perfil editado com sucesso!" |
356 | 352 | ||
357 | -#: .\views.py:361 | 353 | +#: .\views.py:370 |
358 | msgid "User successfully registered!" | 354 | msgid "User successfully registered!" |
359 | msgstr "Usuário cadastrado com sucesso!" | 355 | msgstr "Usuário cadastrado com sucesso!" |
360 | 356 | ||
361 | -#: .\views.py:399 | 357 | +#: .\views.py:408 |
362 | msgid "Recover Password" | 358 | msgid "Recover Password" |
363 | msgstr "Recuperar Senha" | 359 | msgstr "Recuperar Senha" |
364 | 360 | ||
365 | -#: .\views.py:435 | 361 | +#: .\views.py:444 |
366 | msgid "" | 362 | msgid "" |
367 | "Soon you'll receive an email with instructions to set your new password. If " | 363 | "Soon you'll receive an email with instructions to set your new password. If " |
368 | "you don't receive it in 24 hours, please check your spam box." | 364 | "you don't receive it in 24 hours, please check your spam box." |
@@ -370,38 +366,50 @@ msgstr "" | @@ -370,38 +366,50 @@ msgstr "" | ||
370 | "Em breve você receberá um email com instruções para cadastrar sua nova " | 366 | "Em breve você receberá um email com instruções para cadastrar sua nova " |
371 | "senha. Se você não recebê-lo em 24 hhoras, por favor olhe sua caixa de spam." | 367 | "senha. Se você não recebê-lo em 24 hhoras, por favor olhe sua caixa de spam." |
372 | 368 | ||
373 | -#: .\views.py:438 | 369 | +#: .\views.py:447 |
374 | msgid "No user is associated with this email address" | 370 | msgid "No user is associated with this email address" |
375 | msgstr "Nenhum usuário associado com esse endereço de email." | 371 | msgstr "Nenhum usuário associado com esse endereço de email." |
376 | 372 | ||
377 | -#: .\views.py:451 | 373 | +#: .\views.py:460 |
378 | msgid "Reset Password" | 374 | msgid "Reset Password" |
379 | msgstr "Recuperar Senha" | 375 | msgstr "Recuperar Senha" |
380 | 376 | ||
381 | -#: .\views.py:473 | 377 | +#: .\views.py:482 |
382 | msgid "Password reset successfully." | 378 | msgid "Password reset successfully." |
383 | msgstr "Senha alterada com sucesso!" | 379 | msgstr "Senha alterada com sucesso!" |
384 | 380 | ||
385 | -#: .\views.py:477 | 381 | +#: .\views.py:486 |
386 | msgid "We were not able to reset your password." | 382 | msgid "We were not able to reset your password." |
387 | msgstr "Não foi possível restaurar sua senha" | 383 | msgstr "Não foi possível restaurar sua senha" |
388 | 384 | ||
389 | -#: .\views.py:480 | 385 | +#: .\views.py:489 |
390 | msgid "The reset password link is no longer valid." | 386 | msgid "The reset password link is no longer valid." |
391 | msgstr "O link para restaurar senha não está mais válido." | 387 | msgstr "O link para restaurar senha não está mais válido." |
392 | 388 | ||
393 | -#: .\views.py:486 | 389 | +#: .\views.py:495 |
394 | msgid "Log In" | 390 | msgid "Log In" |
395 | msgstr "Entrar" | 391 | msgstr "Entrar" |
396 | 392 | ||
397 | -#: .\views.py:507 | 393 | +#: .\views.py:531 |
398 | msgid "System under maintenance. Try again later" | 394 | msgid "System under maintenance. Try again later" |
399 | msgstr "Sistema em manutenção. Tente novamente mais tarde" | 395 | msgstr "Sistema em manutenção. Tente novamente mais tarde" |
400 | 396 | ||
401 | -#: .\views.py:509 | 397 | +#: .\views.py:533 |
402 | msgid "E-mail or password are incorrect." | 398 | msgid "E-mail or password are incorrect." |
403 | msgstr "Email ou senha incorretos." | 399 | msgstr "Email ou senha incorretos." |
404 | 400 | ||
401 | +#~ msgid "Delete User" | ||
402 | +#~ msgstr "Deletar Usuário" | ||
403 | + | ||
404 | +#~ msgid "All data will be lost and havent how recover it." | ||
405 | +#~ msgstr "Toda informação será perdida e não poderá ser recuperada" | ||
406 | + | ||
407 | +#~ msgid "Remove" | ||
408 | +#~ msgstr "Deletar" | ||
409 | + | ||
410 | +#~ msgid "Remove Account" | ||
411 | +#~ msgstr "Remover Conta" | ||
412 | + | ||
405 | #, fuzzy | 413 | #, fuzzy |
406 | #~ msgid "User {name} created successfully" | 414 | #~ msgid "User {name} created successfully" |
407 | #~ msgstr "Usuário {name} criado com sucesso" | 415 | #~ msgstr "Usuário {name} criado com sucesso" |