From 0304d472220869a8e764c3d6b6c2dbbf77d2ae4e Mon Sep 17 00:00:00 2001 From: Conrad Date: Thu, 1 Mar 2018 15:00:07 -0500 Subject: [PATCH 1/2] Update return values of stored proc --- app/models/building.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/models/building.py b/app/models/building.py index b9d3a73..d95071a 100644 --- a/app/models/building.py +++ b/app/models/building.py @@ -19,9 +19,10 @@ class Building(BaseModel): ProcColumn('building_id'), ProcColumn('lot_id'), ProcColumn('bin'), + ProcColumn('targeting_score'), ) - def __init__(self, street_address, bbl, borough, zipcode, building_id, lot_id, bin): + def __init__(self, street_address, bbl, borough, zipcode, building_id, lot_id, bin, targeting_score): self.street_address = street_address self.bbl = bbl self.borough = borough @@ -29,6 +30,7 @@ class Building(BaseModel): self.building_id = building_id self.lot_id = lot_id self.bin = bin + self.targeting_score = targeting_score def __str__(self): return "Building: {} located at {}".format(self.building_id, self.street_address) -- GitLab From 90d4b8476f0e752ebca6a0b5673830f9605674aa Mon Sep 17 00:00:00 2001 From: Conrad Date: Thu, 8 Mar 2018 10:15:22 -0500 Subject: [PATCH 2/2] Add targeting score to building form --- app/forms/building.py | 1 + 1 file changed, 1 insertion(+) diff --git a/app/forms/building.py b/app/forms/building.py index 0966af0..de2699a 100644 --- a/app/forms/building.py +++ b/app/forms/building.py @@ -12,3 +12,4 @@ class BuildingForm: zip = wtf.StringField(validators=[validators.zip_]) building_id = wtf.IntegerField() lot_id = wtf.IntegerField() + targeting_score = wtf.FloatField() -- GitLab