Sha256: 4124ef71753e68b9c127f1890314e9fcc75d283a318d5cb60d9efc994bed1566
Contents?: true
Size: 1.26 KB
Versions: 4
Compression:
Stored size: 1.26 KB
Contents
<table class='play'> <% last_play_at = Time.local( 1999, 1, 1 ) games.each do |game| %> <% unless last_play_at.year == game.play_at.year && last_play_at.month == game.play_at.month && last_play_at.day == game.play_at.day %> <% unless last_play_at.year == game.play_at.year %> <tr class='game-year'> <td colspan='2'></td> <td colspan='7'> <%= game.play_at.strftime('%Y') %></td> </tr> <% end %> <!-- todo: find a method for week number; do NOT use strftime; there must be something easier --> <% unless last_play_at.strftime('%V') == game.play_at.strftime('%V') %> <tr class='game-week'> <td colspan='2'></td> <td colspan='7'>Week <%= game.play_at.strftime('%V') %></td> </tr> <% end %> <tr class='game-day'> <td></td> <td colspan='8'><%= game.play_at.strftime('%A, %d. %B') %></td> </tr> <% end %> <tr> <td class='game-hour'> <%= game.play_at.strftime('%H:%M') %> </td> <%= render_game_team1( game ) %> <%= render_game_score( game ) %> <%= render_game_team2( game ) %> <%= render_game_flags( game ) %> <%= render_game_round( game ) %> </tr> <% last_play_at = game.play_at end %><!-- each game --> </table>
Version data entries
4 entries across 4 versions & 1 rubygems