org.models.editor ================= .. py:module:: org.models.editor .. autoapi-nested-parse:: Contains the model describing the page editor. Attributes ---------- .. autoapisummary:: org.models.editor.PageActionWithoutPage Classes ------- .. autoapisummary:: org.models.editor.Editor Module Contents --------------- .. py:type:: PageActionWithoutPage :canonical: Literal['new', 'new-root'] .. py:class:: Editor(action: PageActionWithoutPage, page: None, trait: str) Editor(action: PageAction, page: org.models.traitinfo.TraitInfo, trait: str | None = None) Editor(action: Literal['new', 'new-root'], page: None, trait: str | None = None) Defines the model for the page editor. Required because pages need to be edited outside their url structure, since their urls are absorbed completely and turned into SQL queries. .. py:attribute:: action .. py:attribute:: page .. py:attribute:: trait :value: None .. py:method:: is_supported_action(action: str) -> TypeGuard[PageAction] :staticmethod: Returns True if the given action is supported. .. py:property:: page_id :type: int Returns the page id so morepath can create a link to this.