split gamecard into its own app, add models to teamsnap for custom fields (images)

This commit is contained in:
2022-06-09 07:46:53 -05:00
parent aa897f6f49
commit abdab2d30b
56 changed files with 273 additions and 58 deletions

View File

@@ -7,3 +7,43 @@ from benchcoach.users.models import User
class Preferences(models.Model):
user = models.OneToOneField(User, on_delete=models.CASCADE)
managed_team_id = models.IntegerField()
class Team(models.Model):
id = models.IntegerField(primary_key=True)
logo = models.ImageField(
upload_to="logos",
height_field=None,
width_field=None,
max_length=100,
null=True,
blank=True,
)
logo_mono = models.ImageField(
upload_to="logos_mono",
height_field=None,
width_field=None,
max_length=100,
null=True,
blank=True,
)
class Opponent(models.Model):
id = models.IntegerField(primary_key=True)
logo = models.ImageField(
upload_to="logos",
height_field=None,
width_field=None,
max_length=100,
null=True,
blank=True,
)
logo_mono = models.ImageField(
upload_to="logos_mono",
height_field=None,
width_field=None,
max_length=100,
null=True,
blank=True,
)