public async Task <List <HistoryEntity> > GetPopularItemsAsync(WatchingItemType type) { return(await _historyContext .History .Where(x => x.WatchingItemType == type) //.GroupBy(x => x.WatchingItemId) .Take(10) .ToListAsync()); }
public PopularItemsByWatchingTypeQuery(WatchingItemType watchingType) { WatchingType = watchingType; }