调整批调去重逻辑
This commit is contained in:
parent
c4b22272f4
commit
9cfa118df1
|
|
@ -169,11 +169,10 @@ public class PenaltySecurityController {
|
|||
}
|
||||
|
||||
// 保存吊销主体清单到PENALTY_ENT_INFO表
|
||||
if (StringUtils.isNotBlank(penaltyCaseInfo.getCaseid())) {
|
||||
penaltyCaseInfoService.lambdaUpdate().eq(PenaltyCaseInfo::getCaseid, penaltyCaseInfo.getCaseid()).remove();
|
||||
}
|
||||
for (PenaltyCaseInfoEntInfoDto entInfoDto : requestDto.getPenaltylist()) {
|
||||
PenaltyEntInfo one = penaltyEntInfoService.lambdaQuery().eq(PenaltyEntInfo::getCaseid, requestDto.getCaseid())
|
||||
.eq(PenaltyEntInfo::getPripid, entInfoDto.getPripid()).ne(PenaltyEntInfo::getFlgDeleted, CommonConstants.TRUE_1)
|
||||
.last("limit 1").one();
|
||||
|
||||
PenaltyEntInfo penaltyEntInfo = new PenaltyEntInfo();
|
||||
penaltyEntInfo.setCaseid(requestDto.getCaseid());
|
||||
penaltyEntInfo.setPripid(entInfoDto.getPripid());
|
||||
|
|
@ -182,13 +181,8 @@ public class PenaltySecurityController {
|
|||
penaltyEntInfo.setEnttype(StringUtils.trimToEmpty(cleanEntTypeCode(entInfoDto.getEnttype())));
|
||||
penaltyEntInfo.setUpdateTime(LocalDateTime.now());
|
||||
penaltyEntInfo.setFlgDeleted("0");
|
||||
if (one == null) {
|
||||
penaltyEntInfo.setCreateTime(LocalDateTime.now());
|
||||
penaltyEntInfoService.save(penaltyEntInfo);
|
||||
} else {
|
||||
penaltyEntInfo.setId(one.getId());
|
||||
penaltyEntInfoService.updateById(penaltyEntInfo);
|
||||
}
|
||||
}
|
||||
|
||||
return SecurityResultAcceptVO.success(penaltyAcceptLog.getAcceptId());
|
||||
|
|
|
|||
Loading…
Reference in New Issue