Commit 9d8e6eb100f2164aced8f50324f789f04a85f4e7

Authored by 黄 x
1 parent 7a8197a0

fix: 场景联动只允许租户管理、客户进行操作管理

... ... @@ -5,6 +5,7 @@ import io.swagger.annotations.ApiOperation;
5 5 import lombok.RequiredArgsConstructor;
6 6 import org.springframework.http.HttpStatus;
7 7 import org.springframework.http.ResponseEntity;
  8 +import org.springframework.security.access.prepost.PreAuthorize;
8 9 import org.springframework.validation.annotation.Validated;
9 10 import org.springframework.web.bind.annotation.*;
10 11 import org.springframework.web.servlet.support.ServletUriComponentsBuilder;
... ... @@ -33,6 +34,7 @@ import static org.thingsboard.server.common.data.yunteng.constant.QueryConstant.
33 34 @RequestMapping("/api/yt/sceneLinkage")
34 35 @RequiredArgsConstructor
35 36 @Api(tags = "场景联动")
  37 +@PreAuthorize("hasAnyAuthority('TENANT_ADMIN','CUSTOMER_USER')")
36 38 public class YtSceneLinkageController extends BaseController {
37 39
38 40 private final SceneLinkageService sceneLinkageService;
... ...