From d672eee762f597ffdd134f6f9e7df6260a8ba999 Mon Sep 17 00:00:00 2001 From: Pilar Date: Thu, 16 Mar 2023 12:24:09 -0400 Subject: [PATCH] changed percentage to per one (-) --- hub/catalog_factories/cost/montreal_custom_catalog.py | 6 +++--- hub/catalog_factories/data_models/cost/capital_cost.py | 4 ++-- hub/catalog_factories/data_models/cost/income.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/hub/catalog_factories/cost/montreal_custom_catalog.py b/hub/catalog_factories/cost/montreal_custom_catalog.py index a5a921ab..4624e13b 100644 --- a/hub/catalog_factories/cost/montreal_custom_catalog.py +++ b/hub/catalog_factories/cost/montreal_custom_catalog.py @@ -81,8 +81,8 @@ class MontrealCustomCatalog(Catalog): items_list.append(item_description) general_chapters.append(Chapter('D_services', items_list)) - design_allowance = float(entry['Z_allowances_overhead_profit']['Z10_design_allowance']['#text']) - overhead_and_profit = float(entry['Z_allowances_overhead_profit']['Z10_overhead_and_profit']['#text']) + design_allowance = float(entry['Z_allowances_overhead_profit']['Z10_design_allowance']['#text']) / 100 + overhead_and_profit = float(entry['Z_allowances_overhead_profit']['Z10_overhead_and_profit']['#text']) / 100 _capital_cost = CapitalCost(general_chapters, design_allowance, overhead_and_profit) return _capital_cost @@ -135,7 +135,7 @@ class MontrealCustomCatalog(Catalog): hvac = float(archetype['incomes']['subsidies']['hvac_subsidy']['#text']) photovoltaic_system = float(archetype['incomes']['subsidies']['photovoltaic_subsidy']['#text']) electricity_exports = float(archetype['incomes']['energy_exports']['electricity']['#text']) / 1000 / 3600 - reduction_tax = float(archetype['incomes']['tax_reduction']['#text']) + reduction_tax = float(archetype['incomes']['tax_reduction']['#text']) / 100 income = Income(construction_subsidy=construction, hvac_subsidy=hvac, photovoltaic_subsidy=photovoltaic_system, diff --git a/hub/catalog_factories/data_models/cost/capital_cost.py b/hub/catalog_factories/data_models/cost/capital_cost.py index 233043ac..828b5cfc 100644 --- a/hub/catalog_factories/data_models/cost/capital_cost.py +++ b/hub/catalog_factories/data_models/cost/capital_cost.py @@ -26,7 +26,7 @@ class CapitalCost: @property def design_allowance(self): """ - Get design allowance in percentage + Get design allowance in percentage (-) :return: float """ return self._design_allowance @@ -34,7 +34,7 @@ class CapitalCost: @property def overhead_and_profit(self): """ - Get overhead profit in percentage + Get overhead profit in percentage (-) :return: float """ return self._overhead_and_profit diff --git a/hub/catalog_factories/data_models/cost/income.py b/hub/catalog_factories/data_models/cost/income.py index abd74f77..baa880ec 100644 --- a/hub/catalog_factories/data_models/cost/income.py +++ b/hub/catalog_factories/data_models/cost/income.py @@ -56,7 +56,7 @@ class Income: @property def reductions_taxes(self) -> Union[None, float]: """ - Get reduction in taxes in percentage + Get reduction in taxes in percentage (-) :return: None or float """ return self._reductions_taxes