Commit 255f2d8cbfa82197e92c446d9aac3f60b482c8c4
1 parent
5acfd68a
modify builder name
Showing
2 changed files
with
8 additions
and
8 deletions
src/main/java/com/diligrp/xtrade/order/domain/builder/OrderResponseBuilder.java renamed to src/main/java/com/diligrp/xtrade/order/domain/builder/OrderDataBuilder.java
src/main/java/com/diligrp/xtrade/order/service/impl/OrderServiceImpl.java
... | ... | @@ -12,7 +12,7 @@ import org.springframework.transaction.annotation.Transactional; |
12 | 12 | import com.diligrp.xtrade.order.dao.OrderDao; |
13 | 13 | import com.diligrp.xtrade.order.dao.OrderItemDao; |
14 | 14 | import com.diligrp.xtrade.order.domain.builder.DefaultOrderCreator; |
15 | -import com.diligrp.xtrade.order.domain.builder.OrderResponseBuilder; | |
15 | +import com.diligrp.xtrade.order.domain.builder.OrderDataBuilder; | |
16 | 16 | import com.diligrp.xtrade.order.domain.dto.AccountDto; |
17 | 17 | import com.diligrp.xtrade.order.domain.dto.OrderCreateRequestDto; |
18 | 18 | import com.diligrp.xtrade.order.domain.dto.OrderItemDto; |
... | ... | @@ -44,13 +44,13 @@ public class OrderServiceImpl implements OrderService { |
44 | 44 | @Transactional(rollbackFor = Exception.class) |
45 | 45 | public void createOrder(OrderCreateRequestDto orderCreateDto) { |
46 | 46 | |
47 | - //获取相关信息 | |
47 | + // 获取相关信息 | |
48 | 48 | AccountDto saccountDto = accountResolver.getAccount(orderCreateDto.getSaccount()); |
49 | 49 | |
50 | - //构建订单创建者 | |
50 | + // 构建订单创建者 | |
51 | 51 | DefaultOrderCreator orderCreator = DefaultOrderCreator.builder(saccountDto, orderCreateDto, getOrderKey()); |
52 | 52 | |
53 | - //初始化订单基本信息 | |
53 | + // 初始化订单基本信息 | |
54 | 54 | orderCreator.initializeOrderBaseData(); |
55 | 55 | |
56 | 56 | // 订单详情数据封装 |
... | ... | @@ -58,10 +58,10 @@ public class OrderServiceImpl implements OrderService { |
58 | 58 | orderCreator.initializeItemData(getOrderItemKey(), orderItemDto); |
59 | 59 | } |
60 | 60 | |
61 | - //批量插入订单详情 | |
61 | + // 批量插入订单详情 | |
62 | 62 | orderItemDao.insertBatch(orderCreator.createOrderItems()); |
63 | 63 | |
64 | - //插入订单信息 | |
64 | + // 插入订单信息 | |
65 | 65 | orderDao.insertEntity(orderCreator.createOrder()); |
66 | 66 | } |
67 | 67 | |
... | ... | @@ -83,7 +83,7 @@ public class OrderServiceImpl implements OrderService { |
83 | 83 | // TODO need modify because of change |
84 | 84 | @Override |
85 | 85 | public OrderQueryResponseDto orderDetail(Long orderId) { |
86 | - OrderQueryResponseDto orderQueryResponseDto = OrderResponseBuilder | |
86 | + OrderQueryResponseDto orderQueryResponseDto = OrderDataBuilder | |
87 | 87 | .buildOrderDetail(orderDao.selectEntityByOrderId(orderId), orderItemDao.selectItemsByOrderId(orderId)); |
88 | 88 | return orderQueryResponseDto; |
89 | 89 | } | ... | ... |