/// <summary>
        /// Performs create of master page given submitted form data.
        /// </summary>
        /// <param name="form">Form containing master page to create.</param>
        /// <returns>Result of form post.</returns>
        private FormResult CreateMasterPage(Form form)
        {
            // Get master page details
            long       tenantId   = _authenticationService.TenantId;
            MasterPage masterPage = JsonConvert.DeserializeObject <MasterPage>(form.Data);

            masterPage.TenantId        = tenantId;
            masterPage.MasterPageZones = new List <MasterPageZone>();

            // Do the update
            _masterPageService.Create(masterPage);

            // Return form result with no errors
            return(_formHelperService.GetFormResult());
        }
Exemplo n.º 2
0
 public ActionResult HomePage()
 {
     return(CurrentTemplate(_masterPageService.Create <HomePage>(CurrentPage)));
 }