Difference between revisions of "Template:Linked Articles"

From AquaPedia Case Study Database
Jump to: navigation, search
 
(21 intermediate revisions by the same user not shown)
Line 8: Line 8:
 
|Agreements=
 
|Agreements=
 
|Riparians=
 
|Riparians=
 +
|The Pagename= (name of referred page)
 +
|Page Type=
 
}}
 
}}
 
</pre>
 
</pre>
Line 13: Line 15:
 
</noinclude><includeonly>
 
</noinclude><includeonly>
  
{{#if: {{{Water Features|}}} | ==Water Features== |\n }}  
+
{|  style="margin: 1em auto 1em auto;text-align:left;width:100%"
{{#if: {{{Water Features|}}} | {{#arraymap:{{{Water Features}}}|;|x|[[Water Feature::x]]}} | \n }}  
+
! |  Riparians
 +
! |  Water Features
 +
|-
 +
| style="border-top: 1px solid #eeeeee;margin-right:5px;width:40%;" |
 +
<!--Riparians -->
 +
{{#ifeq: {{{Page Type|}}} | Water Feature | {{#ask:[[Riparian in Basin::+]][[Basin::{{{The Pagename|}}}]] |?Riparian=Located in this basin- |format=list |headers=plain |mainlabel=- |link=all |sep=<BR> |offset= |limit= |outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Riparian | {{#ask:[[Located in::{{{The Pagename|}}}]]|format=list|headers=hide|mainlabel=located within|link=subject|columns=1|offset=|limit=|intro=Located within|default=|outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Agreement |{{#ask: [[{{{The Pagename|}}}]]|?Agreement Includes Riparian=Agreement includes riparian-|format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask:[[{{{The Pagename|}}}]]|?Project in Riparian=Project is in- ||format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=|outro=<BR>}} }}
 +
{{#if: {{{Riparians|}}} | {{#arraymap:{{{Riparians}}}|;|x|Other -  [[Riparian::x]] | <BR>}} | }}
  
{{#if: {{{Riparians|}}} |  ==Riparians==|\n }}  
+
| style="border-top: 1px solid #eeeeee;margin-right:5px;width:40%;" |
{{#if: {{{Riparians|}}} | {{#arraymap:{{{Riparians}}}|;|x|*[[Riparian::x]]}} | \n }}  
+
<!--Features -->
 +
{{#ifeq: {{{Page Type|}}} | Water Feature | {{#ask: [[{{{The Pagename|}}}]]|?Within Basin=Located in basin- |format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=&#32; |outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Feature | {{#ask:[[Within Basin::{{{The Pagename|}}}]]|?=Feature in this basin- |format=list |headers=show|mainlabel=- | link=all|offset=|limit=|default=&#32; |outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask: [[{{{The Pagename|}}}]]|?Project in Basin=Project is in basin- |format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=&#32;|outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Riparian | {{#ask:[[Water Resource in Riparian::+]][[Riparian::{{{The Pagename|}}}]] |?Riparian=Located in riparian-  |format=list|headers=hide|mainlabel=-|link=subject|columns=1|offset=|limit=|intro=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Agreement | {{#ask: [[{{{The Pagename|}}}]]|?Agreement Includes Resource=Includes Water Resource- |format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask:[[{{{The Pagename|}}}]]|?Reservoir=Associated Reservoir- |format=list| headers=plain|mainlabel=-|link=all|offset=|limit=|default=&#32; |outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask:[[{{{The Pagename|}}}]]|?Project on River=Dam located on- |format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=&#32; |outro=<BR>}} }}
 +
{{#if: {{{Water Features|}}} | {{#arraymap:{{{Water Features}}}|;|x|Other - [[Water Feature::x]] | <BR>}} | }}
  
{{#if: {{{Water Projects|}}} | ==Projects and Initiatives==|\n }}
+
|}
{{#if: {{{Water Projects|}}} | {{#arraymap:{{{Water Projects}}}|;|x|*[[Water Project::x]]}} | \n}}
+
 
+
{{#if: {{{Agreements|}}} |  ==Agreements or Treaties== |\n  }}
+
{{#if: {{{Agreements|}}} |  {{#arraymap:{{{Agreements|}}}|;|x|*[[Agreement::x]]}} | \n}}  
+
  
 +
{|  style="margin: 1em auto 1em auto;text-align:left;width:100%;"
 +
! |  Projects and Initiatives
 +
! | Agreements and Treaties
 +
|-
 +
| style="border-top: 1px solid #eeeeee;margin-right:5px;width:40%;" |
 +
<!--Projects -->
 +
{{#ifeq: {{{Page Type|}}} | Agreement | {{#ask: [[{{{The Pagename|}}}]]|?Agreement Includes Water Project=Agreement includes- |format=list|sep=, |mainlabel=-|headers=plain|link=subject|columns=1|offset=|limit=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask: [[{{{The Pagename|}}}]]|?Water Projects Influenced by Agreement=Affects- |format=list|sep=, |headers=plain|mainlabel=-|link=subject|offset=|limit=|outro=<BR>|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask: [[{{{The Pagename|}}}]]|?Associated Water Project=Associated Projects- <BR> |format=list|sep=, |headers=plain|mainlabel=-|link=all|offset=|limit=|default=&#32;|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project | {{#ask: [[{{{The Pagename|}}}]]|?Related Initiatives or Commissions=Associated organizational projects- |format=list|sep=, |headers=plain|mainlabel=-|link=subject|offset=|limit=|intro=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Agreement | {{#ask: [[{{{The Pagename|}}}]]|?Related Initiatives or Commissions=Associated organizational projects- |format=list|sep=, |headers=plain|mainlabel=-|link=subject|offset=|limit=|intro=|default=|outro=<BR>}} }}{{#ifeq: {{{Page Type|}}} | Water Project|{{#ask:[[Project In Riparian::{{{The Pagename|}}}]] |?=located in {{{The Pagename|}}}# |format=list |headers=show |mainlabel=located in {{{The Pagename|}}} |link=all|sep=<BR> |offset=|limit=}} }}
 +
{{#if: {{{Water Projects|}}} | {{#arraymap:{{{Water Projects}}}|;|x|Other - [[Water Project::x]] | <BR>}}  | }}
 +
| style="border-top: 1px solid #eeeeee;margin-right:5px;width:40%;" |
 +
<!--Agreements -->
 +
{{#ifeq: {{{Page Type|}}} | Agreement| {{#ask: [[{{{The Pagename|}}}]]||?Previous Agreement=Previous agreement was- |format=list| sep=, |headers=plain|mainlabel=-|link=all|columns=1|offset=|limit=|default=|outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Agreementt|{{#ask: [[Previous Agreement::{{{The Pagename|}}}]]|?=Subsequent agreement is-|format=list|headers=plain|mainlabel=-|link=all|columns=1|offset=|limit=|default=|outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Water Project| {{#ask:[[Agreement Includes Water Project::{{{The Pagename|}}}]]|?=Included in|format=list|headers=plain|mainlabel=-|link=all|columns=1|offset=|limit=|default=|outro=<BR>}} }}
 +
{{#ifeq: {{{Page Type|}}} | Water Project| {{#ask:[[Water Projects Influenced by Agreement::{{{The Pagename|}}}]] |?=Influenced by Agreement |format=list|headers=plain|mainlabel=-|link=all|columns=1|offset=|limit=|default=}} }}
 +
{{#ifeq: {{{Page Type|}}} | Riparian |{{#ask: [[Agreement Includes Riparian::{{{The Pagename|}}}]]|?=Agreement includes riparian-|format=list|headers=plain|mainlabel=-|link=all|offset=|limit=|default=|outro=<BR>}} }}
 +
{{#if: {{{Agreements|}}} |  {{#arraymap:{{{Agreements|}}}|;|x|Other -  [[Agreement::x]] | <BR>}}  | }}
 +
<div style="clear:both;"></div>
 +
|}
 
</includeonly>
 
</includeonly>

Latest revision as of 13:54, 30 September 2014

This is the "Linked Articles" template. It is called by a main article template (e.g.: Water Feature) It should be called in the following format:

{{Linked Articles
|Water Features=
|Water Projects=
|Agreements=
|Riparians=
|The Pagename= (name of referred page)
|Page Type=
}}

Edit the page to see the template text.