Simplify db ORM method names

This commit is contained in:
3wc
2023-10-27 21:01:45 +01:00
parent 23e90a4413
commit 8908290c4d
2 changed files with 5 additions and 5 deletions

View File

@ -38,7 +38,7 @@ class Category(BaseORM):
)
@staticmethod
def list_categories(db_manager, filter_query=None):
def list(db_manager, filter_query=None):
cursor = db_manager.get_cursor()
where = ""
if filter_query is not None:
@ -120,7 +120,7 @@ class Activity(BaseORM):
self.conn.commit()
@staticmethod
def list_activities(db_manager, filter_query=None):
def list(db_manager, filter_query=None):
cursor = db_manager.get_cursor()
where = ""
if filter_query is not None:
@ -195,7 +195,7 @@ class Fact(BaseORM):
super().__init__(db_manager, "facts", id, activity_id=activity_id)
@staticmethod
def list_facts(db_manager):
def list(db_manager):
cursor = db_manager.get_cursor()
cursor.execute("SELECT * FROM facts")
rows = cursor.fetchall()