📄 rfcupdateaction.java
字号:
/*
* Generated by MyEclipse Struts
* Template path: templates/java/JavaClass.vtl
*/
package org.mychange.struts.action;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.mychange.obj.Rfc;
import org.mychange.service.impl.RfcService;
import org.mychange.struts.form.RfcForm;
/**
* MyEclipse Struts
* Creation date: 07-09-2008
*
* XDoclet definition:
* @struts.action path="/rfcUpdate" name="rfcForm" input="/checkRFC.jsp" scope="request" validate="true"
*/
public class RfcUpdateAction extends Action {
/*
* Generated Methods
*/
/*Spring�������*/
// ChineseEncoding ce=new ChineseEncoding();
private RfcService rfcService;
public void setRfcService(RfcService rfcService) {
this.rfcService = rfcService;
}
public RfcService getRfcService() {
return rfcService;
}
/**
* Method execute
* @param mapping
* @param form
* @param request
* @param response
* @return ActionForward
*/
public ActionForward execute(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response) {
HttpSession session = request.getSession();
RfcForm rfcForm = (RfcForm) form;// TODO Auto-generated method stub
int id=rfcForm.getId();
String type=rfcForm.getType();
String des=rfcForm.getDescription();
String name=rfcForm.getRFCname();
String risk=rfcForm.getRisk();
String follower=rfcForm.getFollower();
String money = rfcForm.getMoney();
String people = rfcForm.getPeople();
String priority = rfcForm.getPriority();
String effection = rfcForm.getEffection();
String emergence = rfcForm.getEmergence();
String technology= rfcForm.getTechnology();
String launcher=rfcForm.getLauncher();
String upload=rfcForm.getUploadFile();
Rfc rfc = new Rfc();
rfc.setId(id);
rfc.setRfcname(name);
rfc.setTypes(type);
rfc.setRiskLevel(risk);
rfc.setSkillLevel(technology);
rfc.setDescription(des);
rfc.setEffectLevel(effection);
rfc.setInstancyLevel(emergence);
rfc.setCost(money);
rfc.setManpower(people);
rfc.setPriority(priority);
rfc.setEffectLevel(effection);
rfc.setAttachment(upload);
rfcService.updateRfc(rfc);
return mapping.findForward("updateSuccess");
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -