public async Task <IActionResult> Index(int?categoryId)
 {
     if (categoryId.HasValue)
     {
         ViewBag.ActiveCategory = categoryId;
         return(View(await _articleApiService.GetAllByCategoryIdAsync((int)categoryId)));
     }
     return(View(await _articleApiService.GetAllAsync()));
 }
예제 #2
0
 public async Task <IActionResult> Index()
 {
     return(View(await _articleApiService.GetAllAsync()));
 }
 public async Task <IActionResult> Index()
 {
     // TempData["active"]="blog";
     return(View(await _blogApiService.GetAllAsync()));
 }