| | |
| | | item.getDurationMinutes(), item.getMinParticipants(), item.getMaxParticipants(), |
| | | item.getOriginalPrice(), item.getDiscountPrice())) |
| | | .collect(Collectors.toList()); |
| | | rows.add(new GuideReceivingOptionResponse.ScenicOption(scenic.getId(), scenic.getScenicName(), points, services)); |
| | | rows.add(new GuideReceivingOptionResponse.ScenicOption(scenic.getId(), scenic.getScenicName(), |
| | | positive(scenic.getFirstOrderLeadMinutes(), 15), points, services)); |
| | | } |
| | | return new GuideReceivingOptionResponse(premiumEnabled, value(settings.getPreciseDispatchOrderCount()), |
| | | settings.getPreciseDispatchRating(), rows); |
| | |
| | | if (session == null) { |
| | | return null; |
| | | } |
| | | if ("IN_SERVICE".equals(session.getStatus())) { |
| | | return hasActiveServiceOrder(session) ? session : null; |
| | | if (hasActiveServiceOrder(session)) { |
| | | return session; |
| | | } |
| | | |
| | | GuideRealtimeStatus realtimeStatus = realtimeStatusMapper.selectById(guideId); |
| | |
| | | } |
| | | |
| | | private long value(Integer number) { return number == null ? 0L : number.longValue(); } |
| | | |
| | | private int positive(Integer number, int fallback) { |
| | | return number == null || number < 1 ? fallback : number; |
| | | } |
| | | } |