changecourseaction.java
来自「JAVA编写的远程教育程序,包含了教育学的基本思想和网络应用程序的基本开发模式」· Java 代码 · 共 32 行
JAVA
32 行
package com.whatratimes.webedu.teacher;
import org.apache.struts.action.*;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
/**
* User: Tao
* Date: Jun 13, 2003
* Time: 11:25:40 PM
*/
public class ChangeCourseAction extends Action
{
public ActionForward execute(ActionMapping actionMapping, ActionForm actionForm, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) throws Exception
{
HttpSession session = httpServletRequest.getSession();
DynaActionForm form = (DynaActionForm) actionForm;
Integer course_id = (Integer) form.get("CourseId");
DynaActionForm examForm = (DynaActionForm) session.getAttribute("ExamDetailForm");
examForm.set("CourseId", course_id);
examForm.set("ExamId", new Integer(0));
SetExamHelper.setExams(course_id, session);
return actionMapping.findForward("success");
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?