private static async Task InsertLoginTokens() { using (var context = new VPDataContext(_configuration)) { await context.Database.ExecuteSqlCommandAsync("InsertEmailLoginTokens"); } }
private static async Task <List <User> > GetAllUsers(int vanafUserId) { using (var context = new VPDataContext(_configuration)) { return(await context.Users .Include(u => u.EmailLoginToken) .Where(u => u.Id >= vanafUserId && new[] { 0, 84 }.Contains(u.WebsiteId)) .OrderBy(u => u.Id) .ToListAsync()); } }
private static async Task <List <User> > GetUsers() { using (var context = new VPDataContext(_configuration)) { return(await context.Users .Where(u => new[] { 0, 84 }.Contains(u.WebsiteId) && !u.Actief) .OrderBy(u => u.Id) .ToListAsync()); } }