Ejemplo n.º 1
0
        public EntityNotification Get(int Id)
        {
            var data = base.DataContext.Message.Where(p => p.PK_MessageID == Id);

            if (data.Count() == 1)
            {
                return(FactoryNotification.Get(data.Single()));
            }
            else
            {
                return(null);
            }
        }
Ejemplo n.º 2
0
 public List <EntityNotification> GetByUserID(int UserID)
 {
     return(FactoryNotification.GetList(base.DataContext.Message.Where(p => p.FK_UserID == UserID).OrderByDescending(p => p.CreateDate).ToList()));
 }
Ejemplo n.º 3
0
 public List <EntityNotification> GetAll()
 {
     return(FactoryNotification.GetList(base.DataContext.Message.ToList()));
 }