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

Swagger 업데이트 (에러코드 추가 및 글자 형식 변경) #1046

Open
wants to merge 8 commits into
base: dev/be
Choose a base branch
from

Conversation

kyum-q
Copy link
Contributor

@kyum-q kyum-q commented Feb 2, 2025

⚡️ 관련 이슈

close #1030

📍주요 변경 사항

image

  • swagger 에러 케이스에 에러 코드 추가
    • 사진처럼 swagger 에러케이스 보면 에러 코드도 적절한 것으로 보이게끔 함
  • 전반적인 swagger 확인
  • swagger 메시지 형태 명사구로 변경
  • validationService.validateOrdinal(member, request); 가 무슨 역할인지 몰라서 제거했어요

🎸기타

고려해야 하는 내용을 작성해 주세요.

  • swagger 변경이니 프론트도 리뷰 요청보내요~
  • 제가 리뷰 확인하는 시간도 있으니 7일까지 여유롭게 기한 두었습니다~
    • 되는 사람들만 확인해주세요
  • 이전 pr과 conflict가 계속 날 것 같아서 이전 pr들 되고 머지하는게 좋을 것 같기도 합니다~

🍗 PR 첫 리뷰 마감 기한

02/07

@kyum-q kyum-q added refactor 요구사항이 바뀌지 않은 변경사항 BE 백엔드 labels Feb 2, 2025
@kyum-q kyum-q added this to the 7차 스프린트 💭 milestone Feb 2, 2025
@kyum-q kyum-q self-assigned this Feb 2, 2025
@kyum-q kyum-q changed the base branch from main to dev/be February 2, 2025 01:59
@Size(min = 8, max = 255, message = "비밀번호는 8~16자 사이로 입력해주세요.")
@Size(min = 8, max = 16, message = "비밀번호는 8~16자 사이로 입력해주세요.")
Copy link
Contributor

Choose a reason for hiding this comment

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

ㅋㅋㅋㅋㅋㅋ

Comment on lines +56 to +64
@ErrorCase(description = "입력 없는 필드 존재", exampleMessage = "카테고리 이름이 null 입니다."),
@ErrorCase(description = "카테고리 이름 글자수 오류", exampleMessage = "카테고리 이름은 최대 15자까지 입력 가능합니다."),
@ErrorCase(description = "카테고리 순서 값 1 미만", exampleMessage = "카테고리의 순서는 1 이상이어야 합니다."),
@ErrorCase(description = "카테고리 순서 오류", exampleMessage = "순서가 잘못되었습니다."),
@ErrorCase(description = "기본 카테고리 수정 또는 삭제", errorCode = ErrorCode.DEFAULT_CATEGORY,
exampleMessage = "기본 카테고리는 수정 및 삭제할 수 없습니다."),
@ErrorCase(description = "삭제하려는 카테고리에 템플릿이 존재", errorCode = ErrorCode.CATEGORY_HAS_TEMPLATES,
exampleMessage = "템플릿이 존재하는 카테고리는 삭제할 수 없습니다."),
@ErrorCase(description = "카테고리 개수가 일치하지 않음(수정되지 않은 카테고리도 모두 보내주어야 합니다.)",
Copy link
Contributor

Choose a reason for hiding this comment

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

에러코드 있는 애와 없는 애의 차이가 무엇인가요?!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

매번 에러코드를 입력하는 것이 불편할 것 같아서 default 로 errorCode를 설정하지 않은 것들은 1101 번으로 자동 설정해놨습니다~!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
BE 백엔드 refactor 요구사항이 바뀌지 않은 변경사항
Projects
Status: Todo
Development

Successfully merging this pull request may close these issues.

[REFACTOR] Swagger 최신화
3 participants