This commit is contained in:
aaron 2025-04-09 23:01:40 +08:00
parent b2b7770de2
commit b1bd8c2e82
2 changed files with 6 additions and 0 deletions

View File

@ -4,6 +4,7 @@ from app.api.v1.users import router as users_router
from app.api.v1.auth import router as auth_router from app.api.v1.auth import router as auth_router
from app.api.v1.person_images import router as person_images_router from app.api.v1.person_images import router as person_images_router
from app.api.v1.clothing import router as clothing_router from app.api.v1.clothing import router as clothing_router
from app.api.v1.tryon import router as tryon_router
api_router = APIRouter() api_router = APIRouter()
api_router.include_router(endpoints_router, prefix="") api_router.include_router(endpoints_router, prefix="")
@ -11,3 +12,4 @@ api_router.include_router(users_router, prefix="/users")
api_router.include_router(auth_router, prefix="/auth") api_router.include_router(auth_router, prefix="/auth")
api_router.include_router(person_images_router, prefix="/person-images") api_router.include_router(person_images_router, prefix="/person-images")
api_router.include_router(clothing_router, prefix="/clothing") api_router.include_router(clothing_router, prefix="/clothing")
api_router.include_router(tryon_router, prefix="/tryon")

View File

@ -24,6 +24,10 @@ async def tryon(
db: AsyncSession = Depends(deps.get_db), db: AsyncSession = Depends(deps.get_db),
current_user: User = Depends(get_current_user) current_user: User = Depends(get_current_user)
): ):
"""
试穿请求
"""
# 获取当前用户的默认形象 # 获取当前用户的默认形象
person_image = await person_image_service.get_default_image(db, current_user.id) person_image = await person_image_service.get_default_image(db, current_user.id)
if not person_image: if not person_image: