Add more admin page columns

This commit is contained in:
Tanner Collin 2022-11-16 11:04:07 +00:00
parent f724ec9c30
commit 008be53be3

View File

@ -197,16 +197,22 @@ class StatsMemberCount(models.Model):
vetted_count = models.IntegerField() vetted_count = models.IntegerField()
subscriber_count = models.IntegerField() subscriber_count = models.IntegerField()
MY_FIELDS = ['date', 'member_count', 'green_count', 'six_month_plus_count', 'vetted_count', 'subscriber_count']
class StatsSignupCount(models.Model): class StatsSignupCount(models.Model):
month = models.DateField() month = models.DateField()
signup_count = models.IntegerField() signup_count = models.IntegerField()
retain_count = models.IntegerField(default=0) retain_count = models.IntegerField(default=0)
vetted_count = models.IntegerField(default=0) vetted_count = models.IntegerField(default=0)
MY_FIELDS = ['month', 'signup_count', 'retain_count', 'vetted_count']
class StatsSpaceActivity(models.Model): class StatsSpaceActivity(models.Model):
date = models.DateField(default=today_alberta_tz) date = models.DateField(default=today_alberta_tz)
card_scans = models.IntegerField() card_scans = models.IntegerField()
MY_FIELDS = ['date', 'card_scans']
class Usage(models.Model): class Usage(models.Model):
user = models.ForeignKey(User, related_name='usages', blank=True, null=True, on_delete=models.SET_NULL) user = models.ForeignKey(User, related_name='usages', blank=True, null=True, on_delete=models.SET_NULL)