try
This commit is contained in:
@@ -1,16 +1,26 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
// src/Webshop.Application/DTOs/Customers/UpdateCustomerProfileDto.cs
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace Webshop.Application.DTOs.Customers
|
||||
{
|
||||
public class UpdateCustomerProfileDto
|
||||
{
|
||||
[Required(ErrorMessage = "Vorname ist erforderlich.")]
|
||||
[MaxLength(100)]
|
||||
[StringLength(100)]
|
||||
public string FirstName { get; set; } = string.Empty;
|
||||
|
||||
[Required(ErrorMessage = "Nachname ist erforderlich.")]
|
||||
[MaxLength(100)]
|
||||
[StringLength(100)]
|
||||
public string LastName { get; set; } = string.Empty;
|
||||
|
||||
|
||||
[Phone(ErrorMessage = "Ungültiges Telefonnummernformat.")]
|
||||
public string? PhoneNumber { get; set; } // Telefonnummer des Benutzers
|
||||
|
||||
[EmailAddress(ErrorMessage = "Ungültiges E-Mail-Format.")]
|
||||
public string? Email { get; set; } // E-Mail des Benutzers
|
||||
|
||||
// Optional, aber gute Sicherheitspraxis: Aktuelles Passwort zur Bestätigung sensibler Änderungen
|
||||
[Required(ErrorMessage = "Aktuelles Passwort ist zur Bestätigung erforderlich.")]
|
||||
public string CurrentPassword { get; set; } = string.Empty;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user