Beispiel #1
0
        public IActionResult Index()
        {
            List <Banner>       banners       = bannersRepository.GetBanners();
            List <Product>      products      = productsRepository.GetAllProducts();
            List <Promo>        promos        = promosRepository.GetAllPromos();
            List <PromoProduct> promoProducts = promosRepository.GetAllPromoProducts();

            Navigation navigation = commonRepository.GetNavigation();
            SeoData    seo        = commonRepository.GetSeo("main");

            var mainPage = new MainPage(seo, navigation, null, banners, products, promos, promoProducts);

            return(View(mainPage));
        }
Beispiel #2
0
        public IEnumerable <Banner> GetAllBanners()
        {
            List <Banner> banners = bannersRepository.GetBanners();

            return(banners);
        }