import { Body, Controller, Delete, Get, Param, Post } from '@nestjs/common';
import { CreateTaskWorklogDto } from './dto/create-task-worklog.dto';
import { TaskWorklogService } from './task-worklog.service';

@Controller('task-worklogs')
export class TaskWorklogController {
  constructor(private readonly taskWorklogService: TaskWorklogService) {}

  @Get()
  findAll() {
    return this.taskWorklogService.findAll();
  }

  @Post()
  create(@Body() dto: CreateTaskWorklogDto) {
    return this.taskWorklogService.create(dto);
  }

  @Delete(':id')
  remove(@Param('id') id: string) {
    return this.taskWorklogService.remove(id);
  }
}
