From 7051e68c099ada33eff6e08b447ff3405204c8c0 Mon Sep 17 00:00:00 2001 From: hang <872297557@qq.com> Date: Mon, 23 Sep 2024 10:50:11 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E9=83=A8=E5=88=86=E5=AD=97?= =?UTF-8?q?=E6=AE=B5=E6=9B=B4=E6=96=B0bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- IRaCIS.Core.Application/Service/Management/UserService.cs | 8 ++++---- .../Service/Reading/ShortcutKey/UserWLTemplateService.cs | 2 +- IRaCIS.Core.Domain/Management/UserLog.cs | 2 -- IRaCIS.Core.Infra.EFCore/Repository/ICommandRepository.cs | 2 +- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/IRaCIS.Core.Application/Service/Management/UserService.cs b/IRaCIS.Core.Application/Service/Management/UserService.cs index ffa3f86f3..bc420be2c 100644 --- a/IRaCIS.Core.Application/Service/Management/UserService.cs +++ b/IRaCIS.Core.Application/Service/Management/UserService.cs @@ -183,7 +183,7 @@ namespace IRaCIS.Core.Application.Service await VerifyUserEmailAsync(_userInfo.Id, _userInfo.UserTypeId, newEmail); - await _userRepository.UpdatePartialNowNoQueryAsync(_userInfo.Id, u => new User() + await _userRepository.UpdatePartialFromQueryAsync(_userInfo.Id, u => new User() { EMail = newEmail }); @@ -206,7 +206,7 @@ namespace IRaCIS.Core.Application.Service await VerifyUserPhoneAsync(_userInfo.Id, _userInfo.UserTypeId, newPhone); - await _userRepository.UpdatePartialNowNoQueryAsync(_userInfo.Id, u => new User() + await _userRepository.UpdatePartialFromQueryAsync(_userInfo.Id, u => new User() { Phone = newPhone }); @@ -223,7 +223,7 @@ namespace IRaCIS.Core.Application.Service await VerifyUserNameAsync(_userInfo.Id, newUserName); - await _userRepository.UpdatePartialNowNoQueryAsync(_userInfo.Id, u => new User() + await _userRepository.UpdatePartialFromQueryAsync(_userInfo.Id, u => new User() { UserName = newUserName }); @@ -277,7 +277,7 @@ namespace IRaCIS.Core.Application.Service await _mailVerificationService.AdminResetPwdSendEmailAsync(userId, pwd); - await _userRepository.UpdatePartialNowNoQueryAsync(userId, u => new User() + await _userRepository.UpdatePartialFromQueryAsync(userId, u => new User() { Password = MD5Helper.Md5(pwd), IsFirstAdd = true diff --git a/IRaCIS.Core.Application/Service/Reading/ShortcutKey/UserWLTemplateService.cs b/IRaCIS.Core.Application/Service/Reading/ShortcutKey/UserWLTemplateService.cs index 06c46e64a..6951b5ec6 100644 --- a/IRaCIS.Core.Application/Service/Reading/ShortcutKey/UserWLTemplateService.cs +++ b/IRaCIS.Core.Application/Service/Reading/ShortcutKey/UserWLTemplateService.cs @@ -101,7 +101,7 @@ namespace IRaCIS.Core.Application.Service [HttpPost] public async Task SetAutoCutNextTask(SetAutoCutNextTaskInDto inDto) { - await _userRepository.UpdatePartialNowNoQueryAsync(_userInfo.Id, x => new User() + await _userRepository.UpdatePartialFromQueryAsync(_userInfo.Id, x => new User() { AutoCutNextTask = inDto.AutoCutNextTask diff --git a/IRaCIS.Core.Domain/Management/UserLog.cs b/IRaCIS.Core.Domain/Management/UserLog.cs index b58b58084..9fd177286 100644 --- a/IRaCIS.Core.Domain/Management/UserLog.cs +++ b/IRaCIS.Core.Domain/Management/UserLog.cs @@ -24,5 +24,3 @@ public class UserLog : BaseAddAuditEntity } - - diff --git a/IRaCIS.Core.Infra.EFCore/Repository/ICommandRepository.cs b/IRaCIS.Core.Infra.EFCore/Repository/ICommandRepository.cs index feb8acd5c..20c3f3237 100644 --- a/IRaCIS.Core.Infra.EFCore/Repository/ICommandRepository.cs +++ b/IRaCIS.Core.Infra.EFCore/Repository/ICommandRepository.cs @@ -66,7 +66,7 @@ namespace IRaCIS.Core.Infra.EFCore /// EF跟踪方式 生成 部分字段立即更新,不会去数据库查询完整的实体,不符合我们稽查的需求 - Task UpdatePartialNowNoQueryAsync(Guid id, Expression> updateFactory, params EntityVerifyExp[] verify); + //Task UpdatePartialNowNoQueryAsync(Guid id, Expression> updateFactory, params EntityVerifyExp[] verify); /// EF跟踪方式 生成 部分字段更新,不会去数据库查询完整的实体,不符合我们稽查的需求 //Task UpdatePartialNoQueryAsync(Guid id, Expression> updateFactory, bool autoSave = false, params EntityVerifyExp[] verify);