public ActionResult Index()
        {
            AllProductVM allProduct = new AllProductVM();

            allProduct.Products = ProductsService.Instance.GetAllProducts().Take(9).ToList();
            return(View(allProduct));
        }
Esempio n. 2
0
        public ActionResult Index()
        {
            AllProductVM allProductVM = new AllProductVM
            {
                Categories = repoCategory.GetAll().Include(i => i.Children).Include(i => i.Products).ToList(),
                Brands     = repoBrand.GetAll().Include(i => i.Products).ToList(),
                Products   = repoProduct.GetAll().Include(i => i.Author).Include(i => i.Pictures).ToList()
            };

            ViewBag.PageTitle = "- Kategoriler";
            return(View(allProductVM));
        }