no message

This commit is contained in:
Kittapath 2024-02-28 14:46:17 +07:00
parent 6ed7265094
commit 8339e6ce6d
4 changed files with 32 additions and 25 deletions

View file

@ -0,0 +1,16 @@
import { MigrationInterface, QueryRunner } from "typeorm";
export class UpdateTableSalaryProfileAddRevision31709105846886 implements MigrationInterface {
name = 'UpdateTableSalaryProfileAddRevision31709105846886'
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`salaryOrg\` CHANGE \`total\` \`total\` int NOT NULL COMMENT 'จำนวนคนทั้งหมด' DEFAULT '0'`);
await queryRunner.query(`ALTER TABLE \`salaryOrg\` CHANGE \`fifteenPercent\` \`fifteenPercent\` int NOT NULL COMMENT '15%ของจำนวนคน(จำนวนเต็ม)' DEFAULT '0'`);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`salaryOrg\` CHANGE \`fifteenPercent\` \`fifteenPercent\` int NOT NULL COMMENT '15%ของจำนวนคน(จำนวนเต็ม)'`);
await queryRunner.query(`ALTER TABLE \`salaryOrg\` CHANGE \`total\` \`total\` int NOT NULL COMMENT 'จำนวนคนทั้งหมด'`);
}
}