format:page:technique
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédente | |||
| format:page:technique [2016/10/28 18:05] – [Les mises en places indispensables] florence | format:page:technique [2026/11/13 20:37] (Version actuelle) – modification externe 127.0.0.1 | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| - | ===== Format | + | < |
| - | ==== Capacités | + | ===== Page format: Technical guide ===== |
| + | < | ||
| + | ==== Capabilities | ||
| - | * [[FormatPageCapabilities|Capacités du format page]] | + | |
| - | ==== Ecouteurs d' | + | < |
| - | * Création de module : réordonne et consolide le plan de sections | + | ==== Event listeners ==== |
| - | * Destruction de module : réordonne et consolide le plan de sections | + | |
| - | * Destruction de cours : nettoye les tables complémentaires du format page | + | |
| - | ==== Compléments sur la mise en oeuvre ==== | + | * Module creation: reorders and consolidates the section plan |
| + | * Module deletion: reorders and consolidates the section plan | ||
| + | * Course deletion: cleans the page format' | ||
| - | Le format page est un format très puissant qui demande un peu de technique d' | + | ==== Additional notes on implementation ==== |
| - | Depuis sa version d' | + | The page format is a very powerful |
| - | * Soit concernent le theme, qui est l'un des endroits traditionnellement customisés des Moodle | + | Since its original version for Moodle 2.3, a big effort has been made to get rid of as many patches in the Moodle core as possible. This architectural work is now complete. The page format, for normal operation, must nevertheless be preceded by a rigorous setup of some superficial overrides of Moodle' |
| - | * Soit concerne des customscripts de remplacement de certains points d'entrée | + | |
| - | ==== Les mises en places | + | * Either concern the theme, which is one of the places |
| + | * Or concern customscripts replacing some standard Moodle entry points. | ||
| - | === Le remplacement de la vue de cours === | + | ==== Essential setups ==== |
| - | Moodle prévoit que le gestionnaire de blocs soit basé sur un design pattern de " | + | === Replacing the course view === |
| - | Malheureusement, | + | Moodle provides for the block manager to be based on a "Factory" |
| - | La distribution du format page propose dans un répertoire // | + | Unfortunately, |
| - | * Créer un répertoire | + | The page format distribution offers, in a // |
| - | | + | |
| - | | + | * Creating a // |
| + | | ||
| + | | ||
| Ligne 38: | Ligne 42: | ||
| - | ==== Les mises en place facultatives | + | ==== Optional setups |
| - | Ces mises en place n' | + | These setups do not prevent the page format from working correctly, but can add greater |
| - | === Navigation paginée dans les surcharges de page par des activités | + | === Paginated navigation in page overrides by activities |
| - | Lorsqu' | + | When a page is entirely overridden by an activity, the course reading sequence is stopped on the activity to play it through its different screens. The display context leaves the course and goes into that of the activity, which most often unfolds with " |
| - | Pour les autres qui ne le prévoient pas, il est nécessaire de rajouter quelques contournements par des customscripts, | + | For the others that do not provide for it, some workarounds through |
| - | ATTENTION, toutes les activités ne sont pas architecturées pour admettre un contournement facile. Les plus adéquates sont celles qui font un appel explicite à : | + | :!: WARNING, not all activities are architected to allow an easy workaround. The most suitable are those that make an explicit call to: |
| echo $OUTPUT-> | echo $OUTPUT-> | ||
| - | dans la vue à surcharger | + | In the view to override |
| - | A ce moment, vous pouvez copier cette vue dans un répertoire isomorphe dans les customscripts, | + | At that point, you can copy this view into an isomorphic directory in the customscripts, |
| if ($course-> | if ($course-> | ||
| Ligne 61: | Ligne 65: | ||
| } | } | ||
| - | Comme pour toutes les surcharges par // | + | As for all overrides by // |
| die; | die; | ||
| - | après avoir appelé le // | + | After calling the // |
| + | ==== Page structure repair procedures ==== | ||
| + | |||
| + | It can still happen, in some cases of complex manipulations, | ||
| + | |||
| + | * / | ||
| + | |||
| + | For a given course <IDC> | ||
| + | |||
| + | cd < | ||
| + | sudo -u< | ||
| + | |||
| + | (*) A comma-separated list of ids can be given to the command. Without the --courses parameter, the correction runs on the whole platform, for all detected page format courses. It is advised to back up the database before a global correction operation. | ||
| + | (**) Note that badly attached modules are recovered and reattached in the sections/ | ||
| + | |||
| + | < | ||
| + | |||
| + | ---- | ||
| + | [[format: | ||
| - | [[format: | + | < |
format/page/technique.1477670732.txt.gz · Dernière modification : (modification externe)
