เพิ่มเรื่องร้องเรียนตอนออกคำสั่ง

This commit is contained in:
Kittapath 2024-01-15 10:38:28 +07:00
parent 4f32e253fd
commit 5ca85c6e7e
13 changed files with 4045 additions and 58 deletions

View file

@ -0,0 +1,52 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace BMA.EHR.Infrastructure.Migrations.DisciplineDb
{
/// <inheritdoc />
public partial class updatetableDisciplineDisciplinary_DirectorInvestigatesdatestartnullable3 : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<Guid>(
name: "DisciplineDisciplinaryId",
table: "DisciplineReport_Profiles",
type: "char(36)",
nullable: false,
defaultValue: new Guid("00000000-0000-0000-0000-000000000000"),
collation: "ascii_general_ci");
migrationBuilder.CreateIndex(
name: "IX_DisciplineReport_Profiles_DisciplineDisciplinaryId",
table: "DisciplineReport_Profiles",
column: "DisciplineDisciplinaryId");
migrationBuilder.AddForeignKey(
name: "FK_DisciplineReport_Profiles_DisciplineDisciplinarys_Discipline~",
table: "DisciplineReport_Profiles",
column: "DisciplineDisciplinaryId",
principalTable: "DisciplineDisciplinarys",
principalColumn: "Id",
onDelete: ReferentialAction.Cascade);
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropForeignKey(
name: "FK_DisciplineReport_Profiles_DisciplineDisciplinarys_Discipline~",
table: "DisciplineReport_Profiles");
migrationBuilder.DropIndex(
name: "IX_DisciplineReport_Profiles_DisciplineDisciplinaryId",
table: "DisciplineReport_Profiles");
migrationBuilder.DropColumn(
name: "DisciplineDisciplinaryId",
table: "DisciplineReport_Profiles");
}
}
}

View file

@ -2399,6 +2399,9 @@ namespace BMA.EHR.Infrastructure.Migrations.DisciplineDb
.HasColumnType("longtext")
.HasComment("ระดับโทษความผิด กรณีไม่ร้ายแรง: ภาคทัณฑ์, ตัดเงินเดือน, ลดขั้นเงินเดือน | กรณีร้ายแรง: ปลดออก, ไล่ออก");
b.Property<Guid>("DisciplineDisciplinaryId")
.HasColumnType("char(36)");
b.Property<DateTime?>("EndDateSuspend")
.HasColumnType("datetime(6)")
.HasComment("วันสิ้นสุดการสั่งพักราชการ/ให้ออกจากราชการไว้ก่อน");
@ -2480,6 +2483,8 @@ namespace BMA.EHR.Infrastructure.Migrations.DisciplineDb
b.HasKey("Id");
b.HasIndex("DisciplineDisciplinaryId");
b.ToTable("DisciplineReport_Profiles");
});
@ -2909,6 +2914,17 @@ namespace BMA.EHR.Infrastructure.Migrations.DisciplineDb
b.Navigation("DisciplineInvestigate");
});
modelBuilder.Entity("BMA.EHR.Domain.Models.Discipline.DisciplineReport_Profile", b =>
{
b.HasOne("BMA.EHR.Domain.Models.Discipline.DisciplineDisciplinary", "DisciplineDisciplinary")
.WithMany()
.HasForeignKey("DisciplineDisciplinaryId")
.OnDelete(DeleteBehavior.Cascade)
.IsRequired();
b.Navigation("DisciplineDisciplinary");
});
modelBuilder.Entity("BMA.EHR.Domain.Models.Discipline.DisciplineComplaint", b =>
{
b.Navigation("DisciplineComplaint_Docs");