Ejemplo n.º 1
0
        public List <BlogDTO> GetAll()
        {
            List <Blog> blogs = _blogDAL.GetAll();

            List <BlogDTO> blogsDTO = new List <BlogDTO>();

            foreach (var blog in blogs)
            {
                blogsDTO.Add(BlogMapper(blog));
            }

            return(blogsDTO);
        }
Ejemplo n.º 2
0
 public List <Blog> GetAll()
 {
     return(_blogDal.GetAll().ToList());
 }
Ejemplo n.º 3
0
 public IActionResult AllBlogs()
 {
     return(View(bdb_Context.GetAll().Reverse().ToList()));
 }