Ejemplo n.º 1
0
 public void Update(Spectacle spectacle)
 {
     var dbEntity = mContext.Spectacles.Find(spectacle.Id);
     if (dbEntity != null)
         mContext.Entry(dbEntity).CurrentValues.SetValues(spectacle);
 }
Ejemplo n.º 2
0
 public void Add(Spectacle spectacle)
 {
     spectacle.Id = Guid.NewGuid();
     mContext.Spectacles.Add(spectacle);
 }