From 7a0442cb4700201b03e01e078994712c09c448d8 Mon Sep 17 00:00:00 2001 From: Ramin Date: Thu, 2 May 2024 13:34:29 +0330 Subject: [PATCH] add allocatedFundUSDPreferred and allocatedFundUSD to qfRound --- migration/1714566501335-addTokenAndChainToQFRound.ts | 10 +++++++--- src/entities/qfRound.ts | 8 ++++++++ 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/migration/1714566501335-addTokenAndChainToQFRound.ts b/migration/1714566501335-addTokenAndChainToQFRound.ts index e460662fe..f7cfd1c20 100644 --- a/migration/1714566501335-addTokenAndChainToQFRound.ts +++ b/migration/1714566501335-addTokenAndChainToQFRound.ts @@ -7,15 +7,19 @@ export class AddTokenAndChainToQFRound1714566501335 await queryRunner.query(` ALTER TABLE IF EXISTS "qf_round" ADD COLUMN IF NOT EXISTS "allocatedTokenSymbol" text, - ADD COLUMN IF NOT EXISTS "allocatedTokenChainId" integer; - `); + ADD COLUMN IF NOT EXISTS "allocatedTokenChainId" integer, + ADD COLUMN IF NOT EXISTS "allocatedFundUSDPreferred" boolean, + ADD COLUMN IF NOT EXISTS "allocatedFundUSD" integer; +`); } public async down(queryRunner: QueryRunner): Promise { await queryRunner.query(` ALTER TABLE IF EXISTS "qf_round" DROP COLUMN "allocatedTokenSymbol", - DROP COLUMN "allocatedTokenChainId"; + DROP COLUMN "allocatedTokenChainId", + DROP COLUMN "allocatedFundUSDPreferred", + DROP COLUMN "allocatedFundUSD"; `); } } diff --git a/src/entities/qfRound.ts b/src/entities/qfRound.ts index 2cff59559..b62d7ccb7 100644 --- a/src/entities/qfRound.ts +++ b/src/entities/qfRound.ts @@ -45,6 +45,14 @@ export class QfRound extends BaseEntity { @Column() allocatedFund: number; + @Field(_type => Number, { nullable: true }) + @Column({ nullable: true }) + allocatedFundUSD: number; + + @Field(_type => Boolean, { nullable: true }) + @Column({ nullable: true }) + allocatedFundUSDPreferred: boolean; + @Field(_type => String, { nullable: true }) @Column({ nullable: true }) allocatedTokenSymbol: string;