Compare commits
No commits in common. "9a2059726f1e116eb6721386bb239f36985593ce" and "19661c5e8223c83e53229441326f3aa41c9487ad" have entirely different histories.
9a2059726f
...
19661c5e82
|
|
@ -48,7 +48,7 @@ namespace IRaCIS.Core.Application.AutoMapper
|
||||||
|
|
||||||
CreateMap<TrialSiteSurvey, TrialSiteSurveyView>()
|
CreateMap<TrialSiteSurvey, TrialSiteSurveyView>()
|
||||||
.ForMember(d => d.TrialSiteAliasName, u => u.MapFrom(s => s.TrialSite.TrialSiteAliasName))
|
.ForMember(d => d.TrialSiteAliasName, u => u.MapFrom(s => s.TrialSite.TrialSiteAliasName))
|
||||||
.ForMember(d => d.SiteName, u => u.MapFrom(s => s.TrialSite.TrialSiteName ))
|
.ForMember(d => d.SiteName, u => u.MapFrom(s => isEn_Us ? s.Site.SiteName : s.Site.SiteNameCN))
|
||||||
.ForMember(d => d.TrialSiteCode, u => u.MapFrom(s => s.TrialSite.TrialSiteCode));
|
.ForMember(d => d.TrialSiteCode, u => u.MapFrom(s => s.TrialSite.TrialSiteCode));
|
||||||
|
|
||||||
CreateMap<TrialSiteSurvey, TrialSiteSurveySelectView>();
|
CreateMap<TrialSiteSurvey, TrialSiteSurveySelectView>();
|
||||||
|
|
|
||||||
|
|
@ -1084,31 +1084,4 @@ namespace IRaCIS.Core.Application.Contracts
|
||||||
//public string TrialSiteSurveyEquipmentType { get; set; } = string.Empty;
|
//public string TrialSiteSurveyEquipmentType { get; set; } = string.Empty;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public class AddOrUpdateTrialBodyPartCommand
|
|
||||||
{
|
|
||||||
public string Code { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
public string Name { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
public string NameCN { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public Guid? Id { get; set; }
|
|
||||||
|
|
||||||
[NotDefault]
|
|
||||||
public Guid TrialId { get; set; }
|
|
||||||
}
|
|
||||||
|
|
||||||
public class TrialBodyPartView
|
|
||||||
{
|
|
||||||
public string Code { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
public string Name { get; set; }
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -19,7 +19,6 @@ using static IRaCIS.Core.Domain.Share.StaticData;
|
||||||
using IRaCIS.Core.Application.Service;
|
using IRaCIS.Core.Application.Service;
|
||||||
using DocumentFormat.OpenXml.Office.CustomUI;
|
using DocumentFormat.OpenXml.Office.CustomUI;
|
||||||
using IRaCIS.Core.Domain.Models;
|
using IRaCIS.Core.Domain.Models;
|
||||||
using IRaCIS.Application.Contracts;
|
|
||||||
|
|
||||||
namespace IRaCIS.Core.Application
|
namespace IRaCIS.Core.Application
|
||||||
{
|
{
|
||||||
|
|
@ -1308,29 +1307,5 @@ namespace IRaCIS.Core.Application
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public async Task<IResponseOutput<List<TrialBodyPartView>>> GetTrialBodyPartList(Guid trialId)
|
|
||||||
{
|
|
||||||
var list = await _trialRepository.Where(t => t.Id == trialId).SelectMany(t => t.TrialBodyPartList).Select(t=>new TrialBodyPartView() { Code=t.Code,Name=_userInfo.IsEn_Us?t.Name:t.NameCN}).ToListAsync();
|
|
||||||
|
|
||||||
return ResponseOutput.Ok(list);
|
|
||||||
}
|
|
||||||
|
|
||||||
public async Task<IResponseOutput> AddOrUpdateTrialBodyPart(AddOrUpdateTrialBodyPartCommand incommand)
|
|
||||||
{
|
|
||||||
|
|
||||||
var exp = new EntityVerifyExp<TrialBodyPart>()
|
|
||||||
{
|
|
||||||
VerifyExp = t => (t.Name.Equals(incommand.Name) || t.NameCN.Equals(incommand.NameCN)),
|
|
||||||
|
|
||||||
VerifyMsg = _localizer["TrialBodyPart_DupName"]
|
|
||||||
};
|
|
||||||
|
|
||||||
var cro = await _repository.InsertOrUpdateAsync<TrialBodyPart, AddOrUpdateTrialBodyPartCommand>(incommand, true, exp);
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
return ResponseOutput.Ok(cro.Id.ToString());
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,6 @@ namespace IRaCIS.Core.Application.Service
|
||||||
CreateMap<VisitTask, ReReadingApprovalToBeDoneDto>();
|
CreateMap<VisitTask, ReReadingApprovalToBeDoneDto>();
|
||||||
|
|
||||||
|
|
||||||
CreateMap<AddOrUpdateTrialBodyPartCommand, TrialBodyPart>();
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,6 @@
|
||||||
using BeetleX;
|
using BeetleX;
|
||||||
using BeetleX.BNR;
|
using BeetleX.BNR;
|
||||||
using Castle.DynamicProxy.Generators.Emitters.SimpleAST;
|
using Castle.DynamicProxy.Generators.Emitters.SimpleAST;
|
||||||
using IP2Region.Net.XDB;
|
|
||||||
using IRaCIS.Application.Contracts;
|
|
||||||
using IRaCIS.Core.Application.Contracts;
|
using IRaCIS.Core.Application.Contracts;
|
||||||
using IRaCIS.Core.Application.Helper;
|
using IRaCIS.Core.Application.Helper;
|
||||||
using IRaCIS.Core.Application.Service;
|
using IRaCIS.Core.Application.Service;
|
||||||
|
|
@ -356,28 +354,6 @@ namespace IRaCIS.Application.Services
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public async Task<IResponseOutput> ModifyTrialBodyPart()
|
|
||||||
{
|
|
||||||
|
|
||||||
var searchList = await _dicRepository.Where(t => t.Parent.Code == "BodyPart" && t.ParentId != null && t.IsEnable).ProjectTo<BasicDicSelect>(_mapper.ConfigurationProvider).ToListAsync();
|
|
||||||
|
|
||||||
var needAddBodyPartList = searchList.Select(t => new TrialBodyPart() { Code = t.Code, Name = t.Value, NameCN = t.ValueCN });
|
|
||||||
|
|
||||||
var trialIds = _repository.Where<Trial>(t => !t.TrialBodyPartList.Any()).Select(t => t.Id).ToList();
|
|
||||||
|
|
||||||
foreach (var trialId in trialIds)
|
|
||||||
{
|
|
||||||
var tempList = needAddBodyPartList.Clone();
|
|
||||||
|
|
||||||
tempList.ForEach(t => t.TrialId = trialId);
|
|
||||||
|
|
||||||
await _repository.AddRangeAsync(tempList);
|
|
||||||
}
|
|
||||||
|
|
||||||
await _repository.SaveChangesAsync();
|
|
||||||
return ResponseOutput.Ok();
|
|
||||||
}
|
|
||||||
|
|
||||||
#region 历史维护
|
#region 历史维护
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 维护临床数据 --一定要在同步表前同步数据才行
|
/// 维护临床数据 --一定要在同步表前同步数据才行
|
||||||
|
|
|
||||||
|
|
@ -117,7 +117,7 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
[ForeignKey("JudgeVisitTaskId")]
|
[ForeignKey("JudgeVisitTaskId")]
|
||||||
public VisitTask JudgeVisitTask { get; set; }
|
public VisitTask JudgeVisitTask { get; set; }
|
||||||
|
|
||||||
|
//public SubjectUser SujectArm { get; set; }
|
||||||
|
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public Subject Subject { get; set; }
|
public Subject Subject { get; set; }
|
||||||
|
|
|
||||||
|
|
@ -35,7 +35,8 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
public TrialSite TrialSite { get; set; }
|
public TrialSite TrialSite { get; set; }
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public Trial Trial { get; set; }
|
public Trial Trial { get; set; }
|
||||||
|
[JsonIgnore]
|
||||||
|
public Site Site { get; set; }
|
||||||
|
|
||||||
public DateTime? DeletedTime { get; set; }
|
public DateTime? DeletedTime { get; set; }
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -17,10 +17,6 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
TrialDicList = new List<TrialDictionary>();
|
TrialDicList = new List<TrialDictionary>();
|
||||||
}
|
}
|
||||||
|
|
||||||
[JsonIgnore]
|
|
||||||
public List<TrialBodyPart> TrialBodyPartList { get; set; }
|
|
||||||
|
|
||||||
|
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public List<TaskMedicalReview> TaskMedicalReviewList { get; set; }
|
public List<TaskMedicalReview> TaskMedicalReviewList { get; set; }
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ using System;
|
||||||
using IRaCIS.Core.Domain.Share;
|
using IRaCIS.Core.Domain.Share;
|
||||||
using System.ComponentModel.DataAnnotations;
|
using System.ComponentModel.DataAnnotations;
|
||||||
using System.ComponentModel.DataAnnotations.Schema;
|
using System.ComponentModel.DataAnnotations.Schema;
|
||||||
using System.Collections.Generic;
|
|
||||||
namespace IRaCIS.Core.Domain.Models
|
namespace IRaCIS.Core.Domain.Models
|
||||||
{
|
{
|
||||||
///<summary>
|
///<summary>
|
||||||
|
|
@ -32,8 +31,5 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
|
|
||||||
public Guid TrialId { get; set; }
|
public Guid TrialId { get; set; }
|
||||||
|
|
||||||
[JsonIgnore]
|
|
||||||
public Trial Trial { get; set; }
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -70,6 +70,7 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
public Guid? Auditor { get; set; }
|
public Guid? Auditor { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
//public SubjectVisitStateEnum VisitState { get; set; }
|
||||||
|
|
||||||
//核查状态
|
//核查状态
|
||||||
public CheckStateEnum CheckState { get; set; }
|
public CheckStateEnum CheckState { get; set; }
|
||||||
|
|
@ -217,6 +218,12 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
public Subject Subject { get; set; }
|
public Subject Subject { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
//// 一个访视可以被多个参与者 查看
|
||||||
|
//public List<TrialUser> TrialUsers { get; set; }
|
||||||
|
|
||||||
|
////一个访视 对应该Site下的多个CRC管理 必须加这个 不然生成的sql 会报 TrialSiteUserId 不存在该列名
|
||||||
|
|
||||||
|
//public List<TrialSiteUser> TrialSiteUserList { get; set; }
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public List<PreviousHistory> PreviousHistoryList { get; set; }
|
public List<PreviousHistory> PreviousHistoryList { get; set; }
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
|
|
|
||||||
|
|
@ -300,6 +300,8 @@ namespace IRaCIS.Core.Infra.EFCore
|
||||||
#region Institution
|
#region Institution
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
public virtual DbSet<Site> ResearchCenter { get; set; }
|
||||||
public virtual DbSet<Hospital> Hospitals { get; set; }
|
public virtual DbSet<Hospital> Hospitals { get; set; }
|
||||||
public virtual DbSet<CRO> CROCompany { get; set; }
|
public virtual DbSet<CRO> CROCompany { get; set; }
|
||||||
public virtual DbSet<Sponsor> Sponsor { get; set; }
|
public virtual DbSet<Sponsor> Sponsor { get; set; }
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue