Exemplo n.º 1
0
        /// <summary>
        /// 按最近时间获取用户头像    新加入用户
        /// </summary>
        /// <param name="Uidto"></param>
        /// <returns></returns>
        public IEnumerable <Models.UserInfo> GetUserHeadPortrait()
        {
            var uifSvc             = new DAL.UserInfoService();
            var HeadPortraitEntity = uifSvc.GetUserHeadPortrait();

            return(HeadPortraitEntity);
        }
Exemplo n.º 2
0
        /// <summary>
        /// 微博文章  预览
        /// </summary>
        /// <returns></returns>
        public IEnumerable <DTO.MicroBlogAndUserInfDto> GetPreviewBlog()
        {
            var uifSvc            = new DAL.UserInfoService();
            var PreviewBlogEntity = uifSvc.GetPreviewBlog();

            return(PreviewBlogEntity);
        }
Exemplo n.º 3
0
        /// <summary>
        /// 找回密码方法
        /// </summary>
        /// <param name="whereLambda"></param>
        /// <returns></returns>
        public int ForgetThePwd(DTO.UserInfoDto Uidto)
        {
            var uifSvc = new DAL.UserInfoService();

            //根据邮箱修改密码
            return(uifSvc.ForgetThePwd(Uidto));
        }
Exemplo n.º 4
0
        //保存资料
        public int update(DTO.UserInfoDto du)
        {
            var uifsvc = new DAL.UserInfoService();
            int i      = uifsvc.update(du);

            return(i);
        }
Exemplo n.º 5
0
        //保存图片路径
        public int bao(DTO.UserInfoDto du)
        {
            var uifsvc = new DAL.UserInfoService();
            int i      = uifsvc.bao(du);;

            return(i);
        }
Exemplo n.º 6
0
        //////////////////////////////////////////////////////////////////


        //================================编辑资料开始=====================================//

        //通过登陆后的id显示一些信息
        public Models.UserInfo xian(int id)
        {
            var uifSvc = new DAL.UserInfoService();
            var ui     = uifSvc.xian(id);

            return(ui);
        }
Exemplo n.º 7
0
        /// <summary>
        /// 热门微博用户排名
        /// </summary>
        /// <returns></returns>
        public IEnumerable <Models.UserInfo> GetPopularUser()
        {
            var uifSvc            = new DAL.UserInfoService();
            var PopularUserEntity = uifSvc.GetPopularUser();

            return(PopularUserEntity);
        }
Exemplo n.º 8
0
        /// <summary>
        /// 查询  登录方法
        /// </summary>
        /// <param name="uifo"></param>
        /// <returns></returns>
        public Models.UserInfo GetUserInfoWhere(Models.UserInfo uifo)
        {
            //using 执行完之后立即销毁
            var uifSvc = new DAL.UserInfoService();
            //return uifSvc.GetLogin(s =>(string.IsNullOrEmpty(s.UserEmail=email) &&  s.UserPassword == pwd));
            var loginEntity = uifSvc.GetLogin(uifo);

            return(loginEntity);
        }
Exemplo n.º 9
0
        //添加数据方法
        //string name, string email, string pwd, DateTime birthday, string region, string headPortrait, string autograph, bool states, DateTime registerTime
        public async Task AddUserInfo(string name, string email, string pwd)
        {
            //using 执行完之后立即销毁
            //using (var uifSvc = new DAL.UserInfoService())
            //{
            var uifSvc = new DAL.UserInfoService();
            await uifSvc.AddAsync(new Models.UserInfo {
                UserName = name, UserEmail = email, UserPassword = pwd
            });

            //}
        }
Exemplo n.º 10
0
        /// <summary>
        /// 登录成功后查询出用户的ID BLL层
        /// </summary>
        /// <param name="email"></param>
        /// <returns></returns>
        public IEnumerable <Models.UserInfo> getUserId(string email)
        {
            var uifSvc = new DAL.UserInfoService();

            return(uifSvc.getUserId(email));
        }
Exemplo n.º 11
0
        /// <summary>
        ///  注册
        /// </summary>
        /// <param name="UiDto"></param>
        /// <returns></returns>
        public int AddRegister(DTO.UserInfoDto UiDto)
        {
            var uifSvc = new DAL.UserInfoService();

            return(uifSvc.AddRegister(UiDto));
        }
Exemplo n.º 12
0
        //////////////////////////////////////////////////////////////////
        /// <summary>
        /// 关注、粉丝、微博数 BLL
        /// </summary>
        /// <param name="UserId"></param>
        /// <returns></returns>
        public int[] FFB(int UserId)
        {
            var uifSvc = new DAL.UserInfoService();

            return(uifSvc.FFB(UserId));
        }
Exemplo n.º 13
0
        /// <summary>
        /// 增加点赞数
        /// </summary>
        /// <param name="id"></param>
        /// <param name="Points"></param>
        public int Points_number(int id)
        {
            var uifSvc = new DAL.UserInfoService();

            return(uifSvc.Points_number(id));
        }