keep plan selection during keycloak hop
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
import { Controller, Get, UseGuards } from '@nestjs/common';
|
||||
import { Body, Controller, Get, Param, Put, UseGuards } from '@nestjs/common';
|
||||
import { JwtAuthGuard } from 'src/jwt-auth/jwt-auth.guard';
|
||||
import { KeycloakUser } from 'src/models/main.model';
|
||||
import { AdminAuthGuard } from '../jwt-auth/admin-auth.guard';
|
||||
import { AuthService } from './auth.service';
|
||||
|
||||
@@ -18,12 +20,16 @@ export class AuthController {
|
||||
return this.authService.getUsers();
|
||||
}
|
||||
|
||||
// @UseGuards(AdminAuthGuard)
|
||||
// @Get('user/:userid')
|
||||
// getUser(@Param('userid') userId: string): any {
|
||||
// return this.authService.getUser(userId);
|
||||
// }
|
||||
|
||||
@UseGuards(JwtAuthGuard)
|
||||
@Get('users/:userid')
|
||||
getUser(@Param('userid') userId: string): any {
|
||||
return this.authService.getUser(userId);
|
||||
}
|
||||
@UseGuards(JwtAuthGuard)
|
||||
@Put('users/:userid')
|
||||
updateKeycloakUser(@Body() keycloakUser: KeycloakUser): any {
|
||||
return this.authService.updateKeycloakUser(keycloakUser);
|
||||
}
|
||||
// @UseGuards(AdminAuthGuard)
|
||||
// @Get('user/:userid/lastlogin') //e0811669-c7eb-4e5e-a699-e8334d5c5b01 -> aknuth
|
||||
// getLastLogin(@Param('userid') userId: string): any {
|
||||
|
||||
Reference in New Issue
Block a user