Skip to content

Commit

Permalink
fix(be): 🐛 restore task from bins
Browse files Browse the repository at this point in the history
[docker-latest]
  • Loading branch information
lehuygiang28 committed Aug 22, 2024
1 parent f2f6b95 commit 058de7b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apps/be/src/app/tasks/dtos/task.dto.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ export class TaskDto implements Task {

@ApiPropertyOptional({ type: Date, default: null })
@IsOptional()
deletedAt?: Date;
deletedAt?: Date | null;

@ApiProperty()
@IsOptional()
Expand Down
8 changes: 6 additions & 2 deletions apps/be/src/app/tasks/dtos/update-task.dto.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
import { PartialType } from '@nestjs/swagger';
import { IntersectionType, PartialType, PickType } from '@nestjs/swagger';
import { CreateTaskDto } from './create-task.dto';
import { TaskDto } from './task.dto';

export class UpdateTaskDto extends PartialType(CreateTaskDto) {}
export class UpdateTaskDto extends IntersectionType(
PartialType(CreateTaskDto),
PickType(TaskDto, ['deletedAt']),
) {}

0 comments on commit 058de7b

Please sign in to comment.