From 6dfc06d59325fd2ea6eb83369268f21adba1cd80 Mon Sep 17 00:00:00 2001 From: bionel Date: Sat, 23 Sep 2017 22:23:23 +0300 Subject: remove virtuals from listed packages --- src/frontend/gui/sisyphus-gui.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/frontend/gui') diff --git a/src/frontend/gui/sisyphus-gui.py b/src/frontend/gui/sisyphus-gui.py index e0b112a..d27a171 100755 --- a/src/frontend/gui/sisyphus-gui.py +++ b/src/frontend/gui/sisyphus-gui.py @@ -96,6 +96,7 @@ class Sisyphus(QtWidgets.QMainWindow): def loadDatabase(self): with sqlite3.connect('/var/lib/sisyphus/db/sisyphus.db') as db: cursor=db.cursor() + filterOut = "'%" + "virtual" + "%'" cursor.execute('''SELECT a.category AS cat, a.name AS pn, @@ -108,7 +109,8 @@ class Sisyphus(QtWidgets.QMainWindow): AND a.name = i.name AND a.slot = i.slot WHERE %s LIKE %s %s - ''' % (Sisyphus.SEARCHFIELD, Sisyphus.SEARCHTERM, Sisyphus.SEARCHFILTER)) + AND cat NOT LIKE %s + ''' % (Sisyphus.SEARCHFIELD, Sisyphus.SEARCHTERM, Sisyphus.SEARCHFILTER, filterOut)) rows = cursor.fetchall() Sisyphus.PKGCOUNT = len(rows) Sisyphus.PKGSELECTED = 0 -- cgit v1.2.3