From dc42f4e5d5a9ae8f0ac6fa1bc64bafc9a5c5e33b Mon Sep 17 00:00:00 2001 From: nobohan Date: Thu, 23 Sep 2021 09:41:55 +0200 Subject: [PATCH] #16 dashboard data object --- patches/frontend/src/conf/dashboard.config.ts | 81 ++++++++++++++++--- 1 file changed, 72 insertions(+), 9 deletions(-) diff --git a/patches/frontend/src/conf/dashboard.config.ts b/patches/frontend/src/conf/dashboard.config.ts index d6429c3..1d5b99d 100644 --- a/patches/frontend/src/conf/dashboard.config.ts +++ b/patches/frontend/src/conf/dashboard.config.ts @@ -1,14 +1,77 @@ export const dashboardData = { base: { - area: 34.23, - population: 3456, + name: 'Wasseiges', + area: 24.48, + population: 2996, }, - landuse: { - agricultural: { - area: 1234, + landuse: [ + { + name: 'Terres arables', + area: 1694, }, - forested: { - area: 23, + { + name: 'Prairies', + area: 376, + }, + { + name: 'Bois', + area: 25, + }, + { + name: 'Surfaces bâties', + area: 167 + }, + { + name: 'Autres', + area: 186 } - } -}; \ No newline at end of file + ], + production: [ + { + name: 'Froment', + area: 768.94, + }, + { + name: 'Orge', + area: 61.78, + }, + { + name: 'Betteraves', + area: 313.28, + }, + { + name: 'Pommes de terre', + area: 274.12, + }, + { + name: 'Cultures fourragères (maïs, prairies temporaires, ...)', + area: 108.70, + }, + { + name: 'Vergers', + area: 33.06, + } + ] +}; + +interface landuse { + name: string, + area: number +} + +interface production { + name: string, + area: number +} + + +export type dashboardDataType = { + base: { + name: string, + area: number, + population: number + }, + landuse: landuse[], + production: production[], + // landuse: Record +}