/*
 * Generated by MyEclipse Struts
 * Template path: templates/java/JavaClass.vtl
 */
package com.yuntong.action.ajaxaction;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
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 com.yuntong.service.Y_ISplitRegister;

/** 
 * MyEclipse Struts
 * Creation date: 04-09-2007
 * 根据货票编号删除货票（未估货票）
 * XDoclet definition:
 * @struts.action validate="true"
 */
public class Y_deleteRegisterByIDAction extends Action {
	private  Log log = LogFactory.getLog(Y_deleteRegisterByIDAction.class);
	private Y_ISplitRegister splitRegister;
	
	public Y_ISplitRegister getSplitRegister() {
		return splitRegister;
	}

	public void setSplitRegister(Y_ISplitRegister splitRegister) {
		this.splitRegister = splitRegister;
	}

	public ActionForward execute(ActionMapping mapping, ActionForm form,
			HttpServletRequest request, HttpServletResponse response) {
		//得到编号
		String strRid=request.getParameter("rid");
		log.info("删除编号为"+strRid+"的记录=============");
		int rid=Integer.parseInt(strRid);
		//删除信息
		splitRegister.deleteRegisterByID(rid);
		log.info("删除成功返回ajaxaction");
		return null;
	}
}