Beispiel #1
0
 public CalendarEntry GetCalendarEntry(int calendarEntryId)
 {
     using (CalendarDAL dal = new CalendarDAL())
     {
         SERVDataContract.DbLinq.CalendarEntry entry = dal.GetCalendarEntry(calendarEntryId);
         if (entry == null)
         {
             return(null);
         }
         return(new CalendarEntry(entry));
     }
 }
Beispiel #2
0
        public CalendarEntry GetCalendarEntry(DateTime date, int calendarId, int memberId)
        {
            DateTime cleanDate = new DateTime(date.Year, date.Month, date.Day);

            using (CalendarDAL dal = new CalendarDAL())
            {
                SERVDataContract.DbLinq.CalendarEntry entry = dal.GetCalendarEntry(cleanDate, calendarId, memberId);
                if (entry == null)
                {
                    return(null);
                }
                return(new CalendarEntry(entry));
            }
        }