From 4d9db395ebba5febd3d4efe8809db3f27afa99ca Mon Sep 17 00:00:00 2001 From: mattyatea Date: Sat, 4 Nov 2023 01:33:23 +0900 Subject: [PATCH] migrate push --- .../backend/migration/1698907074200-gorillamode.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 packages/backend/migration/1698907074200-gorillamode.js diff --git a/packages/backend/migration/1698907074200-gorillamode.js b/packages/backend/migration/1698907074200-gorillamode.js new file mode 100644 index 0000000000..6d7d747407 --- /dev/null +++ b/packages/backend/migration/1698907074200-gorillamode.js @@ -0,0 +1,13 @@ +export class Gorillamode1698907074200 { + name = 'Gorillamode1698907074200' + + async up(queryRunner) { + await queryRunner.query(`ALTER TABLE "user" ADD "isGorilla" boolean NOT NULL DEFAULT false`); + await queryRunner.query(`COMMENT ON COLUMN "user"."isGorilla" IS 'Whether the User is a gorilla.'`); + } + + async down(queryRunner) { + await queryRunner.query(`COMMENT ON COLUMN "user"."isGorilla" IS 'Whether the User is a gorilla.'`); + await queryRunner.query(`ALTER TABLE "user" DROP COLUMN "isGorilla"`); + } +}