Skip to content

Commit

Permalink
fix: 편지 리스트/상세 조회 응답 객체 수정 #3
Browse files Browse the repository at this point in the history
  • Loading branch information
623nana committed Aug 23, 2021
1 parent 9892ed5 commit f38b7be
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,18 +36,22 @@ public class LetterResponse {

private String sendOptionText;

private Long sendOptionId;

private LocalDateTime createdDate;

public LetterResponse(Letter source) {
copyProperties(source, this);
this.contents = decodeContents(source.getContents());
this.sendOptionText = source.getSendOption().getText();
this.sendOptionId = source.getSendOption().getId();
this.name = source.getUser().getName();

}

public LetterResponse(Letter source, Question question) {
this(source);
this.questionText = question.getText();
this.name = source.getUser().getName();
}

private String decodeContents(String contents) {
Expand Down

0 comments on commit f38b7be

Please sign in to comment.