-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
16 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { MigrationInterface, QueryRunner } from 'typeorm'; | ||
|
||
export class New1698395142941 implements MigrationInterface { | ||
name = 'New1698395142941'; | ||
|
||
public async up(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query( | ||
`CREATE TABLE "children_pre_register_entity" ("id" uuid NOT NULL DEFAULT uuid_generate_v4(), "createdAt" TIMESTAMP NOT NULL DEFAULT now(), "updatedAt" TIMESTAMP NOT NULL DEFAULT now(), "deletedAt" TIMESTAMP WITH TIME ZONE, "awakeUrl" character varying NOT NULL, "sleptUrl" character varying NOT NULL, "sayName" hstore NOT NULL, "firstName" hstore, "lastName" hstore, "bio" character varying, "birthDate" TIMESTAMP WITH TIME ZONE, "birthPlace" integer, "city" integer, "state" integer, "country" integer, "sex" integer, "education" integer, "housingStatus" integer, "flaskSwId" integer, "address" character varying, "familyCount" integer, "phoneNumber" character varying, "flaskNgoId" integer, "voiceUrl" character varying, "isApproved" boolean DEFAULT false, "locationId" uuid, CONSTRAINT "PK_a06984f3a83b097b1dc2c8bf2a0" PRIMARY KEY ("id"))`, | ||
); | ||
} | ||
public async down(queryRunner: QueryRunner): Promise<void> { | ||
await queryRunner.query( | ||
`ALTER TABLE "children_pre_register_entity" DROP CONSTRAINT "FK_2b2ec4ae41b2b9a3c6a48054d45"`, | ||
); | ||
} | ||
} |