fix permissions and teacher attendance workflows

This commit is contained in:
2026-07-10 20:40:52 +08:00
parent 247879f276
commit 8ed1682b90
95 changed files with 4745 additions and 1237 deletions

View File

@@ -1,11 +1,11 @@
import { Controller, Post, Body, Get, Request, Req, UseGuards } from '@nestjs/common';
import { Controller, Post, Body, Get, Request, Req } from '@nestjs/common';
import { AuthService } from './auth.service';
import { LoginDto } from './dto/auth.dto';
import { JwtAuthGuard } from './guards/jwt-auth.guard';
import { OperationLogsService } from '../operation-logs/operation-logs.service';
import { extractRequestInfo } from '../common/request-utils';
import { Throttle } from '@nestjs/throttler';
import { Public } from './decorators/public.decorator';
import { Authenticated } from './decorators/authenticated.decorator';
@Controller('auth')
export class AuthController {
@@ -45,8 +45,7 @@ export class AuthController {
}
}
@Public()
@UseGuards(JwtAuthGuard)
@Authenticated()
@Get('profile')
getProfile(@Request() req: any) {
return req.user;