Template:Generic cargo count/doc: Difference between revisions

Created page with "<templatedata> { "params": { "1": { "label": "Cargo table", "example": "bcs_cards", "type": "string", "required": true }, "where": { "label": "Where", "description": "Corresponds to the \"where\" field in a cargo query.", "type": "string" } }, "description": "This template displays the number of rows in a specified cargo table.", "format": "inline", "paramOrder": [ "1", "where" ] } </templatedata> ==Example usage== <pre>Bloons Card..."
 
new feature
Line 12: Line 12:
"description": "Corresponds to the \"where\" field in a cargo query.",
"description": "Corresponds to the \"where\" field in a cargo query.",
"type": "string"
"type": "string"
},
"count": {
"label": "Count",
"description": "Overrides the count field.",
"example": "COUNT(description_common)+COUNT(description_rare)+COUNT(description_legendary)",
"type": "string",
"default": "COUNT(*)"
}
}
},
},
Line 18: Line 25:
"paramOrder": [
"paramOrder": [
"1",
"1",
"where"
"where",
"count"
]
]
}
}
Line 25: Line 33:
<pre>Bloons Card Storm has {{generic cargo count|bcs_cards}} cards.</pre>
<pre>Bloons Card Storm has {{generic cargo count|bcs_cards}} cards.</pre>
Bloons Card Storm has {{generic cargo count|bcs_cards}} cards.
Bloons Card Storm has {{generic cargo count|bcs_cards}} cards.
<pre>Rogue Legends has {{generic cargo count|btd6_artifacts|where=type != "Boost"}} Artifacts, or {{generic cargo count|btd6_artifacts|where=type != "Boost"|count=COUNT(description_common)+COUNT(description_rare)+COUNT(description_legendary)}} if different rarities of an Artifact are counted separately.</pre>
Rogue Legends has {{generic cargo count|btd6_artifacts|where=type != "Boost"}} Artifacts, or {{generic cargo count|btd6_artifacts|where=type != "Boost"|count=COUNT(description_common)+COUNT(description_rare)+COUNT(description_legendary)}} Artifacts if different rarity versions of an Artifact are counted separately.
<includeonly>[[Category:Cargo query templates]]</includeonly><noinclude>[[Category:Documentation]]</noinclude>
<includeonly>[[Category:Cargo query templates]]</includeonly><noinclude>[[Category:Documentation]]</noinclude>