// Getting all the coupons
  @Override
  public CouponsList getalltheCoupons(ServiceExecutionContext ctx) throws ExecException {
    CouponsList coupons = new CouponsList();
    try {

      List<Coupon> allCoupons = new ArrayList<Coupon>();
      List<CouponDetails> mycoupons = new ArrayList<CouponDetails>();
      // getting all th coupons in the DB
      allCoupons = couponDAO.getListOfAllCoupenDetails();

      for (Coupon couponDetails : allCoupons) {
        CouponDetails newCoupons = new CouponDetails();
        newCoupons.setCoupon(couponDetails.getCoupenName());
        newCoupons.setFromDate(couponDetails.getValidFrom());
        newCoupons.setToDate(couponDetails.getValidTo());
        newCoupons.setDiscount(couponDetails.getDiscount());
        mycoupons.add(newCoupons);
      }
      coupons.setlistOfCoupons(mycoupons);

    } catch (ExecException m) {
      logger.error("Error while getting the coupen" + m.getMessage());
      throw m;
    } catch (Exception e) {
      logger.error("Error while getting the coupen" + e.getMessage());
      throw new ExecException(ErrorCodes.APPLICATION_ERROR, e, e.getMessage());
    }
    return coupons;
  }