public async Task <ActionResult> Index(int pageid = 1) { // Post and paggination ViewBag.ListPost = await _service.GetAllPost(3, pageid); ViewBag.pageCount = await _service.PageCount() / 3; ViewBag.PageId = pageid; // Comments ViewBag.Comments = await _service.GetAllComment(); // Xp view bag ViewBag.ListXp = await _service.GetAllXp(); // Projects view bags var ListProject = await _service.GetAllProjects(); ViewBag.ProjectSucces = ListProject.Where(p => p.Status == "Complete").Count(); ViewBag.ProjectWorking = ListProject.Where(p => p.Status == "Working").Count(); ViewBag.ProjectFaild = ListProject.Where(p => p.Status == "Faild").Count(); ViewBag.ProjectSuccesUrl = ListProject.Where(p => p.Status == "Complete").Select(p => p.Url).ToList(); return(View()); }