แก้ไขวันที่เกษียณ
This commit is contained in:
parent
87550b158b
commit
613dd34ad7
3 changed files with 52 additions and 3 deletions
|
|
@ -0,0 +1,16 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class UpdateTableProfileAddDateLeave1717671751714 implements MigrationInterface {
|
||||
name = 'UpdateTableProfileAddDateLeave1717671751714'
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`profile\` ADD \`dateLeave\` datetime NULL COMMENT 'วันพ้นราชการ'`);
|
||||
await queryRunner.query(`ALTER TABLE \`profileHistory\` ADD \`dateLeave\` datetime NULL COMMENT 'วันพ้นราชการ'`);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`profileHistory\` DROP COLUMN \`dateLeave\``);
|
||||
await queryRunner.query(`ALTER TABLE \`profile\` DROP COLUMN \`dateLeave\``);
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue