Exemplo n.º 1
0
        public ActionResult Comment(int?PostId)
        {
            BlogPostModel post;

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

            return(View(post));
        }
Exemplo n.º 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));
        }
Exemplo n.º 3
0
        public ActionResult GetPost(int?Id)
        {
            //BlogPostModel post = CMSService.GetPost(Id);

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