1
0
mirror of https://github.com/jcwimer/wrestlingApp synced 2026-03-25 01:14:43 +00:00

Fixed caching of school view

This commit is contained in:
2023-02-02 13:11:01 +00:00
parent c133a8b051
commit 1078dc9e97

View File

@@ -37,8 +37,8 @@
</thead>
<tbody>
<% cache ["#{@school.id}_school_show", @school] do %>
<% @wrestlers.sort_by{|w| w.weight.max}.each do |wrestler| %>
<% cache ["#{wrestler.id}_school_show", @school] do %>
<tr>
<td><%= link_to "#{wrestler.name}", wrestler %></td>
<td><%= wrestler.weight.max %></td>
@@ -49,7 +49,9 @@
<td><%= wrestler.total_team_points - wrestler.total_points_deducted %></td>
<td><% if wrestler.extra? == true %>
Yes
<% end %></td>
<% end %>
</td>
<% end %>
<td><%= wrestler.next_match_bout_number %> <%= wrestler.next_match_mat_name %></td>
<% if can? :manage, wrestler.school %>
<td>
@@ -61,7 +63,7 @@
<% end %>
</tbody>
</table>
<% end %>
<% if can? :manage, @school %>
<%= render 'baums_roster_import' %>
<% end %>