Compare commits

..

No commits in common. "cf9823c682dabe6c8f917c242a69f981cf886231" and "9adab8cef1d8c4477c4574625d863a7eed3f98d9" have entirely different histories.

49 changed files with 70 additions and 45862 deletions

View File

@ -515,7 +515,11 @@ namespace IRaCIS.Core.Application.Contracts
public ReadingStatusEnum ReadingStatus { get; set; }
//最终任务
[Column(TypeName = "decimal(18,2)")]
public decimal VisitTaskNum { get; set; }
//访视会有

View File

@ -78,9 +78,7 @@ public class TaskMedicalReview : BaseFullAuditEntity
[Comment("质询问题")]
public string Questioning { get; set; } = string.Empty;
[Comment("图片路径")]
[StringLength(1000)]
public string ImagePath { get; set; } = string.Empty;
[Comment("审核建议")]
@ -113,6 +111,5 @@ public class TaskMedicalReview : BaseFullAuditEntity
public bool IsAutoGenerate { get; set; }
[StringLength(1000)]
public string PDRelationTaskIdListStr { get; set; } = string.Empty;
}

View File

@ -207,15 +207,13 @@ public class VisitTask : BaseFullAuditEntity
public bool IsReadClinicalData { get; set; } = false;
[Comment("关联的访视任务ID (当前任务是访视任务的话会有自己)")]
[StringLength(2000)]
public string RelatedVisitTaskIds { get; set; } = "[]";
[Comment("报告任务关系 包含冻结")]
[StringLength(2000)]
public string ReportRelatedTaskIds { get; set; } = "[]";
[Comment("既往任务Id 不包括自己")]
[StringLength(2000)]
public string PastResultTaskIds { get; set; } = "[]";
#region 裁判任务特有
@ -225,9 +223,7 @@ public class VisitTask : BaseFullAuditEntity
[Comment("裁判结果的备注")]
public string JudgeResultRemark { get; set; } = string.Empty;
[Comment("裁判结果的图片路径")]
[StringLength(1000)]
public string JudgeResultImagePath { get; set; } = string.Empty;
#endregion

View File

@ -7,6 +7,7 @@ public class FrontAuditConfig : BaseFullAuditEntity
#region 导航属性
#endregion
[StringLength(1000)]
public string ChildDataEnLabel { get; set; } = null!;
[Comment("前端渲染数组 数组名 和数组值")]
@ -22,6 +23,7 @@ public class FrontAuditConfig : BaseFullAuditEntity
[Comment("翻译的字段名 这里有可能是一个数组名 那么具体的翻译字段名就不是这个了")]
public string Code { get; set; } = null!;
[StringLength(1000)]
public string CodeEn { get; set; } = null!;
[Comment("前端使用 C M")]
@ -33,8 +35,10 @@ public class FrontAuditConfig : BaseFullAuditEntity
[Comment("日期格式")]
public string DateType { get; set; } = null!;
[StringLength(512)]
public string Description { get; set; } = null!;
[StringLength(500)]
public string DescriptionCN { get; set; } = null!;
[Comment("翻译的字典名(单个字段翻译的时候)")]
@ -49,12 +53,14 @@ public class FrontAuditConfig : BaseFullAuditEntity
[Comment("后端翻译的类型 对应前端界面 Dictionary Date")]
public string EnumType { get; set; } = null!;
[StringLength(1000)]
public string ForeignKeyEnText { get; set; } = null!;
[Comment("外键表")]
public string ForeignKeyTableName { get; set; } = null!;
[Comment("外键Text")]
[StringLength(1000)]
public string ForeignKeyText { get; set; } = null!;
[Comment("外键Value")]

View File

@ -10,7 +10,6 @@ public class PublishLog : BaseFullAuditEntity
public DateTime? PublishTime { get; set; }
[MaxLength]
public string UpdateContent { get; set; } = string.Empty;
[Comment("0 开发中 ,已发布")]

View File

@ -16,43 +16,43 @@ public class Postgraduate : BaseFullAuditEntity
[Column(TypeName = "date")]
public DateTime? EndDate { get; set; }
[StringLength(50)]
public string Training { get; set; } = string.Empty;
[StringLength(100)]
public string Major { get; set; } = string.Empty;
[StringLength(100)]
public string Hospital { get; set; } = string.Empty;
[StringLength(100)]
public string School { get; set; } = string.Empty;
[StringLength(100)]
public string Country { get; set; } = string.Empty;
[StringLength(100)]
public string Province { get; set; } = string.Empty;
[StringLength(100)]
public string City { get; set; } = string.Empty;
[StringLength(50)]
public string TrainingCN { get; set; } = string.Empty;
[StringLength(100)]
public string MajorCN { get; set; } = string.Empty;
[StringLength(100)]
public string HospitalCN { get; set; } = string.Empty;
[StringLength(100)]
public string SchoolCN { get; set; } = string.Empty;
[StringLength(100)]
public string CountryCN { get; set; } = string.Empty;
[StringLength(100)]
public string ProvinceCN { get; set; } = string.Empty;
[StringLength(100)]
public string CityCN { get; set; } = string.Empty;
}

View File

@ -8,21 +8,13 @@ public partial class ResearchPublication : BaseFullAuditEntity
#endregion
public Guid DoctorId { get; set; }
[MaxLength]
public string Research { get; set; } = string.Empty;
[MaxLength]
public string Grants { get; set; } = string.Empty;
[MaxLength]
public string Publications { get; set; } = string.Empty;
[MaxLength]
public string AwardsHonors { get; set; } = string.Empty;
[MaxLength]
public string ResearchCN { get; set; } = string.Empty;
[MaxLength]
public string GrantsCN { get; set; } = string.Empty;
[MaxLength]
public string PublicationsCN { get; set; } = string.Empty;
[MaxLength]
public string AwardsHonorsCN { get; set; } = string.Empty;
}

View File

@ -15,6 +15,7 @@ public partial class TrialExperience : BaseFullAuditEntity
public Dictionary Phase { get; set; }
[StringLength(512)]
public string EvaluationContent { get; set; } = string.Empty;
public int VisitReadingCount { get; set; }

View File

@ -20,7 +20,6 @@ public class SystemDocConfirmedUser : BaseAddDeleteAuditEntity
public DateTime? SignFirstViewTime { get; set; }
[StringLength(1000)]
public string SignText { get; set; } = string.Empty;
}

View File

@ -17,8 +17,6 @@ public class SystemDocument : BaseFullDeleteAuditEntity
public string Name { get; set; } = string.Empty;
public int SignViewMinimumMinutes { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
}

View File

@ -16,7 +16,5 @@ public class TrialDocConfirmedUser : BaseAddDeleteAuditEntity
public DateTime? ConfirmTime { get; set; }
public Guid ConfirmUserId { get; set; }
public DateTime? SignFirstViewTime { get; set; }
[StringLength(1000)]
public string SignText { get; set; } = string.Empty;
}

View File

@ -24,7 +24,9 @@ public partial class Payment : BaseFullAuditEntity
public decimal AdjustmentUSD { get; set; }
public DateTime CalculateTime { get; set; } = DateTime.Now;
[StringLength(100)]
public string CalculateUser { get; set; } = string.Empty;
[StringLength(500)]
public string Note { get; set; } = string.Empty;
}

View File

@ -9,10 +9,10 @@ public partial class PaymentDetail : BaseFullAuditEntity
public string YearMonth { get; set; } = string.Empty;
public Guid TrialId { get; set; }
[StringLength(50)]
public string TrialCode { get; set; } = string.Empty;
[StringLength(50)]
public string PaymentType { get; set; } = string.Empty;
public int Count { get; set; }

View File

@ -4,7 +4,7 @@ namespace IRaCIS.Core.Domain.Models;
[Table("RankPrice")]
public partial class RankPrice : BaseFullAuditEntity
{
[StringLength(200)]
public string RankName { get; set; } = string.Empty;
[DecimalPrecision(18, 2)]

View File

@ -46,7 +46,7 @@ public class StudyMonitor : BaseAddAuditEntity
public string Note { get; set; } = null!;
[StringLength(1000)]
[StringLength(1024)]
public string RecordPath { get; set; } = null!;
public string StudyCode { get; set; } = null!;

View File

@ -16,8 +16,6 @@ public class NoneDicomStudyFile : BaseAddAuditEntity
public NoneDicomStudy OriginNoneDicomStudy { get; set; }
#endregion
public Guid NoneDicomStudyId { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
public string FileName { get; set; } = string.Empty;

View File

@ -35,8 +35,6 @@ public class SCPInstance : BaseFullAuditEntity, IEntitySeqId
public string WindowWidth { get; set; } = string.Empty;
public bool Anonymize { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
public long? FileSize { get; set; }

View File

@ -36,7 +36,6 @@ public class SCPSeries : BaseFullDeleteAuditEntity, IEntitySeqId
public string BodyPartForEdit { get; set; } = string.Empty;
[StringLength(1000)]
public string ImageResizePath { get; set; } = string.Empty;
}

View File

@ -41,7 +41,6 @@ public class TaskInstance : BaseFullAuditEntity, IEntitySeqId
public bool Anonymize { get; set; }
public string Path { get; set; } = string.Empty;
[StringLength(1000)]
public string HtmlPath { get; set; } = string.Empty;
public long? FileSize { get; set; }

View File

@ -38,7 +38,6 @@ public class TaskSeries : BaseFullDeleteAuditEntity, IEntitySeqId
public string TriggerTime { get; set; } = string.Empty;
public string BodyPartForEdit { get; set; } = string.Empty;
[StringLength(1000)]
public string ImageResizePath { get; set; } = string.Empty;
}

View File

@ -13,8 +13,6 @@ public class SystemNotice : BaseFullAuditEntity
public List<SystemNoticeUserRead> NoticeUserReadList { get; set; } = new List<SystemNoticeUserRead>();
#endregion
[MaxLength]
public string NoticeContent { get; set; } = string.Empty;
public SystemNotice_NoticeTypeEnum NoticeTypeEnum { get; set; }

View File

@ -30,6 +30,8 @@ public class User : BaseFullAuditEntity
public bool AutoCutNextTask { get; set; }
public int Code { get; set; }
public string DepartmentName { get; set; } = null!;
[Comment("医生生成账号后,会有值")]
@ -37,7 +39,7 @@ public class User : BaseFullAuditEntity
public string EMail { get; set; } = null!;
[StringLength(1000)]
[StringLength(1020)]
public string EmailToken { get; set; } = null!;
public string FirstName { get; set; } = null!;
@ -57,6 +59,7 @@ public class User : BaseFullAuditEntity
public DateTime? LastLoginTime { get; set; }
[StringLength(510)]
public string LastName { get; set; } = null!;
public string OrganizationName { get; set; } = null!;

View File

@ -12,7 +12,6 @@ public class PreviousPDF : BaseAddAuditEntity
#endregion
public Guid SubjectVisitId { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
public string FileName { get; set; } = string.Empty;

View File

@ -25,7 +25,6 @@ public class QCChallenge : BaseAddAuditEntity
public DateTime? DeadlineTime { get; set; }
[StringLength(1000)]
public string Note { get; set; } = string.Empty;
public QCChanllengeReuploadEnum ReuploadEnum { get; set; }
@ -51,10 +50,8 @@ public class QCChallenge : BaseAddAuditEntity
public string ClosedUser { get; set; } = string.Empty;
public QCChallengeCloseEnum CloseResonEnum { get; set; }
[StringLength(1000)]
public string Content { get; set; } = string.Empty;
[StringLength(1000)]
public string ActionContent { get; set; } = string.Empty;
public UserTypeEnum UserTypeEnum { get; set; }

View File

@ -11,7 +11,6 @@ public class QCChallengeDialog : BaseAddAuditEntity
public QCChallenge QCChallenge { get; set; }
#endregion
[StringLength(1000)]
public string TalkContent { get; set; } = string.Empty;
public Guid QCChallengeId { get; set; }

View File

@ -13,7 +13,6 @@ public class ReadingClinicalDataPDF : BaseAddAuditEntity
[Comment("阅片临床数据ID")]
public Guid ReadingClinicalDataId { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
public string FileName { get; set; } = string.Empty;
public int Size { get; set; } = 0;

View File

@ -13,7 +13,6 @@ public class ReadingConsistentClinicalDataPDF : BaseAddAuditEntity
[Comment("阅片临床数据ID")]
public Guid ReadingConsistentClinicalDataId { get; set; }
[StringLength(1000)]
public string Path { get; set; } = string.Empty;
public string FileName { get; set; } = string.Empty;

View File

@ -98,6 +98,5 @@ public class SystemClinicalQuestion : BaseAddAuditEntity
public ClinicalCalculateMark? CustomCalculateMark { get; set; }
[Comment("自定义计算问题")]
[MaxLength]
public string CalculateQuestions { get; set; } = "[]";
}

View File

@ -99,7 +99,6 @@ public class TrialClinicalQuestion : BaseAddAuditEntity
public TrialClinicalQuestion GroupQuestin { get; set; }
[Comment("自定义计算问题")]
[MaxLength]
public string CalculateQuestions { get; set; } = "[]";
[Comment("小数点位数")]
public int? DigitPlaces { get; set; }

View File

@ -70,7 +70,6 @@ public class TrialClinicalTableQuestion : BaseAddAuditEntity
public ClinicalCalculateMark? ClinicalCalculateMarkEnum { get; set; }
[Comment("自定义计算问题")]
[MaxLength]
public string CalculateQuestions { get; set; } = "[]";
[Comment("小数点位数")]

View File

@ -38,7 +38,6 @@ public class ReadingMedicalReviewDialog : BaseAddAuditEntity
public Guid VisitTaskId { get; set; }
[Comment("对话内容")]
[StringLength(1000)]
public string Content { get; set; } = string.Empty;
[Comment("用户角色")]
@ -65,10 +64,7 @@ public class ReadingMedicalReviewDialog : BaseAddAuditEntity
public string DisagreeReason { get; set; } = string.Empty;
[Comment("是否申请重阅")]
public bool? IsApplyHeavyReading { get; set; }
[Comment("图片路径")]
[MaxLength]
public string ImagePath { get; set; } = string.Empty;
[Comment("文件名称")]

View File

@ -225,7 +225,6 @@ public class ReadingQuestionTrial : BaseAddAuditEntity
[Comment("限制显示")]
public LimitShow LimitShow { get; set; } = LimitShow.AllShow;
[MaxLength]
[Comment("自定义计算标记")]
public string CalculateQuestions { get; set; } = "[]";

View File

@ -125,7 +125,6 @@ public class ReadingTableQuestionTrial : BaseAddAuditEntity
public LimitEdit LimitEdit { get; set; } = LimitEdit.None;
[Comment("自定义计算标记")]
[MaxLength]
public string CalculateQuestions { get; set; } = "[]";
[Comment("问题英文名称")]

View File

@ -15,7 +15,6 @@ public class ReadingCustomTag : BaseAddAuditEntity
public Guid? InstanceId { get; set; }
[MaxLength]
public string MeasureData { get; set; } = string.Empty;
public int? NumberOfFrames { get; set; }

View File

@ -29,7 +29,7 @@ public class ReadingGlobalTaskInfo : BaseAddAuditEntity
public Guid? QuestionId { get; set; }
[Comment("问题答案")]
[StringLength(1000)]
public string Answer { get; set; } = string.Empty;
public Guid TrialId { get; set; }

View File

@ -21,7 +21,6 @@ public class ReadingOncologyTaskInfo : BaseAddAuditEntity
public Guid VisitTaskId { get; set; }
[Comment("结果")]
[StringLength(1000)]
public string EvaluationResult { get; set; } = string.Empty;
[Comment("原因")]

View File

@ -44,10 +44,8 @@ public class ReadingTableAnswerRowInfo : BaseFullDeleteAuditEntity
public Guid? OtherStudyId { get; set; }
[MaxLength]
public string OtherMarkTool { get; set; } = string.Empty;
[StringLength(1000)]
public string OtherPicturePath { get; set; } = string.Empty;
public int? OtherNumberOfFrames { get; set; }
@ -58,7 +56,6 @@ public class ReadingTableAnswerRowInfo : BaseFullDeleteAuditEntity
public decimal RowIndex { get; set; }
[MaxLength]
public string MeasureData { get; set; } = string.Empty;
[Comment("是否是当前任务添加")]
@ -73,7 +70,6 @@ public class ReadingTableAnswerRowInfo : BaseFullDeleteAuditEntity
public string OrderMark { get; set; } = string.Empty;
[Comment("截图地址")]
[StringLength(1000)]
public string PicturePath { get; set; } = string.Empty;
[Comment("第一次添加的任务ID")]
@ -103,8 +99,6 @@ public class ReadingTableAnswerRowInfo : BaseFullDeleteAuditEntity
[Comment("报告页面显示来自于哪个标记")]
public string ReportMark { get; set; } = string.Empty;
[MaxLength]
public string OtherMeasureData { get; set; } = string.Empty;
[Comment("病灶编号")]
public string RowMark { get; set; } = string.Empty;

View File

@ -31,7 +31,6 @@ public class ReadingTableQuestionAnswer : BaseFullDeleteAuditEntity
public Guid TrialId { get; set; }
public decimal RowIndex { get; set; }
[StringLength(1000)]
public string Answer { get; set; } = string.Empty;
public Guid RowId { get; set; }
}

View File

@ -27,7 +27,6 @@ public class ReadingTaskQuestionAnswer : BaseAddAuditEntity
public Guid VisitTaskId { get; set; }
[Comment("答案")]
[StringLength(1000)]
public string Answer { get; set; } = string.Empty;
[Comment("全局阅片修改的答案")]

View File

@ -22,16 +22,12 @@ public class ReadingTaskQuestionMark : BaseAddAuditEntity
public Guid? SeriesId { get; set; }
public Guid? StudyId { get; set; }
[MaxLength]
public string MarkTool { get; set; } = string.Empty;
[StringLength(1000)]
public string PicturePath { get; set; } = string.Empty;
public int? NumberOfFrames { get; set; }
[MaxLength]
public string MeasureData { get; set; } = string.Empty;
public Guid? FirstAddTaskId { get; set; }
@ -44,14 +40,10 @@ public class ReadingTaskQuestionMark : BaseAddAuditEntity
public Guid? OtherStudyId { get; set; }
[MaxLength]
public string OtherMarkTool { get; set; } = string.Empty;
[StringLength(1000)]
public string OtherPicturePath { get; set; } = string.Empty;
public int? OtherNumberOfFrames { get; set; }
[MaxLength]
public string OtherMeasureData { get; set; } = string.Empty;
}

View File

@ -81,22 +81,26 @@ public partial class Trial : BaseFullDeleteAuditEntity
public Guid IndicationTypeId { get; set; } = Guid.Empty;
public Guid? PhaseId { get; set; } = Guid.Empty;
[StringLength(100)]
public string TrialCode { get; set; } = string.Empty;
public int Code { get; set; }
[StringLength(512)]
public string Indication { get; set; } = string.Empty;
[Comment("入组那一块的状态")]
public int TrialEnrollStatus { get; set; }
[Comment("启动状态")]
[StringLength(500)]
public string TrialStatusStr { get; set; } = StaticData.TrialState.TrialInitializing;
public Guid? CROId { get; set; } = Guid.Empty;
public Guid? SponsorId { get; set; } = Guid.Empty;
public Guid? ReviewModeId { get; set; } = Guid.Empty;
[StringLength(500)]
public string ProjectCycle { get; set; } = string.Empty;
public int ExpectedPatients { get; set; }
@ -106,8 +110,10 @@ public partial class Trial : BaseFullDeleteAuditEntity
public int TotalReviewers { get; set; }
[StringLength(500)]
public string ReviewProtocol { get; set; } = string.Empty;
[StringLength(500)]
public string MessageFromClient { get; set; } = string.Empty;
public string Note { get; set; } = string.Empty;
@ -126,7 +132,6 @@ public partial class Trial : BaseFullDeleteAuditEntity
public string AttendedReviewerTypes { get; set; } = string.Empty;
[StringLength(1000)]
public string TrialExtraConfigJsonStr { get; set; } = string.Empty;
public bool VisitPlanConfirmed { get; set; }

View File

@ -13,7 +13,6 @@ public class TrialSign : BaseAddAuditEntity
public string SignCode { get; set; } = string.Empty;
[StringLength(1000)]
public string SignText { get; set; } = string.Empty;
public bool IsCompleted { get; set; }

View File

@ -137,7 +137,6 @@ public class SubjectVisit : BaseFullDeleteAuditEntity
public ChallengeStateEnum ChallengeState { get; set; }
[MaxLength]
public string CheckResult { get; set; } = String.Empty;
[Comment("是否一致性核查回退")]

View File

@ -3,7 +3,6 @@ using IRaCIS.Core.Infra.EFCore.Common;
using IRaCIS.Core.Infrastructure.Encryption;
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;
using System.Data;
using System.Reflection;
using System.Security.Cryptography;
@ -87,31 +86,31 @@ public class IRaCISDBContext : DbContext
#region decimal 自定义精度,适配多种数据库
foreach (var entityType in modelBuilder.Model.GetEntityTypes())
{
foreach (var property in entityType.GetProperties())
{
// 如果属性类型是 decimal 或 nullable decimal
if (property.ClrType == typeof(decimal) || property.ClrType == typeof(decimal?))
{
// 获取自定义的 DecimalPrecisionAttribute
var precisionAttr = property.PropertyInfo?.GetCustomAttributes(typeof(DecimalPrecisionAttribute), false)
.FirstOrDefault() as DecimalPrecisionAttribute;
//foreach (var entityType in modelBuilder.Model.GetEntityTypes())
//{
// foreach (var property in entityType.GetProperties())
// {
// // 如果属性类型是 decimal 或 nullable decimal
// if (property.ClrType == typeof(decimal) || property.ClrType == typeof(decimal?))
// {
// // 获取自定义的 DecimalPrecisionAttribute
// var precisionAttr = property.PropertyInfo?.GetCustomAttributes(typeof(DecimalPrecisionAttribute), false)
// .FirstOrDefault() as DecimalPrecisionAttribute;
if (precisionAttr != null)
{
property.SetPrecision(precisionAttr.Precision);
property.SetScale(precisionAttr.Scale);
}
else
{
// 默认的精度设置
property.SetPrecision(18);
property.SetScale(2);
}
}
}
}
// if (precisionAttr != null)
// {
// property.SetPrecision(precisionAttr.Precision);
// property.SetScale(precisionAttr.Scale);
// }
// else
// {
// // 默认的精度设置
// property.SetPrecision(18);
// property.SetScale(2);
// }
// }
// }
//}
#endregion

View File

@ -11,7 +11,7 @@ public class IRaCISDBContextFactory : IDesignTimeDbContextFactory<IRaCISDBContex
public IRaCISDBContext CreateDbContext(string[] args)
{
var optionsBuilder = new DbContextOptionsBuilder<IRaCISDBContext>();
optionsBuilder.UseSqlServer("Server=106.14.89.110,1435;Database=Test_IRC_CodeFirst;User ID=sa;Password=xc@123456;TrustServerCertificate=true", contextOptionsBuilder => contextOptionsBuilder.EnableRetryOnFailure());
optionsBuilder.UseSqlServer("Server=106.14.89.110,1435;Database=Test_IRC;User ID=sa;Password=xc@123456;TrustServerCertificate=true", contextOptionsBuilder => contextOptionsBuilder.EnableRetryOnFailure());
return new IRaCISDBContext(optionsBuilder.Options);
}

File diff suppressed because it is too large Load Diff

View File

@ -140,6 +140,7 @@ namespace IRaCIS.Core.Test.CodeFirstTest.MSSQL
[MaxLength(300)]
public string UserDefineLength { get; set; }
[Column(TypeName = "text")]
public string UserDefineText { get; set; }
}