修改QC质疑查询
parent
c5194c1c3a
commit
c00b63a1b0
|
@ -707,6 +707,8 @@ namespace IRaCIS.Core.Application.Service
|
||||||
join p in _frontAuditConfigRepository.Where(x => x.DictionaryCode!=null &&x.DictionaryCode!=string.Empty && x.EnumType == "Dictionary" && x.IsEnable) on u.Id equals p.ParentId
|
join p in _frontAuditConfigRepository.Where(x => x.DictionaryCode!=null &&x.DictionaryCode!=string.Empty && x.EnumType == "Dictionary" && x.IsEnable) on u.Id equals p.ParentId
|
||||||
select new
|
select new
|
||||||
{
|
{
|
||||||
|
//前端展示类型
|
||||||
|
//DataType=p.DataType,
|
||||||
Key = p.Code,
|
Key = p.Code,
|
||||||
Code = p.DictionaryCode,
|
Code = p.DictionaryCode,
|
||||||
Type = p.DictionaryType
|
Type = p.DictionaryType
|
||||||
|
@ -719,7 +721,7 @@ namespace IRaCIS.Core.Application.Service
|
||||||
{
|
{
|
||||||
list.Add(new
|
list.Add(new
|
||||||
{
|
{
|
||||||
|
//DataType="",
|
||||||
Key = "AuditState",
|
Key = "AuditState",
|
||||||
Code = trialtype == TrialQCProcess.SingleAudit ? "AuditStatePE" : "AuditStateRC",
|
Code = trialtype == TrialQCProcess.SingleAudit ? "AuditStatePE" : "AuditStateRC",
|
||||||
Type = "Code",
|
Type = "Code",
|
||||||
|
|
|
@ -112,7 +112,8 @@ namespace IRaCIS.Core.Application.Image.QA
|
||||||
.WhereIf(challengeQuery.VisitPlanArray != null && challengeQuery.VisitPlanArray?.Length > 0, svExpression)
|
.WhereIf(challengeQuery.VisitPlanArray != null && challengeQuery.VisitPlanArray?.Length > 0, svExpression)
|
||||||
//.WhereIf(!string.IsNullOrEmpty(challengeQuery.VisitPlanInfo), challengeQuery.VisitPlanInfo.Contains('.') ? t => t.SubjectVisit.InPlan == false : t => t.SubjectVisit.VisitNum == decimal.Parse(challengeQuery.VisitPlanInfo))
|
//.WhereIf(!string.IsNullOrEmpty(challengeQuery.VisitPlanInfo), challengeQuery.VisitPlanInfo.Contains('.') ? t => t.SubjectVisit.InPlan == false : t => t.SubjectVisit.VisitNum == decimal.Parse(challengeQuery.VisitPlanInfo))
|
||||||
.WhereIf(challengeQuery.IsUrgent != null, t => t.SubjectVisit.IsUrgent == challengeQuery.IsUrgent)
|
.WhereIf(challengeQuery.IsUrgent != null, t => t.SubjectVisit.IsUrgent == challengeQuery.IsUrgent)
|
||||||
.WhereIf(challengeQuery.IsOverTime != null, t => DateTime.Now > t.DeadlineTime)
|
.WhereIf(challengeQuery.IsOverTime != null && challengeQuery.IsOverTime==true, t => t.IsClosed ? t.ClosedTime > t.DeadlineTime : DateTime.Now > t.DeadlineTime)
|
||||||
|
.WhereIf(challengeQuery.IsOverTime != null && challengeQuery.IsOverTime == false, t => t.IsClosed ? t.ClosedTime < t.DeadlineTime : DateTime.Now < t.DeadlineTime)
|
||||||
.ProjectTo<QCChanllengeExportDto>(_mapper.ConfigurationProvider).ToListAsync();
|
.ProjectTo<QCChanllengeExportDto>(_mapper.ConfigurationProvider).ToListAsync();
|
||||||
|
|
||||||
list = list.OrderBy(t => t.TrialSiteCode).ThenBy(t => t.SubjectCode).ThenBy(t => t.ChallengeCode).ToList();
|
list = list.OrderBy(t => t.TrialSiteCode).ThenBy(t => t.SubjectCode).ThenBy(t => t.ChallengeCode).ToList();
|
||||||
|
@ -973,7 +974,8 @@ namespace IRaCIS.Core.Application.Image.QA
|
||||||
.WhereIf(challengeQuery.VisitPlanArray != null && challengeQuery.VisitPlanArray?.Length > 0, svExpression)
|
.WhereIf(challengeQuery.VisitPlanArray != null && challengeQuery.VisitPlanArray?.Length > 0, svExpression)
|
||||||
//.WhereIf(!string.IsNullOrEmpty(challengeQuery.VisitPlanInfo), challengeQuery.VisitPlanInfo.Contains('.') ? t => t.SubjectVisit.InPlan == false : t => t.SubjectVisit.VisitNum == decimal.Parse(challengeQuery.VisitPlanInfo))
|
//.WhereIf(!string.IsNullOrEmpty(challengeQuery.VisitPlanInfo), challengeQuery.VisitPlanInfo.Contains('.') ? t => t.SubjectVisit.InPlan == false : t => t.SubjectVisit.VisitNum == decimal.Parse(challengeQuery.VisitPlanInfo))
|
||||||
.WhereIf(challengeQuery.IsUrgent != null, t => t.SubjectVisit.IsUrgent == challengeQuery.IsUrgent)
|
.WhereIf(challengeQuery.IsUrgent != null, t => t.SubjectVisit.IsUrgent == challengeQuery.IsUrgent)
|
||||||
.WhereIf(challengeQuery.IsOverTime != null, t => DateTime.Now > t.DeadlineTime)
|
.WhereIf(challengeQuery.IsOverTime != null && challengeQuery.IsOverTime == true, t => t.IsClosed ? t.ClosedTime > t.DeadlineTime : DateTime.Now > t.DeadlineTime)
|
||||||
|
.WhereIf(challengeQuery.IsOverTime != null && challengeQuery.IsOverTime == false, t => t.IsClosed ? t.ClosedTime < t.DeadlineTime : DateTime.Now < t.DeadlineTime)
|
||||||
.ProjectTo<QCCRCChallengeViewModel>(_mapper.ConfigurationProvider);
|
.ProjectTo<QCCRCChallengeViewModel>(_mapper.ConfigurationProvider);
|
||||||
|
|
||||||
var pageList = await query.ToPagedListAsync(challengeQuery.PageIndex, challengeQuery.PageSize, challengeQuery.SortField, challengeQuery.Asc, string.IsNullOrWhiteSpace(challengeQuery.SortField), new string[] { "IsUrgent desc", "IsClosed asc" });
|
var pageList = await query.ToPagedListAsync(challengeQuery.PageIndex, challengeQuery.PageSize, challengeQuery.SortField, challengeQuery.Asc, string.IsNullOrWhiteSpace(challengeQuery.SortField), new string[] { "IsUrgent desc", "IsClosed asc" });
|
||||||
|
|
|
@ -2272,6 +2272,8 @@ namespace IRaCIS.Core.Infra.EFCore.Common
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (inspection.VisitTaskId != null)
|
if (inspection.VisitTaskId != null)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -2292,6 +2294,16 @@ namespace IRaCIS.Core.Infra.EFCore.Common
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (inspection.TrialReadingCriterionId == null)
|
||||||
|
{
|
||||||
|
if (generalData.TrialId == null)
|
||||||
|
{
|
||||||
|
var info = await _dbContext.ReadingQuestionCriterionTrial.Where(x => x.Id == inspection.TrialReadingCriterionId).Select(x => new { x.TrialId }).FirstOrDefaultAsync();
|
||||||
|
|
||||||
|
generalData.TrialId = info?.TrialId ?? generalData.TrialId;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Suject visit 都进行了设置 不用处理
|
// Suject visit 都进行了设置 不用处理
|
||||||
|
|
||||||
if (inspection.SubjectVisitId != null)
|
if (inspection.SubjectVisitId != null)
|
||||||
|
|
Loading…
Reference in New Issue