18 lines
655 B
TypeScript
18 lines
655 B
TypeScript
import { MigrationInterface, QueryRunner } from 'typeorm';
|
|
|
|
export class AddFormulaToTax1726365023179 implements MigrationInterface {
|
|
name = 'AddFormulaToTax1726365023179';
|
|
|
|
public async up(queryRunner: QueryRunner): Promise<void> {
|
|
await queryRunner.query(`ALTER TABLE "taxes" ADD "formula_render" json`);
|
|
await queryRunner.query(
|
|
`ALTER TABLE "taxes" ADD "formula_string" character varying`,
|
|
);
|
|
}
|
|
|
|
public async down(queryRunner: QueryRunner): Promise<void> {
|
|
await queryRunner.query(`ALTER TABLE "taxes" DROP COLUMN "formula_string"`);
|
|
await queryRunner.query(`ALTER TABLE "taxes" DROP COLUMN "formula_render"`);
|
|
}
|
|
}
|