|
|
|
@ -50,10 +50,7 @@ public class IoCodeLostServiceImpl extends ServiceImpl<IoCodeLostMapper, IoCodeL
|
|
|
|
|
|
|
|
|
|
public IoCodeLostEntity findByCode(String code) {
|
|
|
|
|
|
|
|
|
|
List<IoCodeLostEntity> codeLostEntities = codeLostEntityMapper.selectList(new QueryWrapper<IoCodeLostEntity>().like("code", code).last("limit 1"));
|
|
|
|
|
if (CollUtil.isNotEmpty(codeLostEntities)) {
|
|
|
|
|
return codeLostEntities.get(0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
RelCodeDetailResponse codeRelEntity = relCodeDetailService.findByCode(code);
|
|
|
|
|
if (codeRelEntity != null) {
|
|
|
|
|
IoCodeLostEntity udiEntity = new IoCodeLostEntity();
|
|
|
|
@ -63,6 +60,12 @@ public class IoCodeLostServiceImpl extends ServiceImpl<IoCodeLostMapper, IoCodeL
|
|
|
|
|
udiEntity.setExpireDate(MsDateUtil.formatDate(codeRelEntity.getValidateDate(), "yyMMdd"));
|
|
|
|
|
return udiEntity;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
List<IoCodeLostEntity> codeLostEntities = codeLostEntityMapper.selectList(new QueryWrapper<IoCodeLostEntity>().like("code", code).last("limit 1"));
|
|
|
|
|
if (CollUtil.isNotEmpty(codeLostEntities)) {
|
|
|
|
|
return codeLostEntities.get(0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|