mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-03-25 01:14:43 +00:00
Fixed caching for wrestler and school show pages
This commit is contained in:
@@ -36,6 +36,7 @@
|
||||
<% end %>
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<table class="table table-striped table-bordered table-condensed">
|
||||
<thead>
|
||||
<tr>
|
||||
@@ -51,7 +52,7 @@
|
||||
|
||||
<tbody>
|
||||
<% @wrestlers.sort_by{|w| w.weight.max}.each do |wrestler| %>
|
||||
<% if wrestler.school_id == @school.id %>
|
||||
<% cache ["schools_view_wrestler", wrestler] do %>
|
||||
<tr>
|
||||
<td><%= wrestler.name %></td>
|
||||
<td><%= wrestler.weight.max %></td>
|
||||
@@ -63,6 +64,7 @@
|
||||
Yes
|
||||
<% end %></td>
|
||||
<td><%= wrestler.nextMatchBoutNumber %> <%= wrestler.nextMatchMatName %></td>
|
||||
<% end %>
|
||||
<td>
|
||||
<%= link_to 'Show', wrestler , :class=>"btn btn-default btn-sm" %>
|
||||
<% if can? :manage, wrestler.school %>
|
||||
@@ -71,7 +73,6 @@
|
||||
<% end %>
|
||||
</td>
|
||||
</tr>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
Reference in New Issue
Block a user