未验证 提交 583c3e84 编写于 作者: 庄家钜's avatar 庄家钜 提交者: GitHub

Merge pull request #1629 from liubenlong/master

LongestMatchColumnWidthStyleStrategy设置列宽BUG
......@@ -33,6 +33,12 @@ public class LongestMatchColumnWidthStyleStrategy extends AbstractColumnWidthSty
if (!needSetWidth) {
return;
}
//LongestMatchColumnWidthStyleStrategy设置列宽BUG:与spring集成时 ,由于bean是单例,CACHE内容不会改变,同一个报表只有第一次调用会动态设置列宽
if (cell.getRowIndex() == 0 && cell.getColumnIndex() == 0) {
CACHE.clear();
}
Map<Integer, Integer> maxColumnWidthMap = cache.get(writeSheetHolder.getSheetNo());
if (maxColumnWidthMap == null) {
maxColumnWidthMap = new HashMap<Integer, Integer>(16);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册