Add UserConsent to models.

This commit is contained in:
juanifioren 2015-06-22 18:42:04 -03:00
parent 9211b4200a
commit 544861abec

View file

@ -59,7 +59,7 @@ class BaseCodeTokenModel(models.Model):
return timezone.now() >= self.expires_at return timezone.now() >= self.expires_at
def __str__(self): def __str__(self):
return "%s - %s (%s)" % (self.client, self.user, self.expires_at) return "%s - %s (%s)" % (self.client, self.user.email, self.expires_at)
def __unicode__(self): def __unicode__(self):
return self.__str__() return self.__str__()
@ -141,3 +141,8 @@ class UserInfo(models.Model):
formatted = formatted[2:] formatted = formatted[2:]
if formatted.endswith(', '): if formatted.endswith(', '):
formatted = formatted[:-2] formatted = formatted[:-2]
class UserConsent(BaseCodeTokenModel):
pass