Spaces:
Sleeping
Sleeping
import { | |
Controller, | |
Get, | |
Post, | |
Body, | |
Patch, | |
Param, | |
Delete, | |
} from '@nestjs/common'; | |
import { FeedsService } from './feeds.service.js'; | |
import { CreateFeedDto } from './dto/create-feed.dto.js'; | |
import { UpdateFeedDto } from './dto/update-feed.dto.js'; | |
import { Public } from '../authentication/authentication.decorator.js'; | |
import { Paginate, PaginateQuery } from 'nestjs-paginate'; | |
() | |
'feeds') | (|
export class FeedsController { | |
constructor(private readonly feedsService: FeedsService) {} | |
() | |
create() { () createFeedDto: CreateFeedDto | |
return this.feedsService.create(createFeedDto); | |
} | |
() | |
findAll() { () paginateQuery: PaginateQuery | |
return this.feedsService.findAll(paginateQuery); | |
} | |
':id') | (|
findOne('id') id: string) { ( | |
return this.feedsService.findOne(+id); | |
} | |
':id') | (|
update('id') id: string, () updateFeedDto: UpdateFeedDto) { ( | |
return this.feedsService.update(+id, updateFeedDto); | |
} | |
':id') | (|
remove('id') id: string) { ( | |
return this.feedsService.remove(+id); | |
} | |
} | |