diff --git a/IRaCIS.Core.Application/Service/TrialSiteUser/PersonalWorkstation.cs b/IRaCIS.Core.Application/Service/TrialSiteUser/PersonalWorkstation.cs index 5f4d4ef47..114460c00 100644 --- a/IRaCIS.Core.Application/Service/TrialSiteUser/PersonalWorkstation.cs +++ b/IRaCIS.Core.Application/Service/TrialSiteUser/PersonalWorkstation.cs @@ -1151,7 +1151,7 @@ namespace IRaCIS.Core.Application .Where(c => c.TrialDocumentList.Where(t => t.IsDeleted == false && t.NeedConfirmedUserTypeList.Any(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId) && !t.TrialDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null)).Count() > 0).CountAsync(); - var needSignSysDocCont = await _systemDocumentRepository.AsQueryable(true) + var needSignSysDocCont = await _systemDocumentRepository.Where(t => t.IsPublish) .Where(t => t.IsDeleted == false && !t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null)) //外部人员 只签署 外部需要签署的 .WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter) @@ -1159,19 +1159,19 @@ namespace IRaCIS.Core.Application .CountAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId); //电子阅片声明是否已经签署 - var isfirstSysDocNeedSign = await _systemDocumentRepository.AsQueryable(true) + var isfirstSysDocNeedSign = await _systemDocumentRepository.Where(t => t.IsPublish) .Where(t => t.IsDeleted == false && !t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null)) //外部人员 只签署 外部需要签署的 .WhereIf(isInternal == false, t => t.DocUserSignType == DocUserSignType.InnerAndOuter) .SelectMany(t => t.NeedConfirmedUserTypeList) .AnyAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId && t.SystemDocument.FileType.Code == "-1"); - var signedTrialCount = await _trialDocumentRepository.AsQueryable(true) + var signedTrialCount = await _trialDocumentRepository.Where(t => t.IsPublish) .Where(t => t.Trial.TrialIdentityUserList.Any(t => t.IdentityUserId == _userInfo.IdentityUserId && t.TrialUserRoleList.Any(t => t.UserRole.UserTypeId == _userInfo.UserTypeId))) .Where(t => t.NeedConfirmedUserTypeList.Any(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId)) .Where(t => t.TrialDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null)).CountAsync(); - var signedSysDocCont = await _systemDocumentRepository.AsQueryable(true) + var signedSysDocCont = await _systemDocumentRepository.Where(t=>t.IsPublish) .Where(t => t.SystemDocConfirmedUserList.Any(t => t.ConfirmUserId == _userInfo.IdentityUserId && t.ConfirmTime != null)) .SelectMany(t => t.NeedConfirmedUserTypeList) .CountAsync(t => t.NeedConfirmUserTypeId == _userInfo.UserTypeId);