using Microsoft.EntityFrameworkCore;
using PARR.DAL.Context;
using PARR.DAL.Contracts;
using PARR.DAL.Models.Base;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace PARR.DAL.Models.Job
{
    [Table("GroupTypes", Schema = DataContextSettings.Job)]
    [Comment("Таблица типов групп работ")]
    public class JobGroupType : IBase
    {
        [Key]
        public Guid Id { get; set; }

        public DateTimeOffset DateCreated { get; set; }

        [NotMapped]
        public DateTimeOffset? DateModified { get; set; }

        public required JobGroupTypesEnum Code { get; set; }

        public required string Name { get; set; }

        public required string Description { get; set; }

        public ICollection<JobGroup> JobGroups { get; set; } = new HashSet<JobGroup>();
    }
}
