i have a table structure like this...
When I import this into entity framework it looks like this...
What I need to do is build a query from LINQ that will return a list of every unique store, populated with a list of people who like that store. (easy, right?)
THE CATCH: I need to filter the list to the person's list of friends that get passed in as a List to the linq query (comes from facebook, so relationships are not in db)...
ONE MORE THING:
i need to return if the store is a favorite of the person requesting the data (the uid
as shown below)
OK, ANOTHER THING: I need to return the list sorted by the highest number of friends who like an item to lowest (the ui below is wrong in that regard)
Here is the method signature of the linq query i need
public List<Store> GetTopStoresFilteredByFriends
(int uid, List<int> friends, int size = 10){
}
To return a user interface that looks like this...