Beispiel #1
0
        public UserInfo Check(string username, string password)
        {
            UserInfo userInfo = new UserInfo();
            //密码加密
            string          pw   = SharedHelpers.EncodeBase64(password);
            List <UserInfo> list = Queryable().ToList();
            UserInfo        User = list.Where(x => x.user_name == username && x.pass_word == pw).FirstOrDefault();

            if (User != null)
            {
                userInfo = User;
            }
            return(userInfo);
        }