change the __str__ return value for the computer class to string

as the name suggests __str__ needs to be of type string.
This commit is contained in:
Andreas Zweili 2017-12-24 23:53:13 +01:00
parent 82a942aa5e
commit 5047e7965d
2 changed files with 2 additions and 2 deletions

View File

@ -208,7 +208,7 @@ class Computer(Device):
on_delete=models.PROTECT)
def __str__(self):
return self.hostname
return str(self.hostname)
#+END_SRC
** ComputerDiskRelation and ComputerRamRelation

View File

@ -148,7 +148,7 @@ class Computer(Device):
on_delete=models.PROTECT)
def __str__(self):
return self.hostname
return str(self.hostname)
class ComputerDiskRelation(models.Model):