담당자연락처 암복호화
eapim-admin CI / build (push) Has been cancelled

This commit is contained in:
eastargh
2026-06-26 14:08:22 +09:00
parent 185a23d748
commit d9201eb603
@@ -15,6 +15,7 @@ import org.springframework.data.domain.Sort;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.eactive.apim.portal.jpa.PersonalDataEncryptConverter;
import com.eactive.apim.portal.user.entity.UserInfo;
import com.eactive.eai.data.converter.LocalDateTimeFormatters;
import com.eactive.eai.data.entity.onl.unifbwk.UnifBwkTp;
@@ -33,6 +34,7 @@ public class UnifbwkManService extends BaseService {
private final BizManService bizManService;
private final UserInfoService userInfoService;
private final UserDao userDao;
private final PersonalDataEncryptConverter encryptConverter = new PersonalDataEncryptConverter();
@Autowired
public UnifbwkManService(UnifBwkTpService unifBwkTpService,
@@ -54,7 +56,8 @@ public class UnifbwkManService extends BaseService {
private UnifbwkUI getUserOrgInfo(UnifBwkTp unifBwkTp) {
UnifbwkUI unifbwkUI = unifbwkUIMapper.toVo(unifBwkTp);
String rspblpsncntpctnt = unifBwkTp.getRspblpsncntpctnt();
String rspblpsncntpctnt = encryptConverter.convertToEntityAttribute(unifBwkTp.getRspblpsncntpctnt());
unifbwkUI.setRsPblpsncntpcTnt(rspblpsncntpctnt);
Optional<UserInfo> userInfo = Optional.empty();
if (StringUtils.isNotBlank(rspblpsncntpctnt)) {
@@ -75,10 +78,13 @@ public class UnifbwkManService extends BaseService {
UnifBwkTp unifBwkTp = unifBwkTpService.getById(eaiBzwkDstcd);
UnifbwkUI unifbwkUI = unifbwkUIMapper.toVo(unifBwkTp);
String rspblpsncntpctnt = encryptConverter.convertToEntityAttribute(unifBwkTp.getRspblpsncntpctnt());
unifbwkUI.setRsPblpsncntpcTnt(rspblpsncntpctnt);
Optional<UserInfo> optionalUserInfo = Optional.empty();
if (StringUtils.isNotBlank(unifBwkTp.getRspblpsncntpctnt())) {
optionalUserInfo = userInfoService.findByOfctelno(unifBwkTp.getRspblpsncntpctnt());
if (StringUtils.isNotBlank(rspblpsncntpctnt)) {
optionalUserInfo = userInfoService.findByOfctelno(rspblpsncntpctnt);
}
if (optionalUserInfo.isPresent()) {
UserInfo userInfo = optionalUserInfo.get();
@@ -90,8 +96,9 @@ public class UnifbwkManService extends BaseService {
public void insert(UnifbwkUI unifbwkUI) {
UnifBwkTp unifBwkTp = unifbwkUIMapper.toEntity(unifbwkUI);
unifBwkTp.setRspblpsncntpctnt(encryptConverter.convertToDatabaseColumn(unifBwkTp.getRspblpsncntpctnt()));
unifBwkTpService.save(unifBwkTp);
bizManService.transactionAdminBiz(unifbwkUI.getEaiBzwkDstcd());
}
@@ -113,6 +120,7 @@ public class UnifbwkManService extends BaseService {
unifbwkUI.setTrackAsisKey2Name(trackAsisKey2Name);
unifbwkUIMapper.updateToEntity(unifbwkUI, unifBwkTp);
unifBwkTp.setRspblpsncntpctnt(encryptConverter.convertToDatabaseColumn(rspblPsnCntpCtnt));
unifBwkTpService.save(unifBwkTp);
}
@@ -132,7 +140,7 @@ public class UnifbwkManService extends BaseService {
map.put("TRACKASISKEY1NAME", e.getTrackasiskey1name());
map.put("TRACKASISKEY2NAME", e.getTrackasiskey2name());
map.put("RSEMPNAME", e.getRsempname());
map.put("RSPBLPSNCNTPCTNT", e.getRspblpsncntpctnt());
map.put("RSPBLPSNCNTPCTNT", encryptConverter.convertToEntityAttribute(e.getRspblpsncntpctnt()));
map.put("GROUPCOCD", e.getGroupcocd());
if (e.getLastModDtm() != null) {
map.put("LAST_MOD_DTM",
@@ -174,6 +182,7 @@ public class UnifbwkManService extends BaseService {
}
UnifBwkTp unifBwkTp = unifbwkUIMapper.toEntity(unifbwkUI);
unifBwkTp.setRspblpsncntpctnt(encryptConverter.convertToDatabaseColumn(unifBwkTp.getRspblpsncntpctnt()));
unifBwkTpService.save(unifBwkTp);
}
@@ -206,6 +215,7 @@ public class UnifbwkManService extends BaseService {
}
unifbwkUIMapper.updateToEntity(unifbwkUI, optionalUnifBwkTp.get());
optionalUnifBwkTp.get().setRspblpsncntpctnt(encryptConverter.convertToDatabaseColumn(unifbwkUI.getRsPblpsncntpcTnt()));
unifBwkTpService.save(optionalUnifBwkTp.get());
}
}