added first searchmodal draft
This commit is contained in:
@@ -15,11 +15,17 @@ import com.vaessl.app.connection.HomeboxEntity;
|
||||
import com.vaessl.app.exception.ConnectionNotFoundException;
|
||||
import com.vaessl.app.exception.RemoteApiException;
|
||||
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
|
||||
import static com.vaessl.app.connection.Endpoint.*;
|
||||
|
||||
@Component
|
||||
public class HomeboxSearchProvider implements SearchProvider {
|
||||
|
||||
// TODO: Remove logger before merge
|
||||
private static final Logger log = LoggerFactory.getLogger(HomeboxSearchProvider.class);
|
||||
|
||||
private final RestClient.Builder restClientBuilder;
|
||||
|
||||
private final ConnectionRepository cRepository;
|
||||
@@ -64,6 +70,8 @@ public class HomeboxSearchProvider implements SearchProvider {
|
||||
return new SearchResponse(title, description, extraSearchResponseData);
|
||||
}).toList();
|
||||
|
||||
log.info("Search results for query '{}': {}", request.query(), items);
|
||||
|
||||
return new PageImpl<>(items, pageable, hbResponse.total());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user