no message
This commit is contained in:
parent
5f5942089a
commit
d9c98f4f25
7 changed files with 169 additions and 56 deletions
16
src/migration/1713347839774-update_table_devhis_add_org.ts
Normal file
16
src/migration/1713347839774-update_table_devhis_add_org.ts
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class UpdateTableDevhisAddOrg1713347839774 implements MigrationInterface {
|
||||
name = 'UpdateTableDevhisAddOrg1713347839774'
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`developmentHistory\` ADD \`org\` varchar(255) NULL COMMENT 'ชื่อหน่วยงานที่สังกัด'`);
|
||||
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` ADD \`org\` varchar(255) NULL COMMENT 'ชื่อหน่วยงานที่สังกัด'`);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`developmentScholarship\` DROP COLUMN \`org\``);
|
||||
await queryRunner.query(`ALTER TABLE \`developmentHistory\` DROP COLUMN \`org\``);
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue