Ejemplo n.º 1
0
 public List <Clubs> Club_List()
 {
     using (var context = new StarTedContext())
     {
         return(context.Clubs.ToList());
     }
 }
Ejemplo n.º 2
0
 // Use this class to help us with CRUD maintenance of our database
 public List <Course> ListCourses()
 {
     // Make use of our "virtual database" class to get the data
     using (var context = new StarTedContext())
     {
         return(context.Courses.ToList());
     }
 }
Ejemplo n.º 3
0
 public List <Clubs> ClubActivities_FindByClub(string ClubID)
 {
     using (var context = new StarTedContext())
     {
         IEnumerable <Clubs> results =
             context.Database.SqlQuery <Clubs>("ClubActivities_FindByClub @ClubID", ClubID);
         return(results.ToList());
     }
 }