Difference between revisions of "Template:Generate concept formlinks from SMW import page"
From TDWG Terms Wiki
m (output delimiter arraymap) |
m (no red links) |
||
Line 31: | Line 31: | ||
-->{{#vardefine: thisHasType|{{#ask: [[{{#var: thisFullPageName}}]] | mainlabel=-|link=none|?Has type#=|format=list}}}}<!-- | -->{{#vardefine: thisHasType|{{#ask: [[{{#var: thisFullPageName}}]] | mainlabel=-|link=none|?Has type#=|format=list}}}}<!-- | ||
− | |||
− | |||
− | |||
check Has type (create a warning if mismatch) and existance (use different icons) | check Has type (create a warning if mismatch) and existance (use different icons) | ||
-->{{#ifexist: {{#var: thisFullPageName}}<!-- | -->{{#ifexist: {{#var: thisFullPageName}}<!-- | ||
− | then-->|{{#formlink: | + | then-->|[[{{#var: thisFullPageName}}|{{#var: thisVocabNoPrefix}}]] {{#formlink: |
form=Property setting<!-- | form=Property setting<!-- | ||
-->|link text=[[File:Pencil.png|x16px|link=]]<!-- | -->|link text=[[File:Pencil.png|x16px|link=]]<!-- | ||
Line 51: | Line 48: | ||
-->{{#ifeq: {{#var: thisHasType}}|{{#var: thisHasTypeImport}}|<!-- then-->|<!-- else-->{{#info: message=“Type:{{#var: thisHasTypeImport}}” on import page [[MediaWiki:Smw_import_{{{ns prefix|}}}]] does not match “Has type:{{#var: thisHasType}}” on page “{{#var: thisFullPageName}}”!}}}}<!-- | -->{{#ifeq: {{#var: thisHasType}}|{{#var: thisHasTypeImport}}|<!-- then-->|<!-- else-->{{#info: message=“Type:{{#var: thisHasTypeImport}}” on import page [[MediaWiki:Smw_import_{{{ns prefix|}}}]] does not match “Has type:{{#var: thisHasType}}” on page “{{#var: thisFullPageName}}”!}}}}<!-- | ||
− | else-->|{{#formlink: | + | else-->|{{#var: thisVocabNoPrefix}} {{#formlink: |
form=Property setting<!-- | form=Property setting<!-- | ||
-->|link text=[[File:Pencil add.png|x16px|link=]]<!-- | -->|link text=[[File:Pencil add.png|x16px|link=]]<!-- | ||
Line 71: | Line 68: | ||
--><span title="A class">[[File:Folder-silk.png|link=]]</span> <!-- | --><span title="A class">[[File:Folder-silk.png|link=]]</span> <!-- | ||
− | |||
-->{{#ifexist: {{#var: thisFullPageName}}<!-- | -->{{#ifexist: {{#var: thisFullPageName}}<!-- | ||
− | then-->|{{#formlink: | + | then-->|[[:{{#var: thisFullPageName}}|{{#var: thisVocabNoPrefix}}]] {{#formlink: |
form=Concept collection<!-- | form=Concept collection<!-- | ||
-->|link text=[[File:Pencil.png|x16px|link=]]<!-- | -->|link text=[[File:Pencil.png|x16px|link=]]<!-- | ||
Line 83: | Line 79: | ||
-->|tooltip=Edit this {{lc:{{ns:category}}}} page<!-- | -->|tooltip=Edit this {{lc:{{ns:category}}}} page<!-- | ||
-->}}<!-- | -->}}<!-- | ||
− | else-->|{{#formlink: | + | else-->|{{#var: thisVocabNoPrefix}} {{#formlink: |
form=Concept collection<!-- | form=Concept collection<!-- | ||
-->|link text=[[File:Pencil add.png|x16px|link=]]<!-- | -->|link text=[[File:Pencil add.png|x16px|link=]]<!-- |
Revision as of 13:10, 26 September 2012
[edit] [ ] Template documentation
This documentation is transcluded from Template:Generate concept formlinks from SMW import page/doc. (edit | history)
Template “Generate concept formlinks from SMW import page” generates a list of formlinks based on a “MediaWiki:Smw_import-ns-prefix”-page
Usage
This template has the following parameter:
{{Generate concept formlinks from SMW import page
|ns prefix= e.g. "dwc" or "rdf" etc.
|title= optional title of the target page
|query string= form_name[field]=value&form_name[field2]=value3 “form_name” must be given, it will be replaced by an appropriate form
}}
Technical documentation
Dependencies: