From 3e18d4bfbf2c657b08b21512c2d884cc9d59df7b Mon Sep 17 00:00:00 2001 From: dengzedong <dengzedong@email> Date: 星期一, 14 十月 2024 16:29:49 +0800 Subject: [PATCH] 模型运行 --- iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java | 14 +++++++++----- 1 files changed, 9 insertions(+), 5 deletions(-) diff --git a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java index 2073532..6122d90 100644 --- a/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java +++ b/iailab-module-data/iailab-module-data-biz/src/main/java/com/iailab/module/data/channel/kio/controller/admin/ChannelKioTagController.java @@ -8,6 +8,7 @@ import com.iailab.module.data.channel.kio.vo.KioTagPageReqVO; import com.iailab.module.data.channel.kio.vo.KioTagRespVO; import io.swagger.v3.oas.annotations.Operation; +import org.springframework.security.access.prepost.PreAuthorize; import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; @@ -18,9 +19,7 @@ import static com.iailab.framework.common.pojo.CommonResult.success; /** - * @author lirm - * @Description - * @createTime 2024年08月26日 + */ @RestController @RequestMapping("/data/channel/kio/tag") @@ -31,12 +30,14 @@ /** * 分页查询tag * */ + @PreAuthorize("@ss.hasPermission('data:channel-kio:query')") @GetMapping("page") public CommonResult<PageResult<KioTagRespVO>> page(@Valid KioTagPageReqVO reqVO){ PageResult<ChannelKioTagEntity> page = channelKioTagService.queryPage(reqVO); return success(BeanUtils.toBean(page, KioTagRespVO.class)); } + @PreAuthorize("@ss.hasPermission('data:channel-kio:query')") @GetMapping("/info/{id}") @Operation(summary = "信息") public CommonResult<ChannelKioTagEntity> info(@PathVariable("id") String id) { @@ -44,8 +45,9 @@ return success(info); } - @PostMapping("/add") - public CommonResult<Boolean> add(@RequestBody ChannelKioTagEntity channelKioTagEntity) { + @PreAuthorize("@ss.hasPermission('data:channel-kio:create')") + @PostMapping("/create") + public CommonResult<Boolean> create(@RequestBody ChannelKioTagEntity channelKioTagEntity) { String id = UUID.randomUUID().toString(); channelKioTagEntity.setId(id); channelKioTagEntity.setCreateTime(new Date()); @@ -53,6 +55,7 @@ return success(true); } + @PreAuthorize("@ss.hasPermission('data:channel-kio:update')") @PutMapping("/update") public CommonResult<Boolean> update(@RequestBody ChannelKioTagEntity channelKioTagEntity) { channelKioTagEntity.setUpdateTime(new Date()); @@ -60,6 +63,7 @@ return success(true); } + @PreAuthorize("@ss.hasPermission('data:channel-kio:delete')") @DeleteMapping("/delete") public CommonResult<Boolean> delete(@RequestParam("id") String id) { channelKioTagService.delete(id); -- Gitblit v1.9.3