site dicomAE 提交
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
parent
9f66a932fc
commit
a615b5cefd
|
@ -6,6 +6,7 @@
|
||||||
using System;
|
using System;
|
||||||
using IRaCIS.Core.Domain.Share;
|
using IRaCIS.Core.Domain.Share;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
using System.ComponentModel.DataAnnotations;
|
||||||
namespace IRaCIS.Core.Application.ViewModel
|
namespace IRaCIS.Core.Application.ViewModel
|
||||||
{
|
{
|
||||||
/// <summary> TrialSiteDicomAEView 列表视图模型 </summary>
|
/// <summary> TrialSiteDicomAEView 列表视图模型 </summary>
|
||||||
|
@ -21,8 +22,12 @@ namespace IRaCIS.Core.Application.ViewModel
|
||||||
}
|
}
|
||||||
|
|
||||||
///<summary>TrialSiteDicomAEQuery 列表查询参数模型</summary>
|
///<summary>TrialSiteDicomAEQuery 列表查询参数模型</summary>
|
||||||
public class TrialSiteDicomAEQuery : PageInput
|
public class TrialSiteDicomAEQuery /*: PageInput*/
|
||||||
{
|
{
|
||||||
|
[NotDefault]
|
||||||
|
|
||||||
|
public Guid TrialSiteId { get; set; }
|
||||||
|
|
||||||
public string? CallingAE { get; set; }
|
public string? CallingAE { get; set; }
|
||||||
|
|
||||||
public string? IP { get; set; }
|
public string? IP { get; set; }
|
||||||
|
|
|
@ -259,7 +259,7 @@ namespace IRaCIS.Application.Contracts
|
||||||
//public string ContactPhone { get; set; } = String.Empty;
|
//public string ContactPhone { get; set; } = String.Empty;
|
||||||
//public string Address { get; set; } = String.Empty;
|
//public string Address { get; set; } = String.Empty;
|
||||||
|
|
||||||
|
public List<string> CallingAEList { get; set; }
|
||||||
public List<string> UserNameList { get; set; } = new List<string>();
|
public List<string> UserNameList { get; set; } = new List<string>();
|
||||||
|
|
||||||
public int? VisitCount { get; set; }
|
public int? VisitCount { get; set; }
|
||||||
|
|
|
@ -13,7 +13,7 @@ namespace IRaCIS.Core.Application.Interfaces
|
||||||
public interface ITrialSiteDicomAEService
|
public interface ITrialSiteDicomAEService
|
||||||
{
|
{
|
||||||
|
|
||||||
Task<PageOutput<TrialSiteDicomAEView>> GetTrialSiteDicomAEList(TrialSiteDicomAEQuery inQuery);
|
Task<List<TrialSiteDicomAEView>> GetTrialSiteDicomAEList(TrialSiteDicomAEQuery inQuery);
|
||||||
|
|
||||||
Task<IResponseOutput> AddOrUpdateTrialSiteDicomAE(TrialSiteDicomAEAddOrEdit addOrEditTrialSiteDicomAE);
|
Task<IResponseOutput> AddOrUpdateTrialSiteDicomAE(TrialSiteDicomAEAddOrEdit addOrEditTrialSiteDicomAE);
|
||||||
|
|
||||||
|
|
|
@ -57,7 +57,7 @@ namespace IRaCIS.Core.Application.Service
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <param name="trialId"></param>
|
/// <param name="trialId"></param>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
public async Task<IResponseOutput<DicomAEView>> GetTrialDicomAEList(Guid trialId)
|
public async Task<IResponseOutput<DicomAEView>> GetTrialDicomAE(Guid trialId)
|
||||||
{
|
{
|
||||||
var dicomAE = _dicomAERepository.Where(t => t.TrialId == trialId).ProjectTo<DicomAEView>(_mapper.ConfigurationProvider).FirstOrDefault();
|
var dicomAE = _dicomAERepository.Where(t => t.TrialId == trialId).ProjectTo<DicomAEView>(_mapper.ConfigurationProvider).FirstOrDefault();
|
||||||
var trialConfig = _trialRepository.Where(t => t.Id == trialId).Select(t => new { t.IsPACSConnect, t.IsTrialPACSConfirmed });
|
var trialConfig = _trialRepository.Where(t => t.Id == trialId).Select(t => new { t.IsPACSConnect, t.IsTrialPACSConfirmed });
|
||||||
|
|
|
@ -25,23 +25,25 @@ namespace IRaCIS.Core.Application.Service
|
||||||
}
|
}
|
||||||
|
|
||||||
[HttpPost]
|
[HttpPost]
|
||||||
public async Task<PageOutput<TrialSiteDicomAEView>> GetTrialSiteDicomAEList(TrialSiteDicomAEQuery inQuery)
|
public async Task<List<TrialSiteDicomAEView>> GetTrialSiteDicomAEList(TrialSiteDicomAEQuery inQuery)
|
||||||
{
|
{
|
||||||
|
|
||||||
var trialSiteDicomAEQueryable =
|
var trialSiteDicomAEQueryable =
|
||||||
|
|
||||||
_trialSiteDicomAERepository
|
_trialSiteDicomAERepository.Where(t=>t.TrialSiteId==inQuery.TrialSiteId)
|
||||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.IP), t => t.IP.Contains(inQuery.IP))
|
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.IP), t => t.IP.Contains(inQuery.IP))
|
||||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Port), t => t.Port.Contains(inQuery.Port))
|
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Port), t => t.Port.Contains(inQuery.Port))
|
||||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Description), t => t.Description.Contains(inQuery.Description))
|
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.Description), t => t.Description.Contains(inQuery.Description))
|
||||||
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.CallingAE), t => t.CallingAE.Contains(inQuery.CallingAE))
|
.WhereIf(!string.IsNullOrWhiteSpace(inQuery.CallingAE), t => t.CallingAE.Contains(inQuery.CallingAE))
|
||||||
.ProjectTo<TrialSiteDicomAEView>(_mapper.ConfigurationProvider);
|
.ProjectTo<TrialSiteDicomAEView>(_mapper.ConfigurationProvider);
|
||||||
|
|
||||||
var pageList = await trialSiteDicomAEQueryable
|
//var pageList = await trialSiteDicomAEQueryable
|
||||||
.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrWhiteSpace(inQuery.SortField) ? nameof(TrialSiteDicomAEView.Id) : inQuery.SortField,
|
//.ToPagedListAsync(inQuery.PageIndex, inQuery.PageSize, string.IsNullOrWhiteSpace(inQuery.SortField) ? nameof(TrialSiteDicomAEView.Id) : inQuery.SortField,
|
||||||
inQuery.Asc);
|
//inQuery.Asc);
|
||||||
|
|
||||||
return pageList;
|
var list = await trialSiteDicomAEQueryable.ToListAsync();
|
||||||
|
|
||||||
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -141,7 +141,8 @@ namespace IRaCIS.Core.Application.Service
|
||||||
.ForMember(d => d.UserCount, u => u.MapFrom(s => s.CRCUserList.Count()))
|
.ForMember(d => d.UserCount, u => u.MapFrom(s => s.CRCUserList.Count()))
|
||||||
.ForMember(d => d.VisitCount, u => u.MapFrom(s => s.SubjectVisitList.Count()))
|
.ForMember(d => d.VisitCount, u => u.MapFrom(s => s.SubjectVisitList.Count()))
|
||||||
.ForMember(d => d.SubjectCount, u => u.MapFrom(s => s.SubjectList.Count()))
|
.ForMember(d => d.SubjectCount, u => u.MapFrom(s => s.SubjectList.Count()))
|
||||||
.ForMember(d => d.UserNameList, u => u.MapFrom(s => s.CRCUserList.Where(t => t.IsDeleted == false).Select(u => u.User.FullName)));
|
.ForMember(d => d.UserNameList, u => u.MapFrom(s => s.CRCUserList.Where(t => t.IsDeleted == false).Select(u => u.User.FullName)))
|
||||||
|
.ForMember(d => d.CallingAEList, u => u.MapFrom(s => s.TrialSiteDicomAEList.Select(u => u.CallingAE)));
|
||||||
//CreateMap<Site, SiteStatSimpleDTO>();
|
//CreateMap<Site, SiteStatSimpleDTO>();
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -55,7 +55,9 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public List<Subject> SubjectList { get; set; }
|
public List<Subject> SubjectList { get; set; }
|
||||||
|
|
||||||
|
[JsonIgnore]
|
||||||
|
|
||||||
|
public List<TrialSiteDicomAE> TrialSiteDicomAEList { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -54,6 +54,10 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
|
|
||||||
public string Description { get; set; }
|
public string Description { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public TrialSite TrialSite { get; set; }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue