예제 #1
0
 def excel(self):
     excel = RegistrantsListToExcel(self._conf,
                                    list=self._list,
                                    display=self._display,
                                    excelSpecific=self._excelSpecific)
     return send_file('RegistrantsList.csv', StringIO(excel.getExcelFile()),
                      'CSV')
예제 #2
0
 def excel( self ):
     filename = "RegistrantsList.csv"
     excel = RegistrantsListToExcel(self._conf,list=self._list, display=self._display, excelSpecific=self._excelSpecific)
     data = excel.getExcelFile()
     self._rh._req.set_content_length(len(data))
     cfg = Config.getInstance()
     mimetype = cfg.getFileTypeMimeType( "CSV" )
     self._rh._req.content_type = """%s"""%(mimetype)
     self._rh._req.headers_out["Content-Disposition"] = """inline; filename="%s\""""%filename
     return data
예제 #3
0
 def excel( self ):
     filename = "RegistrantsList.csv"
     excel = RegistrantsListToExcel(self._conf,list=self._list, display=self._display, excelSpecific=self._excelSpecific)
     data = excel.getExcelFile()
     self._rh._req.set_content_length(len(data))
     cfg = Config.getInstance()
     mimetype = cfg.getFileTypeMimeType( "CSV" )
     self._rh._req.content_type = """%s"""%(mimetype)
     self._rh._req.headers_out["Content-Disposition"] = """inline; filename="%s\""""%filename
     return data
예제 #4
0
 def excel(self):
     excel = RegistrantsListToExcel(self._conf, list=self._list, display=self._display,
                                    excelSpecific=self._excelSpecific)
     return send_file('RegistrantsList.csv', StringIO(excel.getExcelFile()), 'CSV')