mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
include install_date on AssetCondition 🟥
This commit is contained in:
parent
dfe0460155
commit
7bd70ae001
2 changed files with 17 additions and 9 deletions
|
|
@ -1,5 +1,6 @@
|
|||
from dataclasses import dataclass
|
||||
from typing import Optional
|
||||
from datetime import date
|
||||
|
||||
from backend.condition.domain.element import Element
|
||||
|
||||
|
|
@ -7,8 +8,8 @@ from backend.condition.domain.element import Element
|
|||
class AssetCondition:
|
||||
uprn: int
|
||||
element: Element # TODO: should HHSRS elements be handled differently?
|
||||
condition_description: str # TODO: this probably needs to be some sort of enum so it's searchable/filterable on the frontend
|
||||
condition_description: str # TODO: this probably needs to be some sort of enum so it's searchable/filterable on the frontend. Could be hard to map from string though
|
||||
quantity: int
|
||||
renewal_year: Optional[int] = None
|
||||
source: Optional[str] = None
|
||||
# TODO: add install_date
|
||||
install_date: Optional[date] = None
|
||||
|
|
|
|||
|
|
@ -179,7 +179,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="General Needs",
|
||||
quantity=1,
|
||||
renewal_year=None,
|
||||
source=None
|
||||
source=None,
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -187,7 +188,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="Ground Floor",
|
||||
quantity=1,
|
||||
renewal_year=None,
|
||||
source=None
|
||||
source=None,
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -195,7 +197,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="Yes",
|
||||
quantity=None,
|
||||
renewal_year=None,
|
||||
source="Source of Data = ACT"
|
||||
source="Source of Data = ACT",
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -203,7 +206,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="Bathroom on Entrance Level in Property",
|
||||
quantity=1,
|
||||
renewal_year=None,
|
||||
source="Source of Data = Codeman"
|
||||
source="Source of Data = Codeman",
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -211,7 +215,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="No Central Heating in Property",
|
||||
quantity=1,
|
||||
renewal_year=None,
|
||||
source="Source of Data = Codeman"
|
||||
source="Source of Data = Codeman",
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -219,7 +224,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="Category 4 - Typical Risk",
|
||||
quantity=1,
|
||||
renewal_year=None,
|
||||
source="Source of Data = Morgan Sindall"
|
||||
source="Source of Data = Morgan Sindall",
|
||||
install_date=None,
|
||||
),
|
||||
AssetCondition(
|
||||
uprn=1,
|
||||
|
|
@ -227,7 +233,8 @@ def test_lbwf_mapper_maps_house():
|
|||
condition_description="Render or Pebbledash Wall Finish 1 in External Area",
|
||||
quantity=1,
|
||||
renewal_year=2052,
|
||||
source="Source of Data = Codeman"
|
||||
source="Source of Data = Codeman",
|
||||
install_date=date(2009,4,1),
|
||||
),
|
||||
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue