예제 #1
0
        public ActionResult Comment(int?PostId)
        {
            BlogPostModel post;

            if (PostId == null)
            {
                post = new BlogPostModel();
            }
            else
            {
                post = CMSService.GetPost((int)PostId);
            }

            return(View(post));
        }
예제 #2
0
        public ActionResult Create(int Id)
        {
            BlogPostModel post = new BlogPostModel();

            if (Id == 0)
            {
                post = new BlogPostModel();
            }
            else
            {
                post = CMSService.GetPost(Id);
            }

            return(View(post));
        }
예제 #3
0
        public ActionResult GetPost(int?Id)
        {
            //BlogPostModel post = CMSService.GetPost(Id);

            return(Json(CMSService.GetPost((int)Id), JsonRequestBehavior.AllowGet));
        }