Difference between revisions of "Development:Infobox game"

From PCGamingWiki, the wiki about fixing PC games
(Cargo GOG check)
(more Cargo)
Line 60: Line 60:
 
  Icons --><!--
 
  Icons --><!--
 
  storing WSGF Link state -->{{#vardefine:WSGF Link|{{#show: {{PAGENAME}} | ?WSGF Link #}}}}<!--
 
  storing WSGF Link state -->{{#vardefine:WSGF Link|{{#show: {{PAGENAME}} | ?WSGF Link #}}}}<!--
  storing digital state -->{{#vardefine:available digitally|{{#show: {{PAGENAME}} | ?Available digitally}}}}{{#if: {{{wikipedia|}}}{{{gogcom id|}}}{{{steam appid|}}}{{{winehq|}}}{{{strategywiki|}}}{{{mobygames|}}}{{{igdb|}}}{{#var:WSGF Link}}{{{official site|}}}|
+
  storing digital state -->{{#vardefine:available digitally|{{#cargo_query:tables=Tags|where=_pageName = '{{PAGENAME}}'|fields=Available_digitally|default=}}}}{{#if: {{{wikipedia|}}}{{{gogcom id|}}}{{{steam appid|}}}{{{winehq|}}}{{{strategywiki|}}}{{{mobygames|}}}{{{igdb|}}}{{#var:WSGF Link}}{{{official site|}}}|
 
<tr>
 
<tr>
 
<td class="template-infobox-icons" colspan="2"><!--
 
<td class="template-infobox-icons" colspan="2"><!--
Line 92: Line 92:
 
-->{{#if: {{{wikipedia|}}}| [[Wikipedia::{{{wikipedia}}}| ]] }}<!--
 
-->{{#if: {{{wikipedia|}}}| [[Wikipedia::{{{wikipedia}}}| ]] }}<!--
 
-->{{#if: {{{license|}}}| {{Infobox game/license|{{lc:{{{license|}}}}}}} }}<!--
 
-->{{#if: {{{license|}}}| {{Infobox game/license|{{lc:{{{license|}}}}}}} }}<!--
-->{{#if: {{#show: {{PAGENAME}} | ?Article state is stub}}||[[Category:Missing section (References)]]}}<!--
+
-->{{#if: {{#cargo_query:tables=Tags|where=_pageName = '{{PAGENAME}}'|fields=Stub|default=}}||[[Category:Missing section (References)]]}}<!--
 
-->{{#vardefine:Availability|needed}}<!--
 
-->{{#vardefine:Availability|needed}}<!--
 
-->{{#vardefine:Video|needed}}<!--
 
-->{{#vardefine:Video|needed}}<!--
Line 114: Line 114:
 
-->{{#arraymap:{{#var:sidebarSeries}}|,|€€€€€|{{#if:{{#var:sidebarSeriesShown}}||</dd>{{Series|€€€€€}}{{#vardefine:sidebarSeriesShown|true}}}}|}}<!--
 
-->{{#arraymap:{{#var:sidebarSeries}}|,|€€€€€|{{#if:{{#var:sidebarSeriesShown}}||</dd>{{Series|€€€€€}}{{#vardefine:sidebarSeriesShown|true}}}}|}}<!--
 
-->{{Tocbox}}<!--
 
-->{{Tocbox}}<!--
-->{{#if:{{#show: {{PAGENAME}} | ?Warnings}}|{{#vardefine:Top warnings|true}}{{#vardefine:Top last|Infobox}}{{#vardefine:Top|{{#show: {{PAGENAME}} | ?Top}}}}{{#vardefine:DRM|{{#show: {{PAGENAME}} | ?Uses DRM}}}}{{#ifeq:{{#var:Top}}|Infobox|{{Warnings}}}}}}</includeonly><noinclude>{{#cargo_declare:
+
-->{{#if:{{#cargo_query:tables=Tags|where=_pageName = '{{PAGENAME}}'|fields=Warnings|default=}}|{{#vardefine:Top warnings|true}}{{#vardefine:Top last|Infobox}}{{#vardefine:Top|{{#cargo_query:tables=Tags|where=_pageName = '{{PAGENAME}}'|fields=Top|default=}}}}{{#vardefine:DRM|{{#show: {{PAGENAME}} | ?Uses DRM}}}}{{#ifeq:{{#var:Top}}|Infobox|{{Warnings}}}}}}</includeonly><noinclude>{{#cargo_declare:
 
_table=Infobox_game
 
_table=Infobox_game
 
|Cover=File
 
|Cover=File

Revision as of 09:07, 17 September 2021

Error: #cargo_declare must be called from a template page.
Documentation for the above template (sometimes hidden from view).