Exemplo n.º 1
0
        private List <int?> GetNextEditionStartDateDifferences(EditionEntity edition)
        {
            var nextEdition = _editionServices.GetNextEdition(edition, Utility.Constants.ValidEventTypesForCed);

            if (nextEdition == null)
            {
                return new List <int?> {
                           null, null
                }
            }
            ;
            var weekDiff = edition.StartDate.GetValueOrDefault().WeekOfYearDiff(nextEdition.StartDate.GetValueOrDefault());
            var dayDiff  = edition.StartDate.GetValueOrDefault().DayOfYearDiff(nextEdition.StartDate.GetValueOrDefault());

            return(new List <int?> {
                weekDiff, dayDiff
            });
        }