Ejemplo n.º 1
0
        public User GetUesr8Openid(string openid, MODEL.OpenType opentype)
        {
            IQuery query = session.CreateQuery("select u from User u where u.Openid='" + openid + "' and u.Opentype=" + (int)opentype);

            MODEL.User user = query.FutureValue <MODEL.User>().Value;
            return(user);
        }
Ejemplo n.º 2
0
 public void CreateUser(string username, string openid, MODEL.OpenType opentype)
 {
     MODEL.User user = GetUser8Name(username);
     while (user != null)
     {
         username += user + "0";
         user      = GetUser8Name(username);
     }
     MODEL.User newuser = new MODEL.User()
     {
         Name          = username,
         Openid        = openid,
         Opentype      = opentype,
         Avatar        = "/img/mavatar/M_001.jpg",
         CreateTime    = DateTime.Now,
         LastLoginTime = DateTime.Now
     };
     daluser.CreateUser(newuser);
 }
Ejemplo n.º 3
0
 public User GetUesr8Openid(string openid, MODEL.OpenType opentype)
 {
     return(daluser.GetUesr8Openid(openid, opentype));
 }