Шаблон:Vendor list result format — различия между версиями
Материал из Guild Wars 2 wiki
Строка 1: | Строка 1: | ||
− | + | <includeonly>|- {{#ifeq: {{#vardefineecho:historical vendor|{{#show:{{{2}}}|?Is historical|default=false}}}} | true | |
− | + | | title="Vendor currently unavailable" class="gray" | |
− | + | | {{#ifeq:{{{6|false}}}|true| title="Item currently unavailable" class="gray" }} | |
− | |||
− | |||
− | |||
− | |||
− | | | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | | | ||
}} | }} | ||
− | + | | {{#vardefine:smw_name|{{#show:{{{2|}}}|?Has canonical name}}}} data-sort-value="{{#ifeq: {{#var:historical vendor}} | true | ZZZ }}{{#if: {{#var:smw_name}} | {{#var:smw_name}} | {{{2}}} }}" | {{#if: {{#var:smw_name}} | [[{{{1}}}|{{#var:smw_name}}]] | [[{{{1}}}|{{{2}}}]] }} | |
− | + | {{#ifeq:{{#var:showSection|false}}|true| {{!}} style="max-width:100px;" {{!}} {{{3}}} }} | |
− | == | + | | style="max-width:400px;" | {{#show:{{{2|}}}|?Located in|default=–|sep=;}} |
− | ; | + | | style="text-align:{{#if:{{#var:showCostText|}}|left|right}}" | {{#ifeq:{{{5}}}|1|<!--Nothing-->|{{{5}}} / }}{{#arraymap:{{#replace:{{#replace:{{{4}}}|.|}}<!--fix for languages that use dots as thousand separators-->| |}}<!--fix for languages using nbsp as thousand separators -->,|),|@@@| |
− | + | {{currency|{{#replace:{{#explode:@@@| }}|,|}}| {{#sub:@@@|{{#expr:2+{{#pos:@@@| }}}}}}| text = {{#if:{{#var:showCostText|}}|+}} }} | |
− | + | | + }} | |
+ | </includeonly><noinclude> | ||
+ | This semantic result template is used for formatting results from {{tl|vendor list}} and {{tl|vendor table}}. The following parameters are passed to the template: | ||
+ | #Vendor subobject | ||
+ | #Has vendor | ||
+ | #Has vendor section | ||
+ | #Has item cost | ||
+ | #Has item quantity | ||
+ | #Is historical | ||
[[Category:Vendor formatting templates]] | [[Category:Vendor formatting templates]] | ||
+ | [[Category:Semantic result templates]] | ||
</noinclude> | </noinclude> |
Текущая версия на 13:29, 4 апреля 2018
This semantic result template is used for formatting results from {{vendor list}} and {{vendor table}}. The following parameters are passed to the template:
- Vendor subobject
- Has vendor
- Has vendor section
- Has item cost
- Has item quantity
- Is historical