Skip to main content

Module snapshots

Module snapshots 

Source
Expand description

Conversions between the stored entity snapshots and the documents the edit engines work on.

Structs§

PageFacts
Live facts about pages that the course tree shows.

Functions§

apply_glossary
Replaces the glossary terms and references with the document’s.
apply_page_documents
Sets the blocks of each page in documents.
apply_settings
Writes the editable fields of the settings document back. Read-only fields are left alone.
apply_structure
The state after the structure engine turned before into after. contents holds the blocks of new pages. Order numbers change only in lists whose order changed.
completion_policy 🔒
glossary_document
The glossary and references document of the glossary tool.
increasing_order_numbers 🔒
Order numbers for a list in its new order, given each entry’s current number (None if new). The first gets 0, reserved for front pages and the default module; the others keep theirs while strictly increasing, so only added, moved and pushed entries are renumbered.
list_order_numbers 🔒
New order numbers for the list after (entries with their current number, None if new), or all None (keep every number) when the order equals before_ids. A list with no before_ids is renumbered.
model_completion_policy 🔒
page_document
The page with its editor context, or None if the course has no such page.
page_lists 🔒
page_ref
The page with its editor context, borrowed.
page_refs
Every page of the course with its editor context, borrowed.
page_type
The editor context the page’s blocks are checked in.
settings_document
The settings document of the settings tool: the course’s own settings and its modules’.
structure
The course tree the structure engine edits, with the live facts of its pages.
structure_page 🔒