public void Rename(int ID, string name) { Session session = Get(ID); session.Name = name; _db.Entry(session).State = System.Data.Entity.EntityState.Modified; _db.SaveChanges(); }
public Character Edit(DTO.Character character) { Character domainCharacter = Get(character.ID); CharacterConverter.MapDTOToDomain(character, domainCharacter); _db.Entry(domainCharacter).State = System.Data.Entity.EntityState.Modified; _db.SaveChanges(); return(domainCharacter); }