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

feat: 경험 목록 조회 API 구현(#42) #111

Merged
merged 5 commits into from
May 20, 2024
Merged

Conversation

whereami2048
Copy link
Contributor

@whereami2048 whereami2048 commented May 20, 2024

✨ PR 유형

어떤 변경 사항이 있나요??

  • 새로운 기능 추가
  • 버그 수정
  • CSS 등 사용자 UI 디자인 변경
  • 코드에 영향을 주지 않는 변경사항(오타 수정, 탭 사이즈 변경, 변수명 변경)
  • 코드 리팩토링
  • 주석 추가 및 수정
  • 문서 수정
  • 테스트 추가, 테스트 리팩토링
  • 빌드 부분 혹은 패키지 매니저 수정
  • 파일 혹은 폴더명 수정
  • 파일 혹은 폴더 삭제

🛠️ 작업내용

경험 목록 조회 API 구현

📋 추후 진행 사항

경험 검색 API 구현

📌 리뷰 요청 사항

조회하는 방식이 현재 각 Reader들을 가져와서 경험 내부에 들어갈 DTO들을 만드는 방식인데, 뭔가 코드가 길어지고 반복되는 느낌! 이것도 리팩토링 필요...

@whereami2048 whereami2048 linked an issue May 20, 2024 that may be closed by this pull request
2 tasks
}
}

private fun createExperienceDetailResponse(it: Experience): DetailExperience.Response {
Copy link
Member

Choose a reason for hiding this comment

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

이거 it으로 표현하니까 직관적이지가 않은 거 같은데 네이밍 수정해줄래?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

반영 완료!

.let { ExperienceYear.Response(it) }
}

fun getExperienceByYearAndParentTag(year: Int, parentTagId: UUID): List<DetailExperience.Response> {
Copy link
Member

Choose a reason for hiding this comment

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

dto가 리스트일때는 dto로 한번 더 감싸는거 어때?

    data class Response(
        val applyContentList: List<ContentInfo>
    )

    data class ContentInfo(
        val question: String,
        val answer: String
    )

요런식으루

Copy link
Contributor Author

Choose a reason for hiding this comment

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

반영 완료~

@@ -18,6 +18,16 @@ class ExperienceController(
private val experienceEditService: ExperienceEditService,
private val experienceGetService: ExperienceGetService
) {
@GetMapping(ExperienceApi.BASE_URL)
fun getExperienceByFilter(@RequestParam("year") year: Int,
@RequestParam("parent-tag", required = false) parentTagId: UUID,
Copy link
Member

Choose a reason for hiding this comment

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

얘는 왜 ? 가 없나요오 그리구 ?연산자 사용하면 required = false 필요없긴 해

Copy link
Contributor Author

Choose a reason for hiding this comment

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

반영 와와안료!

@whereami2048 whereami2048 merged commit 51cd663 into develop May 20, 2024
1 check passed
@whereami2048 whereami2048 deleted the feat/flight-42 branch May 20, 2024 13:21
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.

경험 목록 조회 API 구현
2 participants