public void insert(Discount discount) {
   jdbcTemplate.update(
       discount.generateInsertQuery(),
       discount.getGoodsId(),
       discount.getStart(),
       discount.getEnd(),
       discount.getDiscount(),
       discount.getDescription(),
       discount.getCreatedDate(),
       discount.getCreatedBy(),
       discount.getUpdatedDate(),
       discount.getUpdatedBy());
 }
 public List<Discount> findAll() {
   return jdbcTemplate.query(SELECT_JOIN_GOODS, Discount.obtainRowMapper());
 }
 public Discount findById(String id) {
   return jdbcTemplate.queryForObject(
       SELECT_JOIN_GOODS_BY_ID, new Object[] {id}, Discount.obtainRowMapper());
 }
 public void delete(Discount discount) {
   jdbcTemplate.update(discount.generateDeleteQuery(), discount.getGoodsId());
 }