Skip to content

[4주차] 시재욱/[feat] 추가 API 구현#144

Open
seejaewook456-maker wants to merge 1 commit intoLeets-Official:시재욱/mainfrom
seejaewook456-maker:시재욱/4주차

Hidden character warning

The head ref may contain hidden characters: "\uc2dc\uc7ac\uc6b1/4\uc8fc\ucc28"
Open

[4주차] 시재욱/[feat] 추가 API 구현#144
seejaewook456-maker wants to merge 1 commit intoLeets-Official:시재욱/mainfrom
seejaewook456-maker:시재욱/4주차

Conversation

@seejaewook456-maker
Copy link
Copy Markdown

@seejaewook456-maker seejaewook456-maker commented Apr 28, 2026

1. 과제 요구사항 중 구현한 내용

  • 게시물/댓글/신고 도메인 활용
  • 단순 CRUD를 넘는 기능 설계 및 구현
  • API 3개 이상 구현
  • 도메인 상태(State) 변화 반영
  • 동일 요청 중복 처리 방지 로직 반영

2. 핵심 변경 사항

  1. 게시글에 대한 신고 기능을 추가했습니다. 이때 같은 사용자가 동일 게시글을 중복 신고하지 못하도록 제한했습니다.
  2. 댓글에 대한 신고 기능을 추가했습니다. 이때 같은 사용자가 동일 댓글을 중복 신고하지 못하도록 제한했습니다.
  3. 게시글/댓글 신고에 대한 처리 기능을 추가했습니다.
  • 신고 상태 : PENDING -> RESOLVED 변경
  • 신고 대상 (게시글/댓글)의 상태 : ACTIVE -> HIDDEN 변경
  1. 추가한 api 관련 예외 처리를 위해 BaseCode에 예외 메시지를 추가했습니다.

3. 실행 및 검증 결과

게시글 신고

게시글 신고 성공

게시글 중복 신고 제한

이미 신고한 게시글

댓글 신고

댓글 신고 성공

댓글 중복 신고 제한

이미 신고한 댓글

댓글/게시글 신고 처리 완료

게시글 신고 처리 완료 댓글 신고 완료

4. 완료 사항

  1. 게시글 신고 및 중복 신고 제한
  2. 댓글 신고 및 중복 신고 제한
  3. 신고 처리 및 상태 변경

5. 추가 사항

#143

제출 체크리스트

  • PR 제목이 규칙에 맞다
  • base가 {이름}/main 브랜치다
  • compare가 {이름}/{숫자}주차 브랜치다
  • 프로젝트가 정상 실행된다
  • 본인을 Assignee로 지정했다
  • 파트 담당 Reviewer를 지정했다
  • 리뷰 피드백을 반영한 뒤 머지/PR close를 진행한다

Reviewer 참고

@seejaewook456-maker seejaewook456-maker requested a review from a team April 28, 2026 08:58
@seejaewook456-maker seejaewook456-maker self-assigned this Apr 28, 2026
Copy link
Copy Markdown

@yeonjuncho yeonjuncho left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 코드와 pr을 깔끔하게 작성해주신 것 같습니다.
고생하셨습니다!

@Enumerated(EnumType.STRING)
@Column(nullable = false)
@Builder.Default
private PostStatus status = PostStatus.ACTIVE;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

과제 요구 사항 중 하나인 상태 변화 (ACTIVE->HIDDEN)를 잘 설계하신 것 같아요 👍

}

// 댓글 신고
public ReportResponse reportComment(Long commentId, ReportCreateRequest request) {
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

예외처리 및 에러 코드 적용, 상태 변화 적용을 잘 설계하셨고, 구조도 깔끔하게 잘 작성하신 것 같습니다 👍

.reporterId(report.getReporter().getId())
.targetType(report.getTargetType())
.targetId(targetId)
.reason(report.getReason())
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💬 신고 사유 필드를 통해 관리자가 신고 내용을 쉽게 파악할 수 있겠네요. 📝 이전에 작성하신 서비스 로직의 title 필드와 이 DTO의 reason 필드 네이밍이 일치하는지 한 번 더 확인해 보시면 완벽할 것 같습니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants