dev-tmp1
luotaiqian 2026-08-19 10:39:07 +08:00
parent 81083e45b2
commit e37f2ff17f
1 changed files with 1 additions and 1 deletions

View File

@ -206,6 +206,7 @@ public class OrgPersonnelExcelImporter {
transactionTemplate.execute(status -> { transactionTemplate.execute(status -> {
orgPersonnelDomainService.add(personnelEntity); orgPersonnelDomainService.add(personnelEntity);
if (!CollectionUtils.isEmpty(personnelCertEntities)) { if (!CollectionUtils.isEmpty(personnelCertEntities)) {
personnelCertEntities.forEach(it -> it.setPersonnelId(personnelEntity.getId()));
Db.saveBatch(personnelCertEntities); Db.saveBatch(personnelCertEntities);
} }
return null; return null;
@ -238,7 +239,6 @@ public class OrgPersonnelExcelImporter {
List<OrgPersonnelCertDO> orgPersonnelCertDOList = new ArrayList<>(personnelCertEntities.size()); List<OrgPersonnelCertDO> orgPersonnelCertDOList = new ArrayList<>(personnelCertEntities.size());
for (OrgPersonnelCertEntity personnelCertEntity : personnelCertEntities) { for (OrgPersonnelCertEntity personnelCertEntity : personnelCertEntities) {
personnelCertEntity.setPersonnelId(personnelEntity.getId());
OrgPersonnelCertDO orgPersonnelCertDO = orgPersonnelCertConvertor.entityToDO(personnelCertEntity); OrgPersonnelCertDO orgPersonnelCertDO = orgPersonnelCertConvertor.entityToDO(personnelCertEntity);
orgPersonnelCertDO.setOrgId(personnelCertEntity.getOrgId()); orgPersonnelCertDO.setOrgId(personnelCertEntity.getOrgId());
orgPersonnelCertDOList.add(orgPersonnelCertDO); orgPersonnelCertDOList.add(orgPersonnelCertDO);