added base of instance parenting

This commit is contained in:
Jakub Trllo 2025-07-14 17:11:19 +02:00
parent 5b277d1251
commit 6064f095c8
2 changed files with 11 additions and 0 deletions

View file

@ -653,6 +653,10 @@ class CreatedInstance:
def product_name(self):
return self._data["productName"]
@property
def parent_instance_id(self) -> Optional[str]:
return self._data.get("parentInstanceId")
@property
def label(self):
label = self._data.get("label")

View file

@ -219,6 +219,7 @@ class InstanceItem:
is_active: bool,
is_mandatory: bool,
has_promised_context: bool,
parent_instance_id: Optional[str],
):
self._instance_id: str = instance_id
self._creator_identifier: str = creator_identifier
@ -232,6 +233,7 @@ class InstanceItem:
self._is_active: bool = is_active
self._is_mandatory: bool = is_mandatory
self._has_promised_context: bool = has_promised_context
self._parent_instance_id: Optional[str] = parent_instance_id
@property
def id(self):
@ -261,6 +263,10 @@ class InstanceItem:
def has_promised_context(self):
return self._has_promised_context
@property
def parent_instance_id(self):
return self._parent_instance_id
def get_variant(self):
return self._variant
@ -312,6 +318,7 @@ class InstanceItem:
instance["active"],
instance.is_mandatory,
instance.has_promised_context,
instance.parent_instance_id,
)