Open
Conversation
hyunssooo
requested changes
Sep 25, 2023
Comment on lines
+23
to
+25
|
|
||
| private UUID menuId; | ||
|
|
There was a problem hiding this comment.
menuId 로 간접참조 하고 있는데요. 이 경우 Menu 의 가격이 변경된다면 예전 주문을 확인할 때 변경된 가격을 노출시켜주는 걸까요?
Comment on lines
+38
to
+46
| public List<UUID> getMenuIds() { | ||
| return orderLineItems.stream().map(TobeOrderLineItem::getMenuId).collect(Collectors.toList()); | ||
| } | ||
|
|
||
| public void validation(final int size) { | ||
| if (orderLineItems.size() != size) { | ||
| throw new IllegalArgumentException(); | ||
| } | ||
| } |
Comment on lines
+6
to
+10
|
|
||
| public class OrderMenu { | ||
| private final UUID id; | ||
| private final boolean displayed; | ||
| private final BigDecimal menuPrice; |
There was a problem hiding this comment.
Order BC 내에 Menu 정의 👍
각 컨텍스트마다 Menu는 다른 의미를 가지는데요. 이 부분은 문서도 수정해 보면 좋을 것 같습니다.
OrderMenu는 따로 DB에 저장될 필요는 없을까요?
Comment on lines
+8
to
+12
|
|
||
| @Table(name = "order_table") | ||
| @Entity | ||
| public class TobeOrderTable { | ||
| @Column(name = "id", columnDefinition = "binary(16)") |
There was a problem hiding this comment.
orderTable은 따로 리팩터링 하지 않은 이유가 있으신가요?
패키지도 신경써보면 좋을 것 같아요. application layer로 보이네요.
Comment on lines
+44
to
+47
|
|
||
| public void setId(final UUID id) { | ||
| this.id = id; | ||
| } |
Comment on lines
+26
to
+28
| @Transient | ||
| private BigDecimal price; | ||
|
|
Comment on lines
+71
to
+82
|
|
||
| // public static TobeOrder order(final OrderStatus status) { | ||
| // final TobeOrder order = new TobeOrder(UUID.randomUUID(), status, LocalDateTime.of(2020, 1, 1, 12, 0), | ||
| // | ||
| // ); | ||
| // order.setId(UUID.randomUUID()); | ||
| // order.setType(OrderType.DELIVERY); | ||
| // order.setStatus(status); | ||
| // order.setOrderDateTime(); | ||
| // order.setOrderLineItems(Arrays.asList(orderLineItem())); | ||
| // return order; | ||
| // } |
Comment on lines
+13
to
+15
|
|
||
| public class InMemoryTobeOrderRepository implements TobeOrderRepository { | ||
| private final Map<UUID, TobeOrder> orders = new HashMap<>(); |
|
현재 어플리케이션 빌드가 실패하는데요. 이 부분도 확인되면 좋을 것 같아요. 🙂 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
마지막 미션 잘 부탁드립니다.