Examples of VoucherRowMapper


Examples of com.jpoweredcart.common.entity.sale.jdbc.VoucherRowMapper

  @Override
  public Voucher get(Integer voucherId, Class<? extends Voucher> clazz) {
    String sql = "SELECT * FROM " +quoteTable("voucher")+ " WHERE voucher_id = ?";
    return getJdbcOperations().queryForObject(sql, new Object[]{voucherId},
        new VoucherRowMapper().setTargetClass(clazz));
  }
View Full Code Here

Examples of com.jpoweredcart.common.entity.sale.jdbc.VoucherRowMapper

  }

  @Override
  public Voucher getOneByCode(String code) {
    String sql = "SELECT DISTINCT * FROM " +quoteTable("voucher")+ " WHERE code = ?";
    return getJdbcOperations().queryForObject(sql, new Object[]{code}, new VoucherRowMapper());
  }
View Full Code Here

Examples of com.jpoweredcart.common.entity.sale.jdbc.VoucherRowMapper

    Integer languageId = getSettingService().getConfig(SettingKey.ADMIN_LANGUAGE_ID, Integer.class);
    //sortedKeys={"v.code", "v.from_name", "v.from_email", "v.to_name", "v.to_email","v.theme", "v.amount", "v.status", "v.date_added"}
    QueryBean query = createPaginationQuery(sql, pageParam);
    query.addParameters(languageId);
    List<Voucher> vouchers = getJdbcOperations().query(query.getSql(),
        query.getParameters(), new VoucherRowMapper(){
          @Override
          public Voucher mapRow(ResultSet rs, Voucher object)
              throws SQLException {
            super.mapRow(rs, object);
            object.setTheme(rs.getString("theme"));
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.