import { MigrationInterface, QueryRunner } from "typeorm"

export class AddPricingPlansTable1755499223807 implements MigrationInterface {
  name = "AddPricingPlansTable1755499223807"

  public async up(queryRunner: QueryRunner): Promise<void> {
    await queryRunner.query(
      `CREATE TABLE "pricing_plans" ("id" SERIAL NOT NULL, "name" character varying NOT NULL, "description" character varying, "is_default" boolean NOT NULL DEFAULT false, "created_at" TIMESTAMP NOT NULL DEFAULT NOW(), "updated_at" TIMESTAMP NOT NULL DEFAULT NOW(), "deleted_at" TIMESTAMP, CONSTRAINT "PK_57aa9837d4777aafc70ba090fb6" PRIMARY KEY ("id"))`,
    )
  }

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