This commit is contained in:
DingZQ
2023-05-11 18:34:23 +08:00
parent 6c446afe88
commit 95078b23ec

View File

@@ -1572,7 +1572,7 @@ async def fastapi_distribute_demand_to_region(network: str, demand: float, regio
# district_metering_area 35
############################################################
@app.post('/calculatedistrictmeteringarea/')
async def fastapi_calculate_district_metering_area(network: str, nodes: list[str], part_count: int = 1, part_type: int) -> list[list[str]]:
async def fastapi_calculate_district_metering_area(network: str, nodes: list[str], part_count: int, part_type: int) -> list[list[str]]:
return calculate_district_metering_area(network, nodes, part_count, part_type)
@@ -1580,7 +1580,7 @@ async def fastapi_calculate_district_metering_area(network: str, nodes: list[str
# service_area 36
############################################################
@app.post('/calculateservicearea/')
async def fastapi_calculate_service_area(network: str, time_index: int = 0) -> dict[str, Any]:
async def fastapi_calculate_service_area(network: str, time_index: int) -> dict[str, Any]:
return calculate_service_area(network, time_index)