16 lines
353 B
Python
16 lines
353 B
Python
from fastapi import APIRouter, Depends, HTTPException
|
|
from app.database import session
|
|
from app.models.delivery import Delivery
|
|
|
|
|
|
router = APIRouter(
|
|
prefix="/command",
|
|
tags=["command"],
|
|
responses={404: {"description": "Not found"}},
|
|
)
|
|
|
|
|
|
@router.get("/")
|
|
async def read_items():
|
|
x = session.query(Delivery).first()
|
|
return {"x": x.id} |