Example #1
0
  /**
   * 用户基本信息管理导出excel
   *
   * @return [参数说明]
   * @return String [返回类型说明]
   * @exception throws [违例类型] [违例说明]
   * @see [类、类#方法、类#成员]
   */
  @SuppressWarnings("unchecked")
  public String exportUserInfo() {
    pageBean.pageNum = 1;
    String ids = request().getParameter("ids"); // id拼接 用,隔开
    pageBean.setPageSize(100000);
    try {
      String username = Convert.strToStr(request().getParameter("userName"), null);
      if (StringUtils.isNotBlank(username)) {
        username = URLDecoder.decode(username, "UTF-8"); // 中文乱码转换
      }

      // 根据选中ID查询用户列表
      // userManageServic.queryUserList(pageBean,ids);
      userManageServic.queryUserManageBaseInfo_id(pageBean, ids);
      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      } // 序号 用户名 真实姓名 手机号码 身份证 用户来源 注册时间 可用金额 冻结金额 待收金额
      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户注册管理列表",
              pageBean.getPage(),
              new String[] {
                "序号", "用户名", "真实姓名", "手机号码", "身份证", "用户来源", "注册时间", "可用金额", "冻结金额", "待收金额"
              },
              new String[] {
                "id",
                "username",
                "realName",
                "cellPhone",
                "idNo",
                "source",
                "createTime",
                "usableSum",
                "freezeSum",
                "dueinSum"
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "t_user", admin.getUserName(), IConstants.EXCEL, admin.getLastIP(), 0, "导出用户注册管理列表", 2);

    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }
Example #2
0
  /**
   * 导出用户积分明细信息
   *
   * @return
   */
  @SuppressWarnings("unchecked")
  public String exportuserintegralcreditinfo() {
    pageBean.pageNum = 1;
    pageBean.setPageSize(100000);
    Long userId = Convert.strToLong(request("userId"), -1L);
    Integer type = Convert.strToInt(request("type"), -1);

    try {

      // 待还款详情
      userManageServic.userintegralcreditinfo(pageBean, userId, type);
      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      }

      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户积分明细",
              pageBean.getPage(),
              new String[] {"用户名", "真实姓名", "积分类型", "备注", "变动类型", "变动分值", "操作时间"},
              new String[] {
                "username",
                "realName",
                "intergraltype",
                "remark",
                "changetype",
                "changerecore",
                "changtime"
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "v_t_userManage_integralinner",
          admin.getUserName(),
          IConstants.EXCEL,
          admin.getLastIP(),
          0,
          "导出用户积分明细",
          2);

    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }
Example #3
0
  /**
   * 导出用户积分信息
   *
   * @return
   */
  @SuppressWarnings("unchecked")
  public String exportintegralinfo() {
    pageBean.pageNum = 1;
    pageBean.setPageSize(100000);

    try {
      // 用户名
      String username =
          request().getParameter("username") == null ? "" : request().getParameter("username");
      username = URLDecoder.decode(username, "UTF-8");
      // 会员积分
      int viprecode = Convert.strToInt(request().getParameter("viprecode"), -1);
      // 用户积分排序
      int creditcode = Convert.strToInt(request().getParameter("creditcode"), -1);
      // 待还款详情
      userManageServic.queryUserManageintegralinfo(pageBean, username, viprecode, creditcode);
      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      }

      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户积分",
              pageBean.getPage(),
              new String[] {"用户名", "真是姓名", "信用积分", "会员积分", "最后调整时间"},
              new String[] {
                "username", "realName", "creditrating", "rating", "repayDate",
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "v_t_usermanage_integralinfo",
          admin.getUserName(),
          IConstants.EXCEL,
          admin.getLastIP(),
          0,
          "导出用户积分信息列表",
          2);

    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }
Example #4
0
  /**
   * 用户注册管理导出excel
   *
   * @return [参数说明]
   * @return String [返回类型说明]
   * @exception throws [违例类型] [违例说明]
   * @see [类、类#方法、类#成员]
   */
  @SuppressWarnings("unchecked")
  public String exportUserRegisterx() {
    pageBean.pageNum = 1;
    String ids = request().getParameter("ids"); // id拼接 用,隔开
    pageBean.setPageSize(100000);
    try {
      String username = Convert.strToStr(request().getParameter("userName"), null);
      if (StringUtils.isNotBlank(username)) {
        username = URLDecoder.decode(username, "UTF-8"); // 中文乱码转换
      }

      // 根据选中ID查询用户列表
      userManageServic.queryUserList(pageBean, ids);

      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      }
      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户注册管理列表",
              pageBean.getPage(),
              new String[] {"用户名", "手机号码", "推荐人", "客户来源", "注册时间", "注册IP", "最后登录时间"},
              new String[] {
                "username",
                "mobilePhone",
                "refferee",
                "source",
                "createTime",
                "registerIp",
                "lastDate"
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "t_user", admin.getUserName(), IConstants.EXCEL, admin.getLastIP(), 0, "导出用户注册管理列表", 2);

    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }
Example #5
0
  /**
   * 导出用户列表信息
   *
   * @return
   */
  @SuppressWarnings("unchecked")
  public String exportusermanageinfo() {
    pageBean.pageNum = 1;
    pageBean.setPageSize(100000);

    try {

      // 用户名
      String userName = SqlInfusion.FilteSqlInfusion(paramMap.get("userName"));
      String realName = SqlInfusion.FilteSqlInfusion(paramMap.get("realName"));
      // 待还款详情
      userManageServic.queryUserManageInfo(pageBean, userName, realName);
      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      }

      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户列表",
              pageBean.getPage(),
              new String[] {"用户名", "真是姓名", "邮箱", "QQ号码", "手机号码", "注册时间", "最后登录IP"},
              new String[] {
                "username", "realName", "email", "qq", "cellPhone", "createTime", "lastIP",
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "t_person", admin.getUserName(), IConstants.EXCEL, admin.getLastIP(), 0, "导出用户列表基本信息", 2);

    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }
Example #6
0
  /**
   * 导出用户列表信息
   *
   * @return
   */
  @SuppressWarnings("unchecked")
  public String exportuserInvestInfo() {
    pageBean.pageNum = 1;
    pageBean.setPageSize(100000);

    try {

      // 用户名
      Long uerId = Convert.strToLong(request().getParameter("i"), -1L);
      String createtimeStart = SqlInfusion.FilteSqlInfusion(paramMap.get("createtimeStart"));
      String createtimeEnd = SqlInfusion.FilteSqlInfusion(paramMap.get("createtimeEnd"));
      // 待还款详情
      userManageServic.queryUserManageInvest(pageBean, uerId, createtimeStart, createtimeEnd);
      if (pageBean.getPage() == null) {
        getOut().print("<script>alert(' 导出记录条数不能为空! ');window.history.go(-1);</script>");
        return null;
      }
      if (pageBean.getPage().size() > IConstants.EXCEL_MAX) {
        getOut().print("<script>alert(' 导出记录条数不能大于50000条 ');window.history.go(-1);</script>");
        return null;
      }

      userManageServic.changeFigure(pageBean);
      HSSFWorkbook wb =
          ExcelUtils.exportExcel(
              "用户投资信息列表",
              pageBean.getPage(),
              new String[] {"用户名", "真时姓名", "手机号码", "投资日期", "还款方式", "投资期限", "投资标题", "投资金额"},
              new String[] {
                "username",
                "realName",
                "cellPhone",
                "investTime",
                "paymentMode",
                "deadline",
                "borrowTitle",
                "investAmount",
              });
      this.export(wb, new Date().getTime() + ".xls");
      Admin admin = (Admin) session().getAttribute(IConstants.SESSION_ADMIN);
      operationLogService.addOperationLog(
          "v_t_userManage_invest",
          admin.getUserName(),
          IConstants.EXCEL,
          admin.getLastIP(),
          0,
          "导出用户投资信息列表",
          2);
    } catch (SQLException e) {

      e.printStackTrace();
    } catch (DataException e) {

      e.printStackTrace();
    } catch (IOException e) {

      e.printStackTrace();
    } catch (Exception e) {
      e.printStackTrace();
    }
    return null;
  }