Commit 2d735b7f authored by Daniel STAN's avatar Daniel STAN

voip: certains appels n'ont pas de durée

Si cela n'a pas décroché, le champ est à NULL (None en python)
parent d97651f7
......@@ -226,4 +226,8 @@ class Call(models.Model):
date = models.DateField(u"Date d'initiation de l'appel")
def __unicode__(self):
return u"%s -> %s @ %s (%ds)" % (self.src, self.dst, self.date, self.duration)
o = u"%s -> %s @ %s" % (self.src, self.dst, self.date)
if self.duration:
o += " (%ds)" % self.duration
return o
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment