Ejemplo n.º 1
0
        public ModelToModel GetAll()
        {
            ModelToModel mm;

            mm = new ModelToModel();
            mm.shops = new List<Shop>();
            using (BookMarketDbContext db = new BookMarketDbContext())
            {
                foreach (var entry in db.GetAllShops())
                    mm.shops.Add(entry);
            }
            return mm;
        }