public async Task <ActionResult> JobPostingDetails(int?i) { JobPostingDetailViewModel model = new JobPostingDetailViewModel(); string jobId = Request.QueryString["jobPostingId"]; model.Job = await _jobPostingService.GetJobByJobId(jobId); var applicants = await _memberService.GetJobApplicantsbyJobId(jobId); model.Applicants = applicants.ToPagedList(i ?? 1, 8); return(View(model)); }
public async Task <ActionResult> JobDetails() { string jobId = Request.QueryString["jobPostingId"]; // TODO // Alter this method to get job details from NoSQL JobPostingInfo jobInfo = await _jobPostingService.GetJobByJobId(jobId); // TODO /* Add ratings from NoSQL */ /* Then uncomment the following code and adapt to your ratings */ //var rating = ratings.FirstOrDefault(r => r.CompanyId == jobInfo.CompanyId); //jobInfo.AverageRating = GetAverageRating(rating); return(View(jobInfo)); }