Ejemplo n.º 1
0
        public ActionResult Exemple6()
        {
            //Default page
            ViewBag.Message = "List Exemple for custom mapping";
            //this exemple show how map a IQueryable to List  with custom mapping
            ExempleOrder exemple6 = new ExempleOrder();
            List<OrderModel> model = null;
            var result = exemple6.GetOrders();
            //see sql request in console output
            model = result.Select<Order, OrderModel>().ToList();

            return View(model);
        }