Beispiel #1
0
 public void Update(Directions directions)
 {
     using (var context = new ApplicationDbContext())
     {
         context.Entry(directions).State = EntityState.Modified;
         context.SaveChanges();
     }
 }
Beispiel #2
0
 public void Add(Directions directions)
 {
     using (var context = new ApplicationDbContext())
     {
         context.Direction.Add(directions);
         context.SaveChanges();
     }
 }