SkhfkMydShow.java
上传用户:quasar007
上传日期:2022-08-11
资源大小:4067k
文件大小:1k
源码类别:

企业管理

开发平台:

Java

  1. package com.webtier.skhfkAction;
  2. import com.tool.Chinese;
  3. import org.apache.struts.action.*;
  4. import javax.servlet.http.*;
  5. import com.domain.SkhfkForm;
  6. import com.service.SkhfkFacade;
  7. import com.service.SkhfkFacadeImpl;
  8. import com.service.CkhmydFacade;
  9. import com.service.CkhmydFacadeImpl;
  10. import java.util.List;
  11. import com.domain.CkhmydForm;
  12. //把满意程度传的sql语句中,去查询有多少条记录和查出有多少条记录
  13. public class SkhfkMydShow
  14.     extends Action {
  15.   private SkhfkFacade facade = null;
  16.   private CkhmydFacade khmyd = null;
  17.   public SkhfkMydShow() {
  18.     this.facade = new SkhfkFacadeImpl();
  19.     this.khmyd = new CkhmydFacadeImpl();
  20.   }
  21.   public ActionForward perform(ActionMapping actionMapping,
  22.                                ActionForm actionForm,
  23.                                HttpServletRequest httpServletRequest,
  24.                                HttpServletResponse httpServletResponse) {
  25.     SkhfkForm skhfkForm = (SkhfkForm) actionForm;
  26.     String count = String.valueOf(this.facade.skhfkCount()-1); //有多少条记录
  27.     httpServletRequest.setAttribute("count", count);
  28.     List listMyd = this.facade.skhfkMyd();
  29.     httpServletRequest.setAttribute("listMyd", listMyd); //指向的是满意程度表
  30.     return actionMapping.findForward("skhfkMydShow");
  31.   }
  32. }