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 : 티켓 상품 생성 #164

Merged
merged 7 commits into from
Jan 20, 2023
Merged

feat : 티켓 상품 생성 #164

merged 7 commits into from
Jan 20, 2023

Conversation

kim-wonjin
Copy link
Member

개요

작업사항

  • 티켓 상품 생성 로직

변경로직

@Schema(nullable = false, example = "1")
private Long purchaseLimit;

public TicketItem toEntity(Event event) {
Copy link
Member

Choose a reason for hiding this comment

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

저도 처음에 request dto에 넣었었는데 mapper 만들어서 거기서 빌더쓰는 게 좀 더 깔끔해 보이는 것 같아요.
리팩토링하면 mapper로 옮기려구요.

Copy link
Member Author

Choose a reason for hiding this comment

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

오케이 저두 리펙해보겠슴다

Copy link
Member

@ImNM ImNM left a comment

Choose a reason for hiding this comment

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

굿임니다요~

@SecurityRequirement(name = "access-token")
@Tag(name = "티켓 상품 관련 컨트롤러")
@RestController
@RequestMapping("/v1/ticket_items")
Copy link
Member

Choose a reason for hiding this comment

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

ticketItems 로 해유!
저희 이렇게 컨벤션 자연스래? 맞춰진것같아요

Copy link
Member Author

Choose a reason for hiding this comment

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

뉑뉑

Comment on lines 36 to 43
hostService.hasHostUser(host, user.getId());
// 호스트 제휴 여부에 따른 가격 체크
if (!host.getPartner()) {
ticketItemService.checkTicketPrice(Money.wons(createTicketItemRequest.getPrice()));
}
TicketItem ticketItem =
ticketItemService.createTicketItem(createTicketItemRequest.toEntity(event));
return CreateTicketItemResponse.from(ticketItem);
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
Member

@cofls6581 cofls6581 left a comment

Choose a reason for hiding this comment

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

수고하셨습니다!

@sonarqubecloud
Copy link

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 198 Code Smells

4.9% 4.9% Coverage
1.3% 1.3% Duplication

@kim-wonjin kim-wonjin merged commit fcc9fcd into dev Jan 20, 2023
@kim-wonjin kim-wonjin deleted the feature/100-create-ticket-item branch January 20, 2023 18:24
@kim-wonjin kim-wonjin changed the title feat 티켓 상품 생성 feat : 티켓 상품 생성 Jan 30, 2023
@kim-wonjin kim-wonjin added For: API [이슈 대상] 외부 API Type: Feature [이슈 목적] 새로운 기능 추가 labels Jan 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
For: API [이슈 대상] 외부 API Type: Feature [이슈 목적] 새로운 기능 추가
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🚀 [feature] 티켓 상품 생성하기
3 participants