diff --git a/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs b/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs index 982f116ed..745d6993e 100644 --- a/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs +++ b/IRaCIS.Core.Application/Service/Document/TrialDocumentService.cs @@ -96,11 +96,12 @@ namespace IRaCIS.Core.Application.Services [HttpPost] public async Task PublishTrialDocument(PublishTrialDocumentInDto inDto) { - await _trialDocumentRepository.BatchUpdateNoTrackingAsync(x => inDto.Ids.Contains(x.Id), x => new TrialDocument() + await _trialDocumentRepository.UpdatePartialFromQueryAsync(x => inDto.Ids.Contains(x.Id), x => new TrialDocument() { IsPublish = true, IsDeleted = false, }); + await _trialDocumentRepository.SaveChangesAsync(); Console.WriteLine("开始 发布项目文档"); Task.Run(async () =>