/// <summary> /// Assigns the project artifact list. /// </summary> /// <param name="presenter">The presenter.</param> /// <param name="artifactList">The artifact list.</param> private static void AssignProjectArtifactList(ProjectDashboardPresenter presenter, IList<ProcessComplianceListItem> artifactList) { var nodeIndex = 0; var groupedList = artifactList.OrderBy(a => a.Squence) .Where(a => a.ArtifactType == (byte)ArtifactType.Project) .GroupBy(u => u.FunctionalArea) .Select(grp => new ProcessComplianceListItem { FunctionalArea = grp.Key, Items = grp.ToList() }) .ToList(); groupedList.ForEach(g => { g.NodeIndex = nodeIndex; nodeIndex++; }); presenter.AssignProcessCompliance(groupedList); presenter.ProcessComplianceList.ForEach(AssignProjectReleaseStatus); }