Hi I have an MVC app I'm calling a stored procedure from. The reason I'm using a stored procedure is because the query is quite complex and it already exists so I may as well use it.
It basically returns to me a :
IEnumerable<Activity>
which is good.
There is a one of many foreign key properties like:
AreaId
on this which gets populated.
However in my model I have the navigation property:
// Navigation properties
public virtual Area Area { get; set; }
which of course isn't populated getting it via the stored procedure.
I'm wondering if there is an easy way to get these navigation properties populated.
I believe I have heard of some command you can call on you entity to refresh navigation properties.