freemarkerdor/src/main/resources/cz/xelfi/quoridor/freemarkerdor/UI/elo.fmt
author Martin Rexa <martin.rexa@centrum.cz>
Wed, 13 Jan 2010 16:57:55 +0100
changeset 218 4633b40ea42f
parent 209 bbb7d4f4e862
child 222 d783bb2a7956
permissions -rw-r--r--
Display debug info about games in list
     1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
     2 <html>
     3   <head>
     4     <title>${bundle.ELO_LIST}</title>
     5     <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
     6   </head>
     7   <body bgcolor="white">
     8       <h3><a href="/">${bundle.TITLE_PLAIN}</a></h3>
     9       <#assign first=toDate[doc.eloList.firstGame?string]/>
    10       <#assign last=toDate[doc.eloList.lastGame?string]/>
    11       <h4>${bundle.ELO_LIST} - ${last?date?string.long}</h4>
    12       <!-- New games: ${first?datetime?string.long} - ${last?datetime?string.long} -->
    13       <table border="1">
    14           <thead>
    15               <tr>
    16                   <th>#</th>
    17                   <th>${bundle.NAME}</th>
    18                   <th>${bundle.ELO}</th>
    19                   <th>${bundle.GAMES}</th>
    20               </tr>
    21           </thead>
    22           <tbody>
    23               <#assign cElo = 10000>
    24               <#assign index = 0>
    25               <#assign cIndex = index>
    26               <#list doc.eloList.elolist.* as item>
    27 
    28                 <#assign index = index + 1>
    29                 <#if cElo = item.@elo?number>
    30                 <#else>
    31                   <#assign cIndex = index>
    32                 </#if>
    33                 <#assign cElo = item.@elo?number>
    34 
    35                 <tr>
    36                 <td>${cIndex}</td>
    37                 <td>${item.@player}</td>
    38                 <td>${item.@elo?number}</td>
    39                 <td>${item.@games}</td>
    40                 </tr>
    41 
    42               </#list>
    43           </tbody>
    44       </table>
    45       <#if (doc.eloList.originalList='false')>
    46           <h4><a href="/elo?historyId=${historyId?number+1}">${bundle.ELO_PREVIOUS}</a></h4>
    47       </#if>
    48   </body>
    49 </html>