public ActionResult Index() { var elCliente = new SI.AdventureWorks.AdventureWorksWcfClient(); var products = elCliente.ListarProductos(); //var products = db.Products.Include(p => p.ProductModel).Include(p => p.ProductSubcategory); return(View(products.ToList())); }
// GET: Products public ActionResult IndexViewModel() { var elCliente = new SI.AdventureWorks.AdventureWorksWcfClient(); var products = elCliente.ListarProductosParaViewModel(); var elResultado = ConvertirProductEnViewModel(products); //var products = db.Products.Include(p => p.ProductModel).Include(p => p.ProductSubcategory); return(View(elResultado.ToList())); }