chenrui
6 天以前 4398a57a5d01d5dd4331f8a04f29f5fd9229a737
src/main/java/com/ruoyi/common/handler/CustomTenantLineHandler.java
@@ -9,6 +9,7 @@
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
import org.springframework.util.ObjectUtils;
import java.util.Set;
@@ -17,8 +18,12 @@
    @Override
    public Expression getTenantId() {
        Integer tenantId = SecurityUtils.getLoginUser().getTenantId();
        return new LongValue(tenantId);
        try {
            Integer tenantId = SecurityUtils.getLoginUser().getTenantId();
            return new LongValue(tenantId);
        } catch (Exception e) {
            return null;
        }
    }
    @Override