diff options
-rw-r--r-- | src/matchbox/db/main/models.py | 1 | ||||
-rw-r--r-- | web/main/views.py | 2 | ||||
-rw-r--r-- | web/templates/view-package-props.html | 1 |
3 files changed, 3 insertions, 1 deletions
diff --git a/src/matchbox/db/main/models.py b/src/matchbox/db/main/models.py index 1b9946b..9263470 100644 --- a/src/matchbox/db/main/models.py +++ b/src/matchbox/db/main/models.py @@ -26,6 +26,7 @@ class PackageProperties(models.Model): error_code = models.IntegerField() contents = models.ManyToManyField('File',through='PackageProperties_File') useflags = models.ManyToManyField('Useflag') + timeadded = models.DateTimeField(auto_now_add=True) class Attachment(models.Model): packageproperties = models.ForeignKey('PackageProperties') diff --git a/web/main/views.py b/web/main/views.py index 3e5fe77..174453b 100644 --- a/web/main/views.py +++ b/web/main/views.py @@ -61,7 +61,7 @@ def view(request, category_name, pkg_name, pkg_ver): raise Http404 pv = pv[0] - pprops = pv.packageproperties_set.all() + pprops = pv.packageproperties_set.order_by('-timeadded') cpv = "%s/%s-%s" % (category_name, pkg_name, pkg_ver) return render_to_response('view-package-props.html',{'pprops':pprops,'cpv':cpv}) diff --git a/web/templates/view-package-props.html b/web/templates/view-package-props.html index 16e27ea..b262bea 100644 --- a/web/templates/view-package-props.html +++ b/web/templates/view-package-props.html @@ -10,6 +10,7 @@ Compile information for: {{cpv}} {% for prop in pprops %} <div class="compileinfo-{% cycle odd,even %}"> + Added to db: {{prop.timeadded|date:"r"}}<br /> Portage profile: {{prop.profile.name}}<br /> Error code: {{prop.error_code}} <br /> Tinderbox IP: {{prop.tinderbox.ip}} <br /> |