Ejemplo n.º 1
0
    def team(self, **kwargs):
        """
        Get a team from its Hattrick ID

        If not ht_id is defined, return the primary team of connected user.

        :key ht_id: Hattrick ID of the requested team, must be an int
        :rtype: ht_team.HTTeam
        """
        return ht_team.HTTeam(chpp=self, **kwargs)
Ejemplo n.º 2
0
 def team(self):
     return ht_team.HTTeam(chpp=self._chpp,
                           ht_id=self.team_ht_id)
Ejemplo n.º 3
0
 def home_team(self):
     return ht_team.HTTeam(chpp=self._chpp, ht_id=self.home_team_id)
Ejemplo n.º 4
0
 def away_team(self):
     return ht_team.HTTeam(chpp=self._chpp, ht_id=self.away_team_id)
Ejemplo n.º 5
0
 def teams(self):
     """Teams list of current user"""
     return [
         ht_team.HTTeam(chpp=self._chpp, ht_id=team_ht_id)
         for team_ht_id in self._teams_ht_id
     ]