public static StoryUpdate ( |
||
story | ||
return |
public static Story StoryUpdate(Story story)
{
if (!story.IsDirty)
{
return story;
}
story = story.Save();
SourceRepository.SourceUpdate(story.StoryId, SourceType.Story, story.StoryId.ToString());
FeedRepository.FeedAdd(FeedAction.Edited, story);
return story;
}
public static void StoryUpdateDuration(int storyId) { var story = StoryRepository.StoryFetch(storyId); var hour = HourRepository.HourFetchInfoList(story); story.Duration = hour.Sum(row => row.Duration); StoryRepository.StoryUpdate(story); }