diff --git a/src/app/portfolio/[slug]/building-passport/[propertyId]/pre-assessment-report/page.tsx b/src/app/portfolio/[slug]/building-passport/[propertyId]/pre-assessment-report/page.tsx index e930468f..607881f5 100644 --- a/src/app/portfolio/[slug]/building-passport/[propertyId]/pre-assessment-report/page.tsx +++ b/src/app/portfolio/[slug]/building-passport/[propertyId]/pre-assessment-report/page.tsx @@ -12,6 +12,7 @@ import { } from "@/app/components/building-passport/FeatureTableColumns"; import { formatGeneralFeatures, + formatHeatDemandFeatures, formatRetrofitFeatures, getConditionReport, getPropertyMeta, @@ -121,149 +122,6 @@ export default async function PreAssessmentReport({ const propertyDetailsSpatial = { inConservationArea: "No", }; - console.log("DATA!!"); - console.log(conditionReportData); - - // const conditionReportData: ConditionReportData = { - // id: 1, - // lastUpdated: "2023-07-12 11:51:31.000 +0100", - // fullAddress: "123 Fake Street, Fake Town", - // postcode: "AB1 2CD", - // currentEpcRating: "C", - // inConservationArea: "Yes", - // propertyType: "House", - // builtForm: "Detached", - // totalFloorArea: 60, - // tenure: "Rented (social)", - // yearBuilt: "1990", - // retrofitFeatures: [ - // { feature: "Wall", description: "Cavity wall", rating: "Poor" }, - // { - // feature: "Roof", - // description: "Flat, limited insulation (assumed)", - // rating: "Very poor", - // }, - // { feature: "Windows", description: "Double glazing", rating: "Good" }, - // { feature: "Heating", description: "Gas boiler", rating: "Good" }, - // { - // feature: "Heating Control", - // description: "Programmer and appliance thermostats", - // rating: "Good", - // }, - // { - // feature: "Hot Water", - // description: "Electric immersion, standard tariff", - // rating: "Good", - // }, - // { - // feature: "Lighting", - // description: "Low energy lighting in all fixed outlets", - // rating: "Very good", - // }, - // { - // feature: "Floor", - // description: "Suspended timber", - // rating: "Poor", - // }, - // { - // feature: "Ventilation", - // description: "Natural", - // rating: "N/A", - // }, - // { - // feature: "Solar Photo Voltaic", - // description: "Not present in the property", - // rating: "N/A", - // }, - // { - // feature: "Solar Hot Water", - // description: "Heating is not solar powered", - // rating: "N/A", - // }, - // { - // feature: "Wind Turbines", - // description: "No wind turbines present", - // rating: "N/A", - // }, - // ], - // generalFeatures: [ - // { - // feature: "Floor Height", - // description: 2.4, - // }, - // { - // feature: "Number of heated rooms", - // description: 5, - // }, - // { - // feature: "Heat loss corridor", - // description: "No", - // }, - // { - // feature: "Heat loss corridor length", - // description: 0, - // }, - // { - // feature: "Number of open fire places", - // description: 0, - // }, - // { - // feature: "Number of extensions", - // description: 0, - // }, - // { - // feature: "Floor level", - // description: "Ground", - // }, - // { - // feature: "Number of storeys", - // description: 2, - // }, - // { - // feature: "Mains gas available", - // description: "Yes", - // }, - // { - // feature: "Energy tariff", - // description: "Standard", - // }, - // ], - // heatingDemand: [ - // { - // feature: "EPC primary energy consumption", - // description: "98 kWh/m2/year", - // }, - // { - // feature: "EPC CO2 emissions", - // description: "2.8 tonnes/year", - // }, - // { - // feature: "Elecrticity Supplier", - // description: "E.ON Energy", - // }, - // { - // feature: "Gas Supplier", - // description: "British Gas", - // }, - // { - // feature: "Meter reading total energy consumption", - // description: "108 kWh/m2/year", - // }, - // { - // feature: "Meter reading electicity consumption", - // description: "22 kWh/m2/year", - // }, - // { - // feature: "Meter reading gas consumption", - // description: "86 kWh/m2/year", - // }, - // ], - // }; - - // const retrofitFeatures = conditionReportData.retrofitFeatures; - // const generalFeatures = conditionReportData.generalFeatures; - // const heatingDemand = conditionReportData.heatingDemand; - const generalFeatures = formatGeneralFeatures( conditionReportData, propertyMeta.propertyType @@ -271,6 +129,8 @@ export default async function PreAssessmentReport({ const retrofitFeatures = formatRetrofitFeatures(conditionReportData); + const heatingDemand = formatHeatDemandFeatures(conditionReportData); + return (