public bool Remove(SectorTO entity) { if (entity is null) { throw new ArgumentNullException(nameof(entity)); } return(Remove(entity.SectorId)); }
public SectorTO Add(SectorTO Entity) { if (Entity is null) { throw new ArgumentNullException(nameof(Entity)); } var sector = Entity.ToEF(); return(issuesContext.Sectors.Add(sector).Entity.ToTransfertObject()); }
public static SectorEF ToEF(this SectorTO issue) { if (issue is null) { throw new ArgumentNullException(nameof(issue)); } return(new SectorEF { SectorId = issue.SectorId, Name = issue.Name }); }
public SectorTO Update(SectorTO Entity) { if (Entity is null) { throw new ArgumentNullException(nameof(Entity)); } return(issuesContext .Sectors .Update(Entity.ToEF()) .Entity .ToTransfertObject()); }