Parser Functions/en: Difference between revisions
(Updating to match new version of source page) |
(Updating to match new version of source page) |
||
Line 300: | Line 300: | ||
This is a shorthand to display | This is a shorthand to display | ||
* a link to create a new meeting | * a link to create a new meeting | ||
* a list of | * a list of scheduled meetings | ||
* a list of recent meetings | * a list of recent meetings | ||
Revision as of 18:37, 26 September 2020
#semorg-person
called like this (preferably via template):
{{#semorg-person: |ref={{FULLPAGENAME}} |prefix={{{prefix|}}} |firstname={{{firstname|}}} |lastname={{{lastname|}}} |name={{{firstname|}}} {{{lastname|}}} |suffix={{{suffix|}}} |workstreet={{{workstreet|}}} |workpostalcode={{{workpostalcode|}}} |worklocality={{{worklocality|}}} |email={{{email|}}} |workphone={{{workphone|}}} |homepage={{{homepage|}}} |note={{{note|}}} |organization={{{organization|}}} |gender={{{gender|}}} }}
sets all the attributes and spits out a nicely formatted table with all the contact information and also a download link for a .vcard file
#semorg-field-rows
Returns the markup for the fields in a form.
Markup | Result |
---|---|
{{#semorg-field-rows:name |template=person }} |
only works in form definitions |
The following system messages control the appearance of the list:
Message | Function |
---|---|
semorg-field-<feature>-<field>-parameters | Any of Page Form's parameters for fields. |
semorg-field-<feature>-<field>-placeholder | |
semorg-field-<feature>-<field>-input-type | |
semorg-field-<feature>-<field>-values | |
semorg-field-<feature>-<field>-mapping-template | |
semorg-field-<feature>-<field>-class | |
semorg-field-<feature>-<field>-prefix | Content to be displayed before the field. |
semorg-field-<feature>-<field>-suffix | Content to be displayed after the field. |
The following parameters are available:
Parameter | Description |
---|---|
template | The name of the feature. |
#semorg-set
Shorthand for {{#set:}}
Markup | Result |
---|---|
{{#semorg-set:person |name={{{name|}}} }} |
{{#set: |semorg-person-name={{{name|}}} }} |
#semorg-set-list
Shorthand for {{#set:}}
for properties with multiple values.
Markup | Result |
---|---|
{{#semorg-set-list:person |name={{{name|}}} }} |
{{#set: |semorg-person-name={{{name|}}}|+sep=, }} |
#semorg-subobject
Shorthand for {{#subobject:}}
.
Markup | Result |
---|---|
{{#semorg-subobject:person |name={{{name|}}} }} |
{{#subobject: |semorg-person-name={{{name|}}}|+sep=, }} |
#semorg-table
Rendering template parameters (or other content) as a table. Field names are used for the first column.
Markup | Result |
---|---|
{{#semorg-table:person |name={{{name|Dummy Person}}} }} |
Name Dummy Person |
#semorg-toggle
Rendering template parameters (or other content) as a table. Field names are used for the first column.
Markup | Result |
---|---|
{{#semorg-toggle: |class=semorg-toggle-test |original-text=hide it |toggle-text=show it }} <div class="semorg-toggle-test"> Text to be toggled </div> |
Text to be toggled |
{{#semorg-toggle: |class=semorg-toggle-hidden-test |original-text=show it |toggle-text=hide it }} <div class="semorg-toggle-hidden-test" style="display:none"> Initially hidden </div> |
#semorg-list
This parser function is used to show lists of pages belonging to a certain category. For the details about this highly configurable parser function see Parser Function semorg-list
#semorg-user-create
Render a link to create a new user account if it doesn't exist already
Markup | Result |
---|---|
{{#semorg-user-create:Dummy User}} <div class="semorg-toggle-test">Text to be toggled</div> |
#semorg-formlink
This parser function is an abbreviation to call {{#formlink}}
with smart defaults.
Markup | Result |
---|---|
{{#semorg-formlink:meeting-group}}
|
Create Meeting |
The following system messages control the appearance of the list:
Message | Function |
---|---|
semorg-formlink-<feature>-link-text | The link text to be displayed. |
semorg-formlink-<feature>-link-type | Use this to set a wiki-wide default for all calls of {{#semorg-formlink:<feature>}}
|
semorg-formlink-<feature>-target | |
semorg-formlink-<feature>-tooltip | |
semorg-formlink-<feature>-popup | |
semorg-formlink-<feature>-new-window | |
semorg-formlink-<feature>-query-string | |
semorg-formlink-<feature>-returnto |
The following parameters are available:
Parameter | Description |
---|---|
link text, link type, target, tooltip, popup, new window, query string, returnto | These are the default parameters for Page Form's {{#formlink}} function
|
#semorg-forminput
This parser function is an abbreviation to call {{#forminput}}
with smart defaults.
Markup | Result |
---|---|
{{#semorg-forminput:group}}
|
The following system messages control the appearance of the list:
Message | Function |
---|---|
semorg-forminput-<feature>-button-text | The button text to be displayed. |
semorg-forminput-<feature>-size | Use this to set a wiki-wide default for all calls of {{#semorg-forminput:<feature>}}
|
semorg-forminput-<feature>-default-value | |
semorg-forminput-<feature>-query-string | |
semorg-forminput-<feature>-autocomplete-on-category | |
semorg-forminput-<feature>-autocomplete-on-namespace | |
semorg-forminput-<feature>-placeholder | |
semorg-forminput-<feature>-popup | |
semorg-forminput-<feature>-returnto |
The following parameters are available:
Parameter | Description |
---|---|
button text, size, default value, query string, autocomplete on category, autocomplete on namespace, placeholder, popup, returnto | These are the default parameters for Page Form's {{#forminput}} function
|
NB: The no autofocus
parameter is set by default.
#semorg-meetings
This is a shorthand to display
- a link to create a new meeting
- a list of scheduled meetings
- a list of recent meetings
Markup | Result | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{#semorg-meetings:group
|group=Testgroup
}}
|
Scheduled Group Meetings no meetings scheduled… no meetings scheduled… Past Group Meetings
|
The following system messages control the appearance:
Message | Function |
---|---|
semorg-list-meeting-current-heading | The heading for the list of current meetings |
semorg-list-meeting-past-heading | The heading for the list of recent meetings |
The following parameters are available:
Parameter | Description |
---|---|
group | If the group is not explicitly set it is assumed to be the title of the current page. You can set it to '+' if you want no specific group. |
#semorg-properties
Show a feature's properties/fields.
Markup | Result |
---|---|
{{#semorg-properties:group}}
|
domain, co-host, description, goals, name, host, permanent, active |
#semorg-values
Render all values for a specific property.
Markup | Result |
---|---|
{{#semorg-values:person-name}}
|
ACME Corp., Ad Min, Brad Pitt, Darth Vader, Jane Doe, John Doe, Luke Skywalker, UNO this is the result of the following code:{{#ask:[[semorg-person-name::+]] |mainlabel=- |headers=hide |limit=1000 |searchlabel= |?semorg-person-name# }} |
#semorg-tabs
Creates togglable tabs.
The following system messages control the appearance of the header:
Message | Function |
---|---|
semorg-tab-<feature>-<tab-id> | The link text for the tab. |
The following parameters are available:
Parameter | Description |
---|---|
?<tab-id>=<tab-content> | ID and content for a tab. |
#semorg-tabs-card
#semorg-user
Show the current user.
Markup | Result |
---|---|
{{#semorg-user:}}
|
User:192.168.0.1 |
#semorg-true
Test whether the first argument is on of SMW's true words.
Markup | Result |
---|---|
{{#semorg-true:yes|true|false}}
|
true |
#semorg-detail
Show header details for page. Replaces the main heading and provides a backlink to the overview page. See the documentation for Detail pages.
The following system messages control the appearance of the header:
Message | Function |
---|---|
semorg-<feature>-page-name | The title of the overview page |
semorg-<feature>-entity name | Name for the instance. Displayed over the page title. |
The following parameters are available:
Parameter | Description |
---|---|
heading | Heading to be displayed instead of the standard heading. Will also call {{DISPLAYTITLE:}} .
|
overview page | Page that should be linked to as the parent page. |
Visualization
#semorg-network
tbd
#semorg-cooperation
tbd
#semorg-circles
tbd