| | |
| | | List<Bookings> bookList = bookingsJoinMapper.selectJoinList(Bookings.class, bookquery); |
| | | for (int i = 0; i < bookings.getBookingTimeList().size(); i++) { |
| | | BookingTime s = bookings.getBookingTimeList().get(i); |
| | | RoomTime roomTime = roomTimeJoinMapper.selectById(s.getTimeId()); |
| | | if(Objects.isNull(roomTime)){ |
| | | throw new BusinessException(ResponseStatus.DATA_EMPTY.getCode(),"存在未查询到的配置日期,请刷新重试"); |
| | | } |
| | | String endRoomTime = gsDate + " " + roomTime.getEndTime()+":00"; |
| | | if(DateUtil.StringToDate(endRoomTime, "yyyy-MM-dd HH:mm:ss").getTime()<=System.currentTimeMillis()){ |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),endRoomTime + "已超过当前时间,无法进行预约"); |
| | | } |
| | | if (!Objects.isNull(bookList) && bookList.size() > MeetConstants.ZERO) { |
| | | List<Bookings> detailDataDtoStream = |
| | | bookList.stream().filter(a -> MeetConstants.equalsInteger(s.getTimeId(), a.getRoomTimeId()) |
| | |
| | | .filter(a -> MeetConstants.equalsInteger(a.getRoomTimeId(), s.getTimeId())) |
| | | .collect(Collectors.toList()); |
| | | if (chriList.size() > 0) { |
| | | RoomTime roomTime = roomTimeJoinMapper.selectById(s.getTimeId()); |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "该会议:" + roomTime.getStartTime() + "-" + roomTime.getEndTime() + "时间段内已被使用"); |
| | | } |
| | | } else { |
| | |
| | | .filter(a -> MeetConstants.equalsInteger(a.getRoomTimeId(), s.getTimeId())) |
| | | .collect(Collectors.toList()); |
| | | if (chriList.size() > 0) { |
| | | RoomTime roomTime = roomTimeJoinMapper.selectById(s.getTimeId()); |
| | | throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(), "该会议:" + roomTime.getStartTime() + "-" + roomTime.getEndTime() + "时间段内已被使用"); |
| | | } |
| | | } |
| | |
| | | .apply(" id in ( select u.OBJ_ID from meeting_user_rel u where u.USER_ID = '" + userId + "' and u.ISDELETED = 0 and OBJ_TYPE = 1 ) ") |
| | | .eq("ISDELETED",MeetConstants.ZERO) |
| | | // .eq("STATUS",MeetConstants.ZERO) |
| | | .apply(" ROOM_ID in ( select r.id from rooms r where r.ISDELETED = 0 and r.STATUS = 0 )") |
| | | .apply(" ROOM_ID in ( select r.id from meeting_rooms r where r.ISDELETED = 0 and r.STATUS = 0 )") |
| | | .like(StringUtils.isNotBlank(dateMsg), "START_TIME", dateMsg)); |
| | | } |
| | | |
| | |
| | | public IPage<UserResponse> getUserPage(PageWrap<UserPageRequest> pageWrap) { |
| | | IPage<UserResponse> page = systemUserMapper.getUserPage(pageWrap.toPage(),new QueryWrapper<UserResponse>() |
| | | .and(StringUtils.isNotBlank(pageWrap.getModel().getKeyword()), i -> i.like("c.realName", pageWrap.getModel().getKeyword()) |
| | | .or().like("e.name", pageWrap.getModel().getKeyword()) |
| | | .or().like("d.COMPANY_NAME_PATH", pageWrap.getModel().getKeyword()) |
| | | ) |
| | | .eq("c.DELETED",0) |
| | | .eq("c.status",0) |