Browse Source

Move MaxLength of currency to consts file

pull/69/head
enisn 5 years ago
parent
commit
972d1bbd47
  1. 2
      modules/payment/src/Payment.Application.Contracts/PaymentRequests/PaymentRequestCreationDto.cs
  2. 1
      modules/payment/src/Payment.Domain.Shared/PaymentRequests/PaymentRequestConsts.cs

2
modules/payment/src/Payment.Application.Contracts/PaymentRequests/PaymentRequestCreationDto.cs

@ -25,7 +25,7 @@ namespace Payment.PaymentRequests
/// 3 Letter Language Code in ISO 4217 Standards.
/// For example: USD, EUR.
/// </summary>
[StringLength(3)]
[StringLength(PaymentRequestConsts.MaxCurrencyLength)]
[CanBeNull]
public string Currency { get; set; }
}

1
modules/payment/src/Payment.Domain.Shared/PaymentRequests/PaymentRequestConsts.cs

@ -2,6 +2,7 @@
{
public static class PaymentRequestConsts
{
public const int MaxCurrencyLength = 100;
public static int MaxCustomerIdLength { get; set; } = 100;
public static int MaxProductIdLength { get; set; } = 100;
public static int MaxProductNameLength { get; set; } = 200;

Loading…
Cancel
Save