diff --git a/src/com/engine/organization/service/impl/ImportCommonServiceImpl.java b/src/com/engine/organization/service/impl/ImportCommonServiceImpl.java index 0e616815..98d15b15 100644 --- a/src/com/engine/organization/service/impl/ImportCommonServiceImpl.java +++ b/src/com/engine/organization/service/impl/ImportCommonServiceImpl.java @@ -687,6 +687,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); Long parentCompanyId = null; @@ -892,6 +895,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); Long parentCompanyId = null; @@ -1126,6 +1132,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); Long parentCompanyId = null; @@ -1388,6 +1397,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); Long parentCompanyId = null; @@ -1665,6 +1677,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); SchemePO schemePO = new SchemePO(); @@ -2273,6 +2288,9 @@ public class ImportCommonServiceImpl extends Service implements ImportCommonServ */ private boolean hasSameName(JclImportHistoryDetailPO historyDetailPO, String cellValue) { String operateDetail = ""; + if (StringUtils.isBlank(cellValue)) { + return false; + } List resourceIds = MapperProxyFactory.getProxy(EmployeeMapper.class).getResourceIdsByName(cellValue); if (CollectionUtils.isEmpty(resourceIds)) { operateDetail = "[" + cellValue + "]未找到对应人员"; diff --git a/src/com/engine/organization/util/saveimport/PostInfoImportUtil.java b/src/com/engine/organization/util/saveimport/PostInfoImportUtil.java index 7a94e567..1aaca042 100644 --- a/src/com/engine/organization/util/saveimport/PostInfoImportUtil.java +++ b/src/com/engine/organization/util/saveimport/PostInfoImportUtil.java @@ -4,7 +4,6 @@ import com.engine.organization.entity.extend.po.ExtendInfoPO; import com.engine.organization.entity.jclimport.po.JclImportHistoryDetailPO; import com.engine.organization.entity.postion.po.PostInfoPO; import com.engine.organization.entity.postion.po.PostPO; -import com.engine.organization.entity.staff.po.StaffPlanPO; import com.engine.organization.mapper.post.PostInfoMapper; import com.engine.organization.mapper.post.PostMapper; import com.engine.organization.util.OrganizationAssert; @@ -66,6 +65,9 @@ public class PostInfoImportUtil { historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); PostInfoPO postInfoPO = null; diff --git a/src/com/engine/organization/util/saveimport/StaffInfoImportUtil.java b/src/com/engine/organization/util/saveimport/StaffInfoImportUtil.java index fbc9770c..d3936eb9 100644 --- a/src/com/engine/organization/util/saveimport/StaffInfoImportUtil.java +++ b/src/com/engine/organization/util/saveimport/StaffInfoImportUtil.java @@ -78,6 +78,9 @@ public class StaffInfoImportUtil { historyDetailPO = new JclImportHistoryDetailPO(); historyDetailPO.setPid(importHistoryId); XSSFRow row = sheetAt.getRow(i); + if (null == row) { + continue; + } // 组装待处理数据 Map map = new HashMap<>(); Long parentCompanyId = null;