feat: 订单明细增加商品冗余字段,保存完整商品信息
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -102,9 +102,15 @@ public class OrderServiceImpl implements OrderService {
|
||||
item.setItemId(UUID.randomUUID().toString());
|
||||
item.setOrderId(order.getOrderId());
|
||||
item.setProductId(product.getProductId());
|
||||
item.setCategoryId(product.getCategoryId());
|
||||
item.setProductName(product.getName());
|
||||
item.setProductSpec(product.getSpec());
|
||||
item.setUnit(product.getUnit());
|
||||
item.setCostPrice(product.getCostPrice());
|
||||
item.setImageUrl(product.getImageUrl());
|
||||
item.setBarcode(product.getBarcode());
|
||||
item.setStockAlert(product.getStockAlert());
|
||||
item.setDescription(product.getDescription());
|
||||
item.setPrice(price);
|
||||
item.setQuantity(itemDTO.getQuantity());
|
||||
item.setSubtotal(subtotal);
|
||||
@@ -347,9 +353,15 @@ public class OrderServiceImpl implements OrderService {
|
||||
item.setItemId(UUID.randomUUID().toString());
|
||||
item.setOrderId(orderId);
|
||||
item.setProductId(product.getProductId());
|
||||
item.setCategoryId(product.getCategoryId());
|
||||
item.setProductName(product.getName());
|
||||
item.setProductSpec(product.getSpec());
|
||||
item.setUnit(product.getUnit());
|
||||
item.setCostPrice(product.getCostPrice());
|
||||
item.setImageUrl(product.getImageUrl());
|
||||
item.setBarcode(product.getBarcode());
|
||||
item.setStockAlert(product.getStockAlert());
|
||||
item.setDescription(product.getDescription());
|
||||
item.setPrice(price);
|
||||
item.setQuantity(itemDTO.getQuantity());
|
||||
item.setSubtotal(subtotal);
|
||||
|
||||
Reference in New Issue
Block a user