public static List<Articles> all()
        {
            using (kmsEntities db = new kmsEntities())
            {
                return db.Articles.ToList();
                //    var query = (from x in db.Articles
                //                 select new
                //                 {
                //                    x.ArticleID,
                //                    x.Title,
                //                    x.Content}).ToList();

                //    return query;
                //}
            }
        }
 public Users GetLogin(string username, string password)
 {
     kmsEntities db = new kmsEntities();
     return db.Users.Where(x => x.Username == username && x.Password == password).SingleOrDefault();
 }