diff options
Diffstat (limited to 'servo/models')
-rw-r--r-- | servo/models/product.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/servo/models/product.py b/servo/models/product.py index a92e750..5d97ae3 100644 --- a/servo/models/product.py +++ b/servo/models/product.py @@ -546,6 +546,9 @@ class ProductCategory(MPTTModel): objects = TreeManager() def get_products(self): + """ + Returns products under this entire category branch + """ return Product.objects.filter( categories__lft__gte=self.lft, categories__rght__lte=self.rght, |