hrms-api-backend/BMA.EHR.Infrastructure/Migrations/20250205090626_update table placementProfile add dnaroot1.cs
2025-02-05 17:48:58 +07:00

317 lines
11 KiB
C#

using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace BMA.EHR.Infrastructure.Migrations
{
/// <inheritdoc />
public partial class updatetableplacementProfileadddnaroot1 : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<string>(
name: "child1DnaOldId",
table: "RetirementResigns",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child1 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child2DnaOldId",
table: "RetirementResigns",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child2 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child3DnaOldId",
table: "RetirementResigns",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child3 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child4DnaOldId",
table: "RetirementResigns",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child4 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "rootDnaOldId",
table: "RetirementResigns",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน root old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child1DnaOldId",
table: "RetirementResignEmployees",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child1 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child2DnaOldId",
table: "RetirementResignEmployees",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child2 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child3DnaOldId",
table: "RetirementResignEmployees",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child3 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child4DnaOldId",
table: "RetirementResignEmployees",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child4 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "rootDnaOldId",
table: "RetirementResignEmployees",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน root old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child1DnaId",
table: "RetirementProfiles",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child1 ")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child2DnaId",
table: "RetirementProfiles",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child2 ")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child3DnaId",
table: "RetirementProfiles",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child3 ")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child4DnaId",
table: "RetirementProfiles",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child4 ")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "rootDnaId",
table: "RetirementProfiles",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน root ")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child1DnaOldId",
table: "RetirementOuts",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child1 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child2DnaOldId",
table: "RetirementOuts",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child2 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child3DnaOldId",
table: "RetirementOuts",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child3 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child4DnaOldId",
table: "RetirementOuts",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child4 old")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "rootDnaOldId",
table: "RetirementOuts",
type: "longtext",
nullable: true)
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child1DnaId",
table: "RetirementDeceaseds",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child1")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child2DnaId",
table: "RetirementDeceaseds",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child2")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child3DnaId",
table: "RetirementDeceaseds",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child3")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "child4DnaId",
table: "RetirementDeceaseds",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน child4")
.Annotation("MySql:CharSet", "utf8mb4");
migrationBuilder.AddColumn<string>(
name: "rootDnaId",
table: "RetirementDeceaseds",
type: "longtext",
nullable: true,
comment: "id หน่วยงาน root")
.Annotation("MySql:CharSet", "utf8mb4");
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "child1DnaOldId",
table: "RetirementResigns");
migrationBuilder.DropColumn(
name: "child2DnaOldId",
table: "RetirementResigns");
migrationBuilder.DropColumn(
name: "child3DnaOldId",
table: "RetirementResigns");
migrationBuilder.DropColumn(
name: "child4DnaOldId",
table: "RetirementResigns");
migrationBuilder.DropColumn(
name: "rootDnaOldId",
table: "RetirementResigns");
migrationBuilder.DropColumn(
name: "child1DnaOldId",
table: "RetirementResignEmployees");
migrationBuilder.DropColumn(
name: "child2DnaOldId",
table: "RetirementResignEmployees");
migrationBuilder.DropColumn(
name: "child3DnaOldId",
table: "RetirementResignEmployees");
migrationBuilder.DropColumn(
name: "child4DnaOldId",
table: "RetirementResignEmployees");
migrationBuilder.DropColumn(
name: "rootDnaOldId",
table: "RetirementResignEmployees");
migrationBuilder.DropColumn(
name: "child1DnaId",
table: "RetirementProfiles");
migrationBuilder.DropColumn(
name: "child2DnaId",
table: "RetirementProfiles");
migrationBuilder.DropColumn(
name: "child3DnaId",
table: "RetirementProfiles");
migrationBuilder.DropColumn(
name: "child4DnaId",
table: "RetirementProfiles");
migrationBuilder.DropColumn(
name: "rootDnaId",
table: "RetirementProfiles");
migrationBuilder.DropColumn(
name: "child1DnaOldId",
table: "RetirementOuts");
migrationBuilder.DropColumn(
name: "child2DnaOldId",
table: "RetirementOuts");
migrationBuilder.DropColumn(
name: "child3DnaOldId",
table: "RetirementOuts");
migrationBuilder.DropColumn(
name: "child4DnaOldId",
table: "RetirementOuts");
migrationBuilder.DropColumn(
name: "rootDnaOldId",
table: "RetirementOuts");
migrationBuilder.DropColumn(
name: "child1DnaId",
table: "RetirementDeceaseds");
migrationBuilder.DropColumn(
name: "child2DnaId",
table: "RetirementDeceaseds");
migrationBuilder.DropColumn(
name: "child3DnaId",
table: "RetirementDeceaseds");
migrationBuilder.DropColumn(
name: "child4DnaId",
table: "RetirementDeceaseds");
migrationBuilder.DropColumn(
name: "rootDnaId",
table: "RetirementDeceaseds");
}
}
}