public ClientService( IMapper mapper, IDSContext Context ) { this.mapper = mapper; this.Context = Context; }
public AccountController( IDSContext context, UserManager <User> userManager, SignInManager <User> signInManager, IIdentityServerInteractionService interaction, IAuthenticationSchemeProvider authenticationSchemeProvider, IEventService events ) { this.context = context; this.userManager = userManager; this.signInManager = signInManager; this.interaction = interaction; this.authenticationSchemeProvider = authenticationSchemeProvider; this.events = events; }
private static async Task InitializeDatabase(IDSContext context, UserManager <User> userManager) { if (!context.Users.Any()) { foreach (var user in IdsConfig.Users) { await userManager.CreateAsync(user, user.PasswordHash); } await context.SaveChangesAsync(); } if (!context.ApiResources.Any()) { foreach (var res in IdsConfig.ApiResource) { await context.ApiResources.AddAsync(res.ToEntity()); } await context.SaveChangesAsync(); } if (!context.Clients.Any()) { foreach (var client in IdsConfig.Clients) { await context.Clients.AddAsync(client.ToEntity()); } await context.SaveChangesAsync(); } if (!context.IdentityResources.Any()) { foreach (var resource in IdsConfig.IdentityResources) { await context.IdentityResources.AddAsync(resource.ToEntity()); } await context.SaveChangesAsync(); } if (!context.ApiScopes.Any()) { foreach (var resource in IdsConfig.ApiScopes) { await context.ApiScopes.AddAsync(resource.ToEntity()); } await context.SaveChangesAsync(); } }
public AuthController(IMemoryCache memoryCache, IDSContext dbContext, ConfigurationValues configuration) : base(memoryCache, dbContext, configuration) { }
public DeviceManager(IMemoryCache memoryCache, IDSContext eFEntities) { _memoryCache = memoryCache; _idsContext = eFEntities; }
public PacketManager(IDSContext dbContext) { _dbContext = dbContext; }
public AccountController(IDSContext context) { this.context = context; }
public ResourceOwnerPasswordValidator(IDSContext context) { _context = context; }
public BaseApiController(IMemoryCache memoryCache, IDSContext dbContext, ConfigurationValues configuration) { Cache = memoryCache; DbContext = dbContext; Configuration = configuration; }