This commit is contained in:
DESKTOP-2S5P7D1\Windows 10 2025-02-04 15:34:36 +07:00
parent fdf27655e1
commit b36ca756d4

View file

@ -0,0 +1,16 @@
import { MigrationInterface, QueryRunner } from "typeorm";
export class Updateroleadddna11738657968680 implements MigrationInterface {
name = 'Updateroleadddna11738657968680'
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`salaryOrgEmployee\` ADD \`rootDnaId\` varchar(40) NOT NULL COMMENT 'คีย์นอก(FK)ของตาราง orgRoot Dna'`);
await queryRunner.query(`ALTER TABLE \`salaryOrg\` ADD \`rootDnaId\` varchar(40) NOT NULL COMMENT 'คีย์นอก(FK)ของตาราง orgRoot Dna'`);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`salaryOrg\` DROP COLUMN \`rootDnaId\``);
await queryRunner.query(`ALTER TABLE \`salaryOrgEmployee\` DROP COLUMN \`rootDnaId\``);
}
}