public ICollection<NotificationWrapper> GetNotificationsForUser(UserWrapper user, int numberOfVisibleNotifications) { if (user == null) { return new List<NotificationWrapper>(); } var notificationAccess = new NotificationAccess(); var result = notificationAccess.GetNotificationsForUser(user); if (numberOfVisibleNotifications < 0) { return result.ToList(); } return result.Take(numberOfVisibleNotifications).ToList(); }
public void MarkNotificationAsRead(UserWrapper userWrapper, int responseId) { NotificationAccess na=new NotificationAccess(); na.MarkNotificationAsRead(userWrapper, responseId); }
public int GetNumberOfUnreadNotifications(UserWrapper userWrapper) { NotificationAccess ua = new NotificationAccess(); return ua.GetNumberOfUnreadNotifications(userWrapper); }