示例#1
0
 def export_response(self):
     """
     Intention: Not to be overridden in general.
     Returns the tabular export of the data, if available.
     """
     if self.exportable_all:
         export_all_rows_task.delay(self.__class__, self.__getstate__())
         return HttpResponse()
     else:
         temp = io.BytesIO()
         export_from_tables(self.export_table, temp, self.export_format)
         return export_response(temp, self.export_format, self.export_name)
示例#2
0
 def export_response(self):
     """
     Intention: Not to be overridden in general.
     Returns the tabular export of the data, if available.
     """
     if self.exportable_all:
         export_all_rows_task.delay(self.__class__, self.__getstate__())
         return HttpResponse()
     else:
         temp = StringIO()
         export_from_tables(self.export_table, temp, self.export_format)
         return export_response(temp, self.export_format, self.export_name)
示例#3
0
 def export_response(self):
     """
     Intention: Not to be overridden in general.
     Returns the tabular export of the data, if available.
     """
     self.is_rendered_as_export = True
     if self.exportable_all:
         export_all_rows_task.delay(self.__class__, self.__getstate__())
         return HttpResponse()
     else:
         # We only want to cache the responses which serve files directly
         # The response which return 200 and emails the reports should not be cached
         return self._export_response_direct()
示例#4
0
    def export_response(self):
        export_all_rows_task.delay(self.__class__, self.__getstate__())

        return HttpResponse()
示例#5
0
    def export_response(self):
        self.request.datespan = None
        export_all_rows_task.delay(self.__class__, self.__getstate__())

        return HttpResponse()
    def export_response(self):
        self.request.datespan = None
        export_all_rows_task.delay(self.__class__, self.__getstate__())

        return HttpResponse()