From 488e98248358c245af8225577def3f5a94becc13 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Tue, 29 May 2012 11:26:18 +0200 Subject: [PATCH] allow rendered find queries, fixes #804 --- pandora/item/managers.py | 2 ++ pandora/item/models.py | 1 + 2 files changed, 3 insertions(+) diff --git a/pandora/item/managers.py b/pandora/item/managers.py index d7a90c2c8..0666c1b91 100644 --- a/pandora/item/managers.py +++ b/pandora/item/managers.py @@ -66,6 +66,8 @@ def parseCondition(condition, user): return Q(id=0) elif k == 'oshash': return Q(files__oshash=v) + elif k == 'rendered': + return Q(rendered=v) elif k == 'resolution': q = parseCondition({'key': 'width', 'value': v[0], 'operator': op}, user) \ & parseCondition({'key': 'height', 'value': v[1], 'operator': op}, user) diff --git a/pandora/item/models.py b/pandora/item/models.py index a4b554bbd..5cf7c0b09 100644 --- a/pandora/item/models.py +++ b/pandora/item/models.py @@ -685,6 +685,7 @@ class Item(models.Model): 'resolution', 'width', 'height', + 'rendered', 'rightslevel', 'saturation', 'size',