Exemple #1
0
		public Sprint GetNextSprint()
		{
			if (_nextSprint == null)
			{
				_nextSprint = GetBacklogSprints().Where(sprint => sprint.StartDate.Date.CompareTo(DateTime.MinValue) == 0).OrderBy(sprint => sprint.Name).FirstOrDefault();
			}
			return _nextSprint;
		}
Exemple #2
0
		public Sprint GetCurrentSprint()
		{
			if (_currentSprint == null)
			{
				_currentSprint = GetSprints().Where(sprint => (!sprint.StartDate.Equals(DateTime.MinValue) ? sprint.StartDate : DateTime.MaxValue).Date.CompareTo(DateTime.Now.Date) <= 0 && (!sprint.EndDate.Equals(DateTime.MinValue) ? sprint.EndDate : DateTime.MaxValue).Date.CompareTo(DateTime.Now.Date) >= 0).FirstOrDefault();
			}
			return _currentSprint;
		}
Exemple #3
0
        public Sprint GetSprintByID(Int32 sprintID)
        {
            Sprint sprint = _jira.Client.GetSprint(this.ID, sprintID);

            if (sprint != null)
            {
                sprint.SetJira(_jira);
            }

            return(sprint);
        }
Exemple #4
0
        public Sprint GetSprintDetail(Sprint sprint)
        {
            Sprint detailedSprint = GetSprintByID(sprint.ID);

            if (detailedSprint == null)
            {
                detailedSprint = sprint;
            }
            detailedSprint.SetJira(_jira);

            return(detailedSprint);
        }
Exemple #5
0
        public List <User> GetUserDetailsForPeriod(DateTime from, DateTime until, List <Issue> additionalIssues)
        {
            List <User>   userDetails = new List <User>();
            List <Sprint> sprints     = GetSprintsBetween(from, until);
            Sprint        firstSprint = sprints.FirstOrDefault();

            if (additionalIssues == null)
            {
                additionalIssues = new List <Issue>();
            }

            if (firstSprint != null)
            {
                sprints.Remove(firstSprint);
                additionalIssues.AddRange(sprints.SelectMany(sprint => sprint.GetIssues()));

                userDetails = firstSprint.GetAssignableUsers(additionalIssues, from, until);
            }

            return(userDetails);
        }
Exemple #6
0
		public Sprint GetSprintDetail(Sprint sprint)
		{
			Sprint detailedSprint = GetSprintByID(sprint.ID);
			if (detailedSprint == null)
			{
				detailedSprint = sprint;
			}
			detailedSprint.SetJira(_jira);

			return detailedSprint;
		}