//All the creations methods add the objects in controller's values and send them to DB public bool AddUserStoryToSprint(UserStory userStory, Sprint sprint) { //Create sprint at the next order, create an activity and return success if (!sprint.OrderedUserStories.ContainsValue(userStory)) { int order = 0; while (sprint.OrderedUserStories.ContainsKey(order)) { order++; } sprint.AddUserStory(order, userStory); DB.AddUserStoryToSprint(userStory, sprint, order); CreateActivity(string.Format("A été ajouté au sprint \"{0}\"", sprint), userStory); return(true); } else { return(false); } }