예제 #1
0
        public ActionResult Details(int id)
        {
            CustomerDTO customer = customService.GetCustomer(id);

            var mapper     = new MapperConfiguration(cfg => cfg.CreateMap <CustomerDTO, CustomerViewModel>()).CreateMapper();
            var customView = mapper.Map <CustomerViewModel>(customer);

            return(View(customView));
        }