| | |
| | | import com.yeshi.fanli.dao.mybatis.order.CommonOrderGoodsMapper;
|
| | | import com.yeshi.fanli.dao.mybatis.order.CommonOrderMapper;
|
| | | import com.yeshi.fanli.dao.mybatis.taobao.TaoBaoWeiQuanOrderMapper;
|
| | | import com.yeshi.fanli.entity.bus.user.HongBao;
|
| | | import com.yeshi.fanli.entity.bus.user.HongBaoV2;
|
| | | import com.yeshi.fanli.entity.bus.user.UserInfo;
|
| | | import com.yeshi.fanli.entity.order.CommonOrder;
|
| | |
| | | public List<CommonOrderVO> listGroupOrderNoByUid(long start, int count, Long uid, Integer state, Integer type,
|
| | | Integer orderState, String orderNo, String startTime, String endTime, Integer dateType)
|
| | | throws CommonOrderException {
|
| | | return commonOrderMapper.listGroupOrderNoByUid(start, count, uid, state, type, orderState, orderNo, startTime,
|
| | | return commonOrderMapper.listUserOrder(start, count, uid, state, type, orderState, orderNo, startTime,
|
| | | endTime, dateType);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public long countGroupOrderNoByUid(Long uid, Integer state, Integer type, Integer orderState, String orderNo,
|
| | | String startTime, String endTime, Integer dateType) throws CommonOrderException {
|
| | | return commonOrderMapper.countGroupOrderNoByUid(uid, state, type, orderState, orderNo, startTime, endTime,
|
| | | return commonOrderMapper.countUserOrder(uid, state, type, orderState, orderNo, startTime, endTime,
|
| | | dateType);
|
| | | }
|
| | |
|
| | |
| | | }
|
| | |
|
| | | // 商品信息
|
| | | List<CommonOrderVO> listGoods = commonOrderMapper.listByOrderNoAndType(listOrder);
|
| | | List<CommonOrderVO> listGoods = commonOrderMapper.listOrderGoodsInfo(listOrder);
|
| | | // 订单商品为空
|
| | | if (listGoods == null || listGoods.size() == 0) {
|
| | | return listOrder;
|
| | |
| | | }
|
| | |
|
| | | @Override
|
| | | public Map<String, BigDecimal> countOrderByHongBaoType(Long uid, Integer day) {
|
| | | return commonOrderMapper.countOrderByHongBaoType(uid, day);
|
| | | public Map<String, BigDecimal> countHistoryOrder(Long uid, Integer day) {
|
| | | return commonOrderMapper.countHistoryOrder(uid, day);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public long countOrder(Long uid, Integer type, Integer day) {
|
| | | return commonOrderMapper.countBonusOrder(uid, type, day);
|
| | | public long countBonusOrderNumber(Long uid, Integer type, Integer day, String startTime, String endTime) {
|
| | | return commonOrderMapper.countBonusOrderNumber(uid, type, day, startTime, endTime);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public BigDecimal countOrderMoney(Long uid, Integer type, Integer day) {
|
| | | return commonOrderMapper.countBonusOrderMoney(uid, type, day);
|
| | | public BigDecimal countBonusOrderMoney(Long uid, Integer type, Integer day, String startTime, String endTime) {
|
| | | return commonOrderMapper.countBonusOrderMoney(uid, type, day, startTime, endTime);
|
| | | }
|
| | |
|
| | | @Override
|
| | |
| | | Integer hongBaoType = order.getHongBaoType();
|
| | | // 邀请订单信息保护
|
| | | if (HongBaoV2.TYPE_YAOQING == hongBaoType || HongBaoV2.TYPE_YIJI == hongBaoType
|
| | | || HongBaoV2.TYPE_ERJI == hongBaoType) {
|
| | | || HongBaoV2.TYPE_ERJI == hongBaoType || HongBaoV2.TYPE_SHARE_YIJI == hongBaoType
|
| | | || HongBaoV2.TYPE_SHARE_ERJI == hongBaoType) {
|
| | | Map<String, String> titleMap = new HashMap<String, String>();
|
| | | titleMap.put("content", "为保障用户隐私,商品信息已隐藏!");
|
| | | titleMap.put("fontColor", "#888888");
|
| | |
| | | commonGoodsVO.setGoodsTitle(titleMap);
|
| | | }
|
| | |
|
| | | // 购买数量
|
| | | commonGoodsVO.setActualCount(commonOrder.getTotalCount() + "件");
|
| | | String settlement = commonOrder.getTotalSettlement().setScale(2, BigDecimal.ROUND_DOWN).toString();
|
| | | commonGoodsVO.setActualPay("实付款:¥" + settlement);
|
| | |
|
| | | |
| | | BigDecimal totalSettlement = commonOrder.getTotalSettlement();
|
| | | if (totalSettlement == null || totalSettlement.compareTo(new BigDecimal(0)) <= 0) {
|
| | | totalSettlement = commonOrder.getTotalPayment();
|
| | | }
|
| | | // 实付款
|
| | | commonGoodsVO.setActualPay("实付款:¥" + totalSettlement);
|
| | | |
| | | listOrderGoods.add(commonGoodsVO);
|
| | |
|
| | | Integer orderType = commonOrder.getOrderType();
|
| | |
| | | hongbaoInfo = "返利";
|
| | | order.setOrderOrigin("1");
|
| | | order.setHongBaoTypePic(CommonOrder.TYPE_FANLI);
|
| | | } else if (HongBaoV2.TYPE_SHARE_GOODS == hongBaoType || HongBaoV2.TYPE_SHARE_YIJI == hongBaoType
|
| | | || HongBaoV2.TYPE_SHARE_ERJI == hongBaoType) {
|
| | | } else if (HongBaoV2.TYPE_SHARE_GOODS == hongBaoType) {
|
| | | // 分享
|
| | | hongbaoInfo = "奖金";
|
| | | order.setOrderOrigin("2");
|
| | | order.setHongBaoTypePic(CommonOrder.TYPE_SHARE);
|
| | | } else if (HongBaoV2.TYPE_YAOQING == hongBaoType || HongBaoV2.TYPE_YIJI == hongBaoType
|
| | | || HongBaoV2.TYPE_ERJI == hongBaoType) {
|
| | | || HongBaoV2.TYPE_ERJI == hongBaoType || HongBaoV2.TYPE_SHARE_YIJI == hongBaoType
|
| | | || HongBaoV2.TYPE_SHARE_ERJI == hongBaoType) {
|
| | | // 邀请
|
| | | hongbaoInfo = "奖金";
|
| | | order.setOrderOrigin("3");
|
| | |
| | | return commonOrderList;
|
| | | }
|
| | |
|
| | | @Override
|
| | | public Map<String, Object> countMoneyGroupOrderNoByUid(Long uid, Integer type, String orderNo, String startTime,
|
| | | String endTime, Integer day) {
|
| | | return commonOrderMapper.countMoneyGroupOrderNoByUid(uid, type, orderNo, startTime, endTime, day);
|
| | | }
|
| | |
|
| | | @Override
|
| | | public long countByUidAndOrderStateWithOrderBalanceTime(Long uid, int state, Date minDate, Date maxDate) {
|