diff --git a/backend/app/plan/utils.py b/backend/app/plan/utils.py index b82be297..fe7939f3 100644 --- a/backend/app/plan/utils.py +++ b/backend/app/plan/utils.py @@ -194,12 +194,15 @@ def create_recommendation_scoring_data( else: raise ValueError("Invalid glazing type - implement me") + if recommendation["type"] == "solar_pv": + scoring_dict["PHOTO_SUPPLY_ENDING"] = property.solar_pv_percentage + if recommendation["type"] not in [ "mechanical_ventilation", "sealing_open_fireplace", "low_energy_lighting", "internal_wall_insulation", "external_wall_insulation", "cavity_wall_insulation", "loft_insulation", "room_roof_insulation", "flat_roof_insulation", "solid_floor_insulation", "suspended_floor_insulation", "exposed_floor_insulation", - "windows_glazing" + "windows_glazing", "solar_pv" ]: raise NotImplementedError("Implement me") diff --git a/etl/testing_data/solar_research.py b/etl/testing_data/solar_research.py index 8ce8a6ac..e66e992c 100644 --- a/etl/testing_data/solar_research.py +++ b/etl/testing_data/solar_research.py @@ -35,7 +35,7 @@ def app(): data = df[ ["UPRN", "PROPERTY_TYPE", "TENURE", "BUILT_FORM", "ROOF_DESCRIPTION", "PHOTO_SUPPLY", "TOTAL_FLOOR_AREA", - "CONSTRUCTION_AGE_BAND"] + "CONSTRUCTION_AGE_BAND", "SOLAR_WATER_HEATING_FLAG"] ].copy() data["PHOTO_SUPPLY"] = data["PHOTO_SUPPLY"].fillna(0) data = data[data["PHOTO_SUPPLY"] != 0] diff --git a/recommendations/Costs.py b/recommendations/Costs.py index 654dd7a8..8dbb9cc9 100644 --- a/recommendations/Costs.py +++ b/recommendations/Costs.py @@ -840,7 +840,10 @@ class Costs: The data in the dashboard is filtered on domestic building installations and then the data across the various regions is manually collected. There is currently no automated way to get the data from the MCS dashboard - :param wattage: + + Price can also be benchmarked against this checkatrade article: + https://www.checkatrade.com/blog/cost-guides/cost-of-solar-panel-installation/ + :param wattage: Peak wattage of the solar PV system :return: """ diff --git a/recommendations/SolarPvRecommendations.py b/recommendations/SolarPvRecommendations.py index ebe774bf..4dcf6104 100644 --- a/recommendations/SolarPvRecommendations.py +++ b/recommendations/SolarPvRecommendations.py @@ -57,5 +57,6 @@ class SolarPvRecommendations: "new_u_value": None, "sap_points": None, **cost_result, + "photo_supply": self.property.solar_pv_percentage # This is required for simulating the SAP impact } ]