コード例 #1
0
        public ActionResult EditPage(int id)
        {
            var pagefound = _pagesService.GetPage(id);
            var result    = Mapper.Map <Page, PageVM>(pagefound);

            return(View(result));
        }
コード例 #2
0
        public IHttpActionResult GetPage(string storeId, string language, string pageName)
        {
            var item = _pagesService.GetPage(storeId, pageName, language);

            if (item == null)
            {
                return(NotFound());
            }

            return(Ok(item.ToWebModel()));
        }
コード例 #3
0
        public IHttpActionResult GetPage(string storeId, string language, string pageName)
        {
            var item = _pagesService.GetPage(storeId, pageName, language);

            if (item == null)
            {
                return(StatusCode(HttpStatusCode.NoContent));
            }

            return(Ok(item.ToWebModel()));
        }
コード例 #4
0
        public IHttpActionResult GetPage(string storeId, string language, string pageName)
        {
            base.CheckCurrentUserHasPermissionForObjects(ContentPredefinedPermissions.Read, new ContentScopeObject {
                StoreId = storeId
            });
            var item = _pagesService.GetPage(storeId, pageName, language);

            if (item == null)
            {
                return(NotFound());
            }

            return(Ok(item.ToWebModel()));
        }