added first searchmodal draft

This commit is contained in:
2026-06-24 00:58:45 +02:00
parent a542d23c00
commit b7bc8f5525
9 changed files with 175 additions and 53 deletions
@@ -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());
}