Skip to content

Conversation

@seorang42
Copy link
Contributor

@seorang42 seorang42 commented Feb 5, 2025

#️⃣연관된 티켓 넘버

CLAP-270
close #92

📝작업 내용

TaskCard에서 사용될 구분 컴포넌트를 구현하였습니다.
StatisticsCategoryCard 컴포넌트에서 1차 카테고리를 선택해도 2차 카테고리가 갱신되지 않는 버그를 수정하였습니다

🏞️스크린샷 (선택)

스크린샷 2025-02-05 오후 6 51 24

💬리뷰 요구사항(선택)

PENDING_COMPLETED를 전역적으로 IN_REVIEWING으로 수정하였습니다.
StatisticsCategoryCard의 경우 본 이슈와는 상관없지만 사소한 수정이라 따로 이슈를 만들지 않고 바로 수정하였습니다

@seorang42 seorang42 added the 📬 API 서버 API 통신 label Feb 5, 2025
@seorang42 seorang42 self-assigned this Feb 5, 2025
@seorang42 seorang42 changed the title CLAP-270 구분 컴포넌트 구현 CLAP-270 TaskCard의 라벨 컴포넌트 제작 Feb 5, 2025
const { data } = useQuery<StatisticsData[]>({
queryKey: [statisticsType, periodType],
queryKey: computed(() => [statisticsType, periodType]),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

기존의 경우엔 statisticsType, periodType이 바뀌어도 새로운 요청이 가지 않는건가요?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

StatisticsCard의 경우 사실 기존의 코드도 정상적으로 작동했습니다.
statisticsType의 경우 애초에 변하지 않으며 periodType는 변해도 일단은 정상적으로 작동했지만,
StatisticsCategoryCard에서 해당 부분에서 변화를 감지하지 못 해 문제가 생겼다보니,
이후 혹시 모를 오작동에 대비해 동일하게 computed로 감싸주게 되었습니다.

비효율적일 수도 있지만, computed를 하나 사용하여 떨어지는 성능보다
혹시 모를 오작동을 사전에 방지하는 것이 더 큰 return 이라고 생각하여 함께 추가해두었습니다.

Copy link
Contributor

@Minkyu0424 Minkyu0424 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@seorang42 seorang42 merged commit a29154e into develop Feb 5, 2025
1 check passed
@seorang42 seorang42 deleted the CLAP-270 branch February 5, 2025 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

📬 API 서버 API 통신

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CLAP-270 TaskCard의 라벨 컴포넌트 제작

3 participants