66from PyQt6 import uic , QtCore , QtWidgets
77
88from ...common import ConnectionTimeoutErrors
9- from ...dbmodel import APIInterrogator , DBExtract
9+ from ...dbmodel import DBExtract
1010
1111from ..api import get_ckan_api
1212from ..main import DCORAid
@@ -34,18 +34,18 @@ def __init__(self, *args, **kwargs):
3434
3535 @QtCore .pyqtSlot ()
3636 def on_refresh_private_data (self ):
37+ self .find_main_window ().check_update_database (force = True )
3738 self .setCursor (QtCore .Qt .CursorShape .WaitCursor )
3839 api = get_ckan_api ()
3940 data = DBExtract ()
4041 if api .is_available () and api .api_key :
4142 try :
42- db = APIInterrogator (api = api )
4343 if self .checkBox_user_following .isChecked ():
44- data += db .get_datasets_user_following ()
44+ data += self . database .get_datasets_user_following ()
4545 if self .checkBox_user_owned .isChecked ():
46- data += db .get_datasets_user_owned ()
46+ data += self . database .get_datasets_user_owned ()
4747 if self .checkBox_user_shared .isChecked ():
48- data += db .get_datasets_user_shared ()
48+ data += self . database .get_datasets_user_shared ()
4949 self .user_filter_chain .set_db_extract (data )
5050 except ConnectionTimeoutErrors :
5151 logger .error (tb .format_exc ())
@@ -64,5 +64,4 @@ def find_main_window():
6464 return widget
6565
6666 def set_database (self , database ):
67- # TODO: Use this database for searches
6867 self .database = database
0 commit comments