From e9816cbd43cc7d8f4b58b6c95d9a929e3f8b7d33 Mon Sep 17 00:00:00 2001 From: shiziyuan9527 Date: Sun, 29 Jan 2023 18:23:43 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E7=94=A8=E6=88=B7=E7=BB=84=E6=9D=83?= =?UTF-8?q?=E9=99=90):=20=E8=B6=85=E7=BA=A7=E7=AE=A1=E7=90=86=E5=91=98?= =?UTF-8?q?=E6=9D=83=E9=99=90=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../io/metersphere/service/BaseCheckPermissionService.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/framework/sdk-parent/sdk/src/main/java/io/metersphere/service/BaseCheckPermissionService.java b/framework/sdk-parent/sdk/src/main/java/io/metersphere/service/BaseCheckPermissionService.java index fda13d7e3f..109b00f092 100644 --- a/framework/sdk-parent/sdk/src/main/java/io/metersphere/service/BaseCheckPermissionService.java +++ b/framework/sdk-parent/sdk/src/main/java/io/metersphere/service/BaseCheckPermissionService.java @@ -78,6 +78,9 @@ public class BaseCheckPermissionService { } public void checkProjectOwner(String projectId) { + if (SessionUtils.getUserId() != null && baseUserService.isSuperUser(SessionUtils.getUserId())) { + return; + } Set projectIds = getUserRelatedProjectIds(); if (CollectionUtils.isEmpty(projectIds)) { return;