Example #1
0
 def init_with_context(self, context):
     self.children = []
     request = context['request']
     for slug, report in reporting.user_reports(request):
         self.children.append({
             'title': report.verbose_name,
             'url': reverse('reporting-view', kwargs={'slug': slug}),
             'external': False,
         })
Example #2
0
 def get_reports(self):
     report_classes = reporting.user_reports(self.request)
     reports = []
     for slug, klass in report_classes:
         reports.append((
             slug,
             klass(self.request),
         ))
     return reports
Example #3
0
 def init_with_context(self, context):
     self.children = []
     request = context['request']
     for slug, report in reporting.user_reports(request):
         self.children.append({
             'title':
             report.verbose_name,
             'url':
             reverse('reporting-view', kwargs={'slug': slug}),
             'external':
             False,
         })
Example #4
0
 def get_reports(self):
     report_classes = reporting.user_reports(self.request)
     reports = []
     for slug, klass in report_classes:
         reports.append((slug, klass(self.request),))
     return reports