diff --git a/registrasion/reporting/forms.py b/registrasion/reporting/forms.py index f4902660..94e99491 100644 --- a/registrasion/reporting/forms.py +++ b/registrasion/reporting/forms.py @@ -4,6 +4,7 @@ from django import forms # Staff-facing forms. + class ProductAndCategoryForm(forms.Form): product = forms.ModelMultipleChoiceField( queryset=inventory.Product.objects.all(), diff --git a/registrasion/reporting/reports.py b/registrasion/reporting/reports.py index 9ba63f06..ab8e924d 100644 --- a/registrasion/reporting/reports.py +++ b/registrasion/reporting/reports.py @@ -120,7 +120,9 @@ class QuerysetReport(BasicReport): def __init__(self, title, attributes, queryset, headings=None, link_view=None): - super(QuerysetReport, self).__init__(title, headings, link_view=link_view) + super(QuerysetReport, self).__init__( + title, headings, link_view=link_view + ) self._attributes = attributes self._queryset = queryset @@ -178,6 +180,7 @@ class Links(Report): self._linked_text(content_type, url, link_text) ] + def report_view(title, form_type=None): ''' Decorator that converts a report view function into something that displays a Report.