Compare commits

...
1 Commits
3 changed files with 44 additions and 33 deletions
+1 -1
View File
@@ -1 +1 @@
1.0.58
1.0.59
+3 -3
View File
@@ -26,6 +26,6 @@ using System.Runtime.InteropServices;
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
[assembly: AssemblyVersion("1.0.58")]
[assembly: AssemblyFileVersion("1.0.58")]
[assembly: AssemblyInformationalVersion("1.0.58")]
[assembly: AssemblyVersion("1.0.59")]
[assembly: AssemblyFileVersion("1.0.59")]
[assembly: AssemblyInformationalVersion("1.0.59")]
@@ -57,7 +57,18 @@ namespace JiraTimeBot.TaskTime
}
var workTasks = _spreadHelper.SpreadTime(taskCommits, remainMinutes, settings.RoundToMinutes);
workTimeItems.AddRange(workTasks);
foreach (var workTask in workTasks)
{
var existingItem = workTimeItems.FirstOrDefault(f => f.Branch == workTask.Branch);
if (existingItem != null)
{
existingItem.TimeSpent += workTask.TimeSpent;
existingItem.Description += "\r\n" + workTask.Description;
continue;
}
workTimeItems.Add(workTask);
}
workTimeItems = workTimeItems.OrderByDescending(f => f.TimeSpent).ToList();
remainMinutes = minutesPerWorkDay - (int) workTimeItems.Sum(f => f.TimeSpent.TotalMinutes);