/// <summary> /// Checkings the worked issues. /// </summary> /// <param name="groupedWorkedIssues">The grouped worked issues.</param> /// <returns></returns> private async Task <Dictionary <string, List <AgileIssue> > > CheckingWorkedIssues(Dictionary <string, List <AgileIssue> > groupedWorkedIssues) { var keys = groupedWorkedIssues.Keys.ToList(); var tasks = keys.Select(async key => { groupedWorkedIssues[key] = await _checkLogService.ChechWorkedOnIssues(groupedWorkedIssues[key], key); }); await Task.WhenAll(tasks); return(groupedWorkedIssues); }
/// <summary> /// Filters the type of the issues by. /// </summary> /// <param name="triageIssues">The team member triage issues model.</param> /// <param name="issues">The issues.</param> /// <returns></returns> private async Task <TeamMemberTriageIssuesModel> FilterIssuesByType(TeamMemberTriageIssuesModel triageIssues, List <AgileIssue> issues) { triageIssues.GropedImpedimentIssues = issues .Where(i => _impededIssueTypes.Contains(i.Fields.Status.Name)) .ToList(); triageIssues.GroupedWorkedIssues = issues .Where(i => i.Fields.Progress.Progress != null && (i.Fields.Progress.Progress >= i.Fields.Progress.Total || i.Fields.Progress.Percent == 100)) .ToList(); triageIssues.GroupedWillWorkIssues = issues .Where(i => !triageIssues.GroupedWorkedIssues.Contains(i) && !triageIssues.GropedImpedimentIssues.Contains(i)) .ToList(); // Checking will work issues on estimate present triageIssues.GroupedWillWorkIssues = FilterWillWorkIssuesByEstimateTime(triageIssues.GroupedWillWorkIssues); // Checking worked on issues that issues were completed after last report creating triageIssues.GroupedWorkedIssues = await _checkLogService.ChechWorkedOnIssues(triageIssues.GroupedWorkedIssues, triageIssues.Developer); return(triageIssues); }