This commit is contained in:
Nick Winter 2014-07-15 09:47:13 -07:00
parent 3318d4a171
commit da73975f20

View file

@ -83,9 +83,9 @@ module.exports = class MyMatchesTabView extends CocoView
team.matches = (convertMatch(match, team.session.get('submitDate')) for match in team.session?.get('matches') or [])
team.matches.reverse()
team.score = (team.session?.get('totalScore') or 10).toFixed(2)
team.wins = _.filter(team.matches, {state: 'win'}).length
team.ties = _.filter(team.matches, {state: 'tie'}).length
team.losses = _.filter(team.matches, {state: 'loss'}).length
team.wins = _.filter(team.matches, {state: 'win', stale: false}).length
team.ties = _.filter(team.matches, {state: 'tie', stale: false}).length
team.losses = _.filter(team.matches, {state: 'loss', stale: false}).length
scoreHistory = team.session?.get('scoreHistory')
if scoreHistory?.length > 1
team.scoreHistory = scoreHistory