20 lines
560 B
C#
20 lines
560 B
C#
namespace SimpleWiki.Models;
|
|
|
|
public class User
|
|
{
|
|
public int Id { get; set; }
|
|
public string FullName { get; set; } = string.Empty;
|
|
public string Email { get; set; } = string.Empty;
|
|
public string PasswordHash { get; set; } = string.Empty;
|
|
public string Role { get; set; } = Roles.User;
|
|
public DateTime CreatedAt { get; set; } = DateTime.UtcNow;
|
|
|
|
public ICollection<Article> Articles { get; set; } = new List<Article>();
|
|
}
|
|
|
|
public static class Roles
|
|
{
|
|
public const string Admin = "Admin";
|
|
public const string User = "User";
|
|
}
|