mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-03-25 01:14:43 +00:00
Added stats to wrestler -> show
This commit is contained in:
@@ -134,5 +134,11 @@ class Match < ActiveRecord::Base
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
def list_w2_stats
|
||||
"#{w2_name}: #{w2_stat}"
|
||||
end
|
||||
|
||||
def list_w1_stats
|
||||
"#{w1_name}: #{w1_stat}"
|
||||
end
|
||||
end
|
||||
|
||||
@@ -40,5 +40,11 @@
|
||||
<br>
|
||||
<% @wrestler.allMatches.each do |m| %>
|
||||
<div> Bout: <%= m.bout_number %> <%= m.bracket_position %> <%= m.wrestler1.name %> vs. <%= m.wrestler2.name %> <%= @wrestler.resultByBout(m.bout_number) %></div>
|
||||
<% if m.w1_stat || m.w2_stat %>
|
||||
<div>Stats:</div>
|
||||
<div><%= m.list_w1_stats %></div>
|
||||
<div><%= m.list_w2_stats %></div>
|
||||
</br>
|
||||
<% end %>
|
||||
<% end %>
|
||||
<% end %>
|
||||
Reference in New Issue
Block a user