fix 人员更新异动
This commit is contained in:
@@ -285,9 +285,18 @@ public class GainfoUpdateService : IGainfoUpdateService
|
||||
ResignationDate = item.ZLZRQ,
|
||||
Workplace = workplace,
|
||||
Factory = factory,
|
||||
ModifiedTime = DateTime.Now
|
||||
}).Where(x => x.Code == item.ename).ExecuteCommandAsync();
|
||||
|
||||
await _identityUserSyncService.SyncAccountAsync(gainfo.Code, gainfo.Name, gainfo.IdNo, factory);
|
||||
if (gainfo.Factory != factory)
|
||||
{
|
||||
await _identityUserSyncService.SyncAccountAsync(gainfo.Code, gainfo.Name, gainfo.IdNo, factory);
|
||||
}
|
||||
|
||||
if (gainfo.Factory != factory || gainfo.Workplace != workplace || gainfo.DepartmentNo != item.appellation)
|
||||
{
|
||||
await _gainfoPermissionService.ResetPermissionsAsync(gainfo.No, DeviceTaskEnumType.Delete, null, "异动生成");
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -346,7 +355,7 @@ public class GainfoUpdateService : IGainfoUpdateService
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
await _dbContext.Client.Ado.CommitTranAsync();
|
||||
}
|
||||
catch (Exception ex)
|
||||
|
||||
Reference in New Issue
Block a user