public IActionResult Edit(int id) { var post = _servicoPost.GetById(id); HttpContext.Session.SetInt32("IdArquivo", post.FotoPost.Id); ViewBag.Usuarios = _servicoUsuario.Get(); ViewBag.CategoriasPost = _servicoCategoriaPost.Get(); return(View("Edit", post)); }
public IActionResult BlogPost(int postId) { var post = _servicePost.GetById(postId); return(View("BlogPost", post)); }