Exemple #1
0
        public UserSessionEntity TryLoginX(string thridpart_username, string thirdpartuserid, int logintype, string url)
        {
            var info = authobj.TryLoginX(thridpart_username, thirdpartuserid, logintype, url);

            if (string.IsNullOrEmpty(info.NickName))
            {
                BCtrl_Users userobj  = new BCtrl_Users();
                string      nickName = "手机用户" + authobj.NickNameMaxID();
                userobj.UpdateMyNickName(info.UserID, nickName);
                info.NickName = nickName;
            }
            if (string.IsNullOrEmpty(info.UserPictureUrl) && string.IsNullOrEmpty(info.ThirdPictureUrl))
            {
                info.Domain      = string.Empty;
                info.PicturePath = AppUtil.UserDefaultHeader + AppUtil.ConvertJpg;
            }
            return(info);
        }
Exemple #2
0
        public UserSessionEntity TryLogin(string loginname, string pwd, out string msg)
        {
            var info = authobj.TryLogin(loginname, pwd, out msg);

            if (info != null && string.IsNullOrEmpty(info.NickName))
            {
                BCtrl_Users userobj  = new BCtrl_Users();
                string      nickName = "手机用户" + authobj.NickNameMaxID();
                userobj.UpdateMyNickName(info.UserID, nickName);
                info.NickName = nickName;
            }
            if (info != null && string.IsNullOrEmpty(info.UserPictureUrl) && string.IsNullOrEmpty(info.ThirdPictureUrl))
            {
                info.Domain = string.Empty;

                info.PicturePath = AppUtil.UserDefaultHeader + AppUtil.ConvertJpg;
            }
            return(info);
        }