Permalink
Browse files

Change to initialize the queryset when a ModelReport is created.

  • Loading branch information...
1 parent 68614f3 commit 5d015a0197eb7d0f1402f1cebac70d8918ba6d5b @kmooney kmooney committed Jul 16, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 reportengine/base.py
View
@@ -103,7 +103,12 @@ def get_rows(self,filters={},order_by=None):
class ModelReport(QuerySetReport):
model = None
-
+
+
+ def __init__(self):
+ super(ModelReport, self).__init__()
+ self.queryset = self.model.objects.all()
+
def get_queryset(self, filters, order_by, queryset=None):
if queryset is None and self.queryset is None:
queryset = self.model.objects.all()

0 comments on commit 5d015a0

Please sign in to comment.