6,566
edits
(The 'full' parameter must now be set to 1 for it to be active. This is required for some recursive transclusions setting a value for {{{full|}}} when the 'full' parameter is not supplied.) |
(Custom parameter support (param1, param2, param3). This is demonstrated by a new example.) |
||
Line 10: | Line 10: | ||
| site = | | site = | ||
| ''site'' = | | ''site'' = | ||
}} | |||
}} | |||
}}{{#ifeq: {{{param1|}}} | 1 | <nowiki></nowiki> | |||
{{!}} {{#ifeq: {{{type1|}}} | num | |||
| {{#ifeq: {{{stat1|}}} | mandatory | |||
| {{{name1}}} | |||
| ''{{{name1}}}'' | |||
}} | |||
| {{#ifeq: {{{stat1|}}} | mandatory | |||
| {{{name1}}} = | |||
| ''{{{name1}}}'' = | |||
}} | |||
}} | |||
}}{{#ifeq: {{{param2|}}} | 1 | <nowiki></nowiki> | |||
{{!}} {{#ifeq: {{{type2|}}} | num | |||
| {{#ifeq: {{{stat2|}}} | mandatory | |||
| {{{name2}}} | |||
| ''{{{name2}}}'' | |||
}} | |||
| {{#ifeq: {{{stat2|}}} | mandatory | |||
| {{{name2}}} = | |||
| ''{{{name2}}}'' = | |||
}} | |||
}} | |||
}}{{#ifeq: {{{param3|}}} | 1 | <nowiki></nowiki> | |||
{{!}} {{#ifeq: {{{type3|}}} | num | |||
| {{#ifeq: {{{stat3|}}} | mandatory | |||
| {{{name3}}} | |||
| ''{{{name3}}}'' | |||
}} | |||
| {{#ifeq: {{{stat3|}}} | mandatory | |||
| {{{name3}}} = | |||
| ''{{{name3}}}'' = | |||
}} | }} | ||
}} | }} | ||
Line 245: | Line 278: | ||
{{!}} style="text-align: center" {{!}} {{#if: {{{pos_site|}}} | {{param|{{{pos_site}}}}}}} | {{!}} style="text-align: center" {{!}} {{#if: {{{pos_site|}}} | {{param|{{{pos_site}}}}}}} | ||
{{!}} style="text-align: center" {{!}} {{{stat_site|mandatory}}} | {{!}} style="text-align: center" {{!}} {{{stat_site|mandatory}}} | ||
</tr> | |||
}}{{#ifeq: {{{param1|}}} | 1 | | |||
<tr> | |||
{{!}} {{param|{{{name1}}}}} | |||
{{!}} {{{desc1}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{short1|}}} | {{param|{{{short1}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{pos1|}}} | {{param|{{{pos1}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{{stat1|optional}}} | |||
</tr> | |||
}}{{#ifeq: {{{param2|}}} | 1 | | |||
<tr> | |||
{{!}} {{param|{{{name2}}}}} | |||
{{!}} {{{desc2}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{short2|}}} | {{param|{{{short2}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{pos2|}}} | {{param|{{{pos2}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{{stat2|optional}}} | |||
</tr> | |||
}}{{#ifeq: {{{param3|}}} | 1 | | |||
<tr> | |||
{{!}} {{param|{{{name3}}}}} | |||
{{!}} {{{desc3}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{short3|}}} | {{param|{{{short3}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{#if: {{{pos3|}}} | {{param|{{{pos3}}}}}}} | |||
{{!}} style="text-align: center" {{!}} {{{stat3|optional}}} | |||
</tr> | </tr> | ||
}}{{#ifeq: {{{cmd|}}} | 1 | | }}{{#ifeq: {{{cmd|}}} | 1 | | ||
Line 485: | Line 542: | ||
{{!}} site_name = | {{!}} site_name = | ||
{{!}} site = {{!}} type_site = {{!}} short_site = {{!}} pos_site = {{!}} stat_site = | {{!}} site = {{!}} type_site = {{!}} short_site = {{!}} pos_site = {{!}} stat_site = | ||
{{!}} param1 = {{!}} type1 = {{!}} short1 = {{!}} pos1 = {{!}} stat1 = {{!}} name1 = {{!}} desc1 = | |||
{{!}} param2 = {{!}} type2 = {{!}} short2 = {{!}} pos2 = {{!}} stat2 = {{!}} name2 = {{!}} desc2 = | |||
{{!}} param3 = {{!}} type3 = {{!}} short3 = {{!}} pos3 = {{!}} stat3 = {{!}} name3 = {{!}} desc3 = | |||
{{!}} cmd = {{!}} type_cmd = {{!}} short_cmd = {{!}} pos_cmd = {{!}} stat_cmd = {{!}} value_cmd = {{!}} eg_cmd = | {{!}} cmd = {{!}} type_cmd = {{!}} short_cmd = {{!}} pos_cmd = {{!}} stat_cmd = {{!}} value_cmd = {{!}} eg_cmd = | ||
{{!}} opt = {{!}} type_opt = {{!}} short_opt = {{!}} pos_opt = {{!}} stat_opt = | {{!}} opt = {{!}} type_opt = {{!}} short_opt = {{!}} pos_opt = {{!}} stat_opt = | ||
Line 836: | Line 896: | ||
| gl = 1 | | gl = 1 | ||
| git = 1 | | git = 1 | ||
| break = 0 | |||
}} | |||
==== Custom parameters ==== | |||
{{obr}}repo link/doc usage | |||
{{!}} template = fgaddon file | |||
{{!}} param1 = 1 {{!}} name1 = aircraft {{!}} type1 = num {{!}} pos1 = 1 {{!}} stat1 = mandatory {{!}} desc1 = The aircraft directory name. If empty, the URL of <code><branch>/Aircraft/</code> will be returned. | |||
{{!}} param2 = 1 {{!}} name2 = path {{!}} type2 = num {{!}} pos2 = 2 {{!}} stat2 = mandatory {{!}} desc2 = The file path following from the aircraft directory name. The full file path will be constructed as <code><nowiki><branch>/Aircraft/<path></nowiki></code>. | |||
{{!}} param3 = 1 {{!}} name3 = file {{!}} type3 = named {{!}} stat3 = optional {{!}} desc3 = If set, then a link to the file rather than the full URL will be shown. | |||
{{!}} sf = 1 | |||
{{!}} svn = 1 | |||
{{!}} break = 0 | |||
{{cbr}} | |||
{{repo link/doc usage | |||
| template = fgaddon file | |||
| param1 = 1 | name1 = aircraft | type1 = num | pos1 = 1 | stat1 = mandatory | desc1 = The aircraft directory name. If empty, the URL of <code><branch>/Aircraft/</code> will be returned. | |||
| param2 = 1 | name2 = path | type2 = num | pos2 = 2 | stat2 = mandatory | desc2 = The file path following from the aircraft directory name. The full file path will be constructed as <code><nowiki><branch>/Aircraft/<path></nowiki></code>. | |||
| param3 = 1 | name3 = file | type3 = named | stat3 = optional | desc3 = If set, then a link to the file rather than the full URL will be shown. | |||
| sf = 1 | |||
| svn = 1 | |||
| break = 0 | | break = 0 | ||
}} | }} |