44 lines
1.1 KiB
C#
44 lines
1.1 KiB
C#
namespace NetinaShop.Domain.CommandQueries.Commands;
|
|
|
|
public sealed record CreateDiscountCommand(string Code,
|
|
int DiscountPercent,
|
|
long DiscountAmount,
|
|
bool HasCode,
|
|
DiscountAmountType AmountType,
|
|
DiscountType Type,
|
|
int Count,
|
|
DateTime StartDate,
|
|
DateTime ExpireDate,
|
|
long PriceFloor,
|
|
bool HasPriceFloor,
|
|
long PriceCeiling,
|
|
bool HasPriceCeiling,
|
|
bool IsInfinity,
|
|
long UseCount,
|
|
bool IsForInvitation,
|
|
Guid ProductId,
|
|
Guid CategoryId) : IRequest<DiscountLDto>;
|
|
|
|
public sealed record UpdateDiscountCommand(Guid Id,
|
|
string Code,
|
|
int DiscountPercent,
|
|
long DiscountAmount,
|
|
bool HasCode,
|
|
DiscountAmountType AmountType,
|
|
DiscountType Type,
|
|
int Count,
|
|
DateTime StartDate,
|
|
DateTime ExpireDate,
|
|
long PriceFloor,
|
|
bool HasPriceFloor,
|
|
long PriceCeiling,
|
|
bool HasPriceCeiling,
|
|
bool IsInfinity,
|
|
long UseCount,
|
|
bool IsForInvitation,
|
|
Guid ProductId,
|
|
Guid CategoryId) : IRequest<bool>;
|
|
|
|
public sealed record DeleteDiscountCommand(Guid Id) : IRequest<bool>;
|
|
|
|
public sealed record CalculateDiscountCommand(string DiscountCode,Order Order) : IRequest<double>; |