修改异地登录ip逻辑
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
dd6419dc44
commit
a43ebc016a
|
@ -970,12 +970,6 @@ namespace IRaCIS.Core.Application.Service
|
|||
|
||||
if (existUserLoginInfo.LastLoginIP != string.Empty)
|
||||
{
|
||||
// 与上一次区域不一致
|
||||
if (SplitAndConcatenate(existUserLoginInfo.LastLoginIP) != SplitAndConcatenate(iPRegion))
|
||||
{
|
||||
|
||||
isLoginUncommonly = true;
|
||||
|
||||
//设置上次登录的IP
|
||||
await _identityUserRepository.BatchUpdateNoTrackingAsync(x => x.Id == existUserLoginInfo.Id, x => new IdentityUser()
|
||||
{
|
||||
|
@ -984,6 +978,14 @@ namespace IRaCIS.Core.Application.Service
|
|||
|
||||
});
|
||||
|
||||
|
||||
// 与上一次区域不一致
|
||||
if (SplitAndConcatenate(existUserLoginInfo.LastLoginIP) != SplitAndConcatenate(iPRegion))
|
||||
{
|
||||
|
||||
isLoginUncommonly = true;
|
||||
|
||||
|
||||
if (loginUser != null)
|
||||
{
|
||||
//异地登录
|
||||
|
|
Loading…
Reference in New Issue