功能修改
This commit is contained in:
@@ -194,6 +194,81 @@ namespace IRaCIS.Core.Application.Contracts
|
||||
|
||||
}
|
||||
|
||||
public class EditPatientInfoCommand
|
||||
{
|
||||
public Guid StudyId { get; set; }
|
||||
/// <summary>
|
||||
/// 性别
|
||||
/// </summary>
|
||||
public string PatientSex { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 体重
|
||||
/// </summary>
|
||||
public string PatientWeight { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总剂量
|
||||
/// </summary>
|
||||
public string RadionuclideTotalDose { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 半衰期
|
||||
/// </summary>
|
||||
public string RadionuclideHalfLife { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 注射时间
|
||||
/// </summary>
|
||||
public string RadiopharmaceuticalStartTime { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 成像 / 采集时间
|
||||
/// </summary>
|
||||
public string AcquisitionTime { get; set; } = null!;
|
||||
}
|
||||
|
||||
public class GetPatientInfoInDto
|
||||
{
|
||||
public Guid StudyId { get; set; }
|
||||
}
|
||||
|
||||
public class PatientInfoDto
|
||||
{
|
||||
|
||||
public Guid StudyId { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 性别
|
||||
/// </summary>
|
||||
public string PatientSex { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 体重
|
||||
/// </summary>
|
||||
public string PatientWeight { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// 总剂量
|
||||
/// </summary>
|
||||
public string RadionuclideTotalDose { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 半衰期
|
||||
/// </summary>
|
||||
public string RadionuclideHalfLife { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 注射时间
|
||||
/// </summary>
|
||||
public string RadiopharmaceuticalStartTime { get; set; } = null!;
|
||||
|
||||
/// <summary>
|
||||
/// 成像 / 采集时间
|
||||
/// </summary>
|
||||
public string AcquisitionTime { get; set; } = null!;
|
||||
}
|
||||
|
||||
public class PreArchiveDicomStudyCommand
|
||||
{
|
||||
|
||||
|
||||
@@ -177,6 +177,41 @@ namespace IRaCIS.Core.Application.Service.ImageAndDoc
|
||||
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 获取患者基本信息
|
||||
/// </summary>
|
||||
/// <param name="inDto"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<PatientInfoDto> GetPatientInfo(GetPatientInfoInDto inDto)
|
||||
{
|
||||
var study = await _dicomStudyRepository.Where(s => s.Id == inDto.StudyId).ProjectTo<PatientInfoDto>(_mapper.ConfigurationProvider).FirstNotNullAsync();
|
||||
|
||||
return study;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 编辑患者基本信息
|
||||
/// </summary>
|
||||
/// <param name="command"></param>
|
||||
/// <returns></returns>
|
||||
[HttpPost]
|
||||
public async Task<IResponseOutput> EditPatientInfo(EditPatientInfoCommand command)
|
||||
{
|
||||
await _dicomStudyRepository.UpdatePartialFromQueryAsync(command.StudyId, x => new DicomStudy
|
||||
{
|
||||
PatientSex = command.PatientSex,
|
||||
PatientWeight = command.PatientWeight,
|
||||
RadionuclideTotalDose = command.RadionuclideTotalDose,
|
||||
RadionuclideHalfLife = command.RadionuclideHalfLife,
|
||||
RadiopharmaceuticalStartTime = command.RadiopharmaceuticalStartTime,
|
||||
AcquisitionTime = command.AcquisitionTime,
|
||||
});
|
||||
await _dicomStudyRepository.SaveChangesAsync();
|
||||
|
||||
return ResponseOutput.Ok();
|
||||
}
|
||||
|
||||
|
||||
[TrialGlobalLimit("AfterStopCannNotOpt")]
|
||||
|
||||
@@ -440,13 +475,13 @@ namespace IRaCIS.Core.Application.Service.ImageAndDoc
|
||||
{
|
||||
await _dicomStudyRepository.UpdatePartialFromQueryAsync(t => t.Id == findStudy.Id, u => new DicomStudy()
|
||||
{
|
||||
RadionuclideTotalDose = incommand.Study.RadionuclideTotalDose.IsNotNullOrEmpty()? incommand.Study.RadionuclideTotalDose : findStudy.RadionuclideTotalDose,
|
||||
RadionuclideTotalDose = incommand.Study.RadionuclideTotalDose.IsNotNullOrEmpty() ? incommand.Study.RadionuclideTotalDose : findStudy.RadionuclideTotalDose,
|
||||
RadionuclideHalfLife = incommand.Study.RadionuclideHalfLife.IsNotNullOrEmpty() ? incommand.Study.RadionuclideHalfLife : findStudy.RadionuclideHalfLife,
|
||||
RadiopharmaceuticalStartTime = incommand.Study.RadiopharmaceuticalStartTime.IsNotNullOrEmpty() ? incommand.Study.RadiopharmaceuticalStartTime : findStudy.RadiopharmaceuticalStartTime
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -25,6 +25,8 @@ namespace IRaCIS.Core.Application.Service
|
||||
|
||||
CreateMap<AddInstanceDto, TaskInstance>();
|
||||
|
||||
CreateMap<DicomStudy, PatientInfoDto>();
|
||||
|
||||
|
||||
CreateMap<DicomSeries, DicomSeriesWithLabelDTO>();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user