chore: commit oxfmt formatting changes and verify artifacts

This commit is contained in:
2026-07-02 15:55:09 +08:00
parent 34726cc46d
commit 4f4cee157a
77 changed files with 5576 additions and 1400 deletions

View File

@@ -9,7 +9,10 @@ import { Public } from './decorators/public.decorator';
@Controller('auth')
export class AuthController {
constructor(private authService: AuthService, private logService: OperationLogsService) {}
constructor(
private authService: AuthService,
private logService: OperationLogsService,
) {}
@Public()
@Post('login')
@@ -19,17 +22,24 @@ export class AuthController {
try {
const result = await this.authService.login(dto, ipAddress);
await this.logService.log({
userId: result.user.id, username: result.user.username,
module: '认证', action: '登录成功',
ipAddress, userAgent, status: 'success',
userId: result.user.id,
username: result.user.username,
module: '认证',
action: '登录成功',
ipAddress,
userAgent,
status: 'success',
});
return result;
} catch (e: any) {
await this.logService.log({
username: dto.username,
module: '认证', action: '登录失败',
module: '认证',
action: '登录失败',
detail: e.message || '密码错误',
ipAddress, userAgent, status: 'fail',
ipAddress,
userAgent,
status: 'fail',
});
throw e;
}