addemployeetodeptaction.java
来自「系统项目的一部分 开发工具:JBuilder X. 数据库:mysql. 」· Java 代码 · 共 26 行
JAVA
26 行
package com.jspdev.ch17;import org.apache.struts.action.*;import javax.servlet.http.*;public final class AddEmployeeToDeptAction extends Action { public ActionForward execute(ActionMapping actionMapping, ActionForm actionForm, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { /**@todo: complete the business logic here, this is just a skeleton.*/ DynaActionForm f = (DynaActionForm) actionForm; String employId=(String)f.get("employId"); String deptId=(String)f.get("deptId"); try { EmployeeBean bean=new EmployeeBean(); bean.resetEmploy(employId,deptId); } catch(Exception e) { e.printStackTrace(); } //return httpServletRequest.setAttribute("deptId",deptId); return(actionMapping.findForward("success")); }}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?