attribute

This commit is contained in:
Hellow2 2023-03-13 14:33:17 +01:00
parent 25ddfc4997
commit 292bdfd2fa
3 changed files with 5 additions and 4 deletions

View File

@ -9,8 +9,8 @@ from .formatted_text import FormattedText
class Lyrics(DatabaseObject): class Lyrics(DatabaseObject):
COLLECTION_ATTRIBUTES = ["source_collection"] COLLECTION_ATTRIBUTES = ("source_collection",)
SIMPLE_ATTRIBUTES = ["text", "language"] SIMPLE_ATTRIBUTES = ("text", "language")
def __init__( def __init__(
self, self,

View File

@ -55,8 +55,8 @@ class Source(DatabaseObject):
Source(src="youtube", url="https://youtu.be/dfnsdajlhkjhsd") Source(src="youtube", url="https://youtu.be/dfnsdajlhkjhsd")
``` ```
""" """
COLLECTION_ATTRIBUTES = [] COLLECTION_ATTRIBUTES = tuple()
SIMPLE_ATTRIBUTES = ["type_enum", "page_enum", "url"] SIMPLE_ATTRIBUTES = ("type_enum", "page_enum", "url")
def __init__(self, page_enum: SourcePages, url: str, id_: str = None, type_enum=None) -> None: def __init__(self, page_enum: SourcePages, url: str, id_: str = None, type_enum=None) -> None:
DatabaseObject.__init__(self, id_=id_) DatabaseObject.__init__(self, id_=id_)

View File

@ -15,6 +15,7 @@ class Target(DatabaseObject):
""" """
SIMPLE_ATTRIBUTES = ("_file", "_path") SIMPLE_ATTRIBUTES = ("_file", "_path")
COLLECTION_ATTRIBUTES = tuple()
def __init__( def __init__(
self, self,