| | |
| | | } |
| | | |
| | | @Override |
| | | public List<QueueDO> getRoomCheckRelatedPatient(String ip) { |
| | | List<RoomDO> roomDOList = roomMapper.queueByIp(ip); |
| | | Optional<RoomDO> optionalQueueDO = roomDOList.stream().filter(item -> StringUtils.hasLength(item.getIp())).findFirst(); |
| | | if (!optionalQueueDO.isPresent()) { |
| | | return new ArrayList<QueueDO>(); |
| | | public List<QueueDO> getRoomCheckRelatedPatient(String ip, Long roomId) { |
| | | if (null == roomId) { |
| | | List<RoomDO> roomDOList = roomMapper.queueByIp(ip); |
| | | Optional<RoomDO> optionalQueueDO = roomDOList.stream().filter(item -> StringUtils.hasLength(item.getIp())).findFirst(); |
| | | if (!optionalQueueDO.isPresent()) { |
| | | return new ArrayList<QueueDO>(); |
| | | } |
| | | roomId = optionalQueueDO.get().getRoomId(); |
| | | } |
| | | |
| | | Long roomId = optionalQueueDO.get().getRoomId(); |
| | | List<Integer> queueStatusList = new ArrayList<>(); |
| | | queueStatusList.add(QueueStatusEnum.RECALLED.getStatus()); |
| | | queueStatusList.add(QueueStatusEnum.READY.getStatus()); |
| | |
| | | } |
| | | |
| | | @Override |
| | | public List<QueueDO> getRoomInstallRelatedPatient(String ip) { |
| | | List<RoomDO> roomDOList = roomMapper.queueByIp(ip); |
| | | Optional<RoomDO> optionalQueueDO = roomDOList.stream().filter(item -> StringUtils.hasLength(item.getIp())).findFirst(); |
| | | if (!optionalQueueDO.isPresent()) { |
| | | return new ArrayList<QueueDO>(); |
| | | } |
| | | public List<QueueDO> getRoomInstallRelatedPatient(String ip, Long roomId) { |
| | | if (null == roomId) { |
| | | List<RoomDO> roomDOList = roomMapper.queueByIp(ip); |
| | | Optional<RoomDO> optionalQueueDO = roomDOList.stream().filter(item -> StringUtils.hasLength(item.getIp())).findFirst(); |
| | | if (!optionalQueueDO.isPresent()) { |
| | | return new ArrayList<QueueDO>(); |
| | | } |
| | | |
| | | Long roomId = optionalQueueDO.get().getRoomId(); |
| | | roomId = optionalQueueDO.get().getRoomId(); |
| | | } |
| | | |
| | | List<Integer> queueStatusList = new ArrayList<>(); |
| | | queueStatusList.add(QueueStatusEnum.RECEIVED.getStatus()); |
| | | queueStatusList.add(QueueStatusEnum.PASSED_INSTALL.getStatus()); |