public IViewComponentResult Invoke(int id) { EfFoodDal foodDal = new EfFoodDal(); var result = foodDal.GetAll(x => x.CategoryId == id); return(View(result)); }
public IViewComponentResult Invoke() { EfFoodDal foodDal = new EfFoodDal(); var result = foodDal.GetAll(); return(View(result)); }
public IActionResult Index(int page = 1) { var result = foodDal.GetAll("Category").ToPagedList(page, 3); return(View(result)); }