From 79f7724923198e8ac17bd409507a6d2ad9de013c Mon Sep 17 00:00:00 2001 From: Remco Burema Date: Fri, 12 Nov 2021 14:30:09 +0100 Subject: [PATCH] Actually set search string + fix code style warnings. It now works! Sort of. Turns out you have to manually click 'Load More' each time now :-) This is also at least partially explains the 'cases' mentioned in previous commit (when switching tabs). part of CURA-8559 --- plugins/Marketplace/RemotePackageList.py | 2 +- plugins/Marketplace/resources/qml/ManagePackagesButton.qml | 2 +- plugins/Marketplace/resources/qml/Marketplace.qml | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/Marketplace/RemotePackageList.py b/plugins/Marketplace/RemotePackageList.py index 150d9901f1..156e7bbf0f 100644 --- a/plugins/Marketplace/RemotePackageList.py +++ b/plugins/Marketplace/RemotePackageList.py @@ -110,7 +110,7 @@ class RemotePackageList(PackageList): if self._package_type_filter != "": request_url += f"&package_type={self._package_type_filter}" if self._search_string != "": - request_url += f"" # TODO + request_url += f"&search={self._search_string}" return request_url def _parseResponse(self, reply: "QNetworkReply") -> None: diff --git a/plugins/Marketplace/resources/qml/ManagePackagesButton.qml b/plugins/Marketplace/resources/qml/ManagePackagesButton.qml index 31b97d89ed..a2ebfe0df7 100644 --- a/plugins/Marketplace/resources/qml/ManagePackagesButton.qml +++ b/plugins/Marketplace/resources/qml/ManagePackagesButton.qml @@ -18,7 +18,7 @@ Button background: Rectangle { color: backgroundColor - border.color: transparent + border.color: "transparent" radius: Math.round(width * 0.5) } diff --git a/plugins/Marketplace/resources/qml/Marketplace.qml b/plugins/Marketplace/resources/qml/Marketplace.qml index e92ac44c1d..7cfb68883f 100644 --- a/plugins/Marketplace/resources/qml/Marketplace.qml +++ b/plugins/Marketplace/resources/qml/Marketplace.qml @@ -170,9 +170,9 @@ Window function onLoaded() { pageTitle.text = content.item.pageTitle - searchStringChanged.connect(onSearchStringChanged) + searchStringChanged.connect(handleSearchStringChanged) } - function onSearchStringChanged(new_search) + function handleSearchStringChanged(new_search) { content.item.model.searchString = new_search }