返回课题组编码 和AE 限制
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
d1e08b0fc0
commit
26e7305bcf
|
|
@ -108,20 +108,26 @@ namespace IRaCIS.Core.SCP.Service
|
||||||
|
|
||||||
var _hospitalGroupRepository = _serviceProvider.GetService<IRepository<HospitalGroup>>();
|
var _hospitalGroupRepository = _serviceProvider.GetService<IRepository<HospitalGroup>>();
|
||||||
|
|
||||||
|
var _dicomAERepository = _serviceProvider.GetService<IRepository<DicomAE>>();
|
||||||
|
|
||||||
|
var aeList = _dicomAERepository/*.Where(t => t.PacsTypeEnum == PacsType.PacsServer)*/.Select(t => t.CalledAE).ToList();
|
||||||
|
|
||||||
|
|
||||||
var list = _hospitalGroupRepository.Where(t => t.IsEnable).ToList();
|
var list = _hospitalGroupRepository.Where(t => t.IsEnable).ToList();
|
||||||
|
|
||||||
CurrentHospitalGroup = list.FirstOrDefault(t => t.CallingAE == Association.CallingAE);
|
CurrentHospitalGroup = list.FirstOrDefault(t => t.CallingAE == association.CallingAE);
|
||||||
|
|
||||||
|
|
||||||
|
var unionAEList = aeList.Union(list.Select(t => t.CallingAE)).ToList();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
var calledAEList = option.CalledAEList;
|
var calledAEList = option.CalledAEList;
|
||||||
|
|
||||||
if (!calledAEList.Contains(association.CalledAE))
|
if (!calledAEList.Contains(association.CalledAE) || !unionAEList.Any(t => t == association.CallingAE))
|
||||||
{
|
{
|
||||||
|
|
||||||
Log.Logger.Warning($"拒绝CalledAE:{association.CalledAE}的连接");
|
Log.Logger.Warning($"拒绝CalledAE:{association.CalledAE} CallingAE:{association.CallingAE}连接");
|
||||||
|
|
||||||
return SendAssociationRejectAsync(
|
return SendAssociationRejectAsync(
|
||||||
DicomRejectResult.Permanent,
|
DicomRejectResult.Permanent,
|
||||||
|
|
@ -332,7 +338,7 @@ namespace IRaCIS.Core.SCP.Service
|
||||||
#region 1帧拆成多个固定大小的,方便移动端浏览
|
#region 1帧拆成多个固定大小的,方便移动端浏览
|
||||||
|
|
||||||
// 回到开头,读取 dicom
|
// 回到开头,读取 dicom
|
||||||
ms.Position = 0;
|
ms.Position = 0;
|
||||||
var dicomFile = DicomFile.Open(ms);
|
var dicomFile = DicomFile.Open(ms);
|
||||||
|
|
||||||
var pixelData = DicomPixelData.Create(dicomFile.Dataset);
|
var pixelData = DicomPixelData.Create(dicomFile.Dataset);
|
||||||
|
|
|
||||||
|
|
@ -261,6 +261,8 @@ namespace IRaCIS.Application.Contracts
|
||||||
public class UserHospitalGroupInfoWithName : UserHospitalGroupInfo
|
public class UserHospitalGroupInfoWithName : UserHospitalGroupInfo
|
||||||
{
|
{
|
||||||
public string Name { get; set; }
|
public string Name { get; set; }
|
||||||
|
|
||||||
|
public string Code { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class UserHospitalGroupInfo
|
public class UserHospitalGroupInfo
|
||||||
|
|
|
||||||
|
|
@ -74,7 +74,7 @@ namespace IRaCIS.Core.Application.Service
|
||||||
.ForMember(d => d.UserType, u => u.MapFrom(t => t.UserTypeName));
|
.ForMember(d => d.UserType, u => u.MapFrom(t => t.UserTypeName));
|
||||||
|
|
||||||
CreateMap<IdentityUser, UserDetailDTO>()
|
CreateMap<IdentityUser, UserDetailDTO>()
|
||||||
.ForMember(d => d.HospitalGroupList, u => u.MapFrom(s => s.IdentityUserHospitalGroupList.Select(t => new UserHospitalGroupInfoWithName() { HospitalGroupId = t.HospitalGroupId, IsDisabled = t.IsDisabled, Name = t.HospitalGroup.Name })));
|
.ForMember(d => d.HospitalGroupList, u => u.MapFrom(s => s.IdentityUserHospitalGroupList.Select(t => new UserHospitalGroupInfoWithName() { HospitalGroupId = t.HospitalGroupId, IsDisabled = t.IsDisabled, Name = t.HospitalGroup.Name,Code=t.HospitalGroup.Code })));
|
||||||
|
|
||||||
|
|
||||||
CreateMap<IdentityUser, UserListDTO>()
|
CreateMap<IdentityUser, UserListDTO>()
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue