Rev 1568 | Rev 1688 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1320 | jmachado | 1 | <%@ page import="jomm.dao.impl.AbstractDao" %> |
2 | <%@ page import="pt.estgp.estgweb.domain.CourseUnit" %> |
||
3 | <%@ page import="pt.estgp.estgweb.domain.CourseUnitGrade" %> |
||
4 | <%@ page import="pt.estgp.estgweb.domain.Student" %> |
||
5 | <%@ page import="pt.estgp.estgweb.domain.dao.DaoFactory" %> |
||
6 | <%@ page import="pt.estgp.estgweb.domain.views.CourseUnitGradeView" %> |
||
7 | <%@ page import="pt.estgp.estgweb.web.utils.DatesUtils" %> |
||
881 | jmachado | 8 | <%@ page import="pt.utl.ist.berserk.logic.serviceManager.IServiceManager" %> |
9 | <%@ page import="pt.utl.ist.berserk.logic.serviceManager.ServiceManager" %> |
||
1320 | jmachado | 10 | <%@ page import="java.util.*" %> |
881 | jmachado | 11 | <%@ page contentType="text/html;charset=UTF-8" language="java" %> |
12 | <%@ taglib uri="/WEB-INF/tlds/struts-html.tld" prefix="html" %> |
||
13 | <%@ taglib uri="/WEB-INF/tlds/struts-nested.tld" prefix="nested" %> |
||
14 | <%@ taglib uri="/WEB-INF/tlds/struts-logic.tld" prefix="logic" %> |
||
15 | <%@ taglib uri="/WEB-INF/tlds/struts-bean.tld" prefix="bean" %> |
||
16 | <%@ taglib uri="/WEB-INF/tlds/struts-tiles.tld" prefix="tiles" %> |
||
17 | <%@ taglib uri="/WEB-INF/tlds/baco.tld" prefix="baco" %> |
||
18 | <%@ taglib uri="/WEB-INF/tlds/jomm.tld" prefix="jomm" %> |
||
19 | <jsp:useBean id="CourseUnitEvaluationForm" type="pt.estgp.estgweb.web.form.courseunits.CourseUnitEvaluationForm" scope="request"/> |
||
20 | <jsp:useBean id="CourseUnitView" type="pt.estgp.estgweb.domain.views.CourseUnitView" scope="request"/> |
||
21 | <jsp:useBean id="UserSession" type="pt.estgp.estgweb.domain.UserSession" scope="request"/> |
||
1312 | jmachado | 22 | <baco:initCourseUnitEvaluationClearances name="CourseUnitView"/> |
23 | |||
881 | jmachado | 24 | |
1133 | jmachado | 25 | <script> |
26 | //Manter a sessão activa para os docentes não perderem os dados |
||
27 | ping(); |
||
28 | </script> |
||
29 | |||
881 | jmachado | 30 | <% |
31 | IServiceManager sm = ServiceManager.getInstance(); |
||
1320 | jmachado | 32 | %> |
881 | jmachado | 33 | |
1320 | jmachado | 34 | <% |
35 | long lastUpdate = 0; |
||
36 | Map<Student,CourseUnitGrade> approvedStudents = new HashMap<Student,CourseUnitGrade>(); |
||
37 | Map<String,List<CourseUnitGrade>> epocaGrades = new HashMap<String, List<CourseUnitGrade>>(); |
||
38 | Map<Student,CourseUnitGrade> finalGrades = new HashMap<Student, CourseUnitGrade>(); |
||
1097 | jmachado | 39 | |
1320 | jmachado | 40 | AbstractDao.getCurrentSession().beginTransaction(); |
41 | CourseUnit cu = DaoFactory.getCourseUnitDaoImpl().load(CourseUnitView.getId()); |
||
42 | for(CourseUnitGrade grade: cu.getCourseUnitGrades()) |
||
43 | { |
||
44 | if(grade.getUpdateDate().getTime() > lastUpdate) |
||
45 | lastUpdate = grade.getUpdateDate().getTime(); |
||
46 | CourseUnitGrade gradeA = approvedStudents.get(grade.getStudent()); |
||
47 | if(gradeA == null || gradeA.getGrade() < grade.getGrade()) |
||
48 | { |
||
49 | if(grade.getGrade() >= 10) |
||
50 | approvedStudents.put(grade.getStudent(),grade); |
||
881 | jmachado | 51 | |
1320 | jmachado | 52 | } |
53 | CourseUnitGrade gradeF = finalGrades.get(grade.getStudent()); |
||
54 | if(gradeF == null || gradeF.getGrade() < grade.getGrade()) |
||
55 | { |
||
56 | finalGrades.put(grade.getStudent(),grade); |
||
57 | } |
||
881 | jmachado | 58 | |
1320 | jmachado | 59 | List<CourseUnitGrade> eg = epocaGrades.get(grade.getDescEpoca()); |
60 | if(eg == null) |
||
61 | { |
||
62 | eg = new ArrayList<CourseUnitGrade>(); |
||
63 | epocaGrades.put(grade.getDescEpoca(),eg); |
||
64 | } |
||
65 | eg.add(grade); |
||
66 | } |
||
881 | jmachado | 67 | |
68 | |||
69 | |||
1320 | jmachado | 70 | %> |
1077 | jmachado | 71 | |
72 | |||
1320 | jmachado | 73 | <div class="modal fade" id="modalNotas" role="dialog" > |
74 | <div class="modal-dialog" data-width="90%" style="display: block; width: 90%; margin-top: 50px;" aria-hidden="false"> |
||
75 | <!-- Modal content--> |
||
76 | <div class="modal-content"> |
||
77 | <div class="modal-header"> |
||
78 | <h1 class="modal-title"> |
||
79 | Notas da Unidade Curricular de <%=CourseUnitView.getName()%> / <%=CourseUnitView.getImportYear()%> |
||
80 | <button type="button" class="btn btn-danger btn-xs pull-right" data-dismiss="modal"><span class="glyphicon glyphicon-remove"> </span> </button> |
||
81 | </h1> |
||
82 | </div> |
||
83 | <div class="modal-body"> |
||
84 | <div class="alert alert-info"> |
||
85 | Esta informação foi sincronizada a partir do sistema central do IPP poderá não estar atualizada. |
||
86 | Última atualização a (<%=DatesUtils.getStringFromDate(new Date(lastUpdate))%>) |
||
87 | </div> |
||
1077 | jmachado | 88 | |
1320 | jmachado | 89 | <% |
90 | int aprovadosNormal20 = 0; |
||
91 | int aprovadosRecurso36 = 0; |
||
92 | int aprovadosEspecial38 = 0; |
||
93 | int aprovados1013 = 0; |
||
94 | int aprovados1416 = 0; |
||
95 | int aprovados1720 = 0; |
||
96 | %> |
||
1312 | jmachado | 97 | |
1320 | jmachado | 98 | <div class="panel panel-success"> |
99 | <div class="panel-heading"> |
||
100 | Pauta Final (Pauta construida com as melhores notas de todos os alunos) |
||
101 | </div> |
||
102 | <div class="panel-body"> |
||
103 | |||
104 | <% |
||
105 | |||
106 | int reprovados = 0; |
||
107 | int semElementos = 0; |
||
108 | int aprovados = 0; |
||
109 | for(CourseUnitGrade grade: finalGrades.values()) |
||
110 | { |
||
111 | |||
112 | |||
113 | if(grade.getGrade() >= 10) |
||
114 | { |
||
115 | aprovados++; |
||
116 | if(grade.getCodigoEpoca().equals("20")) |
||
117 | aprovadosNormal20++; |
||
118 | else if(grade.getCodigoEpoca().equals("36")) |
||
119 | aprovadosRecurso36++; |
||
120 | else if(grade.getCodigoEpoca().equals("38")) |
||
121 | aprovadosEspecial38++; |
||
122 | |||
1568 | jmachado | 123 | if(grade.getCodigoEpoca().equals("20") || grade.getCodigoEpoca().equals("36") || grade.getCodigoEpoca().equals("38")) |
124 | { |
||
125 | if(grade.getGrade() <= 13) |
||
126 | aprovados1013++; |
||
127 | else if(grade.getGrade() <= 16) |
||
128 | aprovados1416++; |
||
129 | else |
||
130 | aprovados1720++; |
||
131 | } |
||
1320 | jmachado | 132 | |
133 | } |
||
134 | else if(grade.getGrade() > 0) |
||
135 | { |
||
136 | reprovados++; |
||
137 | } |
||
138 | else |
||
1568 | jmachado | 139 | semElementos++; |
1320 | jmachado | 140 | } |
141 | int aprovados1013Per = (int) (((float)aprovados1013)/((float)aprovados)*100.0); |
||
142 | int aprovados1416Per = (int) (((float)aprovados1416)/((float)aprovados)*100.0); |
||
143 | int aprovados1720Per = (int) (((float)aprovados1720)/((float)aprovados)*100.0); |
||
1568 | jmachado | 144 | |
145 | int aprovadosIgnorandoEquivalencia = aprovadosNormal20 + aprovadosRecurso36 + aprovadosEspecial38; |
||
146 | int inscritosSemEquivalencias = reprovados + aprovadosIgnorandoEquivalencia + semElementos; |
||
147 | int aprovados1013PerIgnorandoEquivalencias = (int) (((float)aprovados1013)/((float)(aprovadosIgnorandoEquivalencia))*100.0); |
||
148 | int aprovados1416PerIgnorandoEquivalencias = (int) (((float)aprovados1416)/((float)aprovadosIgnorandoEquivalencia)*100.0); |
||
149 | int aprovados1720PerIgnorandoEquivalencias = (int) (((float)aprovados1720)/((float)aprovadosIgnorandoEquivalencia)*100.0); |
||
1320 | jmachado | 150 | %> |
151 | <div class="col-md-4"> |
||
152 | <p><strong>Inscritos:</strong> <%=finalGrades.values().size()%> </p> |
||
153 | <p><strong>Aprovados:</strong> <%=aprovados%> </p> |
||
154 | <p><strong>Reprovados:</strong> <%=reprovados%></p> |
||
155 | <p><strong>Sem Elementos de Avaliação:</strong> <%=semElementos%></p> |
||
156 | </div> |
||
157 | <div class="col-md-4"> |
||
158 | <p><strong>Aprovados em Época Normal:</strong> <%=aprovadosNormal20%> </p> |
||
159 | <p><strong>Aprovados em Época Recurso:</strong> <%=aprovadosRecurso36%> </p> |
||
160 | <p><strong>Aprovados em Época Especial:</strong> <%=aprovadosEspecial38%> </p> |
||
161 | </div> |
||
162 | <div class="col-md-4"> |
||
163 | <p><strong>Aprovados entre 10 e 13:</strong> <%=aprovados1013%> (<%=aprovados1013Per%>%) </p> |
||
164 | <p><strong>Aprovados entre 14 e 16:</strong> <%=aprovados1416%> (<%=aprovados1416Per%>%) </p> |
||
165 | <p><strong>Aprovados entre 17 e 20:</strong> <%=aprovados1720%> (<%=aprovados1720Per%>%) </p> |
||
166 | </div> |
||
167 | <table class="tablesorterfiltered" id="pautaFinal"> |
||
168 | <thead> |
||
169 | <tr> |
||
170 | <th> |
||
171 | <bean:message key="code"/> |
||
172 | </th> |
||
173 | <th> |
||
174 | <bean:message key="student"/> |
||
175 | </th> |
||
176 | <th> |
||
177 | <bean:message key="grade"/> |
||
178 | </th> |
||
179 | <th> |
||
180 | <bean:message key="date"/> |
||
181 | </th> |
||
182 | <th> |
||
183 | Epoca de Avaliação |
||
184 | </th> |
||
185 | <th> |
||
186 | Status de Época |
||
187 | </th> |
||
188 | </tr> |
||
189 | </thead> |
||
190 | <tbody> |
||
191 | <% |
||
192 | for(CourseUnitGrade grade: finalGrades.values()) |
||
193 | { |
||
194 | request.setAttribute("grade",new CourseUnitGradeView(grade)); |
||
195 | %> |
||
196 | <tr> |
||
197 | <td> |
||
198 | ${grade.student.code} |
||
199 | </td> |
||
200 | <td> |
||
201 | ${grade.student.name} |
||
202 | </td> |
||
203 | <td> |
||
204 | <logic:greaterThan value="0" name="grade" property="grade"> |
||
205 | ${grade.grade} |
||
206 | </logic:greaterThan> |
||
207 | <logic:lessThan value="0" name="grade" property="grade"> |
||
208 | S/N |
||
209 | </logic:lessThan> |
||
210 | </td> |
||
211 | <td> |
||
212 | ${grade.formatedDate} |
||
213 | </td> |
||
214 | |||
215 | <td> |
||
216 | ${grade.descEpoca} |
||
217 | </td> |
||
218 | <td> |
||
219 | ${grade.descStatusEpoca} |
||
220 | </td> |
||
221 | </tr> |
||
222 | <% |
||
223 | } |
||
224 | %> |
||
225 | </tbody> |
||
226 | </table> |
||
227 | |||
228 | </div> |
||
229 | </div> |
||
230 | |||
231 | |||
232 | |||
233 | <% |
||
234 | for(Map.Entry<String,List<CourseUnitGrade>> grades: epocaGrades.entrySet()) |
||
235 | { |
||
236 | int reprovadosEp = 0; |
||
237 | int semElementosEp = 0; |
||
238 | int aprovadosEp = 0; |
||
239 | for(CourseUnitGrade grade: grades.getValue()) |
||
240 | { |
||
241 | if(grade.getGrade() >= 10) |
||
242 | { |
||
243 | aprovadosEp++; |
||
244 | } |
||
245 | else if(grade.getGrade() > 0) |
||
246 | { |
||
247 | reprovadosEp++; |
||
248 | } |
||
249 | else |
||
250 | semElementosEp ++; |
||
251 | } |
||
252 | %> |
||
253 | <div class="panel panel-default"> |
||
254 | <div class="panel-heading"> |
||
255 | <%=grades.getKey()%> |
||
256 | </div> |
||
257 | <div class="panel-body"> |
||
258 | <p><strong>Aprovados nesta época:</strong> <%=aprovadosEp%> </p> |
||
259 | <p><strong>Reprovados nesta época:</strong> <%=reprovadosEp%></p> |
||
260 | <p><strong>Sem Elementos de Avaliação nesta época:</strong> <%=semElementosEp%></p> |
||
261 | <table class="tablesorterfiltered"> |
||
262 | <thead> |
||
263 | <tr> |
||
264 | <th> |
||
265 | <bean:message key="code"/> |
||
266 | </th> |
||
267 | <th> |
||
268 | <bean:message key="student"/> |
||
269 | </th> |
||
270 | <th> |
||
271 | <bean:message key="grade"/> |
||
272 | </th> |
||
273 | <th> |
||
274 | <bean:message key="date"/> |
||
275 | </th> |
||
276 | <th> |
||
277 | Epoca de Avaliação |
||
278 | </th> |
||
279 | <th> |
||
280 | Status de Época |
||
281 | </th> |
||
282 | </tr> |
||
283 | </thead> |
||
284 | <tbody> |
||
285 | <% |
||
286 | for(CourseUnitGrade grade: grades.getValue()) |
||
287 | { |
||
288 | request.setAttribute("grade",new CourseUnitGradeView(grade)); |
||
289 | %> |
||
290 | <tr> |
||
291 | <td> |
||
292 | ${grade.student.code} |
||
293 | </td> |
||
294 | <td> |
||
295 | ${grade.student.name} |
||
296 | </td> |
||
297 | <td> |
||
298 | <logic:greaterThan value="0" name="grade" property="grade"> |
||
299 | ${grade.grade} |
||
300 | </logic:greaterThan> |
||
301 | <logic:lessThan value="0" name="grade" property="grade"> |
||
302 | S/N |
||
303 | </logic:lessThan> |
||
304 | </td> |
||
305 | <td> |
||
306 | ${grade.formatedDate} |
||
307 | </td> |
||
308 | <td> |
||
309 | ${grade.descEpoca} |
||
310 | </td> |
||
311 | <td> |
||
312 | ${grade.descStatusEpoca} |
||
313 | </td> |
||
314 | </tr> |
||
315 | <% |
||
316 | } |
||
317 | %> |
||
318 | </tbody> |
||
319 | </table> |
||
320 | |||
321 | </div> |
||
322 | </div> |
||
323 | <% |
||
324 | } |
||
325 | %> |
||
326 | |||
327 | </div> |
||
328 | </div> |
||
329 | </div> |
||
330 | </div> |
||
331 | |||
332 | |||
333 | <% |
||
334 | AbstractDao.getCurrentSession().getTransaction().commit(); |
||
881 | jmachado | 335 | %> |
336 | |||
1320 | jmachado | 337 | |
338 | |||
339 | |||
340 | |||
341 | |||
342 | |||
343 | |||
344 | |||
345 | |||
346 | |||
1312 | jmachado | 347 | <div class="panel panel-primary"> |
348 | <div class="panel-heading"> |
||
1479 | jmachado | 349 | <span class="icon icon-flag"></span> <bean:message key="courseunit.evaluation"/> - <%=CourseUnitView.getName()%> / <%=CourseUnitView.getImportYear()%> |
881 | jmachado | 350 | |
1320 | jmachado | 351 | |
1312 | jmachado | 352 | <% |
353 | if( CourseUnitView.getEvaluationStreamId() !=null ){ |
||
354 | %> |
||
355 | <span class="badge icon"> |
||
356 | <a href="javascript:invoqueDataVersionForm(${CourseUnitView.evaluationStreamId})"><span class="icon icon-history icon-large"></span></a> |
||
357 | </span> |
||
358 | <span class="badge icon"> |
||
359 | <a href="<%=request.getContextPath()%>/repositoryStream/<%=CourseUnitView.getEvaluationStreamId()%>"> |
||
360 | <span class="icon icon-file-pdf icon-large"/> |
||
361 | </a> |
||
362 | </span> |
||
363 | <% |
||
364 | } |
||
365 | %> |
||
987 | jmachado | 366 | |
1312 | jmachado | 367 | </div> |
368 | <div class="panel-body"> |
||
1320 | jmachado | 369 | |
370 | <html:errors/> |
||
371 | <jomm:messages/> |
||
372 | |||
1686 | jmachado | 373 | |
1312 | jmachado | 374 | <baco:notClearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_ACTIVE"> |
375 | <div class="alert alert-info"> |
||
376 | <bean:message key="courseunit.evaluation.period.inactive"/> |
||
377 | </div> |
||
378 | </baco:notClearOperation> |
||
379 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_ACTIVE_SPECIAL_ADMIN"> |
||
380 | <div class="alert alert-warning"> |
||
381 | <bean:message key="courseunit.evaluation.period.admin.active"/> |
||
382 | </div> |
||
383 | </baco:clearOperation> |
||
384 | <logic:equal value="true" name="CourseUnitEvaluationForm" property="courseUnitEvaluationView.fechar"> |
||
385 | <div class="alert alert-success"><bean:message key="courseunit.evaluation.dtp.info"/></div> |
||
386 | </logic:equal> |
||
887 | jmachado | 387 | |
1529 | jmachado | 388 | <!-- ESTADOS --> |
389 | |||
390 | |||
391 | |||
392 | <div class="row-centered clearfix"> |
||
1312 | jmachado | 393 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_STATE_EDIT"> |
1529 | jmachado | 394 | <div class="alert alert-warning col-md-3 col-sm-3"> |
395 | <span class="glyphicon glyphicon-edit"></span> Em edição (Qualquer docente da unidade pode editar e entregar) |
||
1312 | jmachado | 396 | </div> |
397 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
398 | <div class="alert alert-disabled col-md-3 col-sm-3"> |
||
1529 | jmachado | 399 | <span class="glyphicon glyphicon-education"></span> Comissão aguarda entrega do docente |
1312 | jmachado | 400 | </div> |
401 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
402 | <div class="alert alert-disabled col-md-3 col-sm-3"> |
||
1529 | jmachado | 403 | <span class="glyphicon glyphicon-flag"></span> <bean:message key="courseunit.evaluation.state.closed"/> |
1312 | jmachado | 404 | </div> |
405 | </baco:clearOperation> |
||
406 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_STATE_COMPLETE"> |
||
1529 | jmachado | 407 | <div class="alert alert-success col-md-3 col-sm-3"> |
408 | <span class="glyphicon glyphicon-edit"></span> Entregue pelo Docente |
||
1312 | jmachado | 409 | </div> |
410 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
1529 | jmachado | 411 | <div class="alert alert-warning col-md-3 col-sm-3"> |
412 | <span class="glyphicon glyphicon-education"></span> Em <bean:message key="courseunit.evaluation.state.complete"/> pela comissão |
||
1312 | jmachado | 413 | </div> |
414 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
415 | <div class="alert alert-disabled col-md-3 col-sm-3"> |
||
1529 | jmachado | 416 | <span class="glyphicon glyphicon-flag"></span> <bean:message key="courseunit.evaluation.state.closed"/> |
1312 | jmachado | 417 | </div> |
418 | </baco:clearOperation> |
||
419 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_STATE_CLOSED"> |
||
1529 | jmachado | 420 | <div class="alert alert-success col-md-3 col-sm-3"> |
421 | <span class="glyphicon glyphicon-edit"></span> Entregue pelo Docente |
||
1312 | jmachado | 422 | </div> |
423 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
1529 | jmachado | 424 | <div class="alert alert-success col-md-3 col-sm-3"> |
425 | <span class="glyphicon glyphicon-education"></span> Validado pela Comissão |
||
1312 | jmachado | 426 | </div> |
427 | <div class="col-md-1 col-sm-1 vcenter alert"><span class="glyphicon glyphicon-chevron-right"/></div> |
||
1529 | jmachado | 428 | <div class="alert alert-success col-md-3 col-sm-3"> |
429 | <span class="glyphicon glyphicon-flag"></span> <bean:message key="courseunit.evaluation.state.closed"/> |
||
1312 | jmachado | 430 | </div> |
431 | </baco:clearOperation> |
||
432 | </div> |
||
1033 | jmachado | 433 | |
1529 | jmachado | 434 | |
435 | <div class="row-centered clearfix"> |
||
1312 | jmachado | 436 | <div class="col-md-3 col-sm-3"> |
437 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_TRANSITATE_TO_EDIT"> |
||
438 | <html:form action="/user/courseUnitEvaluationController"> |
||
1355 | jmachado | 439 | |
1312 | jmachado | 440 | <input type="hidden" name="dispatch" value="openEvaluation"> |
441 | <html:hidden property="courseUnitView.id"/> |
||
442 | <button type="submit" class="btn btn-default"> |
||
443 | <bean:message key="courseunit.evaluation.transit.to.edition"/> |
||
444 | </button> |
||
445 | </html:form> |
||
446 | </baco:clearOperation> |
||
447 | </div> |
||
448 | <div class="col-md-1 col-sm-1"></div> |
||
449 | <div class="col-md-3 col-sm-3"> |
||
450 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_TRANSITATE_TO_COMPLETE"> |
||
1529 | jmachado | 451 | <button type="button" class="btn btn-default" onclick="$('#buttonTeacherCompleteEvaluation').click()"> |
1312 | jmachado | 452 | <bean:message key="courseunit.evaluation.transit.to.complete"/> |
453 | </button> |
||
454 | </baco:clearOperation> |
||
455 | </div> |
||
456 | <div class="col-md-1 col-sm-1"></div> |
||
457 | <div class="col-md-3 col-sm-3"> |
||
458 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_TRANSITATE_TO_CLOSE"> |
||
1529 | jmachado | 459 | <button type="button" class="btn btn-default" onclick="$('#buttonPublishEvaluation').click()"><bean:message key="courseunit.evaluation.transit.to.closed"/></button> |
1312 | jmachado | 460 | </baco:clearOperation> |
461 | </div> |
||
462 | </div> |
||
987 | jmachado | 463 | |
1529 | jmachado | 464 | |
465 | |||
466 | |||
467 | |||
468 | |||
1312 | jmachado | 469 | </div> |
470 | <div class="panel-body"> |
||
950 | jmachado | 471 | |
987 | jmachado | 472 | |
1033 | jmachado | 473 | |
474 | |||
1686 | jmachado | 475 | <html:form styleId="formEval" styleClass="form-horizontal" action="/user/courseUnitEvaluationControllerWidget"> |
1312 | jmachado | 476 | <input type="hidden" id="dispatch" name="dispatch" value="saveEvaluation"> |
477 | <html:hidden property="id"/> |
||
478 | <html:hidden property="courseUnitView.id"/> |
||
1686 | jmachado | 479 | <input type="hidden" name="autosave" value="true"/> |
1033 | jmachado | 480 | |
481 | |||
1686 | jmachado | 482 | <div class="web-messages"></div> |
881 | jmachado | 483 | |
1686 | jmachado | 484 | |
1312 | jmachado | 485 | <div class="panel panel-default"> |
486 | <div class="panel-heading"> |
||
487 | Dados alterados pelo Docente da Unidade |
||
488 | </div> |
||
489 | <div class="panel-body"> |
||
490 | <div id="autosave"></div> |
||
1032 | jmachado | 491 | |
1320 | jmachado | 492 | |
1355 | jmachado | 493 | <h3>Dados para confirmar pelo Docente da Unidade |
494 | |||
495 | <button type="button" data-toggle="modal" data-target="#modalNotas" class="btn btn-info" href=""> |
||
496 | Consultar Notas |
||
497 | <span class="icon icon-table2"> </span> </button> |
||
498 | |||
499 | |||
500 | </h3> |
||
1320 | jmachado | 501 | <table class="tablesorter-blue" width="100%"> |
1033 | jmachado | 502 | <tr> |
1312 | jmachado | 503 | <th rowspan="2"> |
504 | Nº Alunos Inscritos |
||
505 | </th> |
||
506 | <th rowspan="2"> |
||
507 | Nº de alunos sem elementos de avaliação |
||
508 | </th> |
||
509 | <th colspan="5"> |
||
510 | Nº de alunos aprovados em |
||
511 | </th> |
||
512 | <th rowspan="2"> |
||
513 | Aprovados com a classificação entre 10 e 13 valores (%) |
||
514 | </th> |
||
515 | <th rowspan="2"> |
||
516 | Aprovados com a classificação entre 14 e 16 valores (%) |
||
517 | </th> |
||
518 | <th rowspan="2"> |
||
519 | Aprovados com a classificação entre 17 e 20 valores (%) |
||
520 | </th> |
||
521 | </tr> |
||
522 | <tr> |
||
523 | <th>Avaliação de frequência</th> |
||
524 | <th>Exame Época Normal</th> |
||
525 | <th>Exame Época Recurso</th> |
||
526 | <th>Exame Época Especial</th> |
||
527 | <th>Total</th> |
||
528 | </tr> |
||
529 | <tr> |
||
1320 | jmachado | 530 | <td class="text-center"> |
531 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosInscritos"/> |
||
1033 | jmachado | 532 | </td> |
1320 | jmachado | 533 | <td class="text-center"> |
534 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosSemElementosAvaliacao"/> |
||
1033 | jmachado | 535 | </td> |
1320 | jmachado | 536 | <td class="text-center"> |
537 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprovFrequencia"/> |
||
1033 | jmachado | 538 | </td> |
1320 | jmachado | 539 | <td class="text-center"> |
540 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprovNormal"/> |
||
1312 | jmachado | 541 | </td> |
1320 | jmachado | 542 | <td class="text-center"> |
543 | <html:text styleClass="form-control" style="width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprovRecurso"/> |
||
1312 | jmachado | 544 | </td> |
1320 | jmachado | 545 | <td style="text-align: center"> |
546 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprovEspecial"/> |
||
1312 | jmachado | 547 | </td> |
1320 | jmachado | 548 | <td class="text-center"> |
549 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprovTotal"/> |
||
1312 | jmachado | 550 | </td> |
1320 | jmachado | 551 | <td class="text-center"> |
552 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprov1013"/>% |
||
1312 | jmachado | 553 | </td> |
1320 | jmachado | 554 | <td class="text-center"> |
555 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprov1416"/>% |
||
1312 | jmachado | 556 | </td> |
1320 | jmachado | 557 | <td class="text-center"> |
558 | <html:text styleClass="form-control" style="margin:auto; width: 50px" size="4" property="courseUnitEvaluationView.courseUnitEvaluation.numAlunosAprov1720"/>% |
||
1312 | jmachado | 559 | </td> |
1033 | jmachado | 560 | </tr> |
1320 | jmachado | 561 | <tr> |
1530 | jmachado | 562 | <td colspan="10"> |
563 | <div class="alert alert-info"> |
||
564 | Os dados abaixo são obtidos da sincronização de notas (PODEM ESTAR ERRADOS) (servem apenas como AJUDA para confirmação pelo docente). OS DADOS DE CONSULTA CONTABILIZAM <b><i>EQUIVALÊNCIAS</i></b>, o uso ou não das equivalências nas contagens é da responsabilidade dos docentes e dos orgãos competentes. |
||
565 | </div> |
||
566 | </td> |
||
1320 | jmachado | 567 | </tr> |
568 | <tr> |
||
569 | <td class="text-center"> |
||
1568 | jmachado | 570 | <%=inscritosSemEquivalencias%> |
1320 | jmachado | 571 | </td> |
572 | <td class="text-center"> |
||
573 | <%=semElementos%> |
||
574 | </td> |
||
575 | <td class="text-center"> |
||
576 | ? |
||
577 | </td> |
||
578 | <td class="text-center"> |
||
579 | <%=aprovadosNormal20%> |
||
580 | </td> |
||
581 | <td class="text-center"> |
||
582 | <%=aprovadosRecurso36%> |
||
583 | </td> |
||
584 | <td class="text-center"> |
||
585 | <%=aprovadosEspecial38%> |
||
586 | </td> |
||
587 | <td class="text-center"> |
||
1568 | jmachado | 588 | <%=aprovadosIgnorandoEquivalencia%> |
1320 | jmachado | 589 | </td> |
590 | <td class="text-center"> |
||
1568 | jmachado | 591 | <%=aprovados1013PerIgnorandoEquivalencias%> % |
1320 | jmachado | 592 | </td> |
593 | <td class="text-center"> |
||
1568 | jmachado | 594 | <%=aprovados1416PerIgnorandoEquivalencias%> % |
1320 | jmachado | 595 | </td> |
596 | <td class="text-center"> |
||
1568 | jmachado | 597 | <%=aprovados1720PerIgnorandoEquivalencias%> % |
1320 | jmachado | 598 | </td> |
599 | </tr> |
||
1033 | jmachado | 600 | </table> |
950 | jmachado | 601 | |
1033 | jmachado | 602 | |
1312 | jmachado | 603 | <h3>Auto-avaliação</h3> |
604 | <table class="tablesorter-blue" width="100%"> |
||
605 | <tr> |
||
606 | <th>Apreciação dos resultados quantitativos obtidos pelos estudantes</th> |
||
607 | <td width="80%"> |
||
608 | <html:textarea styleClass="form-control" style="width:100%;height: 200px" property="courseUnitEvaluationView.courseUnitEvaluation.qualApreciacaoQuantitivos"/> |
||
609 | </td> |
||
610 | </tr> |
||
611 | <tr> |
||
612 | <th>Apreciação do funcionamento da UC<br/> |
||
613 | (Condições de funcionamento da UC; problemas detetados; identificação de práticas pedagógicas de mérito ou deficientes; etc.)</th> |
||
614 | <td width="80%"> |
||
615 | <html:textarea styleClass="form-control" style="width:100%;height: 200px" property="courseUnitEvaluationView.courseUnitEvaluation.qualApreciacaoUC"/> |
||
616 | </td> |
||
617 | </tr> |
||
618 | <tr> |
||
619 | <th>Apreciação do cumprimento do programa da UC<br/> |
||
620 | (Adequação das metodologias de ensino/aprendizagem utilizadas; competências efetivamente adquiridas e cumprimento dos conteúdos planificados) |
||
621 | </th> |
||
622 | <td width="80%"> |
||
623 | <html:textarea styleClass="form-control" style="width:100%;height: 200px" property="courseUnitEvaluationView.courseUnitEvaluation.qualApreciacaoCumprimentoPrograma"/> |
||
624 | </td> |
||
625 | </tr> |
||
626 | <tr> |
||
627 | <th> |
||
628 | Conclusões<br/> |
||
629 | (Pontos fortes e fracos; sugestões de melhoria e respetivo plano de ação para a sua concretização) |
||
630 | </th> |
||
631 | <td width="80%"> |
||
632 | <html:textarea styleClass="form-control" style="width:100%;height: 200px" property="courseUnitEvaluationView.courseUnitEvaluation.qualConclusoes"/> |
||
633 | </td> |
||
634 | </tr> |
||
635 | </table> |
||
1215 | jmachado | 636 | |
1312 | jmachado | 637 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_EDITSAVE"> |
1686 | jmachado | 638 | <button type="button" class="btn btn-default" onclick="submitFormWaitAutoSave(form,'saveEvaluation');"><bean:message key="save"/></button> |
1312 | jmachado | 639 | </baco:clearOperation> |
1215 | jmachado | 640 | |
1312 | jmachado | 641 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_TRANSITATE_TO_COMPLETE"> |
1686 | jmachado | 642 | <button type="button" id="buttonTeacherCompleteEvaluation" class="btn btn-default" onclick="submitFormWaitAutoSave(form,'teacherCompleteEvaluation');"><bean:message key="courseunit.evaluation.transit.to.complete"/></button> |
1312 | jmachado | 643 | </baco:clearOperation> |
1215 | jmachado | 644 | |
1312 | jmachado | 645 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_TRANSITATE_TO_CLOSE"> |
1686 | jmachado | 646 | <button type="button" id="buttonPublishEvaluation" class="btn btn-default" onclick="submitFormWaitAutoSave(form,'publishEvaluation');"><bean:message key="courseunit.evaluation.transit.to.closed"/></button> |
1312 | jmachado | 647 | </baco:clearOperation> |
1215 | jmachado | 648 | |
649 | |||
1312 | jmachado | 650 | </div> |
1215 | jmachado | 651 | </div> |
652 | |||
653 | |||
1312 | jmachado | 654 | </html:form> |
655 | |||
656 | |||
1215 | jmachado | 657 | </div> |
658 | </div> |
||
1312 | jmachado | 659 | |
660 | |||
661 | |||
662 | |||
663 | |||
664 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_EDITSAVE"> |
||
665 | |||
666 | <!-- Modal SAVE --> |
||
667 | <!-- Modal --> |
||
668 | <div class="modal fade" id="myModal" role="dialog" > |
||
669 | <div class="modal-dialog" data-width="760" style="display: block; width: 760px; margin-top: 50px;" aria-hidden="false"> |
||
670 | |||
671 | <!-- Modal content--> |
||
672 | <div class="modal-content"> |
||
673 | <div class="modal-header"> |
||
674 | |||
675 | <h1 class="modal-title"><bean:message key="courseunit.evaluation.sending.report.title"/></h1> |
||
676 | </div> |
||
677 | <div class="modal-body"> |
||
678 | <p> |
||
679 | <bean:message key="courseunit.evaluation.sending.report.text"/> <img src="<%=request.getContextPath()%>/imgs/wait.gif"/> |
||
680 | </p> |
||
681 | </div> |
||
682 | <div class="modal-footer"> |
||
683 | |||
684 | </div> |
||
685 | </div> |
||
686 | |||
687 | </div> |
||
688 | </div> |
||
689 | |||
887 | jmachado | 690 | <script> |
1215 | jmachado | 691 | |
692 | |||
889 | jmachado | 693 | $( document ).ready(function() { |
1312 | jmachado | 694 | |
695 | <baco:notClearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_ACTIVE"> |
||
1215 | jmachado | 696 | $("#formEdit :input").attr("disabled", true); |
1312 | jmachado | 697 | </baco:notClearOperation> |
698 | |||
699 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_INFO_STATE_CLOSED"> |
||
950 | jmachado | 700 | $("#formEdit :input").attr("disabled", true); |
1312 | jmachado | 701 | </baco:clearOperation> |
1153 | jmachado | 702 | |
1312 | jmachado | 703 | <baco:notClearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_PERSIST_TEACHER_PART"> |
704 | <baco:notClearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_PERSIST_COMISSION_PART"> |
||
705 | $("#formEdit :input").attr("disabled", true); |
||
706 | </baco:notClearOperation> |
||
707 | </baco:notClearOperation> |
||
1153 | jmachado | 708 | |
1312 | jmachado | 709 | <baco:clearOperation name="CourseUnitView" property="courseUnit" op="EVALUATION_EDITSAVE"> |
1686 | jmachado | 710 | setTimeout("autoSaveStart()",5000); |
1312 | jmachado | 711 | </baco:clearOperation> |
1215 | jmachado | 712 | |
889 | jmachado | 713 | }); |
1312 | jmachado | 714 | |
1686 | jmachado | 715 | |
1215 | jmachado | 716 | var stopAutoSave = false; |
1686 | jmachado | 717 | function autoSaveStart() |
718 | { |
||
719 | if(!stopAutoSave) |
||
720 | sendEvaluation(true,"saveEvaluation"); |
||
889 | jmachado | 721 | |
1686 | jmachado | 722 | } |
723 | |||
724 | function submitFormWaitAutoSave(form,service) |
||
1153 | jmachado | 725 | { |
1686 | jmachado | 726 | stopAutoSave = true; |
727 | $('#myModal').modal({ |
||
728 | show: 'true' |
||
729 | }); |
||
730 | //esperar se houver algum update a executar 1500 segundos é o maximo de espera |
||
731 | //se a pagina não recarregar e porque a thread parou |
||
732 | setTimeout("submitForm('" + service + "')",2000); |
||
733 | } |
||
734 | |||
735 | function submitForm(service) |
||
736 | { |
||
737 | //Para Submeter sem o JSON = true |
||
738 | |||
739 | sendEvaluation(false,service); |
||
740 | } |
||
741 | |||
742 | |||
743 | |||
744 | |||
745 | |||
746 | function sendEvaluation(autosave,service) |
||
747 | { |
||
748 | |||
749 | |||
750 | if(autosave) |
||
1215 | jmachado | 751 | { |
1686 | jmachado | 752 | $("#dispatch").val("saveEvaluation"); |
753 | $("#autosave").html('<div class="alert alert-info">Enviando ...</div>'); |
||
754 | $("#formEval input[name='autosave']").val("true"); |
||
1215 | jmachado | 755 | } |
756 | else |
||
1686 | jmachado | 757 | $("#formEval input[name='autosave']").val("false"); |
1208 | jmachado | 758 | |
1686 | jmachado | 759 | widgetSimpleCall( |
760 | service, |
||
761 | $("#formEval"), |
||
762 | function() |
||
763 | { |
||
764 | $('#myModal').modal("hide"); |
||
765 | //ok |
||
766 | if(autosave) |
||
767 | { |
||
1312 | jmachado | 768 | $("#autosave").html('<div class="alert alert-success">Salvo Automaticamente (Apenas Dados, não gerou PDF, para gerar PDF terá de salvar o docente)</div>'); |
1686 | jmachado | 769 | } |
1215 | jmachado | 770 | else |
1686 | jmachado | 771 | { |
772 | modalWebMessagesGivenContainer("Avaliação Salva","#formEval","<%=request.getContextPath()%>/user/startLoadCourseUnitEvaluation.do?courseUnitId=${CourseUnitView.id}"); |
||
773 | } |
||
1215 | jmachado | 774 | }, |
1686 | jmachado | 775 | function() |
776 | { |
||
777 | $('#myModal').modal("hide"); |
||
778 | modalWebMessagesGivenContainer("Avaliação Salva","#formEval"); |
||
1215 | jmachado | 779 | } |
1686 | jmachado | 780 | ); |
1153 | jmachado | 781 | } |
782 | |||
887 | jmachado | 783 | </script> |
1312 | jmachado | 784 | </baco:clearOperation> |
887 | jmachado | 785 |