Rev 1411 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1411 | Rev 1412 | ||
---|---|---|---|
Line 60... | Line 60... | ||
60 | HttpServletResponse response) |
60 | HttpServletResponse response) |
61 | throws 1.5.0/docs/api/java/lang/Throwable.html">Throwable |
61 | throws 1.5.0/docs/api/java/lang/Throwable.html">Throwable |
62 | { |
62 | { |
63 | QuestionarioRespostaForm frm = (QuestionarioRespostaForm) form; |
63 | QuestionarioRespostaForm frm = (QuestionarioRespostaForm) form; |
64 | 64 | ||
65 | /* |
65 | |
66 | 66 | ||
67 | IServiceManager sm = ServiceManager.getInstance(); |
67 | IServiceManager sm = ServiceManager.getInstance(); |
68 | String[] names = {"year","semestre","questionarioId"}; |
68 | 1.5.0/docs/api/java/lang/String.html">String[] names = {"resposta","alunoRequisitadoId"}; |
69 | Object[] args = {frm.getQuestionario().getYear(),frm.getQuestionario().getSemestre(), frm.getQuestionario().getId()}; |
69 | 5+0%2Fdocs%2Fapi+Object">Object[] args = {frm.getResposta(),frm.getAlunoRequesitadoId()}; |
- | 70 | ||
- | 71 | sm.execute(RequestUtils.getRequester(request, response),"QuestionarioSalvarResposta",args,names); |
|
- | 72 | addMessage(request,"questionario.resposta.com.sucesso"); |
|
70 | 73 | ||
71 | List<QuestionarioImpl> yearSemestreHistory = (List<QuestionarioImpl>) sm.execute(RequestUtils.getRequester(request, response),"setAnoSemestre",args,names); |
- | |
72 | request.setAttribute("SimilarQuestionariosFound",yearSemestreHistory); |
- | |
73 | for(QuestionarioImpl q: yearSemestreHistory) |
- | |
74 | { |
- | |
75 | if(q.getId() != frm.getQuestionario().getId()) |
- | |
76 | { |
- | |
77 | addError(request, "warn.questionario.repeated.in.time", "" + q.getId()); |
- | |
78 | } |
- | |
79 | else |
- | |
80 | { |
- | |
81 | addMessage(request,"questionario.year.semestre.ok"); |
- | |
82 | //Colocando o questionario em tratamento atualizado no form |
- | |
83 | frm.setQuestionario(q); |
- | |
84 | } |
- | |
85 | } |
- | |
86 | */ |
- | |
87 | return mapping.findForward("admin"); |
74 | return mapping.findForward("success"); |
88 | } |
75 | } |
89 | 76 | ||
90 | } |
77 | } |