sol.models.competitor – Competitors¶
-
class
sol.models.competitor.Competitor(**kwargs)¶ A single competitor in a game.
A competitor may be a single person or a team of up to four players, that participate to a given tourney. On each competitor this table keeps the points, the netscore and his bucholz, as well as the final prize. To disambiguate the ranking it maintains also a totscore, the total number of pocketed carrommen summing up competitor’ scores in all played games.
-
bucholz¶ Weight of the opponents (sum of opponents’ points and netscore).
-
caption(html=None, localized=True, player_caption=None)¶ A description of the competitor, made up with the name of each player.
-
description¶ A description of the competitor, made up with the name of each player.
-
idcompetitor¶ Primary key.
-
nationality¶ Nationality of the first player
-
netscore¶ Net score (sum of carrommen difference in each match).
-
player1FirstName¶ First name of the first player
-
player1FullName¶ Full name of the first player
-
player1LastName¶ Last name of the first player
-
player1Nationality¶ Nationality of the first player
-
player1Sex¶ Gender of the first player
-
player2FullName¶ Full name of the second player
-
player2Nationality¶ Nationality of the second player
-
player3FullName¶ Full name of the third player
-
player3Nationality¶ Nationality of the third player
-
player4FullName¶ Full name of the fourth player
-
player4Nationality¶ Nationality of the fourth player
-
points¶ Points (number of wins * 2 + number of draws).
-
prize¶ Final prize.
-
rank¶ The position of this competitor in the tourney’s ranking.
-
rate¶ Rate of this competitor, summing up all players rates
-
retired¶ A competitor may stop playing in the middle of the tourney.
-
serialize(serializer)¶ Reduce a single competitor to a simple dictionary.
Parameters: serializer – a SerializerinstanceReturn type: dict Returns: a plain dictionary containing a flatified view of this competitor
-
totscore¶ Total score (sum of carrommen in each match).
-