예제 #1
0
        public ActionResult Publicity()
        {
            ContentPageModel   cp = new ContentPageModel(connectionString);
            List <ContentPage> contentpublicity = cp.GetContentPagePublicity("publicity");

            ViewBag.contentPage = contentpublicity;
            return(View());
        }
예제 #2
0
        public JsonResult ListAll()
        {
            ContentPageModel cp = new ContentPageModel(connectionString);

            return(Json(cp.GetContentPagePublicity("publicity")));
        }
예제 #3
0
        public JsonResult GetPublicityById(int id)
        {
            ContentPageModel cp = new ContentPageModel(connectionString);

            return(Json(cp.GetContentPagePublicity("publicity").Find(p => p.id == id)));
        }