jyy
2021-03-09 62b534e96922a3911f61845753ee0d126bafd6e1
Merge branch 'api' into hive2.0
3 files modified
27 ■■■■■ changed files
zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/impl/WXShopOrderServiceImpl.java 10 ●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/impl/WxShopLogisticsQueryServiceImpl.java 13 ●●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/shopXcx/mqTask/OrderTask.java 4 ●●●● patch | view | raw | blame | history
zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/impl/WXShopOrderServiceImpl.java
@@ -3,10 +3,6 @@
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.matrix.biz.bean.BizUser;
import com.matrix.system.common.bean.BusParameterSettings;
import com.matrix.system.common.bean.CustomerDataDictionary;
import com.matrix.system.common.dao.BusParameterSettingsDao;
import com.matrix.system.common.dao.CustomerDataDictionaryDao;
import com.matrix.component.rabbitmq.RabiitMqTemplate;
import com.matrix.component.redis.RedisUserLoginUtils;
import com.matrix.component.tools.WxUtils;
@@ -16,7 +12,10 @@
import com.matrix.core.pojo.AjaxResult;
import com.matrix.core.tools.LogUtil;
import com.matrix.core.tools.StringUtils;
import com.matrix.system.common.bean.BusParameterSettings;
import com.matrix.system.common.constance.AppConstance;
import com.matrix.system.common.dao.BusParameterSettingsDao;
import com.matrix.system.common.dao.CustomerDataDictionaryDao;
import com.matrix.system.common.interceptor.HostInterceptor;
import com.matrix.system.constance.Dictionary;
import com.matrix.system.hive.bean.ShoppingGoods;
@@ -196,7 +195,8 @@
        ShopOrder shopOrder = new ShopOrder();
        shopOrder.setCompanyId(bizUser.getCompanyId());
        shopOrder.setStoreId(Integer.parseInt(addShopOrderPOJO.getShopId().toString()));
        shopOrder.setOrderType(ShopOrder.ORDER_TYPE_SERVICE);
        //默认设置为产品类型
        shopOrder.setOrderType(ShopOrder.ORDER_TYPE_GOODS);
        List<ShopOrderDetails> details = new ArrayList<>();
        Integer cartCount = 0;
zq-erp/src/main/java/com/matrix/system/shopXcx/api/service/impl/WxShopLogisticsQueryServiceImpl.java
@@ -1,20 +1,18 @@
package com.matrix.system.shopXcx.api.service.impl;
import com.alibaba.fastjson.JSON;
import com.matrix.core.constance.SystemErrorCode;
import com.matrix.component.tools.HttpCurlUtil;
import com.matrix.core.exception.GlobleException;
import com.matrix.core.pojo.AjaxResult;
import com.matrix.core.tools.LogUtil;
import com.matrix.core.tools.StringUtils;
import com.matrix.system.common.constance.AppConstance;
import com.matrix.system.shopXcx.api.service.WxShopLogisticsQueryService;
import com.matrix.system.shopXcx.api.vo.LogisticsInfoVo;
import com.matrix.system.shopXcx.bean.ShopDeliveryInfo;
import com.matrix.system.shopXcx.bean.ShopLogisticsInfo;
import com.matrix.system.shopXcx.dao.ShopDeliveryInfoDao;
import com.matrix.system.shopXcx.dao.ShopLogisticsInfoDao;
import com.matrix.component.tools.HttpCurlUtil;
import com.matrix.system.shopXcx.api.service.WxShopLogisticsQueryService;
import com.matrix.system.shopXcx.api.vo.LogisticsInfoVo;
import com.matrix.system.shopXcx.api.vo.SfLogisticsInfoVo;
import org.apache.commons.collections.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
@@ -145,12 +143,11 @@
                    }
                }
            } else {
                throw new GlobleException(SystemErrorCode.REQUEST_INVALID, logisticsInfoVo.getReason());
                throw new GlobleException(logisticsInfoVo.getReason());
            }
        } catch (Exception e) {
            LogUtil.error("物流信息查询失败", e);
            throw new GlobleException(SystemErrorCode.REQUEST_INVALID);
            throw new GlobleException("物流信息查询失败");
        }
        List<ShopLogisticsInfo> shopLogisticsInfos = shopLogisticsInfoDao.selectByDelieryId(shopDeliveryInfo.getId());
        result.setStatus(AjaxResult.STATUS_SUCCESS);
zq-erp/src/main/java/com/matrix/system/shopXcx/mqTask/OrderTask.java
@@ -3,6 +3,7 @@
import com.matrix.biz.bean.BizUser;
import com.matrix.biz.service.BizUserService;
import com.matrix.core.exception.GlobleException;
import com.matrix.core.tools.LogUtil;
import com.matrix.core.tools.StringUtils;
import com.matrix.system.common.constance.AppConstance;
@@ -26,7 +27,6 @@
import org.springframework.transaction.annotation.Transactional;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@@ -121,7 +121,7 @@
            ShopSku shopSku = shopSkuDao.selectById(orderItemDto.getsId());
            if (StringUtils.isBlank(shopSku.getStockCode())) {
                LogUtil.warn("销售产品未绑定erp中的产品,无法进行同步");
                throw new GlobleException("销售产品未绑定erp中的产品,无法进行同步");
            }
            String goodsCode =shopSku.getStockCode();