Template:ModelVersionTemplate: Difference between revisions

From IMAGE
Jump to navigation Jump to search
No edit summary
No edit summary
 
(97 intermediate revisions by the same user not shown)
Line 5: Line 5:
{{ModelVersionTemplate
{{ModelVersionTemplate
|hasDescription=
|hasDescription=
|hasNamespace=
|hasVersionDocument=
|isVersionOf=
|isVersionOf=
|versionNumber=
}}
}}
</pre>
</pre>
Edit the page to see the template text.
Edit the page to see the template text.
</noinclude><includeonly>
</noinclude><includeonly>
This version of {{{isVersionOf|}}} is documented in the {{{hasNamespace|}}} namespace.
<div class="page_standard"><table class="PageWidthTableTemplate">
 
<tr><td class="PageWidthTableFirstCell">'''Version of Model:'''</td>
Version description: {{{hasDescription|}}}
<td class="PageWidthTableRemainderCell">[[{{{isVersionOf|}}}]]</td></tr>
<!-- If there is a previous version, check whether the IsCurrenVersion of that previous version is false-->
<tr><td class="PageWidthTableFirstCell">'''Version number:'''</td>
<td class="PageWidthTableRemainderCell">{{{versionNumber|}}}</td></tr>
<tr><td class="PageWidthTableFirstCell">'''Current version:'''</td>
<td class="PageWidthTableRemainderCell">{{{isCurrentVersion|}}}</td></tr>
<tr><td class="PageWidthTableFirstCell">'''Description:'''</td>
<td class="PageWidthTableRemainderCell">{{{hasDescription|}}}</td></tr>
{{#ifeq:{{{hasVersionDocument|}}}|||
<tr><td class="PageWidthTableFirstCell">'''Archive of this version:'''</td>
<td class="PageWidthTableRemainderCell">{{{hasVersionDocument|}}}, [[Media:{{{hasVersionDocument|}}}| open pdf file]]</td></tr>
}}
</table>


previous version has boolean value {{#ask:{{{hasPrevVersion|}}}|?IsCurrentVersion}} for current version
{{#ifeq:{{#show:{{PAGENAME}}|?IsChanged}}|true|
''Changes compared to previous version:''
{{#arraymap:
  {{#ask:[[-Has subobject::{{PAGENAME}}]]|link=none|format=Plainlist|sep=;}}
  |;|zz
  |{{#ask:[[zz]]|mainlabel=-
                |? IsChangeOf
                |? HasChangeDescription
                |format=Plainlist
                |template=ChangeTemplate
                |intro=<table  class="PageWidthTableTemplate">
                |outro=  </table>
    }}
    |<br/>}}
|}}


{{#if:{{{hasPrevVersion|}}}||
See {{#show:{{{isVersionOf|}}}|? HasVersionOverview}}  
|{{#if:{{{hasNamespace|}}}
</div>
  |main
{{#ifeq:{{#ask:[[-Has subobject::{{PAGENAME}}]]|format=count}}
  |{{#if:{{#ask:{{{hasPrevVersion|}}}|? IsCurrentVersion}}
|0
    |1
|{{#set:IsChanged=false}}
    |Previous version and this version both has a 'is current version' = true. Please  set {{{hasPrevVersion|}}} to false!
|{{#set:IsChanged=true}}
    |
  }}
  |
  }}
}}
}}
See components:
{{#ask:[[-IsImplementationOf::{{{isVersionOf|}}}]]
|format=ul }}
{{#if:{{{hasNamespace|}}}|main|{{#set:IsCurrentVersion=1}}|{{#set:IsCurrentVersion=0}} }}
{{#set:HasDescription={{{hasDescription|}}}  
{{#set:HasDescription={{{hasDescription|}}}  
| HasNamespace={{{hasNamespace|}}}  
| IsCurrentVersion={{{isCurrentVersion}}}
| HasVersionDocument={{{hasVersionDocument|}}}  
| IsVersionOf={{{isVersionOf|}}}  
| IsVersionOf={{{isVersionOf|}}}  
| HasVersionNumber={{{versionNumber|}}}
}}  
}}  
[[Category:ModelVersion]]
[[Category:ModelVersion]]
</includeonly>
</includeonly>

Latest revision as of 12:17, 23 March 2020

This is the "ModelVersionTemplate" template. It should be called in the following format:

{{ModelVersionTemplate
|hasDescription=
|hasVersionDocument=
|isVersionOf=
|versionNumber=
}}

Edit the page to see the template text.