Uat_Study
parent
839d72f05a
commit
39844dc8a4
|
@ -35,6 +35,14 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
|
|
||||||
public Enroll Enroll { get; set; }
|
public Enroll Enroll { get; set; }
|
||||||
|
|
||||||
|
public Guid DoctorUserId { get; set; }
|
||||||
|
|
||||||
|
[ForeignKey("DoctorUserId")]
|
||||||
|
|
||||||
|
public User DoctorUser { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -42,11 +50,7 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
|
|
||||||
//是否是裁判医生 裁判医生单独加入
|
//是否是裁判医生 裁判医生单独加入
|
||||||
public bool IsJudgeDoctor { get; set; }
|
public bool IsJudgeDoctor { get; set; }
|
||||||
public Guid DoctorUserId { get; set; }
|
|
||||||
|
|
||||||
[ForeignKey("DoctorUserId")]
|
|
||||||
|
|
||||||
public User DoctorUser { get; set; }
|
|
||||||
public int PlanReadingRatio { get; set; }
|
public int PlanReadingRatio { get; set; }
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -100,7 +100,6 @@ namespace IRaCIS.Core.Domain.Models
|
||||||
|
|
||||||
//public TaskAllocationRule DoctorTaskAllocationRule { get; set; }
|
//public TaskAllocationRule DoctorTaskAllocationRule { get; set; }
|
||||||
|
|
||||||
public Enroll Enroll { get; set; }
|
|
||||||
|
|
||||||
public TaskMedicalReviewRule DoctorTaskMedicalReviewRule { get; set; }
|
public TaskMedicalReviewRule DoctorTaskMedicalReviewRule { get; set; }
|
||||||
|
|
||||||
|
|
|
@ -90,13 +90,8 @@ namespace IRaCIS.Core.Infra.EFCore
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
modelBuilder.Entity<User>().HasMany(t => t.VisitTaskList).WithOne(t => t.DoctorUser).HasForeignKey(t => t.DoctorUserId);
|
modelBuilder.Entity<User>().HasMany(t => t.VisitTaskList).WithOne(t => t.DoctorUser).HasForeignKey(t => t.DoctorUserId).IsRequired(false);
|
||||||
|
|
||||||
//modelBuilder.Entity<Enroll>().HasMany(t => t.DoctorTrialVisitTaskList).WithOne(t => t.Enroll).HasForeignKey(t => new { t.DoctorUserId, t.TrialId }).HasPrincipalKey(u => new { u.DoctorUserId, u.TrialId }).IsRequired(false);
|
|
||||||
|
|
||||||
//modelBuilder.Entity<VisitTask>().HasOne(t => t.Enroll).WithMany(t => t.DoctorTrialVisitTaskList).HasForeignKey(t => new { t.DoctorUserId, t.TrialId }).IsRequired(false).HasPrincipalKey(u => new { u.DoctorUserId, u.TrialId }).IsRequired(false);
|
|
||||||
|
|
||||||
//modelBuilder.Entity<TaskAllocationRule>().HasMany(t => t.DoctorVisitTaskList).WithOne(t => t.DoctorTaskAllocationRule).HasForeignKey(t => new { t.DoctorUserId, t.TrialId }).HasPrincipalKey(u => new { u.DoctorUserId, u.TrialId });
|
|
||||||
|
|
||||||
modelBuilder.Entity<TaskMedicalReviewRule>().HasMany(t => t.DoctorVisitTaskList).WithOne(t => t.DoctorTaskMedicalReviewRule).HasForeignKey(t => new { t.DoctorUserId, t.TrialId }).HasPrincipalKey(u => new { u.DoctorUserId, u.TrialId });
|
modelBuilder.Entity<TaskMedicalReviewRule>().HasMany(t => t.DoctorVisitTaskList).WithOne(t => t.DoctorTaskMedicalReviewRule).HasForeignKey(t => new { t.DoctorUserId, t.TrialId }).HasPrincipalKey(u => new { u.DoctorUserId, u.TrialId });
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue