using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; using System.Runtime.Serialization; namespace MAX.Models { public class User { public enum UserLevel { Unknown = 0, Administrator = 4, CustomUser = 6 } [DatabaseGenerated(DatabaseGeneratedOption.None)] public int Id { get; set; } [Required, MaxLength(50)] public string Username { get; set; } [Required, MaxLength(50)] public string FirstName { get; set; } [Required, MaxLength(50)] public string Surname { get; set; } [IgnoreDataMember] public int AccountId { get; set; } public Account Account { get; set; } public bool Enabled { get; set; } public UserLevel Level { get; set; } public int System { get; set; } public DateTimeOffset LastLogin { get; set; } public bool CanPrintOnline { get; set; } public decimal OnlinePrintValue { get; set; } public bool CanReprintOnline { get; set; } public decimal OnlineReprintValue { get; set; } public bool CanPrintOffline { get; set; } public decimal OfflinePrintValue { get; set; } public bool CanReprintOffline { get; set; } public decimal OfflineReprintValue { get; set; } } }