Umstellung auf nodeclassic

This commit is contained in:
2024-09-04 14:56:24 +02:00
parent c5577969c8
commit d8429f9b4a
47 changed files with 330 additions and 508 deletions

View File

@@ -1,6 +1,6 @@
import { Controller, Get, Param, UseGuards } from '@nestjs/common';
import { AdminAuthGuard } from '../jwt-auth/admin-auth.guard.js';
import { AuthService } from './auth.service.js';
import { Controller, Get, UseGuards } from '@nestjs/common';
import { AdminAuthGuard } from '../jwt-auth/admin-auth.guard';
import { AuthService } from './auth.service';
@Controller('auth')
export class AuthController {
@@ -18,15 +18,15 @@ export class AuthController {
return this.authService.getUsers();
}
@UseGuards(AdminAuthGuard)
@Get('user/:userid')
getUser(@Param('userid') userId: string): any {
return this.authService.getUser(userId);
}
// @UseGuards(AdminAuthGuard)
// @Get('user/:userid')
// getUser(@Param('userid') userId: string): any {
// return this.authService.getUser(userId);
// }
@UseGuards(AdminAuthGuard)
@Get('user/:userid/lastlogin') //e0811669-c7eb-4e5e-a699-e8334d5c5b01 -> aknuth
getLastLogin(@Param('userid') userId: string): any {
return this.authService.getLastLogin(userId);
}
// @UseGuards(AdminAuthGuard)
// @Get('user/:userid/lastlogin') //e0811669-c7eb-4e5e-a699-e8334d5c5b01 -> aknuth
// getLastLogin(@Param('userid') userId: string): any {
// return this.authService.getLastLogin(userId);
// }
}