Utilisateur:Deeploz/Template:UpToDate History

< Utilisateur:Deeploz
Revision as of 10:36, 22 February 2017 by Deeploz (talk | contribs) (Page créée avec « <includeonly>{{#ifexist:{{{1|}}}/version|{{#ifeq: {{{{{1|}}}/version}}|{{{2|}}}|{{#ifexist:{{{3|}}}/version|{{#ifeq: {{{{{3|}}}/version}}|{{{4|}}}|{{#ifexist:{{{5|}}}/vers... »)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Documentation[view] [edit] [history] [purge]

this template checks the validity of a page that is based on (or translated from) content hosted in other pages.

To check the validity, the template retrieves the version number of each source page and compares it with an expected version number.

The template allow to declare up to 3 source pages with their expected version number.

If one of the source page is significantly updated, resulting in a version change, the template will detect the difference with the new version of the source page and the old expected version and display a warning banner and a red traffic light in the page title line. Otherwise, if validated, a green traffic light is displayed in the page title line


{{ UpToDate
|source page #1| expected version for source page #1
|source page #2| expected version for source page #2
|source page #3| expected version for source page #3

The second and third line above are optional, according to the number of source pages that are used to build the content of the current page.


If a page has been built by aggregating content from 3 different pages, Alpha, Beta and Gamma, respectively in version 1.3, 2.2 and 1.0, the following template should be added at the top of the body.

{{ UpToDate
|Alpha| 1.3
|Beta| 2.2
|Gamma| 1.0

Future improvement

  • The current template currently works at a page level for the source page and does not identify change at the section level only.
    • If a change occurs only in a section of the source page, the version increase will impact the whole page and trigger all templates pointing to this source page, even if the destination page is not using the modified section.
    • The template (and the whole mechanism) should be improved to include a section per section validity check.
  • The current template has no recursive capabilities.
    • if the source page is transcluding a content from another page, a change on this other page won't trigger a version increase on the source page, thus won't trigger the template.
    • This will require further investigation to find a efficient way to propagate a change through transclusion.
The above documentation is transcluded from Utilisateur:Deeploz/Template:UpToDate/doc.
Please add categories to the /doc subpage.
Subpages of this page.