ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/goods/GoodsServiceImpl.java
@@ -187,14 +187,16 @@ throw new ServiceException(AppErrorConstant.GOODS_DELETED); } BeanUtils.copyProperties(goods, appGoodsInfoVo); //商户定制价格 //商户是否定制价格 ShopGoods shopGoods = shopGoodsService.getByShopIdAndGoodsId(appGoodsInfoGetDto.getShopId(),goods.getGoodsId()); if (shopGoods != null) { appGoodsInfoVo.setSalesPrice(shopGoods.getSalesPrice()); appGoodsInfoVo.setServiceNum(shopGoods.getServiceNum()); } else { } //是否绑定经销商 Shop shop = remoteShopService.getShop(appGoodsInfoGetDto.getShopId()).getData(); if(shop.getBelongShopId()!=null &&shop.getShopType()==2){ //经销商定制价格 Shop shop = remoteShopService.getShop(appGoodsInfoGetDto.getShopId()).getData(); Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); shopGoods = shopGoodsService.getByShopIdAndGoodsId(belongShop.getShopId(), goods.getGoodsId()); if (1 == belongShop.getModifyPricePermission() && null != shopGoods) { ruoyi-modules/ruoyi-goods/src/main/resources/mapper/lottery/LotteryEventMapper.xml
@@ -37,7 +37,7 @@ DATE_FORMAT(end_time, '%Y-%m-%d %H:%i') as endTime, wx_mini_program_qr_code as wxMiniProgramQrCode from t_lottery_event where del_flag == 0 and shop_id = #{shopId} where del_flag = 0 and shop_id = #{shopId} order by create_time desc </select> <select id="pageMgtLotteryEvent" resultType="com.ruoyi.goods.domain.vo.MgtLotteryEventPageVo"> ruoyi-modules/ruoyi-member/src/main/java/com/ruoyi/member/domain/dto/MgtCouponEditDto.java
@@ -26,15 +26,16 @@ @ApiModelProperty(value = "优惠券id 新增不传") private String couponId; @ApiModelProperty(value="优惠券类型1.满减2.折扣3.代金4.商品5.抽奖领取") @ApiModelProperty(value="优惠券类型1.满减2.折扣3.代金4.商品") @NotNull(message = "优惠券类型不能为空") @Range(min = 1, max = 4 , message = "优惠券类型错误") private Integer couponType; @ApiModelProperty(value="优惠券名称") @NotNull(message = "优惠券名称不能为空") private String couponName; @ApiModelProperty(value = "发送类型1.手动领取2.指定发放") @ApiModelProperty(value = "发送类型1.手动领取2.指定发放3.抽奖领取") @NotNull(message = "发送类型不能为空") private Integer sendType; ruoyi-modules/ruoyi-member/src/main/resources/mapper/coupon/CouponMapper.xml
@@ -165,6 +165,7 @@ END useScope, CASE tc.send_type WHEN 1 THEN '手动获取' WHEN 3 THEN '抽奖发送' ELSE '指定发放' END sendType, CASE tc.send_target ruoyi-modules/ruoyi-order/src/main/java/com/ruoyi/order/service/impl/order/OrderServiceImpl.java
@@ -184,7 +184,7 @@ if(shop!=null&&shop.getShopStatus()!=1){ throw new ServiceException(AppErrorConstant.SHOP_CLOSED); } Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); // Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); // 初始化订单对象 AppSureOrderVo appSureOrderVo = new AppSureOrderVo(); // 初始化订单商品列表 @@ -268,15 +268,20 @@ appShopGoodsGetDto.setGoodsId(goods.getGoodsId()); appShopGoodsGetDto.setShopId(appSureOrderDto.getShopId()); ShopGoods shopGoods = remoteGoodsService.getShopGoods(appShopGoodsGetDto).getData(); //商户是否定制价格 if (shopGoods != null) { goodsPrice = shopGoods.getSalesPrice(); } else { } //是否绑定经销商 if(shop.getBelongShopId()!=null &&shop.getShopType()==2){ //经销商定制价格 appShopGoodsGetDto.setGoodsId(goods.getGoodsId()); appShopGoodsGetDto.setShopId(belongShop.getShopId()); shopGoods = remoteGoodsService.getShopGoods(appShopGoodsGetDto).getData(); AppShopGoodsGetDto shopGoodsGetDto=new AppShopGoodsGetDto(); shopGoodsGetDto.setGoodsId(goods.getGoodsId()); shopGoodsGetDto.setShopId(shop.getBelongShopId()); Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); shopGoods = remoteGoodsService.getShopGoods(shopGoodsGetDto).getData(); if (1 == belongShop.getModifyPricePermission() && null != shopGoods) { goodsPrice = shopGoods.getSalesPrice(); goodsPrice=shopGoods.getSalesPrice(); } } appSureOrderGoodsVo.setGoodsPrice(goodsPrice); @@ -461,7 +466,9 @@ ShopGoods shopGoods = remoteGoodsService.getShopGoods(appShopGoodsGetDto).getData(); if (shopGoods != null) { goodsPrice = shopGoods.getSalesPrice(); } else { } //是否绑定经销商 if(shop.getBelongShopId()!=null &&shop.getShopType()==2){ //经销商定制价格 Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); appShopGoodsGetDto = new AppShopGoodsGetDto(); @@ -577,6 +584,10 @@ //使用优惠券 StringJoiner memberCouponSJ = new StringJoiner(","); List<String> goodsNameList = new ArrayList<>(); Shop shop = remoteShopService.getShop(appPlaceOrderDto.getShopId()).getData(); if(shop!=null&&shop.getShopStatus()!=1){ throw new ServiceException(AppErrorConstant.SHOP_CLOSED); } // 遍历购买的商品列表 for (AppBuyGoodsDto appBuyGoodsDto : appBuyGoodsDtoList) { appSureOrderGoodsVo = new AppSureOrderGoodsVo(); @@ -610,9 +621,10 @@ if (shopGoods != null) { goodsPrice = shopGoods.getSalesPrice(); serviceNum = shopGoods.getServiceNum(); } else { } //是否绑定经销商 if(shop.getBelongShopId()!=null &&shop.getShopType()==2){ //经销商定制价格 Shop shop = remoteShopService.getShop(appPlaceOrderDto.getShopId()).getData(); Shop belongShop = remoteShopService.getShop(shop.getBelongShopId()).getData(); appShopGoodsGetDto = new AppShopGoodsGetDto(); appShopGoodsGetDto.setGoodsId(goods.getGoodsId());