12 changed files with 29250 additions and 87 deletions
-
24src/Shentun.Peis.Domain/OcCheckTypes/OcCheckType.cs
-
21src/Shentun.Peis.Domain/PoisonTypes/PoisonType.cs
-
24src/Shentun.Peis.Domain/Poisons/Poison.cs
-
39src/Shentun.Peis.Domain/ProtectiveMeasuress/ProtectiveMeasures.cs
-
24src/Shentun.Peis.Domain/Symptoms/Symptom.cs
-
36src/Shentun.Peis.EntityFrameworkCore/DbMapping/ProtectiveMeasuress/ProtectiveMeasuresDbMapping.cs
-
4src/Shentun.Peis.EntityFrameworkCore/EntityFrameworkCore/PeisDbContext.cs
-
14520src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155735_init20240520004.Designer.cs
-
38src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155735_init20240520004.cs
-
14520src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155942_init20240520005.Designer.cs
-
41src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155942_init20240520005.cs
-
46src/Shentun.Peis.EntityFrameworkCore/Migrations/PeisDbContextModelSnapshot.cs
@ -0,0 +1,39 @@ |
|||
using System; |
|||
using System.Collections.Generic; |
|||
using System.Linq; |
|||
using System.Text; |
|||
using System.Threading.Tasks; |
|||
using Volo.Abp.Domain.Entities.Auditing; |
|||
using Volo.Abp.Domain.Entities; |
|||
using System.ComponentModel.DataAnnotations.Schema; |
|||
using System.ComponentModel.DataAnnotations; |
|||
|
|||
namespace Shentun.Peis.ProtectiveMeasuress |
|||
{ |
|||
/// <summary>
|
|||
/// 防护措施
|
|||
/// </summary>
|
|||
[Table("protective_measures")] |
|||
public class ProtectiveMeasures : AuditedEntity<Guid>, IHasConcurrencyStamp |
|||
{ |
|||
|
|||
/// <summary>
|
|||
/// 防护措施名称
|
|||
/// </summary>
|
|||
[Column("display_name")] |
|||
[StringLength(50)] |
|||
public string DisplayName { get; set; } |
|||
|
|||
[Column("simple_code")] |
|||
[StringLength(50)] |
|||
public string SimpleCode { get; set; } = null!; |
|||
/// <summary>
|
|||
/// 显示顺序
|
|||
/// </summary>
|
|||
[Column("display_order")] |
|||
public int DisplayOrder { get; set; } |
|||
|
|||
[Column("concurrency_stamp")] |
|||
public string ConcurrencyStamp { get; set; } |
|||
} |
|||
} |
|||
@ -0,0 +1,36 @@ |
|||
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.ProtectiveMeasuress; |
|||
using Shentun.Peis.EntityFrameworkCore; |
|||
|
|||
namespace Shentun.Peis.DbMapping |
|||
{ |
|||
|
|||
internal class ProtectiveMeasuresDbMapping : IEntityTypeConfiguration<ProtectiveMeasures> |
|||
{ |
|||
public void Configure(EntityTypeBuilder<ProtectiveMeasures> entity) |
|||
{ |
|||
entity.HasComment("防护措施"); |
|||
|
|||
entity.Property(e => e.Id) |
|||
.IsFixedLength() |
|||
.HasComment("编号").IsRequired(); |
|||
|
|||
|
|||
entity.Property(e => e.DisplayOrder).HasComment("显示顺序").IsRequired().HasDefaultValueSql("999999"); |
|||
|
|||
|
|||
entity.Property(e => e.DisplayName).HasComment("体检类别名称").IsRequired(); |
|||
|
|||
entity.Property(e => e.SimpleCode).HasComment("自定义简码").IsRequired(); |
|||
|
|||
entity.ConfigureByConvention(); |
|||
} |
|||
} |
|||
} |
|||
14520
src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155735_init20240520004.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,38 @@ |
|||
using System; |
|||
using Microsoft.EntityFrameworkCore.Migrations; |
|||
|
|||
#nullable disable |
|||
|
|||
namespace Shentun.Peis.Migrations |
|||
{ |
|||
public partial class init20240520004 : Migration |
|||
{ |
|||
protected override void Up(MigrationBuilder migrationBuilder) |
|||
{ |
|||
migrationBuilder.CreateTable( |
|||
name: "ProtectiveMeasuress", |
|||
columns: table => new |
|||
{ |
|||
Id = table.Column<Guid>(type: "uuid", nullable: false), |
|||
display_name = table.Column<string>(type: "character varying(50)", maxLength: 50, nullable: true), |
|||
simple_code = table.Column<string>(type: "character varying(50)", maxLength: 50, nullable: true), |
|||
display_order = table.Column<int>(type: "integer", nullable: false), |
|||
ConcurrencyStamp = table.Column<string>(type: "character varying(40)", maxLength: 40, nullable: true), |
|||
CreationTime = table.Column<DateTime>(type: "timestamp without time zone", nullable: false), |
|||
CreatorId = table.Column<Guid>(type: "uuid", nullable: true), |
|||
LastModificationTime = table.Column<DateTime>(type: "timestamp without time zone", nullable: true), |
|||
LastModifierId = table.Column<Guid>(type: "uuid", nullable: true) |
|||
}, |
|||
constraints: table => |
|||
{ |
|||
table.PrimaryKey("PK_ProtectiveMeasuress", x => x.Id); |
|||
}); |
|||
} |
|||
|
|||
protected override void Down(MigrationBuilder migrationBuilder) |
|||
{ |
|||
migrationBuilder.DropTable( |
|||
name: "ProtectiveMeasuress"); |
|||
} |
|||
} |
|||
} |
|||
14520
src/Shentun.Peis.EntityFrameworkCore/Migrations/20240520155942_init20240520005.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,41 @@ |
|||
using Microsoft.EntityFrameworkCore.Migrations; |
|||
|
|||
#nullable disable |
|||
|
|||
namespace Shentun.Peis.Migrations |
|||
{ |
|||
public partial class init20240520005 : Migration |
|||
{ |
|||
protected override void Up(MigrationBuilder migrationBuilder) |
|||
{ |
|||
migrationBuilder.DropPrimaryKey( |
|||
name: "PK_ProtectiveMeasuress", |
|||
table: "ProtectiveMeasuress"); |
|||
|
|||
migrationBuilder.RenameTable( |
|||
name: "ProtectiveMeasuress", |
|||
newName: "protective_measures"); |
|||
|
|||
migrationBuilder.AddPrimaryKey( |
|||
name: "PK_protective_measures", |
|||
table: "protective_measures", |
|||
column: "Id"); |
|||
} |
|||
|
|||
protected override void Down(MigrationBuilder migrationBuilder) |
|||
{ |
|||
migrationBuilder.DropPrimaryKey( |
|||
name: "PK_protective_measures", |
|||
table: "protective_measures"); |
|||
|
|||
migrationBuilder.RenameTable( |
|||
name: "protective_measures", |
|||
newName: "ProtectiveMeasuress"); |
|||
|
|||
migrationBuilder.AddPrimaryKey( |
|||
name: "PK_ProtectiveMeasuress", |
|||
table: "ProtectiveMeasuress", |
|||
column: "Id"); |
|||
} |
|||
} |
|||
} |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue