Skip to content

feat: 5주차 미션_우가#38

Open
sua710 wants to merge 7 commits into
mainfrom
wooga-m5
Open

feat: 5주차 미션_우가#38
sua710 wants to merge 7 commits into
mainfrom
wooga-m5

Conversation

@sua710
Copy link
Copy Markdown
Collaborator

@sua710 sua710 commented Apr 29, 2026

📌 PR 제목

feat: 5주차 미션_우가
feat: 마이페이지 API 연동

🔗 관련 이슈

Closes #이슈번호

✨ 변경 사항

  • ReqRes API를 활용한 마이페이지 유저 정보 조회 기능 추가
  • Retrofit, Gson Converter, OkHttp LoggingInterceptor 설정 추가
  • x-api-key 헤더 자동 추가를 위한 AuthenticationInterceptor 구현
  • userId = 1 유저의 프로필 이미지, 닉네임 표시 기능 구현
  • 팔로잉 유저 리스트 RecyclerView 구현
  • 팔로잉 리스트에 ListAdapter + DiffUtil 적용
  • 마이페이지 UI 구현 및 프로필 메뉴 순서 수정
  • 네트워크 실패 시 오류 메시지 표시 처리

🔍 테스트

  • 테스트 완료
  • 에러 없음
  • ReqRes API key 적용 확인

📸 스크린샷 (선택)

마이페이지
Screenshot_20260429_105454

🚨 추가 이슈

Comment on lines +53 to +62
<Button
android:id="@+id/btnEditProfile"
android:layout_width="180dp"
android:layout_height="52dp"
android:layout_marginTop="26dp"
android:background="@drawable/profile_outline_button_bg"
android:backgroundTint="@android:color/transparent"
android:text="프로필 수정"
android:textColor="#111111"
android:textSize="14sp" />
Copy link
Copy Markdown
Collaborator

@Lemon0610 Lemon0610 Apr 29, 2026

Choose a reason for hiding this comment

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

버튼 글씨가 안 보여요...!

Copy link
Copy Markdown
Collaborator

@jeongkyueun jeongkyueun left a comment

Choose a reason for hiding this comment

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

공통 인터셉터(AuthenticationInterceptor)를 통해 x-api-key를 자동화하신 부분 좋네요!

android:id="@+id/menu_profile"
android:icon="@drawable/ic_user"
android:title="프로필" />

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

여기 회원가입 구현이 없어요

Copy link
Copy Markdown
Collaborator

@kimdoyeon1234 kimdoyeon1234 left a comment

Choose a reason for hiding this comment

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

수고하셨습니다! 이번 PR에서 구조적 완성도가 높았습니다!

다음에 개선하면 좋을 점

  • API 키를 BuildConfig로 분리하고 로깅은 디버그 빌드에서만 켜주세요
  • ProductGridAdapter와 HomeProductAdapter를 ListAdapter + DiffUtil로 개선하면 더 좋아요
  • 더미 데이터 이미지를 상품별로 다르게 넣어주면 UI 확인이 편합니다 🙂

그리고 파일 이름 week5 같이 week로 통일해주세요! 제가 찾기 편하게 ㅎㅎ 수고하셨습니다

Comment on lines +11 to +15
private const val API_KEY = "reqres_4b7b1e3a525043a4b967f4b1085f63ff"

private val loggingInterceptor = HttpLoggingInterceptor().apply {
level = HttpLoggingInterceptor.Level.BODY
}
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

API 키 하드코딩은 local.properties + BuildConfig로 분리해주세요! 로깅도 디버그 빌드에서만 켜도록 수정하면 좋아요

Comment on lines +78 to +92
private fun Product.toUiModel(isLiked: Boolean): ProductUiModel {
return ProductUiModel(
id = id,
name = name,
description = description,
price = price,
imageResId = imageResId,
colorCount = colorCount,
isBestSeller = isBestSeller,
isLiked = isLiked,
category = category,
isNew = isNew
)
}
} No newline at end of file
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Product와 ProductUiModel이 필드가 거의 동일해요. 지금은 학습 단계라 괜찮지만, 실제 프로젝트에서는 서버에서 오는 데이터 모델과 UI 모델이 다를 때 분리하는 게 의미 있습니다! 지금처럼 로컬 더미 데이터만 쓴다면 굳이 두 개로 나누지 않아도 됩니다!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants