From 987c624df192297a530052bae2fe5e8e27444593 Mon Sep 17 00:00:00 2001 From: Kevin Date: Mon, 9 Mar 2020 14:36:19 +0000 Subject: [PATCH] CON-1513-fix-apprentice-link --- .../Employer.Web/Extensions/HtmlHelperExtensions.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Employer/Employer.Web/Extensions/HtmlHelperExtensions.cs b/src/Employer/Employer.Web/Extensions/HtmlHelperExtensions.cs index 74b4502c7f..04ee193379 100644 --- a/src/Employer/Employer.Web/Extensions/HtmlHelperExtensions.cs +++ b/src/Employer/Employer.Web/Extensions/HtmlHelperExtensions.cs @@ -14,16 +14,16 @@ public static class HtmlHelperExtensions public static IHeaderViewModel GetHeaderViewModel(this IHtmlHelper html, bool hideMenu = false) { var externalLinks = (html.ViewContext.HttpContext.RequestServices.GetService(typeof(IOptions)) as IOptions).Value; - var maRoutes = (html.ViewContext.HttpContext.RequestServices.GetService(typeof(IOptions)) as IOptions).Value; var authConfig = (html.ViewContext.HttpContext.RequestServices.GetService(typeof(IOptions)) as IOptions).Value; var requestRoot = html.ViewContext.HttpContext.Request.GetRequestUrlRoot(); var requestPath = html.ViewContext.HttpContext.Request.Path; + var commitmentsSiteUrl = new Uri(externalLinks.CommitmentsSiteUrl); var headerModel = new HeaderViewModel(new HeaderConfiguration { - EmployerCommitmentsBaseUrl = externalLinks.CommitmentsSiteUrl, + EmployerCommitmentsBaseUrl = $"{commitmentsSiteUrl.Scheme}://{commitmentsSiteUrl.Host}/commitments", EmployerFinanceBaseUrl = externalLinks.ManageApprenticeshipSiteUrl, - ManageApprenticeshipsBaseUrl = externalLinks.ManageApprenticeshipSiteUrl, + ManageApprenticeshipsBaseUrl = externalLinks.ManageApprenticeshipSiteUrl, AuthenticationAuthorityUrl = authConfig.Authority, ClientId = authConfig.ClientId, EmployerRecruitBaseUrl = requestRoot,