kopia lustrzana https://gitlab.com/marnanel/chapeau
Thing.__str___ improved, though I'm still not quite happy with it
rodzic
0b3ee9a226
commit
54465e537e
|
@ -90,13 +90,14 @@ class Thing(models.Model):
|
||||||
inactive_warning = ' INACTIVE'
|
inactive_warning = ' INACTIVE'
|
||||||
|
|
||||||
if self.f_name:
|
if self.f_name:
|
||||||
name = self.f_name
|
details = self.f_name
|
||||||
else:
|
else:
|
||||||
name = self.url
|
details = self.url
|
||||||
|
|
||||||
result = '[%s %s%s]' % (
|
result = '[%s %s %s%s]' % (
|
||||||
|
self.number,
|
||||||
self.f_type,
|
self.f_type,
|
||||||
name,
|
details,
|
||||||
inactive_warning,
|
inactive_warning,
|
||||||
)
|
)
|
||||||
return result
|
return result
|
||||||
|
|
Ładowanie…
Reference in New Issue