Skip to content
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

[Feature/user info get] 마이페이지 - 사용자 프로필 조회 API #63

Merged
merged 20 commits into from
Nov 25, 2023

Conversation

dldmsql
Copy link
Member

@dldmsql dldmsql commented Nov 22, 2023

작업 내용

마이페이지 - 사용자 프로필 조회 API

관련 이슈

#62

작업 확인 방법

{
  "localDateTime": "2023-11-22T23:28:10.969465",
  "message": "OK",
  "data": {
    "userId": 3,
    "nickName": "[email protected]",
    "profileImgUrl": "https://everymeal.s3.ap-northeast-2.amazonaws.com/1627667445.png",
    "universityName": "명지대학교"
  }
}

추가 정보 (선택 사항)

jpaRepository 대신 mybatis를 이용해서 필요한 정보만을 추출하도록 했습니다.

@dldmsql dldmsql added the Feature 기능 개발 label Nov 22, 2023
@dldmsql dldmsql self-assigned this Nov 22, 2023
Copy link
Member

@Qbeom0925 Qbeom0925 left a comment

Choose a reason for hiding this comment

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

고생하셨습니다!!

Comment on lines +9 to +14
return new UserProfileRes(
(Long) user.get("userId"),
(String) user.get("nickName"),
(String) user.get("profileImgUrl"),
(String) user.get("universityName"));
}
Copy link
Member

Choose a reason for hiding this comment

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

해당 방법도 좋지만, 생성자를 통해서 설정하는 거라면 ObjectMapper를 사용해보는 것도 시간을 많이 줄일 수 있습니다!!

UserProfileRes userProfileRes = objectMapper.convertValue(map, UserProfileRes.class);

Copy link
Member Author

Choose a reason for hiding this comment

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

오! 바로 반영하겠습니다 : )

@dldmsql
Copy link
Member Author

dldmsql commented Nov 25, 2023

CI 오류 해결 과정

  • 상황

application.yml 파일을 주입하지 못하는 오류 발생

  • 원인

base64로 인코딩이 안되어 있어서

  • 해결

settings > secrets > actions > 키 등록 시, base64로 인코딩된 값 넣기
디렉토리 찾아갈 수 있도록 mkdir -p src/test/resources 로 수정

참고

Copy link

sonarcloud bot commented Nov 25, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

@dldmsql dldmsql merged commit 010728e into develop Nov 25, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature 기능 개발
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants