From 1ff07cc9680fafc1097fd2a57984474a2bd5718c Mon Sep 17 00:00:00 2001 From: Ramin Date: Fri, 16 Aug 2024 16:17:46 +0330 Subject: [PATCH] hotfix migration --- ...ns2_.ts => 1723799657528-addGivArbMissingDonations2_.ts} | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) rename migration/{1723799657527-addGivArbMissingDonations2_.ts => 1723799657528-addGivArbMissingDonations2_.ts} (96%) diff --git a/migration/1723799657527-addGivArbMissingDonations2_.ts b/migration/1723799657528-addGivArbMissingDonations2_.ts similarity index 96% rename from migration/1723799657527-addGivArbMissingDonations2_.ts rename to migration/1723799657528-addGivArbMissingDonations2_.ts index 70c37f0f4..79a8b453b 100644 --- a/migration/1723799657527-addGivArbMissingDonations2_.ts +++ b/migration/1723799657528-addGivArbMissingDonations2_.ts @@ -53,7 +53,7 @@ const transactions: Partial[] = [ }, ]; -export class AddGivArbMissingDonations2_1723799657527 +export class AddGivArbMissingDonations2_1723799657528 implements MigrationInterface { async up(queryRunner: QueryRunner): Promise { @@ -99,13 +99,13 @@ export class AddGivArbMissingDonations2_1723799657527 await calculateGivbackFactor(tx.projectId as number); await queryRunner.query(` INSERT INTO donation ("toWalletAddress", "projectId", "fromWalletAddress", "userId", amount, currency, "transactionId", "transactionNetworkId", anonymous, "valueUsd", status, - "segmentNotified", "isTokenEligibleForGivback", "isProjectVerified", "createdAt", "givbackFactor", "powerRound", "projectRank", "bottomRankInRound", "qfRoundId", "tokenAddress", "qfRoundId") + "segmentNotified", "isTokenEligibleForGivback", "isProjectVerified", "createdAt", "givbackFactor", "powerRound", "projectRank", "bottomRankInRound", "qfRoundId", "tokenAddress") VALUES ('${tx.toWalletAddress?.toLowerCase()}', ${tx.projectId}, '${tx.fromWalletAddress?.toLowerCase()}', ${user.id}, ${tx.amount}, '${tx.currency}', '${tx.transactionId?.toLowerCase()}', ${ tx.transactionNetworkId }, false, ${tx.valueUsd}, 'verified', true, ${isTokenEligibleForGivback}, ${project.verified}, '${createdAt}', ${givbackFactor}, ${powerRound}, ${projectRank}, ${bottomRankInRound}, ${tx.qfRoundId || null}, '${ tx.tokenAddress - }', ${tx.qfRoundId || null}) + }') ON CONFLICT DO NOTHING; `);