Skip to content

Commit

Permalink
chore: add createdAt to post list
Browse files Browse the repository at this point in the history
  • Loading branch information
Marades committed Jul 17, 2024
1 parent 4a8cdce commit 6ca291e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/modules/posts/response/listPost.response.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@ export class ListPostItem {
})
readAt: Date;

@ApiProperty()
createdAt: Date;

constructor(data: Post & { _id: Types.ObjectId }) {
this.id = data._id.toString();
this.folderId = data.folderId.toString();
Expand All @@ -35,6 +38,7 @@ export class ListPostItem {
this.description = data.description;
this.isFavorite = data.isFavorite;
this.readAt = data.readAt;
this.createdAt = data.createdAt;
}
}

Expand Down

0 comments on commit 6ca291e

Please sign in to comment.