修改查询
continuous-integration/drone/push Build is passing Details

Uat_IRC_Net8
hang 2025-01-03 17:58:33 +08:00
parent 5faf1a5442
commit 69151bbddb
1 changed files with 4 additions and 2 deletions

View File

@ -61,8 +61,10 @@ namespace IRaCIS.Core.Application.Service
throw new BusinessValidationFailedException("Id 或者VisitTaskId 必传一个");
}
var result = await _userFeedBackRepository.WhereIf(inQuery.Id == null, t => t.VisitTaskId == inQuery.VisitTaskId)
.WhereIf(inQuery.VisitTaskId == null, t => t.Id == inQuery.Id).ProjectTo<UserFeedBackView>(_mapper.ConfigurationProvider).FirstOrDefaultAsync();
var result = await _userFeedBackRepository
.WhereIf(inQuery.Id != null, t => t.Id == inQuery.Id)
.WhereIf(inQuery.VisitTaskId != null, t => t.VisitTaskId == inQuery.VisitTaskId)
.ProjectTo<UserFeedBackView>(_mapper.ConfigurationProvider).FirstOrDefaultAsync();