예제 #1
0
 public static IList<BlogModel> RetrieveBlogs(BlogContext context)
 {
     return context.Blogs.ToList();
 }
예제 #2
0
 public static BlogModel RetrieveBlogById(BlogContext context, int id)
 {
     return context.Blogs.Where(x => x.Id == id).FirstOrDefault();
 }