Add migration
This commit is contained in:
1158
Migrations/25641019135022_AddLevelScore.Designer.cs
generated
Normal file
1158
Migrations/25641019135022_AddLevelScore.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load Diff
47
Migrations/25641019135022_AddLevelScore.cs
Normal file
47
Migrations/25641019135022_AddLevelScore.cs
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
using System;
|
||||||
|
using Microsoft.EntityFrameworkCore.Migrations;
|
||||||
|
|
||||||
|
namespace tb320eva.Migrations
|
||||||
|
{
|
||||||
|
public partial class AddLevelScore : Migration
|
||||||
|
{
|
||||||
|
protected override void Up(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.CreateTable(
|
||||||
|
name: "eva_level_score_detail",
|
||||||
|
columns: table => new
|
||||||
|
{
|
||||||
|
id = table.Column<Guid>(nullable: false),
|
||||||
|
created = table.Column<DateTime>(nullable: false),
|
||||||
|
updated = table.Column<DateTime>(nullable: false),
|
||||||
|
isActive = table.Column<bool>(nullable: false),
|
||||||
|
level_score_id = table.Column<Guid>(nullable: false),
|
||||||
|
min_value = table.Column<decimal>(nullable: true),
|
||||||
|
max_value = table.Column<decimal>(nullable: true),
|
||||||
|
min_percentage = table.Column<decimal>(nullable: true),
|
||||||
|
max_percentage = table.Column<decimal>(nullable: true)
|
||||||
|
},
|
||||||
|
constraints: table =>
|
||||||
|
{
|
||||||
|
table.PrimaryKey("PK_eva_level_score_detail", x => x.id);
|
||||||
|
table.ForeignKey(
|
||||||
|
name: "FK_eva_level_score_detail_eva_level_score_level_score_id",
|
||||||
|
column: x => x.level_score_id,
|
||||||
|
principalTable: "eva_level_score",
|
||||||
|
principalColumn: "id",
|
||||||
|
onDelete: ReferentialAction.Cascade);
|
||||||
|
});
|
||||||
|
|
||||||
|
migrationBuilder.CreateIndex(
|
||||||
|
name: "IX_eva_level_score_detail_level_score_id",
|
||||||
|
table: "eva_level_score_detail",
|
||||||
|
column: "level_score_id");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected override void Down(MigrationBuilder migrationBuilder)
|
||||||
|
{
|
||||||
|
migrationBuilder.DropTable(
|
||||||
|
name: "eva_level_score_detail");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -16,7 +16,7 @@ namespace tb320eva.Migrations
|
|||||||
#pragma warning disable 612, 618
|
#pragma warning disable 612, 618
|
||||||
modelBuilder
|
modelBuilder
|
||||||
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.SerialColumn)
|
.HasAnnotation("Npgsql:ValueGenerationStrategy", NpgsqlValueGenerationStrategy.SerialColumn)
|
||||||
.HasAnnotation("ProductVersion", "2.2.6-servicing-10079")
|
.HasAnnotation("ProductVersion", "2.2.4-servicing-10062")
|
||||||
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
.HasAnnotation("Relational:MaxIdentifierLength", 63);
|
||||||
|
|
||||||
modelBuilder.Entity("TodoAPI2.Models.activity_log_evaEntity", b =>
|
modelBuilder.Entity("TodoAPI2.Models.activity_log_evaEntity", b =>
|
||||||
@@ -723,6 +723,33 @@ namespace tb320eva.Migrations
|
|||||||
b.ToTable("eva_level_score");
|
b.ToTable("eva_level_score");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("TodoAPI2.Models.eva_level_score_detailEntity", b =>
|
||||||
|
{
|
||||||
|
b.Property<Guid>("id");
|
||||||
|
|
||||||
|
b.Property<DateTime>("created");
|
||||||
|
|
||||||
|
b.Property<bool>("isActive");
|
||||||
|
|
||||||
|
b.Property<Guid>("level_score_id");
|
||||||
|
|
||||||
|
b.Property<decimal?>("max_percentage");
|
||||||
|
|
||||||
|
b.Property<decimal?>("max_value");
|
||||||
|
|
||||||
|
b.Property<decimal?>("min_percentage");
|
||||||
|
|
||||||
|
b.Property<decimal?>("min_value");
|
||||||
|
|
||||||
|
b.Property<DateTime>("updated");
|
||||||
|
|
||||||
|
b.HasKey("id");
|
||||||
|
|
||||||
|
b.HasIndex("level_score_id");
|
||||||
|
|
||||||
|
b.ToTable("eva_level_score_detail");
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("TodoAPI2.Models.eva_limit_frame_employeeEntity", b =>
|
modelBuilder.Entity("TodoAPI2.Models.eva_limit_frame_employeeEntity", b =>
|
||||||
{
|
{
|
||||||
b.Property<Guid>("id");
|
b.Property<Guid>("id");
|
||||||
@@ -1077,6 +1104,14 @@ namespace tb320eva.Migrations
|
|||||||
.HasForeignKey("create_evaluation_detail_id");
|
.HasForeignKey("create_evaluation_detail_id");
|
||||||
});
|
});
|
||||||
|
|
||||||
|
modelBuilder.Entity("TodoAPI2.Models.eva_level_score_detailEntity", b =>
|
||||||
|
{
|
||||||
|
b.HasOne("TodoAPI2.Models.eva_level_scoreEntity", "eva_level_score_level_score_id")
|
||||||
|
.WithMany()
|
||||||
|
.HasForeignKey("level_score_id")
|
||||||
|
.OnDelete(DeleteBehavior.Cascade);
|
||||||
|
});
|
||||||
|
|
||||||
modelBuilder.Entity("TodoAPI2.Models.eva_limit_frame_employeeEntity", b =>
|
modelBuilder.Entity("TodoAPI2.Models.eva_limit_frame_employeeEntity", b =>
|
||||||
{
|
{
|
||||||
b.HasOne("TodoAPI2.Models.eva_limit_frame_groupEntity", "eva_limit_frame_group_frame_group_guid")
|
b.HasOne("TodoAPI2.Models.eva_limit_frame_groupEntity", "eva_limit_frame_group_frame_group_guid")
|
||||||
|
|||||||
Reference in New Issue
Block a user