Exemplo n.º 1
0
 public void Add(Car entity)
 {
     using (ReCapDatabaseContext context = new ReCapDatabaseContext())
     {
         var addedEntity = context.Entry(entity);
         addedEntity.State = EntityState.Added;
         context.SaveChanges();
     }
 }