import { MigrationInterface, QueryRunner } from "typeorm"; export class Migrations1691602467422 implements MigrationInterface { name = 'Migrations1691602467422' public async up(queryRunner: QueryRunner): Promise { await queryRunner.query(`CREATE TABLE "companies" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "name" character varying NOT NULL, "deleted_at" TIMESTAMP, "created_at" TIMESTAMP NOT NULL DEFAULT now(), "updated_at" TIMESTAMP NOT NULL DEFAULT now(), CONSTRAINT "UQ_3dacbb3eb4f095e29372ff8e131" UNIQUE ("name"), CONSTRAINT "PK_d4bc3e82a314fa9e29f652c2c22" PRIMARY KEY ("id"))`); } public async down(queryRunner: QueryRunner): Promise { await queryRunner.query(`DROP TABLE "companies"`); } }