Expand description
A snapshot of a chapter, course module or course’s settings after every save. Page history
lives in page_history.
Structs§
- Entity
History Entry - One history row; see
insert. - Entity
Version - The newest history row of an entity: who last changed it and when.
- History
Author - Who made a change that history records.
Enums§
- Entity
History Change Reason - Why a history row was written.
Functions§
- get_
by_ id - The history row.
- insert
- Records
snapshotas a new history row. Only chapters, modules and course settings have history; the database refuses other entity types. - latest_
version - The newest
page_historyorentity_historyrow of the page, chapter, module or course settings with the id, only in the course whencourse_idis given.Nonefor glossary terms and references, which have no history, and for entities never saved since history was introduced. - record_
current record_current_manyof one entity.- record_
current_ many - Records the current state of the entities as saved, as
record_saveddoes. Deleted and missing entities are skipped. - record_
deleted - Records the entity’s current state as deleted. Call it before deleting the entity; does nothing if it is already gone.
- record_
saved - Records each snapshot as saved, except those equal to their entity’s latest history row.
- save_
recording - Runs
savein a transaction and then records the entity’s state asrecord_currentdoes.