public void Delete(int entityId)
 {
     using (var context = _contextCreator())
     {
         _repository = new ConnectedRepository <ServiceAddress>(context);
         _repository.Delete(entityId);
     }
 }
示例#2
0
 public void Delete(int entityId)
 {
     using (var context = _contextCreator())
     {
         _repository = new ConnectedRepository <Customer>(context);
         _repository.Delete(entityId);
     }
 }
示例#3
0
 public ActionResult DeleteConfirmed(int id)
 {
     _repository.Delete(id);
     //ChlorineLevel chlorineLevel = db.ChlorineLevelSet.Find(id);
     //db.ChlorineLevelSet.Remove(chlorineLevel);
     //db.SaveChanges();
     return(RedirectToAction("Index"));
 }