diff --git a/app/views/schools/show.html.erb b/app/views/schools/show.html.erb
index 0028dec..c56963f 100644
--- a/app/views/schools/show.html.erb
+++ b/app/views/schools/show.html.erb
@@ -36,6 +36,7 @@
<% end %>
+
@@ -51,7 +52,7 @@
<% @wrestlers.sort_by{|w| w.weight.max}.each do |wrestler| %>
- <% if wrestler.school_id == @school.id %>
+ <% cache ["schools_view_wrestler", wrestler] do %>
| <%= wrestler.name %> |
<%= wrestler.weight.max %> |
@@ -63,6 +64,7 @@
Yes
<% end %>
<%= wrestler.nextMatchBoutNumber %> <%= wrestler.nextMatchMatName %> |
+ <% end %>
<%= link_to 'Show', wrestler , :class=>"btn btn-default btn-sm" %>
<% if can? :manage, wrestler.school %>
@@ -71,7 +73,6 @@
<% end %>
|
- <% end %>
<% end %>
diff --git a/app/views/wrestlers/show.html.erb b/app/views/wrestlers/show.html.erb
index c74b305..24794ba 100644
--- a/app/views/wrestlers/show.html.erb
+++ b/app/views/wrestlers/show.html.erb
@@ -5,6 +5,7 @@
<% if can? :manage, @school %>
| <%= link_to "Edit #{@wrestler.name}", edit_wrestler_path(@wrestler), :class=>"btn btn-primary" %>
<% end %>
+<% cache ["wrestlers", @wrestler] do %>
@@ -44,3 +45,4 @@
<% @wrestler.deductedPoints.each do |w| %>
Deducted points: <%= w.points %>
<% end %>
+<% end %>
\ No newline at end of file