...
|
...
|
@@ -12,6 +12,7 @@ import com.yohoufo.dal.order.SellerOrderGoodsViewMapper; |
|
|
import com.yohoufo.dal.order.model.SellerOrderGoods;
|
|
|
import com.yohoufo.order.event.SellerOrderPriceChangeEvent;
|
|
|
import com.yohoufo.order.service.proxy.InBoxFacade;
|
|
|
import com.yohoufo.order.utils.OrderAssist;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.LoggerFactory;
|
...
|
...
|
@@ -68,7 +69,8 @@ public class SellerOrderPriceChangeHandler implements IEventHandler<SellerOrderP |
|
|
//根据storageId获取所有在售的卖家的订单
|
|
|
List<SellerOrderGoods> noticeList= sellerOrderGoodsViewMapper.selectCanSellByStorageId(storageId);
|
|
|
//把自己过滤掉,只保留价格高于当前价格
|
|
|
noticeList = noticeList.stream().filter(r->r.getGoodsPrice().compareTo(changedPrice)>0&&changedSellerUid!=r.getUid().intValue()).collect(Collectors.toList());
|
|
|
//非预售的订单才push
|
|
|
noticeList = noticeList.stream().filter(r-> !OrderAssist.skupIsAdvance(r.getAttributes())&&r.getGoodsPrice().compareTo(changedPrice)>0&&changedSellerUid!=r.getUid().intValue()).collect(Collectors.toList());
|
|
|
if(CollectionUtils.isEmpty(noticeList)){
|
|
|
logger.warn("Subscribe SellerOrderPriceChangeEvent msg return SellerOrderGoods with empty same storage id , event {} ,sog {}", event,sog);
|
|
|
return ;
|
...
|
...
|
|