prinfsfzyselectfenye.java

来自「客户管理系统是一个典型的数据库开发应用程序」· Java 代码 · 共 44 行

JAVA
44
字号
package com.webtier.queryInformation;

import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionForm;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.Action;
import com.service.SfzyFacade;
import com.service.SfzyFacadeImpl;
import java.io.UnsupportedEncodingException;
import java.util.List;

public class PrinfSfzySelectFenYe
    extends Action {

  private SfzyFacade facade;
  public PrinfSfzySelectFenYe() {
    this.facade = new SfzyFacadeImpl();
  }

  public ActionForward perform(ActionMapping actionMapping,
                               ActionForm actionForm,
                               HttpServletRequest httpServletRequest,
                               HttpServletResponse httpServletResponse) throws
      UnsupportedEncodingException {
    httpServletRequest.setCharacterEncoding("gb2312");
    Integer iCount = Integer.valueOf(httpServletRequest.getParameter("iCount"));
    Integer iCount1=new Integer( (iCount.intValue() - 1) * 8);
    if (iCount1.intValue() > 0) {
      List list=this.facade.sfzyFenYe(iCount1);
      httpServletRequest.setAttribute("iCount", String.valueOf(iCount));
      httpServletRequest.setAttribute("total", String.valueOf(this.facade.toatl()));
      httpServletRequest.setAttribute("sfzylist",list);
      return actionMapping.findForward("prinfSfzySelectFenYeSuccess");
    }
    else {
      return actionMapping.findForward("prinfSfzySelectFenYeFail");
    }

  }

}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?