mirror of
https://github.com/spalencsar/bearhub.git
synced 2026-07-07 01:14:15 +02:00
appimage refactoring | limiting name, desc and publisher in the apps table
This commit is contained in:
@@ -112,7 +112,7 @@ class AppImageManager(SoftwareManager):
|
||||
if con:
|
||||
try:
|
||||
cursor = con.cursor()
|
||||
cursor.execute(query.FIND_APPS_LATEST_VERSIONS.format(','.join(names)))
|
||||
cursor.execute(query.FIND_APPS_BY_NAME.format(','.join(names)))
|
||||
|
||||
for tup in cursor.fetchall():
|
||||
for app in res.installed:
|
||||
|
||||
@@ -4,5 +4,5 @@ RELEASE_ATTRS = ('version', 'url_download', 'published_at')
|
||||
|
||||
SEARCH_APPS_BY_NAME_OR_DESCRIPTION = "SELECT {} FROM apps".format(','.join(APP_ATTRS)) + " WHERE lower(name) LIKE '%{}%' or lower(description) LIKE '%{}%'"
|
||||
FIND_APP_ID_BY_NAME_AND_GITHUB = "SELECT id FROM apps WHERE lower(name) = '{}' and lower(github) = '{}'"
|
||||
FIND_APPS_LATEST_VERSIONS = "SELECT name, github, version, url_download FROM apps WHERE lower(name) IN ({})"
|
||||
FIND_APPS_BY_NAME = "SELECT name, github, version, url_download FROM apps WHERE lower(name) IN ({})"
|
||||
FIND_RELEASES_BY_APP_ID = "SELECT {} FROM releases".format(','.join(RELEASE_ATTRS)) + " WHERE app_id = {} ORDER BY version desc"
|
||||
|
||||
Reference in New Issue
Block a user