// GET: Admin/Product public ActionResult Index() { ProductsListingModel model = new ProductsListingModel(); model.Products = productServices.GetAllProducts(); model.MainMenus = mainServices.GetAllMainMenus(); model.SubMenus = subServices.GetAllSubMenus(); model.Brands = brandServices.GetAllBrands(); model.Tags = tagServices.GetAllTags(); model.Suppliers = supplierServices.GetAllSuppliers(); return(View(model)); }
// GET: Admin/Brand public ActionResult Index() { BrandListingModel model = new BrandListingModel(); model.Brands = services.GetAllBrands(); return(View(model)); }
public IActionResult GetAllBrands() { try { return(Ok(_brandServices.GetAllBrands())); } catch (Exception) { return(StatusCode(500)); } }
public IActionResult Index(string brandName) { var shoeList = BrandServices.GetShoesByBrandName(brandName); var allBrandsVm = BrandServices.GetAllBrands(); dynamic mymodel = new ExpandoObject(); mymodel.Shoes = shoeList.Shoes; mymodel.Brand = allBrandsVm; return(View(mymodel)); }
public IActionResult Index(int productId) { var shoe = _shoesService.GetShoeById(productId); shoe.Sizes = _quantityService.GetAllSizesById(productId); var allBrandsVm = _brandServices.GetAllBrands(); dynamic mymodel = new ExpandoObject(); mymodel.Shoe = shoe; mymodel.Brand = allBrandsVm; return(View(mymodel)); }
public IActionResult AddShoeView() { var allShoesVm = new ShoeListViewModel { Shoes = _shoesService.GetAllShoes() }; var allBrandsVM = _brandServices.GetAllBrands(); dynamic myModel = new ExpandoObject(); myModel.AllShoes = allShoesVm.Shoes; myModel.Brand = allBrandsVM; return(View(myModel)); }
public IViewComponentResult Invoke() { var brand = _brandServices.GetAllBrands(); return(View(brand)); }
public IActionResult GetAllBrands() { var allBrands = _brandService.GetAllBrands(); return(Ok(allBrands)); }