diff options
Diffstat (limited to 'bitbake')
-rw-r--r-- | bitbake/lib/toaster/orm/models.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index 2d7ef09bb1..3b72f802a0 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py | |||
@@ -23,6 +23,7 @@ from django.db import models | |||
23 | from django.db.models import F, Q, Avg | 23 | from django.db.models import F, Q, Avg |
24 | from django.utils import timezone | 24 | from django.utils import timezone |
25 | 25 | ||
26 | from django.core.urlresolvers import reverse | ||
26 | 27 | ||
27 | from django.core import validators | 28 | from django.core import validators |
28 | from django.conf import settings | 29 | from django.conf import settings |
@@ -1109,6 +1110,9 @@ class Layer_Version(models.Model): | |||
1109 | return self.up_branch.name | 1110 | return self.up_branch.name |
1110 | return ("Cannot determine the vcs_reference for layer version %s" % vars(self)) | 1111 | return ("Cannot determine the vcs_reference for layer version %s" % vars(self)) |
1111 | 1112 | ||
1113 | def get_detailspage_url(self, project_id): | ||
1114 | return reverse('layerdetails', args=(project_id, self.pk)) | ||
1115 | |||
1112 | def __unicode__(self): | 1116 | def __unicode__(self): |
1113 | return "%d %s (VCS %s, Project %s)" % (self.pk, str(self.layer), self.get_vcs_reference(), self.build.project if self.build is not None else "No project") | 1117 | return "%d %s (VCS %s, Project %s)" % (self.pk, str(self.layer), self.get_vcs_reference(), self.build.project if self.build is not None else "No project") |
1114 | 1118 | ||