|
@@ -100,14 +100,9 @@ public class EnterpriseHandler extends BaseNotifyHandler {
|
|
|
// 通知到达时本地尚未创建 → 先查预登记记录(applyInvite 创建的 PENDING 记录)
|
|
// 通知到达时本地尚未创建 → 先查预登记记录(applyInvite 创建的 PENDING 记录)
|
|
|
entity = enterpriseMapper.selectByOutBizNoIgnoreTenant(outBizNo);
|
|
entity = enterpriseMapper.selectByOutBizNoIgnoreTenant(outBizNo);
|
|
|
if (entity == null) {
|
|
if (entity == null) {
|
|
|
- // PENDING 也不存在(历史数据),直接新建
|
|
|
|
|
- entity = new EnterpriseEntity();
|
|
|
|
|
- entity.setEnterpriseId(enterpriseId);
|
|
|
|
|
- entity.setOutBizNo(outBizNo);
|
|
|
|
|
- entity.setAccountId(accountId);
|
|
|
|
|
- entity.setStatus(status);
|
|
|
|
|
- entity.setRemark(remark);
|
|
|
|
|
- enterpriseMapper.insert(entity);
|
|
|
|
|
|
|
+ // PENDING 也不存在,无法获取 tenantId,记录错误并跳过
|
|
|
|
|
+ log.error("通知找不到企业记录且无PENDING预登记: enterprise_id={}, out_biz_no={}", enterpriseId, outBizNo);
|
|
|
|
|
+ return;
|
|
|
} else {
|
|
} else {
|
|
|
entity.setEnterpriseId(enterpriseId);
|
|
entity.setEnterpriseId(enterpriseId);
|
|
|
entity.setOutBizNo(outBizNo);
|
|
entity.setOutBizNo(outBizNo);
|