From be22e1ded5dd22bd91551eae384356e92a72dd13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pierre-Rapha=C3=ABl=20Wozny?= Date: Thu, 17 Oct 2024 11:04:56 +0200 Subject: [PATCH] fix: renamed businessId to displayName (API nomenclature) --- src/pages/TableTracking.tsx | 4 ++-- src/types/pearl.d.ts | 2 +- src/ui/SurveyCard.tsx | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pages/TableTracking.tsx b/src/pages/TableTracking.tsx index bcfe07d7..c20e825e 100644 --- a/src/pages/TableTracking.tsx +++ b/src/pages/TableTracking.tsx @@ -240,10 +240,10 @@ function SurveyUnitRow({ surveyUnit }: Readonly) { {isActive ? ( - #{surveyUnit.businessId ? surveyUnit.businessId : surveyUnit.id} + #{surveyUnit.displayName ? surveyUnit.displayName : surveyUnit.id} ) : ( - `#${surveyUnit.businessId ? surveyUnit.businessId : surveyUnit.id}` + `#${surveyUnit.displayName ? surveyUnit.displayName : surveyUnit.id}` )} diff --git a/src/types/pearl.d.ts b/src/types/pearl.d.ts index 51e475e2..8b10701e 100644 --- a/src/types/pearl.d.ts +++ b/src/types/pearl.d.ts @@ -95,7 +95,7 @@ declare global { }; type SurveyUnit = { - businessId?: string; + displayName?: string; id: string; persons: SurveyUnitPerson[]; address: SurveyUnitAddress; diff --git a/src/ui/SurveyCard.tsx b/src/ui/SurveyCard.tsx index 62c5da62..94b06b2c 100644 --- a/src/ui/SurveyCard.tsx +++ b/src/ui/SurveyCard.tsx @@ -85,7 +85,7 @@ export function SurveyCard({ surveyUnit, locked = false }: Readonly} - #{surveyUnit.businessId ? surveyUnit.businessId : surveyUnit.id} + #{surveyUnit.displayName ? surveyUnit.displayName : surveyUnit.id}