Package com.dzidzi.dto.coupon
Class Coupon
java.lang.Object
com.dzidzi.dto.merge.EntityId
com.dzidzi.dto.coupon.CouponEntityApi
com.dzidzi.dto.coupon.Coupon
Represents a coupon of the api.
-
Constructor Summary
ConstructorsConstructorDescriptionCoupon(UUID id, String couponName, double percentage, BigDecimal couponAmount, String couponCode, String description, Date startDate, Date endDate, long createdOn, boolean active, CreatorEntity createdBy, long modifiedOn, CreatorEntity modifiedBy, CouponType couponType, List<UUID> restaurantsAppliedTo) -
Method Summary
Modifier and TypeMethodDescriptionThe coupon numberTheCouponType.TheCreatorEntityof the user who created the couponlongThe date and time the coupon was createdThe description of the couponThe end date of the couponTheCreatorEntityof the user who modified the couponlongThe date and time modifiedThe restaurantIds this coupon is applied to.The start date of the couponbooleanisActive()The validity of the couponvoidsetCreatedBy(CreatorEntity createdBy) TheCreatorEntityof the user who created the couponvoidsetModifiedBy(CreatorEntity modifiedBy) TheCreatorEntityof the user who modified the couponvoidsetRestaurantsAppliedTo(List<UUID> restaurantsAppliedTo) The restaurantIds this coupon is applied to.Methods inherited from class com.dzidzi.dto.coupon.CouponEntityApi
getCouponAmount, getCouponName, getPercentage
-
Constructor Details
-
Coupon
public Coupon(UUID id, String couponName, double percentage, BigDecimal couponAmount, String couponCode, String description, Date startDate, Date endDate, long createdOn, boolean active, CreatorEntity createdBy, long modifiedOn, CreatorEntity modifiedBy, CouponType couponType, List<UUID> restaurantsAppliedTo)
-
-
Method Details
-
getCouponCode
The coupon number -
getDescription
The description of the coupon -
getStartDate
The start date of the coupon -
getEndDate
The end date of the coupon -
getCreatedOn
public long getCreatedOn()The date and time the coupon was created -
isActive
public boolean isActive()The validity of the coupon -
getCreatedBy
TheCreatorEntityof the user who created the coupon -
getModifiedOn
public long getModifiedOn()The date and time modified -
getModifiedBy
TheCreatorEntityof the user who modified the coupon -
getCouponType
TheCouponType. -
getRestaurantsAppliedTo
The restaurantIds this coupon is applied to. -
setCreatedBy
TheCreatorEntityof the user who created the coupon -
setModifiedBy
TheCreatorEntityof the user who modified the coupon -
setRestaurantsAppliedTo
The restaurantIds this coupon is applied to.
-