แก้ type unit
This commit is contained in:
parent
3bfd309ae8
commit
be48ab20f5
5 changed files with 42 additions and 7 deletions
|
|
@ -0,0 +1,16 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class UpdateTableKpiUserEvaluationAddEvaluationReqEdit21715229248848 implements MigrationInterface {
|
||||
name = 'UpdateTableKpiUserEvaluationAddEvaluationReqEdit21715229248848'
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`kpiUserSpecial\` DROP COLUMN \`unit\``);
|
||||
await queryRunner.query(`ALTER TABLE \`kpiUserSpecial\` ADD \`unit\` varchar(255) NULL COMMENT 'หน่วยนับ'`);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`kpiUserSpecial\` DROP COLUMN \`unit\``);
|
||||
await queryRunner.query(`ALTER TABLE \`kpiUserSpecial\` ADD \`unit\` int NULL COMMENT 'หน่วยนับ'`);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
|
||||
export class UpdateTableKpiUserEvaluationAddEvaluationReqEdit31715229338637 implements MigrationInterface {
|
||||
name = 'UpdateTableKpiUserEvaluationAddEvaluationReqEdit31715229338637'
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`kpiSpecial\` DROP COLUMN \`unit\``);
|
||||
await queryRunner.query(`ALTER TABLE \`kpiSpecial\` ADD \`unit\` varchar(255) NULL COMMENT 'หน่วยนับ'`);
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.query(`ALTER TABLE \`kpiSpecial\` DROP COLUMN \`unit\``);
|
||||
await queryRunner.query(`ALTER TABLE \`kpiSpecial\` ADD \`unit\` int NULL COMMENT 'หน่วยนับ'`);
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue