82 lines
3.6 KiB
C#
82 lines
3.6 KiB
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace BMA.EHR.Infrastructure.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class update_table_placementRepatriation_add_refId1 : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AlterColumn<string>(
|
|
name: "PositionName",
|
|
table: "RetirementDeceasedNotis",
|
|
type: "longtext",
|
|
nullable: true,
|
|
comment: "ชื่อตำแหน่งของผู้รับสำเนาคำสั่ง",
|
|
oldClrType: typeof(string),
|
|
oldType: "longtext",
|
|
oldComment: "ชื่อตำแหน่งของผู้รับสำเนาคำสั่ง")
|
|
.Annotation("MySql:CharSet", "utf8mb4")
|
|
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
|
|
|
migrationBuilder.AlterColumn<string>(
|
|
name: "OrganizationName",
|
|
table: "RetirementDeceasedNotis",
|
|
type: "longtext",
|
|
nullable: true,
|
|
comment: "ชื่อหน่วยงานของผู้รับสำเนาคำสั่ง",
|
|
oldClrType: typeof(string),
|
|
oldType: "longtext",
|
|
oldComment: "ชื่อหน่วยงานของผู้รับสำเนาคำสั่ง")
|
|
.Annotation("MySql:CharSet", "utf8mb4")
|
|
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.UpdateData(
|
|
table: "RetirementDeceasedNotis",
|
|
keyColumn: "PositionName",
|
|
keyValue: null,
|
|
column: "PositionName",
|
|
value: "");
|
|
|
|
migrationBuilder.AlterColumn<string>(
|
|
name: "PositionName",
|
|
table: "RetirementDeceasedNotis",
|
|
type: "longtext",
|
|
nullable: false,
|
|
comment: "ชื่อตำแหน่งของผู้รับสำเนาคำสั่ง",
|
|
oldClrType: typeof(string),
|
|
oldType: "longtext",
|
|
oldNullable: true,
|
|
oldComment: "ชื่อตำแหน่งของผู้รับสำเนาคำสั่ง")
|
|
.Annotation("MySql:CharSet", "utf8mb4")
|
|
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
|
|
|
migrationBuilder.UpdateData(
|
|
table: "RetirementDeceasedNotis",
|
|
keyColumn: "OrganizationName",
|
|
keyValue: null,
|
|
column: "OrganizationName",
|
|
value: "");
|
|
|
|
migrationBuilder.AlterColumn<string>(
|
|
name: "OrganizationName",
|
|
table: "RetirementDeceasedNotis",
|
|
type: "longtext",
|
|
nullable: false,
|
|
comment: "ชื่อหน่วยงานของผู้รับสำเนาคำสั่ง",
|
|
oldClrType: typeof(string),
|
|
oldType: "longtext",
|
|
oldNullable: true,
|
|
oldComment: "ชื่อหน่วยงานของผู้รับสำเนาคำสั่ง")
|
|
.Annotation("MySql:CharSet", "utf8mb4")
|
|
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
|
}
|
|
}
|
|
}
|