public async void Configure( IApplicationBuilder app, IWebHostEnvironment env, MyIdentityContext context, UserManager <MyIdentityUser> userManager, RoleManager <IdentityRole> roleManager) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } // Start the database with some users and clams. var initializer = new IdentityInitializer(context, userManager, roleManager); await initializer.Initialize(); app.UseSwaggerConfiguration(); app.UseHttpsRedirection(); app.UseRouting(); // Custom NetDevPack abstraction here! app.UseAuthConfiguration(); app.UseEndpoints(endpoints => { endpoints.MapControllers(); }); }
public AccountController( UserManager <MyIdentityUser> userManager, SignInManager <MyIdentityUser> signinManager, RoleManager <IdentityRole> roleManager, MyIdentityContext identityContext) { _userManager = userManager; _signInManager = signinManager; _roleManager = roleManager; _identityContext = identityContext; }
public IdentityController(UserManager <ApiUser> userManager, MyIdentityContext ctx, SignInManager <ApiUser> signInManager, IConfiguration configuration, IOptions <JwtIssuerOptions> jwtOptions) { _userManager = userManager; _identityContext = ctx; _signInManager = signInManager; _configuration = configuration; _jwtOptions = jwtOptions.Value; //_identityContext.Database.Migrate(); }
public AccountController(MyIdentityContext context) { this.context = context; }