feat: 导入自动匹配文件类型 不限制xls

(cherry picked from commit 878e4a8b33)
This commit is contained in:
2024-08-16 18:12:48 +08:00
parent e58e4f392f
commit f013915dff
@@ -1777,7 +1777,7 @@ public class LawsCommonServiceImpl implements ILawsCommonService {
} else {
inputStream = Files.newInputStream(excelfilelist.get(0).toPath());
}
try (Workbook workbook = new HSSFWorkbook(inputStream)) {
try (Workbook workbook = WorkbookFactory.create(inputStream)) {
// 检测是否是空Excel
Sheet sheet = workbook.getSheetAt(0);
// 验证前三行是否有数据