From 2e08d6d4c0710d3e535b5944faa9df4af828c0f7 Mon Sep 17 00:00:00 2001
From: xiaoyong931011 <15274802129@163.com>
Date: Tue, 02 Nov 2021 10:54:52 +0800
Subject: [PATCH] Merge branch 'score_shop' of http://120.27.238.55:7000/r/beauty-erp into score_shop

---
 zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/ShoppingCartService.java |   14 ++++++++++----
 1 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/ShoppingCartService.java b/zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/ShoppingCartService.java
index 3cf7afd..aed6be7 100644
--- a/zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/ShoppingCartService.java
+++ b/zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/ShoppingCartService.java
@@ -1,6 +1,6 @@
 package com.matrix.system.shopXcx.api.service;
 
-import com.matrix.component.redis.RedisUserLoginUtils;
+import com.matrix.system.common.init.UserCacheManager;
 import com.matrix.core.tools.LogUtil;
 import com.matrix.system.common.dao.BusParameterSettingsDao;
 import com.matrix.system.shopXcx.api.vo.ShopCartBillVo;
@@ -21,7 +21,7 @@
     @Autowired
     private ShopShoppingCartDao shoppingCartDao;
     @Autowired
-    private RedisUserLoginUtils redisUserLoginUtils;
+    private UserCacheManager userCacheManager;
 
     @Autowired
     WxShopCouponService shopCouponService;
@@ -256,8 +256,14 @@
         for (ShopShoppingCart shopShoppingCart : cartList) {
             sum = sum.add(shopShoppingCart.getPrice().multiply(BigDecimal.valueOf(shopShoppingCart.getCartNumber())));
             if (shopShoppingCart.getIsSelected() == 1) {
-                selectSum = selectSum
-                        .add(shopShoppingCart.getPrice().multiply(BigDecimal.valueOf(shopShoppingCart.getCartNumber())));
+                if(shopShoppingCart.getCartType()==ShopShoppingCart.CAR_TYPE_MICRO){
+                    selectSum = selectSum
+                            .add(shopShoppingCart.getPrice().multiply(BigDecimal.valueOf(shopShoppingCart.getCartNumber())));
+                }else {
+                    selectSum = selectSum
+                            .add(shopShoppingCart.getScorePrice().multiply(BigDecimal.valueOf(shopShoppingCart.getCartNumber())));
+                }
+
             }
         }
 

--
Gitblit v1.9.1