修改一版代码
parent
873d4af8da
commit
2a695259c7
|
@ -54,6 +54,7 @@ namespace IRaCIS.Core.API.Controllers
|
||||||
ITrialConfigService _trialConfigService,
|
ITrialConfigService _trialConfigService,
|
||||||
INoneDicomStudyService noneDicomStudyService,
|
INoneDicomStudyService noneDicomStudyService,
|
||||||
ISubjectService _subjectService,
|
ISubjectService _subjectService,
|
||||||
|
|
||||||
ISubjectVisitService subjectVisitService,
|
ISubjectVisitService subjectVisitService,
|
||||||
IQCOperationService qCOperationService,
|
IQCOperationService qCOperationService,
|
||||||
IClinicalDataService clinicalDataService,
|
IClinicalDataService clinicalDataService,
|
||||||
|
@ -88,8 +89,26 @@ namespace IRaCIS.Core.API.Controllers
|
||||||
return await _inspectionService.GetInspectionData(dto);
|
return await _inspectionService.GetInspectionData(dto);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#region 影像质疑
|
||||||
|
/// <summary>
|
||||||
|
/// 手动领取 或者取消 QC任务
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="opt"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
[HttpPost, Route("Inspection/QCOperation/ObtainOrCancelQCTask")]
|
||||||
|
[UnitOfWork]
|
||||||
|
public async Task<IResponseOutput> ObtainOrCancelQCTask(DataInspectionDto<ObtainOrCancelQCTaskDto> opt)
|
||||||
|
{
|
||||||
|
var fun = await _qCOperationService.ObtainOrCancelQCTask(opt.OptCommand.trialId, opt.OptCommand.subjectVisitId, opt.OptCommand.obtaionOrCancel);
|
||||||
|
if (!fun.IsSuccess)
|
||||||
|
{
|
||||||
|
return ResponseOutput.NotOk(fun.ErrorMessage);
|
||||||
|
}
|
||||||
|
return await _inspectionService.Enforcement(opt.OptCommand, opt.AuditInfo, opt.SignInfo, null, fun);
|
||||||
|
}
|
||||||
|
|
||||||
#region Qc
|
#endregion
|
||||||
|
#region 影像上传
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -195,9 +214,7 @@ namespace IRaCIS.Core.API.Controllers
|
||||||
return await _inspectionService.Enforcement(opt.OptCommand.Id, opt.AuditInfo, opt.SignInfo, fun);
|
return await _inspectionService.Enforcement(opt.OptCommand.Id, opt.AuditInfo, opt.SignInfo, fun);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region 临床数据采集 ClinicalDataService
|
#region 临床数据采集 ClinicalDataService
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 新增或修改既往放疗史
|
/// 新增或修改既往放疗史
|
||||||
|
@ -291,8 +308,6 @@ namespace IRaCIS.Core.API.Controllers
|
||||||
return await _inspectionService.Enforcement(opt.OptCommand.Id, opt.AuditInfo, opt.SignInfo, fun);
|
return await _inspectionService.Enforcement(opt.OptCommand.Id, opt.AuditInfo, opt.SignInfo, fun);
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
#region 访视计划
|
#region 访视计划
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 新增或添加访视计划
|
/// 新增或添加访视计划
|
||||||
|
|
|
@ -160,6 +160,13 @@ namespace IRaCIS.Core.Application.Service.Inspection.DTO
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
||||||
|
public class ObtainOrCancelQCTaskDto
|
||||||
|
{
|
||||||
|
public Guid trialId { get; set; }
|
||||||
|
public Guid subjectVisitId { get; set; }
|
||||||
|
public bool obtaionOrCancel { get; set; }
|
||||||
|
}
|
||||||
|
|
||||||
public class DataInspectionDto<T> : IInspectionDTO, ISignDTO
|
public class DataInspectionDto<T> : IInspectionDTO, ISignDTO
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
|
@ -266,6 +266,26 @@ namespace IRaCIS.Application.Services
|
||||||
|
|
||||||
var isSuccess = await _subjectRepository.DeleteFromQueryAsync(u => u.Id == id);
|
var isSuccess = await _subjectRepository.DeleteFromQueryAsync(u => u.Id == id);
|
||||||
await _repository.DeleteFromQueryAsync<SubjectVisit>(u => u.SubjectId == id);
|
await _repository.DeleteFromQueryAsync<SubjectVisit>(u => u.SubjectId == id);
|
||||||
|
var subvisit = await _repository.GetQueryable<SubjectVisit>().Where(x=>x.SubjectId==id).ToListAsync();
|
||||||
|
|
||||||
|
List<DataInspection> datas = new List<DataInspection>();
|
||||||
|
|
||||||
|
foreach (var item in subvisit)
|
||||||
|
{
|
||||||
|
datas.Add(new DataInspection()
|
||||||
|
{
|
||||||
|
SiteId = item.SiteId,
|
||||||
|
SubjectId = item.SubjectId,
|
||||||
|
TrialId = item.TrialId,
|
||||||
|
SubjectVisitId = item.Id,
|
||||||
|
Identification = "Delete|Visit|Data|Visit-Image Upload",
|
||||||
|
JsonDetail = JsonConvert.SerializeObject(item)
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
await _inspectionService.AddListInspectionRecordAsync(datas);
|
||||||
return ResponseOutput.Result(isSuccess);
|
return ResponseOutput.Result(isSuccess);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue