Generator: Difference between revisions
From SemanticOrganization
(Created page with "{{Generator |template-id=GE |form-titles=Generator |form-unique-number=No |placeholder=Name |template-fields={{Generator-field |field-id=template-name |field-property-id=TN |f...") |
m (Text replacement - "|field-" to "|") |
||
(3 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
{{ | {{Semorg-generator | ||
|template-id=GE | |template-id=GE | ||
|form-titles=Generator | |form-titles=Generator | ||
|form-unique-number=No | |form-unique-number=No | ||
|placeholder=Name | |placeholder=Name | ||
|template-fields={{ | |template-fields={{Semorg-generator-field | ||
| | |id=template-name | ||
| | |property-id=TN | ||
| | |name=Name des Vorlage | ||
| | |type=txt | ||
}}{{ | }}{{Semorg-generator-field | ||
| | |id=template-id | ||
| | |property-id=TI | ||
| | |name=ID der Vorlage | ||
| | |type=txt | ||
}}{{ | }}{{Semorg-generator-field | ||
| | |id=page-name | ||
| | |property-id=PN | ||
| | |name=automatischer Seitenname | ||
}} | }} | ||
}} | }} |
Latest revision as of 14:24, 22 November 2018
Messages
"semorg-generator-template": "semorg-generator", "semorg-generator-category": "semorg-generator", "semorg-generator-form": "semorg-generator", "semorg-form-generator-create-title": "Create Generator", "semorg-form-generator-edit-title": "Edit Generator", "semorg-forminput-generator-placeholder": "Name", "semorg-form-generator-template": "generator", "semorg-form-generator-rows": "template-id, page-name, template-name", "semorg-list-generator-headers": "generator-template-id, generator-page-name, generator-template-name", "semorg-field-generator-page-name-name": "automatischer Seitenname", "semorg-field-generator-page-name-parameters": "", "semorg-field-generator-template-id-name": "ID der Vorlage", "semorg-field-generator-template-id-parameters": "", "semorg-field-generator-template-name-name": "Name des Vorlage", "semorg-field-generator-template-name-parameters": "",
Form
<noinclude>{{semorg-bundle}}</noinclude><includeonly>{{{info |create title={{int:semorg-form-generator-create-title}} |edit title={{int:semorg-form-generator-edit-title}}<span class="d-none">: <page name></span> |page name= }}} {{semorg-form-template|generator}} {{semorg-form-standard-inputs}} </includeonly>
as embedded:
Use this code, if this is not meant to be a standalone feature but rather a supplement that should be embedded in other forms. Add this line to a form definition that includes a field with the parameter holds template
. The second parameter of the semorg-form-template-embed
call should be the target field, specified with <feature>[<field>]
(e.g. meeting-group[files]
or {{int:semorg-meeting-group-template}}[files]
to respect template customization).
{{semorg-form-template-embed|generator|}}
Category
{{semorg-category}}
Template
<noinclude>{{semorg-bundle}}</noinclude><includeonly>[[Category:{{int:semorg-generator-category}}]]{{#semorg-set:generator |template-id={{{template-id|}}} |page-name={{{page-name|}}} |template-name={{{template-name|}}} }}{{#semorg-detail:generator}}{{#semorg-table:generator |template-id={{{template-id|}}} |page-name={{{page-name|}}} |template-name={{{template-name|}}} }}</includeonly>
Row Template
<noinclude>{{semorg-bundle}}</noinclude><includeonly><tr> <td>[[{{{target|}}}]]</td> <td>{{{template-id|}}}</td> <td>{{{page-name|}}}</td> <td>{{{template-name|}}}</td> {{semorg-showedit |target={{{target|}}} }} </tr></includeonly>
Overview Page Template
Template:Semorg-generator-overview
<noinclude>{{semorg-bundle}}</noinclude><includeonly>{{#semorg-list:generator |heading={{int:semorg-generator-page-name}} |formlink={{#semorg-forminput:generator}} |links={{{links|}}} |query={{{query|}}} |sort={{{sort|}}} |order={{{order|}}} |limit={{{limit|}}} |filter links={{{filter links|}}} |filters={{{filters|}}} |category={{{category|}}} |headers={{{headers|}}} |row template={{{row template|}}} |tableclass={{{tableclass|}}} |title={{{title|}}} |sums={{{sums|}}} |csv={{{csv|}}} |default={{{default|}}} |returnto={{{returnto|}}} |help={{{help|}}} }}</includeonly>
Overview Page
[[]]
{{semorg-generator-overview}}
Property Registration
Add the following line to LocalSettings.php
:
$wgSemorgAdditionalProperties['generator'] = [ "id" => "GE","fields" => ["template-id" => [ "id" => "TI","type" => "txt" ],"page-name" => [ "id" => "PN","type" => "" ],"template-name" => [ "id" => "TN","type" => "txt" ], ] ];