cattle_grid.extensions.examples.context ¶
Extension to add information to the context
See FEP-f228
This extension requires the muck out extension to be installed.
models ¶
Base ¶
Bases: AsyncAttrs
, DeclarativeBase
Base model
ContextInformation ¶
Bases: Base
Contains information about the context
Source code in cattle_grid/extensions/examples/context/models.py
context_id
class-attribute
instance-attribute
¶
context_id: Mapped[bytes] = mapped_column(
UUIDType(binary=True)
)
The id (uuid as bytes)
object_id
class-attribute
instance-attribute
¶
object_id: Mapped[str] = mapped_column(String(256))
The object in this context
parent_id
class-attribute
instance-attribute
¶
parent_id: Mapped[str | None] = mapped_column(
String(256), default=None
)
id of the post, that was replied to