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

[SKRB-148] feat: 행사 생성 API 틀 구현 #8

Merged
merged 4 commits into from
Oct 25, 2023
Merged

Conversation

hyeon-z
Copy link
Collaborator

@hyeon-z hyeon-z commented Oct 24, 2023

💠 Jira 티켓 링크

🖥️ 작업 내용

  • 행사 생성 repository, service, controller 틀 구현

✅ PR시 확인 사항

  • 테스트 코드 작성
  • Linear History 여부

📢 리뷰어 전달 사항

틀 구현을 위해 임시로 넣은 값

  • controllerLocation
  • CreateEventRequest의 파라미터, toEntity 메서드
  • Event 엔티티의 기본 생성자

@hyeon-z hyeon-z added the FEAT feature label Oct 24, 2023
@hyeon-z hyeon-z self-assigned this Oct 24, 2023
Copy link
Member

@juno-junho juno-junho left a comment

Choose a reason for hiding this comment

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

커멘트 한번 확인해주세요 👍


import com.spaceclub.event.domain.Event;

public record CreateEventRequest(Long id) {
Copy link
Member

Choose a reason for hiding this comment

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

dto를 뽑아야 api 명세가 나오지 않나요?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

api틀 만든 PR 후 명세 관련 작업 커밋할 예정입니다! (DTO, controller 테스트)


@Service
@RequiredArgsConstructor
public class EventService {
Copy link
Member

Choose a reason for hiding this comment

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

서비스 인터페이스로 만들어 놓고 빠르게 api 명세 뽑아도 좋을것 같아요

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

서비스를 mock으로 테스트할 예정이라 class로 만들었습니다!

@juno-junho
Copy link
Member

PR 제목 컨벤션 한번 확인해 주세요 feat이 빠졌어요

@hyeon-z hyeon-z changed the title [SKRB-148] 행사 생성 API 틀 구현 [SKRB-148] feat: 행사 생성 API 틀 구현 Oct 24, 2023
Copy link
Member

@choi5798 choi5798 left a comment

Choose a reason for hiding this comment

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

컨벤션 관련된 변경사항만 수정하면 될 것 같습니다~

private final EventService eventService;

@PostMapping
public ResponseEntity<Void> saveEvent(@RequestBody CreateEventRequest request) {
Copy link
Member

Choose a reason for hiding this comment

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

저희 컨트롤러, 서비스에서 생성 관련 메소드는 create로 시작하기로 컨벤션 정했어요

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

EventController내의 메서드명이라 Event를 때고 create로 변경했습니다.
chore: controller 메서드 명 create으로 변경

import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

@Entity
@NoArgsConstructor(access = AccessLevel.PROTECTED)
//@NoArgsConstructor(access = AccessLevel.PROTECTED)
Copy link
Member

Choose a reason for hiding this comment

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

특별한 의미를 나타내지 않는 주석은 지워도 될 것 같아요

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

API 틀을 만들기 위해 임시로 변경한 부분이라 주석처리 했습니다.

@hyeon-z hyeon-z requested a review from choi5798 October 25, 2023 04:43
Copy link
Member

@choi5798 choi5798 left a comment

Choose a reason for hiding this comment

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

👍

@hyeon-z hyeon-z merged commit d2db373 into develop Oct 25, 2023
1 check passed
@hyeon-z hyeon-z deleted the feat/SKRB-148 branch October 25, 2023 05:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FEAT feature
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants