Refactor/KD-55 GraduationUser 상세 조회 API가 졸업 상태를 포함하도록 수정#299
Refactor/KD-55 GraduationUser 상세 조회 API가 졸업 상태를 포함하도록 수정#299JangYeongHu merged 7 commits intodevelopfrom
Conversation
|
Important Review skippedAuto incremental reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Walkthrough졸업 사용자의 상태 정보를 응답에 포함시키기 위해 GraduationUserAdminFacade에서 GraduationUserStatusResponse를 생성하고, GraduationUserDetailResponse에 status 필드를 추가했습니다. 동시에 데이터베이스 스키마에 capstone_completion 컬럼을 추가하고 관련 데이터를 업데이트했습니다. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 추가 주의 영역:
Possibly related issues
Possibly related PRs
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Test Coverage Report
Files
|
Codecov Report❌ Patch coverage is
@@ Coverage Diff @@
## develop #299 +/- ##
=============================================
- Coverage 86.56% 86.51% -0.06%
Complexity 67 67
=============================================
Files 24 24
Lines 268 267 -1
Branches 17 14 -3
=============================================
- Hits 232 231 -1
- Misses 21 24 +3
+ Partials 15 12 -3
Continue to review full report in Codecov by Sentry.
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Actionable comments posted: 1
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
aics-admin/src/main/java/kgu/developers/admin/graduationUser/presentation/response/GraduationUserDetailResponse.java (1)
57-67:graduationDate가 null일 경우 NPE 발생 가능성이 있습니다.스키마에서
graduation_date는 nullable 컬럼입니다.graduationUser.getGraduationDate()가 null인 경우.format(formatter)호출 시 NullPointerException이 발생할 수 있습니다.🔎 제안된 수정
public static GraduationUserDetailResponse from( GraduationUser graduationUser, GraduationUserStatusResponse status ) { DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM"); return GraduationUserDetailResponse.builder() .graduationUserId(graduationUser.getId()) .name(graduationUser.getName()) .studentId(graduationUser.getUserId()) - .graduationDate(graduationUser.getGraduationDate().format(formatter)) + .graduationDate(graduationUser.getGraduationDate() != null + ? graduationUser.getGraduationDate().format(formatter) + : null) .advisor(graduationUser.getAdvisorProfessor()) .major(graduationUser.getDepartment()) .capstoneCompletion(graduationUser.getCapstoneCompletion()) .status(status) .build(); }
🧹 Nitpick comments (2)
aics-admin/src/main/java/kgu/developers/admin/graduationUser/application/GraduationUserAdminFacade.java (2)
104-111: 변수 네이밍 일관성 개선을 권장합니다.
midThesisapproval은 camelCase 컨벤션에 맞게midThesisApproval로 변경하는 것이 좋습니다.🔎 제안된 수정
- boolean midThesisapproval = false; + boolean midThesisApproval = false; if(midThesisSubmitted) { - midThesisapproval = thesisQueryService.isApproved(middleThesisId); + midThesisApproval = thesisQueryService.isApproved(middleThesisId); } GraduationUserStatusResponse.Thesis.Middle midStatus = - new GraduationUserStatusResponse.Thesis.Middle(midThesisSubmitted,midThesisapproval); + new GraduationUserStatusResponse.Thesis.Middle(midThesisSubmitted, midThesisApproval);
113-120: 변수 네이밍 일관성 개선을 권장합니다.
finalThesisapproval도 동일하게finalThesisApproval로 변경하는 것이 좋습니다.🔎 제안된 수정
- boolean finalThesisapproval = false; + boolean finalThesisApproval = false; if(finalThesisSubmitted) { - finalThesisapproval = thesisQueryService.isApproved(finalThesisId); + finalThesisApproval = thesisQueryService.isApproved(finalThesisId); } GraduationUserStatusResponse.Thesis.Final finalStatus = - new GraduationUserStatusResponse.Thesis.Final(finalThesisSubmitted,finalThesisapproval); + new GraduationUserStatusResponse.Thesis.Final(finalThesisSubmitted, finalThesisApproval);
📜 Review details
Configuration used: Repository UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
aics-admin/src/main/java/kgu/developers/admin/graduationUser/application/GraduationUserAdminFacade.java(1 hunks)aics-admin/src/main/java/kgu/developers/admin/graduationUser/presentation/response/GraduationUserDetailResponse.java(2 hunks)aics-admin/src/main/java/kgu/developers/admin/graduationUser/presentation/response/GraduationUserSummaryResponse.java(1 hunks)aics-api/src/main/resources/db/data.sql(1 hunks)aics-api/src/main/resources/db/schema.sql(1 hunks)
🔇 Additional comments (4)
aics-admin/src/main/java/kgu/developers/admin/graduationUser/presentation/response/GraduationUserSummaryResponse.java (1)
47-61: LGTM!파라미터 포맷팅 변경으로 가독성이 향상되었습니다. 팩토리 메서드 로직은 정확합니다.
aics-api/src/main/resources/db/schema.sql (1)
159-159: LGTM!
capstone_completion컬럼 추가가 올바르게 되었습니다. 다른 선택적 필드들과 동일하게 nullable로 설정되어 있어 기존 데이터와의 호환성이 유지됩니다.aics-admin/src/main/java/kgu/developers/admin/graduationUser/application/GraduationUserAdminFacade.java (1)
130-134: LGTM!상세 조회 시 졸업 상태 정보를 포함하도록 올바르게 수정되었습니다.
buildSubmissionStatus헬퍼 메서드를 재사용하여 코드 중복을 방지한 점이 좋습니다.aics-admin/src/main/java/kgu/developers/admin/graduationUser/presentation/response/GraduationUserDetailResponse.java (1)
34-51: LGTM!
capstoneCompletion과status필드 추가가 올바르게 되었습니다. Schema 어노테이션의 예시도 상세하게 작성되어 API 문서화에 도움이 됩니다.
dkdltm221
left a comment
There was a problem hiding this comment.
논문,자격증 조회 서비스 수정하신 코드가 제거와 동일해서 충돌 생기는 부분만 잘해결해주시면 될거같습니다. 고생하셨어요!
Summary
GraduationUserDetailResponse가 졸업 상태 정보를 포함하도록 상세 조회 API를 수정합니다.
Tasks