public String scheme() throws WebDataException {
    AdminUser adminUser = getAdminUser();
    if (null == adminUser) {
      throw new WebDataException("你还没有登录!");
    }
    Class<S> cls = kenoService.getSchemeClass();
    if (queryForm != null) {
      if (StringUtils.isNotBlank(queryForm.getPeriodNumber()))
        criteria.add(Restrictions.eq("s.periodNumber", queryForm.getPeriodNumber()));

      if (queryForm.getState() != null)
        criteria.add(Restrictions.eq("s.state", queryForm.getState()));
      if (queryForm.getTicketState() != null)
        criteria.add(Restrictions.eq("s.schemePrintState", queryForm.getTicketState()));

      if (queryForm.getPrizeSended() != null)
        criteria.add(Restrictions.eq("s.cut", queryForm.getPrizeSended()));

      if (queryForm.getWon() != null) criteria.add(Restrictions.eq("s.won", queryForm.getWon()));

      if (StringUtils.isNotBlank(queryForm.getSponsorNames())) {
        String[] arr = queryForm.getSponsorNames().trim().split(",");
        if (arr.length == 1) {
          criteria.add(Restrictions.eq("s.sponsorName", arr[0]));
        } else if (arr.length == 2) {
          criteria.add(
              Restrictions.or(
                  Restrictions.eq("s.sponsorName", arr[0]),
                  Restrictions.eq("s.sponsorName", arr[1])));
        } else {
          criteria.add(Restrictions.in("s.sponsorName", arr));
        }
      }

      if (StringUtils.isNotBlank(queryForm.getSchemeNumbers())) {
        String[] arr = queryForm.getSchemeNumbers().trim().split(",");
        List<Long> idList = new ArrayList<Long>();
        for (String s : arr) {
          Long id = getLottery().getSchemeId(s);
          if (id != null) idList.add(id);
        }
        if (idList.size() == 1) {
          criteria.add(Restrictions.eq("s.id", idList.get(0)));
        } else if (idList.size() == 2) {
          criteria.add(
              Restrictions.or(
                  Restrictions.eq("s.id", idList.get(0)), Restrictions.eq("s.id", idList.get(1))));
        } else if (idList.size() > 2) {
          criteria.add(Restrictions.in("s.id", idList));
        }
      }
    }
    criteria.addOrder(Order.desc("s.id"));
    pagination = kenoService.findByCriteriaAndPagination(criteria, pagination);
    return "scheme";
  }
  /**
   * 追号管理
   *
   * @return
   * @throws WebDataException
   */
  public String chase() throws WebDataException {
    AdminUser adminUser = getAdminUser();
    if (null == adminUser) {
      throw new WebDataException("你还没有登录!");
    }
    //		Class<C> cls = kenoService.getChasePlanClass();
    XDetachedCriteria criteria = new XDetachedCriteria(ChasePlan.class, "s");
    if (queryForm != null) {
      if (StringUtils.isNotBlank(queryForm.getFirstPeriodNumber())) {
        I issueData = kenoService.findByIssueNumber(queryForm.getFirstPeriodNumber());
        if (issueData != null) {
          criteria.add(Restrictions.eq("s.firstPeriodId", issueData.getId()));
        }
      }

      if (queryForm.getChaseState() != null)
        criteria.add(Restrictions.eq("s.state", queryForm.getChaseState()));

      if (queryForm.getWon() != null) criteria.add(Restrictions.eq("s.won", queryForm.getWon()));

      if (queryForm.getWonStop() != null)
        criteria.add(Restrictions.eq("s.wonStop", queryForm.getWonStop()));

      if (StringUtils.isNotBlank(queryForm.getPeriodNumber())) {
        I issueData = kenoService.findByIssueNumber(queryForm.getPeriodNumber());
        if (issueData != null) {
          criteria.add(Restrictions.eq("s.curPeriodId", issueData.getId()));
        }
      }

      if (StringUtils.isNotBlank(queryForm.getSponsorNames())) {
        String[] arr = queryForm.getSponsorNames().trim().split(",");
        if (arr.length == 1) {
          criteria.add(Restrictions.eq("s.userName", arr[0]));
        } else if (arr.length == 2) {
          criteria.add(
              Restrictions.or(
                  Restrictions.eq("s.userName", arr[0]), Restrictions.eq("s.userName", arr[1])));
        } else {
          criteria.add(Restrictions.in("s.userName", arr));
        }
      }
    }
    pagination = kenoService.findByCriteriaAndPagination(criteria, pagination);
    return "chase";
  }