diff --git a/IRaCIS.Core.Application/TestService.cs b/IRaCIS.Core.Application/TestService.cs index a66522634..9f0256df0 100644 --- a/IRaCIS.Core.Application/TestService.cs +++ b/IRaCIS.Core.Application/TestService.cs @@ -282,10 +282,19 @@ namespace IRaCIS.Application.Services Console.WriteLine(RSAEncryption.Encrypt(publicKey, MD5Helper.Md5("123456"))); + + + //U2FsdGVkX1+atIRsUP6uhWIMHIVmn7U2sy4HlgWiWJG1qc0WdYyQqzgTJ1JLeQGHvYrIYm90/YCkBYclYbnm1g== + + string plainText = "Hello, BouncyCastle!"; string key = "12345678901234567890123456789012"; // AES 密钥长度应为 16 字节(128 位) string iv = "your-iv-12345678"; // IV 长度为 16 字节 + + Console.WriteLine(AesEncryption.Encrypt(MD5Helper.Md5("123456"), key)); + Console.WriteLine(AesEncryption.Encrypt("cyldev", key)); + Console.WriteLine($"原始文本: {plainText}"); // 加密 diff --git a/IRaCIS.Core.Domain/Dcotor/DoctorDictionary.cs b/IRaCIS.Core.Domain/Dcotor/DoctorDictionary.cs index 0eed81e88..48920c6f5 100644 --- a/IRaCIS.Core.Domain/Dcotor/DoctorDictionary.cs +++ b/IRaCIS.Core.Domain/Dcotor/DoctorDictionary.cs @@ -1,28 +1,29 @@ +using Microsoft.EntityFrameworkCore; using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -namespace IRaCIS.Core.Domain.Models +namespace IRaCIS.Core.Domain.Models; + + +[Comment("ҽ - ҽֵ")] +[Table("DoctorDictionary")] +public class DoctorDictionary : Entity { - [Table("DoctorDictionary")] - public partial class DoctorDictionary : Entity - { - #region - [JsonIgnore] - [ForeignKey("DoctorId")] - public Doctor Doctor { get; set; } + #region + [JsonIgnore] + [ForeignKey("DoctorId")] + public Doctor Doctor { get; set; } - [JsonIgnore] - [ForeignKey("DictionaryId")] - public Dictionary Dictionary { get; set; } - #endregion + [JsonIgnore] + [ForeignKey("DictionaryId")] + public Dictionary Dictionary { get; set; } + #endregion + public Guid DictionaryId { get; set; } - [StringLength(50)] - public string KeyName { get; set; } = string.Empty; + public Guid DoctorId { get; set; } - public Guid DoctorId { get; set; } - - public Guid DictionaryId { get; set; } - } + [StringLength(400)] + public string KeyName { get; set; } = null!; } diff --git a/IRaCIS.Core.Domain/Dcotor/DoctorWorkload.cs b/IRaCIS.Core.Domain/Dcotor/DoctorWorkload.cs index 2701ef933..a5ed3cefd 100644 --- a/IRaCIS.Core.Domain/Dcotor/DoctorWorkload.cs +++ b/IRaCIS.Core.Domain/Dcotor/DoctorWorkload.cs @@ -1,50 +1,52 @@ +using Microsoft.EntityFrameworkCore; using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -namespace IRaCIS.Core.Domain.Models +namespace IRaCIS.Core.Domain.Models; + +[Comment("ҽƷ - ¼")] +[Table("DoctorWorkload")] +public partial class Workload :BaseFullAuditEntity { - [Table("DoctorWorkload")] - public partial class Workload :BaseFullAuditEntity - { - #region + #region - #endregion - [Required] - public Guid TrialId { get; set; } + #endregion - public Guid DoctorId { get; set; } + public int Adjudication { get; set; } - public int DataFrom { get; set; } + public int AdjudicationIn24H { get; set; } - public DateTime WorkTime { get; set; } + public int AdjudicationIn48H { get; set; } - public int Training { get; set; } + public int CreateUserType { get; set; } - public int Downtime { get; set; } + public int DataFrom { get; set; } - public int Timepoint { get; set; } + public Guid DoctorId { get; set; } - public int TimepointIn24H { get; set; } + public int Downtime { get; set; } - public int TimepointIn48H { get; set; } + public int Global { get; set; } - public int Adjudication { get; set; } + public bool IsLock { get; set; } - public int AdjudicationIn24H { get; set; } + public int RefresherTraining { get; set; } - public int AdjudicationIn48H { get; set; } + public int Timepoint { get; set; } - public int Global { get; set; } - public int RefresherTraining { get; set; } + public int TimepointIn24H { get; set; } - public int CreateUserType { get; set; } + public int TimepointIn48H { get; set; } - [Required] - public string YearMonth { get; set; } = string.Empty; + public int Training { get; set; } - public bool IsLock { get; set; } = false; + public Guid TrialId { get; set; } + + public DateTime WorkTime { get; set; } + + [StringLength(400)] + public string YearMonth { get; set; } = null!; - } } diff --git a/IRaCIS.Core.Domain/Dcotor/Education.cs b/IRaCIS.Core.Domain/Dcotor/Education.cs index 813af7de7..830176315 100644 --- a/IRaCIS.Core.Domain/Dcotor/Education.cs +++ b/IRaCIS.Core.Domain/Dcotor/Education.cs @@ -1,64 +1,59 @@ +using Microsoft.EntityFrameworkCore; using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -namespace IRaCIS.Core.Domain.Models +namespace IRaCIS.Core.Domain.Models; + +[Comment("ҽ - Ϣ")] +[Table("Education")] +public class Education : BaseFullAuditEntity { - [Table("Education")] - public partial class Education : BaseFullAuditEntity - { - #region + #region - #endregion - public Guid DoctorId { get; set; } + #endregion + public DateOnly? BeginDate { get; set; } - [Column(TypeName = "date")] - public DateTime? BeginDate { get; set; } - [Column(TypeName = "date")] - public DateTime? EndDate { get; set; } + [StringLength(400)] + public string City { get; set; } = null!; - [StringLength(50)] - public string Degree { get; set; } = string.Empty; - [StringLength(100)] - public string Major { get; set; } = string.Empty; + [StringLength(400)] + public string CityCN { get; set; } = null!; - [StringLength(100)] - public string Organization { get; set; } = string.Empty; + [StringLength(400)] + public string Country { get; set; } = null!; + [StringLength(400)] + public string CountryCN { get; set; } = null!; - [StringLength(50)] - public string Country { get; set; } = string.Empty; + [StringLength(400)] + public string Degree { get; set; } = null!; + [StringLength(400)] + public string DegreeCN { get; set; } = null!; - [StringLength(50)] - public string Province { get; set; } = string.Empty; + public Guid DoctorId { get; set; } + public DateOnly? EndDate { get; set; } - [StringLength(50)] - public string City { get; set; } = string.Empty; + [StringLength(400)] + public string Major { get; set; } = null!; - - [StringLength(50)] - public string DegreeCN { get; set; } = string.Empty; - [StringLength(100)] - public string MajorCN { get; set; } = string.Empty; + [StringLength(400)] + public string MajorCN { get; set; } = null!; - [StringLength(100)] - public string OrganizationCN { get; set; } = string.Empty; + [StringLength(400)] + public string Organization { get; set; } = null!; + [StringLength(400)] + public string OrganizationCN { get; set; } = null!; - [StringLength(50)] - public string CountryCN { get; set; } = string.Empty; + [StringLength(400)] + public string Province { get; set; } = null!; + [StringLength(400)] + public string ProvinceCN { get; set; } = null!; - [StringLength(50)] - public string ProvinceCN { get; set; } = string.Empty; + public int ShowOrder { get; set; } - - [StringLength(50)] - public string CityCN { get; set; } = string.Empty; - - public int ShowOrder { get; set; } - - } } diff --git a/IRaCIS.Core.Domain/Financial/ReviewerPayInformation.cs b/IRaCIS.Core.Domain/Financial/ReviewerPayInformation.cs index 9dc577be4..4a8b87375 100644 --- a/IRaCIS.Core.Domain/Financial/ReviewerPayInformation.cs +++ b/IRaCIS.Core.Domain/Financial/ReviewerPayInformation.cs @@ -1,28 +1,29 @@ +using Microsoft.EntityFrameworkCore; using System; using System.ComponentModel.DataAnnotations; using System.ComponentModel.DataAnnotations.Schema; -namespace IRaCIS.Core.Domain.Models +namespace IRaCIS.Core.Domain.Models; + +[Comment("ҽƷ - ֧Ϣ")] +[Table("DoctorPayInformation")] +public partial class ReviewerPayInformation : BaseFullAuditEntity { - [Table("DoctorPayInformation")] - public partial class ReviewerPayInformation : BaseFullAuditEntity - { - public Guid DoctorId { get; set; } - [StringLength(200)] - public string DoctorNameInBank { get; set; } = string.Empty; + [DecimalPrecision(18, 2)] + public decimal Additional { get; set; } - [StringLength(100)] - public string IDCard { get; set; } = string.Empty; + [StringLength(400)] + public string BankCardNumber { get; set; } = null!; - [StringLength(100)] - public string BankCardNumber { get; set; } = string.Empty; + public string BankName { get; set; } = null!; - [StringLength(200)] - public string BankName { get; set; } = string.Empty; - public Guid RankId { get; set; } + public Guid DoctorId { get; set; } - [Column(TypeName = "decimal(18,2)")] - public decimal Additional { get; set; } + public string DoctorNameInBank { get; set; } = null!; + + [StringLength(400)] + public string IDCard { get; set; } = null!; + + public Guid RankId { get; set; } - } }