Examples of CategoryRowMapper


Examples of com.jpoweredcart.common.entity.catalog.jdbc.CategoryRowMapper

    String sql = "SELECT DISTINCT *, (SELECT keyword FROM " +quoteTable("url_alias")
        + " WHERE query = ?) AS keyword FROM "
        + quoteTable("category")+" WHERE category_id = ?";
    CategoryForm catForm = (CategoryForm)getJdbcOperations().queryForObject(
        sql, new Object[]{"category_id="+catId, catId},
        new CategoryRowMapper(){
          @Override
          public Category mapRow(ResultSet rs, int rowNum)
              throws SQLException {
            CategoryForm form = (CategoryForm)super.mapRow(rs, rowNum);
            form.setKeyword(rs.getString("keyword"));
View Full Code Here

Examples of com.jpoweredcart.common.entity.catalog.jdbc.CategoryRowMapper

  @Override
  public Category get(Integer catId, Class<? extends Category> clazz) {
   
    String sql = "SELECT * FROM " + quoteTable("category")+" WHERE category_id = ?";
    Category cat = getJdbcOperations().queryForObject(sql,
        new Object[]{catId}, new CategoryRowMapper().setTargetClass(clazz));
    return cat;
  }
View Full Code Here

Examples of com.jpoweredcart.common.entity.catalog.jdbc.CategoryRowMapper

      +" cd ON (c.category_id = cd.category_id) WHERE cd.language_id = ? ORDER BY c.sort_order, cd.name ASC";
    QueryBean query = createPaginationQuery(sql, pageParam);
    query.addParameters(languageId);
   
    List<Category> catList = getJdbcOperations().query(query.getSql(),
        query.getParameters(), new CategoryRowMapper(){
      @Override
      public Category mapRow(ResultSet rs, int rowNum)
          throws SQLException {
        Category cat = super.mapRow(rs, rowNum);
        cat.setName(getPath(cat.getId(), separator));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.