]> de.git.xonotic.org Git - xonotic/xonstat.git/commitdiff
Fix the ordering of things and the view game links.
authorAnt Zucaro <azucaro@gmail.com>
Wed, 8 Feb 2012 02:11:48 +0000 (21:11 -0500)
committerAnt Zucaro <azucaro@gmail.com>
Wed, 8 Feb 2012 02:11:48 +0000 (21:11 -0500)
xonstat/templates/map_info.mako
xonstat/templates/search.mako
xonstat/templates/server_info.mako

index 9bed0313d5af1f3586726d76b8a106b9b7f37e58..7e975c152221b0b9baa0094b1fec5296dc634560 100755 (executable)
@@ -19,51 +19,10 @@ ${parent.title()}
 <h2>Sorry, that map wasn't found!</h2>
 
 % else:
-<div class="row">
-  <div class="span12">
-    <h2>${gmap.name}</h2>
-
-    <h3>Recent Games</h3>
-    <table class="table table-bordered table-condensed">
-      <thead>
-        <tr>
-          <th>Game #</th>
-          <th>Type</th>
-          <th>Time</th>
-          <th>Winner</th>
-        </tr>
-      </thead>
-      <tbody>
-        % for (game, srv, map, pgstat) in recent_games:
-        % if game != '-':
-        <tr>
-          <td><a href="${request.route_url('game_info', id=game.game_id)}" title="View detailed information about this game">${game.game_id}</a></td>
-          <td class="gt_icon"><img title="${game.game_type_cd}" src="/static/images/icons/24x24/${game.game_type_cd}.png" alt="${game.game_type_cd}" /></td>
-          <td>${game.start_dt.strftime('%m/%d/%Y %H:%M')}</td>
-          <td>
-            % if pgstat.player_id > 2:
-            <a href="${request.route_url('player_info', id=pgstat.player_id)}" title="Go to the player info page for this player">${pgstat.nick_html_colors()|n}</a>
-          </td>
-            % else:
-            ${pgstat.nick_html_colors()|n}
-          </td>
-            % endif
-        </tr>
-        % else:
-        <tr>
-          <td>-</td>
-          <td>-</td>
-          <td>-</td>
-          <td>-</td>
-        </tr>
-        % endif
-    % endfor
-        </tbody>
-    </table>
-  </div>
-</div>
-
-
+<h2>${gmap.name}</h2>
+<p>
+  Added on ${gmap.create_dt.strftime('%m/%d/%Y at %H:%M')}
+</p>
 <div class="row">
   <div class="span4">
     <h3>Top Scoring Players</h3>
@@ -146,7 +105,50 @@ ${parent.title()}
     </tbody>
 </table>
 </div>
-
 </div> <!-- /row -->
 
+
+<div class="row">
+  <div class="span12">
+    <h3>Recent Games</h3>
+    <table class="table table-bordered table-condensed">
+      <thead>
+        <tr>
+          <th></th>
+          <th>Type</th>
+          <th>Time</th>
+          <th>Winner</th>
+        </tr>
+      </thead>
+      <tbody>
+        % for (game, srv, map, pgstat) in recent_games:
+        % if game != '-':
+        <tr>
+          <td><a class="btn btn-primary btn-small" href="${request.route_url('game_info', id=game.game_id)}" title="View detailed information about this game">View</a></td>
+          <td class="gt_icon"><img title="${game.game_type_cd}" src="/static/images/icons/24x24/${game.game_type_cd}.png" alt="${game.game_type_cd}" /></td>
+          <td>${game.start_dt.strftime('%m/%d/%Y %H:%M')}</td>
+          <td>
+            % if pgstat.player_id > 2:
+            <a href="${request.route_url('player_info', id=pgstat.player_id)}" title="Go to the player info page for this player">${pgstat.nick_html_colors()|n}</a>
+          </td>
+            % else:
+            ${pgstat.nick_html_colors()|n}
+          </td>
+            % endif
+        </tr>
+        % else:
+        <tr>
+          <td>-</td>
+          <td>-</td>
+          <td>-</td>
+          <td>-</td>
+        </tr>
+        % endif
+    % endfor
+        </tbody>
+    </table>
+  </div>
+</div>
+
+
 % endif
index 12768f0188d85e727c0fc3f0dfe38a4749105f64..3c4f79409b1d9347308cd3c306705e2dfffe3c5e 100755 (executable)
 % if result_type == "game":
 <table>
     <tr>
-        <th>Game ID</th>
+        <th></th>
         <th>Map</th>
         <th>Server</th>
         <th>Played On</th>
     </tr>
     % for (game, server, gmap) in results:
     <tr>
-        <td><a href="${request.route_url("game_info", id=game.game_id)}" name="Game info page for game #${game.game_id}">${game.game_id}</a></td>
+        <td><a class="btn btn-primary btn-small" href="${request.route_url("game_info", id=game.game_id)}" name="Game info page for game #${game.game_id}">View</a></td>
         <td><a href="${request.route_url("map_info", id=gmap.map_id)}" name="Map info page for map #${gmap.map_id}">${gmap.name}</a></td>
         <td><a href="${request.route_url("server_info", id=server.server_id)}" name="Server info page for server #${server.server_id}">${server.name}</a></td>
         <td>${game.create_dt.strftime('%m/%d/%Y at %I:%M %p')}</td>
index 5bb4ed8b62cc18fe092eeb76afb6e0794d33a38e..2c8d4963b505bed9e0fefb5c2824b6ca6380ed15 100755 (executable)
@@ -22,58 +22,12 @@ Server Information
     <p>
       IP Address: ${server.ip_addr} <br />
       Revision: ${server.revision} <br />
-      Created: ${server.create_dt.strftime('%m/%d/%Y at %I:%M %p')} <br />
+      Added on ${server.create_dt.strftime('%m/%d/%Y at %I:%M %p')} <br />
     </p>
   </div>
 </div>
 
 
-<div class="row">
-  <div class="span12">
-    <h3>Recent Games</h2>
-    <table class="table table-bordered table-condensed">
-      <thead>
-        <tr>
-          <th>Game #</th>
-          <th>Type</th>
-          <th>Map</th>
-          <th>Time</th>
-          <th>Winner</th>
-        </tr>
-      </thead>
-      <tbody>
-      % for (game, srv, map, pgstat) in recent_games:
-        % if game != '-':
-        <tr>
-          <td><a href="${request.route_url('game_info', id=game.game_id)}" title="View detailed information about this game">${game.game_id}</a></td>
-          <td class="gt_icon"><img title="${game.game_type_cd}" src="/static/images/icons/24x24/${game.game_type_cd}.png" alt="${game.game_type_cd}" /></td>
-          <td><a href="${request.route_url('map_info', id=map.map_id)}" title="Go to the map detail page for this map">${map.name}</a></td>
-          <td>${game.start_dt.strftime('%m/%d/%Y %H:%M')}</td>
-          <td>
-          % if pgstat.player_id > 2:
-            <a href="${request.route_url('player_info', id=pgstat.player_id)}" title="Go to the player info page for this player">${pgstat.nick_html_colors()|n}</a>
-          </td>
-          % else:
-            ${pgstat.nick_html_colors()|n}
-          </td>
-          % endif
-        </tr>
-            % else:
-            <tr>
-              <td>-</td>
-              <td>-</td>
-              <td>-</td>
-              <td>-</td>
-              <td>-</td>
-            </tr>
-            % endif
-        % endfor
-        </tbody>
-    </table>
-  </div>
-</div>
-
-
 <div class="row">
   <div class="span4">
     <h3>Top Scoring Players</h3>
@@ -163,4 +117,52 @@ Server Information
 
 </div> <!-- /row -->
 
+
+
+<div class="row">
+  <div class="span12">
+    <h3>Recent Games</h2>
+    <table class="table table-bordered table-condensed">
+      <thead>
+        <tr>
+          <th></th>
+          <th>Type</th>
+          <th>Map</th>
+          <th>Time</th>
+          <th>Winner</th>
+        </tr>
+      </thead>
+      <tbody>
+      % for (game, srv, map, pgstat) in recent_games:
+        % if game != '-':
+        <tr>
+          <td><a class="btn btn-primary btn-small" href="${request.route_url('game_info', id=game.game_id)}" title="View detailed information about this game">View</a></td>
+          <td class="gt_icon"><img title="${game.game_type_cd}" src="/static/images/icons/24x24/${game.game_type_cd}.png" alt="${game.game_type_cd}" /></td>
+          <td><a href="${request.route_url('map_info', id=map.map_id)}" title="Go to the map detail page for this map">${map.name}</a></td>
+          <td>${game.start_dt.strftime('%m/%d/%Y %H:%M')}</td>
+          <td>
+          % if pgstat.player_id > 2:
+            <a href="${request.route_url('player_info', id=pgstat.player_id)}" title="Go to the player info page for this player">${pgstat.nick_html_colors()|n}</a>
+          </td>
+          % else:
+            ${pgstat.nick_html_colors()|n}
+          </td>
+          % endif
+        </tr>
+            % else:
+            <tr>
+              <td>-</td>
+              <td>-</td>
+              <td>-</td>
+              <td>-</td>
+              <td>-</td>
+            </tr>
+            % endif
+        % endfor
+        </tbody>
+    </table>
+  </div>
+</div>
+
+
 % endif