fix: 修改系统参数只允许系统管理员操作
This commit is contained in:
parent
52b0b93510
commit
801ee5edd5
|
@ -5,6 +5,7 @@ import io.metersphere.commons.constants.ParamConstants;
|
|||
import io.metersphere.commons.constants.RoleConstants;
|
||||
import io.metersphere.ldap.domain.LdapInfo;
|
||||
import io.metersphere.service.SystemParameterService;
|
||||
import org.apache.shiro.authz.annotation.Logical;
|
||||
import org.apache.shiro.authz.annotation.RequiresRoles;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
|
@ -30,6 +31,7 @@ public class SystemParameterController {
|
|||
}
|
||||
|
||||
@GetMapping("/version")
|
||||
@RequiresRoles(value = {RoleConstants.ADMIN, RoleConstants.TEST_MANAGER, RoleConstants.TEST_USER, RoleConstants.TEST_VIEWER, RoleConstants.ORG_ADMIN}, logical = Logical.OR)
|
||||
public String getVersion() {
|
||||
return SystemParameterService.getVersion();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue