测试logger记录日志
This commit is contained in:
parent
7470dd2bd8
commit
e58f10478b
@ -12,7 +12,7 @@ APP_PORT = 9099
|
||||
# 应用版本
|
||||
APP_VERSION= '1.6.2'
|
||||
# 应用是否开启热重载
|
||||
APP_RELOAD = true
|
||||
APP_RELOAD = false
|
||||
# 应用是否开启IP归属区域查询
|
||||
APP_IP_LOCATION_QUERY = true
|
||||
# 应用是否允许账号同时登录
|
||||
|
||||
@ -8,6 +8,7 @@ from sqlalchemy.ext.asyncio import AsyncSession
|
||||
from module_admin.annotation.log_annotation import Log
|
||||
from config.enums import BusinessType, RedisInitKeyConfig
|
||||
from utils.response_util import ResponseUtil
|
||||
from utils.log_util import logger
|
||||
|
||||
|
||||
testController = APIRouter(prefix='/test')
|
||||
@ -37,6 +38,8 @@ async def hello_post_json(
|
||||
|
||||
user_name = await TestService.get_user_name(query_db, login_info)
|
||||
|
||||
logger.info("测试成功")
|
||||
|
||||
return ResponseUtil.success(model_content=user_name)
|
||||
|
||||
@Log(title='测试post_form_data', business_type=BusinessType.OTHER, log_type='post')
|
||||
|
||||
Loading…
Reference in New Issue
Block a user