-
Notifications
You must be signed in to change notification settings - Fork 3
[feature] 동아리 지원하기 기능 #536
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
aa1a9ee
feat: 지원서 라우팅 주석해제
lepitaaar 1613b2b
fix: api 명세에 맞게 필드 변경
lepitaaar fa00ffe
feat: 지원하기 추가
lepitaaar f13b8d5
feat: 동아리 지원하기 활성화
lepitaaar 73662a5
feat: 첫번째 질문은 이름으로 고정
lepitaaar e944612
feat: 지원서가 존재하지 않는경우 리다이렉트
lepitaaar 92cebe0
feat: 질문에 readOnly 속성 추가
lepitaaar db1e1c7
feat: '지원 관리' 알림 메시지 제거
lepitaaar 2abf809
fix: 모든 상왕에서 커서가 변경됨
lepitaaar 189bffb
fix: 오류 발생 시 사용자에게 안내 메시지 표시
lepitaaar 512a559
Update frontend/src/pages/AdminPage/application/CreateApplicationForm…
lepitaaar ed44003
refactor: field change
lepitaaar File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| import API_BASE_URL from '@/constants/api'; | ||
| import { AnswerItem } from '@/types/application'; | ||
|
|
||
| export const applyToClub = async ( | ||
| clubId: string, | ||
| answers: AnswerItem[], | ||
| ) => { | ||
| try { | ||
| const response = await fetch( | ||
| `${API_BASE_URL}/api/club/${clubId}/apply`, | ||
| { | ||
| method: 'POST', | ||
| headers: { | ||
| 'Content-Type': 'application/json', | ||
| }, | ||
| body: JSON.stringify({ | ||
| questions: [ | ||
| ...answers | ||
| ] | ||
| }), | ||
| }, | ||
| ); | ||
|
|
||
| if (!response.ok) { | ||
| throw new Error('답변 제출에 실패했습니다.'); | ||
| } | ||
|
|
||
| const result = await response.json(); | ||
| return result.data; | ||
| } catch (error) { | ||
| console.error('답변 제출 중 오류 발생:', error); | ||
| throw error; | ||
| } | ||
| }; | ||
|
|
||
| export default applyToClub; |
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
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
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
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
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
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
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
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
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
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
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
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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
응답 본문을 한 번만 읽도록 개선하세요.
response.json()을 두 번 호출하면 "Body has already been read" 오류가 발생할 수 있습니다. 응답 본문을 한 번만 읽고 재사용하세요.📝 Committable suggestion
🤖 Prompt for AI Agents