[models] Add __str__ function for all serialized models (for debug)
This commit is contained in:
parent
d2ef02c2af
commit
a479d0c0ee
|
@ -39,6 +39,9 @@ class ModelSerializeMixin:
|
||||||
key, value = d.popitem()
|
key, value = d.popitem()
|
||||||
return value
|
return value
|
||||||
return d
|
return d
|
||||||
|
|
||||||
|
def __str__(self) -> str:
|
||||||
|
return self.serialize().__str__()
|
||||||
|
|
||||||
|
|
||||||
class Serial(TypeDecorator):
|
class Serial(TypeDecorator):
|
||||||
|
|
Loading…
Reference in New Issue