Skip to content

Commit

Permalink
리뷰 반영
Browse files Browse the repository at this point in the history
  • Loading branch information
punkryn committed Jun 14, 2024
1 parent aca75e9 commit db66ccb
Show file tree
Hide file tree
Showing 7 changed files with 2 additions and 34 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,6 @@ public class PostTicketingRequestDto {
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy-MM-dd'T'HH:mm:ss", timezone = "Asia/Seoul")
private final LocalDateTime saleEnd;

@NotNull
private final List<CreateTicketMetadata> tickets;

@Builder
public PostTicketingRequestDto(
@NotBlank String title,
Expand All @@ -58,8 +55,7 @@ public PostTicketingRequestDto(
@NotNull Integer runningMinutes,
@NotNull LocalDateTime eventTime,
@NotNull LocalDateTime saleStart,
@NotNull LocalDateTime saleEnd,
@NotNull List<CreateTicketMetadata> tickets) {
@NotNull LocalDateTime saleEnd) {
this.title = title;
this.description = description;
this.location = location;
Expand All @@ -68,7 +64,6 @@ public PostTicketingRequestDto(
this.eventTime = eventTime;
this.saleStart = saleStart;
this.saleEnd = saleEnd;
this.tickets = tickets;
}

public CreateTicketingCommandDto convertToDto(String memberEmail, MultipartFile thumbnail) {
Expand All @@ -83,7 +78,6 @@ public CreateTicketingCommandDto convertToDto(String memberEmail, MultipartFile
.eventTime(eventTime)
.saleStart(saleStart)
.saleEnd(saleEnd)
.tickets(tickets)
.build();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@ public class CreateTicketingCommandDto {
private final LocalDateTime saleEnd;
private final MultipartFile thumbnail;
private LocalDateTime commandCreatedAt = LocalDateTime.now();
private final List<CreateTicketMetadata> tickets;

@Builder
public CreateTicketingCommandDto(
Expand All @@ -38,8 +37,7 @@ public CreateTicketingCommandDto(
MultipartFile thumbnail,
LocalDateTime eventTime,
LocalDateTime saleStart,
LocalDateTime saleEnd, LocalDateTime commandCreatedAt,
List<CreateTicketMetadata> tickets) {
LocalDateTime saleEnd, LocalDateTime commandCreatedAt) {
this.memberEmail = memberEmail;
this.title = title;
this.description = description;
Expand All @@ -53,6 +51,5 @@ public CreateTicketingCommandDto(
if (commandCreatedAt != null) {
this.commandCreatedAt = commandCreatedAt;
}
this.tickets = tickets;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,6 @@ void postTicketingSuccess() throws Exception {
.eventTime(now.plusYears(3))
.saleStart(now.plusYears(1))
.saleEnd(now.plusYears(2))
.tickets(Arrays.asList(
new CreateTicketMetadata(10, 10, "Gold", "", 2000),
new CreateTicketMetadata(10, 10, "Silver", "", 1000)
))
.build();
var content = objectMapper.writeValueAsString(req);

Expand Down Expand Up @@ -344,10 +340,6 @@ private CreateTicketingCommandDto createCreateTicketingCommand(String email, Str
.saleStart(now.plusYears(1))
.saleEnd(now.plusYears(2))
.eventTime(now.plusYears(3))
.tickets(Arrays.asList(
new CreateTicketMetadata(10, 10, "Gold", "", 2000),
new CreateTicketMetadata(10, 10, "Silver", "", 1000)
))
.build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,6 @@ private CreateTicketingCommandDto createTicketingCommand(String email, LocalDate
.saleStart(saleStart)
.saleEnd(saleEnd)
.thumbnail(thumbnail)
.tickets(tickets)
.build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,6 @@ void deleteTicketingSuccess() {
Assertions.assertThat(ticketingOpt.isPresent()).isTrue();

var ticketing = ticketingOpt.get();
Assertions.assertThat(ticketRepository.findAllByTicketing(ticketing).size())
.isEqualTo(createTicketingCommand.getTickets().size());

var deleteTicketingCommand = DeleteTicketingCommandDto.builder()
.ticketingId(ticketingId)
Expand Down Expand Up @@ -164,10 +162,6 @@ private CreateTicketingCommandDto createTicketingCommand(String email, LocalDate
.eventTime(eventTime)
.saleStart(saleStart)
.saleEnd(saleEnd)
.tickets(Arrays.asList(
new CreateTicketMetadata(10, 10, "Gold", "", 2000),
new CreateTicketMetadata(10, 10, "Silver", "", 1000)
))
.build();
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -326,10 +326,6 @@ private CreateTicketingCommandDto createTicketingCommand(String email, LocalDate
.eventTime(eventTime)
.saleStart(saleStart)
.saleEnd(saleEnd)
.tickets(Arrays.asList(
new CreateTicketMetadata(10, 10, "Gold", "", 2000),
new CreateTicketMetadata(10, 10, "Silver", "", 1000)
))
.build();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -154,10 +154,6 @@ private CreateTicketingResultDto createTicketing(String email, LocalDateTime sal
.location("")
.category("")
.description("")
.tickets(Arrays.asList(
new CreateTicketMetadata(10, 10, "Gold", "", 2000),
new CreateTicketMetadata(10, 10, "Silver", "", 1000)
))
.build();
return createTicketingUseCase.createTicketing(createTicketingCommandDto);
}
Expand Down

0 comments on commit db66ccb

Please sign in to comment.