Ignore:
Timestamp:
02/27/18 23:20:14 (19 months ago)
Author:
jzenisek
Message:

#2839: implemented refreshing list of available (i.e. for non-admins assignable) resources depending on currently selected project

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2839_HiveProjectManagement/HeuristicLab.Clients.Hive/3.3/HiveAdminClient.cs

    r15813 r15819  
    6565    }
    6666
     67    private IItemList<AssignedProjectResource> projectResourceAssignments;
     68    public IItemList<AssignedProjectResource> ProjectResourceAssignments {
     69      get { return projectResourceAssignments; }
     70    }
     71
    6772    private Dictionary<Guid, HashSet<Project>> projectAncestors;
    6873    public Dictionary<Guid, HashSet<Project>> ProjectAncestors {
     
    110115        resources = new ItemList<Resource>();
    111116        projects = new ItemList<Project>();
     117        projectResourceAssignments = new ItemList<AssignedProjectResource>();
    112118
    113119        projectAncestors = new Dictionary<Guid, HashSet<Project>>();
     
    120126          service.GetSlavesForAdministration().ForEach(s => resources.Add(s));
    121127          service.GetProjectsForAdministration().ForEach(p => projects.Add(p));
     128          var projectIds = projects.Select(p => p.Id).ToList();
     129          if(projectIds.Any())
     130            service.GetAssignedResourcesForProjectsAdministration(projectIds)
     131            .ForEach(a => projectResourceAssignments.Add(a));
    122132        });
    123133
Note: See TracChangeset for help on using the changeset viewer.