diff --git a/services/webapp/code/rosetta/core_app/models.py b/services/webapp/code/rosetta/core_app/models.py index 5bb17919cde5e0e4b9dfeb9fa3e80d0fad330ae3..9749a1a710b92eeb482ec9b4907bd5c09d5508fe 100644 --- a/services/webapp/code/rosetta/core_app/models.py +++ b/services/webapp/code/rosetta/core_app/models.py @@ -247,7 +247,7 @@ class ComputingSysConf(models.Model): def __str__(self): - return str('Computing sys conf for {} with id "{}"'.format(self.computing, self.id)) + return 'Computing sys conf for {} with id "{}"'.format(self.computing, self.id) @@ -258,10 +258,13 @@ class ComputingUserConf(models.Model): computing = models.ForeignKey(Computing, related_name='+', on_delete=models.CASCADE) data = JSONField(blank=True, null=True) - @property def id(self): - return str('Computing user conf for {} with id "{}" of user "{}"'.format(self.computing, self.id, self.user)) + return str(self.uuid).split('-')[0] + + def __str__(self): + return 'Computing user conf for {} with id "{}" of user "{}"'.format(self.computing, self.id, self.user) +