| | |
| | | import com.yeshi.fanli.vo.msg.ClientTextStyleVO;
|
| | | import com.yeshi.fanli.vo.order.CommonOrderGoodsVO;
|
| | | import com.yeshi.fanli.vo.order.CommonOrderVO;
|
| | | import com.yeshi.fanli.vo.order.OrderCountVO;
|
| | | import com.yeshi.fanli.vo.order.WeiQuanInfo;
|
| | |
|
| | | import net.sf.json.JSONObject;
|
| | |
| | | */
|
| | | public void setSystemCouponRecord(CommonOrderVO order, boolean hasRewardCoupon, boolean exchangeCoupon,
|
| | | Integer hongBaoState, Integer hongBaoType, List<UserSystemCouponRecord> list, List<String> signList,
|
| | | AcceptData acceptData) {
|
| | | Long uid, AcceptData acceptData) {
|
| | |
|
| | | // 是否免单商品
|
| | | boolean freeOrder = false;
|
| | |
| | | rewardOrder = true; // 奖励成功 2.0.2 消失
|
| | | }
|
| | | } else if (hasRewardCoupon && !freeOrder && HongBaoV2.TYPE_ZIGOU == hongBaoType
|
| | | && HongBaoV2.STATE_YILINGQU == hongBaoState) {
|
| | | // 有可用的奖励券 、非免单订单 、且已到账的 、返利订单
|
| | | type = 2;
|
| | | rewardOrder = true;
|
| | | && HongBaoV2.STATE_YILINGQU == hongBaoState) { // 有可用的奖励券 、非免单订单 、且已到账的 、返利订单
|
| | | if (!userVIPInfoService.isVIP(uid)) { // 非会员可使用奖励券
|
| | | type = 2; |
| | | rewardOrder = true; |
| | | }
|
| | | }
|
| | |
|
| | | if (rewardOrder) {
|
| | |
| | | order.setVipOrder(false);
|
| | | } else
|
| | | order.setVipOrder(false);
|
| | | |
| | | if(order.isVipOrder())
|
| | | order.setVipOrderDesc("订单来源:由超级会员的粉丝产生");
|
| | | }
|
| | |
|
| | | for (CommonOrderVO order : listOrder) {
|
| | |
| | | } else if (CommonOrder.STATE_SX == orderState) {
|
| | | orderStateContent = "未付款/已退款";
|
| | | } else if (CommonOrder.STATE_WQ == orderState) {
|
| | | orderStateContent = "已维权";
|
| | | orderStateContent = "已售后";
|
| | | if (sourceType != null && sourceType == Constant.SOURCE_TYPE_TAOBAO) {
|
| | | /* 订单维权 判断是否全部维权 */
|
| | | List<TaoBaoWeiQuanOrder> listWQ = taoBaoWeiQuanOrderMapper
|
| | |
| | | } else {
|
| | | // 2019.8.1 返回维权信息
|
| | | if (settleTime != null && august != null && settleTime.getTime() > august.getTime()) {
|
| | | orderStateContent = "维权成功";
|
| | | orderStateContent = "售后成功";
|
| | | WeiQuanInfo weiQuanInfo = new WeiQuanInfo();
|
| | | weiQuanInfo.setOldHongBao("¥" + hongBao.setScale(2, BigDecimal.ROUND_DOWN).toString());
|
| | | weiQuanInfo
|
| | | .setWqHongBao("维权:-¥" + weiQuanMoney.setScale(2, BigDecimal.ROUND_DOWN).toString());
|
| | | .setWqHongBao("售后:-¥" + weiQuanMoney.setScale(2, BigDecimal.ROUND_DOWN).toString());
|
| | | hongBao = MoneyBigDecimalUtil.sub(hongBao, weiQuanMoney);
|
| | | order.setWeiQuanInfo(weiQuanInfo);
|
| | | }
|
| | |
| | | // 奖励订单、免单 使用记录
|
| | | if (sourceType == null) {
|
| | | setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType, null,
|
| | | signList, acceptData);
|
| | | signList, uid, acceptData);
|
| | | } else if (sourceType == Constant.SOURCE_TYPE_TAOBAO) {
|
| | | setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
|
| | | listRecordTB, signList, acceptData);
|
| | | listRecordTB, signList, uid, acceptData);
|
| | | } else if (sourceType == Constant.SOURCE_TYPE_JD) {
|
| | | setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
|
| | | listRecordJD, signList, acceptData);
|
| | | listRecordJD, signList, uid, acceptData);
|
| | | } else if (sourceType == Constant.SOURCE_TYPE_PDD) {
|
| | | setSystemCouponRecord(order, hasRewardCoupon, exchangeCoupon, hongBaoState, hongBaoType,
|
| | | listRecordPDD, signList, acceptData);
|
| | | listRecordPDD, signList, uid, acceptData);
|
| | | }
|
| | | }
|
| | |
|
| | |
| | | public Map<String, BigDecimal> countHistoryOrder(Long uid, Integer day, Integer source) {
|
| | | return commonOrderMapper.countHistoryOrder(uid, day, source);
|
| | | }
|
| | | |
| | | @Override
|
| | | public OrderCountVO getOrderCount(Long uid, Integer day, Integer source) {
|
| | | return commonOrderMapper.getOrderCount(uid, day, source);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public long countBonusOrderNumber(Long uid, Integer type, Integer day, String startTime, String endTime,
|