View Source
Class BackOfficeController
Inheritance
System.Object
Microsoft.AspNetCore.Mvc.ControllerBase
Microsoft.AspNetCore.Mvc.Controller
Assembly: Umbraco.Web.BackOffice.dll
Syntax
[PluginController("UmbracoBackOffice")]
public class BackOfficeController : UmbracoController, IActionFilter, IAsyncActionFilter, IFilterMetadata, IDisposable
Constructors
View Source
BackOfficeController(IBackOfficeUserManager, IRuntimeState, IRuntimeMinifier, IOptionsSnapshot<GlobalSettings>, IHostingEnvironment, ILocalizedTextService, IGridConfig, BackOfficeServerVariables, AppCaches, IBackOfficeSignInManager, IBackOfficeSecurityAccessor, ILogger<BackOfficeController>, IJsonSerializer, IBackOfficeExternalLoginProviders, IHttpContextAccessor, IBackOfficeTwoFactorOptions, IManifestParser, ServerVariablesParser, IOptions<SecuritySettings>)
Declaration
[ActivatorUtilitiesConstructor]
public BackOfficeController(IBackOfficeUserManager userManager, IRuntimeState runtimeState, IRuntimeMinifier runtimeMinifier, IOptionsSnapshot<GlobalSettings> globalSettings, IHostingEnvironment hostingEnvironment, ILocalizedTextService textService, IGridConfig gridConfig, BackOfficeServerVariables backOfficeServerVariables, AppCaches appCaches, IBackOfficeSignInManager signInManager, IBackOfficeSecurityAccessor backofficeSecurityAccessor, ILogger<BackOfficeController> logger, IJsonSerializer jsonSerializer, IBackOfficeExternalLoginProviders externalLogins, IHttpContextAccessor httpContextAccessor, IBackOfficeTwoFactorOptions backOfficeTwoFactorOptions, IManifestParser manifestParser, ServerVariablesParser serverVariables, IOptions<SecuritySettings> securitySettings)
Parameters
Methods
View Source
Application()
Returns the JavaScript main file including all references found in manifests
Declaration
[HttpGet]
[AllowAnonymous]
public async Task<IActionResult> Application()
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|
View Source
AuthorizeUpgrade()
This Action is used by the installer when an upgrade is detected but the admin user is not logged in. We need to
ensure the user is authenticated before the install takes place so we redirect here to show the standard login
screen.
Declaration
[HttpGet]
[StatusCodeResult(HttpStatusCode.ServiceUnavailable)]
[AllowAnonymous]
public async Task<IActionResult> AuthorizeUpgrade()
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|
View Source
Default()
Declaration
[HttpGet]
[AllowAnonymous]
public async Task<IActionResult> Default()
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|
View Source
ExternalLinkLoginCallback()
Callback path when the user initiates a link login request from the back office to the external provider from the
LinkLogin(String) action
Declaration
[Authorize(Policy = "BackOfficeAccess")]
[HttpGet]
public async Task<IActionResult> ExternalLinkLoginCallback()
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|
View Source
ExternalLogin(String, String)
Declaration
[HttpPost]
[AllowAnonymous]
public ActionResult ExternalLogin(string provider, string redirectUrl = null)
Parameters
Type |
Name |
Description |
System.String |
provider |
|
System.String |
redirectUrl |
|
Returns
Type |
Description |
Microsoft.AspNetCore.Mvc.ActionResult |
|
View Source
GetGridConfig()
Declaration
[Authorize(Policy = "BackOfficeAccess")]
[AngularJsonOnlyConfiguration]
[HttpGet]
public IEnumerable<IGridEditorConfig> GetGridConfig()
Returns
View Source
LinkLogin(String)
Called when a user links an external login provider in the back office
Declaration
[Authorize(Policy = "BackOfficeAccess")]
[HttpPost]
public ActionResult LinkLogin(string provider)
Parameters
Type |
Name |
Description |
System.String |
provider |
|
Returns
Type |
Description |
Microsoft.AspNetCore.Mvc.ActionResult |
|
View Source
LocalizedText(String)
Get the json localized text for a given culture or the culture for the current user
Declaration
[HttpGet]
[AllowAnonymous]
public async Task<Dictionary<string, Dictionary<string, string>>> LocalizedText(string culture = null)
Parameters
Type |
Name |
Description |
System.String |
culture |
|
Returns
Type |
Description |
Task<Dictionary<System.String, Dictionary<System.String, System.String>>> |
|
View Source
ServerVariables()
Returns the JavaScript object representing the static server variables javascript object
Declaration
[Authorize(Policy = "BackOfficeAccess")]
public async Task<JavaScriptResult> ServerVariables()
Returns
View Source
ValidatePasswordResetCode(Int32, String)
Declaration
[HttpGet]
[AllowAnonymous]
public async Task<IActionResult> ValidatePasswordResetCode([Bind(new string[]{}, Prefix = "u")] int userId, [Bind(new string[]{}, Prefix = "r")] string resetCode)
Parameters
Type |
Name |
Description |
System.Int32 |
userId |
|
System.String |
resetCode |
|
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|
View Source
VerifyInvite(String)
Declaration
[HttpGet]
[AllowAnonymous]
public async Task<IActionResult> VerifyInvite(string invite)
Parameters
Type |
Name |
Description |
System.String |
invite |
|
Returns
Type |
Description |
Task<Microsoft.AspNetCore.Mvc.IActionResult> |
|