Created
June 6, 2021 14:30
-
-
Save Defcoq/6f74e2e7457b27d27bbc21b7e8304768 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 ProductRepository : Model.IProductRepository | |
{ | |
public IList<Model.Product> FindAll() | |
{ | |
var products = from p in new ITInnovDesign.SoC.Repository.ProductContext().Products | |
select new Model.Product | |
{ | |
Id = p.ProductId, | |
Name = p.ProductName, | |
Price = new Model.Price(p.Rrp, p.SellingPrice) | |
}; | |
return products.ToList(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment