public virtual LayoutModel CreateLayoutModel(ContentReference currentContentLink, RequestContext requestContext)
        {
            if (ContentReference.StartPage.ID == 0)
                return null;

            var startPage = _contentLoader.Get<StartPage>(ContentReference.StartPage);

            return new LayoutModel
            {
                // MenuTopPages = startPage.MenuTopPageLinks,
                SearchPageRouteValues = requestContext.GetPageRoute(startPage.SearchPageLink),
                SearchPageLink = startPage.SearchPageLink,

                // header
                SearchLabel = startPage.SearchLabel,
                SearchPlaceholderLabel = startPage.SearchPlaceholderLabel,
                LogoAlternativeText = startPage.LogoAlternativeText,

                // footer
                PhoneNumber = startPage.PhoneNumber,
                PhoneNumberLabel =  startPage.PhoneNumberLabel,
                MailAddress = startPage.MailAddress,
                Address = startPage.Address,
                CvrNumber = startPage.CvrNumber
            };
        }
        public virtual LayoutModel CreateLayoutModel(ContentReference currentContentLink, RequestContext requestContext)
        {
            var settings = _siteSettingsRepository.Get();

            return new LayoutModel
                {
                    Logotype = settings.SiteLogotype,
                    LogotypeLinkUrl = new MvcHtmlString(_urlResolver.GetUrl(SiteDefinition.Current.StartPage)),
                    ProductPages = settings.ProductPageLinks,
                    CompanyInformationPages = settings.CompanyInformationPageLinks,
                    NewsPages = settings.NewsPageLinks,
                    CustomerZonePages = settings.CustomerZonePageLinks,
                    LoggedIn = requestContext.HttpContext.User.Identity.IsAuthenticated,
                    LoginUrl = new MvcHtmlString(GetLoginUrl(currentContentLink)),
                    SearchPageRouteValues = requestContext.GetPageRoute(settings.SearchPageLink)
                };
        }
        public virtual LayoutModel CreateLayoutModel(ContentReference currentContentLink, RequestContext requestContext)
        {
            var startPage = _contentLoader.Get<StartPage>(SiteDefinition.Current.StartPage);

            //var companyPages = _contentLoader.GetChildren<PageData>(startPage.CompanyInformationPageLink)
            //    .FilterForDisplay(requirePageTemplate: true)
            //    .ToList();
            //companyPages.Insert(0, _contentLoader.Get<PageData>(startPage.CompanyInformationPageLink));

            return new LayoutModel
                {
                    Logotype = startPage.SiteLogotype,
                    LogotypeLinkUrl = new MvcHtmlString(_urlResolver.GetUrl(SiteDefinition.Current.StartPage)),
                    ProductPages = startPage.ProductPageLinks,
                    CompanyInformationPages = startPage.CompanyInformationPageLinks,
                    NewsPages = startPage.NewsPageLinks,
                    CustomerZonePages = startPage.CustomerZonePageLinks,
                    LoggedIn = requestContext.HttpContext.User.Identity.IsAuthenticated,
                    LoginUrl = new MvcHtmlString(GetLoginUrl(currentContentLink)),
                    SearchPageRouteValues = requestContext.GetPageRoute(startPage.SearchPageLink)
                };
        }