hrms-api-org/src/migration/1718165907865-update_table_role_add_node1.ts
2024-06-12 11:20:46 +07:00

14 lines
668 B
TypeScript

import { MigrationInterface, QueryRunner } from "typeorm";
export class UpdateTableRoleAddNode11718165907865 implements MigrationInterface {
name = 'UpdateTableRoleAddNode11718165907865'
public async up(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`authRoleAttr\` DROP FOREIGN KEY \`FK_b5b59c60792d518f4f025379dba\``);
}
public async down(queryRunner: QueryRunner): Promise<void> {
await queryRunner.query(`ALTER TABLE \`authRoleAttr\` ADD CONSTRAINT \`FK_b5b59c60792d518f4f025379dba\` FOREIGN KEY (\`authSysId\`) REFERENCES \`authSys\`(\`id\`) ON DELETE NO ACTION ON UPDATE NO ACTION`);
}
}