| | |
| | | import org.yeshi.utils.taobao.TbImgUtil; |
| | | |
| | | import com.aliyun.openservices.ons.api.Message; |
| | | import com.aliyun.openservices.ons.api.Producer; |
| | | import com.yeshi.fanli.dao.mybatis.order.CommonOrderGoodsMapper; |
| | | import com.yeshi.fanli.dao.mybatis.order.CommonOrderMapper; |
| | | import com.yeshi.fanli.dao.mybatis.order.CommonOrderTradeIdMapMapper; |
| | |
| | | import com.yeshi.fanli.service.inter.user.UserSystemCouponService; |
| | | import com.yeshi.fanli.service.inter.user.invite.UserInviteService; |
| | | import com.yeshi.fanli.service.inter.user.vip.UserVIPInfoService; |
| | | import com.yeshi.fanli.service.manger.msg.RocketMQManager; |
| | | import com.yeshi.fanli.service.manger.user.UserLevelManager; |
| | | import com.yeshi.fanli.util.Constant; |
| | | import com.yeshi.fanli.util.MoneyBigDecimalUtil; |
| | |
| | | @Resource |
| | | private TaoBaoOrderGoodsMapper taoBaoOrderGoodsMapper; |
| | | |
| | | @Resource(name = "producer") |
| | | private Producer orderProducer; |
| | | @Resource |
| | | private RocketMQManager rocketMQManager; |
| | | |
| | | // 奖励订单图片 |
| | | public final static String PIC_REWARD = "http://img.flqapp.com/resource/order/order_state_reward.png"; |
| | |
| | | settlement, firstOrder.getUserInfo().getId(), placeDate, new Date()); |
| | | Message msg = MQMsgBodyFactory.create(MQTopicName.TOPIC_ORDER, OrderTopicTagEnum.orderConfirm, |
| | | mqMsg); |
| | | orderProducer.send(msg); |
| | | rocketMQManager.sendNormalMsg(msg, null); |
| | | } |
| | | } |
| | | } |
| | |
| | | { |
| | | SuningGoodsInfo pddGoods = null; |
| | | // TODO 需要获取 |
| | | pddGoods = SuningApiUtil.getGoodsDetail(suningOrderInfo.getGoodsNum(), "00000000"); |
| | | pddGoods = SuningApiUtil.getGoodsDetail(suningOrderInfo.getGoodsNum(), suningOrderInfo.getSellerCode()); |
| | | if (pddGoods != null) { |
| | | cog = CommonOrderGoodsFactory.create(pddGoods); |
| | | } |
| | |
| | | return commonOrderMapper.getByOrderNo(uid, orderNO); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public List<CommonOrder> getByOrderNoAndSourceType(Long uid, String orderNO, int sourceType) { |
| | | return commonOrderMapper.getByOrderNoAndSourceType(uid, orderNO, sourceType); |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public CommonOrder selectLatestValidByUid(Long uid) { |
| | | List<Integer> stateList = new ArrayList<>(); |
| | |
| | | Integer goodsType = commonGoodsVO.getGoodsType(); |
| | | if (goodsType != null & goodsType == Constant.SOURCE_TYPE_ELME) { |
| | | order.setOrderType(Constant.SOURCE_TYPE_ELME); // 饿了么订单 |
| | | commonGoodsVO.setGoodsId("0"); |
| | | } |
| | | |
| | | if (goodsType == Constant.SOURCE_TYPE_SUNING) { |
| | |
| | | return commonOrderMapper.listByOrderNo(orderNo); |
| | | } |
| | | |
| | | @Override |
| | | public CommonOrder getFirstOrder(Long uid) { |
| | | return commonOrderMapper.getFirstOrder(uid); |
| | | } |
| | | |
| | | } |