mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-04-26 16:20:55 +00:00
Fixed win displays for brackets
This commit is contained in:
@@ -43,7 +43,17 @@ class Match < ActiveRecord::Base
|
|||||||
return ""
|
return ""
|
||||||
end
|
end
|
||||||
if self.finished == 1
|
if self.finished == 1
|
||||||
return "(#{self.score})"
|
if self.win_type == "Default"
|
||||||
|
return "Def"
|
||||||
|
elsif self.win_type == "Injury Default"
|
||||||
|
return "Inj"
|
||||||
|
elsif self.win_type == "DQ"
|
||||||
|
return "DQ"
|
||||||
|
elsif self.win_type == "Forfeit"
|
||||||
|
return "For"
|
||||||
|
else
|
||||||
|
return "(#{self.score})"
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
@@ -82,10 +82,10 @@ class Wrestler < ActiveRecord::Base
|
|||||||
return ""
|
return ""
|
||||||
end
|
end
|
||||||
if @match.first.winner_id == self.id
|
if @match.first.winner_id == self.id
|
||||||
return "W #{@match.first.score}"
|
return "W #{@match.first.bracketScore}"
|
||||||
end
|
end
|
||||||
if @match.first.winner_id != self.id
|
if @match.first.winner_id != self.id
|
||||||
return "L #{@match.first.score}"
|
return "L #{@match.first.bracketScore}"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user