public async Task <IViewComponentResult> InvokeAsync() { var result = await _commonService.GetCategoryHomeAsync(); if (result.Code != HttpStatusCode.OK) { return(View("Default", new List <CategoriesDto>())); } return(View("Default", result.ResultObj)); }
public async Task <IActionResult> Index() { var result = await _apiService.GetCategoryHomeAsync(); return(View(result.ResultObj)); }