コード例 #1
0
        public static void Add(NotificationType type, ApplicationUser owner, ApplicationUser initiator, Idea idea, IdeasContext context, bool viewed = false)
        {
            var notification = new Notification {
                Owner            = owner,
                Initiator        = initiator,
                NotificationType = type,
                Idea             = idea,
                DateTime         = DateTime.Now,
                Viewed           = viewed
            };

            context.Notifications.Add(notification);
        }
コード例 #2
0
 private static bool RestoreTimeLineForFollowing(Idea idea)
 {
     idea.LatestUpdate = idea.DateTime;
     return(true);
 }