Subversion Repositories bacoAlunos

Rev

Rev 1312 | Rev 1487 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1312 Rev 1486
Line 75... Line 75...
75
        CourseView cV = (CourseView) sm.execute(RequestUtils.getRequester(request, response), serviceName, args, names);
75
        CourseView cV = (CourseView) sm.execute(RequestUtils.getRequester(request, response), serviceName, args, names);
76
        request.setAttribute("CourseView",cV);
76
        request.setAttribute("CourseView",cV);
77
        cF.setCourseView(cV);
77
        cF.setCourseView(cV);
78
    }
78
    }
79
 
79
 
-
 
80
    private void loadForPublic(CourseForm cF, HttpServletRequest request, HttpServletResponse response)
-
 
81
            throws 1.5.0/docs/api/java/lang/Throwable.html">Throwable, InvalidFilterException, ServiceManagerException, InvalidFilterExpressionException, IncompatibleFilterException, FilterRetrieveException, NoCookiesException
-
 
82
    {
-
 
83
        1.5.0/docs/api/java/lang/String.html">String code = cF.getCourseView().getCode();
-
 
84
        long id = cF.getCourseView().getId();
-
 
85
 
-
 
86
        IServiceManager sm = ServiceManager.getInstance();
-
 
87
        1.5.0/docs/api/java/lang/String.html">String[] names = new 1.5.0/docs/api/java/lang/String.html">String[]{"serializable"};
-
 
88
        5+0%2Fdocs%2Fapi+Object">Object[] args;
-
 
89
        1.5.0/docs/api/java/lang/String.html">String serviceName;
-
 
90
        if(code != null)
-
 
91
        {
-
 
92
            args = new 5+0%2Fdocs%2Fapi+Object">Object[]{code,false};
-
 
93
            serviceName = "LoadCourseByCode";
-
 
94
        }
-
 
95
        else
-
 
96
        {
-
 
97
            args = new 5+0%2Fdocs%2Fapi+Object">Object[]{id,true};
-
 
98
            serviceName = "LoadCourse";
-
 
99
        }
-
 
100
        CourseView cV = (CourseView) sm.execute(RequestUtils.getRequester(request, response), serviceName, args, names);
-
 
101
        request.setAttribute("CourseView",cV);
-
 
102
        cF.setCourseView(cV);
-
 
103
    }
-
 
104
 
80
    public ActionForward loadPlan(ActionMapping mapping,
105
    public ActionForward loadPlan(ActionMapping mapping,
81
                              ActionForm form,
106
                              ActionForm form,
82
                              HttpServletRequest request,
107
                              HttpServletRequest request,
83
                              HttpServletResponse response)
108
                              HttpServletResponse response)
84
            throws ServletException
109
            throws ServletException
Line 136... Line 161...
136
                              HttpServletResponse response)
161
                              HttpServletResponse response)
137
            throws ServletException
162
            throws ServletException
138
    {
163
    {
139
        try
164
        try
140
        {
165
        {
141
            load((CourseForm) form,request,response);
166
            loadForPublic((CourseForm) form,request,response);
142
            return mapping.findForward("loadSeparators");
167
            return mapping.findForward("loadSeparators");
143
        }
168
        }
144
        catch (FilterChainFailedException e)
169
        catch (FilterChainFailedException e)
145
        {
170
        {
146
            return mapping.findForward("error401");
171
            return mapping.findForward("error401");