| | |
| | | import com.yeshi.fanli.util.jd.JDApiUtil; |
| | | import com.yeshi.fanli.util.jd.JDUtil; |
| | | import com.yeshi.fanli.util.pinduoduo.PinDuoDuoApiUtil; |
| | | import com.yeshi.fanli.util.taobao.TaoBaoOrderUtil; |
| | | import com.yeshi.fanli.util.taobao.TaoBaoUtil; |
| | | import com.yeshi.fanli.util.taobao.TaoKeApiUtil; |
| | | import com.yeshi.fanli.util.user.UserLevelUtil; |
| | |
| | | } |
| | | Map<Long, Boolean> vipUserMap = userVIPInfoService.listByUids(needSelectVIPUidList); |
| | | |
| | | |
| | | // 设置是否为vip订单 |
| | | for (CommonOrderVO order : listOrder) { |
| | | if (order.getHongBaoType() == HongBaoV2.TYPE_YIJI || order.getHongBaoType() == HongBaoV2.TYPE_ERJI |
| | |
| | | String orderNo = order.getOrderNo(); |
| | | Integer sourceType = order.getSourceType(); |
| | | Integer hongBaoType = order.getHongBaoType(); |
| | | |
| | | |
| | | |
| | | // 商品信息组合 |
| | | for (CommonOrderVO commonOrder : listGoods) { |
| | | CommonOrderGoods goods = commonOrder.getCommonOrderGoods(); |
| | |
| | | } |
| | | commonGoodsVO.setActualPay("付款金额:¥" + totalSettlement); |
| | | |
| | | |
| | | // 邀请订单信息保护 |
| | | if (HongBaoV2.TYPE_YAOQING == hongBaoType || HongBaoV2.TYPE_YIJI == hongBaoType |
| | | || HongBaoV2.TYPE_ERJI == hongBaoType || HongBaoV2.TYPE_SHARE_YIJI == hongBaoType |
| | |
| | | order.getListOrderGoods().add(commonGoodsVO); |
| | | } |
| | | } |
| | | |
| | | |
| | | Date thirdCreateTime = order.getThirdCreateTime(); |
| | | order.setDownTime("下单时间:" + format.format(thirdCreateTime)); |
| | | order.setObtainTime(thirdCreateTime.getTime()); |
| | | |
| | | |
| | | Date settleTime = order.getSettleTime(); |
| | | if (settleTime != null) { |
| | | order.setReceiveTime("收货时间:" + format.format(settleTime)); |
| | |
| | | wholeOrderState = CommonOrder.STATE_WHOLE_ORDER_BUFENYOUXIAO; |
| | | |
| | | for (TaoBaoOrder taoBaoOrder : taoBaoOrders) { |
| | | CommonOrder newCommonOrder = TaoBaoOrderUtil.convert(taoBaoOrder); |
| | | CommonOrder newCommonOrder = CommonOrderFactory.create(taoBaoOrder); |
| | | CommonOrderGoods cog = new CommonOrderGoods(); |
| | | cog.setGoodsId(taoBaoOrder.getAuctionId() + ""); |
| | | cog.setGoodsType(Constant.SOURCE_TYPE_TAOBAO); |
| | |
| | | @Override |
| | | public List<CommonOrderVO> listQuery(long start, int count, Integer keyType, String key, Integer state, |
| | | Integer type, Integer orderState, String startTime, String endTime, Integer source, List<Long> listShopId, |
| | | List<Long> listGoodsId, Date minTime, BigDecimal money,BigDecimal payment) throws CommonOrderException { |
| | | List<Long> listGoodsId, Date minTime, BigDecimal money, BigDecimal payment) throws CommonOrderException { |
| | | |
| | | List<CommonOrderVO> list = null; |
| | | |
| | |
| | | startTime, endTime, source, payment); |
| | | } else { |
| | | list = commonOrderMapper.listQuery(start, count, keyType, key, state, type, orderState, startTime, endTime, |
| | | source, listShopId, listGoodsId, minTime, money,payment); |
| | | source, listShopId, listGoodsId, minTime, money, payment); |
| | | } |
| | | |
| | | if (list == null) { |
| | |
| | | @Override |
| | | public long countQuery(Integer keyType, String key, Integer state, Integer type, Integer orderState, |
| | | String startTime, String endTime, Integer source, List<Long> listShopId, List<Long> listGoodsId, |
| | | Date minTime, BigDecimal money,BigDecimal payment) throws CommonOrderException { |
| | | Date minTime, BigDecimal money, BigDecimal payment) throws CommonOrderException { |
| | | if (StringUtil.isNullOrEmpty(key) || keyType == 1) {// 搜索框无值或者按订单号搜索时都只搜索主订单 |
| | | return commonOrderMapper.countQueryWithNoChild(keyType, key, state, type, orderState, startTime, endTime, |
| | | source, payment); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public List<CommonOrderVO> searchOrderByUid(AcceptData acceptData, int page, int size, Long uid, List<ESOrder> list) throws Exception { |
| | | public List<CommonOrderVO> searchOrderByUid(AcceptData acceptData, int page, int size, Long uid, List<ESOrder> list) |
| | | throws Exception { |
| | | List<CommonOrderVO> listVO = commonOrderMapper.searchOrderByUid((page - 1) * size, size, uid, list); |
| | | |
| | | // 订单信息为空 |
| | |
| | | * @param listGoods |
| | | * @param uid |
| | | */ |
| | | private void orderVOFactoryNew(AcceptData acceptData, List<CommonOrderVO> listOrder, List<CommonOrderVO> listGoods, Long uid) |
| | | throws Exception { |
| | | private void orderVOFactoryNew(AcceptData acceptData, List<CommonOrderVO> listOrder, List<CommonOrderVO> listGoods, |
| | | Long uid) throws Exception { |
| | | List<String> listTB = new ArrayList<String>(); |
| | | List<String> listJD = new ArrayList<String>(); |
| | | List<String> listPDD = new ArrayList<String>(); |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | SimpleDateFormat format = new SimpleDateFormat("yyyy.MM.dd HH:mm"); |
| | | SimpleDateFormat formatday = new SimpleDateFormat("yyyy.MM.dd"); |
| | |
| | | boolean vip = userVIPInfoService.isVIP(uid); |
| | | // 是否存在奖励券 |
| | | boolean hasRewardCoupon = userSystemCouponService.getValidRebateCoupon(uid); |
| | | |
| | | |
| | | for (CommonOrderVO order : listOrder) { |
| | | String orderNo = order.getOrderNo(); |
| | | Integer sourceType = order.getSourceType(); |
| | | Integer hongBaoType = order.getHongBaoType(); |
| | | |
| | | |
| | | // 商品信息组合 |
| | | for (CommonOrderVO commonOrder : listGoods) { |
| | | CommonOrderGoods goods = commonOrder.getCommonOrderGoods(); |
| | |
| | | totalSettlement = commonOrder.getTotalPayment(); |
| | | } |
| | | commonGoodsVO.setActualPay("付款金额:¥" + totalSettlement); |
| | | |
| | | |
| | | |
| | | // 邀请订单信息保护 |
| | | if (HongBaoV2.TYPE_YAOQING == hongBaoType || HongBaoV2.TYPE_YIJI == hongBaoType |
| | | || HongBaoV2.TYPE_ERJI == hongBaoType || HongBaoV2.TYPE_SHARE_YIJI == hongBaoType |
| | |
| | | order.setRebateLink(rebateLink + "?orderNo=" + orderNo +"&sourceType=" + sourceType); |
| | | } |
| | | } |
| | | |
| | | |
| | | Date settleTime = order.getSettleTime(); |
| | | if (settleTime != null) { |
| | | order.setReceiveTime("收货时间:" + format.format(settleTime)); |
| | |
| | | } |
| | | } |
| | | |
| | | @Override |
| | | public Date getThirdCreateTime(String orderId, int sourceType) { |
| | | List<CommonOrder> list = listBySourceTypeAndOrderId(sourceType, orderId); |
| | | if (list == null || list.size() == 0) |
| | | return null; |
| | | return list.get(0).getThirdCreateTime(); |
| | | } |
| | | |
| | | } |