public void EditProduct(Product p) { _db.Entry(p).State = System.Data.Entity.EntityState.Modified; _db.SaveChanges(); }