Initial commit
This commit is contained in:
@@ -0,0 +1,72 @@
|
||||
using System.ComponentModel.DataAnnotations;
|
||||
|
||||
namespace PowderCoating.Application.DTOs.User;
|
||||
|
||||
public class UserProfileDto
|
||||
{
|
||||
public string Id { get; set; } = string.Empty;
|
||||
public string Email { get; set; } = string.Empty;
|
||||
public string FirstName { get; set; } = string.Empty;
|
||||
public string LastName { get; set; } = string.Empty;
|
||||
public string FullName { get; set; } = string.Empty;
|
||||
public string? Phone { get; set; }
|
||||
public string? Department { get; set; }
|
||||
public string? Position { get; set; }
|
||||
public string? EmployeeNumber { get; set; }
|
||||
public string? CompanyRole { get; set; }
|
||||
public string Theme { get; set; } = "light";
|
||||
public string SidebarColor { get; set; } = "ocean";
|
||||
public string DateFormat { get; set; } = "MM/dd/yyyy";
|
||||
public string? TimeZone { get; set; }
|
||||
public bool HasProfilePicture { get; set; }
|
||||
public DateTime HireDate { get; set; }
|
||||
public DateTime CreatedAt { get; set; }
|
||||
public DateTime? LastLoginDate { get; set; }
|
||||
}
|
||||
|
||||
public class UpdateProfileDto
|
||||
{
|
||||
[Required]
|
||||
[StringLength(100)]
|
||||
public string FirstName { get; set; } = string.Empty;
|
||||
|
||||
[Required]
|
||||
[StringLength(100)]
|
||||
public string LastName { get; set; } = string.Empty;
|
||||
|
||||
[Phone]
|
||||
public string? Phone { get; set; }
|
||||
}
|
||||
|
||||
public class ChangePasswordDto
|
||||
{
|
||||
[Required]
|
||||
public string CurrentPassword { get; set; } = string.Empty;
|
||||
|
||||
[Required]
|
||||
[StringLength(100, MinimumLength = 8)]
|
||||
public string NewPassword { get; set; } = string.Empty;
|
||||
|
||||
[Required]
|
||||
[Compare("NewPassword", ErrorMessage = "Passwords do not match.")]
|
||||
public string ConfirmPassword { get; set; } = string.Empty;
|
||||
}
|
||||
|
||||
public class UpdateEmailDto
|
||||
{
|
||||
[Required]
|
||||
[EmailAddress]
|
||||
[StringLength(200)]
|
||||
public string NewEmail { get; set; } = string.Empty;
|
||||
|
||||
[Required]
|
||||
public string CurrentPassword { get; set; } = string.Empty;
|
||||
}
|
||||
|
||||
public class UpdateAppearanceDto
|
||||
{
|
||||
public string Theme { get; set; } = "light";
|
||||
public string SidebarColor { get; set; } = "ocean";
|
||||
public string DateFormat { get; set; } = "MM/dd/yyyy";
|
||||
public string? TimeZone { get; set; }
|
||||
}
|
||||
Reference in New Issue
Block a user