⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rwglyblbmbean.java

📁 以前做的一个j2ee的项目
💻 JAVA
字号:
package gov.gdlt.ssgly.taxweb.mbean.rwgl;

import java.util.*;

import gov.gdlt.ssgly.taxcore.comm.bizdelegate.*;
import gov.gdlt.ssgly.taxcore.comm.bizinterface.*;
import gov.gdlt.ssgly.taxcore.comm.log.*;
import gov.gdlt.ssgly.taxcore.taxevent.rwgl.*;
import gov.gdlt.ssgly.taxweb.tag.*;
import gov.gdlt.ssgly.taxweb.comm.util.WebUtil;

/**
 * <p>Title: 查看待办任务mBean</p>
 *
 * <p>Description: 广东地税税收管理员工作平台</p>
 *
 * <p>Copyright: Copyright (c) 2005 广东省地方税务局,广州市地方税务局</p>
 *
 * <p>Company: 广州地税</p>
 *
 * @author 王隽
 * @version 1.0
 */
public class RWGLyblbMBean extends PagedBaseBean {
    private ArrayList rwlbVO;
    private String swry_dm;
    private String lblx;
    private String gjz;
    public RWGLyblbMBean() {
        lblx = "yblb";//指定列表类型
        swry_dm = (String) WebUtil.eval("#{user.userID}");
        LogWritter.sysDebug("MBean for yblb created! swry=" + swry_dm);
        //获取列表数据,不再使用此方法获取列表数据
        //this.getRwlb(lblx);
    }

    public void setRwlbVO(ArrayList rwlbVO) {
        this.rwlbVO = rwlbVO;
    }

    public void setLblx(String lblx) {
        this.lblx = lblx;
    }

    public void setGjz(String gjz) {
        this.gjz = gjz;
    }

    public ArrayList getRwlbVO() {
        return this.rwlbVO;
    }

    public String getLblx() {
        return lblx;
    }

    public String getGjz() {
        return gjz;
    }

    /**
     * 获取列表内容,因分页显示列表已停止使用
     * @param lb_lx String \u2014\u2014列表类型
     * @return String
     */
    private String getRwlb(String lb_lx) {
//        //创建RequestEvent
//        RWGLckrwReqEvent req = new RWGLckrwReqEvent();
//        req.setLb_lx(lb_lx);
//        req.setSwry_dm(swry_dm);
//        req.setDealMethod("getRwlb");
//        //调用代理方法
//        ISsglyService service = new SsglyDelegate();
//        ResponseEvent resp = service.invokeTask(req);
//        //处理ResponseEvent
//        RWGLckrwResEvent ssglyRes = (RWGLckrwResEvent) resp;
//        setRwlbVO(ssglyRes.getRwlbVO());
        return "success";
    }

    /**
     * 收回已发出的任务
     * @return String
     */
    public String pullBack(){
        LogWritter.sysDebug("begin unsign");
        if (rwlbVO != null) {
            LogWritter.sysDebug("rwlbVO is not null");
            int n = rwlbVO.size();
            LogWritter.sysDebug("data has " + rwlbVO.size() + " rows");
            RWGLrwlbVO cur_rwlb;
            RWGLckrwReqEvent req = new RWGLckrwReqEvent();
            ISsglyService service = new SsglyDelegate();
            RWGLckrwResEvent ssglyRes;
            req.setDealMethod("pullBack");
            req.setSwry_dm(swry_dm);
            //逐行数据检查
            for (int i = 0; i < n; i++) {
                cur_rwlb = (RWGLrwlbVO) rwlbVO.get(i);
                //对于选择的行,进行收回
                if (cur_rwlb.isChecked()) {
                    req.setRw_xh(cur_rwlb.getRw_xh());
                    LogWritter.sysDebug("pulling back " + cur_rwlb.getRw_xh() +
                                        " by " + swry_dm);
                    try{
                        ssglyRes = (RWGLckrwResEvent) service.invokeTask(req);
                    }catch (Exception e){
                        e.printStackTrace();
                    }
                }
            }
        } else {
            LogWritter.sysDebug("rwlbVO is null");
        }
        //清空分页列表的内容,以便重新获取
        objectList = Collections.synchronizedList(new ArrayList());
        //getContentList();
        //this.getRwlb(lblx);
        return "success";
    }

    /**
     * 实现分页列表抽象方法,获取某页数据
     * @param currentPage int
     * @throws Exception
     */
    protected void refreshObjectList(int currentPage) throws Exception{
         LogWritter.sysDebug("------------refreshObjectList-----------------");
         String tempGJZ = WebUtil.getParameterFromContextMap("gjz");
        if ("重要".equals(tempGJZ)) {
            tempGJZ = "zhongyao";
        } else if ("一般".equals(tempGJZ)) {
            tempGJZ = "yiban";
        }
        if (tempGJZ == null || "".equals(tempGJZ)) {
            rwlbVO=(ArrayList) getSplitTable("T_RWGL_RWJL.getYblb",swry_dm,20,currentPage);
        } else {
            HashMap ha = new HashMap();
            ha.put("swry_dm", swry_dm);
            ha.put("rwms", tempGJZ);
            ha.put("yxj", tempGJZ.trim());
            ha.put("rwlx", tempGJZ);
            ha.put("rwxl", tempGJZ);
            ha.put("blfs", tempGJZ);
            ha.put("rwxd", tempGJZ);
            ha.put("fssj", tempGJZ);
            ha.put("jsz", tempGJZ);
	        ha.put("nsrbm", tempGJZ);
            rwlbVO = (ArrayList) getSplitTable("T_RWGL_RWJL.getYblbBygjz",
                                               ha, 20, currentPage);
        }
        if ("zhongyao".equals(tempGJZ)) {
            tempGJZ = "重要";
        } else if ("yiban".equals(tempGJZ)) {
            tempGJZ = "一般";
        }

        gjz = tempGJZ;


            //this.totalPageCount= MathTotal("T_DM_GZRZ_SXJB.selectAllSxCount", null, 10);

     }

     /**
      * 实现分页列表抽象方法,获取列表总行数
      * @throws Exception
      */
     protected void getTotalPage() throws Exception{
         //使用count时,执行MathTotalasCount,如果没有count,则使用MathTotal
         LogWritter.sysDebug("------------getTotalPage-----------------");
         String tempGJZ = WebUtil.getParameterFromContextMap("gjz");
           if ("重要".equals(tempGJZ)) {
               tempGJZ = "zhongyao";
           } else if ("一般".equals(tempGJZ)) {
               tempGJZ = "yiban";
           }
           if (tempGJZ == null || "".equals(tempGJZ)) {
               this.totalPageCount= MathTotal("T_RWGL_RWJL.getYblb",swry_dm,20);
           } else {
               HashMap ha = new HashMap();
               ha.put("swry_dm", swry_dm);
               ha.put("rwms", tempGJZ);
               ha.put("yxj", tempGJZ.trim());
               ha.put("rwlx", tempGJZ);
               ha.put("rwxl", tempGJZ);
               ha.put("blfs", tempGJZ);
               ha.put("rwxd", tempGJZ);
               ha.put("fssj", tempGJZ);
               ha.put("jsz", tempGJZ);
			   ha.put("nsrbm", tempGJZ);
               this.totalPageCount= MathTotalAsCount("T_RWGL_RWJL.getYblbBygjzAsCOUNT",ha,20);
           }


     }

     //实现抽象方法
     protected void runExtraRoutine() {
     }

     //实现排序的抽象方法
    protected void sort(final String column, final boolean ascending) {

    }
}

⌨️ 快捷键说明

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