Changeset 1799


Ignore:
Timestamp:
May 2, 2011, 12:38:14 PM (6 years ago)
Author:
robert@…
Message:

Adjusted assay exporting to use CSV export method

Location:
trunk/grails-app/controllers/dbnp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/grails-app/controllers/dbnp/query/AdvancedQueryController.groovy

    r1798 r1799  
    553553                                                module: "gscf",
    554554                                                name:"excel",
    555                                                 description: "Export as Excel",
     555                                                description: "Export as CSV",
    556556                                                url: createLink( controller: "study", action: "exportToExcel", params: [ 'format': 'list', 'ids' : ids ] ),
    557557                                                submitUrl: createLink( controller: "study", action: "exportToExcel", params: [ 'format': 'list' ] ),
     
    569569                                                module: "gscf",
    570570                                                name:"excel",
    571                                                 description: "Export as Excel",
     571                                                description: "Export as CSV",
    572572                                                url: createLink( controller: "assay", action: "exportToExcel", params: [ 'format': 'list', 'ids' : ids ] ),
    573573                                                submitUrl: createLink( controller: "assay", action: "exportToExcel", params: [ 'format': 'list' ] ),
  • trunk/grails-app/controllers/dbnp/studycapturing/AssayController.groovy

    r1798 r1799  
    292292                        return;
    293293
    294                 // If only 1 assay is asked for, don't bother with merging multiple assays.
    295                 // In that case just use the export method to export one assay per sheet
    296                 if( assays.size() == 1 )
    297                         return exportToExcelAsSheets( params );
    298 
    299294                // Send headers to the browser so the user can download the file
    300                 def filename = 'export.xlsx'
     295                def filename = 'export.csv'
    301296                response.setHeader("Content-disposition", "attachment;filename=\"${filename}\"")
    302297                response.setContentType("application/octet-stream")
     
    326321
    327322                        def rowData   = assayService.convertColumnToRowStructure(mergedColumnWiseData)
    328                         assayService.exportRowWiseDataToExcelFile( rowData, response.getOutputStream() )
     323                        assayService.exportRowWiseDataToCSVFile( rowData, response.getOutputStream() )
    329324
    330325                        response.outputStream.flush()
Note: See TracChangeset for help on using the changeset viewer.