Beispiel #1
0
 private void DropExecutions()
 {
     using (var repo = new NHGetAllRepository <EventExecution>())
     {
         repo.Delete(x => x.Event == null);
     }
 }
Beispiel #2
0
 public static Y GetAnotherEntity <Y>(long id) where Y : Entity
 {
     using (var repo = new NHGetAllRepository <Y>())
     {
         return(repo.Get(id));
     }
 }
Beispiel #3
0
 private void DropPurchases()
 {
     using (var repo = new NHGetAllRepository <Purchase>())
     {
         repo.Delete(x => x.Event == null);
     }
 }
Beispiel #4
0
 public static IEnumerable <Y> GetAnotherEntity <Y>(IEnumerable <long> ids) where Y : Entity
 {
     using (var repo = new NHGetAllRepository <Y>())
     {
         return(repo.GetAll(ids));
     }
 }
Beispiel #5
0
        public void Delete(long id)
        {
            using (var repo = new NHGetAllRepository <EventExecution>())
            {
                repo.Delete(x => x.Event.Id == id);
            }

            base.Delete(id);
        }