Uat_Study
he 2023-07-18 11:30:41 +08:00
parent f85c51f7de
commit 24b2067f50
3 changed files with 26 additions and 19 deletions

View File

@ -204,7 +204,7 @@ namespace IRaCIS.Core.Application
ToBeRepliedCount = t.SubjectVisitList.Where(u => u.CheckState == CheckStateEnum.CVIng &&
u.CheckChallengeDialogList.OrderByDescending(t => t.CreateTime).First().UserTypeEnum == UserTypeEnum.ClinicalResearchCoordinator).Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
@ -247,7 +247,7 @@ namespace IRaCIS.Core.Application
UrgentCount = g.Where(u => u.OriginalReReadingTask.IsUrgent == true).Count(),
ToBeApprovalCount = g.Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ReReadingApplyToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -285,7 +285,7 @@ namespace IRaCIS.Core.Application
IsUrgent = t.IsUrgent || t.IsSubjectExpeditedView,
ToBeApprovalCount = t.EnrollList.Where(u => u.EnrollStatus == EnrollStatus.InviteIntoGroup).Count()
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ReviewerSelectToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -317,7 +317,7 @@ namespace IRaCIS.Core.Application
ToBeApprovalCount = t.ReadModuleList.Where(u => u.IsCRCConfirm&&!u.IsPMConfirm).Count()
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ReviewerSelectToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -362,7 +362,7 @@ namespace IRaCIS.Core.Application
IsUrgent = t.IsUrgent || t.IsSubjectExpeditedView,
ToBeApprovalCount = t.EnrollList.Where(u => u.EnrollStatus == EnrollStatus.HasCommittedToCRO).Count()
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ReviewerSelectToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -399,7 +399,7 @@ namespace IRaCIS.Core.Application
UrgentCount = g.Where(u => u.OriginalReReadingTask.IsUrgent == true).Count(),
ToBeApprovalCount = g.Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ReReadingApprovalToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -440,9 +440,9 @@ namespace IRaCIS.Core.Application
ExperimentName = t.ExperimentName,
TrialCode = t.TrialCode,
UrgentCount = t.SubjectVisitList.Where(u => u.IsBaseLine && u.SubmitState != SubmitStateEnum.Submitted && u.IsUrgent).Count(),
ToBeDealedCount = t.SubjectVisitList.Where(u => u.IsBaseLine && u.SubmitState != SubmitStateEnum.Submitted).Count(),
ToBeDealedCount = t.ReadingClinicalDataList.Where(x=>!x.IsSign&& x.ClinicalDataTrialSet.UploadRole == UploadRole.CRC && x.ClinicalDataTrialSet.ClinicalDataLevel != ClinicalLevel.SubjectVisit).Count(),
});
}).Where(x=>x.ToBeDealedCount>0);
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageClinicalDataToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -489,7 +489,7 @@ namespace IRaCIS.Core.Application
.Where(u => u.IsClosed == false && u.LatestReplyUser.UserTypeEnum == UserTypeEnum.IQC).Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageQuestionToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -530,7 +530,7 @@ namespace IRaCIS.Core.Application
ToBeReplyedCount = t.SubjectVisitList.Where(c => c.TrialSite.CRCUserList.Any(u => u.UserId == _userInfo.Id))
.Where(u => u.CheckState == CheckStateEnum.CVIng && u.CheckChallengeState == CheckChanllengeTypeEnum.PMWaitCRCReply).Count()
});
}).Where(x => x.ToBeDealedCount > 0); ;
@ -576,7 +576,7 @@ namespace IRaCIS.Core.Application
.Where(c => c.TrialSite.CRCUserList.Any(u => u.UserId == _userInfo.Id))
.Where(u => u.SubmitState == SubmitStateEnum.ToSubmit && u.IsPMBackOrReReading).Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageReUploadToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -620,7 +620,7 @@ namespace IRaCIS.Core.Application
.Where(c => c.TrialSite.CRCUserList.Any(u => u.UserId == _userInfo.Id))
.Where(u => u.SubmitState == SubmitStateEnum.ToSubmit).Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageSubmittedToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -673,7 +673,7 @@ namespace IRaCIS.Core.Application
//待审核通过统计从已领取到QC提交之间的 已领取 待审核 审核中 (审核完成 领取人就会清理 所以只用查询当前领取人是自己的就好了)
ToBeReviewedCount = t.SubjectVisitList.Where(u => u.CurrentActionUserId == _userInfo.Id).Count()
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageQualityToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -718,7 +718,7 @@ namespace IRaCIS.Core.Application
ToBeDealedCount = t.SubjectVisitList.SelectMany(c => c.QCChallengeList)
.Where(u => u.CreateUserId == _userInfo.Id && u.IsClosed == false && u.LatestReplyUser.UserTypeEnum == UserTypeEnum.ClinicalResearchCoordinator).Count(),
});
}).Where(x => x.ToBeDealedCount > 0); ;
var result = await query.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrEmpty(inQuery.SortField) ? nameof(ImageQuestionToBeDoneDto.TrialId) : inQuery.SortField, inQuery.Asc);
@ -790,9 +790,9 @@ namespace IRaCIS.Core.Application
HaveSignedCount = c.VisitTaskList.Where(t => t.DoctorUserId == _userInfo.Id && (t.TaskState == TaskState.Effect || t.TaskState == TaskState.Freeze)
&& t.ReadingTaskState == ReadingTaskState.HaveSigned).Count(),
})
}).Where(x => x.ToBeDealedCount > 0);
;
;
#region 废弃
//var query = _trialRepository

View File

@ -75,7 +75,14 @@ namespace IRaCIS.Core.Domain.Models
public ClinicalDataTrialSet ClinicalDataTrialSet { get; set; }
[JsonIgnore]
[JsonIgnore]
[ForeignKey("TrialId")]
public Trial Trial { get; set; }
[JsonIgnore]
[ForeignKey("ReadingId")]
public SubjectVisit SubjectVisit { get; set; }

View File

@ -85,8 +85,8 @@ namespace IRaCIS.Core.Domain.Models
public virtual ICollection<TrialStatusDetail> ClinicalTrialProjectDetails { get; set; }
[JsonIgnore]
public virtual ICollection<TrialDictionary> TrialDicList { get; set; }
[JsonIgnore]
public List<ReadingClinicalData> ReadingClinicalDataList { get; set; }
[StringLength(100)]
public string TrialCode { get; set; } = string.Empty;