Skip to content

Commit

Permalink
优化导入带标题文件关闭清理
Browse files Browse the repository at this point in the history
  • Loading branch information
yangzongzhuan committed Dec 25, 2024
1 parent b45dc2e commit 88ad5a2
Showing 1 changed file with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -283,11 +283,23 @@ public void createSubHead()
* @return 转换后集合
*/
public List<T> importExcel(InputStream is)
{
return importExcel(is, 0);
}

/**
* 对excel表单默认第一个索引名转换成list
*
* @param is 输入流
* @param titleNum 标题占用行数
* @return 转换后集合
*/
public List<T> importExcel(InputStream is, int titleNum)
{
List<T> list = null;
try
{
list = importExcel(is, 0);
list = importExcel(StringUtils.EMPTY, is, titleNum);
}
catch (Exception e)
{
Expand All @@ -301,18 +313,6 @@ public List<T> importExcel(InputStream is)
return list;
}

/**
* 对excel表单默认第一个索引名转换成list
*
* @param is 输入流
* @param titleNum 标题占用行数
* @return 转换后集合
*/
public List<T> importExcel(InputStream is, int titleNum) throws Exception
{
return importExcel(StringUtils.EMPTY, is, titleNum);
}

/**
* 对excel表单指定表格索引名转换成list
*
Expand Down

0 comments on commit 88ad5a2

Please sign in to comment.