| | |
| | | import cc.mrbird.febs.pay.model.BrandWCPayRequestData; |
| | | import cc.mrbird.febs.pay.service.IPayService; |
| | | import cc.mrbird.febs.pay.service.IXcxPayService; |
| | | import cc.mrbird.febs.rabbit.producter.AgentProducer; |
| | | import cn.hutool.core.collection.CollUtil; |
| | | import cn.hutool.core.date.DateUnit; |
| | | import cn.hutool.core.date.DateUtil; |
| | |
| | | private final MallGoodsCouponMapper mallGoodsCouponMapper; |
| | | private final MallExpressInfoMapper mallExpressInfoMapper; |
| | | |
| | | private final AgentProducer agentProducer; |
| | | private final IXcxPayService iXcxPayService; |
| | | private final IPayService payService; |
| | | private final MallMemberMapper mallMemberMapper; |
| | |
| | | vo.setPatternPrice(clothesPattern.getPrice()); |
| | | vo.setPatternRemark(entity.getRemark()); |
| | | vo.setPatternImage(clothesPattern.getImage()); |
| | | vo.setBoxHeight(clothesPattern.getBoxHeight()); |
| | | vo.setBoxWidth(clothesPattern.getBoxWidth()); |
| | | vo.setLeftPercent(clothesPattern.getLeftPercent()); |
| | | vo.setTopPercent(clothesPattern.getTopPercent()); |
| | | |
| | | |
| | | vos.add(vo); |
| | | |
| | | totalPatternPrice = totalPatternPrice.add(clothesPattern.getPrice()); |
| | |
| | | vo.setLocationPrice(location.getPrice()); |
| | | vo.setLocationRemark(entity.getRemark()); |
| | | vo.setLocationImage(location.getImage()); |
| | | |
| | | vo.setBoxHeight(location.getBoxHeight()); |
| | | vo.setBoxWidth(location.getBoxWidth()); |
| | | vo.setLeftPercent(location.getLeftPercent()); |
| | | vo.setTopPercent(location.getTopPercent()); |
| | | vos.add(vo); |
| | | |
| | | totalLocationPrice = totalLocationPrice.add(location.getPrice()); |
| | |
| | | continue; |
| | | } else if (ClothesOrderItemEnum.CUSTOMIZE.getCode() == item.getType()) { |
| | | ClothesMemberStature clothesMemberStature = clothesMemberStatureMapper.selectById(item.getSkuId()); |
| | | if (ObjectUtil.isNull(clothesMemberStature)){ |
| | | throw new FebsException("请选择您的自定义尺码"); |
| | | } |
| | | orderItem.setItemId(clothesMemberStature.getId()); |
| | | orderItem.setName(clothesMemberStature.getName()); |
| | | orderItem.setPrice(BigDecimal.ZERO); |
| | |
| | | BigDecimal realAmount = total.subtract(discountAmount).add(deliveryAmount).setScale(2, RoundingMode.DOWN); |
| | | orderInfo.setRealAmount(realAmount); |
| | | clothesOrderMapper.updateById(orderInfo); |
| | | |
| | | //过期时间修改成24小时 |
| | | agentProducer.sendClothesOrderCancelDelayMsg(orderInfo.getId(), 24 * 60 * 60 * 1000L); |
| | | |
| | | ApiClothesOrderInfoVo apiClothesOrderInfoVo = new ApiClothesOrderInfoVo(); |
| | | apiClothesOrderInfoVo.setOrderId(orderInfo.getId()); |
| | |
| | | if(ObjectUtil.isNull(orderInfo)){ |
| | | throw new FebsException("订单不存在"); |
| | | } |
| | | if (member.getId() != orderInfo.getMemberId()) { |
| | | if (!ObjectUtil.equal(member.getId(), orderInfo.getMemberId())) { |
| | | throw new FebsException("无权限操作"); |
| | | } |
| | | if (ClothesEnum.UP.getCode() == orderInfo.getDelFlag()) { |