Difference between revisions of "RatingsTest"

From Sega Retro

Line 1: Line 1:
{{#vardefine:totalReviews|0}}{{#vardefine:cumulativeScore|0}}{{#vardefine:arguments|}}
+
{{#vardefine:totalReviews|0}}{{#vardefine:cumulativeScore|0}}{{#vardefine:printthis|}}{{#vardefine:argno|0}}
 
{|cellpadding="0" cellspacing="0" class="breakout mw-collapsible mw-collapsed" style="width:auto !important; max-width: 320px; float: right; margin-left: 0px; display: inline; position: relative;"
 
{|cellpadding="0" cellspacing="0" class="breakout mw-collapsible mw-collapsed" style="width:auto !important; max-width: 320px; float: right; margin-left: 0px; display: inline; position: relative;"
 
!style="height:39px;" |Sega Retro Average 
 
!style="height:39px;" |Sega Retro Average 
Line 14: Line 14:
 
| value  
 
| value  
 
|
 
|
 +
{{#vardefine:argno|{{#expr:{{#var: argno}} + 1}}}}
 
{{#vardefine:argtype|score}}
 
{{#vardefine:argtype|score}}
 
{{#ifeq: {{#var: key}}|icon|{{#vardefine:argtype|icon}}|}}
 
{{#ifeq: {{#var: key}}|icon|{{#vardefine:argtype|icon}}|}}
Line 20: Line 21:
 
{{#ifeq: {{#var: argtype}}|score|{{#vardefine:pubname|{{#var: key}}}}{{#vardefine:pubscore|{{#var: value}}}}|}}
 
{{#ifeq: {{#var: argtype}}|score|{{#vardefine:pubname|{{#var: key}}}}{{#vardefine:pubscore|{{#var: value}}}}|}}
 
{{#ifeq: {{#var: argtype}}|source|{{#vardefine:pubsource|{{#var: value}}}}
 
{{#ifeq: {{#var: argtype}}|source|{{#vardefine:pubsource|{{#var: value}}}}
{{RatingsRowSum|{{#var: pubname}}|{{#var: pubscore}}|{{#var: pubsource}}}} {{#vardefine:arguments|{{#var:arguments}} <br/> {{#var: pubname}}|{{#var: pubscore}}|{{#var: pubsource}}}}
+
{{RatingsRowSum|{{#var: pubname}}|{{#var: pubscore}}|{{#var: pubsource}}}} {{#vardefine:printthis|{{#var:printthis}} <br/> {{#var: pubname}} {{#var: pubscore}} {{#var: pubsource}}}}
 
{{#vardefine:pubname|null}}{{#vardefine:pubscore|null}}{{#vardefine:pubsource|null}}|}}
 
{{#vardefine:pubname|null}}{{#vardefine:pubscore|null}}{{#vardefine:pubsource|null}}|}}
  
Line 38: Line 39:
 
|colspan="2" style="padding:2px; text-align:center; line-height:initial" | <small>Based on<br>'''{{#var: totalReviews}}''' review{{#ifexpr: {{#var: totalReviews}} > 1|s| }}</small>
 
|colspan="2" style="padding:2px; text-align:center; line-height:initial" | <small>Based on<br>'''{{#var: totalReviews}}''' review{{#ifexpr: {{#var: totalReviews}} > 1|s| }}</small>
 
|}
 
|}
{{#var: arguments}}
+
{{#var: printthis}}
 
<noinclude>[[Category:Breakout box templates]]</noinclude>
 
<noinclude>[[Category:Breakout box templates]]</noinclude>

Revision as of 05:43, 15 June 2016

Sega Retro Average 
Publication Score Source
{{{{{icon}}}|L}} Division by zero.
Based on
0 review