Difference between revisions of "Template:Link Skill/Table"

From A3! Wiki
m
(2nd try - remove en link skills from chara page)
 
(10 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
<includeonly>
 
<includeonly>
 +
See the [[Link Skills]] page for more information on how to use link skills and what Part 1 / Part 2 link skills are.
 +
 +
<div class="linkskilltable">
 
{{#cargo_query:
 
{{#cargo_query:
 
tables=Link_Skill
 
tables=Link_Skill
|fields=CONCAT(linkname, IFNULL(CONCAT('<br /><span style="color: red; font-size: 0.8em;">Event: [[',event,']]</span>'),''))=Link Skill,  
+
|fields=CONCAT(IFNULL(CONCAT('<span style="font-size: 0.8em;">Part ', year, '</span><br />'),''), linkname, IFNULL(CONCAT('<br /><span style="color: red; font-size: 0.8em;">Event: [[',event,']]</span>'),''))=Link Skill,  
 
IF(troupe IS NOT NULL, CONCAT('[[File:', troupe, '_troupe.png|25px|link=]] [[', troupe, ' Troupe|', troupe, ']]'),  
 
IF(troupe IS NOT NULL, CONCAT('[[File:', troupe, '_troupe.png|25px|link=]] [[', troupe, ' Troupe|', troupe, ']]'),  
CONCAT(IFNULL(CONCAT('[[File:',file1,'|33px]] '),''), CONCAT('[[', CASE WHEN LOCATE(' ',chara1) = 0 THEN chara1 ELSE LEFT(chara1,LOCATE(' ',chara1) - 1) END,']]'),
+
CONCAT(IFNULL(CONCAT('[[File:',file1,'|33px]] '),IFNULL(CONCAT('[[File:',CASE WHEN LOCATE(' ',chara1) = 0 THEN chara1 ELSE LEFT(chara1,LOCATE(' ',chara1) - 1) END,' Card Icon.png|33px]] '),'')), CONCAT('[[',chara1,'|', CASE WHEN LOCATE(' ',chara1) = 0 THEN chara1 ELSE LEFT(chara1,LOCATE(' ',chara1) - 1) END,']]'),
IFNULL(CONCAT('<br />[[File:',file2,'|33px]] '),''), IFNULL(CONCAT('<br />[[', CASE WHEN LOCATE(' ',chara2) = 0 THEN chara2 ELSE LEFT(chara2,LOCATE(' ',chara2) - 1) END,']]'),''),
+
IF(chara2 IS NOT NULL, CONCAT('<br />',IFNULL(CONCAT('[[File:',file2,'|33px]] '),IFNULL(CONCAT('[[File:',CASE WHEN LOCATE(' ',chara2) = 0 THEN chara2 ELSE LEFT(chara2,LOCATE(' ',chara2) - 1) END,' Card Icon.png|33px]] '),'')), CONCAT('[[',chara2,'|', CASE WHEN LOCATE(' ',chara2) = 0 THEN chara2 ELSE LEFT(chara2,LOCATE(' ',chara2) - 1) END,']]') ),''),
IFNULL(CONCAT('<br />[[File:',file3,'|33px]] '),''), IFNULL(CONCAT('<br />[[', CASE WHEN LOCATE(' ',chara3) = 0 THEN chara3 ELSE LEFT(chara3,LOCATE(' ',chara3) - 1) END,']]'),''),
+
IF(chara3 IS NOT NULL, CONCAT('<br />',IFNULL(CONCAT('[[File:',file3,'|33px]] '),IFNULL(CONCAT('[[File:',CASE WHEN LOCATE(' ',chara3) = 0 THEN chara3 ELSE LEFT(chara3,LOCATE(' ',chara3) - 1) END,' Card Icon.png|33px]] '),'')), CONCAT('[[',chara3,'|', CASE WHEN LOCATE(' ',chara3) = 0 THEN chara3 ELSE LEFT(chara3,LOCATE(' ',chara3) - 1) END,']]') ),''),
IFNULL(CONCAT('<br />[[File:',file4,'|33px]] '),''), IFNULL(CONCAT('<br />[[', CASE WHEN LOCATE(' ',chara4) = 0 THEN chara4 ELSE LEFT(chara4,LOCATE(' ',chara4) - 1) END,']]'),''),
+
IF(chara4 IS NOT NULL, CONCAT('<br />',IFNULL(CONCAT('[[File:',file4,'|33px]] '),IFNULL(CONCAT('[[File:',CASE WHEN LOCATE(' ',chara4) = 0 THEN chara4 ELSE LEFT(chara4,LOCATE(' ',chara4) - 1) END,' Card Icon.png|33px]] '),'')), CONCAT('[[',chara4,'|', CASE WHEN LOCATE(' ',chara4) = 0 THEN chara4 ELSE LEFT(chara4,LOCATE(' ',chara4) - 1) END,']]') ),''),
IFNULL(CONCAT('<br />[[File:',file5,'|33px]] '),''), IFNULL(CONCAT('<br />[[', CASE WHEN LOCATE(' ',chara5) = 0 THEN chara5 ELSE LEFT(chara5,LOCATE(' ',chara5) - 1) END,']]'),'') ) ) = Characters,
+
IF(chara5 IS NOT NULL, CONCAT('<br />',IFNULL(CONCAT('[[File:',file5,'|33px]] '),IFNULL(CONCAT('[[File:',CASE WHEN LOCATE(' ',chara5) = 0 THEN chara5 ELSE LEFT(chara5,LOCATE(' ',chara5) - 1) END,' Card Icon.png|33px]] '),'')), CONCAT('[[',chara5,'|', CASE WHEN LOCATE(' ',chara5) = 0 THEN chara5 ELSE LEFT(chara5,LOCATE(' ',chara5) - 1) END,']]') ),'') ) ) = Characters,
 
description=Description,
 
description=Description,
 
CONCAT(CASE WHEN attribute = "Co" THEN CONCAT('[[File:Comedy.png|20px|link=|Comedy]] Co ', bonus, '% Up') WHEN attribute = "Ac" THEN CONCAT('[[File:Action.png|20px|link=|Action]] Ac ', bonus, '% Up') ELSE CONCAT('[[File:Serious.png|20px|link=|Serious]] Sr ', bonus, '% Up') END) = Bonus
 
CONCAT(CASE WHEN attribute = "Co" THEN CONCAT('[[File:Comedy.png|20px|link=|Comedy]] Co ', bonus, '% Up') WHEN attribute = "Ac" THEN CONCAT('[[File:Action.png|20px|link=|Action]] Ac ', bonus, '% Up') ELSE CONCAT('[[File:Serious.png|20px|link=|Serious]] Sr ', bonus, '% Up') END) = Bonus
|where="{{PAGENAME}}" IN(chara1,chara2,chara3,chara4) OR troupe="{{Character to Troupe|character={{PAGENAME}} }}"
+
|where=type="Regular" AND "{{PAGENAME}}" IN(chara1,chara2,chara3,chara4,chara5) OR troupe="{{Character to Troupe|character={{PAGENAME}} }}"
 
|format=table
 
|format=table
 
|order by=CASE WHEN attribute = "Co" THEN 0
 
|order by=CASE WHEN attribute = "Co" THEN 0
Line 17: Line 20:
 
      WHEN attribute = "Sr" THEN 2 END, bonus DESC
 
      WHEN attribute = "Sr" THEN 2 END, bonus DESC
 
}}
 
}}
 +
</div>
 
</includeonly>
 
</includeonly>

Latest revision as of 11:10, 21 January 2020