RecruitEditTab에서 외부 지원서 URL을 업데이트하는 로직 추가#610
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
|
Warning
|
| Cohort / File(s) | Change Summary |
|---|---|
RecruitEditTab externalApplicationUrl 추가frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx |
updatedData에 externalApplicationUrl 속성 추가 및 값 할당 로직 반영 |
Estimated code review effort
🎯 1 (Trivial) | ⏱️ ~2 minutes
Possibly related PRs
- [fix] 지원서 미등록 시 alert 반복 버그 수정 및 외부 링크/지원서 분기 처리 #605: club description 업데이트 데이터에
externalApplicationUrl속성 추가와 직접적으로 관련됨. - [feature]외부 지원서 링크 추가 #606: 프론트엔드 업데이트 뮤테이션에
externalApplicationUrl속성 추가와 백엔드 엔티티 및 DTO 필드 도입이 연계됨. - [release]모아동 BE v1.0.5 배포 #608: 프론트엔드 뮤테이션에
externalApplicationUrl추가와 백엔드 리크루팅 정보 엔티티 및 DTO 필드 추가가 직접적으로 연결됨.
Suggested labels
✨ Feature
Suggested reviewers
- PororoAndFriends
Note
⚡️ Unit Test Generation is now available in beta!
Learn more here, or try it out under "Finishing Touches" below.
✨ Finishing Touches
- 📝 Generate Docstrings
🧪 Generate unit tests
- Create PR with unit tests
- Post copyable unit tests in a comment
- Commit unit tests in branch
feature/add-externalUrl-field
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.
🪧 Tips
Chat
There are 3 ways to chat with CodeRabbit:
- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
I pushed a fix in commit <commit_id>, please review it.Explain this complex logic.Open a follow-up GitHub issue for this discussion.
- Files and specific lines of code (under the "Files changed" tab): Tag
@coderabbitaiin a new review comment at the desired location with your query. Examples:@coderabbitai explain this code block.@coderabbitai modularize this function.
- PR comments: Tag
@coderabbitaiin a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.@coderabbitai read src/utils.ts and explain its main purpose.@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.@coderabbitai help me debug CodeRabbit configuration file.
Support
Need help? Create a ticket on our support page for assistance with any issues or questions.
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.
CodeRabbit Commands (Invoked using PR comments)
@coderabbitai pauseto pause the reviews on a PR.@coderabbitai resumeto resume the paused reviews.@coderabbitai reviewto trigger an incremental review. This is useful when automatic reviews are disabled for the repository.@coderabbitai full reviewto do a full review from scratch and review all the files again.@coderabbitai summaryto regenerate the summary of the PR.@coderabbitai generate docstringsto generate docstrings for this PR.@coderabbitai generate sequence diagramto generate a sequence diagram of the changes in this PR.@coderabbitai generate unit teststo generate unit tests for this PR.@coderabbitai resolveresolve all the CodeRabbit review comments.@coderabbitai configurationto show the current CodeRabbit configuration for the repository.@coderabbitai helpto get help.
Other keywords and placeholders
- Add
@coderabbitai ignoreanywhere in the PR description to prevent this PR from being reviewed. - Add
@coderabbitai summaryto generate the high-level summary at a specific location in the PR description. - Add
@coderabbitaianywhere in the PR title to generate the title automatically.
Documentation and Community
- Visit our Documentation for detailed information on how to use CodeRabbit.
- Join our Discord Community to get help, request features, and share feedback.
- Follow us on X/Twitter for updates and announcements.
There was a problem hiding this comment.
Actionable comments posted: 1
🔭 Outside diff range comments (1)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (1)
40-47: externalApplicationUrl 필드 지원을 위한 타입 및 API 확장 필요현재
useUpdateClubDescription훅은ClubDescription타입만을 받으며, 해당 인터페이스에는externalApplicationUrl필드가 정의되어 있지 않습니다. 따라서 아래 작업이 필요합니다:•
src/types/club.ts의 ClubDescription 인터페이스에externalApplicationUrl?: string | null;필드를 추가하세요.
•src/apis/updateClubDescription.ts(또는 해당 GraphQL/mutation 정의)에서
externalApplicationUrl인자를 받아 처리하도록 스키마와 리졸버를 확장하세요.
• 프론트엔드 훅(useUpdateClubDescription)의 시그니처가 업데이트된 타입을 반영하는지 확인하세요.이후
RecruitEditTab에서 전달한externalApplicationUrl이 정상적으로 백엔드에 저장되는지 검증하시면 됩니다.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx(1 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
frontend/**/*.{ts,tsx}
📄 CodeRabbit Inference Engine (frontend/.cursorrules)
frontend/**/*.{ts,tsx}: Replace magic numbers with named constants for clarity.
Replace complex or nested ternary operators with if/else statements or IIFEs for readability.
Assign complex boolean conditions to named variables.
Use consistent return types for similar functions and hooks.
Avoid hidden side effects; functions should only perform actions implied by their signature (Single Responsibility Principle).
Use unique, descriptive names for custom wrappers and functions to avoid ambiguity.
Define constants near related logic or ensure names link them clearly.
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
frontend/**/*.tsx
📄 CodeRabbit Inference Engine (frontend/.cursorrules)
frontend/**/*.tsx: Abstract complex logic/interactions into dedicated components or higher-order 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.
Break down broad state management into smaller, focused hooks or contexts.
Use component composition instead of props drilling.
Files:
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx
🧠 Learnings (2)
📓 Common learnings
Learnt from: seongwon030
PR: Moadong/moadong#195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
Learnt from: seongwon030
PR: Moadong/moadong#548
File: frontend/src/pages/ClubDetailPage/ClubDetailPage.tsx:17-57
Timestamp: 2025-07-19T05:05:10.196Z
Learning: ClubDetailPage.tsx에서 notJoinedClubNames 배열의 하드코딩은 의도적인 설계 결정입니다. 개발자가 명시적으로 하드코딩을 선택했으므로 이에 대한 리팩토링 제안을 하지 않아야 합니다.
frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx (2)
Learnt from: seongwon030
PR: #195
File: frontend/src/pages/AdminPage/AdminPage.tsx:7-7
Timestamp: 2025-03-19T05:18:07.818Z
Learning: AdminPage.tsx에서 현재 하드코딩된 클럽 ID('67d2e3b9b15c136c6acbf20b')는 로그인 기능 구현 후 동적으로 가져오는 방식으로 수정될 예정입니다.
Learnt from: lepitaaar
PR: #406
File: backend/src/main/java/moadong/club/service/ClubApplyService.java:34-38
Timestamp: 2025-05-19T05:45:52.957Z
Learning: The code duplication between createClubApplication and editClubApplication methods in ClubApplyService.java is acknowledged but will be addressed in a future refactoring, as per the developer's plan.
| recruitmentEnd: recruitmentEnd?.toISOString(), | ||
| recruitmentTarget: recruitmentTarget, | ||
| description: description, | ||
| externalApplicationUrl: clubDetail.externalApplicationUrl ?? '' |
There was a problem hiding this comment.
외부 지원서 URL 편집을 위한 UI 컴포넌트가 누락되었습니다.
externalApplicationUrl 속성이 updatedData에 추가되었지만, 사용자가 이 값을 편집할 수 있는 UI 컴포넌트(예: InputField)가 JSX에 없습니다. 현재 구현으로는 기존 값만 다시 전송되며, 실제로 URL을 수정할 수 없습니다.
다음과 같이 외부 지원서 URL을 편집할 수 있는 입력 필드를 추가해야 합니다:
const [recruitmentTarget, setRecruitmentTarget] = useState('');
const [description, setDescription] = useState('');
+ const [externalApplicationUrl, setExternalApplicationUrl] = useState(''); setRecruitmentTarget((prev) => prev || clubDetail.recruitmentTarget || '');
setDescription((prev) => prev || clubDetail.description || '');
+ setExternalApplicationUrl((prev) => prev || clubDetail.externalApplicationUrl || ''); externalApplicationUrl: clubDetail.externalApplicationUrl ?? ''
+ externalApplicationUrl: externalApplicationUrl <InputField
label='모집 대상'
placeholder='모집 대상을 입력해주세요.'
type='text'
value={recruitmentTarget}
onChange={(e) => setRecruitmentTarget(e.target.value)}
onClear={() => setRecruitmentTarget('')}
maxLength={10}
/>
+ <InputField
+ label='외부 지원서 URL'
+ placeholder='외부 지원서 URL을 입력해주세요.'
+ type='url'
+ value={externalApplicationUrl}
+ onChange={(e) => setExternalApplicationUrl(e.target.value)}
+ onClear={() => setExternalApplicationUrl('')}
+ />Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In frontend/src/pages/AdminPage/tabs/RecruitEditTab/RecruitEditTab.tsx at line
46, the externalApplicationUrl field is included in updatedData but there is no
input component in the JSX to allow users to edit this URL. To fix this, add an
input field component (such as an InputField) bound to externalApplicationUrl in
the form JSX so users can modify the URL. Ensure the input updates the
corresponding state or form data to reflect user changes.
#️⃣연관된 이슈
#609
📝작업 내용
RecruitEditTab에서 외부 지원서 URL을 업데이트하는 로직 추가
중점적으로 리뷰받고 싶은 부분(선택)
논의하고 싶은 부분(선택)
🫡 참고사항
Summary by CodeRabbit