Info display tweaks
This commit is contained in:
@@ -3,19 +3,19 @@ from fastapi import APIRouter, Depends
|
||||
from sqlalchemy.orm import Session
|
||||
from app.api.deps import get_db
|
||||
from app.crud.crud_ppr import ppr as crud_ppr
|
||||
from app.schemas.ppr import PPR
|
||||
from app.schemas.ppr import PPRPublic
|
||||
|
||||
router = APIRouter()
|
||||
|
||||
|
||||
@router.get("/arrivals", response_model=List[PPR])
|
||||
@router.get("/arrivals", response_model=List[PPRPublic])
|
||||
async def get_public_arrivals(db: Session = Depends(get_db)):
|
||||
"""Get today's arrivals for public display"""
|
||||
arrivals = crud_ppr.get_arrivals_today(db)
|
||||
return arrivals
|
||||
|
||||
|
||||
@router.get("/departures", response_model=List[PPR])
|
||||
@router.get("/departures", response_model=List[PPRPublic])
|
||||
async def get_public_departures(db: Session = Depends(get_db)):
|
||||
"""Get today's departures for public display"""
|
||||
departures = crud_ppr.get_departures_today(db)
|
||||
|
||||
Reference in New Issue
Block a user