public ActionResult Comment(int?PostId) { BlogPostModel post; if (PostId == null) { post = new BlogPostModel(); } else { post = CMSService.GetPost((int)PostId); } return(View(post)); }
public ActionResult Create(int Id) { BlogPostModel post = new BlogPostModel(); if (Id == 0) { post = new BlogPostModel(); } else { post = CMSService.GetPost(Id); } return(View(post)); }
public ActionResult GetPost(int?Id) { //BlogPostModel post = CMSService.GetPost(Id); return(Json(CMSService.GetPost((int)Id), JsonRequestBehavior.AllowGet)); }