api list บรรจุ
api list คนในบรรจุ
This commit is contained in:
parent
385d37c985
commit
40e8a2641c
18 changed files with 31546 additions and 54 deletions
10249
BMA.EHR.Infrastructure/Migrations/20230629083241_Update table Placement add PlacementType.Designer.cs
generated
Normal file
10249
BMA.EHR.Infrastructure/Migrations/20230629083241_Update table Placement add PlacementType.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,92 @@
|
|||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace BMA.EHR.Infrastructure.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class UpdatetablePlacementaddPlacementType : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropColumn(
|
||||
name: "TypeExam",
|
||||
table: "Placements");
|
||||
|
||||
migrationBuilder.AddColumn<Guid>(
|
||||
name: "PlacementTypeId",
|
||||
table: "Placements",
|
||||
type: "char(36)",
|
||||
nullable: false,
|
||||
defaultValue: new Guid("00000000-0000-0000-0000-000000000000"),
|
||||
collation: "ascii_general_ci");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "PlacementTypes",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, comment: "PrimaryKey", collation: "ascii_general_ci"),
|
||||
CreatedAt = table.Column<DateTime>(type: "datetime(6)", nullable: false, comment: "สร้างข้อมูลเมื่อ"),
|
||||
CreatedUserId = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "User Id ที่สร้างข้อมูล")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
LastUpdatedAt = table.Column<DateTime>(type: "datetime(6)", nullable: true, comment: "แก้ไขข้อมูลล่าสุดเมื่อ"),
|
||||
LastUpdateUserId = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "User Id ที่แก้ไขข้อมูลล่าสุด")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreatedFullName = table.Column<string>(type: "varchar(200)", maxLength: 200, nullable: false, comment: "ชื่อ User ที่สร้างข้อมูล")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
LastUpdateFullName = table.Column<string>(type: "varchar(200)", maxLength: 200, nullable: false, comment: "ชื่อ User ที่แก้ไขข้อมูลล่าสุด")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
Name = table.Column<string>(type: "longtext", nullable: false, comment: "ชื่อประเภทบรรจุ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IsActive = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "สถานะการใช้งาน")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_PlacementTypes", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.CreateIndex(
|
||||
name: "IX_Placements_PlacementTypeId",
|
||||
table: "Placements",
|
||||
column: "PlacementTypeId");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_Placements_PlacementTypes_PlacementTypeId",
|
||||
table: "Placements",
|
||||
column: "PlacementTypeId",
|
||||
principalTable: "PlacementTypes",
|
||||
principalColumn: "Id",
|
||||
onDelete: ReferentialAction.Cascade);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_Placements_PlacementTypes_PlacementTypeId",
|
||||
table: "Placements");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "PlacementTypes");
|
||||
|
||||
migrationBuilder.DropIndex(
|
||||
name: "IX_Placements_PlacementTypeId",
|
||||
table: "Placements");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "PlacementTypeId",
|
||||
table: "Placements");
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "TypeExam",
|
||||
table: "Placements",
|
||||
type: "longtext",
|
||||
nullable: false,
|
||||
comment: "ประเภทการสอบ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
}
|
||||
}
|
||||
}
|
||||
10212
BMA.EHR.Infrastructure/Migrations/20230629112400_Update table Placement add ReportingDate.Designer.cs
generated
Normal file
10212
BMA.EHR.Infrastructure/Migrations/20230629112400_Update table Placement add ReportingDate.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,124 @@
|
|||
using System;
|
||||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace BMA.EHR.Infrastructure.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class UpdatetablePlacementaddReportingDate : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_PlacementProfiles_PlacementStatuses_PlacementStatusId",
|
||||
table: "PlacementProfiles");
|
||||
|
||||
migrationBuilder.DropTable(
|
||||
name: "PlacementStatuses");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "PlacementStatusId",
|
||||
table: "PlacementProfiles",
|
||||
newName: "GenderId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_PlacementProfiles_PlacementStatusId",
|
||||
table: "PlacementProfiles",
|
||||
newName: "IX_PlacementProfiles_GenderId");
|
||||
|
||||
migrationBuilder.AddColumn<bool>(
|
||||
name: "IsRelief",
|
||||
table: "PlacementProfiles",
|
||||
type: "tinyint(1)",
|
||||
nullable: false,
|
||||
defaultValue: false,
|
||||
comment: "ผ่อนผัน");
|
||||
|
||||
migrationBuilder.AddColumn<string>(
|
||||
name: "PlacementStatus",
|
||||
table: "PlacementProfiles",
|
||||
type: "longtext",
|
||||
nullable: true,
|
||||
comment: "สถานะการบรรจุ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.AddColumn<DateTime>(
|
||||
name: "ReportingDate",
|
||||
table: "PlacementProfiles",
|
||||
type: "datetime(6)",
|
||||
nullable: true,
|
||||
comment: "วันที่รายงานตัว");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_PlacementProfiles_Genders_GenderId",
|
||||
table: "PlacementProfiles",
|
||||
column: "GenderId",
|
||||
principalTable: "Genders",
|
||||
principalColumn: "Id");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.DropForeignKey(
|
||||
name: "FK_PlacementProfiles_Genders_GenderId",
|
||||
table: "PlacementProfiles");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "IsRelief",
|
||||
table: "PlacementProfiles");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "PlacementStatus",
|
||||
table: "PlacementProfiles");
|
||||
|
||||
migrationBuilder.DropColumn(
|
||||
name: "ReportingDate",
|
||||
table: "PlacementProfiles");
|
||||
|
||||
migrationBuilder.RenameColumn(
|
||||
name: "GenderId",
|
||||
table: "PlacementProfiles",
|
||||
newName: "PlacementStatusId");
|
||||
|
||||
migrationBuilder.RenameIndex(
|
||||
name: "IX_PlacementProfiles_GenderId",
|
||||
table: "PlacementProfiles",
|
||||
newName: "IX_PlacementProfiles_PlacementStatusId");
|
||||
|
||||
migrationBuilder.CreateTable(
|
||||
name: "PlacementStatuses",
|
||||
columns: table => new
|
||||
{
|
||||
Id = table.Column<Guid>(type: "char(36)", nullable: false, comment: "PrimaryKey", collation: "ascii_general_ci"),
|
||||
CreatedAt = table.Column<DateTime>(type: "datetime(6)", nullable: false, comment: "สร้างข้อมูลเมื่อ"),
|
||||
CreatedUserId = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "User Id ที่สร้างข้อมูล")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
LastUpdatedAt = table.Column<DateTime>(type: "datetime(6)", nullable: true, comment: "แก้ไขข้อมูลล่าสุดเมื่อ"),
|
||||
LastUpdateUserId = table.Column<string>(type: "varchar(40)", maxLength: 40, nullable: false, comment: "User Id ที่แก้ไขข้อมูลล่าสุด")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
CreatedFullName = table.Column<string>(type: "varchar(200)", maxLength: 200, nullable: false, comment: "ชื่อ User ที่สร้างข้อมูล")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
LastUpdateFullName = table.Column<string>(type: "varchar(200)", maxLength: 200, nullable: false, comment: "ชื่อ User ที่แก้ไขข้อมูลล่าสุด")
|
||||
.Annotation("MySql:CharSet", "utf8mb4"),
|
||||
IsActive = table.Column<bool>(type: "tinyint(1)", nullable: false, comment: "สถานะการใช้งาน"),
|
||||
Name = table.Column<string>(type: "longtext", nullable: false, comment: "ชื่อสถานะบรรจุ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
},
|
||||
constraints: table =>
|
||||
{
|
||||
table.PrimaryKey("PK_PlacementStatuses", x => x.Id);
|
||||
})
|
||||
.Annotation("MySql:CharSet", "utf8mb4");
|
||||
|
||||
migrationBuilder.AddForeignKey(
|
||||
name: "FK_PlacementProfiles_PlacementStatuses_PlacementStatusId",
|
||||
table: "PlacementProfiles",
|
||||
column: "PlacementStatusId",
|
||||
principalTable: "PlacementStatuses",
|
||||
principalColumn: "Id");
|
||||
}
|
||||
}
|
||||
}
|
||||
10213
BMA.EHR.Infrastructure/Migrations/20230629131642_Update table Placement add start status.Designer.cs
generated
Normal file
10213
BMA.EHR.Infrastructure/Migrations/20230629131642_Update table Placement add start status.Designer.cs
generated
Normal file
File diff suppressed because it is too large
Load diff
|
|
@ -0,0 +1,50 @@
|
|||
using Microsoft.EntityFrameworkCore.Migrations;
|
||||
|
||||
#nullable disable
|
||||
|
||||
namespace BMA.EHR.Infrastructure.Migrations
|
||||
{
|
||||
/// <inheritdoc />
|
||||
public partial class UpdatetablePlacementaddstartstatus : Migration
|
||||
{
|
||||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.UpdateData(
|
||||
table: "PlacementProfiles",
|
||||
keyColumn: "PlacementStatus",
|
||||
keyValue: null,
|
||||
column: "PlacementStatus",
|
||||
value: "");
|
||||
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "PlacementStatus",
|
||||
table: "PlacementProfiles",
|
||||
type: "longtext",
|
||||
nullable: false,
|
||||
comment: "สถานะการบรรจุ",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "longtext",
|
||||
oldNullable: true,
|
||||
oldComment: "สถานะการบรรจุ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
protected override void Down(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
migrationBuilder.AlterColumn<string>(
|
||||
name: "PlacementStatus",
|
||||
table: "PlacementProfiles",
|
||||
type: "longtext",
|
||||
nullable: true,
|
||||
comment: "สถานะการบรรจุ",
|
||||
oldClrType: typeof(string),
|
||||
oldType: "longtext",
|
||||
oldComment: "สถานะการบรรจุ")
|
||||
.Annotation("MySql:CharSet", "utf8mb4")
|
||||
.OldAnnotation("MySql:CharSet", "utf8mb4");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -8524,6 +8524,9 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasColumnType("int")
|
||||
.HasComment("จำนวนผู้สอบได้");
|
||||
|
||||
b.Property<Guid>("PlacementTypeId")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<string>("Round")
|
||||
.IsRequired()
|
||||
.HasColumnType("longtext")
|
||||
|
|
@ -8533,11 +8536,6 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasColumnType("datetime(6)")
|
||||
.HasComment("วันที่เริ่มบัญชีบัญชี");
|
||||
|
||||
b.Property<string>("TypeExam")
|
||||
.IsRequired()
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("ประเภทการสอบ");
|
||||
|
||||
b.Property<int>("Year")
|
||||
.HasMaxLength(5)
|
||||
.HasColumnType("int")
|
||||
|
|
@ -8545,6 +8543,8 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.HasIndex("PlacementTypeId");
|
||||
|
||||
b.ToTable("Placements");
|
||||
});
|
||||
|
||||
|
|
@ -8889,6 +8889,9 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasColumnType("longtext")
|
||||
.HasComment("ชื่อ");
|
||||
|
||||
b.Property<Guid?>("GenderId")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<bool?>("IsOfficer")
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("ข้าราชการฯ กทม.");
|
||||
|
|
@ -8897,6 +8900,10 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasColumnType("longtext")
|
||||
.HasComment("การคัดกรองคุณสมบัติ");
|
||||
|
||||
b.Property<bool>("IsRelief")
|
||||
.HasColumnType("tinyint(1)")
|
||||
.HasComment("ผ่อนผัน");
|
||||
|
||||
b.Property<string>("Knowledge")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("ความสามารถพิเศษ");
|
||||
|
|
@ -9028,8 +9035,10 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
b.Property<Guid?>("PlacementId")
|
||||
.HasColumnType("char(36)");
|
||||
|
||||
b.Property<Guid?>("PlacementStatusId")
|
||||
.HasColumnType("char(36)");
|
||||
b.Property<string>("PlacementStatus")
|
||||
.IsRequired()
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("สถานะการบรรจุ");
|
||||
|
||||
b.Property<double?>("PointA")
|
||||
.HasColumnType("double")
|
||||
|
|
@ -9120,6 +9129,10 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasColumnType("longtext")
|
||||
.HasComment("เหตุผลผ่อนผัน");
|
||||
|
||||
b.Property<DateTime?>("ReportingDate")
|
||||
.HasColumnType("datetime(6)")
|
||||
.HasComment("วันที่รายงานตัว");
|
||||
|
||||
b.Property<string>("SalaryClass")
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("ตำแหน่ง (รายละเอียด)");
|
||||
|
|
@ -9147,6 +9160,8 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
|
||||
b.HasIndex("FatherPrefixId");
|
||||
|
||||
b.HasIndex("GenderId");
|
||||
|
||||
b.HasIndex("MarryPrefixId");
|
||||
|
||||
b.HasIndex("MotherPrefixId");
|
||||
|
|
@ -9155,8 +9170,6 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
|
||||
b.HasIndex("PlacementId");
|
||||
|
||||
b.HasIndex("PlacementStatusId");
|
||||
|
||||
b.HasIndex("PositionLevelId");
|
||||
|
||||
b.HasIndex("PositionLineId");
|
||||
|
|
@ -9184,7 +9197,7 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
b.ToTable("PlacementProfiles");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.PlacementStatus", b =>
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.PlacementType", b =>
|
||||
{
|
||||
b.Property<Guid>("Id")
|
||||
.ValueGeneratedOnAdd()
|
||||
|
|
@ -9238,11 +9251,11 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
b.Property<string>("Name")
|
||||
.IsRequired()
|
||||
.HasColumnType("longtext")
|
||||
.HasComment("ชื่อสถานะบรรจุ");
|
||||
.HasComment("ชื่อประเภทบรรจุ");
|
||||
|
||||
b.HasKey("Id");
|
||||
|
||||
b.ToTable("PlacementStatuses");
|
||||
b.ToTable("PlacementTypes");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.HR.LimitTypeLeave", b =>
|
||||
|
|
@ -9833,10 +9846,21 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
b.Navigation("Report2DetailHistory");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.Placement", b =>
|
||||
{
|
||||
b.HasOne("BMA.EHR.Domain.Models.Placement.PlacementType", "PlacementType")
|
||||
.WithMany()
|
||||
.HasForeignKey("PlacementTypeId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
||||
b.Navigation("PlacementType");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.PlacementCareer", b =>
|
||||
{
|
||||
b.HasOne("BMA.EHR.Domain.Models.Placement.PlacementProfile", "PlacementProfile")
|
||||
.WithMany()
|
||||
.WithMany("PlacementCareers")
|
||||
.HasForeignKey("PlacementProfileId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
|
@ -9851,7 +9875,7 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasForeignKey("EducationLevelId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.Placement.PlacementProfile", "PlacementProfile")
|
||||
.WithMany()
|
||||
.WithMany("PlacementEducations")
|
||||
.HasForeignKey("PlacementProfileId")
|
||||
.OnDelete(DeleteBehavior.Cascade)
|
||||
.IsRequired();
|
||||
|
|
@ -9887,6 +9911,10 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.WithMany()
|
||||
.HasForeignKey("FatherPrefixId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.MetaData.Gender", "Gender")
|
||||
.WithMany()
|
||||
.HasForeignKey("GenderId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.MetaData.Prefix", "MarryPrefix")
|
||||
.WithMany()
|
||||
.HasForeignKey("MarryPrefixId");
|
||||
|
|
@ -9900,13 +9928,9 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
.HasForeignKey("OrganizationPositionId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.Placement.Placement", "Placement")
|
||||
.WithMany()
|
||||
.WithMany("PlacementProfiles")
|
||||
.HasForeignKey("PlacementId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.Placement.PlacementStatus", "PlacementStatus")
|
||||
.WithMany()
|
||||
.HasForeignKey("PlacementStatusId");
|
||||
|
||||
b.HasOne("BMA.EHR.Domain.Models.MetaData.PositionLevel", "PositionLevel")
|
||||
.WithMany()
|
||||
.HasForeignKey("PositionLevelId");
|
||||
|
|
@ -9967,6 +9991,8 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
|
||||
b.Navigation("FatherPrefix");
|
||||
|
||||
b.Navigation("Gender");
|
||||
|
||||
b.Navigation("MarryPrefix");
|
||||
|
||||
b.Navigation("MotherPrefix");
|
||||
|
|
@ -9975,8 +10001,6 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
|
||||
b.Navigation("Placement");
|
||||
|
||||
b.Navigation("PlacementStatus");
|
||||
|
||||
b.Navigation("PositionLevel");
|
||||
|
||||
b.Navigation("PositionLine");
|
||||
|
|
@ -10168,6 +10192,18 @@ namespace BMA.EHR.Infrastructure.Migrations
|
|||
{
|
||||
b.Navigation("PositionMasterHistorys");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.Placement", b =>
|
||||
{
|
||||
b.Navigation("PlacementProfiles");
|
||||
});
|
||||
|
||||
modelBuilder.Entity("BMA.EHR.Domain.Models.Placement.PlacementProfile", b =>
|
||||
{
|
||||
b.Navigation("PlacementCareers");
|
||||
|
||||
b.Navigation("PlacementEducations");
|
||||
});
|
||||
#pragma warning restore 612, 618
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue