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: 공연 회차 시간 관련 검증 로직 구현 #216

Merged
merged 3 commits into from
Jan 11, 2024
Merged

Conversation

park0jae
Copy link
Member

구현 기능

  • 공연 회차 시간 관련 검증 로직 구현

기능 상세

  • startedAt 이 > endedAt 인 경우 검증
  • bookingStartedAt 이 > bookingEndedAt 인 경우 검증
  • 회차가 다르나, 공연 상영 시간이 같은 케이스 검증
image

resolve: #211

@park0jae park0jae added feature 기능 event 공연 labels Jan 11, 2024
@park0jae park0jae self-assigned this Jan 11, 2024
public Boolean isAlreadyExistEventPlayTime(LocalDateTime startedAt, LocalDateTime endedAt, Long eventId) {
BooleanExpression query = event.id.eq(eventId)
.and(eventTime.startedAt.lt(endedAt))
.and(eventTime.endedAt.gt(startedAt));
Copy link
Member

Choose a reason for hiding this comment

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

쿼리 굳 👍

@KarmaPol KarmaPol merged commit 1a1bbc3 into main Jan 11, 2024
1 check passed
@park0jae park0jae deleted the event/211 branch January 11, 2024 02:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
event 공연 feature 기능
Projects
No open projects
Status: Done
Development

Successfully merging this pull request may close these issues.

feat: 공연 회차 시간 관련 검증 로직 구현
2 participants