]> ruin.nu Git - ndwebbie.git/blobdiff - root/src/rankings/galaxies.tt2
Converted rankings
[ndwebbie.git] / root / src / rankings / galaxies.tt2
diff --git a/root/src/rankings/galaxies.tt2 b/root/src/rankings/galaxies.tt2
new file mode 100644 (file)
index 0000000..869a3e6
--- /dev/null
@@ -0,0 +1,46 @@
+[% META title = 'Galaxy Rankings' %]
+<p><a href="[% c.uri_for('galaxies', order, offset - 100) %]">Previous 100</a>
+       <a href="[% c.uri_for('galaxies', order, offset + 100) %]">Next 100</a>
+</p>
+<table class="stats">
+       <tr align="center"><th colspan="4">Rank</th>
+       </tr>
+       <tr>
+       <th><a href="[% c.uri_for('galaxies', 'sizerank', offset) %]">Size</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'scorerank', offset) %]">Score</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'valuerank', offset) %]">Value</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'xprank', offset) %]">XP</a></th>
+       <th>Coords</th>
+       <th><a href="[% c.uri_for('galaxies', 'planets', offset) %]">Planets</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'sizerank', offset) %]">Size</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'scorerank', offset) %]">Score</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'valuerank', offset) %]">Value</a></th>
+       <th><a href="[% c.uri_for('galaxies', 'xprank', offset) %]">XP</a></th>
+       </tr>
+       [% FOR g IN galaxies %]
+       <tr align="right" class="[% loop.count % 2 == 0 ? 'even' : 'odd' %]">
+               [% g.sizerankimg = (g.sizerank_gain_day == 0 ? 'stay' : (g.sizerank_gain_day < 0 ? 'up' : 'down')) %]
+               <td title="[% g.sizerank_gain_day %] Today | [% g.sizerank_gain %] Tick">[% g.sizerank %] <img src="/static/images/[% g.sizerankimg %].png" alt="[% g.sizerankimg %]"> </td>
+               [% g.scorerankimg = (g.scorerank_gain_day == 0 ? 'stay' : (g.scorerank_gain_day < 0 ? 'up' : 'down')) %]
+               <td title="[% g.scorerank_gain_day %] Today | [% g.scorerank_gain %] Tick">[% g.scorerank %] <img src="/static/images/[% g.scorerankimg %].png" alt="[% g.scorerankimg %]"> </td>
+               [% g.valuerankimg = (g.valuerank_gain_day == 0 ? 'stay' : (g.valuerank_gain_day < 0 ? 'up' : 'down')) %]
+               <td title="[% g.valuerank_gain_day %] Today | [% g.valuerank_gain %] Tick">[% g.valuerank %] <img src="/static/images/[% g.valuerankimg %].png" alt="[% g.valuerankimg %]"> </td>
+               [% g.xprankimg = (g.xprank_gain_day == 0 ? 'stay' : (g.xprank_gain_day < 0 ? 'up' : 'down')) %]
+               <td title="[% g.xprank_gain_day %] Today | [% g.xprank_gain %] Tick">[% g.xprank %] <img src="/static/images/[% g.xprankimg %].png" alt="[% g.xprankimg %]"> </td>
+               <td><a href="[% c.uri_for('/stats','galaxy',g.x,g.y) %]">[% g.x %]:[% g.y %]</a></td>
+               [% g.planetsimg = (g.planets_gain_day == 0 ? 'stay' : (g.planets_gain_day > 0 ? 'up' : 'down')) %]
+               <td title="[% g.planets_gain_day %] Today | [% g.planets_gain %] Tick">[% comma(g.planets) %] <img src="/static/images/[% g.planetsimg %].png" alt="[% g.planetsimg %]"> </td>
+               [% g.sizeimg = (g.size_gain_day == 0 ? 'stay' : (g.size_gain_day > 0 ? 'up' : 'down')) %]
+               <td title="[% g.size_gain_day %] Today | [% g.size_gain %] Tick">[% comma(g.size) %] <img src="/static/images/[% g.sizeimg %].png" alt="[% g.sizeimg %]"> </td>
+               [% g.scoreimg = (g.score_gain_day == 0 ? 'stay' : (g.score_gain_day > 0 ? 'up' : 'down')) %]
+               <td title="[% comma(g.score_gain_day) %] Today | [% comma(g.score_gain) %] Tick">[% comma(g.score) %] <img src="/static/images/[% g.scoreimg %].png" alt="[% g.scoreimg %]"> </td>
+               [% g.valueimg = (g.value_gain_day == 0 ? 'stay' : (g.value_gain_day > 0 ? 'up' : 'down')) %]
+               <td title="[% comma(g.value_gain_day) %] Today | [% comma(g.value_gain) %] Tick">[% comma(g.value) %] <img src="/static/images/[% g.valueimg %].png" alt="[% g.valueimg %]"> </td>
+               [% g.xpimg = (g.xp_gain_day == 0 ? 'stay' : (g.xp_gain_day > 0 ? 'up' : 'down')) %]
+               <td title="[% comma(g.xp_gain_day) %] Today | [% comma(g.xp_gain) %] Tick">[% comma(g.xp) %] <img src="/static/images/[% g.xpimg %].png" alt="[% g.xpimg %]"> </td>
+       </tr>
+[% END %]
+</table>
+<p><a href="[% c.uri_for('galaxies', order, offset - 100) %]">Previous 100</a>
+       <a href="[% c.uri_for('galaxies', order, offset + 100) %]">Next 100</a>
+</p>