From 406efa6f1403661a0aab66225b7bd7737d750163 Mon Sep 17 00:00:00 2001 From: yuliang_guo Date: Fri, 30 Jan 2026 15:04:01 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=20endpoints=20?= =?UTF-8?q?=E6=A8=A1=E5=9D=97=E5=AF=BC=E5=85=A5=E8=B7=AF=E5=BE=84?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - progress.py: get_db, get_current_user 从 app.core.deps 导入 - speech.py: 同上 - recommendation.py: 同上 --- backend/app/api/v1/endpoints/progress.py | 3 +-- backend/app/api/v1/endpoints/recommendation.py | 3 +-- backend/app/api/v1/endpoints/speech.py | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/backend/app/api/v1/endpoints/progress.py b/backend/app/api/v1/endpoints/progress.py index 2876710..078da43 100644 --- a/backend/app/api/v1/endpoints/progress.py +++ b/backend/app/api/v1/endpoints/progress.py @@ -8,8 +8,7 @@ from sqlalchemy.ext.asyncio import AsyncSession from sqlalchemy import select, func, and_ from pydantic import BaseModel, Field -from app.core.database import get_db -from app.api.deps import get_current_user +from app.core.deps import get_db, get_current_user from app.models.user import User from app.models.course import Course, CourseMaterial from app.models.user_course_progress import ( diff --git a/backend/app/api/v1/endpoints/recommendation.py b/backend/app/api/v1/endpoints/recommendation.py index 096ff92..766ce08 100644 --- a/backend/app/api/v1/endpoints/recommendation.py +++ b/backend/app/api/v1/endpoints/recommendation.py @@ -6,8 +6,7 @@ from fastapi import APIRouter, Depends, Query from sqlalchemy.ext.asyncio import AsyncSession from pydantic import BaseModel -from app.core.database import get_db -from app.api.deps import get_current_user +from app.core.deps import get_db, get_current_user from app.models.user import User from app.services.recommendation_service import RecommendationService diff --git a/backend/app/api/v1/endpoints/speech.py b/backend/app/api/v1/endpoints/speech.py index 9d4cbda..0276e71 100644 --- a/backend/app/api/v1/endpoints/speech.py +++ b/backend/app/api/v1/endpoints/speech.py @@ -5,8 +5,7 @@ from typing import Optional from fastapi import APIRouter, Depends, File, UploadFile, Form, HTTPException from pydantic import BaseModel -from app.core.database import get_db -from app.api.deps import get_current_user +from app.core.deps import get_db, get_current_user from app.models.user import User from app.services.speech_recognition import ( get_speech_recognition_service,