alphaH 2 tygodni temu
rodzic
commit
16fc5a4ee0

+ 1 - 3
java/src/main/java/com/payment/platform/core/tenant/TenantInnerInterceptor.java

@@ -107,9 +107,7 @@ public class TenantInnerInterceptor extends TenantLineInnerInterceptor {
                 // 无认证(通知回调/定时任务)→ 跳过,保持旧行为
                 if (CONDITIONAL_TABLES.contains(cleaned)) {
                     if (auth != null && auth.getPrincipal() instanceof LoginUser user) {
-                        if (user.getTenantId() != null) {
-                            return false; // 已登录用户 → 应用租户过滤
-                        }
+                        return user.getTenantId() == null; // 已登录用户 → 应用租户过滤
                     }
                     return true; // 无认证上下文 → 跳过
                 }