Skip to content

Instantly share code, notes, and snippets.

@cdpidan
cdpidan / .editorconfig
Last active April 8, 2021 07:25 — forked from simonauner/pre-commit
Format c# with dotnet-format with pre-commit hook
# EditorConfig is awesome:http://EditorConfig.org
# top-most EditorConfig file
root = true
# Don't use tabs for indentation.
[*]
indent_style = space
# (Please don't specify an indent_size here; that has too many unintended consequences.)
@cdpidan
cdpidan / AccountController.cs
Created December 19, 2017 14:29 — forked from hikalkan/AccountController.cs
User Impersonation for ASP.NET Boilerplate
/* SAMPLE AJAX CALL to this action:
(This is enough since it's automatically redirected to the target tenant's ImpersonateSignIn action)
abp.ajax({
url: abp.appPath + 'Account/Impersonate',
data: JSON.stringify({
tenantId: 1, //Target tenant id (can be null if target user is a host user)
userId: 2 //Target user id
})