using System.ComponentModel.DataAnnotations;

namespace WarehouseAppSHIPS.Models
{
    public class AppUser
    {
        [Key]
        public int Id { get; set; }

        [Required, MaxLength(50)]
        public string Username { get; set; } = string.Empty;

        [Required]
        public string PasswordHash { get; set; } = string.Empty;

        [Required, MaxLength(100)]
        public string FullName { get; set; } = string.Empty;

        [Required]
        public UserRole Role { get; set; }

        public virtual ICollection<InboundTransaction> InboundTransactions { get; set; } = new List<InboundTransaction>();
        public virtual ICollection<MaterialRequest> RequestsMade { get; set; } = new List<MaterialRequest>();
        public virtual ICollection<MaterialRequest> RequestsApproved { get; set; } = new List<MaterialRequest>();
        public virtual ICollection<StockOpname> StockOpnames { get; set; } = new List<StockOpname>();
        public virtual ICollection<ProcurementRequest> ProcurementRequests { get; set; } = new List<ProcurementRequest>();
    }
}