Liberty: add __unicode__ methods to some models

This commit is contained in:
Benjamin Dauvergne 2010-06-01 14:05:07 +02:00
parent 4d984065ac
commit 270075e5bc
1 changed files with 6 additions and 0 deletions

View File

@ -25,6 +25,9 @@ class LibertyAttributeMap(models.Model):
mappings = models.ManyToManyField(LibertyAttributeMapping,
related_name = "maps")
def __unicode__(self):
return self.name
class LibertyProvider(models.Model):
name = models.CharField(max_length = 40, unique = True,
help_text = "Internal nickname for the service provider")
@ -34,6 +37,9 @@ class LibertyProvider(models.Model):
ssl_certificate = models.FileField(
upload_to = FilenameGenerator("ssl_certificate"))
def __unicode__(self):
return self.name
class LibertyServiceProvider(LibertyProvider):
encrypt_nameid = models.BooleanField(verbose_name = "Encrypt NameID")
encrypt_assertion = models.BooleanField(