【m】log完成

This commit is contained in:
2026-05-06 16:08:00 +08:00
parent e47eee39ed
commit a6cda3e9dd
7 changed files with 70 additions and 42 deletions

View File

@@ -6,6 +6,7 @@ import * as swaggerJSDoc from 'swagger-jsdoc';
import * as swaggerUi from 'swagger-ui-express';
import { Express } from 'express';
import Options from './class/options';
import { log, LogLevel } from './log';
/**
* 初始化Swagger
@@ -60,5 +61,5 @@ export const initSwagger = (app: Express, config: Options): void => {
const swaggerSpec = swaggerJSDoc(swaggerOptions);
app.use('/api-docs', swaggerUi.serve, swaggerUi.setup(swaggerSpec));
console.log(`Swagger文档已初始化访问 ${serverUrl}/api-docs 查看`);
log(LogLevel.info, `Swagger文档已初始化访问 ${serverUrl}/api-docs 查看`);
};