diff --git a/src/entities/kpiUserDevelopment.ts b/src/entities/kpiUserDevelopment.ts index 2c6f97c..b336908 100644 --- a/src/entities/kpiUserDevelopment.ts +++ b/src/entities/kpiUserDevelopment.ts @@ -27,6 +27,13 @@ export class KpiUserDevelopment extends EntityBase { }) summary: number; + @Column({ + nullable: true, + comment: "ระดับคะแนน", + default: null, + }) + point: number; + @Column({ nullable: true, comment: "เกณฑ์การประเมิน 10", @@ -91,8 +98,6 @@ export class CreateKpiUserDevelopment { @Column() target: string | null; @Column() - summary?: number | null; - @Column() achievement10?: string | null; @Column() achievement5?: string | null; @@ -114,8 +119,6 @@ export class UpdateKpiUserDevelopment { @Column() target: string | null; @Column() - summary?: number | null; - @Column() achievement10?: string | null; @Column() achievement5?: string | null; diff --git a/src/migration/1715245130866-update_table_kpiSpecial_unit_to_string1.ts b/src/migration/1715245130866-update_table_kpiSpecial_unit_to_string1.ts new file mode 100644 index 0000000..9821248 --- /dev/null +++ b/src/migration/1715245130866-update_table_kpiSpecial_unit_to_string1.ts @@ -0,0 +1,14 @@ +import { MigrationInterface, QueryRunner } from "typeorm"; + +export class UpdateTableKpiSpecialUnitToString11715245130866 implements MigrationInterface { + name = 'UpdateTableKpiSpecialUnitToString11715245130866' + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE \`kpiUserDevelopment\` ADD \`point\` int NULL COMMENT 'ระดับคะแนน'`); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query(`ALTER TABLE \`kpiUserDevelopment\` DROP COLUMN \`point\``); + } + +}