示例#1
0
 public static PasswordReset Create(long userId, int expiresInMinutesFromNow)
 {
     return(Create(User.OneWhere(c => c.Id == userId), expiresInMinutesFromNow));
 }
示例#2
0
 /// <summary>
 /// Get the user with the specified email address
 /// </summary>
 /// <param name="email"></param>
 /// <returns></returns>
 public static User GetByEmail(string email, Database database = null)
 {
     return(User.OneWhere(c => c.Email == email && c.IsDeleted != true, database));
 }
示例#3
0
 public static PasswordReset Create(string userName, int expiresInMinutesFromNow)
 {
     return(Create(User.OneWhere(c => c.UserName == userName), expiresInMinutesFromNow));
 }
示例#4
0
 /// <summary>
 /// Get the user with the specified userName or null if the user is not found
 /// </summary>
 /// <param name="userName"></param>
 /// <returns></returns>
 public static User GetByUserName(string userName, Database db = null)
 {
     return(User.OneWhere(c => c.UserName == userName && c.IsDeleted != true, db));
 }