Package com.dzidzi.dto.coupon
Class AddCouponRequest
java.lang.Object
com.dzidzi.dto.coupon.AddCouponRequest
AddCouponRequest represents the DTO request containing the objects used to create a new coupon.
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionAddCouponRequest(String couponName, String couponCode, Double percentage, BigDecimal couponAmount, String description, Date startDate, Date endDate, List<UUID> assignedToRestaurants, boolean forTest) Creates a newAddCouponRequestinstance. -
Method Summary
Modifier and TypeMethodDescriptionstatic AddCouponRequest.Builderbuilder()The restaurants to assign this coupon to, mostly used by restaurants with branches.The coupon amountThe coupon code.The coupon nameThe description of the couponThe end date of the couponThe coupon percentageThe start date of the couponboolean
-
Constructor Details
-
AddCouponRequest
public AddCouponRequest() -
AddCouponRequest
@ConstructorProperties({"couponName","couponCode","percentage","couponAmount","description","startDate","endDate","assignedToRestaurants","forTest"}) public AddCouponRequest(String couponName, String couponCode, Double percentage, BigDecimal couponAmount, String description, Date startDate, Date endDate, List<UUID> assignedToRestaurants, boolean forTest) Creates a newAddCouponRequestinstance.- Parameters:
couponName- The coupon namecouponCode- The coupon code. If no code is specified, the platform generates the code.percentage- The coupon percentagecouponAmount- The coupon amountdescription- The description of the couponstartDate- The start date of the couponendDate- The end date of the couponassignedToRestaurants- The restaurants to assign this coupon to, mostly used by restaurants with branches.forTest-
-
-
Method Details
-
builder
-
getCouponName
The coupon name -
getCouponCode
The coupon code. If no code is specified, the platform generates the code. -
getPercentage
The coupon percentage -
getCouponAmount
The coupon amount -
getDescription
The description of the coupon -
getStartDate
The start date of the coupon -
getEndDate
The end date of the coupon -
getAssignedToRestaurants
The restaurants to assign this coupon to, mostly used by restaurants with branches. -
isForTest
public boolean isForTest()
-