Template:InfoBoxTemplate: Difference between revisions

From IMAGE
Jump to navigation Jump to search
No edit summary
No edit summary
(98 intermediate revisions by 4 users not shown)
Line 2: Line 2:
It should be called in the following format:
It should be called in the following format:
<pre>
<pre>
{{InfoBoxtemplate
{{InfoBoxtemplate}}
|PagePartHeader=
|Application=
|IMAGEComponent=
|ExternalModel=
|KeyReference=
|Reference=
}}
</pre>
</pre>
</noinclude><includeonly>
</noinclude><includeonly><!--
{{#ifexpr:{{InfoboxTestTemplate|basepage={{#titleparts: {{PAGENAME}}|1}}|subpage={{#titleparts: {{PAGENAME}}|1|2}} }}|
check the need for an infobox on this page (most recent version is the norm)
<div style="float:right; clear:right; ">
-->{{#ifeq:{{InfoboxTestTemplate|basepage={{ROOTPAGENAME}}|subpage={{SUBPAGENAME}} }}|0|| <!--
{{InfoBoxStyleTemplate}}
existing data for infobox
{{#ifexpr:{{PropertyTestTemplate|prop=belongsToPage|page={{PAGENAME}}|reverse=1}}>0|
--><div class="InfoBoxTemplateClear"><table class="InfoBoxStyle"> <!--
  <tr>{{InfoBoxCellStyleTemplate}}<b>{{{PagePartHeader|}}}</b></td></tr>
-->{{#ifeq: {{#ask:[[-HasVersionOverview::<q>[[IsImplementationOf::{{ROOTPAGENAME}}]]</q>]]|format =count}}|0||
  <tr><td>
<tr><td class="InfoBoxCellStyleTemplate">Version Overviews</td></tr>
   <ul>
<tr><td>
{{#ask:[[{{PAGENAME}}]]|mainlabel=|? HasPageLabel=|link=none|format=template|template=PagePartTemplate}}
{{#ask:[[IMAGE framework version overview]]|format=ul}}
{{#ask: [[BelongsToPage:: {{PAGENAME}}]]|mainlabel=|? HasPageLabel=|? HasSequence=|sort=HasSequence|link=none|format=template|template=PagePartTemplate}}
{{#ask:[[-HasVersionOverview::<q>[[IsImplementationOf::{{ROOTPAGENAME}}]]</q>]]|format=ul}}
</ul>
</td></tr>
  </td></tr>
}}<!-- model of component and version
|}}
-->{{#ifeq:{{PropertyTestTemplate|prop=IsImplementationOf|page={{ROOTPAGENAME}}|reverse=1 }}|0||
{{#ifeq:{{{IMAGEComponent|}}}|||
<tr><td class="InfoBoxCellStyleTemplate">Component is implemented in:</td></tr>
  <tr>{{InfoBoxCellStyleTemplate}}<b>Related IMAGE components</b></td></tr>
<tr><td>{{#arraymap:
  <tr><td>
   {{#ask:[[Concept:ModelWithVersion]][[IsImplementationOf::{{ROOTPAGENAME}}]]|link=none|sep=;}}
  <ul>
  |;|yy
  {{#arraymaptemplate:{{{IMAGEComponent|}}}|ComponentHasIMAGEComponentTemplate|;|}}
  |{{#arraymap: {{#ask:[[Category:ModelVersion]][[IsVersionOf::yy]]|link=none|sep=;}}
  </ul>
    |;|xx
  </td></tr>
    |{{#ifeq:{{#ask:[[IsCurrentVersion::true]][[IsVersionOf::yy]]|link=none}}|xx
}}
      |<ul><li>yy (version {{#show:xx|? HasVersionNumber}})</li></ul>
{{#ifeq:{{{Application|}}}|||
      {{#ask:[[Category:AggregatedComponent]][[-IsImplementationOf::yy]]
  <tr>{{InfoBoxCellStyleTemplate}}<b>Projects/Applications</b></td></tr>
        |intro=Aggregated component:|format=ul
  <tr><td>
      }}{{#ask:[[Category:Component]][[-IsImplementationOf::yy]]
  <ul>
          |intro=Components:|format=ul}}
  {{#arraymaptemplate:{{{Application|}}}|ComponentHasApplicationTemplate|;|}}
    |}}   
  </ul>
  |}}
  </td></tr>
| and }}
}}
</td></tr><!--
{{#ifeq:{{{ExternalModel|}}}|||
-->{{#ifeq:{{PropertyTestTemplate|prop=HasIMAGEComponent|page={{#titleparts: {{FULLPAGENAME}}|1}} }}|0||
  <tr>{{InfoBoxCellStyleTemplate}}<b>External models</b></td></tr>
<tr><td class="InfoBoxCellStyleTemplate">Related IMAGE components</td></tr>
  <tr><td>
<tr ><td>{{#ask:[[-HasIMAGEComponent::{{#titleparts: {{FULLPAGENAME}}|1}}]]|format=ul}}
  <ul>
</td></tr>}}
  {{#arraymaptemplate:{{{ExternalModel|}}}|ComponentHasExternalModelTemplate|;|}}
}}<!--
  </ul>
-->{{#ifeq:{{PropertyTestTemplate|prop=HasApplication|page={{#titleparts: {{FULLPAGENAME}}|1}} }}|0||
  </td></tr>
<tr><td class="InfoBoxCellStyleTemplate">Projects/Applications</td></tr>
}}
<tr><td>{{#ask:[[-HasApplication::{{#titleparts: {{FULLPAGENAME}}|1}}]]|format=ul}}
{{#ifeq:{{#ask:[[Category:Computer Model]][[IsImplementationOf::{{PAGENAME}}]]|format=count}}|0||
</td></tr>}}<!--
  <tr>{{InfoBoxCellStyleTemplate}}<b>Implemented in computer model</b></td></tr>
-->{{#ifeq:{{PropertyTestTemplate|prop=HasModelDatabase|page={{#titleparts: {{FULLPAGENAME}}|1}} }}|0||
  <tr><td>
<tr><td class="InfoBoxCellStyleTemplate">Models/Databases</td></tr>
  {{#ask:[[Category:Computer Model]][[IsImplementationOf::{{PAGENAME}}]]  
<tr><td>{{#ask:[[-HasModelDatabase::{{#titleparts: {{FULLPAGENAME}}|1}}]]|format=ul}}
    |format=ul
</td></tr>}}<!--
  }}</td></tr>
-->{{#ifeq:{{PropertyTestTemplate|prop=HasOverview|page={{#titleparts: {{FULLPAGENAME}}|1}} }}|0||
}}
<tr><td class="InfoBoxCellStyleTemplate">Relevant  overviews</td></tr>
{{#ifeq:{{{KeyReference|}}}|||
<tr><td>{{#ask:[[-HasOverview::{{#titleparts: {{FULLPAGENAME}}|1}}]]|format=ul}}
  <tr>{{InfoBoxCellStyleTemplate}}<b>Key references</b></td></tr>
</td></tr>}}<!--
  <tr><td>
-->{{#ifeq:{{PropertyTestTemplate|prop=HasKeyReference|page={{#titleparts: {{FULLPAGENAME}}|1}} }}|0||
  <ul>
<tr><td class="InfoBoxCellStyleTemplate">Key publications</td></tr>
  {{#arraymaptemplate:{{{KeyReference|}}}|ComponentHasKeyReferenceTemplate|;|}}
<tr><td><tr><td>{{#ask:[[-HasKeyReference::{{#titleparts: {{FULLPAGENAME}}|1}}]]|format=ul}}
  </ul>
</td></tr>}}<!--
  </td></tr>
-->{{#ifeq:{{PropertyTestTemplate|prop=HasReference|page={{FULLPAGENAME}} }}|0||
}}
<tr><td class="InfoBoxCellStyleTemplate">References</td></tr>
{{#ifeq:{{{Reference|}}}|||
<tr><td class="mw-collapsible mw-collapsed">
  <tr>{{InfoBoxCellStyleTemplate}}<b>References</b></td></tr>
{{#ask:[[-HasReference::{{FULLPAGENAME}}]]|format=ul}}
  <tr><td>
</td></tr>
  <ul>
  {{#arraymaptemplate:{{{Reference|}}}|ComponentHasReferenceTemplate|;|}}
  </ul>
  </td></tr>
}}
}}
</table>
</table>
</div>
</div>
|}}
}}<!--
</includeonly>
--></includeonly>

Revision as of 08:13, 1 August 2017

It should be called in the following format:

{{InfoBoxtemplate}}