comment
This commit is contained in:
parent
59d31704bd
commit
3827986593
@ -10,5 +10,9 @@ pip install -r requirements.txt
|
|||||||
python -m uvicorn app:app --reload
|
python -m uvicorn app:app --reload
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Note: First time touching FastAPI in this manner, so organization
|
||||||
|
is not great. Any questions of "WTF?? Why did you do it this way?" - because it ended up that way,
|
||||||
|
I have not worked on a project of this scope so moving _LEGO_ bits around just worked.
|
||||||
|
|
||||||
|
|
||||||
Paired with https://gitea.tyrel.dev/tyrel/go-webservice-gin
|
Paired with https://gitea.tyrel.dev/tyrel/go-webservice-gin
|
@ -44,7 +44,7 @@ def get_album(album_id: int, session: Session = Depends(get_db)):
|
|||||||
raise HTTPException(**ex.__dict__)
|
raise HTTPException(**ex.__dict__)
|
||||||
|
|
||||||
|
|
||||||
# API to update a existing album info
|
# API to update an existing album info
|
||||||
@router.put("/albums/{album_id}", response_model=models.schemas.Album)
|
@router.put("/albums/{album_id}", response_model=models.schemas.Album)
|
||||||
def update_album(album_id: int, new_info: models.schemas.AlbumBase, session: Session = Depends(get_db)):
|
def update_album(album_id: int, new_info: models.schemas.AlbumBase, session: Session = Depends(get_db)):
|
||||||
try:
|
try:
|
||||||
|
Loading…
Reference in New Issue
Block a user