Merge remote-tracking branch 'origin/master'
| | |
| | | @ApiModelProperty(value = "技师名称") |
| | | private String technicianName; |
| | | |
| | | @ApiModelProperty(value = "技师id") |
| | | private Integer technicianId; |
| | | |
| | | @ApiModelProperty(value = "预约单id") |
| | | private String technicianSubscribeId; |
| | | |
| | |
| | | @TableField("purchase_limit") |
| | | private Integer purchaseLimit; |
| | | |
| | | @ApiModelProperty(value = "配送方式(1=自提,2=快递,1,2 = 自提+快递)") |
| | | @ApiModelProperty(value = "配送方式(1=自提,2=快递)") |
| | | @TableField("distribution_mode") |
| | | private String distributionMode; |
| | | |
| | |
| | | } |
| | | List<CouponInfo> couponInfoList = couponInfoClient.getCouponInfoList(couponIds).getData(); |
| | | //构建返回数据 |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"); |
| | | DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy.MM.dd HH:mm"); |
| | | List<PaymentUserCouponVo> infoVoList = new ArrayList<>(); |
| | | for (UserCoupon userCoupon : list) { |
| | | CouponInfo couponInfo = couponInfoList.stream().filter(s -> s.getId().equals(userCoupon.getCouponId())).findFirst().get(); |
| | |
| | | couponInfoVo.setDiscountAmount(couponInfo.getDiscountAmount()); |
| | | couponInfoVo.setMoneyAmount(couponInfo.getMoneyAmount()); |
| | | couponInfoVo.setDiscount(couponInfo.getDiscount()); |
| | | if(null != couponInfo.getPeriodStartTime()){ |
| | | couponInfoVo.setPeriodStartTime(couponInfo.getPeriodStartTime().atTime(0, 0, 0).format(formatter)); |
| | | couponInfoVo.setPeriodEndTime(couponInfo.getPeriodEndTime().atTime(23, 59, 59).format(formatter)); |
| | | if(null != userCoupon.getStartTime()){ |
| | | couponInfoVo.setPeriodStartTime(userCoupon.getStartTime().format(formatter)); |
| | | couponInfoVo.setPeriodEndTime(userCoupon.getEndTime().format(formatter)); |
| | | } |
| | | String forGoodIds = couponInfo.getForGoodIds(); |
| | | String[] split = forGoodIds.split(","); |
| | |
| | | orderDetailVO.setLatitude(shop.getLatitude()); |
| | | orderDetailVO.setShopId(shop.getId()); |
| | | orderDetailVO.setTechnicianName(technician.getName()); |
| | | orderDetailVO.setTechnicianId(technician.getId()); |
| | | return orderDetailVO; |
| | | } |
| | | |
| | |
| | | if(null != orderActivityInfo1){ |
| | | order.setActivityJson(JSON.toJSONString(orderActivityInfo1)); |
| | | } |
| | | if(null != shoppingCartPayment.getUserAddressId()){ |
| | | if(2 == shoppingCartPayment.getDistributionMode()){ |
| | | UserAddress address = userAddressClient.getUserAddressById(shoppingCartPayment.getUserAddressId()).getData(); |
| | | order.setExpressAmount(expressFee); |
| | | order.setAddressJson(JSON.toJSONString(address)); |
| | |
| | | List<Long> usersNameList = new ArrayList<>(); |
| | | List<Long> usersPhoneList = new ArrayList<>(); |
| | | |
| | | if (StringUtils.isNotEmpty(goodsEvaluate.getUserName())) { |
| | | if (StringUtils.isNotEmpty(goodsEvaluate.getGoodsName())) { |
| | | goodsIds = goodsService.lambdaQuery() |
| | | .like(Goods::getName, goodsEvaluate.getGoodsName()) |
| | | .list().stream().map(Goods::getId).collect(Collectors.toList()); |
| | |
| | | return R.ok(new Page<>()); |
| | | } |
| | | } |
| | | if (StringUtils.isNotEmpty(goodsEvaluate.getPhone())&&StringUtils.isNotEmpty(goodsEvaluate.getUserName())){ |
| | | // 取交集 |
| | | usersNameList.retainAll(usersPhoneList); |
| | | }else{ |
| | | usersNameList.addAll(usersPhoneList); |
| | | } |
| | | Page<GoodsEvaluate> page = goodsEvaluateService.page(Page.of(pageNum, pageSize), new LambdaQueryWrapper<GoodsEvaluate>() |
| | | .in(!goodsIds.isEmpty(), GoodsEvaluate::getGoodsId, goodsIds) |
| | | .in(!usersNameList.isEmpty(), GoodsEvaluate::getAppUserId, usersNameList) |
| | |
| | | return R.ok(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 预约技师 |
| | | */ |
| | | @PostMapping("/switchingTechnician") |
| | | @ApiOperation(value = "切换技师", notes = "切换技师", tags = {"小程序-个人中心-门店管理-预约列表"}) |
| | | public R<Void> switchingTechnician(@RequestBody TechnicianSubscribe technicianSubscribe) { |
| | | technicianSubscribeService.switchingTechnician(technicianSubscribe); |
| | | return R.ok(); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 取消服务 |
| | | */ |
| | |
| | | |
| | | |
| | | /** |
| | | * 切換技師 |
| | | * @param technicianSubscribe |
| | | */ |
| | | void switchingTechnician(TechnicianSubscribe technicianSubscribe); |
| | | |
| | | |
| | | /** |
| | | * 定时修改到期状态 |
| | | */ |
| | | void taskEditStstus(); |
| | |
| | | SysUser sysUser = sysUserClient.getSysUser(userid).getData(); |
| | | GoodsBargainPrice bargainPrice = this.getOne(new LambdaQueryWrapper<GoodsBargainPrice>().eq(GoodsBargainPrice::getShopId, sysUser.getObjectId()) |
| | | .eq(GoodsBargainPrice::getGoodsId, vo.getGoodsId()).eq(GoodsBargainPrice::getDelFlag, 0).last(" order by create_time desc limit 0, 1")); |
| | | if(null != bargainPrice && 1 == bargainPrice.getAuditStatus()){ |
| | | if(null != bargainPrice && 0 == bargainPrice.getAuditStatus()){ |
| | | return R.fail("特价申请正在审核中"); |
| | | } |
| | | bargainPrice = new GoodsBargainPrice(); |
| | |
| | | } |
| | | |
| | | Shop shop = shopMapper.selectById(appUser.getShopId()); |
| | | if(null != shop){ |
| | | if(null != shop && shop.getDelFlag() == 0 && shop.getStatus() == 1){ |
| | | NearbyShopVO vo = new NearbyShopVO(); |
| | | vo.setId(appUser.getShopId().longValue()); |
| | | vo.setName(shop.getName()); |
| | |
| | | @Resource |
| | | private RemoteOrderGoodsClient orderGoodsClient; |
| | | @Resource |
| | | private RedisTemplate<String, String> redisTemplate; |
| | | |
| | | private RedisTemplate redisTemplate; |
| | | @Resource |
| | | private AppUserClient appUserClient; |
| | | |
| | |
| | | } |
| | | |
| | | |
| | | @Override |
| | | public void switchingTechnician(TechnicianSubscribe technicianSubscribe) { |
| | | TechnicianSubscribe subscribe = this.getById(technicianSubscribe.getId()); |
| | | if(subscribe.getTechnicianId().equals(technicianSubscribe.getTechnicianId())){ |
| | | throw new RuntimeException("不能切换相同的技师"); |
| | | } |
| | | subscribe.setTechnicianId(technicianSubscribe.getTechnicianId()); |
| | | this.updateById(subscribe); |
| | | } |
| | | |
| | | /** |
| | | * 定时修改到期状态 |
| | | */ |
| | |
| | | (select ROUND(AVG(score), 1) from t_shop_score where shop_id = ts.id) as score |
| | | FROM |
| | | t_shop ts |
| | | WHERE ts.del_flag = 0 AND ts.`status` = 1 AND ts.id = #{shopId} |
| | | WHERE ts.del_flag = 0 AND ts.id = #{shopId} |
| | | </select> |
| | | <select id="selectShopList" resultType="com.ruoyi.other.api.domain.Shop"> |
| | | SELECT |