Package com.eatle.persistent.pojo.system.frontdata

Examples of com.eatle.persistent.pojo.system.frontdata.ServiceInformationCriteria$Criteria


  @Override
  public Pagination findPagination(Map<String, Object> queryMap,
      int currentPage, int pageSize)
  {
    ServiceInformationCriteria serviceInformationCriteria = new ServiceInformationCriteria();
    Criteria criteria = serviceInformationCriteria.createCriteria();
    // 设置搜索条件参数
    if (queryMap != null)
    {
      if (queryMap.containsKey("mobile"))
      {
        criteria.andServeMobileLike("%"+ (String) queryMap.get("mobile") + "%");
      }
      if (queryMap.containsKey("tel"))
      {
        criteria.andServeTelLike("%"+ (String) queryMap.get("tel") + "%");
      }
      if (queryMap.containsKey("qq"))
      {
        criteria.andServeQqLike("%"+ (String) queryMap.get("qq") + "%");
      }
      if (queryMap.containsKey("email"))
      {
        criteria.andServeEmailLike("%"+ (String) queryMap.get("email") + "%");
      }
    }
    // 设置分页参数
    serviceInformationCriteria.setPageSize(pageSize);
    serviceInformationCriteria.setStartIndex((currentPage - 1) * pageSize);
    List<ServiceInformation> items = serviceInformationMapper.selectByCriteria(serviceInformationCriteria);
    int totalCount = (int) serviceInformationMapper.selectCountByCriteria(serviceInformationCriteria);
    return new Pagination(pageSize, currentPage, totalCount, items);
  }
View Full Code Here

TOP

Related Classes of com.eatle.persistent.pojo.system.frontdata.ServiceInformationCriteria$Criteria

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.