feat: jwt authentication

This commit is contained in:
Hasta Ragil Saputra
2021-12-08 18:08:24 +07:00
parent 5ff23abda5
commit 9510a39d5b
6 changed files with 73 additions and 2 deletions

View File

@@ -13,6 +13,7 @@ import {
import { UsersService } from './users.service';
import { CreateUserDto } from './dto/create-user.dto';
import { UpdateUserDto } from './dto/update-user.dto';
import {Public} from "../auth/public.decorator";
@Controller({
path: 'users',
@@ -30,6 +31,7 @@ export class UsersController {
};
}
@Public()
@Get()
async findAll(@Query('page') page: number) {
const [data, count] = await this.usersService.findAll(page);