コード例 #1
0
        public ActionResult Preview(int id)
        {
            var newsPostViewModel = NewsPostHelper.GetNewsPostViewModelById(id, 1, User.IsInRole(Roles.Moderator.ToString()));

            return(View("Details", newsPostViewModel));
        }
コード例 #2
0
        public ActionResult Details(int id, int?page)
        {
            var newsPostViewModel = NewsPostHelper.GetNewsPostViewModelById(id, page ?? 1, User.IsInRole(Roles.Moderator.ToString()), true);

            return(View(newsPostViewModel));
        }