[FEAT] project 상세조회·수정·벌크상태변경·타임라인 엔드포인트 배선 - #146
Merged
Conversation
FR-PJ-02,03,06,07 — domain/application 계층은 이미 완성돼 있던 상태라
ProjectController 연결과 Request/Response DTO 필드 채우기가 핵심이다.
- 상세조회(GET /{id})·수정(PATCH /{id})·벌크상태변경(PATCH /status/bulk) 배선
- 상세조회·타임라인에 companyId 스코프 검증 추가(다른 회사 프로젝트를 id로 직접
조회할 수 있던 IDOR 구멍을 배선하면서 함께 막음)
- 타임라인(GetProjectTimelineUseCase)은 설계부터 필요해서 action 도메인에
ActionQueryPort 신설(ProjectQueryPort와 동일한 방향의 조회 포트) — project는
action 엔티티를 직접 참조하지 않고 이 포트로만 팀 액션을 조회한다
ProjectServiceTest 신설(회사 스코프·OWNER 검증·all-or-nothing·지연 배지 계산), ProjectControllerTest에 신규 엔드포인트 4개 배선 검증 추가.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthrough프로젝트 상세 조회에 회사 소속 검증을 추가했다. 프로젝트 수정과 상태 일괄 변경 API를 구현했다. 액션 조회 포트를 연결해 프로젝트 타임라인과 지연 상태를 반환한다. 요청·응답 DTO와 서비스·컨트롤러 테스트를 추가했다. Changes프로젝트 관리 흐름
Estimated code review effort: 4 (Complex) | ~45 minutes Possibly related PRs
Suggested labels: Suggested reviewers: Sequence Diagram(s)sequenceDiagram
actor 인증 사용자
participant ProjectController
participant ProjectService
participant ActionPersistenceAdapter
participant SpringDataActionRepository
인증 사용자->>ProjectController: GET /{projectId}/timeline
ProjectController->>ProjectService: companyId, projectId 전달
ProjectService->>ActionPersistenceAdapter: findTeamActionsByProjectId(projectId)
ActionPersistenceAdapter->>SpringDataActionRepository: 액션 유형·프로젝트 ID 조회
SpringDataActionRepository-->>ActionPersistenceAdapter: 액션 목록 반환
ActionPersistenceAdapter-->>ProjectService: TeamActionSummary 목록 반환
ProjectService-->>ProjectController: 지연 여부를 계산한 TimelineItem 목록
ProjectController-->>인증 사용자: ProjectTimelineItemResponse 목록
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Comment |
develop이 #142(ActionDistributionPort 실구현) 반영 후 앞서나가서 발생한 ActionPersistenceAdapter.java 충돌 해결 — develop의 toEntity() 추출과 이 브랜치의 findTeamActionsByProjectId()를 모두 보존.
This was referenced Aug 9, 2026
4 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📌 연관 이슈
📝 작업 내용
GET /api/projects/{projectId}배선 — 이미 완성돼 있던GetProjectDetailUseCase/ProjectService.getDetail에 컨트롤러·Response DTO 연결PATCH /api/projects/{projectId}배선 —UpdateProjectUseCase/ProjectService.update에 컨트롤러·Request DTO 연결PATCH /api/projects/status/bulk배선 — 빈 record였던BulkUpdateProjectStatusRequest에 필드 채우고 컨트롤러 연결GET /api/projects/{projectId}/timeline신규 구현 — 유일하게 계약(GetProjectTimelineUseCase)까지 빈 상태였어서 설계부터 진행. action 도메인에ActionQueryPort신설(action이 선언·구현, project가 호출 —ProjectQueryPort와 반대 방향의 동일 패턴)해서 project가 action 엔티티를 직접 참조하지 않고 팀 액션을 조회하도록 함PROJECT_NOT_FOUND로 응답하도록 막았습니다(존재 여부 자체를 노출하지 않음).ProjectServiceTest신설(회사 스코프·OWNER 검증·벌크 all-or-nothing·타임라인 지연 배지 계산, 정상+예외),ProjectControllerTest에 신규 엔드포인트 4개 배선 검증 추가🖥️ 프론트엔드 연동 가이드 (API 명세)
1. 주요 엔드포인트
GET/api/projects/{projectId}: 프로젝트 상세(기획 탭) 조회 — 전 구성원 공개PATCH/api/projects/{projectId}: 프로젝트 수정 — OWNER 전용, tag·status는 받지 않음(불변/별도 엔드포인트)PATCH/api/projects/status/bulk: 보드 "저장" 버튼용 상태 일괄변경 — OWNER 전용, all-or-nothingGET/api/projects/{projectId}/timeline: 타임라인 탭 조회 — 전 구성원 공개, 한 행 = 팀 액션 카드2. 요청 파라미터 (Request)
PATCH /api/projects/{projectId}#RRGGBBPATCH /api/projects/status/bulkTODO/IN_PROGRESS/DONE3. 정상 응답 예시 (200 OK)
GET /api/projects/{projectId}/timeline
{ "httpStatus": 200, "message": "프로젝트 타임라인을 조회했습니다.", "data": [ { "actionId": 10, "title": "백엔드 API 설계", "teamId": 1, "teamName": "개발팀", "status": "IN_PROGRESS", "dueDate": "2026-08-01", "isDelayed": true } ] }4.⚠️ 프론트엔드 참고 및 주의사항
isDelayed는 DB 컬럼이 아니라 서버가 계산해서 내려주는 파생값입니다(마감일이 지났고 상태가 DONE이 아닌 경우).tag·status필드를 보내도 무시됩니다 — tag는 생성 후 불변(FR-PJ-04), status는 벌크 엔드포인트 전용입니다.PJ-001)가 납니다.🚨 주요 에러 코드 및 예외 (Exceptions)
PJ-001: 존재하지 않거나 다른 회사 소속인 프로젝트 (상세조회·수정·벌크·타임라인 공통)PJ-002: 프로젝트 소유자가 아닌 사람이 수정/상태변경 시도PJ-006: 소속되지 않은 부서를 teamIds에 지정💡 백엔드 리뷰 포인트 (Backend Review)
ActionQueryPort는 action 도메인이 선언·구현하고 project가 소비합니다. 기존ProjectQueryPort(project가 선언·구현, meeting이 소비)와 방향이 반대인 동일 패턴이라 이해하기 쉬울 겁니다.ActionPersistenceAdapter에findTeamActionsByProjectId구현 시, 완료된 프로젝트 필터링에 쓰던 것과 동일하게 2단계 파생 쿼리(팀 액션 조회 → teamId로 팀명 배치조회)로 처리해 Gate 1(QUERY_002, 신규@Query금지)을 준수했습니다.✅ 체크리스트
compileJava·test·migrationCheck전부 통과 확인)ProjectServiceTest예외 케이스 포함)🤖 Generated with Claude Code
Summary by CodeRabbit
새로운 기능
개선 사항