作者 RuoYi

代码生成防止缓存内的数据没有及时写入到zip文件

@@ -262,6 +262,7 @@ public class GenTableServiceImpl implements IGenTableService @@ -262,6 +262,7 @@ public class GenTableServiceImpl implements IGenTableService
262 zip.putNextEntry(new ZipEntry(VelocityUtils.getFileName(template, table))); 262 zip.putNextEntry(new ZipEntry(VelocityUtils.getFileName(template, table)));
263 IOUtils.write(sw.toString(), zip, Constants.UTF8); 263 IOUtils.write(sw.toString(), zip, Constants.UTF8);
264 IOUtils.closeQuietly(sw); 264 IOUtils.closeQuietly(sw);
  265 + zip.flush();
265 zip.closeEntry(); 266 zip.closeEntry();
266 } 267 }
267 catch (IOException e) 268 catch (IOException e)