@inherits Dynamicweb.Rendering.ViewModelTemplate @MasterPageFile("Master.cshtml") @using Dynamicweb.Rapido.Blocks @using Dynamicweb.Rapido.Blocks.Components @using Dynamicweb.Rapido.Blocks.Components.General @functions { BlocksPage modalWarningPage = BlocksPage.GetBlockPage("CustomModalWarningPage"); } @{ Block cookieModal = new Block { Id = "CookieModal", SortId = 10, Component = new Modal { Id = "Cookie", Heading = new Heading { Title = Translate("This website use cookies"), Level = 2 }, Width = ModalWidth.Sm, BodyTemplate = RenderCookieForm() } }; modalWarningPage.Add(cookieModal); Block cookieScript = new Block { Id = "CookieScript", SortId = 20, Template = RenderCookieScript(true) }; modalWarningPage.Add(cookieScript); } @Include("Blocks/CookieForm.cshtml") @Include("Blocks/CookieScript.cshtml") @Include("Blocks/Custom__Blocks.cshtml") @* The @RenderBlockList base helper is included in Components/GridBuilder.cshtml *@ @RenderBlockList(modalWarningPage.BlocksRoot.BlocksList)