mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-26 01:42:16 +00:00
Fix for a situation that should be impossible
This commit is contained in:
@@ -148,7 +148,7 @@ class Asset(models.Model, RevisionMixin):
|
|||||||
|
|
||||||
def __str__(self):
|
def __str__(self):
|
||||||
out = str(self.asset_id) + ' - ' + self.description
|
out = str(self.asset_id) + ' - ' + self.description
|
||||||
if self.is_cable:
|
if self.is_cable and self.cable_type is not None:
|
||||||
out += '{} - {}m - {}'.format(self.cable_type.plug, self.length, self.cable_type.socket)
|
out += '{} - {}m - {}'.format(self.cable_type.plug, self.length, self.cable_type.socket)
|
||||||
return out
|
return out
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user