Merge branch 'Test.IRC' of http://192.168.3.69:2000/XCKJ/irc-netcore-api into Test.IRC

IRC_NewDev
he 2023-11-01 13:12:48 +08:00
commit 2036c63a59
4 changed files with 91 additions and 75 deletions

View File

@ -162,7 +162,8 @@ namespace IRaCIS.Core.Application.Service.Inspection
};
query = query.WhereIf(dto.SiteId != null, x => x.SiteId == dto.SiteId)
.Where(x => (x.TrialId == dto.TrialId) || (x.TrialId == null && x.CreateTime >= trialData.CreateTime && x.CreateTime <= trialData.TrialFinishTime))
//.Where(x => (x.TrialId == dto.TrialId) || (x.TrialId == null && x.CreateTime >= trialData.CreateTime && x.CreateTime <= trialData.TrialFinishTime))
.Where(x => x.TrialId == dto.TrialId )
#region 废弃
// .WhereIf(dto.BatchId != null && dto.ObjectRelationParentId == null && dto.GeneralId == null, x => x.BatchId == dto.BatchId)
@ -190,7 +191,7 @@ namespace IRaCIS.Core.Application.Service.Inspection
.WhereIf(dto.StartTime != null, x => x.CreateTime >= dto.StartTime)
.WhereIf(dto.EndTime != null, x => x.CreateTime <= dto.EndTime)
.WhereIf(dto.ModuleType != null, x => x.ModuleTypeId == dto.ModuleType)
.WhereIf(!dto.Description.IsNullOrEmpty(), x => x.Description == dto.Description)
.WhereIf(!dto.Description.IsNullOrEmpty(), x => x.Description.Contains(dto.Description)|| x.DescriptionCN.Contains(dto.Description))
.WhereIf(!dto.OpByUserName.IsNullOrEmpty(), x => x.CreateUserName.Contains(dto.OpByUserName))
//.WhereIf(!dto.SubjectInfo.IsNullOrEmpty(), x => x.SubjectCode.Contains(dto.SubjectInfo))
.WhereIf(dto.IsSign != null, x => x.IsSign == dto.IsSign);

View File

@ -70,6 +70,8 @@ namespace IRaCIS.Core.Application.Service.Third_partyProject.DTO
public Guid TrialReadingCriterionId { get; set; }
public string TrialReadingCriterionName { get; set; }
public List<string> StudyInstanceUidList { get; set; }
}
public class UpdateTaskImageStateCommand

View File

@ -24,6 +24,9 @@ namespace IRaCIS.Core.Application.Service
.ForMember(o => o.UserName, t => t.MapFrom(u => u.DoctorUser.UserName))
.ForMember(o => o.FullName, t => t.MapFrom(u => u.DoctorUser.FullName))
.ForMember(o => o.TrialReadingCriterionName, t => t.MapFrom(u => u.TrialReadingCriterion.CriterionName))
.ForMember(o => o.StudyInstanceUidList, t => t.MapFrom(u => u.SourceSubjectVisit.StudyList.Select(t=>t.StudyInstanceUid)))
;
}
}

View File

@ -919,10 +919,7 @@ namespace IRaCIS.Core.Infra.EFCore.Common
.Where(t => t.TrialEmailNoticeConfigId == entity.Id).Select(t =>
new { t.TrialEmailNoticeConfigId, t.EmailUserType, t.UserType }).ToList();
if (_userInfo.RequestUrl == "TrialEmailNoticeConfig/getTrialEmailNoticeConfigList")
{
extraIdentification = "/Auto";
}
await InsertInspection<TrialEmailNoticeConfig>(entity, type, x => new InspectionConvertDTO()
{
@ -1491,6 +1488,9 @@ namespace IRaCIS.Core.Infra.EFCore.Common
}
#endregion
#region 中心调研
// 中心调研表
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(TrialSiteSurvey)))
{
@ -1532,78 +1532,10 @@ namespace IRaCIS.Core.Infra.EFCore.Common
});
}
#endregion
// 既往手术史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousSurgery)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousSurgery;
await InsertInspection<PreviousSurgery>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
}, new
{
Type = ClinicalFileType.PreviousSurgery
});
}
// 既往放疗史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousHistory)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousHistory;
await InsertInspection<PreviousHistory>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
ObjectRelationParentId = x.SubjectVisitId,
}, new
{
Type = ClinicalFileType.PreviousHistory
});
}
// 其他治疗史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousOther)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousOther;
await InsertInspection<PreviousOther>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
ObjectRelationParentId = x.SubjectVisitId,
}, new
{
Type = ClinicalFileType.PreviousOther
});
}
//系统 Qc 问题
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(QCQuestion)))
@ -1691,6 +1623,9 @@ namespace IRaCIS.Core.Infra.EFCore.Common
}
#region 项目参与人员 项目site
// 项目中心 Site未稽查
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(TrialSite)))
@ -1760,6 +1695,7 @@ namespace IRaCIS.Core.Infra.EFCore.Common
});
}
#endregion
// 受试者
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(Subject)))
@ -1902,6 +1838,8 @@ namespace IRaCIS.Core.Infra.EFCore.Common
);
}
#region Dicom 非Dicom 既往手术史..临床数据
// Dicom
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(DicomStudy)))
{
@ -1952,6 +1890,78 @@ namespace IRaCIS.Core.Infra.EFCore.Common
});
}
// 既往手术史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousSurgery)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousSurgery;
await InsertInspection<PreviousSurgery>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
}, new
{
Type = ClinicalFileType.PreviousSurgery
});
}
// 既往放疗史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousHistory)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousHistory;
await InsertInspection<PreviousHistory>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
ObjectRelationParentId = x.SubjectVisitId,
}, new
{
Type = ClinicalFileType.PreviousHistory
});
}
// 其他治疗史
foreach (var item in entitys.Where(x => x.Entity.GetType() == typeof(PreviousOther)))
{
var type = GetEntityAuditOpt(item);
var entity = item.Entity as PreviousOther;
await InsertInspection<PreviousOther>(entity, type, x => new InspectionConvertDTO()
{
IsDistinctionInterface = false,
SubjectVisitId = x.SubjectVisitId,
ObjectRelationParentId2 = x.ClinicalDataTrialSetId,
ObjectRelationParentId = x.SubjectVisitId,
}, new
{
Type = ClinicalFileType.PreviousOther
});
}
#endregion
#region 阅片人入组