Ejemplo n.º 1
0
 /// <summary>
 /// web global use
 /// </summary>
 /// <param name="ticket"></param>
 public MVCUser(FormsAuthenticationTicket ticket)
     : this(ticket.Name, AuthenticationTicketUserData.FromString(ticket.UserData))
 {
     if (ticket == null)
     {
         throw new ArgumentNullException("ticket");
     }
 }
Ejemplo n.º 2
0
 public MVCUser(string name, AuthenticationTicketUserData userData)
 {
     if (userData == null)
     {
         throw new ArgumentNullException("userData");
     }
     this.Name     = name;
     this.UserId   = userData.UserId;
     this.RoleName = userData.RoleName;
     this.Roles    = userData.Roles;
     this.ClassID  = userData.ClassID;
     this.Dept     = userData.Dept;
     this.FacId    = userData.FacID;
     this.Tel      = userData.Tel;
 }