Difference between revisions of "Template:Furniture Text"

From Animal Crossing: Pocket Camp Wiki
Jump to: navigation, search
m
(Optimize?)
 
Line 1: Line 1:
  +
<includeonly>{{#vardefine:furniture text image
[[File:{{#cargo_query:tables=Furniture|where=_pageName="{{{1}}}"|fields=Image|group by=_pageName|no html}}.png|24px|link=]] {{#ifeq:{{{tooltip|true}}}|true|{{Tooltip|[[{{{1}}}]]|{{#invoke:CargoQuery|main|q?tables=Furniture|q?where=_pageName="{{{1}}}"|q?fields=_pageName=PageName,MaterialCost,NumBells,CraftTime|template=Furniture Tooltip}}|line=false}}|[[{{{1}}}]]}}
 
  +
| {{#if:{{{1|}}}
  +
| {{#var:{{{1|}}}.Image
  +
| {{#vardefineecho:{{{1|}}}.Image
  +
| {{#cargo_query:tables=Furniture|where=_pageName="{{{1}}}"|fields=Image|group by=_pageName|no html}}
  +
}}
  +
}}
  +
| Error-image
  +
}}
  +
}}[[File:{{#var:furniture text image}}.png|24px|link=]] {{#ifeq:{{{tooltip|true}}}|true
  +
| {{#vardefine:furniture tooltip content
  +
| {{#if:{{{1|}}}
  +
| {{#var:{{{1|}}}.Tooltip
  +
| {{#vardefineecho:{{{1|}}}.Tooltip
 
| {{#invoke:CargoQuery|main|q?tables=Furniture|q?where=_pageName="{{{1}}}"|q?fields=_pageName=PageName,MaterialCost,NumBells,CraftTime|template=Furniture Tooltip}}
  +
}}
  +
}}
  +
}}
  +
}}{{Tooltip|[[{{{1}}}]]|{{#var:furniture tooltip content}}|line=false}}
  +
| [[{{{1}}}]]
  +
}}</includeonly><noinclude>{{doc}}[[Category:Templates]]</noinclude>

Latest revision as of 15:24, 24 January 2021