Merge branch 'develop' into adiDev
This commit is contained in:
commit
d7b095b91f
4 changed files with 66 additions and 9 deletions
|
|
@ -360,10 +360,12 @@ export class DevelopmentScholarshipController extends Controller {
|
||||||
"scholarshipYear",
|
"scholarshipYear",
|
||||||
"scholarshipType",
|
"scholarshipType",
|
||||||
"fundType",
|
"fundType",
|
||||||
|
"bookNumber",
|
||||||
|
"bookDate",
|
||||||
"governmentDate",
|
"governmentDate",
|
||||||
|
"governmentEndDate",
|
||||||
"isGraduated",
|
"isGraduated",
|
||||||
"graduatedDate",
|
"graduatedDate",
|
||||||
"isNoGraduated",
|
|
||||||
"graduatedReason",
|
"graduatedReason",
|
||||||
"root",
|
"root",
|
||||||
],
|
],
|
||||||
|
|
|
||||||
|
|
@ -474,14 +474,37 @@ export class DevelopmentScholarship extends EntityBase {
|
||||||
})
|
})
|
||||||
isNoUseBudget: boolean;
|
isNoUseBudget: boolean;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
comment: "เลขที่หนังสือรายงานตัวกลับเข้าปฏิบัติราชการ",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
bookNumber: string;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: true,
|
nullable: true,
|
||||||
type: "datetime",
|
type: "datetime",
|
||||||
comment: "กลับเข้ารับราชการตั้งแต่",
|
comment: " หนังสือรายงานตัวกลับเข้าปฏิบัติราชการลงวันที่",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
bookDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วันที่กลับเข้าปฏิบัติราชการ",
|
||||||
default: null,
|
default: null,
|
||||||
})
|
})
|
||||||
governmentDate: Date;
|
governmentDate: Date;
|
||||||
|
|
||||||
|
@Column({
|
||||||
|
nullable: true,
|
||||||
|
type: "datetime",
|
||||||
|
comment: "วันสิ้นสุดภาระผูกพัน",
|
||||||
|
default: null,
|
||||||
|
})
|
||||||
|
governmentEndDate: Date;
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
comment: "สำเร็จการศึกษาตามที่หลักสูตรกำหนด",
|
comment: "สำเร็จการศึกษาตามที่หลักสูตรกำหนด",
|
||||||
default: false,
|
default: false,
|
||||||
|
|
@ -496,12 +519,6 @@ export class DevelopmentScholarship extends EntityBase {
|
||||||
})
|
})
|
||||||
graduatedDate: Date;
|
graduatedDate: Date;
|
||||||
|
|
||||||
@Column({
|
|
||||||
comment: "เสร็จสิ้นการศึกษาตามที่หลักสูตรกำหนดแล้วแต่ยังไม่สำเร็จการศึกษา",
|
|
||||||
default: false,
|
|
||||||
})
|
|
||||||
isNoGraduated: boolean;
|
|
||||||
|
|
||||||
@Column({
|
@Column({
|
||||||
nullable: true,
|
nullable: true,
|
||||||
comment: "เนื่องจาก",
|
comment: "เนื่องจาก",
|
||||||
|
|
@ -628,9 +645,11 @@ export class UpdateDevelopmentScholarship {
|
||||||
}
|
}
|
||||||
|
|
||||||
export class UpdateDevelopmentScholarshipUser {
|
export class UpdateDevelopmentScholarshipUser {
|
||||||
|
bookNumber: string | null;
|
||||||
|
bookDate: Date | null;
|
||||||
governmentDate: Date | null;
|
governmentDate: Date | null;
|
||||||
|
governmentEndDate: Date | null;
|
||||||
isGraduated: boolean | null;
|
isGraduated: boolean | null;
|
||||||
graduatedDate: Date | null;
|
graduatedDate: Date | null;
|
||||||
isNoGraduated: boolean | null;
|
|
||||||
graduatedReason: string | null;
|
graduatedReason: string | null;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,22 @@
|
||||||
|
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||||
|
|
||||||
|
export class UpdateTableDevAddGovernmentEndDate1713332483208 implements MigrationInterface {
|
||||||
|
name = 'UpdateTableDevAddGovernmentEndDate1713332483208'
|
||||||
|
|
||||||
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` ADD \`bookNumber\` varchar(255) NULL COMMENT 'เลขที่หนังสือรายงานตัวกลับเข้าปฏิบัติราชการ'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` ADD \`bookDate\` datetime NULL COMMENT ' หนังสือรายงานตัวกลับเข้าปฏิบัติราชการลงวันที่'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` ADD \`governmentEndDate\` datetime NULL COMMENT 'วันสิ้นสุดภาระผูกพัน'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` CHANGE \`governmentDate\` \`governmentDate\` datetime NULL COMMENT 'วันที่กลับเข้าปฏิบัติราชการ'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`strategyChild5\` CHANGE \`strategyChild5Name\` \`strategyChild5Name\` varchar(255) NULL COMMENT 'กลยุทธ์ที่/เป้าประสงค์ที่'`);
|
||||||
|
}
|
||||||
|
|
||||||
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`strategyChild5\` CHANGE \`strategyChild5Name\` \`strategyChild5Name\` varchar(255) NULL COMMENT 'กลยุทธ์ที่'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` CHANGE \`governmentDate\` \`governmentDate\` datetime NULL COMMENT 'กลับเข้ารับราชการตั้งแต่'`);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` DROP COLUMN \`governmentEndDate\``);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` DROP COLUMN \`bookDate\``);
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` DROP COLUMN \`bookNumber\``);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||||
|
|
||||||
|
export class UpdateTableDevAddGovernmentEndDate11713334672151 implements MigrationInterface {
|
||||||
|
name = 'UpdateTableDevAddGovernmentEndDate11713334672151'
|
||||||
|
|
||||||
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` DROP COLUMN \`isNoGraduated\``);
|
||||||
|
}
|
||||||
|
|
||||||
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||||
|
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` ADD \`isNoGraduated\` tinyint NOT NULL COMMENT 'เสร็จสิ้นการศึกษาตามที่หลักสูตรกำหนดแล้วแต่ยังไม่สำเร็จการศึกษา' DEFAULT '0'`);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue