list/gen: generate lists based on pools
This commit is contained in:
parent
de0f472fdc
commit
076de1bc44
7 changed files with 30 additions and 22 deletions
|
@ -5,6 +5,7 @@ from typing import List, Iterable, Dict, Any, Optional
|
|||
|
||||
from pydantic import BaseModel, Field
|
||||
|
||||
from app.models.base import Pool
|
||||
from app.models.bridges import Bridge
|
||||
|
||||
|
||||
|
@ -31,7 +32,7 @@ class Bridgelines(BaseModel):
|
|||
title = "Bridgelines Version 1"
|
||||
|
||||
|
||||
def bridgelines(*, distribution_method: Optional[str] = None) -> Dict[str, Any]:
|
||||
def bridgelines(pool: Pool, *, distribution_method: Optional[str] = None) -> Dict[str, Any]:
|
||||
bridges: Iterable[Bridge] = Bridge.query.filter(
|
||||
Bridge.destroyed.is_(None),
|
||||
Bridge.deprecated.is_(None),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue