Skip to content

Commit

Permalink
Add prefix "Bicycle parking" to names
Browse files Browse the repository at this point in the history
  • Loading branch information
juuso-j committed Jun 26, 2024
1 parent 3812bf4 commit 3bbb23e
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions mobility_data/importers/bicycle_stands.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ class BicyleStand(MobileUnitDataBase):

def __init__(self):
super().__init__()
self.prefix_name = {}
self.related_unit = None
self.extra = {f: None for f in self.EXTRA_FIELDS}

Expand Down Expand Up @@ -110,7 +109,7 @@ def set_geojson_feature(self, feature):
else:
self.name["sv"] = name
self.name["en"] = name
self.prefix_name = {k: f"{NAME_PREFIX[k]} {v}" for k, v in self.name.items()}
self.name = {k: f"{NAME_PREFIX[k]} {v}" for k, v in self.name.items()}
addr = feature["osoite"].as_string().split(",")
# Some addresses are in format:"Pyhän Henrikin aukio, Kupittaankatu 8, 20520 Turku"
# Then remove the prefix part.
Expand Down Expand Up @@ -188,8 +187,8 @@ def set_gml_feature(self, feature):
full_names = get_closest_address_full_name(self.geometry)
self.name[FI_KEY] = full_names[FI_KEY]
self.name[SV_KEY] = full_names[SV_KEY]
self.name[EN_KEY] = full_names[EN_KEY]
self.prefix_name = {k: f"{NAME_PREFIX[k]} {v}" for k, v in self.name.items()}
self.name[EN_KEY] = full_names[FI_KEY]
self.name = {k: f"{NAME_PREFIX[k]} {v}" for k, v in self.name.items()}


def get_data_sources():
Expand Down

0 comments on commit 3bbb23e

Please sign in to comment.