[refactor] 관리자페이지 모집정보수정에서 소개글 섹션을 제거한다#956
Conversation
- RecruitEditTab에서 더 이상 관리하지 않는 description 필드 및 관련 로직, MarkdownEditor 컴포넌트 제거 - handleUpdateClub함수에서 날짜 변환 시 undefined일 경우 빈 문자열을 할당하여 타입 에러 수정
- ClubDescription 인터페이스에서 description 및 externalApplicationUrl 필드 제거 - 모집 정보 수정에 필요한 recruitmentStart, recruitmentEnd, recruitmentTarget 필드 추가
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning
|
| 코호트 / 파일(s) | 변경 요약 |
|---|---|
RecruitEditTab 컴포넌트 업데이트frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx |
MarkdownEditor 임포트 및 소개글 UI 블록 제거, 로컬 description 상태 제거, 초기 effect에서 description 설정 제거, 업데이트 페이로드에서 description 및 externalApplicationUrl 제거, recruitmentStart/recruitmentEnd가 undefined일 때 null 사용으로 기본값 조정, 성공/오류 메시지 텍스트를 "모집 정보"로 변경 |
클럽 타입 정의 변경frontend/src/types/club.ts |
ClubDetail.recruitmentStart/recruitmentEnd 타입을 `string |
Sequence Diagram(s)
(해당 변경은 주로 UI/타입 제거 및 페이로드 조정으로, 다중 컴포넌트 간 새로운 순차 흐름을 도식화할 필요가 없어 생략합니다.)
Estimated code review effort
🎯 3 (Moderate) | ⏱️ ~25 minutes
Possibly related issues
- [refactor] MOA-449 관리자페이지 모집정보수정에서 소개글 섹션을 제거한다 #955: 관리자페이지 RecruitEditTab에서 소개글 섹션 제거 목표와 일치 — UI/상태 제거 관련.
- [refactor] MOA-452 동아리 수정 API 명세 변경 #960: 클럽 스키마와 API 페이로드(설명/추천/모집일자) 변경 관련 — 타입·페이로드 변화와 연관.
- [feature] MOA-453 동아리 소개 필드 추가 #962: Club description 데이터 모델 변경 관련 — description 필드 제거/재배치와 연관.
Possibly related PRs
- [feature] 관리자 페이지 모집기간 선택에 상시모집 처리 버튼을 추가한다 #774: RecruitEditTab의 모집 날짜 처리 및 항상 모집 로직 변경과 교차 영향 가능.
- RecruitEditTab에서 외부 지원서 URL을 업데이트하는 로직 추가 #610: RecruitEditTab에서 externalApplicationUrl/description 관련 페이로드 조정과 직접적 관련.
- [feature] 관리자페이지 수정하기 api 연동 #195: 이전에 도입된 description 관련 변경을 되돌리거나 조정하는 성격으로 연관성 높음.
Suggested reviewers
- oesnuj
- lepitaaar
- Zepelown
Pre-merge checks and finishing touches
❌ Failed checks (1 inconclusive)
| Check name | Status | Explanation | Resolution |
|---|---|---|---|
| Out of Scope Changes check | ❓ Inconclusive | ClubDetail에서 recommendClubs 필드를 제거한 변경은 명시된 이슈 범위와 직접적인 관련이 없으므로 추가 검토가 필요합니다. | recommendClubs 필드 제거가 필요한 이유와 기존 코드에 미치는 영향을 확인하십시오. 이것이 MOA-449와 관련된 필수 변경인지 명확히 하세요. |
✅ Passed checks (4 passed)
| Check name | Status | Explanation |
|---|---|---|
| Description Check | ✅ Passed | Check skipped - CodeRabbit’s high-level summary is enabled. |
| Title check | ✅ Passed | 제목이 변경사항의 주요 내용(소개글 섹션 제거)을 명확하게 요약하고 있으며, 간결하고 구체적입니다. |
| Linked Issues check | ✅ Passed | PR의 코드 변경사항이 MOA-449 이슈의 요구사항을 충족합니다. RecruitEditTab에서 소개글(description) 섹션 및 MarkdownEditor를 제거했고, ClubDescription 타입을 API 요청에 맞게 수정했으며, 날짜 필드의 null 처리를 구현했습니다. |
| Docstring Coverage | ✅ Passed | No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. |
✨ Finishing touches
- 📝 Generate docstrings
🧪 Generate unit tests (beta)
- Create PR with unit tests
- Post copyable unit tests in a comment
- Commit unit tests in branch
refactor/#955-admin-remove-recruitment-intro-MOA-449
📜 Recent review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (2)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsxfrontend/src/types/club.ts
🧰 Additional context used
📓 Path-based instructions (3)
frontend/**/*.{ts,tsx,js,jsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
frontend/**/*.{ts,tsx,js,jsx}: Replace magic numbers with named constants for clarity
Replace complex/nested ternaries withif/elseor IIFEs for readability
Assign complex boolean conditions to named variables for explicit meaning
Avoid hidden side effects; functions should only perform actions implied by their signature (Single Responsibility Principle)
Use unique and descriptive names for custom wrappers/functions to avoid ambiguity
Define constants near related logic or ensure names link them clearly to avoid silent failures
Break down broad state management into smaller, focused hooks/contexts to reduce coupling
Files:
frontend/src/types/club.tsfrontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
frontend/**/*.{ts,tsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
Use consistent return types for similar functions/hooks
Files:
frontend/src/types/club.tsfrontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
frontend/**/*.{tsx,jsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
frontend/**/*.{tsx,jsx}: Abstract complex logic/interactions into dedicated components/HOCs
Separate significantly different conditional UI/logic into distinct components
Colocate simple, localized logic or use inline definitions to reduce context switching
Choose field-level or form-level cohesion based on form requirements when using form libraries like react-hook-form
Use Component Composition instead of Props Drilling to reduce coupling
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
🧠 Learnings (2)
📓 Common learnings
Learnt from: seongwon030
Repo: Moadong/moadong PR: 195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
📚 Learning: 2025-03-19T05:18:07.818Z
Learnt from: seongwon030
Repo: Moadong/moadong PR: 195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
Applied to files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
🧬 Code graph analysis (1)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (2)
frontend/src/types/club.ts (1)
ClubDetail(16-28)frontend/src/apis/updateClubDescription.ts (1)
updateClubDescription(5-37)
🔇 Additional comments (5)
frontend/src/types/club.ts (2)
23-24: LGTM!
recruitmentStart와recruitmentEnd필드의 타입을string | null로 변경한 것은 백엔드 API의 nullable 날짜 처리와 일관성이 있습니다.
30-35: LGTM! ClubDescription 타입이 API 요청 구조에 맞게 간소화되었습니다.
description필드 제거와 모집 관련 필드 추가가 PR 목표(소개글 섹션 제거)에 부합합니다.updateClubDescription.ts에서 이 타입을 직접 사용하므로 API 페이로드 구조가 올바르게 반영되었습니다.frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (3)
115-120: 이전 리뷰 이슈가 올바르게 해결되었습니다.
toISOString() ?? ''대신toISOString() ?? null로 변경하여 백엔드 LocalDateTime 역직렬화 문제가 해결되었습니다.updatedData구조가ClubDescription타입과 정확히 일치합니다.
122-132: LGTM! 알림 메시지가 기능 변경에 맞게 업데이트되었습니다."동아리 정보"에서 "모집 정보"로 변경된 메시지가 이 탭의 실제 역할을 정확히 반영합니다.
26-31: LGTM! description 상태 제거가 완료되었습니다.MarkdownEditor와 관련된 상태 및 UI가 깔끔하게 제거되어 PR 목표(소개글 섹션 제거)가 달성되었습니다.
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 @coderabbitai help to get the list of available commands and usage tips.
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Disabled knowledge base sources:
- Jira integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (2)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsxfrontend/src/types/club.ts
🧰 Additional context used
📓 Path-based instructions (3)
frontend/**/*.{ts,tsx,js,jsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
frontend/**/*.{ts,tsx,js,jsx}: Replace magic numbers with named constants for clarity
Replace complex/nested ternaries withif/elseor IIFEs for readability
Assign complex boolean conditions to named variables for explicit meaning
Avoid hidden side effects; functions should only perform actions implied by their signature (Single Responsibility Principle)
Use unique and descriptive names for custom wrappers/functions to avoid ambiguity
Define constants near related logic or ensure names link them clearly to avoid silent failures
Break down broad state management into smaller, focused hooks/contexts to reduce coupling
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsxfrontend/src/types/club.ts
frontend/**/*.{tsx,jsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
frontend/**/*.{tsx,jsx}: Abstract complex logic/interactions into dedicated components/HOCs
Separate significantly different conditional UI/logic into distinct components
Colocate simple, localized logic or use inline definitions to reduce context switching
Choose field-level or form-level cohesion based on form requirements when using form libraries like react-hook-form
Use Component Composition instead of Props Drilling to reduce coupling
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
frontend/**/*.{ts,tsx}
📄 CodeRabbit inference engine (frontend/.cursorrules)
Use consistent return types for similar functions/hooks
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsxfrontend/src/types/club.ts
🧠 Learnings (3)
📓 Common learnings
Learnt from: seongwon030
Repo: Moadong/moadong PR: 195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
📚 Learning: 2025-03-19T05:18:07.818Z
Learnt from: seongwon030
Repo: Moadong/moadong PR: 195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
Applied to files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
📚 Learning: 2025-07-19T05:05:10.196Z
Learnt from: seongwon030
Repo: Moadong/moadong PR: 548
File: frontend/src/pages/ClubDetailPage/ClubDetailPage.tsx:17-57
Timestamp: 2025-07-19T05:05:10.196Z
Learning: ClubDetailPage.tsx에서 notJoinedClubNames 배열의 하드코딩은 의도적인 설계 결정입니다. 개발자가 명시적으로 하드코딩을 선택했으므로 이에 대한 리팩토링 제안을 하지 않아야 합니다.
Applied to files:
frontend/src/types/club.ts
🧬 Code graph analysis (1)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (2)
frontend/src/types/club.ts (1)
ClubDetail(16-28)frontend/src/apis/updateClubDescription.ts (1)
updateClubDescription(5-37)
🔇 Additional comments (3)
frontend/src/types/club.ts (1)
30-35: 변경 사항이 적절합니다.
ClubDescription타입이 API 업데이트 페이로드에 맞게 수정되었습니다.description및externalApplicationUrl필드를 제거하고 모집 관련 필드(recruitmentStart,recruitmentEnd,recruitmentTarget)를 추가한 것은 RecruitEditTab의 변경 사항과 일치합니다.ClubDetail은 전체 클럽 데이터를 표현하는 타입으로description을 유지하고,ClubDescription은 모집 정보 업데이트 API의 페이로드 타입으로 분리된 설계가 명확합니다.frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (2)
26-26: 훅 순서 변경이 안전합니다.
useOutletContext를 다른 훅들 이후에 호출하도록 변경했습니다. React 훅은 최상위 레벨에서 호출되는 한 순서를 변경해도 안전하며, 이 변경은 문제가 없습니다.
124-124: 사용자 메시지 업데이트가 적절합니다.알림 메시지를 "동아리 정보"에서 "모집 정보"로 변경하여 이 탭의 기능을 더 정확하게 반영하도록 개선했습니다.
Also applies to: 130-130
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
Outdated
Show resolved
Hide resolved
- recruitmentStart/End 타입을 `string | null`로 변경 - 날짜 미설정 시 null 값을 전송하도록 `updatedData` 객체 생성 로직 수정
#️⃣연관된 이슈
📝작업 내용
1. 모집 정보 탭(RecruitEditTab) 로직 간소화
해당 탭에서 동아리 상세 설명(description) 필드를 제거했습니다.
이에 따라 불필요해진 MarkdownEditor 컴포넌트와 관련 상태/로직을 삭제했습니다.
2. 타입 정의 업데이트 (types/club.ts)
ClubDescription타입을 실제 API 요청에 맞게 수정했습니다. (recruitmentStart, recruitmentEnd, recruitmentTarget 추가)3. 기타 버그 수정
날짜 데이터 변환 시 undefined가 발생할 수 있는 타입 에러를 수정했습니다.
중점적으로 리뷰받고 싶은 부분(선택)
논의하고 싶은 부분(선택)
🫡 참고사항
Summary by CodeRabbit
릴리스 노트
기능 변경
개선 사항
✏️ Tip: You can customize this high-level summary in your review settings.