var product = db.Products.First(p => p.Id == 5);
In the product detail show page, show.aspx?Id=5, 开发者_如何学Python I want to get the previous and next product link.
How can I do that?
Should I connect to the database three times to get the current product and previous id and next id for generate links?
I have solved this problem by returning two entities.
精彩评论