Remove obsolete endpoints (#89)
Remove endpoints api/login/token and api/login/profile --------- Co-authored-by: Thomas Peetz <thomas.peetz@cimt-ag.de> Reviewed-on: #89
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
from typing import List
|
||||
|
||||
from fastapi import APIRouter
|
||||
|
||||
from src.db.models.comic import Volume
|
||||
from src.db.session import SessionDep
|
||||
from src.schema.comics.volume import VolumeResponse, to_response
|
||||
|
||||
router = APIRouter()
|
||||
|
||||
@router.get("/volumes", response_model=List[VolumeResponse])
|
||||
def get_issues(db: SessionDep) -> List[VolumeResponse]:
|
||||
results: List[VolumeResponse] = []
|
||||
worktypes = db.query(Volume).all()
|
||||
for worktype in worktypes:
|
||||
response = to_response(worktype)
|
||||
results.append(response)
|
||||
return results
|
||||
Reference in New Issue
Block a user