public virtual void CanGetTotalHours() { float hours = _timeEntryAuditRepository.GetCount(119, DateTime.Parse("12/11/2010")); Console.WriteLine(hours); Assert.That(hours > 0); }
public IList <TimeEntryAuditDto> GetIncompleteWeeklyTimeForAllUsers(DateTime weekEndingDate) { IList <Person> activeUsers = _personManagementService.GetActiveStaff(); if (activeUsers == null) { return(new List <TimeEntryAuditDto>()); } return((from activeUser in activeUsers where _timeEntryAuditRepository.GetCount(activeUser.Id, weekEndingDate) == 0 let hours = GetHoursForWeek(weekEndingDate, activeUser.Id) where hours < 40 select new TimeEntryAuditDto { AuditTimeStamp = DateTime.Now, Hours = hours.ToString(), UserId = activeUser.Id, WeekEndingDate = weekEndingDate }).ToList()); }