From b21fea3f54dc89a30a9fe2aea0f9247d0184c051 Mon Sep 17 00:00:00 2001 From: Kristofer Date: Mon, 16 Oct 2023 16:15:09 +0200 Subject: [PATCH] Add quantifier information to attestations --- packages/frontend/src/model/eas/eas.constants.ts | 4 ++-- packages/frontend/src/model/eas/types/attestation.type.ts | 1 + .../PeriodDetails/components/CreateAttestationsDialog.tsx | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/packages/frontend/src/model/eas/eas.constants.ts b/packages/frontend/src/model/eas/eas.constants.ts index 23ac313da..e3d291e76 100644 --- a/packages/frontend/src/model/eas/eas.constants.ts +++ b/packages/frontend/src/model/eas/eas.constants.ts @@ -1,10 +1,10 @@ export const EAS_ADDRESS = '0x4200000000000000000000000000000000000021'; export const ATTESTATION_SCHEMA_UID = - '0x1c622d3fdb24759ed71266b218c4750ad54549a7612451851f3b0432ce167e68'; + '0x5f2b0ffc7e874c2624e38aea44a5e68bebe69dbd7e181cdbb8ab657d05b74301'; export const ATTESTATION_SCHEMA = - 'string period,string username,uint16 received_score,uint16 given_score,bool top_10_receiver,bool top_50_receiver,bool top_100_receiver,bool top_10_giver,bool top_50_giver,bool top_100_giver'; + 'string period,string username,bool quantifier,uint16 received_score,uint16 given_score,bool top_10_receiver,bool top_50_receiver,bool top_100_receiver,bool top_10_giver,bool top_50_giver,bool top_100_giver'; export const ATTESTATION_REPORT_MANIFEST_URL = 'https://raw.githubusercontent.com/givepraise/reports/main/reports/attestations/manifest.json'; diff --git a/packages/frontend/src/model/eas/types/attestation.type.ts b/packages/frontend/src/model/eas/types/attestation.type.ts index d34644f2a..d68ad073d 100644 --- a/packages/frontend/src/model/eas/types/attestation.type.ts +++ b/packages/frontend/src/model/eas/types/attestation.type.ts @@ -1,6 +1,7 @@ export type Attestation = { username: string; period: string; + quantifier: string; received_score: string; given_score: string; top_10_receiver: string; diff --git a/packages/frontend/src/pages/PeriodDetails/components/CreateAttestationsDialog.tsx b/packages/frontend/src/pages/PeriodDetails/components/CreateAttestationsDialog.tsx index 12eb61933..c50d4696e 100644 --- a/packages/frontend/src/pages/PeriodDetails/components/CreateAttestationsDialog.tsx +++ b/packages/frontend/src/pages/PeriodDetails/components/CreateAttestationsDialog.tsx @@ -58,6 +58,7 @@ export function CreateAttestationsDialog({ csvObjects.push({ period: periodId, username: attestation.users_username, + quantifier: attestation.quantifier.toString(), received_score: attestation.total_received_praise_score.toString(), given_score: attestation.total_given_praise_score.toString(), top_10_receiver: attestation.top_10_receiver.toString(),