Aslee vor 3 Jahren
Ursprung
Commit
e0b0c1e371

+ 2 - 2
src/main/java/com/caimei/modules/order/service/NewOrderService.java

@@ -442,12 +442,12 @@ public class NewOrderService extends CrudService<NewOrderDao, NewOrder> {
                     for (NewOrderProduct orderProduct : shopOrder.getNewOrderProducts()) {
                         productName.append(orderProduct.getName());
                         // 没有折扣时促销才生效
-                        if (orderProduct.getDiscount() >= 100d) {
+                        if (orderProduct.getDiscount() >= 100d && !onlinePay) {
                             if (null != promotionsList && promotionsList.size() > 0) {
                                 for (CmPromotion promotion : promotionsList) {
                                     if ("3".equals(promotion.getType())) {
                                         shopOrder.setOrderPromotionsId(orderProduct.getOrderPromotionsId());
-                                        if ("2".equals(promotion.getMode()) && !onlinePay) {
+                                        if ("2".equals(promotion.getMode())) {
                                             promotionsTouchPrice = promotion.getTouchPrice();
                                             promotionsReducedPrice = promotion.getReducedPrice();
                                             shopTouchPrice += (orderProduct.getNum() * orderProduct.getPrice());

+ 2 - 2
src/main/java/com/caimei/modules/order/service/SplitAccountService.java

@@ -286,7 +286,7 @@ public class SplitAccountService extends BaseService {
         return list;
     }
 
-    public static <T> T postForm(Map<String, String> params, String url, String sign, Class<T> clazz) {
+    public <T> T postForm(Map<String, String> params, String url, String sign, Class<T> clazz) {
         FormBody.Builder builder = new FormBody.Builder();
         for (Map.Entry<String, String> entry : params.entrySet()) {
             builder.add(entry.getKey(), entry.getValue());
@@ -328,7 +328,7 @@ public class SplitAccountService extends BaseService {
         return res.toJavaObject(clazz);
     }
 
-    public static Map<String, String> convertBean(Object bean) {
+    public Map<String, String> convertBean(Object bean) {
         Class clazz = bean.getClass();
         Field[] fields = clazz.getDeclaredFields();
         for (Field f : fields) {

+ 2 - 2
src/main/java/com/caimei/modules/order/utils/OrderUtil.java

@@ -146,11 +146,11 @@ public class OrderUtil {
         double svipShopReduction = 0d;
         for (NewOrderProduct o : orderProducts) {
             // 没有折扣时促销才生效
-            if (o.getDiscount() == 100d) {
+            if (o.getDiscount() == 100d && !onlinePay) {
                 for (CmPromotion promotion : promotionsList) {
                     if ("3".equals(promotion.getType())) {
                         shopOrder.setOrderPromotionsId(o.getOrderPromotionsId());
-                        if ("2".equals(promotion.getMode()) && !onlinePay) {
+                        if ("2".equals(promotion.getMode())) {
                             promotionsTouchPrice = promotion.getTouchPrice();
                             promotionsReducedPrice = promotion.getReducedPrice();
                             shopTouchPrice += (o.getNum() * o.getPrice());