Merge dev into feature/1716-accounts-and-groups

This commit is contained in:
Marek Wolan
2023-08-09 09:18:06 +01:00
17 changed files with 719 additions and 9 deletions

View File

@@ -124,7 +124,15 @@ class ActionManager:
class SimComponent(BaseModel):
"""Extension of pydantic BaseModel with additional methods that must be defined by all classes in the simulator."""
"""Extension of pydantic BaseModel with additional methods that must be defined by all classes in the simulator."""
uuid: str
"""The component UUID."""
def __init__(self, **kwargs):
if not kwargs.get("uuid"):
kwargs["uuid"] = str(uuid4())
super().__init__(**kwargs)
model_config = ConfigDict(arbitrary_types_allowed=True, extra=Extra.allow)
uuid: str = str(uuid4())