-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: 봉사모집 상세페이지 보호소프로필 이동, 봉사 신청 msw 추가 (#245)
* refactor(volunteer): 봉사모집상세조회, 보호소 간단정보조회 fetch hook 분리 * refactor(volunteer): 봉사모집상세조회 데이터 받아오기 * feat(volunteer): 봉사신청 mock api 추가 * fix(volunteer): 봉사신청 api 수정 * feat(volunteer): 봉사신청 msw 연결 * fix(volunteer): 채팅하기 버튼 제거 * feat(volunteer): 보호소 정보 클릭하면 보호소 프로필 페이지로 이동 * feat(volunteer): 봉사신청 자동마감 된 경우 추가
- Loading branch information
Showing
6 changed files
with
138 additions
and
146 deletions.
There are no files selected for viewing
This file contains 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 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
9 changes: 9 additions & 0 deletions
9
apps/volunteer/src/pages/volunteers/detail/_hooks/useFetchRecruitmentDetail.ts
This file contains 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,9 @@ | ||
import { useSuspenseQuery } from '@tanstack/react-query'; | ||
import { getRecruitmentDetail } from 'shared/apis/common/Recruitments'; | ||
|
||
const useFetchRecruitmentDetail = (recruitmentId: number) => | ||
useSuspenseQuery({ | ||
queryKey: ['recruitment', recruitmentId], | ||
queryFn: async () => (await getRecruitmentDetail(recruitmentId)).data, | ||
}); | ||
export default useFetchRecruitmentDetail; |
11 changes: 11 additions & 0 deletions
11
apps/volunteer/src/pages/volunteers/detail/_hooks/useFetchSimpleShelterInfo.ts
This file contains 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,11 @@ | ||
import { useSuspenseQuery } from '@tanstack/react-query'; | ||
|
||
import { getSimpleShelterProfile } from '@/apis/shelter'; | ||
|
||
const useFetchSimpleShelterInfo = (shelterId: number) => | ||
useSuspenseQuery({ | ||
queryKey: ['shelter', 'simpleProfile', shelterId], | ||
queryFn: async () => (await getSimpleShelterProfile(shelterId)).data, | ||
}); | ||
|
||
export default useFetchSimpleShelterInfo; |
74 changes: 0 additions & 74 deletions
74
apps/volunteer/src/pages/volunteers/detail/_hooks/useFetchVolunteerDetail.ts
This file was deleted.
Oops, something went wrong.
This file contains 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