public bool DoesEmailExists(string Email) { var _db = DolphinDb.GetInstance(); var rslt = _db.SingleOrDefault <DolUser>("where Email=@0", Email); if (rslt == null) { return(false); } else { return(true); } }
public bool DoesUsernameExists(string Username) { var _db = DolphinDb.GetInstance(); var rslt = _db.SingleOrDefault <DolUser>("where UserName=@0", Username); if (rslt == null) { return(false); } else { return(true); } }
public bool IsCompanyActive(string username) { var _db = DolphinDb.GetInstance(); string sql = "select A.*,B.* from Dol_User A inner join Dol_Client B on B.ClientId=A.ClientId inner join User_Role C on C.RoleId=A.RoleId where A.UserName=@0"; var result = _db.SingleOrDefault <UserDetailsObj>(sql, username); if (result.IsClientActive) { return(true); } else { return(false); } }
public bool IsUserActive(string Username, string Password) { var _db = DolphinDb.GetInstance(); string _password = new EncryptionManager().EncryptValue(Password); var rslt = _db.FirstOrDefault <DolUser>("where UserName=@0 and Password=@1", Username, _password); if (rslt.Isuseractive == true) { return(true); } else { return(false); } }
public bool DoesPasswordExists(string Username, string Password) { var _db = DolphinDb.GetInstance(); string password = new EncryptionManager().EncryptValue(Password); var rslt = _db.FirstOrDefault <DolUser>("where UserName=@0 and Password=@1", Username, password); if (rslt != null) { return(true); } else { return(false); } }