def get_team(self):
    return PlayerRole.objects.get(player=self).team
PLAYER_ROLES = ('Regular', 'Regular'), ('Captain', 'Captain')


class PlayerRole(Model):
    player = OneToOneField(Player, primary_key=True)
team = ForeignKey(Team, null=True)
role = CharField(max_length=20, choices=PLAYER_ROLES, default=PLAYER_ROLES[
    0][0])


class Meta:
    unique_together = 'player', 'team'
Django circular model reference