public void dataExport() {
String path = getContext().getRealPath();
String tempPath = path + "docs"+File.separator+"excelTemp"+File.separator+"aboutDeviceTable.xls";
String destPath = path + "docs"+File.separator+"destExcel"+File.separator+"aboutDeviceTable.xls";
// 生成excel
ExcelUtil.doExcel(tempPath, beans, destPath);
LvMain lvMain=(LvMain) beans.get("deviceInfo");
String name= lvMain.getDeviceName()+"台区配变低压概况及厂站低压设备.xls";
// 下载excel
ExcelUtil.doDownLoad(destPath, name,
getContext().getResponse());
}
- 1
- 2
前往页