Beispiel #1
0
        private void Refresh()
        {
            ChangingRole    = false;
            AddingEpic      = false;
            AddingUserStory = false;

            SelectedProject = _projectService.GetProjectById(SelectedProject.Id);
            SelectedMember  = null;
            UpdateMembers();
            NotInProjectUsers.Clear();
            NotInProjectUsers.AddRange(_projectService.GetAllUsersNotInProject(SelectedProject.Id));
            UpdateUsers();
        }
Beispiel #2
0
 public void OnNavigatedTo(NavigationContext navigationContext)
 {
     SelectedProject = (Project)navigationContext.Parameters["Project"];
     SelectedMember  = null;
     ProjectName     = SelectedProject.Name;
     ProjectKey      = SelectedProject.Key;
     NotInProjectUsers.Clear();
     NotInProjectUsers.AddRange(_projectService.GetAllUsersNotInProject(SelectedProject.Id));
     UpdateUsers();
     IsProjectStarted = SelectedProject.Sprints.Count != 0;
     if (IsProjectStarted)
     {
         CurrentSprint = SelectedProject.Sprints.OrderByDescending(p => p.Order).First();
     }
     UpdateMembers();
 }
Beispiel #3
0
 private void AddMember()
 {
     try
     {
         var member = _projectService.AddUserToProject(_addingUser, SelectedProject, SelectedRole);
         SelectedProject.Members.Add(member);
         member.User    = _addingUser;
         member.Project = SelectedProject;
         NotInProjectUsers.Remove(NotInProjectUsers.FirstOrDefault(user => user.Id == _addingUser.Id));
         UpdateUsers();
         UpdateMembers();
         SelectingRole = false;
     }
     catch (Exception e)
     {
         ShowError("Error", e.Message);
     }
 }