import { MigrationInterface, QueryRunner } from "typeorm";

export class Migrations1744176742031 implements MigrationInterface {
    name = 'Migrations1744176742031'

    public async up(queryRunner: QueryRunner): Promise<void> {
        await queryRunner.query(`CREATE TABLE "guest_user_profile_access" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "ip" character varying(45) NOT NULL, "remaining_count" integer NOT NULL DEFAULT '0', "expire_at" TIMESTAMP NOT NULL, "createdAt" TIMESTAMP NOT NULL DEFAULT now(), CONSTRAINT "PK_07b50294fd0f839f63e0665de49" PRIMARY KEY ("id"))`);
    }

    public async down(queryRunner: QueryRunner): Promise<void> {
        await queryRunner.query(`DROP TABLE "guest_user_profile_access"`);
    }

}
