| | |
| | | |
| | | // 根据id获取手机号 |
| | | |
| | | Boolean isPriorityDispatch = false; |
| | | R<XpAppUser> xpAppUserR = xpAppUserClient.queryOperationsUserById(Long.valueOf(uid)); |
| | | if (xpAppUserR.getCode() == R.SUCCESS) { |
| | | Long count = xpWhitelistMapper.selectCount(new LambdaQueryWrapper<XpWhitelist>().eq(XpWhitelist::getAccount, xpAppUserR.getData().getPhoneNumber()).eq(XpWhitelist::getIsPriorityDispatch, 1)); |
| | | if (count > 0) { |
| | | isPriorityDispatch = true; |
| | | } |
| | | } |
| | | Boolean isPriorityDispatch = true; |
| | | // R<XpAppUser> xpAppUserR = xpAppUserClient.queryOperationsUserById(Long.valueOf(uid)); |
| | | // if (xpAppUserR.getCode() == R.SUCCESS) { |
| | | // Long count = xpWhitelistMapper.selectCount(new LambdaQueryWrapper<XpWhitelist>().eq(XpWhitelist::getAccount, xpAppUserR.getData().getPhoneNumber()).eq(XpWhitelist::getIsPriorityDispatch, 1)); |
| | | // if (count > 0) { |
| | | // isPriorityDispatch = true; |
| | | // } |
| | | // } |
| | | |
| | | // 生成订单数据 |
| | | XpOrder xpOrder = new XpOrder(); |
| | |
| | | |
| | | // 根据id获取手机号 |
| | | |
| | | Boolean isPriorityDispatch = false; |
| | | R<XpAppUser> xpAppUserR = xpAppUserClient.queryOperationsUserById(Long.valueOf(uid)); |
| | | if (xpAppUserR.getCode() == R.SUCCESS) { |
| | | Long count = xpWhitelistMapper.selectCount(new LambdaQueryWrapper<XpWhitelist>().eq(XpWhitelist::getAccount, xpAppUserR.getData().getPhoneNumber()).eq(XpWhitelist::getIsPriorityDispatch, 1)); |
| | | if (count > 0) { |
| | | isPriorityDispatch = true; |
| | | } |
| | | } |
| | | Boolean isPriorityDispatch = true; |
| | | // R<XpAppUser> xpAppUserR = xpAppUserClient.queryOperationsUserById(Long.valueOf(uid)); |
| | | // if (xpAppUserR.getCode() == R.SUCCESS) { |
| | | // Long count = xpWhitelistMapper.selectCount(new LambdaQueryWrapper<XpWhitelist>().eq(XpWhitelist::getAccount, xpAppUserR.getData().getPhoneNumber()).eq(XpWhitelist::getIsPriorityDispatch, 1)); |
| | | // if (count > 0) { |
| | | // isPriorityDispatch = true; |
| | | // } |
| | | // } |
| | | |
| | | // 生成订单数据 |
| | | XpOrder xpOrder = new XpOrder(); |
| | |
| | | String uid = request.getHeader("XP-Uid"); |
| | | return xpOrderService.fareBreakdown(orderId,uid); |
| | | } |
| | | /**+ |
| | | * 获取行程费用明细 |
| | | */ |
| | | @PutMapping("/api/v1/mini-program/order/feeDescription/{orderId}") |
| | | @ApiOperation(value = "获取费用说明", tags = {"小程序-获取费用说明"}) |
| | | @XpClientCheck(checkToken = false, checkOtpToken = true) |
| | | public R<String> feeDescription(@PathVariable("orderId") Long orderId, HttpServletRequest request) { |
| | | // uid已通过拦截器otp校验,可以直接使用 |
| | | String uid = request.getHeader("XP-Uid"); |
| | | return xpOrderService.feeDescription(orderId,uid); |
| | | } |
| | | /** |
| | | * 订单评价 |
| | | */ |
| | |
| | | void popOrder(PopOrderDto dto); |
| | | |
| | | OrderDetailVo orderDetail(Long orderId, String uid); |
| | | |
| | | R<String> feeDescription(Long orderId, String uid); |
| | | } |
| | |
| | | return orderDetailVo; |
| | | } |
| | | |
| | | @Override |
| | | public R<String> feeDescription(Long orderId, String uid) { |
| | | XpOrder order = this.getById(orderId); |
| | | R<XpPricing> pricingByCityId = xpPricingClient.getPricingByCid(order.getCityId()); |
| | | XpPricing pricing = pricingByCityId.getData(); |
| | | if (pricing == null) { |
| | | throw new ServiceException("当前城市未配置定价规则", I18nKeyConstant.ORDER_PRICING_NOT_EXISTS); |
| | | }else{ |
| | | return R.ok(pricing.getPriceRule()); |
| | | } |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 成功操作下发命令后调用 用于弹出redis队列的获取成功的数据 |