计算成本价问题
This commit is contained in:
@@ -320,7 +320,7 @@ public interface ShopOrderStatisticMapper extends BaseMapper<ShopOrderStatistic>
|
||||
" `order`.shop_id = #{shopId} " +
|
||||
" and trade_day = #{tradeDay} " +
|
||||
" and paid_time is not null" +
|
||||
" order by detail.product_id, detail.sku_id")
|
||||
" group by detail.product_id, detail.sku_id")
|
||||
List<ProductCostAmountVO> getOrderDetailProduct(Long shopId, LocalDate tradeDay);
|
||||
|
||||
}
|
||||
|
||||
@@ -226,7 +226,7 @@ public class ShopOrderStatisticServiceImpl extends ServiceImpl<ShopOrderStatisti
|
||||
*/
|
||||
private BigDecimal getProductCostAmount(Long shopId, LocalDate day) {
|
||||
BigDecimal productCostAmount = BigDecimal.ZERO;
|
||||
////获取orderDetail信息 productId skuId 数量
|
||||
//获取orderDetail信息 productId skuId 数量
|
||||
List<ProductCostAmountVO> orderDetailProduct = mapper.getOrderDetailProduct(shopId, day);
|
||||
orderDetailProduct = orderDetailProduct.stream()
|
||||
.filter(Objects::nonNull)
|
||||
|
||||
Reference in New Issue
Block a user