public ActionForward viewInformation(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws FenixActionException, FenixFilterException { ActionErrors errors = new ActionErrors();
public ActionForward viewInformation(ActionMapping mapping, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws FenixFilterException, FenixServiceException { RequestUtils.getAndSetStringToRequest(request, "info");  Integer degreeCurricularPlanID = Integer.valueOf(RequestUtils.getAndSetStringToRequest(request, "degreeCurricularPlanID")); DegreeCurricularPlan degreeCurricularPlan = rootDomainObject.readDegreeCurricularPlanByOID(degreeCurricularPlanID);  ExecutionYear currentExecutionYear = ExecutionYear.readCurrentExecutionYear(); DegreeInfo currentDegreeInfo = currentExecutionYear.getDegreeInfo(degreeCurricularPlan.getDegree());  if (currentDegreeInfo == null) { final IUserView userView = SessionUtils.getUserView(request);  if (!userView.getPerson().getTeacher().isCoordinatorFor(degreeCurricularPlan, currentExecutionYear)) { final ActionErrors errors = new ActionErrors(); errors.add("notAuthorized", new ActionError("error.exception.notAuthorized2")); saveErrors(request, errors); return new ActionForward(mapping.getInput()); }
    public ActionForward viewInformation(ActionMapping mapping, ActionForm form,            HttpServletRequest request, HttpServletResponse response) throws FenixActionException,            FenixFilterException {        ActionErrors errors = new ActionErrors();        IUserView userView = SessionUtils.getUserView(request);        Integer degreeCurricularPlanID = new Integer(RequestUtils.getAndSetStringToRequest(request,                "degreeCurricularPlanID"));        // it's necessary to find which information will be edited        RequestUtils.getAndSetStringToRequest(request, "info");        RequestUtils.getAndSetStringToRequest(request, "inEnglish");        Object[] args = { degreeCurricularPlanID };        InfoDegreeInfo infoDegreeInfo = null;        try {            infoDegreeInfo = (InfoDegreeInfo) ServiceManagerServiceFactory.executeService(userView,                    "ReadDegreeInfoByDegreeCurricularPlanID", args);        } catch (NotAuthorizedException e) {            errors.add("notAuthorized", new ActionError("error.exception.notAuthorized2"));        } catch (FenixServiceException e) {            if (e.getMessage().equals("error.invalidExecutionDegree")) {                errors.add("invalidExecutionDegree", new ActionError("error.invalidExecutionDegree"));            } else if (e.getMessage().equals("error.impossibleDegreeInfo")) {                errors.add("impossibleDegreeInfo", new ActionError("error.impossibleDegreeInfo"));            } else {                e.printStackTrace();                throw new FenixActionException(e);            }        }        if (!errors.isEmpty()) {            saveErrors(request, errors);            return (new ActionForward(mapping.getInput()));        }        DynaActionForm degreeInfoForm = (DynaActionForm) form;        fillForm(infoDegreeInfo, degreeInfoForm);        return mapping.findForward("viewInformation");    }