Template:ContentPartsTemplate: Difference between revisions

From IMAGE
Jump to navigation Jump to search
No edit summary
No edit summary
(19 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<noinclude>
<noinclude>
Template to display the subpages of a page. subpage = 0 means main page and subpage = 1 subpage.
Template to display main page and subpages of an 'object'
It should be called in the following format:
<pre>
<pre>
{{ContentPartsTemplate
{{ContentPartsTemplate
|PagePartHeader=
|PagePartHeader=
|subpage
}}
}}
</pre>
</pre>
</noinclude><includeonly>
</noinclude><includeonly>
{{#ifexpr:{{PropertyTestTemplate
{{#ifexpr:{{PropertyTestTemplate
   |prop=belongsToPage
   |prop=BelongsToPage
   |page= {{#titleparts:{{PAGENAME}}|1}}
   |page= {{#titleparts:{{FULLPAGENAME}}|1}}
   |reverse=1}}>0
   |reverse=1}}>0
|
|
   <table align="left" class="toc"><tr><td><div><b>{{{PagePartHeader|}}}</b></div>
   <div class="toc">
<strong>{{{PagePartHeader|}}}</strong>
   <ol>
   <ol>
   {{#ask:[[ {{#titleparts:{{PAGENAME}}|1}}]]
   {{#ask:[[ {{#titleparts:{{FULLPAGENAME}}|1}}]]
   |mainlabel=
   |mainlabel=
   |? HasPageLabel=
   |? HasPageLabel=
Line 23: Line 22:
   |template=PagePartTemplate
   |template=PagePartTemplate
   }}
   }}
   {{#ask:[[BelongsToPage::{{#titleparts: {{PAGENAME}}|1}}]]
   {{#ask:[[BelongsToPage::{{#titleparts: {{FULLPAGENAME}}|1}}]]
   |mainlabel=
   |mainlabel=
   |? HasPageLabel=
   |? HasPageLabel=
Line 31: Line 30:
   |format=template
   |format=template
   |template=PagePartTemplate
   |template=PagePartTemplate
   }}
   }}{{addInfoPartsTemplate}}</ol></div>
  {{#ifexpr:{{PropertyTestTemplate
    |prop=belongsToTextPage
    |page= {{#titleparts:{{PAGENAME}}|1}}
    |reverse=1}}>0
  |
  <div style="text-indent:50px">Additional info </div>
    {{#ask:[[BelongsToTextPage::{{#titleparts: {{PAGENAME}}|1}}]]
    |mainlabel=
    |mainlabel=
    |link=none
    |format=template
    |template=PagePartTemplate
    }}
  |}}
  </ol></td></tr>
  </table>
|}}
|}}

Revision as of 19:15, 29 April 2016

Template to display main page and subpages of an 'object'

{{ContentPartsTemplate
|PagePartHeader=
}}