Ejemplo n.º 1
0
        public List<BankModel> BindFromEntities()
        {
            
            using (RepositoryHolder scope = new RepositoryHolder())
            {
                BankMapper mapper = new BankMapper();
                //CurrencyRateMapper mapper2 = new CurrencyRateMapper();   
                List<BankModel> result = mapper.EntityToModel(
                    scope.BankRepository
                    .Fetch()               
                   .ToList());
                return result;
            }

        }
Ejemplo n.º 2
0
        public List<BankModel> BindFromEntities()
        {
            using (RepositoryHolder scope = new RepositoryHolder())
            {
                BankMapper mapper = new BankMapper();
                
                List<BankModel> result =
                    scope.AdressRepository
                    .Fetch()
                    .Select
                        (
                            p =>
                                mapper.EntityToModel(p)
                        )
                   .ToList();
                return result;
            }

        }