Commit c799060a authored by dahai's avatar dahai

push

parent e021f88c
......@@ -35,7 +35,7 @@ public class ExportExcelApi {
// //使用Servlet实现文件下载的时候,避免浏览器自动打开文件
String fout = null;
fout = ExportExcel.exportExcelDate(mapList);
String outFile = dateTime + "公安网数据";
String outFile = dateTime + "myExcel";
try {
FileInputStream fis = new FileInputStream(new File(fout));
byte[] b = new byte[fis.available()];
......
......@@ -162,7 +162,7 @@ public class ExportXMLApi {
* @throws IOException 可能出现文件写入不成功
*/
private String createToMakePackageXML(List<PreproPersonEntity> preproPersonEntities , FilesEntity filesEntity, String url) throws IOException {
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd");
SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMdd");
SimpleDateFormat simpleDateFormat2 = new SimpleDateFormat("yyyyMMddhhmmss");
Document document = DocumentHelper.createDocument();
Element PACKAGE = DocumentHelper.createElement("PACKAGE");
......@@ -186,7 +186,7 @@ public class ExportXMLApi {
newFilesEntity.setVersionCode(filesEntity.getVersionCode());
newFilesEntity.setRecordNumber((long)preproPersonEntities.size());
long l = newFilesService.saveNewFiles(newFilesEntity);
newFilesEntity.setNewFileName(simpleDateFormat.format(new Date())+"-"+newFilesEntity.getId());
newFilesEntity.setNewFileName("ZAGL_ZZJH_"+filesEntity.getDwdm()+simpleDateFormat.format(new Date())+""+newFilesEntity.getId());
newFilesService.updateNewFileName(newFilesEntity);
int NO=1;
......@@ -246,7 +246,7 @@ public class ExportXMLApi {
preproPersonService.updatePreproPerson_NewFileName(preproPersonEntities);
String files_seq = newFilesEntity.getId()+"";
try {
FileOutputStream fos = new FileOutputStream("D:\\XML\\" + simpleDateFormat.format(new Date())+"-"+files_seq+ ".xml");
FileOutputStream fos = new FileOutputStream("D:\\XML\\"+"ZAGL_ZZJH_"+filesEntity.getDwdm() + simpleDateFormat.format(new Date())+"-"+files_seq+ ".xml");
OutputStreamWriter osw = new OutputStreamWriter(fos, "UTF-8");
OutputFormat of = new OutputFormat();
of.setEncoding("UTF-8");
......@@ -265,7 +265,7 @@ public class ExportXMLApi {
// return document;
return "D:\\XML\\" + simpleDateFormat.format(new Date())+"-"+files_seq+ ".xml";
return "D:\\XML\\" +"ZAGL_ZZJH_"+filesEntity.getDwdm()+ simpleDateFormat.format(new Date())+"-"+files_seq+ ".xml";
}
/**
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment