def get_project_urls(self): # XXX: Django 1.10 requires a view callable. I was too lazy to figure out # how to mock one, so just using this random low-level thing. # As far as I can see, none of our plugins use get_project_urls, so # all this can probably even be removed, but I'm keeping it here for now # for fear of breakage. from django.views.generic.list import BaseListView return [url("", BaseListView.as_view())]
def get(self, request, *args, **kwargs): if not hasattr(self, 'token'): self.token = kwargs["token"] self.columns = TableDataMap.get_columns(self.token) query_form = QueryDataForm(request.GET) if query_form.is_valid(): self.query_data = query_form.cleaned_data else: return self.render_to_response({"error": "Query form is invalid."}) return BaseListView.get(self, request, *args, **kwargs)