Difference between revisions of "RatingsTest"

From Sega Retro

Line 1: Line 1:
{{#vardefine:totalReviews|0}}{{#vardefine:cumulativeScore|0}}{{#vardefine:printthis|}}{{#vardefine:argno|0}}
+
{{#vardefine:totalReviews|0}}{{#vardefine:cumulativeScore|0}}{{#vardefine:printthis|}}{{#vardefine:argno|0}}{{#vardefine:sources|}}
 
{|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 17: Line 17:
 
{{#vardefine:argtype|score}}
 
{{#vardefine:argtype|score}}
 
{{#ifeq: {{#var: key}}|icon|{{#vardefine:argtype|icon}}|}}
 
{{#ifeq: {{#var: key}}|icon|{{#vardefine:argtype|icon}}|}}
{{#ifeq: {{#sub:{{#var: key}}|{{#len:key}} - 7|7}}|_source|{{#vardefine:argtype|source}}|}}
+
{{#ifeq: {{#sub:{{#var: key}}|{{#len:key}} - 7|7}}|_source|{{#vardefine:argtype|source}}{{#vardefine:sources|{{#var:sources}}<br/>{{#var: key}} -> {{#sub:{{#var: key}}|{{#len:key}} - 7|7}} | }}
  
 
{{#ifeq: {{#var: argtype}}|score|{{#vardefine:pubname|{{#var: key}}}}{{#vardefine:pubscore|{{#var: value}}}}|}}
 
{{#ifeq: {{#var: argtype}}|score|{{#vardefine:pubname|{{#var: key}}}}{{#vardefine:pubscore|{{#var: value}}}}|}}
Line 39: 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:sources}}
 
{{#var: argno}}: {{#var: printthis}}
 
{{#var: argno}}: {{#var: printthis}}
 
<noinclude>[[Category:Breakout box templates]]</noinclude>
 
<noinclude>[[Category:Breakout box templates]]</noinclude>

Revision as of 06:48, 15 June 2016

Sega Retro Average 
{{#forargs:
Publication Score Source
key value




{{{{{icon}}}|L}} Division by zero.
Based on
0 review

1: