diff --git a/skyeye-shop/shop-store/src/main/java/com/skyeye/coupon/service/impl/CouponUseServiceImpl.java b/skyeye-shop/shop-store/src/main/java/com/skyeye/coupon/service/impl/CouponUseServiceImpl.java index 8d716dce..e786376d 100644 --- a/skyeye-shop/shop-store/src/main/java/com/skyeye/coupon/service/impl/CouponUseServiceImpl.java +++ b/skyeye-shop/shop-store/src/main/java/com/skyeye/coupon/service/impl/CouponUseServiceImpl.java @@ -44,6 +44,7 @@ import java.util.List; import java.util.Map; import java.util.Objects; import java.util.stream.Collectors; +import java.util.stream.Stream; /** * @ClassName: CouponUseServiceImpl @@ -202,7 +203,11 @@ public class CouponUseServiceImpl extends SkyeyeBusinessServiceImpl list = list(queryWrapper); couponService.setDataMation(list, CouponUse::getCouponId); - return JSONUtil.toList(JSONUtil.toJsonStr(list), null); + List collect = list.stream().map(item -> { + item.setUsageCount(item.getUsedCount()); + return item; + }).collect(Collectors.toList()); + return JSONUtil.toList(JSONUtil.toJsonStr(collect), null); } @Override diff --git a/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderItemServiceImpl.java b/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderItemServiceImpl.java index cb2be349..ecd6eed7 100644 --- a/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderItemServiceImpl.java +++ b/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderItemServiceImpl.java @@ -156,7 +156,7 @@ public class OrderItemServiceImpl extends SkyeyeBusinessServiceImpl updateWrapper = new UpdateWrapper<>(); diff --git a/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderServiceImpl.java b/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderServiceImpl.java index 5a0cf37c..a7f92b5d 100644 --- a/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderServiceImpl.java +++ b/skyeye-shop/shop-store/src/main/java/com/skyeye/order/service/impl/OrderServiceImpl.java @@ -598,7 +598,7 @@ public class OrderServiceImpl extends SkyeyeBusinessServiceImpl boolean allTwo = orderItemList.stream().map(OrderItem::getOrderItemState) .allMatch(orderItemState -> orderItemState == ShopOrderItemState.FINISHED.getKey()); if (allTwo) { - updateOrderState(orderId, ShopOrderState.COMPLETED.getKey()); + updateOrderState(orderId, ShopOrderState.SIGN.getKey()); } else { updateOrderState(orderId, ShopOrderState.PARTIALLYDONE.getKey()); }