Created
December 10, 2020 21:50
-
-
Save bjornmicallef/e37f6da967e726c7a191bd54565d3ac7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class UserSettingsService : IUserSettingsService | |
{ | |
private readonly StockNotificationContext _dbContext; | |
public UserSettingsService(StockNotificationContext dbContext) | |
{ | |
_dbContext = dbContext; | |
} | |
public async Task<IEnumerable<Seller>> GetSellers() | |
{ | |
return await _dbContext.tblSellers | |
.Select(x => new Seller | |
{ | |
Id = x.Id, | |
Name = x.Name, | |
Url = x.Url | |
}) | |
.ToListAsync(); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment