Merge remote-tracking branch 'origin/netcore/netcore' into feature/8651-config-options-patten
This commit is contained in:
@@ -47,6 +47,16 @@ namespace Umbraco.Extensions
|
||||
return linkGenerator.GetPathByAction(nameof(InstallController.Index), ControllerExtensions.GetControllerName<InstallController>(), new { area = Constants.Web.Mvc.InstallArea });
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Returns the URL for the installer api
|
||||
/// </summary>
|
||||
/// <param name="linkGenerator"></param>
|
||||
/// <returns></returns>
|
||||
public static string GetInstallerApiUrl(this LinkGenerator linkGenerator)
|
||||
{
|
||||
return linkGenerator.GetPathByAction(nameof(InstallController.Index), ControllerExtensions.GetControllerName<InstallApiController>(), new { area = Constants.Web.Mvc.InstallArea }).EnsureEndsWith('/');
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Return the Url for a Web Api service
|
||||
/// </summary>
|
||||
|
||||
@@ -32,18 +32,6 @@ namespace Umbraco.Extensions
|
||||
return url.Action("Default", ControllerExtensions.GetControllerName(backOfficeControllerType), new { area = Constants.Web.Mvc.BackOfficeApiArea });
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Return the installer API url
|
||||
/// </summary>
|
||||
/// <param name="url"></param>
|
||||
/// <returns></returns>
|
||||
public static string GetInstallerApiUrl(this IUrlHelper url)
|
||||
{
|
||||
// there is no default action here so we need to get it by action and trim the action
|
||||
return url.Action("GetSetup", ControllerExtensions.GetControllerName<InstallApiController>(), new { area = Constants.Web.Mvc.InstallArea })
|
||||
.TrimEnd("GetSetup");
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Return the Url for a Web Api service
|
||||
/// </summary>
|
||||
|
||||
@@ -83,7 +83,7 @@ namespace Umbraco.Web.Common.Install
|
||||
}
|
||||
|
||||
// gen the install base url
|
||||
ViewData.SetInstallApiBaseUrl(Url.GetInstallerApiUrl());
|
||||
ViewData.SetInstallApiBaseUrl(_linkGenerator.GetInstallerApiUrl());
|
||||
|
||||
// get the base umbraco folder
|
||||
var baseFolder = _hostingEnvironment.ToAbsolute(_globalSettings.UmbracoPath);
|
||||
|
||||
Reference in New Issue
Block a user