Files
leaudit-platform-backend/fastapi_modules/fastapi_leaudit/controllers/__init__.py
T
wren 535d97a70c chore: initial commit — leaudit-platform project skeleton
17-table PostgreSQL schema with full Chinese column comments,
FastAPI project structure (admin/common/modules),
DSL rule files, and schema migration scripts.
2026-04-27 16:48:22 +08:00

16 lines
410 B
Python

"""控制器包(需要 JWT 鉴权)。"""
from typing import Any
from fastapi import APIRouter, Depends, Request
from fastapi_common.fastapi_common_security.security import verify_access_token
async def jwt_auth_dependency(RequestObj: Request) -> dict[str, Any]:
"""JWT 鉴权依赖。"""
return verify_access_token(RequestObj)
router = APIRouter(dependencies=[Depends(jwt_auth_dependency)])