migrate routing command to use the models and store data there
This commit is contained in:
parent
325823e631
commit
80c335ba04
6 changed files with 194 additions and 108 deletions
|
|
@ -118,7 +118,6 @@ def listing_filter_options(func):
|
|||
def cli(ctx, data_dir: str):
|
||||
ctx.ensure_object(dict)
|
||||
ctx.obj["data_dir"] = data_dir
|
||||
pass
|
||||
|
||||
|
||||
@cli.command()
|
||||
|
|
@ -218,12 +217,14 @@ def routing(
|
|||
"Please set it to your API key for the routing service."
|
||||
)
|
||||
|
||||
repository = ListingRepository(engine=engine)
|
||||
asyncio.run(
|
||||
routing_module.calculate_route(
|
||||
listing_paths,
|
||||
repository,
|
||||
destination_address,
|
||||
# destination_address_coordinates,
|
||||
TravelMode[travel_mode],
|
||||
limit=limit,
|
||||
)
|
||||
)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue