forked from DGNum/gestioCOF
Ajoute des fonctions __str__
là où ça manque
This commit is contained in:
parent
4d27d85384
commit
ea6e7a1472
2 changed files with 20 additions and 1 deletions
|
@ -89,6 +89,9 @@ class Club(models.Model):
|
|||
respos = models.ManyToManyField(User, related_name="clubs_geres")
|
||||
membres = models.ManyToManyField(User, related_name="clubs")
|
||||
|
||||
def __str__(self):
|
||||
return self.name
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class CustomMail(models.Model):
|
||||
|
@ -148,6 +151,9 @@ class EventCommentValue(models.Model):
|
|||
related_name="comments")
|
||||
content = models.TextField("Contenu", blank=True, null=True)
|
||||
|
||||
def __str__(self):
|
||||
return "Commentaire de %s" % self.commentfield
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class EventOption(models.Model):
|
||||
|
@ -243,8 +249,16 @@ class SurveyAnswer(models.Model):
|
|||
verbose_name = "Réponses"
|
||||
unique_together = ("user", "survey")
|
||||
|
||||
def __str__(self):
|
||||
return "Réponse de %s sondage %s" % (
|
||||
self.user.get_full_name(),
|
||||
self.survey.title)
|
||||
|
||||
|
||||
@python_2_unicode_compatible
|
||||
class Clipper(models.Model):
|
||||
username = models.CharField("Identifiant", max_length=20)
|
||||
fullname = models.CharField("Nom complet", max_length=200)
|
||||
|
||||
def __str__(self):
|
||||
return "Clipper %s" % self.username
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue