13 changed files with 16620 additions and 1 deletions
-
19src/Shentun.Peis.Application.Contracts/PatientRegisters/UpdatePatientRegisterMedicalStartDateInputDto.cs
-
26src/Shentun.Peis.Application/PatientRegisters/PatientRegisterAppService.cs
-
7src/Shentun.Peis.Domain/PatientRegisters/PatientRegister.cs
-
109src/Shentun.Peis.Domain/ThirdBookings/ThirdBooking.cs
-
40src/Shentun.Peis.Domain/ThirdMedicalCenterBookingDates/ThirdMedicalCenterBookingDate.cs
-
48src/Shentun.Peis.Domain/ThirdMedicalCenters/ThirdMedicalCenter.cs
-
37src/Shentun.Peis.EntityFrameworkCore/DbMapping/ThirdBookings/ThirdBookingDbMapping.cs
-
26src/Shentun.Peis.EntityFrameworkCore/DbMapping/ThirdMedicalCenterBookingDates/ThirdMedicalCenterBookingDateDbMapping.cs
-
27src/Shentun.Peis.EntityFrameworkCore/DbMapping/ThirdMedicalCenters/ThirdMedicalCenterDbMapping.cs
-
11src/Shentun.Peis.EntityFrameworkCore/EntityFrameworkCore/PeisDbContext.cs
-
15948src/Shentun.Peis.EntityFrameworkCore/Migrations/20240926065811_insert_third_booking.Designer.cs
-
103src/Shentun.Peis.EntityFrameworkCore/Migrations/20240926065811_insert_third_booking.cs
-
220src/Shentun.Peis.EntityFrameworkCore/Migrations/PeisDbContextModelSnapshot.cs
@ -0,0 +1,19 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Text; |
||||
|
|
||||
|
namespace Shentun.Peis.PatientRegisters |
||||
|
{ |
||||
|
public class UpdatePatientRegisterMedicalStartDateInputDto |
||||
|
{ |
||||
|
/// <summary>
|
||||
|
/// 体检开始日期
|
||||
|
/// </summary>
|
||||
|
public string MedicalStartDate { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 登记ID 集合
|
||||
|
/// </summary>
|
||||
|
public List<Guid> PatientRegisterIds { get; set; } = new List<Guid>(); |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,109 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.ComponentModel.DataAnnotations.Schema; |
||||
|
using System.ComponentModel.DataAnnotations; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Volo.Abp.Domain.Entities.Auditing; |
||||
|
using Volo.Abp.Domain.Entities; |
||||
|
using Org.BouncyCastle.Crypto.Tls; |
||||
|
|
||||
|
namespace Shentun.Peis.Models |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 第三方预约人员记录
|
||||
|
/// </summary>
|
||||
|
[Table("third_booking")] |
||||
|
public class ThirdBooking : AuditedEntity<Guid>, IHasConcurrencyStamp |
||||
|
{ |
||||
|
/// <summary>
|
||||
|
/// 姓名
|
||||
|
/// </summary>
|
||||
|
[Column("patient_name")] |
||||
|
[StringLength(100)] |
||||
|
public string PatientName { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 单位分组ID
|
||||
|
/// </summary>
|
||||
|
[Column("customer_org_group_id")] |
||||
|
[StringLength(32)] |
||||
|
public string CustomerOrgGroupId { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 第三方体检中心Id
|
||||
|
/// </summary>
|
||||
|
[Column("third_medical_center_id")] |
||||
|
[StringLength(32)] |
||||
|
public string ThirdMedicalCenterId { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 身份证类型( 0 身份证 )
|
||||
|
/// </summary>
|
||||
|
[StringLength(2)] |
||||
|
[Column("id_type")] |
||||
|
public string IdType { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 身份证
|
||||
|
/// </summary>
|
||||
|
[StringLength(18)] |
||||
|
[Column("id_no")] |
||||
|
public string IdNo { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 性别
|
||||
|
/// </summary>
|
||||
|
[StringLength(2)] |
||||
|
[Column("sex_name")] |
||||
|
public string SexName { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 年龄
|
||||
|
/// </summary>
|
||||
|
[Column("age")] |
||||
|
public short Age { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 预约日期
|
||||
|
/// </summary>
|
||||
|
[Column("booking_date")] |
||||
|
public DateTime BookingDate { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 电话
|
||||
|
/// </summary>
|
||||
|
[StringLength(20)] |
||||
|
[Column("phone")] |
||||
|
public string Phone { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 分公司
|
||||
|
/// </summary>
|
||||
|
[StringLength(100)] |
||||
|
[Column("child_company_name")] |
||||
|
public string ChildCompanyName { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 部门
|
||||
|
/// </summary>
|
||||
|
[StringLength(100)] |
||||
|
[Column("department_name")] |
||||
|
public string DepartmentName { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 婚姻状况
|
||||
|
/// </summary>
|
||||
|
[StringLength(20)] |
||||
|
[Column("marital_status_name")] |
||||
|
public string MaritalStatusName { get; set; } |
||||
|
|
||||
|
[Column("concurrency_stamp")] |
||||
|
public string ConcurrencyStamp { get; set; } |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,40 @@ |
|||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.ComponentModel.DataAnnotations.Schema; |
||||
|
using System.ComponentModel.DataAnnotations; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Volo.Abp.Domain.Entities.Auditing; |
||||
|
using Volo.Abp.Domain.Entities; |
||||
|
|
||||
|
namespace Shentun.Peis.Models |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 第三方体检中心预约日期
|
||||
|
/// </summary>
|
||||
|
[Table("third_medical_center_booking_date")] |
||||
|
public class ThirdMedicalCenterBookingDate : AuditedEntity<Guid>, IHasConcurrencyStamp |
||||
|
{ |
||||
|
/// <summary>
|
||||
|
/// 第三方体检中心id
|
||||
|
/// </summary>
|
||||
|
[Column("third_medical_center_id")] |
||||
|
|
||||
|
public Guid ThirdMedicalCenterId { get; set; } |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 可以预约日期
|
||||
|
/// </summary>
|
||||
|
[Column("booking_date")] |
||||
|
public DateTime BookingDate { get; set; } |
||||
|
|
||||
|
|
||||
|
[Column("concurrency_stamp")] |
||||
|
public string ConcurrencyStamp { get; set; } |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,48 @@ |
|||||
|
using Microsoft.EntityFrameworkCore; |
||||
|
using Shentun.Peis.Models; |
||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.ComponentModel.DataAnnotations.Schema; |
||||
|
using System.ComponentModel.DataAnnotations; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Volo.Abp.Domain.Entities.Auditing; |
||||
|
using Volo.Abp.Domain.Entities; |
||||
|
|
||||
|
namespace Shentun.Peis.Models |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 第三方预约体检中心
|
||||
|
/// </summary>
|
||||
|
[Table("third_medical_center")] |
||||
|
public class ThirdMedicalCenter : AuditedEntity<Guid>, IHasConcurrencyStamp, IDisplayName, IDisplayOrder |
||||
|
{ |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 名称
|
||||
|
/// </summary>
|
||||
|
[Column("display_name")] |
||||
|
[StringLength(100)] |
||||
|
public string DisplayName { get; set; } = null!; |
||||
|
|
||||
|
/// <summary>
|
||||
|
/// 单位分组ID
|
||||
|
/// </summary>
|
||||
|
[Column("customer_org_group_id")] |
||||
|
|
||||
|
public Guid CustomerOrgGroupId { get; set; } |
||||
|
|
||||
|
|
||||
|
|
||||
|
[Column("display_order")] |
||||
|
public int DisplayOrder { get; set; } |
||||
|
|
||||
|
[Column("concurrency_stamp")] |
||||
|
public string ConcurrencyStamp { get; set; } |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,37 @@ |
|||||
|
using Microsoft.EntityFrameworkCore.Metadata.Builders; |
||||
|
using Microsoft.EntityFrameworkCore; |
||||
|
using Shentun.Peis.Models; |
||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Shentun.Peis.EntityFrameworkCore; |
||||
|
|
||||
|
namespace Shentun.Peis.DbMapping |
||||
|
{ |
||||
|
|
||||
|
internal class ThirdBookingDbMapping : IEntityTypeConfiguration<ThirdBooking> |
||||
|
{ |
||||
|
public void Configure(EntityTypeBuilder<ThirdBooking> entity) |
||||
|
{ |
||||
|
entity.HasComment("第三方预约人员记录"); |
||||
|
entity.Property(t => t.PatientName).HasComment("姓名").IsRequired(); |
||||
|
entity.Property(t => t.CustomerOrgGroupId).HasComment("单位分组ID"); |
||||
|
entity.Property(t => t.ThirdMedicalCenterId).HasComment("第三方体检中心Id"); |
||||
|
entity.Property(t => t.IdType).HasComment("身份证类型").IsRequired(); |
||||
|
entity.Property(t => t.IdNo).HasComment("身份证").IsRequired(); |
||||
|
entity.Property(t => t.SexName).HasComment("性别"); |
||||
|
entity.Property(t => t.Age).HasComment("年龄"); |
||||
|
entity.Property(t => t.BookingDate).HasComment("预约日期"); |
||||
|
entity.Property(t => t.Phone).HasComment("电话"); |
||||
|
entity.Property(t => t.ChildCompanyName).HasComment("分公司"); |
||||
|
entity.Property(t => t.DepartmentName).HasComment("部门"); |
||||
|
entity.Property(t => t.MaritalStatusName).HasComment("婚姻状况"); |
||||
|
entity.Property(e => e.Id).IsFixedLength().IsRequired(); |
||||
|
|
||||
|
|
||||
|
entity.ConfigureByConvention(); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,26 @@ |
|||||
|
using Microsoft.EntityFrameworkCore.Metadata.Builders; |
||||
|
using Microsoft.EntityFrameworkCore; |
||||
|
using Shentun.Peis.Models; |
||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Shentun.Peis.EntityFrameworkCore; |
||||
|
|
||||
|
namespace Shentun.Peis.DbMapping |
||||
|
{ |
||||
|
internal class ThirdMedicalCenterBookingDateDbMapping : IEntityTypeConfiguration<ThirdMedicalCenterBookingDate> |
||||
|
{ |
||||
|
public void Configure(EntityTypeBuilder<ThirdMedicalCenterBookingDate> entity) |
||||
|
{ |
||||
|
entity.HasComment("第三方体检中心预约日期"); |
||||
|
entity.Property(t => t.ThirdMedicalCenterId).HasComment("第三方体检中心id").IsRequired(); |
||||
|
entity.Property(t => t.BookingDate).HasComment("可以预约日期").IsRequired(); |
||||
|
entity.Property(e => e.Id).IsFixedLength().IsRequired(); |
||||
|
|
||||
|
|
||||
|
entity.ConfigureByConvention(); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
@ -0,0 +1,27 @@ |
|||||
|
using Microsoft.EntityFrameworkCore.Metadata.Builders; |
||||
|
using Microsoft.EntityFrameworkCore; |
||||
|
using Shentun.Peis.Models; |
||||
|
using System; |
||||
|
using System.Collections.Generic; |
||||
|
using System.Linq; |
||||
|
using System.Text; |
||||
|
using System.Threading.Tasks; |
||||
|
using Shentun.Peis.EntityFrameworkCore; |
||||
|
|
||||
|
namespace Shentun.Peis.DbMapping |
||||
|
{ |
||||
|
|
||||
|
internal class ThirdMedicalCenterDbMapping : IEntityTypeConfiguration<ThirdMedicalCenter> |
||||
|
{ |
||||
|
public void Configure(EntityTypeBuilder<ThirdMedicalCenter> entity) |
||||
|
{ |
||||
|
entity.HasComment("第三方预约人员记录"); |
||||
|
entity.Property(t => t.DisplayName).HasComment("体检中心名称").IsRequired(); |
||||
|
entity.Property(t => t.CustomerOrgGroupId).HasComment("单位分组ID"); |
||||
|
entity.Property(e => e.Id).IsFixedLength().IsRequired(); |
||||
|
|
||||
|
|
||||
|
entity.ConfigureByConvention(); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
15948
src/Shentun.Peis.EntityFrameworkCore/Migrations/20240926065811_insert_third_booking.Designer.cs
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -0,0 +1,103 @@ |
|||||
|
using System; |
||||
|
using Microsoft.EntityFrameworkCore.Migrations; |
||||
|
|
||||
|
#nullable disable |
||||
|
|
||||
|
namespace Shentun.Peis.Migrations |
||||
|
{ |
||||
|
public partial class insert_third_booking : Migration |
||||
|
{ |
||||
|
protected override void Up(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.AddColumn<string>( |
||||
|
name: "Third_Booking_Id", |
||||
|
table: "patient_register", |
||||
|
type: "text", |
||||
|
nullable: true); |
||||
|
|
||||
|
migrationBuilder.CreateTable( |
||||
|
name: "third_booking", |
||||
|
columns: table => new |
||||
|
{ |
||||
|
id = table.Column<Guid>(type: "uuid", fixedLength: true, nullable: false), |
||||
|
patient_name = table.Column<string>(type: "character varying(100)", maxLength: 100, nullable: false, comment: "姓名"), |
||||
|
customer_org_group_id = table.Column<string>(type: "character varying(32)", maxLength: 32, nullable: true, comment: "单位分组ID"), |
||||
|
third_medical_center_id = table.Column<string>(type: "character varying(32)", maxLength: 32, nullable: true, comment: "第三方体检中心Id"), |
||||
|
id_type = table.Column<string>(type: "character varying(2)", maxLength: 2, nullable: false, comment: "身份证类型"), |
||||
|
id_no = table.Column<string>(type: "character varying(18)", maxLength: 18, nullable: false, comment: "身份证"), |
||||
|
sex_name = table.Column<string>(type: "character varying(2)", maxLength: 2, nullable: true, comment: "性别"), |
||||
|
age = table.Column<short>(type: "smallint", nullable: false, comment: "年龄"), |
||||
|
booking_date = table.Column<DateTime>(type: "timestamp without time zone", nullable: false, comment: "预约日期"), |
||||
|
phone = table.Column<string>(type: "character varying(20)", maxLength: 20, nullable: true, comment: "电话"), |
||||
|
child_company_name = table.Column<string>(type: "character varying(100)", maxLength: 100, nullable: true, comment: "分公司"), |
||||
|
department_name = table.Column<string>(type: "character varying(100)", maxLength: 100, nullable: true, comment: "部门"), |
||||
|
marital_status_name = table.Column<string>(type: "character varying(20)", maxLength: 20, nullable: true, comment: "婚姻状况"), |
||||
|
concurrency_stamp = table.Column<string>(type: "character varying(40)", maxLength: 40, nullable: true), |
||||
|
creation_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
creator_id = table.Column<Guid>(type: "uuid", nullable: false), |
||||
|
last_modification_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
last_modifier_id = table.Column<Guid>(type: "uuid", nullable: false) |
||||
|
}, |
||||
|
constraints: table => |
||||
|
{ |
||||
|
table.PrimaryKey("PK_third_booking", x => x.id); |
||||
|
}, |
||||
|
comment: "第三方预约人员记录"); |
||||
|
|
||||
|
migrationBuilder.CreateTable( |
||||
|
name: "third_medical_center", |
||||
|
columns: table => new |
||||
|
{ |
||||
|
id = table.Column<Guid>(type: "uuid", fixedLength: true, nullable: false), |
||||
|
display_name = table.Column<string>(type: "character varying(100)", maxLength: 100, nullable: false, comment: "体检中心名称"), |
||||
|
customer_org_group_id = table.Column<Guid>(type: "uuid", nullable: false, comment: "单位分组ID"), |
||||
|
display_order = table.Column<int>(type: "integer", nullable: false), |
||||
|
concurrency_stamp = table.Column<string>(type: "character varying(40)", maxLength: 40, nullable: true), |
||||
|
creation_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
creator_id = table.Column<Guid>(type: "uuid", nullable: false), |
||||
|
last_modification_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
last_modifier_id = table.Column<Guid>(type: "uuid", nullable: false) |
||||
|
}, |
||||
|
constraints: table => |
||||
|
{ |
||||
|
table.PrimaryKey("PK_third_medical_center", x => x.id); |
||||
|
}, |
||||
|
comment: "第三方预约人员记录"); |
||||
|
|
||||
|
migrationBuilder.CreateTable( |
||||
|
name: "third_medical_center_booking_date", |
||||
|
columns: table => new |
||||
|
{ |
||||
|
id = table.Column<Guid>(type: "uuid", fixedLength: true, nullable: false), |
||||
|
third_medical_center_id = table.Column<Guid>(type: "uuid", nullable: false, comment: "第三方体检中心id"), |
||||
|
booking_date = table.Column<DateTime>(type: "timestamp without time zone", nullable: false, comment: "可以预约日期"), |
||||
|
concurrency_stamp = table.Column<string>(type: "character varying(40)", maxLength: 40, nullable: true), |
||||
|
creation_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
creator_id = table.Column<Guid>(type: "uuid", nullable: false), |
||||
|
last_modification_time = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
||||
|
last_modifier_id = table.Column<Guid>(type: "uuid", nullable: false) |
||||
|
}, |
||||
|
constraints: table => |
||||
|
{ |
||||
|
table.PrimaryKey("PK_third_medical_center_booking_date", x => x.id); |
||||
|
}, |
||||
|
comment: "第三方体检中心预约日期"); |
||||
|
} |
||||
|
|
||||
|
protected override void Down(MigrationBuilder migrationBuilder) |
||||
|
{ |
||||
|
migrationBuilder.DropTable( |
||||
|
name: "third_booking"); |
||||
|
|
||||
|
migrationBuilder.DropTable( |
||||
|
name: "third_medical_center"); |
||||
|
|
||||
|
migrationBuilder.DropTable( |
||||
|
name: "third_medical_center_booking_date"); |
||||
|
|
||||
|
migrationBuilder.DropColumn( |
||||
|
name: "Third_Booking_Id", |
||||
|
table: "patient_register"); |
||||
|
} |
||||
|
} |
||||
|
} |
||||
Write
Preview
Loading…
Cancel
Save
Reference in new issue